From d319879c78cc0648cbac5c83f576b44943866d45 Mon Sep 17 00:00:00 2001 From: wlh Date: Fri, 26 Dec 2014 21:52:41 +0800 Subject: [PATCH] delete email in rootscope --- tuban/build/main.js | 2 +- tuban/build/main.min.js | 2 +- tuban/lib/main.js | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/tuban/build/main.js b/tuban/build/main.js index f0feb1a..cda0738 100644 --- a/tuban/build/main.js +++ b/tuban/build/main.js @@ -57,7 +57,7 @@ app.run(['$rootScope', function($rootScope) { $rootScope.appName = '图班网'; $rootScope.desc = '基于位置的通讯录'; $rootScope.author = '鬼谣'; - $rootScope.email = 'wlhmyit@126.com'; + $rootScope._email = 'wlhmyit@126.com'; }]); diff --git a/tuban/build/main.min.js b/tuban/build/main.min.js index 3d6163a..8b21392 100644 --- a/tuban/build/main.min.js +++ b/tuban/build/main.min.js @@ -1,2 +1,2 @@ /*! tuban-wlhmyit 2014-12-26 */ -!function(a){function b(a,b,c,d,e,f,g,h){if(!document.getElementById("__vczero_vczero_tip")){var i=document.createElement("div");i.style.position="fixed","number"==typeof a&&(i.style.top=a+"px"),"number"==typeof b&&(i.style.left=b+"px"),"number"==typeof c&&(i.style.right=c+"px"),"number"==typeof d&&(i.style.bottom=d+"px"),i.id="__vczero_vczero_tip",i.style.zIndex="100",i.style.height=f+"px",i.style.width=e+"px",i.style.backgroundColor="#000",i.style.opacity="0.7",i.style.color="#FFF",i.style.textAlign="center",i.style.fontSize="15px",i.style.lineHeight=f/h+"px",i.style.borderRadius="3px",i.innerHTML=g,document.getElementsByTagName("body")[0].appendChild(i)}}function c(){var a=document.getElementById("__vczero_vczero_tip");a&&document.querySelector("body").removeChild(a)}var d={setTip:b,hideTip:c};a.Tip=d}(window);var app=angular.module("app",["ui.router","ngCookies"]),SERVER_BASE_URL="http://123.57.39.116:6547/";app.run(["$rootScope",function(a){a.appName="图班网",a.desc="基于位置的通讯录",a.author="鬼谣",a.email="wlhmyit@126.com"}]),app.constant("ServiceConfig",{wei_content:SERVER_BASE_URL+"wei/get",wei_zan:SERVER_BASE_URL+"wei/zan",wei_comment:SERVER_BASE_URL+"wei/comment",wei_create:SERVER_BASE_URL+"wei/create",user_get:SERVER_BASE_URL+"user/get",user_login:SERVER_BASE_URL+"user/login",user_register:SERVER_BASE_URL+"user/register",user_common:SERVER_BASE_URL+"user/getCommon",user_ben:SERVER_BASE_URL+"user/getBen",user_self:SERVER_BASE_URL+"user/getSelf",user_common_update:SERVER_BASE_URL+"user/updateCommon",user_ben_update:SERVER_BASE_URL+"user/updateBen",user_ben_get_name:SERVER_BASE_URL+"user/singleBen/name",user_common_get_nickname:SERVER_BASE_URL+"user/getCommon/name",user_ben_get_realname:SERVER_BASE_URL+"user/singleBen/name",wei_get_token_page:SERVER_BASE_URL+"wei/getByToken",wei_delete:SERVER_BASE_URL+"wei/delete",user_update_password:SERVER_BASE_URL+"user/updatePassword",article_get:SERVER_BASE_URL+"article/get",article_detail:SERVER_BASE_URL+"article/get/id",amap_url:"http://webapi.amap.com/maps?v=1.3&key=ad925c5003760094713775d64748d872&callback=init"}),app.config(["$httpProvider",function(a){a.defaults.headers.post["Content-Type"]="application/x-www-form-urlencoded;charset=utf-8",a.defaults.headers.put["Content-Type"]="application/x-www-form-urlencoded;charset=utf-8",a.defaults.transformRequest=[function(a){var b=[];for(var c in a)b.push(c+"="+a[c]);return b.join("&")}]}]),app.config(["$stateProvider","$urlRouterProvider",function(a,b){b.otherwise("/"),a.state("index",{url:"/",views:{"":{templateUrl:"views/index/index.html"},"header@index":{templateUrl:"views/header.html",controller:"HeaderController"},"footer@index":{templateUrl:"views/footer.html",controller:""},"weibo@index":{templateUrl:"views/index/weibo.html",controller:"WeiboController"},"article@index":{templateUrl:"views/index/article.html",controller:"ArticleController"},"post@index":{templateUrl:"views/index/post.html",controller:"PostWeiboController"}}}).state("login",{url:"/login",views:{"":{templateUrl:"views/login/login.html",controller:"LoginController"}}}).state("register",{url:"/register",views:{"":{templateUrl:"views/register/register.html",controller:"RegisterController"}}}).state("contacts",{url:"/contacts",views:{"":{templateUrl:"views/contacts/contacts.html",controller:""},"header@contacts":{templateUrl:"views/header.html",controller:"HeaderController"},"userinfo@contacts":{templateUrl:"views/contacts/userinfo.html",controller:"UserInfoController"},"map@contacts":{templateUrl:"views/contacts/map.html",controller:"MapController"},"search@contacts":{templateUrl:"views/contacts/search.html",controller:"SearchUserController"}}}).state("ucenter",{url:"/ucenter",views:{"":{templateUrl:"views/ucenter/ucenter.html",controller:""},"header@ucenter":{templateUrl:"views/header.html",controller:"HeaderController"},"userWeibo@ucenter":{templateUrl:"views/ucenter/weibo.html",controller:"UcWeiboController"},"userDetailInfo@ucenter":{templateUrl:"views/ucenter/user.html",controller:"UcUserController"},"footer@ucenter":{templateUrl:"views/footer.html",controller:""}}}).state("article",{url:"/article/:id",views:{"":{templateUrl:"views/article/article.html",controller:""},"header@article":{templateUrl:"views/header.html",controller:"HeaderController"},"article_content@article":{templateUrl:"views/article/article_content.html",controller:"ArticleDetailController"},"footer@article":{templateUrl:"views/footer.html",controller:""}}}).state("article_index",{url:"/article",views:{"":{templateUrl:"views/article/article.html",controller:""},"header@article_index":{templateUrl:"views/header.html",controller:"HeaderController"},"article_content@article_index":{templateUrl:"views/article/article_content.html",controller:"ArticleDetailController"},"footer@article_index":{templateUrl:"views/footer.html",controller:""}}})}]),app.service("SelfWeibo",["$http","ServiceConfig","Time",function(a,b,c){return{getData:function(d,e,f){var g="?token="+d+"&page="+e;a.get(b.wei_get_token_page+g).success(function(a){if(a.status){var b=a.items;for(i in b){b[i].time=c.formatTime(b[i].time);for(var d in b[i].comments)b[i].comments[d].time=c.formatTime(b[i].comments[d].time)}}f(a)}).error(function(){f({status:0})})}}}]),app.service("Time",function(){return{formatTime:function(a){var b=new Date(a);return b.getFullYear()+"-"+(parseInt(b.getMonth())+1)+"-"+b.getDate()+" "+b.getHours()+":"+b.getMinutes()+":"+b.getSeconds()}}}),app.service("WeiboData",["$http","Time","ServiceConfig",function(a,b,c){return{getItems:function(d,e){a.get(c.wei_content+"?page="+d).success(function(a){var c=[];if(a.status){c=a.items;for(var d=0;d10&&(b.items=b.items.slice(0,10))}),b.zan=function(b){var f=c.get("user");if(f){var g="?token="+f.token,h="&id="+b._id,i=e.wei_zan+g+h;a.get(i).success(function(a){a.status?a.zans?(b.zans=a.zans,Tip.setTip(200,350,null,null,240,80,"谢谢您的打赏~~~~",1),d(Tip.hideTip,2300)):(Tip.setTip(200,350,null,null,240,80,"伦家怎么好意思再收呢!",1),d(Tip.hideTip,2300)):(Tip.setTip(200,350,null,null,240,80,"不好意思,打赏失败了...",1),d(Tip.hideTip,2300))}).error(function(){Tip.setTip(200,350,null,null,260,80,"服务君感冒了,请刷新页面重试...",1),d(Tip.hideTip,2300)})}else Tip.setTip(200,350,null,null,240,80,"只有登录了,才能点赞哦~~~",1),d(Tip.hideTip,2300)},b.comment=function(a){a.isShowComDiv=a.isShowComDiv?!1:!0},b.addComment=function(b,g){var h=c.get("user");if(h&&g){var i="?token="+h.token,j="&comment="+g,k="&id="+b._id,l=e.wei_comment+i+j+k;a.get(l).success(function(a){a.status?(b.comments.push({nickname:a.nickname,email:a.email,comment:a.comment,avatar:a.avatar,time:f.formatTime(a.time)}),document.getElementById("_commentContent").value="",Tip.setTip(200,350,null,null,240,80,"您的评论实在是精彩了~~",1),d(Tip.hideTip,2300)):(Tip.setTip(200,350,null,null,240,80,"不好意思,评论失败了...",1),d(Tip.hideTip,2300))}).error(function(){Tip.setTip(200,350,null,null,240,80,"服务君感冒了,评论失败了...",1),d(Tip.hideTip,2300)})}else Tip.setTip(200,350,null,null,280,80,"请登录,评论的内容不能为空~~",1),d(Tip.hideTip,2300)},b.prePage=function(){b.currentPage=b.currentPage-1,b.currentPage>=0?g.getItems(10*b.currentPage,function(a){a.length?b.items=a:(Tip.setTip(200,350,null,null,260,80,"君别着急,现在都查不出数据了...",1),d(Tip.hideTip,2300))}):(b.currentPage=b.currentPage+1,Tip.setTip(200,350,null,null,260,80,"君别翻旧账了,这是第一页啦~~~",1),d(Tip.hideTip,2300))},b.nextPage=function(){b.currentPage=b.currentPage+1,b.currentPage=0?g.getData(h.token,j,function(b){b.status&&(a.items=b.items)}):(j=0,Tip.setTip(250,(parseInt(i)-240)/2,null,null,260,80,"已经是第一页...",1),d(Tip.hideTip,3e3))},a.nextPage=function(){j+=1,j10&&(b.items=b.items.slice(0,10))}),b.zan=function(b){var f=c.get("user");if(f){var g="?token="+f.token,h="&id="+b._id,i=e.wei_zan+g+h;a.get(i).success(function(a){a.status?a.zans?(b.zans=a.zans,Tip.setTip(200,350,null,null,240,80,"谢谢您的打赏~~~~",1),d(Tip.hideTip,2300)):(Tip.setTip(200,350,null,null,240,80,"伦家怎么好意思再收呢!",1),d(Tip.hideTip,2300)):(Tip.setTip(200,350,null,null,240,80,"不好意思,打赏失败了...",1),d(Tip.hideTip,2300))}).error(function(){Tip.setTip(200,350,null,null,260,80,"服务君感冒了,请刷新页面重试...",1),d(Tip.hideTip,2300)})}else Tip.setTip(200,350,null,null,240,80,"只有登录了,才能点赞哦~~~",1),d(Tip.hideTip,2300)},b.comment=function(a){a.isShowComDiv=a.isShowComDiv?!1:!0},b.addComment=function(b,g){var h=c.get("user");if(h&&g){var i="?token="+h.token,j="&comment="+g,k="&id="+b._id,l=e.wei_comment+i+j+k;a.get(l).success(function(a){a.status?(b.comments.push({nickname:a.nickname,email:a.email,comment:a.comment,avatar:a.avatar,time:f.formatTime(a.time)}),document.getElementById("_commentContent").value="",Tip.setTip(200,350,null,null,240,80,"您的评论实在是精彩了~~",1),d(Tip.hideTip,2300)):(Tip.setTip(200,350,null,null,240,80,"不好意思,评论失败了...",1),d(Tip.hideTip,2300))}).error(function(){Tip.setTip(200,350,null,null,240,80,"服务君感冒了,评论失败了...",1),d(Tip.hideTip,2300)})}else Tip.setTip(200,350,null,null,280,80,"请登录,评论的内容不能为空~~",1),d(Tip.hideTip,2300)},b.prePage=function(){b.currentPage=b.currentPage-1,b.currentPage>=0?g.getItems(10*b.currentPage,function(a){a.length?b.items=a:(Tip.setTip(200,350,null,null,260,80,"君别着急,现在都查不出数据了...",1),d(Tip.hideTip,2300))}):(b.currentPage=b.currentPage+1,Tip.setTip(200,350,null,null,260,80,"君别翻旧账了,这是第一页啦~~~",1),d(Tip.hideTip,2300))},b.nextPage=function(){b.currentPage=b.currentPage+1,b.currentPage=0?g.getData(h.token,j,function(b){b.status&&(a.items=b.items)}):(j=0,Tip.setTip(250,(parseInt(i)-240)/2,null,null,260,80,"已经是第一页...",1),d(Tip.hideTip,3e3))},a.nextPage=function(){j+=1,j