diff --git a/src/views/purchase/purchasingrequisition/add.vue b/src/views/purchase/purchasingrequisition/add.vue
index 8d8bb5c..47239a0 100644
--- a/src/views/purchase/purchasingrequisition/add.vue
+++ b/src/views/purchase/purchasingrequisition/add.vue
@@ -11,9 +11,9 @@
-
-
+
+
{{ item.label }}
@@ -841,7 +841,7 @@ upload-file-url="/purchase/purchasingfiles/upload"
取消
- 暂存
+ 暂存
@@ -963,6 +963,7 @@ const dataForm = reactive({
isSpecial: '',
hasAssets: '0',
purchaseMode: '',
+ purchaseSchool:'',
purchaseType: '',
purchaseTypeUnion: '',
purchaseChannel: '',
@@ -1199,8 +1200,8 @@ const isPurchaseTypeUnionRequired = computed(() => {
return false;
});
-// 学校统一采购 - 采购形式是否必填
-const isPurchaseModeRequired = computed(() => {
+// 学校统一采购 - 组织采购形式是否必填
+const isPurchaseSchoolRequired = computed(() => {
// 审核阶段:采购中心必填
if (isFlowEmbed.value && isPurchaseCenter.value) {
return true;
@@ -1231,20 +1232,7 @@ const showPurchaseDetailBlocks = computed(() => {
return !!isViewMode.value || !!isFlowEmbed.value || !!dataForm.id || isPurchaseTypeDetermined.value;
});
-// 学校统一采购时采购形式默认值(不由用户选择):>=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 >= BUDGET_GOV_PURCHASE_THRESHOLD.value) return '1'; // 政府采购
- if (budget >= BUDGET_DEPT_PURCHASE_THRESHOLD.value && budget < BUDGET_GOV_PURCHASE_THRESHOLD.value) {
- if (dataForm.isCentralized === '0') return '2'; // 集采=否 → 学校自主采购
- if (dataForm.isCentralized === '1') return '1'; // 政府集中采购 → 政府采购
- if (dataForm.isCentralized === '2') return '2'; // 学校集中采购 → 学校自主采购
- }
- return null;
-});
-
-// 学校统一采购时采购形式是否禁用
+// 学校统一采购时组织采购形式是否禁用
// 申请阶段:始终可选(根据默认值自动选中后,允许用户自行修改)
// 流程嵌入:采购中心节点可编辑,其他节点只读
const schoolUnifiedPurchaseFormDisabled = computed(() => {
@@ -1587,15 +1575,11 @@ watch(
{ immediate: true }
);
-// 学校统一采购:采购形式由规则默认选择,随预算与集采变化自动更新
+// 学校统一采购:组织采购形式由规则默认选择,随预算与集采变化自动更新
watch(
- [() => schoolUnifiedPurchaseFormDefault.value, () => isDeptPurchase.value],
+ [ () => isDeptPurchase.value],
() => {
if (isDeptPurchase.value) return;
- const def = schoolUnifiedPurchaseFormDefault.value;
- if (def != null && dataForm.purchaseMode !== def) {
- dataForm.purchaseMode = def;
- }
},
{ immediate: true }
);
@@ -1745,12 +1729,12 @@ const dataRules = reactive({
},
],
// 学校统一采购 + 采购中心审核:采购形式必填
- purchaseMode: [
+ purchaseSchool: [
{
validator: (_rule: any, value: string, callback: (e?: Error) => void) => {
if (!isDeptPurchase.value && isFlowEmbed.value && isPurchaseCenter.value) {
if (!value || String(value).trim() === '') {
- callback(new Error('请选择采购形式'));
+ callback(new Error('请选择组织采购形式'));
return;
}
}
@@ -1877,6 +1861,7 @@ async function loadDetail(applyId: string | number) {
isCentralized: detail.isCentralized != null ? String(detail.isCentralized) : '',
isSpecial: detail.isSpecial != null ? String(detail.isSpecial) : '',
purchaseMode: detail.purchaseMode != null ? String(detail.purchaseMode) : '',
+ purchaseSchool: detail.purchaseSchool != null ? String(detail.purchaseSchool) : '',
purchaseType:
detail.purchaseType === DEPT_PURCHASE_TYPE.ENTRUST_CENTER
? ''
diff --git a/src/views/purchase/purchasingrequisition/index.vue b/src/views/purchase/purchasingrequisition/index.vue
index d8dd72d..4bc878a 100644
--- a/src/views/purchase/purchasingrequisition/index.vue
+++ b/src/views/purchase/purchasingrequisition/index.vue
@@ -55,7 +55,7 @@
采购申请管理