Ver Fonte

丽格V1.0.1

zhengjinyi há 1 ano atrás
pai
commit
9464605c9a

+ 3 - 4
components/cm-module/cm-cart-temp/index.vue

@@ -6,7 +6,7 @@
 			borderRadius="10rpx"
 			:isLoading="true"
 			:loadingType="5"
-		></tui-skeleton>
+		/>
 		<view v-else class="container-cart-main tui-skeleton" :style="{ paddingTop: isshowDelbtn ? '0rpx' : '80rpx' }">
 			<template v-if="pathType == 0">
 				<view class="foot-check-delbtn" v-if="!isshowDelbtn && goodsList.length > 0">
@@ -231,7 +231,7 @@
 			:popupShow="popupShow2"
 			:skuProduct="handlePros"
 			@skuBtnConfirm="handleBtnConfirm"
-		></cm-unit-popup>
+		/>
 		<!-- 弹窗提示 -->
 		<tui-modal
 			:show="modal"
@@ -243,8 +243,7 @@
 			:size="32"
 			shape="circle"
 			:maskClosable="false"
-		>
-		</tui-modal>
+		/>
 	</view>
 </template>
 

+ 1 - 1
components/cm-module/headerNavbar/header-back.vue

@@ -18,8 +18,8 @@
 				lineHeight: navbarBtn.height + 'px;'
 			}"
 		>
-			<text v-if="haveBack" @click="_goBack" class="iconfont icon-fanhui"></text>
 			<text v-if="isShare" @click="_goBack" class="iconfont icon-shouye"></text>
+			<text v-else @click="_goBack" class="iconfont icon-fanhui"></text>
 		</view>
 		<view
 			class="navbar-icon"

+ 4 - 5
pages/seller/cart/components/index.vue

@@ -6,7 +6,7 @@
 			borderRadius="10rpx"
 			:isLoading="true"
 			:loadingType="5"
-		></tui-skeleton>
+		/>
 		<view v-else class="container-cart-main tui-skeleton" :style="{ paddingTop: isshowDelbtn ? '0rpx' : '80rpx' }">
 			<view class="foot-check-delbtn" v-if="!isshowDelbtn && goodsList.length > 0">
 				<view class="foot-text"
@@ -144,7 +144,7 @@
 						</view>
 					</view>
 				</view>
-				<view class="footer">
+				<view class="footer" :style="{ paddingBottom: isIphoneX ? '68rpx' : '0rpx' }">
 					<view class="footer-le">
 						<view class="foot-check checkbox-box" @tap.stop="handleCheckAll">
 							<button
@@ -187,7 +187,7 @@
 			:popupShow="popupShow2"
 			:skuProduct="handlePros"
 			@skuBtnConfirm="handleBtnConfirm"
-		></cm-unit-popup>
+		/>
 		<!-- 弹窗提示 -->
 		<tui-modal
 			:show="modal"
@@ -199,8 +199,7 @@
 			:size="32"
 			shape="circle"
 			:maskClosable="false"
-		>
-		</tui-modal>
+		/>
 	</view>
 </template>
 

+ 1 - 1
pages/seller/goods/components/cm-unit-popup.vue

@@ -159,7 +159,7 @@ export default {
 		handleChoisSku(sku, index) {
 			// 选择SKU
 			this.skuIndex = index
-			this.unitParams.productCount = this.handleMinNumber = sku.minBuyNumber
+			this.unitParams.productCount = this.productCount = this.handleMinNumber = sku.minBuyNumber
 			this.unitParams.skuId = sku.skuId
 			this.skuProductPrice = sku.price
 			this.$emit('skuClick', sku)

+ 23 - 12
pages/seller/order/components/cm-freight-popup.vue

@@ -73,7 +73,7 @@
 									class="form-input"
 									type="number"
 									v-model="handlePostageVal"
-									@input="handleInputPostage"
+									@input="$event => (handlePostageVal = checkedInput($event))"
 									placeholder="请填写运费"
 									maxlength="20"
 								/>
@@ -148,7 +148,7 @@ export default {
 		return {
 			popupShow: false,
 			isColdChina: false,
-			handleColdChain:0,// 记录冷链费
+			handleColdChain: 0, // 记录冷链费
 			handlePostage: 0, // 记录原始运费
 			handlePostageVal: 0, // 记录修改的运费
 			handlePostageFlag: 0, //  记录运费类型
@@ -223,11 +223,11 @@ export default {
 					break
 			}
 		},
-		handleInputPostage(e) {
-			//处理邮费显示
-			// if (e.detail.value == '') {
-			// 	this.handleSupplier.postage = 0
-			// }
+		//处理格式
+		checkedInput(e) {
+			const value = e.detail.value
+			const pattern = /[^0-9.]/g
+			return Number(value.replace(pattern, ''))
 		},
 		// 勾选冷链费
 		handleChangeColdChina() {
@@ -257,22 +257,33 @@ export default {
 		// 确定运费
 		handleComfirm() {
 			if (this.handlePostageFlag === 0) {
-				let handleTotalPrice = this.isColdChina ? this.handleTotalPrice : Number(this.repiceNumSub(this.handleTotalPrice, this.handleColdChain))
-				this.handleSupplier.totalPrice = Number(this.repiceNumSub(handleTotalPrice, this.handleSupplier.postage))
+				let handleTotalPrice = this.isColdChina
+					? this.handleTotalPrice
+					: Number(this.repiceNumSub(this.handleTotalPrice, this.handleColdChain))
+				this.handleSupplier.totalPrice = Number(
+					this.repiceNumSub(handleTotalPrice, this.handleSupplier.postage)
+				)
 				this.$emit('changePostage', this.handleSupplier, this.index)
 			} else if (this.handlePostageFlag === 1) {
 				if (this.handlePostageVal == 0 || !this.handlePostageVal) {
 					this.$util.msg('请填写运费', 2000)
 					return
 				}
+				let handleTotalPrice = this.isColdChina
+					? this.handleTotalPrice
+					: Number(this.repiceNumSub(this.handleTotalPrice, this.handleColdChain))
 				this.handleSupplier.totalPrice = Number(
-					(this.handleTotalPrice * 100 - this.handlePostage * 100 + this.handlePostageVal * 100) / 100
+					(handleTotalPrice * 100 - this.handlePostage * 100 + this.handlePostageVal * 100) / 100
 				)
 				this.handleSupplier.postage = this.handlePostageVal
 				this.$emit('changePostage', this.handleSupplier, this.index)
 			} else {
-				let handleTotalPrice = this.isColdChina ? this.handleTotalPrice : Number(this.repiceNumSub(this.handleTotalPrice, this.handleColdChain))
-				this.handleSupplier.totalPrice = Number(this.repiceNumSub(handleTotalPrice, this.handleSupplier.postage))
+				let handleTotalPrice = this.isColdChina
+					? this.handleTotalPrice
+					: Number(this.repiceNumSub(this.handleTotalPrice, this.handleColdChain))
+				this.handleSupplier.totalPrice = Number(
+					this.repiceNumSub(handleTotalPrice, this.handleSupplier.postage)
+				)
 				this.$emit('changePostage', this.handleSupplier, this.index)
 			}
 			this.popupShow = false