Browse Source

进度条数据绑定

yangc 8 years ago
parent
commit
07bbc0aa86

+ 2 - 2
src/main/webapp/resources/js/vendor/controllers/forstore/vendor_materialCtrl.js

@@ -19,10 +19,10 @@ define([ 'app/app', 'jquery-uploadify' ], function(app) {
 
 		$scope.$$nonProduct.enterBatchPutOnPropertySaveButton = false;
 
-		$scope.salePrice = 0;
+		// $scope.salePrice = 0;
 
 		$scope.setSalePrice = function (price) {
-			$scope.salePrice = price;
+			$scope.uasBatchPutOnProperty.editFluctuateRate = price;
 		}
 
 		$scope.onSalePriceChange = function (salePrice) {

+ 1 - 1
src/main/webapp/resources/view/vendor/forstore/erp/vendor_material_erp.html

@@ -1614,7 +1614,7 @@
 					</div>
 					<div class="operate-content">
 						<div class="batch-sale">
-							<p><span class="batch-price-title">批量设置销售价:</span><em>0</em><span class="batch-progress"><i style="left: {{salePrice ? salePrice > 200 ? '100%' : salePrice / 2 + '%' : 0}}"></i></span><em>200</em></p>
+							<p><span class="batch-price-title">批量设置销售价:</span><em>0</em><span class="batch-progress"><i style="left: {{uasBatchPutOnProperty.editFluctuateRate ? uasBatchPutOnProperty.editFluctuateRate > 200 ? '100%' : uasBatchPutOnProperty.editFluctuateRate / 2 + '%' : 0}}"></i></span><em>200</em></p>
 							<div><span>销售价 = 近一个月的平均销售价 X </span><input type="number" ng-model="uasBatchPutOnProperty.editFluctuateRate" ng-change="onSalePriceChange()"> %
 								<span class="com-btn-level2 com-btn-submit" ng-click="setSalePrice(100)">100%</span>
 								<span class="com-btn-level2 com-btn-submit" ng-click="setSalePrice(120)">120%</span>

+ 2 - 2
src/main/webapp/resources/view/vendor/forstore/erp/vendor_material_unstandard_erp.html

@@ -1614,8 +1614,8 @@
 					</div>
 					<div class="operate-content">
 						<div class="batch-sale">
-							<p><span class="batch-price-title">批量设置销售价:</span><em>0</em><span class="batch-progress"><i style="left: {{salePrice ? salePrice > 200 ? '100%' : salePrice / 2 + '%' : 0}}"></i></span><em>200</em></p>
-							<div><span>销售价 = 近一个月的平均销售价 X </span><input type="number" ng-model="salePrice" ng-change="onSalePriceChange()"> %
+							<p><span class="batch-price-title">批量设置销售价:</span><em>0</em><span class="batch-progress"><i style="left: {{uasBatchPutOnProperty.editFluctuateRate ? uasBatchPutOnProperty.editFluctuateRate > 200 ? '100%' : uasBatchPutOnProperty.editFluctuateRate / 2 + '%' : 0}}"></i></span><em>200</em></p>
+							<div><span>销售价 = 近一个月的平均销售价 X </span><input type="number" ng-model="uasBatchPutOnProperty.editFluctuateRate" ng-change="onSalePriceChange()"> %
 								<span class="com-btn-level2 com-btn-submit" ng-click="setSalePrice(100)">100%</span>
 								<span class="com-btn-level2 com-btn-submit" ng-click="setSalePrice(120)">120%</span>
 								<span class="com-btn-level2 com-btn-submit" ng-click="setSalePrice(130)">130%</span>