|
@@ -557,7 +557,7 @@
|
|
|
</template>
|
|
|
|
|
|
<script>
|
|
|
-import { submitApply, listApply, getApply, delApply, addApply, updateApply, exportApply, importTemplate} from "@/api/production/apply";
|
|
|
+import { saveAndSubmitApply, submitApply, listApply, getApply, delApply, addApply, updateApply, exportApply, importTemplate} from "@/api/production/apply";
|
|
|
import { addSai } from "@/api/production/sai";
|
|
|
import { treeselect, listDept } from "@/api/system/dept";
|
|
|
import { getToken } from "@/utils/auth";
|
|
@@ -1304,7 +1304,26 @@ export default {
|
|
|
});
|
|
|
},
|
|
|
/** 新增/修改提交按钮 */
|
|
|
- handleSaveAndSubmit() {},
|
|
|
+ handleSaveAndSubmit() {
|
|
|
+ this.form.files = []
|
|
|
+ if (this.fileList.length > 0) {
|
|
|
+ for (let i = 0; i < this.fileList.length; i++) {
|
|
|
+ let obj = {}
|
|
|
+ obj.fileName = this.fileList[i].name
|
|
|
+ obj.fileUrl = this.fileList[i].response.msg
|
|
|
+ this.form.files.push(obj)
|
|
|
+ }
|
|
|
+ }
|
|
|
+ this.$refs["form"].validate(valid => {
|
|
|
+ if (valid) {
|
|
|
+ saveAndSubmitApply(this.form).then(response => {
|
|
|
+ this.msgSuccess("提交成功");
|
|
|
+ this.open = false;
|
|
|
+ this.getList();
|
|
|
+ });
|
|
|
+ }
|
|
|
+ });
|
|
|
+ },
|
|
|
/** 统计至SAI检查台账提交按钮 */
|
|
|
submitSaiForm() {
|
|
|
for (let i = 0; i < this.saiList.length; i++) {
|