Ver código fonte

调拨单页面优化;

001295 1 ano atrás
pai
commit
ff0e62df04
1 arquivos alterados com 97 adições e 97 exclusões
  1. 97 97
      src/views/purchase/transferOrder/add.vue

+ 97 - 97
src/views/purchase/transferOrder/add.vue

@@ -129,7 +129,7 @@
             </el-form-item>
           </el-col>
         </el-row>
-        <el-row :span="1.5">
+        <el-row :gutter="10">
           <el-col :span="1.5">
             <el-form-item label="调出库存组织" prop="deliveryInventoryOrg">
               <el-select clearable :disabled="sonDisable" size="mini" v-model="basicForm.deliveryInventoryOrg" 
@@ -161,7 +161,7 @@
               <el-select clearable :disabled="sonDisable || isOrg"
                 size="mini"
                 v-model="basicForm.deliveryDept"
-                @focus="chooseRefer('DEPT_PARAM', true, '调出部门', basicForm.deliveryInventoryOrg)"
+                @focus="chooseRefer('DEPT_PARAM', true, '调出部门', '','','',{drpOrg:basicForm.deliveryInventoryOrg})"
                 style="width: 200px"
               >
                 <el-option v-for="item in deptOptions" :key="item.id" :label="item.name" :value="item.id"/>
@@ -324,6 +324,96 @@
                 />
                 <el-table-column
                   show-overflow-tooltip
+                  label="数量"
+                  align="center"
+                  prop="qty"
+                  width="150px"
+                  :render-header="addRedStar"
+                >
+                  <template slot-scope="scope">
+
+                    <el-form-item class="hang" :prop="'materialInfo.' + scope.$index + '.qty'" :show-message="false" :rules="{ required: true, message: '请填写数量', trigger: 'blur' }">
+                      <el-input
+                        type="number"
+                        min="0"
+                        :disabled="sonDisable"
+                        clearable
+                        size="mini"
+                        v-model="scope.row.qty"
+                        @input="getSL(scope)"
+                        @change="changeQty()"
+                      />
+                    </el-form-item>
+                  </template>
+                </el-table-column>
+                <el-table-column
+                  show-overflow-tooltip
+                  label="调入部门"
+                  align="center"
+                  prop="storageDeptName"
+                  width="220px"
+                  :render-header="addRedStar"
+                >
+                  <template slot-scope="scope">
+                    <el-form-item class="hang" :prop="'materialInfo.' + scope.$index + '.storageDeptName'" :show-message="false" :rules="{ required: true, message: '请填写调入部门', trigger: 'blur' }">
+                      <el-input
+                        clearable
+                        :disabled="sonDisable || isOrg"
+                        size="mini"
+                        v-model="scope.row.storageDeptName"
+                        @clear="cleanMx(scope.$index, '调入部门')"
+                        @focus="
+                          chooseMxBM(
+                            scope.$index,
+                            'DEPT_PARAM',
+                            true,
+                            '调入部门',{drpOrg:basicForm.deliveryInventoryOrg}
+                          )
+                        "
+                      >
+                        <el-button
+                          size="mini"
+                          :disabled="sonDisable || isOrg"
+                          slot="append"
+                          icon="el-icon-more"
+                          @click="
+                            chooseMxBM(
+                              scope.$index,
+                              'DEPT_PARAM',
+                              true,
+                              '调入部门',{drpOrg:basicForm.deliveryInventoryOrg}
+                            )
+                          "
+                        ></el-button>
+                      </el-input>
+                    </el-form-item>
+                  </template>
+                </el-table-column>
+                <el-table-column
+                  show-overflow-tooltip
+                  label="调拨日期"
+                  align="center"
+                  prop="allotDate"
+                  width="230px"
+                  :render-header="addRedStar"
+                >
+                  <template slot-scope="scope">
+                    <el-form-item class="hang" :prop="'materialInfo.' + scope.$index + '.allotDate'" :show-message="false" :rules="{ required: true, message: '请填写调拨日期', trigger: 'blur' }">
+                      <el-date-picker
+                        ref="findDate"
+                        v-model="scope.row.allotDate"
+                        :disabled="sonDisable"
+                        type="date"
+                        size="mini"
+                        :picker-options="pickerOptionsEnd"
+                        value-format="yyyy-MM-dd"
+                      >
+                      </el-date-picker>
+                    </el-form-item>
+                  </template>
+                </el-table-column>
+                <el-table-column
+                  show-overflow-tooltip
                   label="调拨出库单号"
                   align="center"
                   prop="deliveryCode"
@@ -368,30 +458,7 @@
                   prop="unitName"
                 />
                 <!-- <el-table-column show-overflow-tooltip label="调出仓库" align="center" prop="deliveryWarehouseName"/> -->
-                <el-table-column
-                  show-overflow-tooltip
-                  label="数量"
-                  align="center"
-                  prop="qty"
-                  width="150px"
-                  :render-header="addRedStar"
-                >
-                  <template slot-scope="scope">
-
-                    <el-form-item class="hang" :prop="'materialInfo.' + scope.$index + '.qty'" :show-message="false" :rules="{ required: true, message: '请填写数量', trigger: 'blur' }">
-                      <el-input
-                        type="number"
-                        min="0"
-                        :disabled="sonDisable"
-                        clearable
-                        size="mini"
-                        v-model="scope.row.qty"
-                        @input="getSL(scope)"
-                        @change="changeQty()"
-                      />
-                    </el-form-item>
-                  </template>
-                </el-table-column>
+                
                 <el-table-column
                   show-overflow-tooltip
                   label="主单位"
@@ -477,51 +544,6 @@
                 </el-table-column>
                 <el-table-column
                   show-overflow-tooltip
-                  label="调入部门"
-                  align="center"
-                  prop="storageDeptName"
-                  width="220px"
-                  :render-header="addRedStar"
-                >
-                  <template slot-scope="scope">
-                    <el-form-item class="hang" :prop="'materialInfo.' + scope.$index + '.storageDeptName'" :show-message="false" :rules="{ required: true, message: '请填写调入部门', trigger: 'blur' }">
-                      <el-input
-                        clearable
-                        :disabled="sonDisable || isOrg"
-                        size="mini"
-                        v-model="scope.row.storageDeptName"
-                        @clear="cleanMx(scope.$index, '调入部门')"
-                        @focus="
-                          chooseMxBM(
-                            scope.$index,
-                            'DEPT_PARAM',
-                            true,
-                            '调入部门',
-                            basicForm.storageInventoryOrg
-                          )
-                        "
-                      >
-                        <el-button
-                          size="mini"
-                          :disabled="sonDisable || isOrg"
-                          slot="append"
-                          icon="el-icon-more"
-                          @click="
-                            chooseMxBM(
-                              scope.$index,
-                              'DEPT_PARAM',
-                              true,
-                              '调入部门',
-                              basicForm.storageInventoryOrg
-                            )
-                          "
-                        ></el-button>
-                      </el-input>
-                    </el-form-item>
-                  </template>
-                </el-table-column>
-                <el-table-column
-                  show-overflow-tooltip
                   label="调入货位"
                   align="center"
                   prop="storageAllocationName"
@@ -624,29 +646,6 @@
                 />
                 <el-table-column
                   show-overflow-tooltip
-                  label="调拨日期"
-                  align="center"
-                  prop="allotDate"
-                  width="230px"
-                  :render-header="addRedStar"
-                >
-                  <template slot-scope="scope">
-                    <el-form-item class="hang" :prop="'materialInfo.' + scope.$index + '.allotDate'" :show-message="false" :rules="{ required: true, message: '请填写调拨日期', trigger: 'blur' }">
-                      <el-date-picker
-                        ref="findDate"
-                        v-model="scope.row.allotDate"
-                        :disabled="sonDisable"
-                        type="date"
-                        size="mini"
-                        :picker-options="pickerOptionsEnd"
-                        value-format="yyyy-MM-dd"
-                      >
-                      </el-date-picker>
-                    </el-form-item>
-                  </template>
-                </el-table-column>
-                <el-table-column
-                  show-overflow-tooltip
                   label="批准文号"
                   align="center"
                   prop="ratifyCode"
@@ -1929,13 +1928,14 @@ export default {
       }
     },
 
-    chooseRefer(type, isPage, title, pkOrg, isDirectStore, gubFlag) {
+    chooseRefer(type, isPage, title, pkOrg, isDirectStore, gubFlag,parame) {
       this.referCondition.type = type;
       this.referCondition.isPage = isPage;
       this.referCondition.title = title;
       this.referCondition.pkOrg = pkOrg;
       this.referCondition.isDirectStore = isDirectStore;
       this.referCondition.gubFlag = gubFlag;
+      this.referCondition.parame = parame;
       this.$refs.refer.init(this.referCondition);
     },
     selectionsToInput(selection) {
@@ -2149,12 +2149,12 @@ export default {
       this.$refs.refer.init(this.referCondition);
     },
     // 明细行选择调入部门
-    chooseMxBM(index, type, isPage, title, pkOrg) {
+    chooseMxBM(index, type, isPage, title,parame) {
       this.tableIndex = index;
       this.referCondition.type = type;
       this.referCondition.isPage = isPage;
       this.referCondition.title = title;
-      this.referCondition.pkOrg = pkOrg;
+      this.referCondition.parame = parame;
       this.$refs.refer.init(this.referCondition);
     },
     // 选择框彻底清空