Commit 912813996e4939b8e02fe88accd93db6fee83f62

Authored by 陈鑫涛
1 parent 7447756d

默认使用刀版图

src/components/Common/Typesetting/typesetting.js
... ... @@ -5,7 +5,6 @@ import { VerticalRightOutlined, VerticalLeftOutlined, LeftOutlined, RightOutline
5 5 import * as commonUtils from "@/utils/utils"; /* 通用方法 */
6 6 import commonConfig from "@/utils/config";
7 7 import styles from "./index.less";
8   -// import DynamicSVG from "../../Common/BoxDesign/index";
9 8 import DynamicSVG from "../../Common/BoxDesignCompontent/svg";
10 9 import * as commonFunc from "@/components/Common/commonFunc";
11 10  
... ... @@ -38,6 +37,7 @@ const Typesetting = props => {
38 37 sPackDetailPath,
39 38 sColumnNameConfig,
40 39 bAdvancedSetting, // 高级设置
  40 + sSvgPath,
41 41 } = slaveRowData;
42 42  
43 43 const { masterData, selectedNode, slaveData } = state;
... ... @@ -336,10 +336,12 @@ const Typesetting = props => {
336 336 }}
337 337 >
338 338 <div style={{ transform: `rotateZ(${offsetZ}deg)` }}>
339   - <DynamicSVG {...svgProps} />
  339 + {!sSvgPath ? <DynamicSVG {...svgProps} /> : <img src={sSvgPath} width="100%" height="100%" />}
  340 + {/* <DynamicSVG {...svgProps} /> */}
340 341 </div>
341 342 </div>
342 343 );
  344 +
343 345 const createBox = (col, row, index, leftPosition, topPosition, offsetZ, icon) => (
344 346 <div
345 347 key={`${col}-${row}-${index}`}
... ... @@ -373,7 +375,7 @@ const Typesetting = props =&gt; {
373 375 }}
374 376 >
375 377 <div style={{ transform: `rotateZ(${iFAngle}deg)` }}>
376   - <DynamicSVG {...svgProps} />
  378 + {!sSvgPath ? <DynamicSVG {...svgProps} /> : <img src={sSvgPath} width="100%" height="100%" />}
377 379 </div>
378 380 </div>
379 381 <div
... ... @@ -387,12 +389,12 @@ const Typesetting = props =&gt; {
387 389 position: "absolute",
388 390 left: `${isVertical ? dSLengthOffset + dYBJJ : jInnerWidth + dFLengthOffset + dSLengthOffset + dYBJJ}px`,
389 391 top: `${
390   - isVertical ? jInnerHeight + dXBJJ + dFWidthOffset + dSWidthOffset : iSAngle === 90 || iSAngle === 270 ? 0 : dSWidthOffset + dXBJJ
  392 + isVertical ? jInnerHeight + dXBJJ + dFWidthOffset + dSWidthOffset : iSAngle === 90 || iSAngle === 270 ? dSWidthOffset : dSWidthOffset + dXBJJ
391 393 }px`,
392 394 }}
393 395 >
394 396 <div style={{ transform: `rotateZ(${iSAngle}deg)` }}>
395   - <DynamicSVG {...svgProps} />
  397 + {!sSvgPath ? <DynamicSVG {...svgProps} /> : <img src={sSvgPath} width="100%" height="100%" />}
396 398 </div>
397 399 </div>
398 400 </div>
... ... @@ -432,7 +434,7 @@ const Typesetting = props =&gt; {
432 434 {/* <img src={icon} width="100%" height="100%" /> */}
433 435 {/* {isSvg ? <DynamicSVG {...props} /> : <img src={icon} width="100%" height="100%" />} */}
434 436 <div style={{ transform: `rotateZ(${iFAngle}deg)` }}>
435   - <DynamicSVG {...svgProps} />
  437 + {!sSvgPath ? <DynamicSVG {...svgProps} /> : <img src={sSvgPath} width="100%" height="100%" />}
436 438 </div>
437 439 </div>
438 440 </div>
... ...
src/components/QuickQuote/index.css
... ... @@ -63,13 +63,14 @@
63 63 .quickQuote .content .rightContent .viewTable1 :global .ant-form-item-label {
64 64 background-color: transparent !important;
65 65 color: #000 !important;
66   - flex: 0 0 100px !important;
67   - max-width: 100px !important;
  66 + flex: 0 0 70px !important;
  67 + max-width: 70px !important;
  68 + text-align: right !important;
68 69 }
69 70 .quickQuote .content .rightContent .viewTable :global .ant-form-item-control,
70 71 .quickQuote .content .rightContent .viewTable1 :global .ant-form-item-control {
71 72 flex: 1;
72   - max-width: calc(100% - 100px);
  73 + max-width: calc(100% - 70x);
73 74 }
74 75 .quickQuote .content .rightContent .viewTable :global .viewStyle .ant-input-number,
75 76 .quickQuote .content .rightContent .viewTable1 :global .viewStyle .ant-input-number {
... ... @@ -166,6 +167,10 @@
166 167 display: flex;
167 168 align-items: center;
168 169 }
  170 +.quickQuote .content .rightContent .boxPart1 .boxPart1Right .boxRreview :global .ant-carousel .slick-dots li button {
  171 + background-color: #000;
  172 + /* 未激活时的指示器颜色 */
  173 +}
169 174 .quickQuote .content .rightContent .boxPart1 .boxPart1Right .boxRreview :global .ant-image {
170 175 padding: 15px;
171 176 }
... ... @@ -244,7 +249,7 @@
244 249 }
245 250 .quickQuote .content .rightContent .many {
246 251 width: 100%;
247   - height: 235px;
  252 + height: 185px;
248 253 padding: 0 10px 0 10px;
249 254 position: relative;
250 255 }
... ...
src/components/QuickQuote/index.jsx
1 1 /* eslint-disable */
2 2 import { useRef, useEffect, useState, useCallback, useMemo } from "react";
3   -import { Button, Divider, Tabs, Tree, Radio, Image, Modal, Input, message, Badge, Checkbox } from "antd-v4";
  3 +import { Button, Divider, Tabs, Tree, Radio, Image, Modal, Input, message, Badge, Checkbox, Carousel } from "antd-v4";
4 4 import { ArrowLeftOutlined, FolderFilled, FolderOpenFilled, FileTextFilled, PlusOutlined, MinusOutlined } from "@ant-design/icons";
5 5 import { cloneDeep } from "lodash";
6 6 import commonConfig from "@/utils/config";
... ... @@ -479,7 +479,7 @@ const QuickQuoteEvent = props =&gt; {
479 479 // 核价按钮
480 480 addState.handleCalcPrice = async () => {
481 481 const { masterConfig, masterData = {}, slaveConfig, slaveData = [], selectedNode = {}, extraParts = {} } = state;
482   - const selectProduct = commonFunc.showLocalMessage(props, 'selectProduct', '请先选择产品');
  482 + const selectProduct = commonFunc.showLocalMessage(props, "selectProduct", "请先选择产品");
483 483 if (commonUtils.isEmptyObject(selectedNode)) {
484 484 message.error(selectProduct, 2);
485 485 return;
... ... @@ -1204,7 +1204,7 @@ const TreeComponent = props =&gt; {
1204 1204 const ContentComponent = props => {
1205 1205 const { selectedNode = {}, extraParts = {} } = props.state;
1206 1206 const manyqtysInfo = props.getI18nName("manyqtysInfo", "多数量报价");
1207   - const selectProduct = commonFunc.showLocalMessage(props, 'selectProduct', '请先选择产品');
  1207 + const selectProduct = commonFunc.showLocalMessage(props, "selectProduct", "请先选择产品");
1208 1208 const { showName } = selectedNode;
1209 1209 const extraPartsList = extraParts[showName] || [];
1210 1210 let { sAllPartsName = "" } = selectedNode;
... ... @@ -1316,7 +1316,7 @@ const ContentComponent = props =&gt; {
1316 1316 // 主表组件
1317 1317 const MasterComponent = props => {
1318 1318 const { masterConfig, masterData = {}, selectedNode = {} } = props.state;
1319   - const { app }= props;
  1319 + const { app } = props;
1320 1320 if (!masterConfig) return "";
1321 1321  
1322 1322 const ableConfigs = masterConfig.gdsconfigformslave.filter(item => item.sName && item.bVisible);
... ... @@ -1344,7 +1344,7 @@ const MasterComponent = props =&gt; {
1344 1344 lengthData.showName = "高(D)";
1345 1345 lengthData.sChinese = "高(D)";
1346 1346 lengthData.sEnglish = "Height (D)";
1347   - if(app.userinfo?.sLanguage === 'sEnglish') {
  1347 + if (app.userinfo?.sLanguage === "sEnglish") {
1348 1348 lengthData.showName = lengthData.sEnglish;
1349 1349 }
1350 1350 }
... ... @@ -1353,7 +1353,7 @@ const MasterComponent = props =&gt; {
1353 1353 lengthData.showName = "长(L)";
1354 1354 lengthData.sChinese = "长(L)";
1355 1355 lengthData.sEnglish = "Length (L)";
1356   - if(app.userinfo?.sLanguage === 'sEnglish') {
  1356 + if (app.userinfo?.sLanguage === "sEnglish") {
1357 1357 lengthData.showName = lengthData.sEnglish;
1358 1358 }
1359 1359 }
... ... @@ -1477,7 +1477,7 @@ const BoxComponent = props =&gt; {
1477 1477 if (item.sName === "sPaperDirection" && selectedNode.sTypeKey === "huace") {
1478 1478 return false;
1479 1479 }
1480   -
  1480 +
1481 1481 // 判断bPartsDimension 是否显示展长展宽,0不显示,1显示
1482 1482  
1483 1483 if (selectedNode.bPartsDimension === false && (item.sName === "dPartsLength" || item.sName === "dPartsWidth")) {
... ... @@ -1496,9 +1496,9 @@ const BoxComponent = props =&gt; {
1496 1496 if (selectedNode.sProductType === "不干胶") {
1497 1497 showNameKeyList = ["dZBLB", "dZBJJ", "dYBJJ", "dSBJJ", "dXBJJ"];
1498 1498 }
1499   - const UlToolPosition = commonFunc.showLocalMessage(props, 'UlToolPosition', '上下刀位');
1500   - const RLToolPosition = commonFunc.showLocalMessage(props, 'RLToolPosition', '左右刀位');
1501   - const LeftMargin = commonFunc.showLocalMessage(props, 'LeftMargin', '左右刀位');
  1499 + const UlToolPosition = commonFunc.showLocalMessage(props, "UlToolPosition", "上下刀位");
  1500 + const RLToolPosition = commonFunc.showLocalMessage(props, "RLToolPosition", "左右刀位");
  1501 + const LeftMargin = commonFunc.showLocalMessage(props, "LeftMargin", "左右刀位");
1502 1502 boxConfigList = boxConfig?.gdsconfigformslave?.filter(item => item.bVisible && showNameKeyList.includes(item.sName)) || [];
1503 1503 if (selectedNode.sProductType === "不干胶") {
1504 1504 const mappings = {
... ... @@ -1549,9 +1549,10 @@ const BoxComponent = props =&gt; {
1549 1549 x.sName === "dPartsWidth" ||
1550 1550 x.sName === "dRowGap" ||
1551 1551 x.sName === "dColGap" ||
1552   - x.sName === "dBleed" ||
  1552 + x.sName === "dBleed" ||
1553 1553 x.sName === "sPaperDirection",
1554   - default: x => x.sName === "dBleed" || x.sName === "sMagnification" || x.sName === "dPartsLength" || x.sName === "dPartsWidth" || x.sName === "dSumPQty",
  1554 + default: x =>
  1555 + x.sName === "dBleed" || x.sName === "sMagnification" || x.sName === "dPartsLength" || x.sName === "dPartsWidth" || x.sName === "dSumPQty",
1555 1556 };
1556 1557 if (selectedNode.sProductType === "不干胶") {
1557 1558 upViewProps12.viewConfigs = upViewProps12.viewConfigs.filter(filterConditions.juantong);
... ... @@ -1559,7 +1560,7 @@ const BoxComponent = props =&gt; {
1559 1560 if (!(selectedNode.sTypeKey === "huace" && slaveRowData.sBoxModel === "封面")) {
1560 1561 upViewProps12.viewConfigs = upViewProps12.viewConfigs.filter(filterConditions.default);
1561 1562 }
1562   -
  1563 +
1563 1564 // 拼板信息表单
1564 1565 const upViewProps20 = getUpViewPropsByITag(20);
1565 1566 // 如果是卷筒类需要单独处理
... ... @@ -1995,16 +1996,16 @@ const BoxComponent = props =&gt; {
1995 1996 const isShowImg = boxList.find(x => x.sName === "盒身")?.type !== "" || false;
1996 1997 const PrintingParameters = props.getI18nName("PrintingParameters", "印刷参数");
1997 1998  
1998   - const BoxInformation = commonFunc.showLocalMessage(props, 'Box-typeInformation', '拼版信息');
1999   - const ImpositionInformation = commonFunc.showLocalMessage(props, 'ImpositionInformation', '拼版信息');
  1999 + const BoxInformation = commonFunc.showLocalMessage(props, "Box-typeInformation", "拼版信息");
  2000 + const ImpositionInformation = commonFunc.showLocalMessage(props, "ImpositionInformation", "拼版信息");
2000 2001  
2001   - const noImage = commonFunc.showLocalMessage(props, 'ImpositionInformation', '暂无图片');
  2002 + const noImage = commonFunc.showLocalMessage(props, "ImpositionInformation", "暂无图片");
2002 2003  
2003 2004  
2004   - // props.setState(prevState => ({
2005   - // ...prevState,
2006   - // svgBoxList: boxList,
2007   - // }));
  2005 + const imagesData = [
  2006 + { src: slaveRowData.sPackDetailPathUpLoad, alt: "展开图" },
  2007 + { src: slaveRowData.sPackPath, alt: "立体图" },
  2008 + ];
2008 2009 return (
2009 2010 <Tabs
2010 2011 key={boxModel}
... ... @@ -2079,9 +2080,7 @@ const BoxComponent = props =&gt; {
2079 2080 <div className={styles.boxPart1Right}>
2080 2081 <div className={styles.boxRreview}>
2081 2082 <Image.PreviewGroup>
2082   - {!isShowImg ? (
2083   - <Image width={300} src={slaveRowData.sPackDetailPathUpLoad} />
2084   - ) : svgProps.boxList.length ? (
  2083 + {svgProps.boxList.length ? (
2085 2084 <div style={{ width: " 300px", height: "300px" }}>
2086 2085 <DynamicSVG {...svgProps} />
2087 2086 </div>
... ... @@ -2099,7 +2098,16 @@ const BoxComponent = props =&gt; {
2099 2098 )} */}
2100 2099 {/* <div className={styles.boxRreviewTitile}>展开图</div> */}
2101 2100 {slaveRowData.sPackPath ? (
2102   - <Image width={300} src={slaveRowData.sPackPath} />
  2101 + // <Image width={300} src={slaveRowData.sPackPath} />
  2102 +
  2103 + <Carousel style={{ width: "300px", height: "300px" }} className={styles.carousel} dots>
  2104 + { imagesData.map((image, index) => (
  2105 + <div key={index} className="carousel-item">
  2106 + <Image width={300} src={image.src} alt={image.alt} />
  2107 + </div>
  2108 + ))
  2109 + }
  2110 + </Carousel>
2103 2111 ) : (
2104 2112 <div className={styles.noImg}>{noImage}</div>
2105 2113 )}
... ... @@ -2603,11 +2611,11 @@ const BoxModelSelectedModal = props =&gt; {
2603 2611 const [boxData, setBoxData] = useState([]);
2604 2612 const [treeClassName, setTreeClassName] = useState("");
2605 2613 const [boxTypeSelected, setBoxTypeSelected] = useState("全部");
2606   - const UniqueID = commonFunc.showLocalMessage(props, 'UniqueID', '唯一ID');
2607   - const sName = commonFunc.showLocalMessage(props, 'jurCon', '名称');
2608   - const KnifeLineChart = commonFunc.showLocalMessage(props, 'KnifeLineChart', '刀线图');
2609   - const ThreeDGraph = commonFunc.showLocalMessage(props, '3DGraph', '3D图');
2610   - const BtnOperations = commonFunc.showLocalMessage(props, 'BtnOperations', '操作');
  2614 + const UniqueID = commonFunc.showLocalMessage(props, "UniqueID", "唯一ID");
  2615 + const sName = commonFunc.showLocalMessage(props, "jurCon", "名称");
  2616 + const KnifeLineChart = commonFunc.showLocalMessage(props, "KnifeLineChart", "刀线图");
  2617 + const ThreeDGraph = commonFunc.showLocalMessage(props, "3DGraph", "3D图");
  2618 + const BtnOperations = commonFunc.showLocalMessage(props, "BtnOperations", "操作");
2611 2619  
2612 2620 useEffect(() => {
2613 2621 const boxList = [
... ... @@ -2742,7 +2750,7 @@ const BoxModelSelectedModal = props =&gt; {
2742 2750 return svgProps;
2743 2751 };
2744 2752 const selectBoxList = boxData.filter(item => (boxTypeSelected === "全部" ? true : (item.sBoxType || "其它") === boxTypeSelected));
2745   - const noImage = commonFunc.showLocalMessage(props, 'ImpositionInformation', '暂无图片');
  2753 + const noImage = commonFunc.showLocalMessage(props, "ImpositionInformation", "暂无图片");
2746 2754 const tableProps = {
2747 2755 ...commonBusiness.getTableTypes("box", {
2748 2756 ...props,
... ... @@ -2757,10 +2765,11 @@ const BoxModelSelectedModal = props =&gt; {
2757 2765 columns
2758 2766 .filter(item => item.dataIndex?.includes("Path"))
2759 2767 .forEach(column => {
  2768 +
2760 2769 // (value ? (column.dataIndex === 'sPackDetailPath' ? (boxData[index].sPackPath ? <img src={value} alt="" width={270} height={270} /> : '') : <img src={value} alt="" width={270} height={270} />) : "暂无图片");
2761 2770 column.render = (value, record, index) =>
2762 2771 column.dataIndex === "sPackDetailPathUpLoad" ? (
2763   - selectBoxList[index].sTypes ? (
  2772 + !value ? (
2764 2773 <div style={{ width: "auto", height: 150 }}>
2765 2774 <DynamicSVG {...getSvgProps(selectBoxList[index])} />
2766 2775 </div>
... ... @@ -2794,8 +2803,8 @@ const BoxModelSelectedModal = props =&gt; {
2794 2803 });
2795 2804 },
2796 2805 };
2797   - const BoxSelection = commonFunc.showLocalMessage(props, 'Box-TypeSelection', '盒型选择');
2798   - const BtnClose = commonFunc.showLocalMessage(props, 'BtnClose', '关闭');
  2806 + const BoxSelection = commonFunc.showLocalMessage(props, "Box-TypeSelection", "盒型选择");
  2807 + const BtnClose = commonFunc.showLocalMessage(props, "BtnClose", "关闭");
2799 2808 return (
2800 2809 <AntdDraggableModal
2801 2810 width="min(calc(100vw - 350px), 1100px)"
... ...
src/components/QuickQuote/index.less
... ... @@ -207,7 +207,9 @@
207 207 height: auto;
208 208 display: flex;
209 209 align-items: center;
210   -
  210 + :global .ant-carousel .slick-dots li button {
  211 + background-color: #000; /* 未激活时的指示器颜色 */
  212 + }
211 213 :global {
212 214 .ant-image {
213 215 padding: 15px;
... ... @@ -373,7 +375,7 @@
373 375 .boxTree {
374 376 width: 250px;
375 377 height: 100%;
376   - background: var(--xly-skin-header-color, #383d41);
  378 + background: var(--xly-skin-header-color, #383d41);
377 379 padding: 10px 0 0 10px;
378 380 overflow: hidden;
379 381  
... ...
src/mobile/components/SelectInput.jsx
... ... @@ -73,6 +73,7 @@ const SelectInput = props =&gt; {
73 73 const data = coplyColumns[index];
74 74 data[itemDetail.sName] = data[itemDetail.sName] ? data[itemDetail.sName] : data.label || data.sName || data.sProcessName || data.sColorName;
75 75 setValue(columns[index]?.label || "");
  76 +
76 77 props.onDataChange(tableName, itemDetail.sName, data, data.sId, coplyColumns);
77 78 setVisible(false);
78 79 };
... ... @@ -151,6 +152,7 @@ const SelectInput = props =&gt; {
151 152 } else {
152 153 if (sDropDownType === "sql") {
153 154 const { sSqlCondition } = itemDetail;
  155 +
154 156 if (sSqlCondition) {
155 157 const { viewRow } = props;
156 158 const keys = sSqlCondition.split(",").map(sSqlCondition => sSqlCondition.split(".")[1]);
... ...
src/mobile/quotation/detailNew.jsx
... ... @@ -1109,7 +1109,6 @@ const QuotationDetail = props =&gt; {
1109 1109 lengthData.showName = "长(L)";
1110 1110 lengthData.sChinese = "长(L)";
1111 1111 lengthData.sEnglish = "Length (L)";
1112   - console.log('23323', app);
1113 1112 if(app.userinfo?.sLanguage === 'sEnglish') {
1114 1113 lengthData.showName = lengthData.sEnglish;
1115 1114 }
... ... @@ -2303,7 +2302,7 @@ const PrintParamsComponent = props =&gt; {
2303 2302 const result = [];
2304 2303 for (let i = 0; i < printParams.length + 1; i++) {
2305 2304 const printParamsItem = printParams[i - 1];
2306   - const viewRow = { ...(i === 0 ? slaveRowData : printParamsItem), sProductClassifyId: selectedNode.sId };
  2305 + const viewRow = { ...(i === 0 ? slaveRowData : printParamsItem), sProductClassifyId: selectedNode.sId,sProcessId:i === 0 ? slaveRowData.sId : printParamsItem.sId};
2307 2306  
2308 2307 const viewProps = {
2309 2308 ...props,
... ... @@ -2481,7 +2480,10 @@ const MaterialsComponent = props =&gt; {
2481 2480  
2482 2481 return (
2483 2482 <div>
2484   - 材料信息
  2483 + <div className={styles.boxTitle}>
  2484 + 材料信息
  2485 + <EditFill color="#BFBFBF" style={{ marginLeft: "1rem" }} />
  2486 + </div>
2485 2487 <div className={styles.materialsLine}>
2486 2488 <div className={styles.selectInput} style={{ width: "50%" }}>
2487 2489 <SelectInput {...viewProps} itemDetail={materialsConfigNew[0]} />
... ...
src/mobile/quotation/quotationDetail.css
... ... @@ -4,6 +4,8 @@
4 4 }
5 5 .customer {
6 6 margin-top: 0.5rem;
  7 + font-size: 1.25rem;
  8 + font-weight: 600;
7 9 }
8 10 .customer :global .adm-input-element {
9 11 border: 1px solid #dededf;
... ...
src/mobile/quotation/quotationDetail.less
... ... @@ -6,6 +6,8 @@
6 6 }
7 7 .customer {
8 8 margin-top: 0.5rem;
  9 + font-size: 1.25rem;
  10 + font-weight: 600;
9 11 :global .adm-input-element {
10 12 border: 1px solid #dededf;
11 13 height: 3.125rem;
... ...