bug修改
This commit is contained in:
parent
2ff57d9798
commit
a48cd552f6
@ -169,7 +169,7 @@
|
||||
</template>
|
||||
|
||||
<script setup name="Trans_group">
|
||||
import { listTrans_group, getTrans_group, delTrans_group, addTrans_group, updateTrans_group } from '@/api/produce/manage_sheep/trans_group/trans_group'
|
||||
import { listTrans_group, getTrans_group, delTrans_group, addTrans_group, updateTrans_group } from '@/api/produce/manage_sheep/trans_group'
|
||||
import { listSheepfold_management as listSheepfold } from '@/api/fileManagement/sheepfold_management'
|
||||
import request from '@/utils/request'
|
||||
|
||||
|
@ -167,7 +167,7 @@
|
||||
</template>
|
||||
|
||||
<script setup name="Transition_info">
|
||||
import { listTransition_info, getTransition_info, delTransition_info, addTransition_info, updateTransition_info } from "@/api/produce/manage_sheep/transition_info/transition_info"
|
||||
import { listTransition_info, getTransition_info, delTransition_info, addTransition_info, updateTransition_info } from "@/api/produce/manage_sheep/transition_info"
|
||||
import request from '@/utils/request'
|
||||
|
||||
const { proxy } = getCurrentInstance()
|
||||
@ -310,87 +310,6 @@ function handleDelete(row) {
|
||||
proxy.$modal.msgSuccess("删除成功")
|
||||
})
|
||||
}
|
||||
function handleExport() {
|
||||
proxy.download('/produce/manage_sheep/transition_info/export',
|
||||
{ ...queryParams.value },
|
||||
`transition_info_${new Date().getTime()}.xlsx`)
|
||||
}
|
||||
|
||||
/* -------------------- 审批 -------------------- */
|
||||
function handleApprove(row) {
|
||||
approveForm.value = { ...row }
|
||||
approveDialog.value = true
|
||||
}
|
||||
function getTransTypeLabel(val) {
|
||||
const hit = trans_type.value.find(item => Number(item.value) === val)
|
||||
return hit ? hit.label : val
|
||||
}
|
||||
function handleApproveAgree() {
|
||||
approveForm.value.status = 1
|
||||
updateTransition_info(approveForm.value).then(() => {
|
||||
approveDialog.value = false
|
||||
proxy.$modal.msgSuccess("审批成功,状态已更新为同意")
|
||||
getList()
|
||||
})
|
||||
}
|
||||
function handleApproveReject() {
|
||||
approveForm.value.status = 2
|
||||
updateTransition_info(approveForm.value).then(() => {
|
||||
approveDialog.value = false
|
||||
proxy.$modal.msgSuccess("审批成功,状态已更新为驳回")
|
||||
getList()
|
||||
})
|
||||
}
|
||||
|
||||
/* -------------------- 下拉 -------------------- */
|
||||
function getVarietyOptions() {
|
||||
request({
|
||||
url: '/base/variety/list',
|
||||
method: 'get',
|
||||
params: { pageNum: 1, pageSize: 9999 }
|
||||
}).then(res => { varietyOptions.value = res.rows || [] })
|
||||
}
|
||||
|
||||
/** 导出按钮操作 */
|
||||
function handleExport() {
|
||||
proxy.download('/produce/manage_sheep/transition_info/export', {
|
||||
...queryParams.value
|
||||
}, `transition_info_${new Date().getTime()}.xlsx`)
|
||||
}
|
||||
// 审批记录的对话框
|
||||
const approveDialog = ref(false);
|
||||
const approveForm = ref({});
|
||||
|
||||
// 审批按钮操作
|
||||
function handleApprove(row) {
|
||||
// 打开审批对话框
|
||||
approveForm.value = { ...row };
|
||||
approveDialog.value = true;
|
||||
}
|
||||
|
||||
// 同意审批
|
||||
function handleApproveAgree() {
|
||||
approveForm.value.status = 1; // 状态设置为同意
|
||||
updateTransition_info(approveForm.value).then(() => {
|
||||
approveDialog.value = false;
|
||||
proxy.$modal.msgSuccess("审批成功,状态已更新为同意");
|
||||
getList();
|
||||
}).catch((error) => {
|
||||
proxy.$modal.msgError(`审批失败:${error}`);
|
||||
});
|
||||
}
|
||||
|
||||
// 驳回审批
|
||||
function handleApproveReject() {
|
||||
approveForm.value.status = 2; // 状态设置为驳回
|
||||
updateTransition_info(approveForm.value).then(() => {
|
||||
approveDialog.value = false;
|
||||
proxy.$modal.msgSuccess("审批成功,状态已更新为驳回");
|
||||
getList();
|
||||
}).catch((error) => {
|
||||
proxy.$modal.msgError(`审批失败:${error}`);
|
||||
});
|
||||
}
|
||||
|
||||
getList()
|
||||
|
||||
|
@ -111,7 +111,7 @@
|
||||
</template>
|
||||
|
||||
<script setup name="FixHoof">
|
||||
import { listFixHoof, getFixHoof, delFixHoof, addFixHoof, updateFixHoof, checkSheepByManageTags, getVarietyOptions } from '@/api/produce/other/fixHoof/fixHoof'
|
||||
import { listFixHoof, getFixHoof, delFixHoof, addFixHoof, updateFixHoof, checkSheepByManageTags, getVarietyOptions } from '@/api/produce/other/fixHoof'
|
||||
import { listSheepfold_management as listSheepfold } from '@/api/fileManagement/sheepfold_management'
|
||||
// import request from '@/utils/request'
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user