| | |
| | | <el-upload :action="action" :auto-upload="true" |
| | | :data="{ orderId: dataVisibleIndex === 0 ? filesLookInfo.enterOrderId : filesLookInfo.quarterOrderId }" |
| | | :on-success="handleSuccessUp" :show-file-list="false" |
| | | accept='.jpg,.jpeg,.png,.gif,.doc,.docx,.xls,.xlsx,.ppt,.pptx,.pdf,.zip,.rar' :headers="headers" |
| | | accept='.jpg,.jpeg,.png,.gif,.doc,.docx,.xls,.xlsx,.ppt,.pptx,.pdf,.zip,.rar' :headers="uploadHeader" |
| | | :before-upload="beforeUpload" style="width: 80px !important;" :on-error="onError" ref='upload'> |
| | | <el-button size="small" type="primary" style="height: 38px">附件上传</el-button> |
| | | </el-upload> |
| | |
| | | import file from "@/utils/file"; |
| | | import limsTable from "@/components/Table/lims-table.vue"; |
| | | import { delfile, downFile, getFileList } from "@/api/business/rawMaterialOrder"; |
| | | import { getToken } from "@/utils/auth"; |
| | | export default { |
| | | name: "filesLookVisible", |
| | | // import 引入的组件需要注入到对象中才能使用 |
| | |
| | | this.upLoading = false; |
| | | if (response.code == 200) { |
| | | this.$message.success('上传成功'); |
| | | this.$refs.fileList.selectList() |
| | | this.getFileList() |
| | | } |
| | | }, |
| | | beforeUpload(file) { |
| | |
| | | } |
| | | }, |
| | | computed: { |
| | | headers() { |
| | | return { |
| | | 'Authorization': "Bearer " + getToken() |
| | | } |
| | | }, |
| | | action() { |
| | | return this.javaApi + '/insOrderPlan/uploadFile' |
| | | } |