|
@@ -396,7 +396,7 @@
|
|
|
</el-col>
|
|
|
|
|
|
<!-- 审批弹窗 -->
|
|
|
- <el-dialog title="审批" :visible.sync="centerDialogVisible" width="30%" center>
|
|
|
+ <el-dialog title="审批" :visible.sync="centerDialogVisible" width="100" center>
|
|
|
<span>{{this.activeFileName}}</span>
|
|
|
<span slot="footer" class="dialog-footer">
|
|
|
<el-button @click="check(false)">不通过</el-button>
|
|
@@ -405,7 +405,7 @@
|
|
|
</el-dialog>
|
|
|
|
|
|
<!-- 模具报废上传弹窗 -->
|
|
|
- <el-dialog title="模具报废上传" :visible.sync="centerDialog2Visible" width="30%" :before-close="clearFileRecord" center>
|
|
|
+ <el-dialog title="模具报废上传" :visible.sync="centerDialog2Visible" width="100" :before-close="clearFileRecord" center>
|
|
|
<p>申请单</p>
|
|
|
<el-upload ref="upload1" action="customize" :http-request="uploadFile" :limit="1" :auto-upload="false">
|
|
|
<el-button size="small" type="primary">上传</el-button>
|
|
@@ -420,7 +420,7 @@
|
|
|
</el-dialog>
|
|
|
|
|
|
<!-- 零件文档上传弹窗 -->
|
|
|
- <el-dialog title="零件文档上传" v-if="centerDialog4Visible" :visible.sync="centerDialog4Visible" width="30%" :before-close="clearFileRecord" center>
|
|
|
+ <el-dialog title="零件文档上传" v-if="centerDialog4Visible" :visible.sync="centerDialog4Visible" width="100" :before-close="clearFileRecord" center>
|
|
|
<p style="color:#ccc;">文件命名规则:零件编号+2D/3D 如 LJ001+2D.dwg</p>
|
|
|
<el-upload ref="upload4" action="uploadFile" :http-request="uploadPartFile" :show-file-list="true" :before-remove="beforeRemove" multiple>
|
|
|
<el-button size="small" type="primary">上传</el-button>
|
|
@@ -578,7 +578,7 @@
|
|
|
flag: 1
|
|
|
},
|
|
|
|
|
|
- files: new FormData()
|
|
|
+ files: []
|
|
|
};
|
|
|
},
|
|
|
methods: {
|
|
@@ -995,19 +995,16 @@
|
|
|
},
|
|
|
|
|
|
uploadPartFile(params) {
|
|
|
- //this.files.push(params.file)
|
|
|
- this.files.append("file", params.file);
|
|
|
+ this.files.push(params.file)
|
|
|
return false;
|
|
|
},
|
|
|
|
|
|
uploadFilePart() {
|
|
|
- // var fileObj = this.files;
|
|
|
- // var form = new FormData();
|
|
|
- // for(var i in fileObj){
|
|
|
- // console.log(fileObj[i])
|
|
|
- // form.append("file", fileObj[i]);
|
|
|
- // }
|
|
|
- var form = this.files;
|
|
|
+ var fileObj = this.files;
|
|
|
+ var form = new FormData();
|
|
|
+ for(var i in fileObj){
|
|
|
+ form.append("file", fileObj[i]);
|
|
|
+ }
|
|
|
form.append("mouldId", this.detailId);
|
|
|
this.http.uploadFile( this.port.mold.partUpload, form,
|
|
|
res => {
|
|
@@ -1016,7 +1013,8 @@
|
|
|
message: "上传成功",
|
|
|
type: "success"
|
|
|
});
|
|
|
- this.$refs.upload.clearFiles();
|
|
|
+ this.centerDialog4Visible = false;
|
|
|
+ this.$refs.upload4.clearFiles();
|
|
|
this.getPartList();
|
|
|
} else {
|
|
|
this.$message({
|
|
@@ -1026,6 +1024,7 @@
|
|
|
}
|
|
|
},
|
|
|
error => {
|
|
|
+ this.centerDialog4Visible = false;
|
|
|
this.$message({
|
|
|
message: error,
|
|
|
type: "error"
|