Browse Source

修复删除供应商联系人之后错乱显示的bug

git-svn-id: svn+ssh://10.10.101.21/source/platform/platform-b2b@7677 f3bf4e98-0cf0-11e4-a00c-a99a8b9d557d
hejq 9 years ago
parent
commit
d68ba387df
1 changed files with 2 additions and 2 deletions
  1. 2 2
      src/main/webapp/resources/js/index/app.js

+ 2 - 2
src/main/webapp/resources/js/index/app.js

@@ -8033,7 +8033,7 @@ define([ 'toaster', 'charts', 'ngTable', 'common/services', 'service/Purc', 'ser
 		});
 		});
 		
 		
 		// 获取地址信息
 		// 获取地址信息
-		$http.get('resources/citydata/city.json',  {"Accept": "application/json;charset=utf-8", "Accept-Charset":"charset=utf-8"
+		$http.get('resources/citydata/city.json',  {"Accept": "application/json;charset=utf-8", "Accept-Charset": "charset=utf-8"
 		   }).then(function(response) {
 		   }).then(function(response) {
 			$scope.provinces = response.data;
 			$scope.provinces = response.data;
 		});
 		});
@@ -8564,9 +8564,9 @@ define([ 'toaster', 'charts', 'ngTable', 'common/services', 'service/Purc', 'ser
 		
 		
 		// 删除供应商联系人
 		// 删除供应商联系人
 		$scope.deleteById = function(id, index) {
 		$scope.deleteById = function(id, index) {
+			$scope.vendorContacts.splice(index, 1);
 			Vendor.deleteContact({id: id}, {}, function(data) {
 			Vendor.deleteContact({id: id}, {}, function(data) {
 				toaster.pop('success', '提示', '供应商联系人删除成功');
 				toaster.pop('success', '提示', '供应商联系人删除成功');
-				$scope.vendorContacts.splice(1, index);
 			}, function(response) {
 			}, function(response) {
 				toaster.pop('error', '提示', response.data);
 				toaster.pop('error', '提示', response.data);
 			});
 			});