bug 修复

This commit is contained in:
BianLzhaoMin 2025-09-06 15:34:24 +08:00
parent 8d011e88c8
commit 271478037b
11 changed files with 101 additions and 60 deletions

View File

@ -153,6 +153,12 @@ export default {
return false
}
//
if (file.name.length > 30) {
this.$modal.msgError('文件名称不能超过30个字符')
return false
}
this.$modal.loading('图片正在上传,请稍候...')
// #
const newFileName = file.name.replace(/#/g, '@')
@ -200,6 +206,16 @@ export default {
return false
}
//
if (file.name.length > 30) {
this.$modal.msgError('文件名称不能超过30个字符')
this.$emit(
'update:fileList',
fileList.filter((item) => item.uid !== file.uid),
)
return false
}
// // #
// const newFileName = file.name.replace(/#/g, '@')
// const newFile = new File([file], newFileName, { type: file.type })

View File

@ -169,6 +169,8 @@ export default {
return false
}
console.log(file.name, 'file.name')
this.$modal.loading('图片正在上传,请稍候...')
// #
const newFileName = file.name.replace(/#/g, '@')
@ -215,6 +217,16 @@ export default {
)
return false
}
//
if (file.name.length > 30) {
this.$modal.msgError('文件名称不能超过30个字符')
this.$emit(
'update:fileList',
fileList.filter((item) => item.uid !== file.uid),
)
return false
}
this.$emit('update:fileList', fileList)
this.$emit('onUploadChange', fileList)
},

View File

@ -95,6 +95,7 @@
size="mini"
type="danger"
icon="el-icon-delete"
v-if="!data.proId"
v-hasPermi="['att:machine:delete']"
@click="onHandleDeleteSubBaseInfo(data)"
>

View File

@ -261,14 +261,17 @@ export default {
},
//
onHandleConfirmFinish: debounce(async () => {
try {
await this.$refs.addApplyFormRef.onHandleConfirmFinishFun()
this.handleCloseDialogOuter()
this.$refs.cardReplacementApplyTableRef.getTableList()
} catch (error) {
// console.log('', error)
onHandleConfirmFinish: debounce(function () {
const handleAsync = async () => {
try {
await this.$refs.addApplyFormRef.onHandleConfirmFinishFun()
this.handleCloseDialogOuter()
this.$refs.cardReplacementApplyTableRef.getTableList()
} catch (error) {
// console.log('', error)
}
}
handleAsync()
}, 1500),
//

View File

@ -1352,10 +1352,10 @@ export default {
//
onChangeProId(val) {
this.keyInfoForm.teamId = ''
this.keyInfoForm.subId = ''
if (!val) {
this.keyInfoForm.proName = ''
this.keyInfoForm.subId = ''
this.keyInfoForm.teamId = ''
this.subSelectList = []
this.teamSelectList = []
return
@ -1378,9 +1378,9 @@ export default {
},
//
onChangeSubId(val) {
this.keyInfoForm.teamId = ''
if (!val) {
this.keyInfoForm.subName = ''
this.keyInfoForm.teamId = ''
this.keyInfoForm.subId = ''
this.teamSelectList = []
return
}

View File

@ -13,13 +13,13 @@ export const formLabel = [
f_width: '180px',
isShow: false, // 是否展示label
},
{
f_label: '联系方式',
f_model: 'phone',
f_type: 'ipt',
f_width: '180px',
isShow: false, // 是否展示label
},
// {
// f_label: '联系方式',
// f_model: 'phone',
// f_type: 'ipt',
// f_width: '180px',
// isShow: false, // 是否展示label
// },
{
f_label: '工程',
f_model: 'proId',
@ -28,14 +28,14 @@ export const formLabel = [
isShow: false, // 是否展示label
f_selList: [], // 工程列表
},
{
f_label: '工种',
f_model: 'postId',
f_type: 'sel',
f_width: '180px',
isShow: false, // 是否展示label
f_selList: [], // 工种列表
},
// {
// f_label: '工种',
// f_model: 'postId',
// f_type: 'sel',
// f_width: '180px',
// isShow: false, // 是否展示label
// f_selList: [], // 工种列表
// },
{
f_label: '分包',
f_model: 'subId',

View File

@ -244,14 +244,17 @@ export default {
},
//
onHandleConfirmAddOrEdit: debounce(async () => {
try {
await this.$refs.addOrEditFormContentRef.onHandleConfirmAddOrEditFun()
this.$refs.personEntryTableRef.getTableList()
this.handleCloseDialogOuter()
} catch (error) {
// console.log('', error)
onHandleConfirmAddOrEdit: debounce(function () {
const handleAsync = async () => {
try {
await this.$refs.addOrEditFormContentRef.onHandleConfirmAddOrEditFun()
this.$refs.personEntryTableRef.getTableList()
this.handleCloseDialogOuter()
} catch (error) {
// console.log('', error)
}
}
handleAsync()
}, 1000),
//

View File

@ -233,17 +233,24 @@ export default {
},
//
onHandleConfirmAddOrEdit: debounce(async () => {
try {
const res =
await this.$refs.uploadContractContentRef.onHandleConfirmAddOrEditFun()
if (res !== 'isClose') {
this.$refs.contractWitnessTableRef.getTableList()
onHandleConfirmAddOrEdit: debounce(function () {
//
const handleAsync = async () => {
try {
const res =
await this.$refs.uploadContractContentRef.onHandleConfirmAddOrEditFun()
if (res !== 'isClose') {
this.$refs.contractWitnessTableRef.getTableList()
}
this.handleCloseDialogOuter()
} catch (error) {
//
console.error('表单提交失败', error)
}
this.handleCloseDialogOuter()
} catch (error) {
// console.log('', error)
}
//
handleAsync()
}, 1000),
//

View File

@ -190,18 +190,21 @@ export default {
},
//
onHandleConfirmAddOrEdit: debounce(async () => {
try {
const res =
await this.$refs.uploadContractContentRef.onHandleConfirmAddOrEditFun()
onHandleConfirmAddOrEdit: debounce(function () {
const handleAsync = async () => {
try {
const res =
await this.$refs.uploadContractContentRef.onHandleConfirmAddOrEditFun()
if (res !== 'isClose') {
this.$refs.wageCardWitnessTableRef.getTableList()
if (res !== 'isClose') {
this.$refs.wageCardWitnessTableRef.getTableList()
}
this.handleCloseDialogOuter()
} catch (error) {
// console.log('', error)
}
this.handleCloseDialogOuter()
} catch (error) {
// console.log('', error)
}
handleAsync()
}, 1000),
//

View File

@ -152,7 +152,7 @@ export default {
sex: this.sex,
isAtt: this.isAtt,
postId: this.postId,
mainProId: this.selectCompany,
subComId: this.selectCompany,
},
commonSlots: [
'onSiteCount',

View File

@ -2,17 +2,13 @@
<!-- 固定临时人员 -->
<div class="person-ratio">
<div class="person-ratio-row">
<div>
<div @click="onHandleOpenDialog('fixed')">
<svg-icon icon-class="fixed-person" style="font-size: 32px" />
<span @click="onHandleOpenDialog('fixed')">
{{ personAttendanceData.einNum }}</span
>
<span> {{ personAttendanceData.einNum }}</span>
</div>
<div>
<div @click="onHandleOpenDialog('temp')">
<svg-icon icon-class="temp-person" style="font-size: 26px" />
<span @click="onHandleOpenDialog('temp')">
{{ personAttendanceData.tempNum }}</span
>
<span> {{ personAttendanceData.tempNum }}</span>
</div>
</div>