From 4eda50a881183f821e678d9ae96acd09f26d2b6e Mon Sep 17 00:00:00 2001 From: luchenqun Date: Mon, 27 Feb 2017 20:15:42 +0800 Subject: [PATCH] =?UTF-8?q?=E5=A6=82=E6=9E=9C=E5=A2=9E=E5=8A=A0=E7=9A=84?= =?UTF-8?q?=E5=88=86=E7=B1=BB=E4=B8=BA=E7=A9=BA=EF=BC=8C=E9=82=A3=E4=B9=88?= =?UTF-8?q?=E4=B8=8D=E5=85=B3=E9=97=AD=E9=A1=B5=E9=9D=A2?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- public/scripts/controllers/tags-controller.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/public/scripts/controllers/tags-controller.js b/public/scripts/controllers/tags-controller.js index 6088fcc..56ae1ae 100644 --- a/public/scripts/controllers/tags-controller.js +++ b/public/scripts/controllers/tags-controller.js @@ -216,10 +216,11 @@ app.controller('tagsCtr', ['$scope', '$filter', '$window', '$stateParams', '$tim } $scope.addTag = function(tag) { - ngDialog.close(dialog); console.log(tag); tag = tag.replace(/(^\s*)|(\s*$)/g, '').replace(/\s+/g, ' '); // 去除前后空格,多个空格转为一个空格; if (tag) { + ngDialog.close(dialog); + var tags = []; tags.push(tag); bookmarkService.addTags(tags)