Merge branch 'master' of https://git.lionquexpress.com/wuweihua/BMS
This commit is contained in:
@@ -311,6 +311,7 @@
|
||||
:show-file-list="false"
|
||||
:action="uploadFileUrl"
|
||||
:headers="uploadHeaders"
|
||||
:data="{ module: 'customer' }"
|
||||
:before-upload="handleBeforeAttachmentUpload"
|
||||
:on-success="handleAttachmentUploadSuccess"
|
||||
:on-error="handleAttachmentUploadError"
|
||||
@@ -506,12 +507,12 @@
|
||||
</el-col>
|
||||
<el-col :span="24">
|
||||
<el-form-item label="营业执照" prop="businessLicenseUrl">
|
||||
<image-upload v-model="companyForm.businessLicenseUrl" :limit="1" :size="5" />
|
||||
<image-upload v-model="companyForm.businessLicenseUrl" :limit="1" :size="5" :action="ossUploadAction" />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="24">
|
||||
<el-form-item label="其他附件" prop="attachmentIds">
|
||||
<file-upload v-model="companyForm.attachmentIds" :limit="10" :size="50" accept=".pdf,.jpg,.jpeg,.png,.doc,.docx,.xls,.xlsx,.zip,.rar" />
|
||||
<file-upload v-model="companyForm.attachmentIds" :limit="10" :size="50" accept=".pdf,.jpg,.jpeg,.png,.doc,.docx,.xls,.xlsx,.zip,.rar" :action="ossUploadAction" />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="24">
|
||||
@@ -905,7 +906,9 @@ function handleUserChange(uid, user, nameField) {
|
||||
|
||||
/* ---------------- 附件上传 ---------------- */
|
||||
const baseUrl = import.meta.env.VITE_APP_BASE_API
|
||||
const uploadFileUrl = ref(baseUrl + '/common/upload')
|
||||
const uploadFileUrl = ref(baseUrl + '/common/upload/oss')
|
||||
// OSS 上传端点(相对路径,组件内部会拼 VITE_APP_BASE_API)
|
||||
const ossUploadAction = '/common/upload/oss'
|
||||
const uploadHeaders = ref({ Authorization: 'Bearer ' + getToken() })
|
||||
const attachmentTypeOptions = ref([
|
||||
{ value: '0', label: '附件资料' },
|
||||
|
||||
@@ -726,6 +726,7 @@
|
||||
:show-file-list="false"
|
||||
:action="uploadFileUrl"
|
||||
:headers="uploadHeaders"
|
||||
:data="{ module: 'receipt' }"
|
||||
:before-upload="handleBeforeUpload"
|
||||
:on-success="handleUploadSuccess"
|
||||
:on-error="handleUploadError"
|
||||
@@ -2194,7 +2195,7 @@ watch(activeTab, (tab) => {
|
||||
})
|
||||
|
||||
/* ================= 附件上传 ================= */
|
||||
const uploadFileUrl = ref(baseUrl + "/common/upload")
|
||||
const uploadFileUrl = ref(baseUrl + "/common/upload/oss")
|
||||
const uploadHeaders = ref({ Authorization: "Bearer " + getToken() })
|
||||
const ATTACHMENT_SIZE_LIMIT = 50
|
||||
const ATTACHMENT_EXTENSIONS = ["pdf", "jpg", "jpeg", "png", "gif", "doc", "docx", "xls", "xlsx", "zip", "rar"]
|
||||
|
||||
@@ -275,6 +275,7 @@
|
||||
:show-file-list="false"
|
||||
:action="uploadFileUrl"
|
||||
:headers="uploadHeaders"
|
||||
:data="{ module: 'supplier' }"
|
||||
:before-upload="handleBeforeAttachmentUpload"
|
||||
:on-success="handleAttachmentUploadSuccess"
|
||||
:on-error="handleAttachmentUploadError"
|
||||
@@ -470,12 +471,12 @@
|
||||
</el-col>
|
||||
<el-col :span="24">
|
||||
<el-form-item label="营业执照" prop="businessLicenseUrl">
|
||||
<image-upload v-model="companyForm.businessLicenseUrl" :limit="1" :size="5" />
|
||||
<image-upload v-model="companyForm.businessLicenseUrl" :limit="1" :size="5" :action="ossUploadAction" />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="24">
|
||||
<el-form-item label="其他附件" prop="attachmentIds">
|
||||
<file-upload v-model="companyForm.attachmentIds" :limit="10" :size="50" accept=".pdf,.jpg,.jpeg,.png,.doc,.docx,.xls,.xlsx,.zip,.rar" />
|
||||
<file-upload v-model="companyForm.attachmentIds" :limit="10" :size="50" accept=".pdf,.jpg,.jpeg,.png,.doc,.docx,.xls,.xlsx,.zip,.rar" :action="ossUploadAction" />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="24">
|
||||
@@ -720,7 +721,9 @@ function handleUserChange(uid, user, nameField) {
|
||||
|
||||
/* ---------------- 附件上传 ---------------- */
|
||||
const baseUrl = import.meta.env.VITE_APP_BASE_API
|
||||
const uploadFileUrl = ref(baseUrl + '/common/upload')
|
||||
const uploadFileUrl = ref(baseUrl + '/common/upload/oss')
|
||||
// OSS 上传端点(相对路径,组件内部会拼 VITE_APP_BASE_API)
|
||||
const ossUploadAction = '/common/upload/oss'
|
||||
const uploadHeaders = ref({ Authorization: 'Bearer ' + getToken() })
|
||||
const attachmentTypeOptions = ref([
|
||||
{ value: '0', label: '附件资料' },
|
||||
|
||||
Reference in New Issue
Block a user