lilei 1 vuosi sitten
vanhempi
commit
3eecdfe911
2 muutettua tiedostoa jossa 6 lisäystä ja 8 poistoa
  1. 2 2
      App.vue
  2. 4 6
      pages/storeManage/priceSetting/priceSetting.vue

+ 2 - 2
App.vue

@@ -1,8 +1,8 @@
 <script>
 	export default {
 		globalData: {
-			// baseUrl: 'http://192.168.2.103:9110/saas/clz/', // 本地
-			baseUrl: 'https://md.test.zyucgj.com/saas/clz/', // 预发布
+			baseUrl: 'http://192.168.2.103:9110/saas/clz/', // 本地
+			// baseUrl: 'https://md.test.zyucgj.com/saas/clz/', // 预发布
 			// baseUrl: 'https://car.zyucgj.com/saas/clz/' // 生产
 		},
 		onLaunch: function() {

+ 4 - 6
pages/storeManage/priceSetting/priceSetting.vue

@@ -88,17 +88,11 @@
 		onLoad() {
 			this.shelfSn = this.hasShelf.shelfSn
 			this.priceShowType = this.$store.state.vuex_priceTypeList
-			this.getPriceCofig()
 		},
 		onShow() {
 			this.getRow()
 		},
 		methods:{
-			// 获取价格配置
-			getPriceCofig(){
-				this.priceType[0].show = this.configPrice.shelf_cost_show == '1' || this.configPrice.non_shelf_cost_show == '1'
-				this.priceType[1].show = this.configPrice.shelf_price_show == '1' || this.configPrice.non_shelf_price_show == '1'
-			},
 			priceChange(e,item){
 				console.log(e,item)
 				const row = item.storeParamList.find(k => k.paramCode == e.name)
@@ -131,6 +125,10 @@
 					item.carPriceVal = cop?cop.paramValue:''
 					const pp = a.find(b=>b.paramCode=='PURCHASES_PRICE') // 进货价值
 					item.ppPriceVal = pp?pp.paramValue:''
+					
+					// 列表显示价格选项判断
+					this.priceType[0].show = pp.status == 1
+					this.priceType[1].show = cop.status == 1
 					item.priceTypeList = JSON.parse(JSON.stringify(this.priceType.filter(item => item.show)))
 					// 赋值
 					item.priceTypeList.map(key => {