From b6e4f84570a93f7a76cf89406905dacad5436c62 Mon Sep 17 00:00:00 2001
From: Teo <2642673902@qq.com>
Date: Sat, 9 Aug 2025 09:56:49 +0800
Subject: [PATCH 1/2] =?UTF-8?q?=E5=90=88=E5=B9=B6?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
.env.development | 2 +-
src/layout/components/notice/index.vue | 1 -
src/views/materials/repertoryDetails/index.vue | 2 +-
3 files changed, 2 insertions(+), 3 deletions(-)
diff --git a/.env.development b/.env.development
index fe20df3..8aa5e08 100644
--- a/.env.development
+++ b/.env.development
@@ -5,7 +5,7 @@ VITE_APP_TITLE = 新能源项目管理平台
VITE_APP_ENV = 'development'
# 开发环境
-VITE_APP_BASE_API = 'http://192.168.110.159:8898'
+VITE_APP_BASE_API = 'http://192.168.110.119:8898'
# 无人机接口地址
diff --git a/src/layout/components/notice/index.vue b/src/layout/components/notice/index.vue
index e43b2b8..12e8289 100644
--- a/src/layout/components/notice/index.vue
+++ b/src/layout/components/notice/index.vue
@@ -19,7 +19,6 @@
-
diff --git a/src/views/materials/repertoryDetails/index.vue b/src/views/materials/repertoryDetails/index.vue
index 09f0876..4d7d555 100644
--- a/src/views/materials/repertoryDetails/index.vue
+++ b/src/views/materials/repertoryDetails/index.vue
@@ -142,7 +142,7 @@ const resetQuery = () => {
/** 修改按钮操作 */
const handleUpdate = async (row?: RepertoryVO) => {
- proxy?.$tab.openPage('/materials-management/repertoryDetail', '物资清单详情', {
+ proxy?.$tab.openPage('/materials/repertoryDetail', '物资清单详情', {
id: row.id
});
};
From 6bbe8a83f713ab702413aace38683915275f636d Mon Sep 17 00:00:00 2001
From: Teo <2642673902@qq.com>
Date: Sat, 9 Aug 2025 18:02:06 +0800
Subject: [PATCH 2/2] =?UTF-8?q?=E5=AE=A1=E6=A0=B8=E5=B7=A5=E4=BD=9C?=
=?UTF-8?q?=E6=B5=81?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
.env.development | 2 +-
src/api/materials/batchPlan/index.ts | 13 +++
src/api/materials/batchPlan/types.ts | 2 +-
src/api/out/monthPlan/types.ts | 18 ++-
src/views/materials/batchPlan/index.vue | 67 +++++++----
src/views/materials/batchPlan/indexEdit.vue | 14 +--
src/views/materials/cailiaoshebei/index.vue | 97 ++++++++--------
src/views/materials/orderEquipment/index.vue | 108 +++++++++---------
.../materials/orderEquipment/indexEdit.vue | 3 +-
.../orderEquipment/indexEquipment.vue | 52 +++++----
src/views/materials/orderMaterials/index.vue | 12 +-
src/views/materials/suppliesprice/index.vue | 33 ++++--
src/views/out/constructionValue/index.vue | 2 +-
src/views/out/designCompletion/index.vue | 37 +++---
src/views/out/monthPlan/index.vue | 6 +-
src/views/out/monthPlan/indexEdit.vue | 2 +-
16 files changed, 264 insertions(+), 204 deletions(-)
diff --git a/.env.development b/.env.development
index 8aa5e08..fe20df3 100644
--- a/.env.development
+++ b/.env.development
@@ -5,7 +5,7 @@ VITE_APP_TITLE = 新能源项目管理平台
VITE_APP_ENV = 'development'
# 开发环境
-VITE_APP_BASE_API = 'http://192.168.110.119:8898'
+VITE_APP_BASE_API = 'http://192.168.110.159:8898'
# 无人机接口地址
diff --git a/src/api/materials/batchPlan/index.ts b/src/api/materials/batchPlan/index.ts
index 59238fc..6227d9b 100644
--- a/src/api/materials/batchPlan/index.ts
+++ b/src/api/materials/batchPlan/index.ts
@@ -108,3 +108,16 @@ export const getPcDetail = (id: string | number): AxiosPromise
method: 'get'
});
};
+
+/**
+ * 查询物资-材料设备选择列表
+ * @param query
+ * @returns {*}
+ */
+export const listSelectCailiaoshebei = (query?: any): AxiosPromise => {
+ return request({
+ url: '/cailiaoshebei/materialbatchdemandplan/masterDataList',
+ method: 'get',
+ params: query
+ });
+};
diff --git a/src/api/materials/batchPlan/types.ts b/src/api/materials/batchPlan/types.ts
index a60ab66..2d0b773 100644
--- a/src/api/materials/batchPlan/types.ts
+++ b/src/api/materials/batchPlan/types.ts
@@ -3,7 +3,7 @@ export interface CailiaoshebeiVO {
* 主键ID
*/
id: string | number;
-
+ cailiaoshebeiId?: string | number;
/**
* 批次ID
*/
diff --git a/src/api/out/monthPlan/types.ts b/src/api/out/monthPlan/types.ts
index 3144767..526b3dd 100644
--- a/src/api/out/monthPlan/types.ts
+++ b/src/api/out/monthPlan/types.ts
@@ -43,7 +43,6 @@ export interface MonthPlanVO {
* 完成审核状态
*/
completeAuditStatus: string;
-
}
export interface MonthPlanForm extends BaseEntity {
@@ -51,6 +50,10 @@ export interface MonthPlanForm extends BaseEntity {
* 主键ID
*/
id?: string | number;
+ /**
+ * 是否设计
+ */
+ isDesign?: boolean;
/**
* 项目ID
@@ -91,11 +94,9 @@ export interface MonthPlanForm extends BaseEntity {
* 完成审核状态
*/
completeAuditStatus?: string;
-
}
export interface MonthPlanQuery extends PageQuery {
-
/**
* 项目ID
*/
@@ -136,11 +137,8 @@ export interface MonthPlanQuery extends PageQuery {
*/
completeAuditStatus?: string;
- /**
- * 日期范围参数
- */
- params?: any;
+ /**
+ * 日期范围参数
+ */
+ params?: any;
}
-
-
-
diff --git a/src/views/materials/batchPlan/index.vue b/src/views/materials/batchPlan/index.vue
index 579b460..2f656a5 100644
--- a/src/views/materials/batchPlan/index.vue
+++ b/src/views/materials/batchPlan/index.vue
@@ -15,7 +15,7 @@
-
+
+ >
+
+
+ {{node.label }}
+
+
+
+
-
+
选择
-
+
保存
@@ -66,21 +73,16 @@
-
+
-
+
-
-
-
-
-
@@ -94,9 +96,12 @@
:data="cailiaoshebeiAllList"
:props="{
label: 'name',
- key: 'id'
+ key: 'cailiaoshebeiId'
}"
- />
+ >
+ {{ `${option.specification || ''} ${option.name || ''}` }}1
+
+
diff --git a/src/views/materials/cailiaoshebei/index.vue b/src/views/materials/cailiaoshebei/index.vue
index b786f4b..70e49db 100644
--- a/src/views/materials/cailiaoshebei/index.vue
+++ b/src/views/materials/cailiaoshebei/index.vue
@@ -66,7 +66,7 @@
-
+
+ >
+
+
+ {{ node.label }}
+
+
+
+
-
+
新增
-
+
修改
-
+
删除
-
审核
@@ -132,30 +134,26 @@
-
-
+
+
+
+ {{ item }}
+
+
+
+
-
-
+
-
-
-
+
+
+
-
-
+
+
-
-
@@ -258,9 +245,9 @@ import {
import { CailiaoshebeiVO, CailiaoshebeiQuery, CailiaoshebeiForm } from '@/api/materials/cailiaoshebei/types';
import { listContractor } from '@/api/project/contractor';
import { useUserStoreHook } from '@/store/modules/user';
-
+const batchNumber = ref('');
const { proxy } = getCurrentInstance() as ComponentInternalInstance;
-const { supply } = toRefs(proxy?.useDict('supply'));
+const { supply, wf_business_status } = toRefs(proxy?.useDict('supply', 'wf_business_status'));
// 获取用户 store
const userStore = useUserStoreHook();
// 从 store 中获取项目列表和当前选中的项目
@@ -268,7 +255,7 @@ const currentProject = computed(() => userStore.selectedProject);
const batchTreeRef = ref(null);
const cailiaoshebeiList = ref([]);
const buttonLoading = ref(false);
-const loading = ref(true);
+const loading = ref(false);
const showSearch = ref(true);
const ids = ref>([]);
const single = ref(true);
@@ -338,14 +325,19 @@ const getList = async () => {
loading.value = true;
const res = await listCailiaoshebei(queryParams.value);
cailiaoshebeiList.value = res.rows;
+ console.log(1111);
loading.value = false;
};
+const searchBatchList = async () => {
+ queryParams.value.batchNumber = batchNumber.value;
+ getBatchList();
+};
+
//查询批次列表
const getBatchList = async () => {
const res = await listBatch(queryParams.value);
- console.log('🚀 ~ getBatchList ~ res:', res);
batchOptions.value = res.rows;
total.value = res.total;
try {
@@ -356,6 +348,8 @@ const getBatchList = async () => {
} catch (error) {
form.value.batchNumber = '';
}
+ console.log(145615616);
+
getList();
};
@@ -381,6 +375,7 @@ const cancel = () => {
const reset = () => {
const preservedBatchId = form.value.batchNumber; // 先保存当前的 batchNumber
const approvalDesigndBatchId = form.value.approvalDesign; // 先保存当前的 batchNumber
+ selectValue.value = [];
form.value = { ...initFormData, batchNumber: preservedBatchId, approvalDesign: approvalDesigndBatchId }; // 重置但保留
cailiaoshebeiFormRef.value?.resetFields();
@@ -458,10 +453,9 @@ const submitForm = () => {
/** 新增批次 */
const addBatch = async () => {
await proxy?.$modal.confirm('是否确认新增批次?').finally(() => (loading.value = false));
- const res = await getBatch({ projectId: currentProject.value.id });
- console.log('🚀 ~ addBatch ~ res:', res);
+ queryParams.value.batchNumber = '';
+ await getBatch({ projectId: currentProject.value.id });
await getBatchList();
-
proxy?.$modal.msgSuccess('新增成功');
};
@@ -541,3 +535,14 @@ onUnmounted(() => {
listeningProject();
});
+
+
diff --git a/src/views/materials/orderEquipment/index.vue b/src/views/materials/orderEquipment/index.vue
index 2443a82..19e3c7d 100644
--- a/src/views/materials/orderEquipment/index.vue
+++ b/src/views/materials/orderEquipment/index.vue
@@ -4,7 +4,7 @@
-
+
+ >
+
+
+ {{ node.label }}
+
+
+
+
选择
-->
- 保存
+ 保存
审核
-
+
分享
-
+
-
+
@@ -61,25 +76,23 @@
-
+
-
+
-
+
-
-
@@ -87,45 +100,11 @@
-
+
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
+
+
@@ -169,7 +148,7 @@ import { listContractor } from '@/api/project/contractor';
import { useUserStoreHook } from '@/store/modules/user';
const { proxy } = getCurrentInstance() as ComponentInternalInstance;
-const { supply } = toRefs(proxy?.useDict('supply'));
+const { supply, wf_business_status } = toRefs(proxy?.useDict('supply', 'wf_business_status'));
// 获取用户 store
const userStore = useUserStoreHook();
// 从 store 中获取项目列表和当前选中的项目
@@ -194,6 +173,7 @@ const dialog = reactive({
visible: false,
title: ''
});
+const batchNumber = ref('');
const initFormData: CailiaoshebeiForm = {
id: undefined,
@@ -261,8 +241,11 @@ const getBatchList = async () => {
try {
queryParams.value.batchNumber = res.rows[0].batchNumber;
batchTreeRef.value.setCurrentKey(res.rows[0].batchNumber);
- form.value.batchNumber = res.rows[0].batchNumber;
- form.value.approvalOrder = res.rows[0].approvalOrder;
+ Object.assign(form.value, res.rows[0]);
+ console.log('🚀 ~ getBatchList ~ form.value:', form.value);
+
+ // form.value.batchNumber = res.rows[0].batchNumber;
+ // form.value.approvalOrder = res.rows[0].approvalOrder;
} catch (error) {
form.value.batchNumber = '';
}
@@ -340,9 +323,9 @@ const onShare = () => {
const tokenStorage = useStorage(TokenKey, null);
const getToken = () => tokenStorage.value;
console.log(getToken());
-
+
// 跳转新的地址 传token
- let url = `http://192.168.110.151:7788/indexEquipment?projectId=${encodeURIComponent(currentProject.value.id)}&token=${encodeURIComponent(getToken())}&batchNumber=${encodeURIComponent(form.value.batchNumber)}`;
+ let url = `http://192.168.110.142:7788/indexEquipment?projectId=${encodeURIComponent(currentProject.value.id)}&token=${encodeURIComponent(getToken())}&batchNumber=${encodeURIComponent(form.value.batchNumber)}`;
window.open(url, '_blank');
};
/** 提交按钮 */
@@ -377,6 +360,11 @@ const handleAudit = async () => {
});
};
+const searchBatchList = async () => {
+ queryParams.value.batchNumber = batchNumber.value;
+ getBatchList();
+};
+
/** 提交穿梭框数据 */
const submitTransferForm = async () => {
cailiaoshebeiList.value = cailiaoshebeiSelectedList.value.map((id) => {
@@ -447,3 +435,13 @@ onUnmounted(() => {
listeningProject();
});
+
diff --git a/src/views/materials/orderEquipment/indexEdit.vue b/src/views/materials/orderEquipment/indexEdit.vue
index 1fa1a47..fc1c9e5 100644
--- a/src/views/materials/orderEquipment/indexEdit.vue
+++ b/src/views/materials/orderEquipment/indexEdit.vue
@@ -19,7 +19,7 @@
物资-设备订货
-
+
@@ -231,7 +231,6 @@ const submit = async (status, data) => {
onMounted(() => {
nextTick(async () => {
routeParams.value = proxy.$route.query;
- console.log('🚀 ~ proxy.$route.query:', proxy.$route.query);
reset();
loading.value = false;
if (routeParams.value.type === 'update' || routeParams.value.type === 'view' || routeParams.value.type === 'approval') {
diff --git a/src/views/materials/orderEquipment/indexEquipment.vue b/src/views/materials/orderEquipment/indexEquipment.vue
index 12732aa..3a7315f 100644
--- a/src/views/materials/orderEquipment/indexEquipment.vue
+++ b/src/views/materials/orderEquipment/indexEquipment.vue
@@ -13,11 +13,11 @@
-
+
@@ -30,7 +30,7 @@
-
+
@@ -50,11 +50,7 @@
-
-
-
-
-
+
@@ -84,6 +80,7 @@ const loading = ref(false);
const showSearch = ref(true);
const queryFormRef = ref
();
const cailiaoshebeiFormRef = ref();
+const { proxy } = getCurrentInstance();
var token = '';
const initFormData: CailiaoshebeiForm = {
id: undefined,
@@ -134,7 +131,7 @@ const { queryParams, form, rules } = toRefs(data);
const getList = async () => {
// 请求数据
axios
- .get('http://192.168.110.159:8898/cailiaoshebei/materialsorder/trackPcPlanList', {
+ .get('http://192.168.110.159:8898/cailiaoshebei/materialsorder/pcPlanListGHS', {
headers: {
'Content-Type': 'application/json',
'Authorization': `Bearer ${token}`,
@@ -147,7 +144,7 @@ const getList = async () => {
})
.then((response) => {
form.value = response.data.rows[0];
- console.log(form.value);
+ getListAll();
})
.catch((error) => {
console.error('请求失败:', error);
@@ -170,6 +167,8 @@ const getListAll = () => {
})
.then((response) => {
console.log('请求成功:', response.data);
+ cailiaoshebeiList.value = response.data.rows;
+
loading.value = false;
})
.catch((error) => {
@@ -179,22 +178,29 @@ const getListAll = () => {
};
/** 提交按钮 */
const submitForm = async () => {
+ cailiaoshebeiList.value.forEach((item) => {
+ if (item.id) {
+ delete item.id;
+ }
+ });
axios
- .get('http://192.168.110.159:8898/cailiaoshebei/materialsorder/modifyTheOrderFormGYS', {
- headers: {
- 'Content-Type': 'application/json',
- 'Authorization': `Bearer ${token}`,
- 'X-Requested-With': 'XMLHttpRequest'
- },
- params: {
- id: '',
- materialstatus: '',
- overdueType: '',
- cause: ''
+ .put(
+ 'http://192.168.110.159:8898/cailiaoshebei/materialsorder/modifyTheOrderFormGYS',
+ { ...form.value, list: cailiaoshebeiList.value, batchNumber: form.value.batchNumber }, // 请求体
+ {
+ headers: {
+ 'Content-Type': 'application/json',
+ 'Authorization': `Bearer ${token}`,
+ 'X-Requested-With': 'XMLHttpRequest'
+ },
+ params: {
+ /* 如果你还要传 URL 查询参数 */
+ }
}
- })
+ )
.then((response) => {
- console.log('请求成功:', response.data);
+ proxy?.$modal.msgSuccess('操作成功');
+
loading.value = false;
})
.catch((error) => {
diff --git a/src/views/materials/orderMaterials/index.vue b/src/views/materials/orderMaterials/index.vue
index 2fb321e..e95997d 100644
--- a/src/views/materials/orderMaterials/index.vue
+++ b/src/views/materials/orderMaterials/index.vue
@@ -4,7 +4,7 @@
-
+
userStore.selectedProject);
const batchTreeRef = ref(null);
const cailiaoshebeiList = ref([]);
const buttonLoading = ref(false);
-const loading = ref(true);
+const loading = ref(false);
const showSearch = ref(true);
const ids = ref>([]);
const single = ref(true);
@@ -250,9 +250,12 @@ const data = reactive>({
});
const { queryParams, form, rules } = toRefs(data);
+const batchNumber = ref('');
/** 查询物资-材料设备列表 */
const getList = async () => {
+ if (!queryParams.value.batchNumber) return;
+
loading.value = true;
const res = await listCailiaoshebei(queryParams.value);
cailiaoshebeiList.value = res.rows;
@@ -287,6 +290,11 @@ const handleNodeClick = (data: any) => {
getList();
};
+const searchBatchList = async () => {
+ queryParams.value.batchNumber = batchNumber.value;
+ getBatchList();
+};
+
/** 取消按钮 */
const cancel = () => {
reset();
diff --git a/src/views/materials/suppliesprice/index.vue b/src/views/materials/suppliesprice/index.vue
index db2d71b..46eab90 100644
--- a/src/views/materials/suppliesprice/index.vue
+++ b/src/views/materials/suppliesprice/index.vue
@@ -15,7 +15,7 @@
-->
-
+
+
+
+ {{ node.label }}
+
+
-
-
-
-
-
-
+
修改 userStore.selectedProject);
const batchTreeRef = ref(null);
const cailiaoshebeiList = ref([]);
const buttonLoading = ref(false);
-const loading = ref(true);
+const loading = ref(false);
const showSearch = ref(true);
const ids = ref>([]);
const single = ref(true);
@@ -262,6 +263,7 @@ const multiple = ref(true);
const total = ref(0);
const batchOptions = ref([]);
const { wf_business_status } = toRefs(proxy?.useDict('wf_business_status'));
+const batchNumber = ref('');
const queryFormRef = ref();
const cailiaoshebeiFormRef = ref();
@@ -357,8 +359,8 @@ const getBatchList = async () => {
/** 节点单击事件 */
const handleNodeClick = (data: any) => {
- console.log('🚀 ~ handleNodeClick ~ data:', data);
queryParams.value.batchNumber = data.batchNumber;
+ batchNumber.value = '';
form.value.batchNumber = data.batchNumber;
form.value.approvalPlan = data.approvalPlan;
console.log('🚀 ~ handleNodeClick ~ form.value:', form.value);
@@ -368,6 +370,11 @@ const handleNodeClick = (data: any) => {
getList();
};
+const searchBatchList = () => {
+ queryParams.value.batchNumber = batchNumber.value;
+ getBatchList();
+};
+
/** 取消按钮 */
const cancel = () => {
reset();
@@ -506,6 +513,14 @@ onUnmounted(() => {
});