更新采购申请
This commit is contained in:
@@ -35,6 +35,14 @@
|
||||
招标代理管理
|
||||
</span>
|
||||
<div class="header-actions">
|
||||
<el-button
|
||||
icon="Files"
|
||||
link
|
||||
type="primary"
|
||||
|
||||
>
|
||||
代理汇总
|
||||
</el-button>
|
||||
<el-button
|
||||
icon="FolderAdd"
|
||||
type="primary"
|
||||
@@ -170,7 +178,7 @@ const handleDelete = async (row: any) => {
|
||||
}
|
||||
|
||||
try {
|
||||
await delObj(row.id);
|
||||
await delObj({"id":row.id});
|
||||
useMessage().success('删除成功');
|
||||
getDataList();
|
||||
} catch (err: any) {
|
||||
|
||||
@@ -272,9 +272,10 @@
|
||||
<el-row :gutter="24">
|
||||
<el-col :span="12" class="mb16">
|
||||
<el-form-item label="采购形式" prop="purchaseMode">
|
||||
<el-radio-group v-model="dataForm.purchaseMode" :disabled="flowFieldDisabled('purchaseMode')">
|
||||
<el-radio-group v-model="dataForm.purchaseMode" :disabled="schoolUnifiedPurchaseFormDisabled">
|
||||
<el-radio v-for="item in purchaseModeSchoolList" :key="item.value" :label="item.value">{{ item.label }}</el-radio>
|
||||
</el-radio-group>
|
||||
<!-- <div v-if="schoolUnifiedPurchaseFormDefault != null" class="template-note mt5"><el-text type="info" size="small">根据预算金额与是否集采由系统自动选择</el-text></div> -->
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<!-- 学校统一采购时申请阶段不显示采购方式;审批环节(流程嵌入)时显示,由采购中心补充选择、其他节点只读 -->
|
||||
@@ -709,6 +710,22 @@ const isDeptPurchase = computed(() => {
|
||||
dataForm.budget && dataForm.budget < 50000);
|
||||
});
|
||||
|
||||
// 学校统一采购时采购形式默认值(不由用户选择):>=100万→政府采购('1');5万~100万且集采=否→学校自主('2');5万~100万且集采=政府集中采购→政府采购('1');5万~100万且集采=学校集中采购→学校自主('2')
|
||||
const schoolUnifiedPurchaseFormDefault = computed(() => {
|
||||
if (isDeptPurchase.value || dataForm.budget == null) return null;
|
||||
const budget = Number(dataForm.budget);
|
||||
if (budget >= 1000000) return '1'; // 政府采购
|
||||
if (budget >= 50000 && budget < 1000000) {
|
||||
if (dataForm.isCentralized === '0') return '2'; // 集采=否 → 学校自主采购
|
||||
if (dataForm.isCentralized === '1') return '1'; // 政府集中采购 → 政府采购
|
||||
if (dataForm.isCentralized === '2') return '2'; // 学校集中采购 → 学校自主采购
|
||||
}
|
||||
return null;
|
||||
});
|
||||
|
||||
// 学校统一采购时采购形式是否禁用(由规则自动选择,不由用户选择)
|
||||
const schoolUnifiedPurchaseFormDisabled = computed(() => flowFieldDisabled('purchaseMode') || (schoolUnifiedPurchaseFormDefault.value != null));
|
||||
|
||||
// 特殊情况字典 value:0否 1紧急 2单一 3进口
|
||||
const isUrgentSpecial = computed(() => dataForm.isSpecial === '1');
|
||||
|
||||
@@ -785,7 +802,7 @@ const isGoodsCategory = computed(() => {
|
||||
const isSpecialServiceCategory = computed(() => {
|
||||
const category = getCategoryInfo();
|
||||
if (!category) return false;
|
||||
return Number(category.isMallService) === 1 ;
|
||||
return Number(category.isMallService) === 1 || Number(category.isProjectService) === 1;
|
||||
});
|
||||
|
||||
// 委托采购中心方式自动判断:
|
||||
@@ -913,6 +930,15 @@ watch([() => dataForm.categoryCode, () => dataForm.budget, () => isDeptPurchase.
|
||||
}
|
||||
}, { immediate: true });
|
||||
|
||||
// 学校统一采购:采购形式由规则默认选择,随预算与集采变化自动更新
|
||||
watch([() => schoolUnifiedPurchaseFormDefault.value, () => isDeptPurchase.value], () => {
|
||||
if (isDeptPurchase.value) return;
|
||||
const def = schoolUnifiedPurchaseFormDefault.value;
|
||||
if (def != null && dataForm.purchaseMode !== def) {
|
||||
dataForm.purchaseMode = def;
|
||||
}
|
||||
}, { immediate: true });
|
||||
|
||||
// 下载模版
|
||||
const downloadTemplate = async (type: string) => {
|
||||
const templateMap: Record<string, { fileName: string, displayName: string }> = {
|
||||
|
||||
@@ -76,6 +76,14 @@
|
||||
采购申请管理
|
||||
</span>
|
||||
<div class="header-actions">
|
||||
<el-button
|
||||
icon="Files"
|
||||
link
|
||||
type="primary"
|
||||
|
||||
>
|
||||
采购申请汇总
|
||||
</el-button>
|
||||
<el-button
|
||||
icon="FolderAdd"
|
||||
type="primary"
|
||||
|
||||
@@ -46,7 +46,7 @@
|
||||
<div class="card-header">
|
||||
<span class="card-title">
|
||||
<el-icon class="title-icon"><Document /></el-icon>
|
||||
业务分管管理
|
||||
业务分管部门及人员
|
||||
</span>
|
||||
<div class="header-actions">
|
||||
<el-button
|
||||
@@ -56,15 +56,15 @@
|
||||
v-auth="'purchase_purchasingBusinessDept_add'">
|
||||
新增
|
||||
</el-button>
|
||||
<el-button
|
||||
plain
|
||||
icon="UploadFilled"
|
||||
type="primary"
|
||||
class="ml10"
|
||||
@click="excelUploadRef.show()"
|
||||
v-auth="'purchase_purchasingBusinessDept_add'">
|
||||
导入
|
||||
</el-button>
|
||||
<!-- <el-button -->
|
||||
<!-- plain -->
|
||||
<!-- icon="UploadFilled" -->
|
||||
<!-- type="primary" -->
|
||||
<!-- class="ml10" -->
|
||||
<!-- @click="excelUploadRef.show()" -->
|
||||
<!-- v-auth="'purchase_purchasingBusinessDept_add'">-->
|
||||
<!-- 导入-->
|
||||
<!-- </el-button>-->
|
||||
<el-button
|
||||
plain
|
||||
:disabled="multiple"
|
||||
@@ -134,14 +134,14 @@
|
||||
</el-table-column>
|
||||
<el-table-column label="操作" align="center" fixed="right" width="150">
|
||||
<template #default="scope">
|
||||
<el-button
|
||||
icon="Edit"
|
||||
link
|
||||
type="primary"
|
||||
v-auth="'purchase_purchasingBusinessDept_edit'"
|
||||
@click="formDialogRef.openDialog(scope.row.id)">
|
||||
编辑
|
||||
</el-button>
|
||||
<!-- <el-button -->
|
||||
<!-- icon="Edit" -->
|
||||
<!-- link -->
|
||||
<!-- type="primary" -->
|
||||
<!-- v-auth="'purchase_purchasingBusinessDept_edit'"-->
|
||||
<!-- @click="formDialogRef.openDialog(scope.row.id)">-->
|
||||
<!-- 编辑-->
|
||||
<!-- </el-button>-->
|
||||
<el-button
|
||||
icon="Delete"
|
||||
link
|
||||
|
||||
@@ -93,13 +93,13 @@
|
||||
</el-table-column>
|
||||
<el-table-column label="操作" align="center" fixed="right" width="150">
|
||||
<template #default="scope">
|
||||
<el-button
|
||||
icon="Edit"
|
||||
link
|
||||
type="primary"
|
||||
@click="formDialogRef.openDialog('edit', scope.row)">
|
||||
编辑
|
||||
</el-button>
|
||||
<!-- <el-button -->
|
||||
<!-- icon="Edit" -->
|
||||
<!-- link -->
|
||||
<!-- type="primary" -->
|
||||
<!-- @click="formDialogRef.openDialog('edit', scope.row)">-->
|
||||
<!-- 编辑-->
|
||||
<!-- </el-button>-->
|
||||
<el-button
|
||||
icon="Delete"
|
||||
link
|
||||
|
||||
Reference in New Issue
Block a user