From 35b8f2e7b34875efebed526a7394ff50e65f8e90 Mon Sep 17 00:00:00 2001
From: whycq <10027870+whycq@user.noreply.gitee.com>
Date: 星期三, 22 十一月 2023 10:50:15 +0800
Subject: [PATCH] #
---
pages/business/plan/addPlan2.vue | 62 ++++++++++++++++---------------
1 files changed, 32 insertions(+), 30 deletions(-)
diff --git a/pages/business/plan/addPlan2.vue b/pages/business/plan/addPlan2.vue
index 2384db9..91b91c3 100644
--- a/pages/business/plan/addPlan2.vue
+++ b/pages/business/plan/addPlan2.vue
@@ -8,31 +8,18 @@
<uni-forms-item label="璺熻釜椤圭洰" required name="orderId" >
<view @click="autoLoad('order','')">
<uni-combox :candidates="orderIds" placeholder="璇烽�夋嫨璺熻釜椤圭洰"
- v-model="baseFormData.orderId" @input="autoLoad('order',baseFormData.orderId)"></uni-combox>
+ v-model="baseFormData.orderId$" @input="autoLoad('order',baseFormData.orderId$)"></uni-combox>
</view>
</uni-forms-item>
- <uni-forms-item label="涓氬姟鍛�" required name="userId">
- <view @click="autoLoad('user','')">
- <uni-combox :candidates="users" placeholder="璇烽�夋嫨涓氬姟鍛�"
- v-model="baseFormData.userId" @input="autoLoad('user',baseFormData.userId)"></uni-combox>
+ <uni-forms-item label="瀹㈡埛鍚嶇О" required name="cstmrId">
+ <view @click="autoLoad('cstmr','')">
+ <uni-combox :candidates="cstmrs" placeholder="璇烽�夋嫨瀹㈡埛鍚嶇О"
+ v-model="baseFormData.cstmrId$" @input="autoLoad('cstmr',baseFormData.cstmrId$)"></uni-combox>
</view>
</uni-forms-item>
<uni-forms-item label="涓氬姟鍛樿仈绯绘柟寮�" required name="userXmlSelPhone">
<uni-easyinput v-model="baseFormData.userXmlSelPhone" placeholder="璇疯緭鍏ヤ笟鍔″憳鑱旂郴鏂瑰紡" />
- </uni-forms-item>
- <uni-forms-item label="鎵�闇�" name="planNeed">
- <uni-data-checkbox v-model="baseFormData.planNeed" multiple :localdata="planNeeds" />
- </uni-forms-item>
- <uni-forms-item label="鐢宠鏃ユ湡" required name="appleTime">
- <uni-datetime-picker type="date" return-type="string" v-model="baseFormData.appleTime" />
- </uni-data-picker>
- </uni-forms-item>
- <uni-forms-item label="瀹㈡埛鍚嶇О" required name="cstmrId">
- <view @click="autoLoad('cstmr','')">
- <uni-combox :candidates="cstmrs" placeholder="璇烽�夋嫨瀹㈡埛鍚嶇О"
- v-model="baseFormData.cstmrId" @input="autoLoad('cstmr',baseFormData.cstmrId)"></uni-combox>
- </view>
</uni-forms-item>
<uni-forms-item label="涓氬姟绫诲瀷" required name="planType">
<uni-easyinput disabled placeholder="璇疯緭鍏ヤ笟鍔$被鍨�" v-model="baseFormData.planType"></uni-easyinput>
@@ -40,6 +27,12 @@
<uni-forms-item label="绔嬮」" name="beItem">
<uni-data-checkbox v-model="baseFormData.beItem" :localdata="beItem$" />
</uni-forms-item>
+ <uni-forms-item label="鎵�闇�" name="planNeed">
+ <uni-data-checkbox v-model="baseFormData.planNeed" multiple :localdata="planNeeds" />
+ </uni-forms-item>
+
+
+
<uni-forms-item label="璐х墿瑙勬牸" required name="input_2">
@@ -97,9 +90,6 @@
</uni-forms-item>
<br>
- <uni-forms-item label="瑙勫垝鍛�" name="planner$">
- <uni-easyinput v-model="baseFormData.planner$" placeholder="璇疯緭鍏ヨ鍒掑憳" />
- </uni-forms-item>
<uni-forms-item label="鏇存敼鏂规" name="change">
<uni-data-checkbox v-model="baseFormData.change" :localdata="changeValue" />
</uni-forms-item>
@@ -126,6 +116,7 @@
</template>
<script>
+ import user from '@/pages/api/user/user.js'
import test from '../../../static/js/citys-data.js'
export default {
data() {
@@ -142,12 +133,13 @@
userId: '',
appleTime: '',
cstmrId: '',
- planType: '绔嬩綋搴擄紙璐ф灦锛�',
+ planType: '绔嬩綋搴擄紙闆嗘垚锛�',
select_2: '',
changeReason: '',
changeTime: '',
planBonus: '',
- planLeaderBonus: ''
+ planLeaderBonus: '',
+ userXmlSelPhone: ''
},
selList: ['鐗涜吙寮�','妯寮�','鏂拌兘婧�','鍏朵粬'],
rules: {
@@ -343,8 +335,18 @@
onShow() {
// 鑾峰彇鐪佸競鍖�
this.citysData = test.citysData
+ // 鑾峰彇涓氬姟鍛樿仈绯绘柟寮�
+ this.getDetail()
},
methods: {
+ async getDetail() {
+ let res = await user.getDetail()
+ if (res.code === 200) {
+ this.baseFormData.userXmlSelPhone = res.data.mobile
+ } else if (res.code === 403) {
+ this.backLogin(res)
+ }
+ },
bindPickerChange: function(e) {
this.cstmrTypeIndex = e.detail.value
this.baseFormData.cstmrType = this.cstmrTypes[e.detail.value].id
@@ -409,20 +411,20 @@
var element
for (element of that.cstmrList) {
- if(element.value == that.baseFormData.cstmrId) {
+ if(element.value == that.baseFormData.cstmrId$) {
that.baseFormData.cstmrId = element.id
}
}
for (element of that.orderList) {
- if(element.name == that.baseFormData.orderId) {
+ if(element.name == that.baseFormData.orderId$) {
that.baseFormData.orderId = element.id
}
}
- for (element of that.userList) {
- if(element.value == that.baseFormData.userId) {
- that.baseFormData.userId = element.id
- }
- }
+ // for (element of that.userList) {
+ // if(element.value == that.baseFormData.userId) {
+ // that.baseFormData.userId = element.id
+ // }
+ // }
for(var i = 1;i <= that.selList.length; i++) {
if (that.selList[i] == that.baseFormData.select_3) {
that.baseFormData.select_3 = 'value' + i
--
Gitblit v1.9.1