|
|
@ -133,9 +133,10 @@ const open = async (row) => { |
|
|
|
formLoading.value = true |
|
|
|
formLoading.value = true |
|
|
|
try { |
|
|
|
try { |
|
|
|
const data = await SalaryApi.getSalaryDetail(row.id) |
|
|
|
const data = await SalaryApi.getSalaryDetail(row.id) |
|
|
|
formData.value = { ...data, meritsRate: data.meritsRate * 100 } |
|
|
|
if (!data) { |
|
|
|
if (!formData.value) { |
|
|
|
|
|
|
|
resetForm(row.id) |
|
|
|
resetForm(row.id) |
|
|
|
|
|
|
|
} else { |
|
|
|
|
|
|
|
formData.value = { ...data } |
|
|
|
} |
|
|
|
} |
|
|
|
} finally { |
|
|
|
} finally { |
|
|
|
formLoading.value = false |
|
|
|
formLoading.value = false |
|
|
@ -179,7 +180,7 @@ const submitForm = async () => { |
|
|
|
// 提交请求 |
|
|
|
// 提交请求 |
|
|
|
formLoading.value = true |
|
|
|
formLoading.value = true |
|
|
|
try { |
|
|
|
try { |
|
|
|
const data = formData.value |
|
|
|
const data = { ...formData.value } |
|
|
|
await SalaryApi.updateSalary(data) |
|
|
|
await SalaryApi.updateSalary(data) |
|
|
|
message.success('配置成功') |
|
|
|
message.success('配置成功') |
|
|
|
dialogVisible.value = false |
|
|
|
dialogVisible.value = false |
|
|
|