lilei 1 year ago
parent
commit
efdf355c93

+ 10 - 1
pages/index/index.vue

@@ -117,7 +117,7 @@
 	} from 'vuex'
 	import scrollBox from '@/components/scrollBox.vue'
 	import UniStatusBar from '@/components/uni-status-bar/uni-status-bar.vue'
-	import { shelfBondRecordWaitPayRecord, findStoreShelf, shelfGetTotalWaitQty, getProductfindByScanCode } from '@/api/shelf.js'
+	import { shelfBondRecordWaitPayRecord, findStoreShelf, shelfGetTotalWaitQty, getProductfindByScanCode, queryQplsConfig } from '@/api/shelf.js'
 	import { xprhStoreApplyRead } from '@/api/xprh.js'
 	import { findCurrentRewardRule } from '@/api/rewardRule.js'
 	import { listLookUp, getLookUpDatas, getCurrUserInfo } from '@/api/data.js';
@@ -323,6 +323,13 @@
 					}
 				});
 			},
+			// 获取价格配置
+			getPriceCofig(){
+				const data = this.$store.state.vuex_storeShelf
+				queryQplsConfig({shelfSn: data.shelfSn}).then(res => {
+					this.$store.state.vuex_configPrice = res.data || null
+				})
+			},
 			// 最新用户信息
 			getCurrUserInfo(){
 				getCurrUserInfo().then(res => {
@@ -407,6 +414,8 @@
 						console.log(res)
 						this.$store.state.vuex_storeShelf = res.data;
 						if(res.data){
+							// 获取价格权限配置
+							this.getPriceCofig()
 							// 保证金查询
 							this.getShelfBWPayRecord()
 							// 获取订单信息

+ 2 - 2
pages/storeManage/priceSetting/priceSetting.vue

@@ -96,8 +96,8 @@
 		methods:{
 			// 获取价格配置
 			getPriceCofig(){
-				this.priceType[0].show = this.configPrice.shelf_cost_show == '1'
-				this.priceType[1].show = this.configPrice.shelf_price_show == '1'
+				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)

+ 19 - 9
pagesA/digitalShelf/choosePart.vue

@@ -60,9 +60,16 @@
 										</view>
 										<view class="flex justify_between">
 											<view class="item-detail-text flex_1">
-												<view @click="openPriceModal(item,1)">
-													<text class="item-price" :style="{color:!item.price?'#666':''}" v-if="showCarPrice">{{item.price?'¥'+item.price:'暂无价格'}}</text>
-													<text class="item-price" :style="{color:!item.cost?'#666':''}" v-if="showCostPrice&&item.affiliation=='SHELF'">{{item.cost?'¥'+item.cost:'暂无价格'}}</text>
+												<!-- 货架产品 -->
+												<view @click="openPriceModal(item,1)" v-if="item.affiliation=='SHELF'">
+													<text class="item-price" :style="{color:!item.price?'#666':''}" v-if="showCarPrice&&configPrice.shelf_price_show == '1'">{{item.price?'¥'+item.price:'暂无价格'}}</text>
+													<text class="item-price" :style="{color:!item.cost?'#666':''}" v-if="showCostPrice&&configPrice.shelf_cost_show == '1'">{{item.cost?'¥'+item.cost:'暂无价格'}}</text>
+													<u-icon name="arrow-right" v-if="priceShowVal"></u-icon>
+												</view>
+												<!-- 非货架 -->
+												<view @click="openPriceModal(item,1)" v-else>
+													<text class="item-price" :style="{color:!item.price?'#666':''}" v-if="showCarPrice&&configPrice.non_shelf_price_show == '1'">{{item.price?'¥'+item.price:'暂无价格'}}</text>
+													<text class="item-price" :style="{color:!item.cost?'#666':''}" v-if="showCostPrice&&configPrice.non_shelf_cost_show == '1'">{{item.cost?'¥'+item.cost:'暂无价格'}}</text>
 													<u-icon name="arrow-right" v-if="priceShowVal"></u-icon>
 												</view>
 											</view>
@@ -72,7 +79,7 @@
 												</u-button>
 												<u-number-box v-else @change="updateVinNums" @blur="updateVinNums" v-model="item.qty" :index="item.productSn" :min="0" :max="item.currentInven"></u-number-box>
 											</view>
-											<view class="item-detail-text" v-if="item.affiliation=='SUPER_CATALOGUE'||!item.currentInven">
+											<view class="item-detail-text" v-if="item.affiliation=='NON_SHELF'||!item.currentInven">
 												<text v-if="!item.checked" @click="addPart(item)" class="phtxt">我要急送</text>
 												<u-number-box v-else @change="updateVinNums" @blur="updateVinNums" v-model="item.qty" :index="item.productSn" :min="0"></u-number-box>
 											</view>
@@ -116,8 +123,8 @@
 									</view>
 									<view class="flex justify_between">
 										<view class="item-detail-text flex_1" @click="openPriceModal(item,0)">
-											<text class="item-price" :style="{color:!item.price?'#666':''}" v-if="showCarPrice">{{item.price?'¥'+item.price:'暂无价格'}}</text>
-											<text class="item-price" :style="{color:!item.cost?'#666':''}" v-if="showCostPrice">{{item.cost?'¥'+item.cost:'暂无价格'}}</text>
+											<text class="item-price" :style="{color:!item.price?'#666':''}" v-if="showCarPrice&&configPrice.shelf_price_show == '1'">{{item.price?'¥'+item.price:'暂无价格'}}</text>
+											<text class="item-price" :style="{color:!item.cost?'#666':''}" v-if="showCostPrice&&configPrice.shelf_cost_show == '1'">{{item.cost?'¥'+item.cost:'暂无价格'}}</text>
 											<u-icon name="arrow-right" v-if="priceShowVal"></u-icon>
 										</view>
 										<view class="item-detail-text" v-if="item.currentInven">
@@ -156,7 +163,7 @@
 					<u-image width="44" height="44" :src="`/static/icon_shopping@3x.png`"></u-image>
 				</div>
 			</div>
-			<view v-if="(showCarPrice||showCostPrice)&&totalAmount">
+			<view>
 				<!-- 合计:<text>¥{{totalAmount}}</text> -->
 			</view>
 			<div>
@@ -184,7 +191,7 @@
 								<view class="item-detail-info">
 									<view class="flex justify_between">
 										<text class="item-detail-text flex_1">{{item.code}}</text>
-										<text class="item-detail-text" v-if="item.affiliation!='SUPER_CATALOGUE'">库存:{{item.currentInven?item.currentInven:0}} {{item.unit}}</text>
+										<text class="item-detail-text" v-if="item.affiliation!='NON_SHELF'">库存:{{item.currentInven?item.currentInven:0}} {{item.unit}}</text>
 									</view>
 									<view class="flex" v-if="item.productTypeSn=='543766811373752320'" style="padding-bottom: 5px;">
 										<u-tag :text="item.origCode" mode="light" borderColor="#ffffff" shape="circle" type="success"></u-tag>
@@ -229,7 +236,7 @@
 					<text>产品名称</text>
 					<text>{{tempData.name||'--'}}</text>
 				</view>
-				<view v-if="tempData.affiliation=='SHELF'">
+				<view>
 					<text>进货价</text>
 					<text>{{tempData.cost?'¥'+tempData.cost:'暂无价格'}}</text>
 				</view>
@@ -313,6 +320,9 @@
 			hasRedPacket(){
 				const rule = this.$store.state.vuex_rewardRule
 				return rule&&rule.ruleStatus == 'release'
+			},
+			configPrice(){
+				return this.$store.state.vuex_configPrice
 			}
 		},
 		onLoad(opts) {

+ 1 - 1
pagesA/qualityPolicy/creatCustomInfo.vue

@@ -16,7 +16,7 @@
 				<view class="inputs">{{carInfo.mileage}}KM</view>
 			</view>
 			<view class="flex align_center">
-				<view class="labes">车牌号:</view>
+				<view class="labes">车牌号<u-icon name="question-circle-fill"></u-icon>:</view>
 				<view class="inputs">{{carInfo.vehicleNumber||'--'}}</view>
 			</view>
 		</view>