yusheng il y a 6 mois
Parent
commit
0f0db1775a

+ 10 - 7
pages/salesServiceManagement/demandList/add.vue

@@ -6,8 +6,8 @@
 		<u-subsection :list="list" :current="current" @change="sectionChange"></u-subsection>
 		<u-cell-group v-show="current == 0">
 			<!-- 售后对象 -->
-			<u-cell title="需求编码" arrow-direction="down" >
-				<view slot="value" style="display: flex;align-items: center;width: 100%;" >
+			<u-cell title="需求编码" arrow-direction="down">
+				<view slot="value" style="display: flex;align-items: center;width: 100%;">
 					<u--input disabled style="flex:1" border="surround" v-model="form.code">
 					</u--input>
 				</view>
@@ -92,7 +92,7 @@
 					:localdata="pie_car_type">
 				</uni-data-picker>
 				<u--input v-else slot="value" style="flex:1" placeholder="请输入" disabled border="surround"
-					:value="form.pieCarType==1?'是':'否'">
+					:value="getTetx(form.pieCarType)">
 
 				</u--input>
 			</u-cell>
@@ -115,8 +115,8 @@
 				</u--input>
 			</u-cell>
 			<u-cell title="涉及事业部门" arrow-direction="down" class="required-mark-new" @click.native="salesDeptShow">
-				<u--input slot="value" :disabled="!isDisable"  style="pointer-events: none;"   placeholder="请选择" border="surround"
-					v-model="form.involveDeptName" ></u--input>
+				<u--input slot="value" :disabled="!isDisable" style="pointer-events: none;" placeholder="请选择"
+					border="surround" v-model="form.involveDeptName"></u--input>
 			</u-cell>
 			<u-cell title="备注说明" arrow-direction="down">
 				<u--textarea border="surround" :disabled="!isDisable" placeholder=" " slot="value" v-model="form.remark"
@@ -305,7 +305,7 @@
 					el.categoryCode = el.code;
 					el.categoryName = el.name;
 					el.categoryModel = el.modelType;
-					el.productCategoryName=el.categoryLevelPath
+					el.productCategoryName = el.categoryLevelPath
 					return el;
 				});
 				let params = {
@@ -336,6 +336,9 @@
 
 		},
 		methods: {
+			getTetx(val) {
+				return this.pie_car_type.find(data => data.value == val)?.text
+			},
 			//选择部门
 			salesDeptShow() {
 				if (!this.isDisable) {
@@ -502,7 +505,7 @@
 						})
 						return
 					}
-					
+
 					if (!data.orderCode && this.form.associationType !== '3') {
 						const message = this.form.associationType === "1" ? "请选择发货单" : "请选择销售订单"
 						this.$refs.uToast.show({

+ 11 - 4
pages/salesServiceManagement/demandList/components/itemSelect.vue

@@ -98,6 +98,8 @@
 					(productItem, productIndex) => {
 						return {
 							...productItem,
+							productCategoryName: productItem.categoryLevelPath,
+							productBrand: productItem.brandNum,
 							outInDetailRecordRequestList: productItem.outInDetailRecordRequestList.map((
 								packingItem) => {
 								return {
@@ -118,11 +120,16 @@
 				// 获取包装维度数据
 				const arr = [];
 				for (const key in productList) {
-					for (const k in productList[key].outInDetailRecordRequestList) {
-						arr.push({
-							...productList[key].outInDetailRecordRequestList[k]
-						});
+					if (productList[key].outInDetailRecordRequestList.length) {
+						for (const k in productList[key].outInDetailRecordRequestList) {
+							arr.push({
+								...productList[key].outInDetailRecordRequestList[k]
+							});
+						}
+					} else {
+						arr.push(productList[key])
 					}
+
 				}
 				this.listData = arr;
 			},