linwenxin vor 4 Monaten
Ursprung
Commit
65f617b1ff

+ 34 - 3
src/views/auxiliaryFittings/salesManagement/components/auxiliarySalesOrderDetail.vue

@@ -35,7 +35,7 @@
                 <el-input type="text" :value="formData.salesId" disabled></el-input>
               </el-form-item>
             </el-col>
-            <el-col :span="16">
+            <el-col :span="8">
               <el-form-item label="网点名称" prop="websitId">
                 <el-select
                   clearable
@@ -58,6 +58,28 @@
               </el-form-item>
             </el-col>
             <el-col :span="8">
+              <el-form-item label="师傅所属网点" prop="websitId">
+                <el-select
+                  clearable
+                  filterable
+                  v-model="formData.websit2"
+                  :disabled="formData.flag != 'SAVE' && formType != 0"
+                  value-key="websitId"
+                  @change="changeWebsit2"
+                  placeholder="请选择"
+                  style="width: 100%"
+                >
+                  <el-option
+                    v-for="item in websitList2"
+                    :key="item.websitId"
+                    :label="`(${item.websitId})${item.name}`"
+                    :value="item"
+                  >
+                  </el-option>
+                </el-select>
+              </el-form-item>
+            </el-col>
+            <el-col :span="8">
               <el-form-item label="购买方" :required="true" style="padding-bottom: 1px">
                 <el-radio-group
                   v-model="formData.buyPeople"
@@ -666,6 +688,7 @@ export default {
     return {
       dataList: [],
       websitList: [],
+      websitList2: [],
       workerList: [],
       mainList: [],
       projectList: [],
@@ -675,6 +698,7 @@ export default {
       payCodeUrl: '',
       formData: {
         websit: {},
+        websit2: {},
         websitId: '',
         websitName: '',
         file_url: [],
@@ -818,6 +842,9 @@ export default {
       getWebsit({ type: 'C' }).then(res => {
         this.websitList = res.data
       })
+      getWebsit({ type: 'C', isAll: true }).then(res => {
+        this.websitList2 = res.data
+      })
     },
     changeWebsit(e) {
       this.dataList = []
@@ -825,10 +852,14 @@ export default {
       this.formData.websitName = e.name
       this.formData.storageName = ''
       this.formData.storageId = ''
-      this.getWorker()
       this.getCategory(e.websitId, this.formData.storageId)
       this.getWarehouseList(e.websitId)
     },
+    changeWebsit2(e) {
+      this.formData.workerWebsitId = e.websitId
+      this.formData.workerWebsitName = e.name
+      this.getWorker()
+    },
     changeStorage(e) {
       if (!this.formData.isImport && this.formData.orderSource == 'SELF') {
         this.dataList = []
@@ -917,7 +948,7 @@ export default {
       getWorker({
         pageNum: 1,
         pageSize: -1,
-        params: this.formType == 2 ? [] : [{ param: 'b.websit_id', compare: '=', value: this.formData.websitId }]
+        params: this.formType == 2 ? [] : [{ param: 'b.websit_id', compare: '=', value: this.formData.workerWebsitId }]
       }).then(res => {
         this.workerList = res.data.records
       })