From 0dcc25b1a158433ebb4f6ce26b0eec2e0a3e07bd Mon Sep 17 00:00:00 2001 From: luchenqun Date: Mon, 10 Apr 2017 20:11:44 +0800 Subject: [PATCH] =?UTF-8?q?=E7=94=A8=E4=B8=80=E4=B8=AA=E6=B5=81=E6=B0=93?= =?UTF-8?q?=E5=8A=9E=E6=B3=95=E7=A1=AE=E4=BF=9D=E6=98=BE=E7=A4=BA=E5=8E=86?= =?UTF-8?q?=E5=8F=B2=E6=90=9C=E7=B4=A2=E8=AE=B0=E5=BD=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- README.md | 2 +- public/scripts/controllers/menus-controller.js | 16 +++++++++------- 2 files changed, 10 insertions(+), 8 deletions(-) diff --git a/README.md b/README.md index 1761d2e..58f1075 100644 --- a/README.md +++ b/README.md @@ -33,7 +33,7 @@ **MySql**: 用来做数据存储。 **AngularJS**:大家都懂的。 **jQuery**: 大家都懂的。本来用了AngularJS是不需要再使用jQuery了的。但是有些功能AngularJS要大费周章才能完成,jQuery一句代码就能解决。所以还是忍不住将它导入了进来。 -**mongo**:保存登陆的session。 +**mongo**:后台保存登陆的session。 **Semantic**:由于没有美工人员,自己开发的,不想界面太丑,用了这套UI。 5 目录结构 diff --git a/public/scripts/controllers/menus-controller.js b/public/scripts/controllers/menus-controller.js index 405c796..9bd18c4 100644 --- a/public/scripts/controllers/menus-controller.js +++ b/public/scripts/controllers/menus-controller.js @@ -95,7 +95,7 @@ app.controller('menuCtr', ['$scope', '$stateParams', '$state', '$window', '$time $scope.searchByHistory = function(type, data) { $scope.searchWord = data; $('.search-item').val($scope.searchWord); - + $('.js-search-option').dropdown('set value', type); var types = {}; types[0] = '书签'; @@ -187,12 +187,14 @@ app.controller('menuCtr', ['$scope', '$stateParams', '$state', '$window', '$time bookmarkService.userInfo({}) .then((data) => { $scope.searchHistory = JSON.parse(data.search_history || '[]'); - $timeout(function() { - $('.search-item').popup({ - on: 'focus', - inline: true - }); - }, 1000) + for (var i = 1; i <= 100; i += 10) { + $timeout(function() { + $('.search-item').popup({ + on: 'focus', + inline: true + }); + }, 100 * i) + } }) .catch((err) => { toastr.error('获取信息失败。错误信息:' + JSON.stringify(err), "错误");