Jelajahi Sumber

物资调度申报样式和接口修改

zhangyihao 7 bulan lalu
induk
melakukan
e6365668f8

+ 3 - 8
src/views/comprehensiveGuarantee/materialReserves/materialsDistributionAdd.vue

@@ -44,13 +44,6 @@
                 </el-form-item>
               </template>
             </el-table-column>
-            <el-table-column label="调度目的" prop="dispatch_purpose" align="center">
-              <template #default="scope">
-                <el-form-item :prop="'detail.' + scope.$index + '.dispatch_purpose'" :rules="rules.dispatch_purpose">
-                  <el-input v-model="scope.row.dispatch_purpose" type="textarea" autosize placeholder="请输入" />
-                </el-form-item>
-              </template>
-            </el-table-column>
           </el-table>
         </el-form>
         <div class="common-dialog-footer" style="margin-top: 18px">
@@ -83,7 +76,7 @@ const props = defineProps({
 
 const { proxy } = getCurrentInstance() as ComponentInternalInstance;
 const emits = defineEmits(['close']);
-
+let dispatch_purpose = ref('');
 const formRef = ref();
 let detailData = reactive({
   dispatch_purpose: '',
@@ -120,9 +113,11 @@ const submitForm = async (formEl) => {
   if (!formEl) return;
   await formEl.validate((valid) => {
     if (valid) {
+      detailData.dispatch_purpose = dispatch_purpose.value;
       createDispatch(detailData).then(() => {
         proxy.$modal.msgSuccess('新增成功');
         emits('close', true);
+        emits('refresh');
       });
     } else {
       nextTick(() => {