From 6eb9cca89aedae484108987adc39b921e2a4268c Mon Sep 17 00:00:00 2001
From: chenxt <10125295+chen-xintao97@user.noreply.gitee.com>
Date: Sun, 4 Jan 2026 15:06:21 +0800
Subject: [PATCH] 设备及目标信息根据bPushDiff展示字段
---
src/components/Common/CommonHooks/useCommonBase.js | 1 -
src/mes/common/siderInfoComponent/index.js | 41 +++++++++++++++++++++++------------------
src/mes/common/siderInfoComponent/index.less | 3 ++-
src/utils/config.js | 2 +-
4 files changed, 26 insertions(+), 21 deletions(-)
diff --git a/src/components/Common/CommonHooks/useCommonBase.js b/src/components/Common/CommonHooks/useCommonBase.js
index e7d64e6..6258e1d 100644
--- a/src/components/Common/CommonHooks/useCommonBase.js
+++ b/src/components/Common/CommonHooks/useCommonBase.js
@@ -2975,7 +2975,6 @@ const useCommonBase = props => {
}
const newData = bAddFirst ? [addRowData, ...data] : [...data, addRowData];
- console.log("🚀 ~ handleMesTableLineAdd ~ newData:", newData,masterData,state,props)
const selectedRowKeys = [newSid];
const addState = {};
if (location.pathname.includes("indexPad")) {
diff --git a/src/mes/common/siderInfoComponent/index.js b/src/mes/common/siderInfoComponent/index.js
index 34080b9..2bed777 100644
--- a/src/mes/common/siderInfoComponent/index.js
+++ b/src/mes/common/siderInfoComponent/index.js
@@ -352,8 +352,8 @@ const WorkOrderTypeComponent = () => {
const [productionDivId] = useState(
`productionDivId_${commonUtils.createSid()}`
);
- const task= commonFunc.showLocalMessage(props, 'task', '任务:工单信息');
- const specialFocus= commonFunc.showLocalMessage(props, 'specialFocus', '任务:工单信息');
+ const task = commonFunc.showLocalMessage(props, 'task', '任务:工单信息');
+ const specialFocus = commonFunc.showLocalMessage(props, 'specialFocus', '任务:工单信息');
return (
@@ -404,7 +404,7 @@ const WorkOrderTypeComponent = () => {
const { sProcessName, sState } = item;
let colorValue;
switch (
- Number(sState) // 根据状态显示颜色
+ Number(sState) // 根据状态显示颜色
) {
case 2:
colorValue = "#FF7E37"; /* 2:等待:黄色 */
@@ -501,12 +501,12 @@ const WorkOrderTypeComponent = () => {
>
{viewRow.specialMemo
? viewRow.specialMemo
- .split(",")
- .map(item => (
-
- {item}
-
- ))
+ .split(",")
+ .map(item => (
+
+ {item}
+
+ ))
: ""}
@@ -533,11 +533,10 @@ const WorkOrderTypeComponent = () => {
style={{ cursor: "not-allowed", gap: 5 }}
>
{viewRow.sLabelColor}
@@ -634,7 +633,6 @@ const DeviceTargetInfoComponent = () => {
};
};
const equipmentTargetInformation = commonFunc.showLocalMessage(props, 'equipmentTargetInformation', '设备及目标信息');
-
return (
@@ -642,13 +640,20 @@ const DeviceTargetInfoComponent = () => {
{equipmentTargetInformation}
{showConfig.map((config, index) => {
- if (index > 4) return "";
+ // if (index > 4) return "";
+ // bPushDiff
+ const { bPushDiff = false } = props?.app?.userinfo
const className = cx({
mesShowType: true,
odd: index % 2 === 0
});
const showTypeProps = handleGetShowTypeProps(config);
-
+ if (index > 4 && !bPushDiff) {
+ return ''
+ }
+ if (index > 4 && bPushDiff && !['dPieceDefectBQty', 'dPieceDefectAQty'].includes(config?.sName)) {
+ return ''
+ }
if (config?.sName?.endsWith("Qty")) {
return (
@@ -754,7 +759,7 @@ const TeamInfoComponent = () => {
const teamShiftInfo = props.teamShiftInfoData?.[0] || {};
const { sEmployeeName = "", sEmployeeNo = "" } = teamShiftInfo;
- const teamInformation= commonFunc.showLocalMessage(props, 'teamInformation', '班组信息');
+ const teamInformation = commonFunc.showLocalMessage(props, 'teamInformation', '班组信息');
const captain = commonFunc.showLocalMessage(props, 'captain', '机长');
diff --git a/src/mes/common/siderInfoComponent/index.less b/src/mes/common/siderInfoComponent/index.less
index 3d02138..7acaab2 100644
--- a/src/mes/common/siderInfoComponent/index.less
+++ b/src/mes/common/siderInfoComponent/index.less
@@ -218,7 +218,8 @@
// 设备及目标信息
.deviceTargetInfo {
// .size(100%, 25%);
- .size(100%, 230px);
+ .size(100%);
+ max-height: 330px;
// margin-bottom: 15px;
background-color: #FFF6DE;
diff --git a/src/utils/config.js b/src/utils/config.js
index 72efcee..d0dfeb8 100644
--- a/src/utils/config.js
+++ b/src/utils/config.js
@@ -6,7 +6,7 @@ export const webSite = {
// faceAddress: isDev ? '//192.168.11.22:8080/xlyFace' : '//' + location.host + '/xlyFace',
fileAddress: isDev ? '//km5cjx.gnway.cc:43920/xlyReport/' : '//' + location.host + '/xlyReport/', // 接口地址
faceAddress: isDev ? '//km5cjx.gnway.cc:43920/xlyFace' : '//' + location.host + '/xlyFace',
- ipAddress: localStorage.ipAddress ? localStorage.ipAddress : isDev ? '//km5cjx.gnway.cc:47400/xlyEntry/' : '//' + location.host + '/xlyEntry/',
+ ipAddress: localStorage.ipAddress ? localStorage.ipAddress : isDev ? '//km5cjx.gnway.cc:43920/xlyEntry/' : '//' + location.host + '/xlyEntry/',
interfaceAddress: isDev ? '//km5cjx.gnway.cc:43920/xlyApi/' : '//' + location.host + '/xlyApi/', // 接口地址
// ipAddress: isDev ? '//ebc.jinjia.com:8091/xlyEntry/' : '//' + location.host + '/xlyEntry/',
// interfaceAddress: isDev ? '//ebc.jinjia.com:8091/xlyApi/' : '//' + location.host + '/xlyApi/', // 接口地址
--
libgit2 0.22.2