瀏覽代碼

一级市场订单转售修改

linbl 1 年之前
父節點
當前提交
8ac6e997c1
共有 1 個文件被更改,包括 6 次插入22 次删除
  1. 6 22
      pages/market/two/leader/resale.vue

+ 6 - 22
pages/market/two/leader/resale.vue

@@ -21,7 +21,7 @@
 				<view class="item">
 					<text class="label">转售金额(必填)</text>
 					<text class="desc">
-						<input type="number" v-model="order.resalePrice" placeholder="请输入(元)" />
+						<input type="number" v-model="resalePrice" placeholder="请输入(元)" />
 					</text>
 				</view>
 			</view>
@@ -33,7 +33,7 @@
 						<view class="itm" v-if="item.feeType ==1">2、收费类型:按交易额收取</view>
 						<view class="itm" v-if="item.feeType ==2">2、收费类型:按次收取</view>
 						<view class="itm" v-if="item.feeType ==1">3、收费%(按交易额):<span style="color: coral;">{{ item.percent }} %</span></view>
-						<view class="itm" v-if="item.feeType ==1">4、当前订单收取金额:<span style="color: coral;">{{ (item.percent * order.resalePrice)/100}} 元</span></view>
+						<view class="itm" v-if="item.feeType ==1">4、当前订单收取金额:<span style="color: coral;">{{ (item.percent * resalePrice)/100}} 元</span></view>
 						<view class="itm" v-if="item.feeType ==2">3、收费金额(按次收):<span style="color: coral;">{{ item.feeMoney }} 元</span></view>
 						<view class="itm" v-if="item.feeType ==2">4、当前订单收取金额:<span style="color: coral;">{{ item.feeMoney }} 元</span></view>
 						</br>
@@ -56,29 +56,14 @@
 export default {
 	data() {
 		return {
-			user: this.getUser(),
 			item: {},
-			order: {
-				resalePrice: '',
-				levelOneOrderId: '',
-				goodsId: '',
-				goodsName: '',
-				goodsUnit: '',
-				tradeAreaId: '',
-				tradeAreaName: '',
-			},
+			resalePrice: '',
 			feeItemLIst: []
 		};
 	},
 	onLoad(e) {
 		if (e.item) {
 			this.item = JSON.parse(e.item);
-			this.order.levelOneOrderId = this.item.id;
-			this.order.goodsId = this.item.goodsId;
-			this.order.goodsName = this.item.goodsNames;
-			this.order.goodsUnit = this.item.goodsUnit;
-			this.order.tradeAreaId = this.item.tradeAreaId;
-			this.order.tradeAreaName = this.item.tradeAreaName;
 		}
 		this.getFeeItem();
 	},
@@ -93,8 +78,8 @@ export default {
 			});
 		},
 		ok() {
-			let rule = [{ name: 'resalePrice', checkType: 'notnull', errorMsg: '请输入转售金额' }];
-			if (!this.verify.check(this.order, rule)) {
+			let rule = { name: 'resalePrice', checkType: 'notnull', errorMsg: '请输入转售金额' };
+			if (!this.verify.check(this.resalePrice, rule)) {
 				uni.showModal({ content: this.verify.error, showCancel: false });
 				return false;
 			}
@@ -105,8 +90,7 @@ export default {
 					if (res.confirm) {
 						this.http.request({
 							url: '/level-two-server/app/TbOrders/addOrderByResale',
-							method: 'POST',
-							data: this.order,
+							data: {id: this.item.id, resalePrice: this.resalePrice},
 							success: res => {
 								uni.showToast({title: '提交成功'});
 								this.item.resaleStatus = 1;