Browse Source

增加地址选择

git-svn-id: svn+ssh://10.10.101.21/source/platform/platform-b2b@7523 f3bf4e98-0cf0-11e4-a00c-a99a8b9d557d
hejq 9 years ago
parent
commit
f88cff5d26

File diff suppressed because it is too large
+ 0 - 0
src/main/webapp/resources/citydata/city.json


+ 42 - 0
src/main/webapp/resources/css/add.css

@@ -436,11 +436,28 @@ input:focus, select:focus {
 	float: left;
 }
 
+.per-data ul li button {
+	width: 94px;
+	height: 36px;
+	display: inline-block;
+	font-size: 14px;
+	color: #fff;
+	text-align: center;
+	line-height: 34px;
+	float: left;
+}
+
 .per-data ul li a.save {
 	margin-left: 60px;
 	background: #327ebe;
 }
 
+.per-data ul li button.save {
+	margin-left: 60px;
+	background: #327ebe;
+		border: 1px;
+}
+
 .per-data ul li a.mod-psd {
 	background: #8dc7f9;
 	margin-left: 30px;
@@ -450,6 +467,10 @@ input:focus, select:focus {
 	background: #3578ba;
 }
 
+.per-data ul li button:hover {
+	background: #3578ba;
+}
+
 /*产品资料-价格-新增*/
 .com_head {
 	width: 100%;
@@ -1109,11 +1130,27 @@ input:focus, select:focus {
 	text-align: center;
 }
 
+.bomb-box .box04 .many-file-btn button {
+	width: 94px;
+	height: 36px;
+	line-height: 36px;
+	font-size: 14px;
+	display: inline-block;
+	text-align: center;
+}
+
+.bomb-box .box04 .many-file-btn button.btn01 {
+	border: 1px;
+	background: #327ebe;
+	color: #fff;
+}
+
 .bomb-box .box04 .many-file-btn a.btn01 {
 	background: #327ebe;
 	color: #fff;
 }
 
+
 .bomb-box .box04 .many-file-btn .btn01 a {
 	color: #fff;
 }
@@ -1124,6 +1161,11 @@ input:focus, select:focus {
 	margin-left: 45px;
 }
 
+.bomb-box .box04 .many-file-btn button:hover {
+	background: #135c9a;
+	color: #fff;
+}
+
 .bomb-box .box04 .many-file-btn a:hover {
 	background: #135c9a;
 	color: #fff;

+ 18 - 3
src/main/webapp/resources/js/index/app.js

@@ -7945,7 +7945,7 @@ app.controller('SaleSendCtrl', ['$scope', '$filter', 'SaleSend', 'ngTableParams'
 	/**
 	 * 新增采购单
 	 */
-	app.controller('PurcNewOrderCtrl',['$scope', '$modal', 'toaster', '$filter', 'addtoCart', '$rootScope', 'VendorInfo', 'ngTableParams', 'BaseService', 'Product', 'newPurcOrder', 'cartOperation', 'ShipAddress', 'Vendor', function($scope, $modal, toaster, $filter, addtoCart, $rootScope, VendorInfo, ngTableParams, BaseService, Product, newPurcOrder, cartOperation, ShipAddress, Vendor) {
+	app.controller('PurcNewOrderCtrl',['$scope', '$modal', 'toaster', '$filter', 'addtoCart', '$rootScope', 'VendorInfo', 'ngTableParams', 'BaseService', 'Product', 'newPurcOrder', 'cartOperation', 'ShipAddress', 'Vendor', '$http', function($scope, $modal, toaster, $filter, addtoCart, $rootScope, VendorInfo, ngTableParams, BaseService, Product, newPurcOrder, cartOperation, ShipAddress, Vendor, $http) {
 		
 		// 获取收货地址列表
 		ShipAddress.shipAddList({}, function(data) {
@@ -7953,6 +7953,12 @@ app.controller('SaleSendCtrl', ['$scope', '$filter', 'SaleSend', 'ngTableParams'
 			$scope.order.shipadd = $scope.ships[0];
 		});
 		
+		// 获取地址信息
+		$http.get('resources/citydata/city.json',  {"Accept": "application/json;charset=utf-8", "Accept-Charset":"charset=utf-8"
+		   }).then(function(response) {
+			$scope.provinces = response.data;
+		});
+		
 		$scope.order = {
 				date : new Date(),
 				cust : {
@@ -8167,7 +8173,6 @@ app.controller('SaleSendCtrl', ['$scope', '$filter', 'SaleSend', 'ngTableParams'
 				}
 			}
 			addtoCart.save({}, $scope.order, function(data){
-			    console.log($scope.order);
 				$scope.loading = false;
 				toaster.pop('success', '成功', '保存成功');
 				window.location.hash = '#/purc/cart/'+data.id;
@@ -8320,6 +8325,13 @@ app.controller('SaleSendCtrl', ['$scope', '$filter', 'SaleSend', 'ngTableParams'
 	 * 我的供应商
 	 */
 	app.controller('PurcVendorCtrl', ['$scope', 'Vendor', 'BaseService','AuthenticationService', 'ngTableParams', '$modal','toaster', '$rootScope', function($scope, Vendor, BaseService, AuthenticationService,ngTableParams,$modal, toaster, $rootScope){
+		// 搜索框回车
+		$scope.onSearch = function(keyword) {
+			$scope.keyword = keyword;
+			$scope.customerParams.page(1);
+			$scope.customerParams.reload();
+		};
+		
 		$scope.customerParams = new ngTableParams({
 			page : 1, 
 			count : 10
@@ -8328,7 +8340,9 @@ app.controller('SaleSendCtrl', ['$scope', '$filter', 'SaleSend', 'ngTableParams'
 			counts: [5, 10, 25, 50],
 			getData : function($defer, params) {
 				$scope.loading = true;
-				Vendor.getVendor(BaseService.parseParams(params.url()), function(page){
+				var pageParams = params.url();
+				pageParams.keyword = $scope.keyword;
+				Vendor.getVendor.call(null, BaseService.parseParams(pageParams), function(page){
 					$scope.loading = false;
 					if(page) {
 						params.total(page.totalElements);
@@ -8353,6 +8367,7 @@ app.controller('SaleSendCtrl', ['$scope', '$filter', 'SaleSend', 'ngTableParams'
 			$rootScope.businessCode = businessCode;
 			window.location.hash = "#/purc/addOrder";
 		}
+		
 	}]);
 	
 	/**

Some files were not shown because too many files changed in this diff