Commit 867bd8eb99c0cb1af6d74040917a6cdef20cabf6

Authored by zhangzzzz
1 parent 59378d2a

优化指令集功能;

src/components/Common/CommonComponent/index.js
@@ -493,9 +493,10 @@ export default class CommonComponent extends Component { @@ -493,9 +493,10 @@ export default class CommonComponent extends Component {
493 } else if (commonUtils.isNotEmptyObject(sMemo) && sMemo.indexOf("sAssignField") > -1) { 493 } else if (commonUtils.isNotEmptyObject(sMemo) && sMemo.indexOf("sAssignField") > -1) {
494 /* 赋值字段 变量设置双击弹出 */ 494 /* 赋值字段 变量设置双击弹出 */
495 this.props.onFieldDoubleClick(this.state.dataValue, this.props.showConfig, this.props.name); 495 this.props.onFieldDoubleClick(this.state.dataValue, this.props.showConfig, this.props.name);
496 - } else if (commonUtils.isNotEmptyObject(sMemo) && sMemo.indexOf("sInstruct") > -1) { 496 + } else if (commonUtils.isNotEmptyObject(sMemo) && sMemo.toLowerCase().includes('instruct')) {
497 /* 赋值字段 变量设置双击弹出 */ 497 /* 赋值字段 变量设置双击弹出 */
498 - this.props.onFieldDoubleClick(this.state.dataValue, this.props.showConfig, this.props.name); 498 + // this.props.onFieldDoubleClick(this.state.dataValue, this.props.showConfig, this.props.name);
  499 + this.handleEditInstruct();
499 } 500 }
500 }; 501 };
501 502
@@ -1827,7 +1828,7 @@ export default class CommonComponent extends Component { @@ -1827,7 +1828,7 @@ export default class CommonComponent extends Component {
1827 rows: commonUtils.isNotEmptyNumber(this.props.showConfig.iRowValue) ? this.props.showConfig.iRowValue : 1, 1828 rows: commonUtils.isNotEmptyNumber(this.props.showConfig.iRowValue) ? this.props.showConfig.iRowValue : 1,
1828 }; 1829 };
1829 1830
1830 - if (this.props.showConfig.sName.toLowerCase().includes('instruct')) { 1831 + if (this.props.showConfig.sName.toLowerCase().includes('instruct') && this.props.enabled) {
1831 obj.suffix = ( 1832 obj.suffix = (
1832 <span style={{ width: "8px" }} onClick={this.handleEditInstruct}> 1833 <span style={{ width: "8px" }} onClick={this.handleEditInstruct}>
1833 <EditOutlined style={{ color: "rgba(0,0,0,.85)" }} /> 1834 <EditOutlined style={{ color: "rgba(0,0,0,.85)" }} />
@@ -2077,7 +2078,7 @@ export default class CommonComponent extends Component { @@ -2077,7 +2078,7 @@ export default class CommonComponent extends Component {
2077 ), 2078 ),
2078 }; 2079 };
2079 2080
2080 - if (this.props.showConfig.sName.toLowerCase().includes('instruct')) { 2081 + if (this.props.showConfig.sName.toLowerCase().includes('instruct') && this.props.enabled) {
2081 obj.suffix = ( 2082 obj.suffix = (
2082 <span style={{ width: "8px" }} onClick={this.handleEditInstruct}> 2083 <span style={{ width: "8px" }} onClick={this.handleEditInstruct}>
2083 <EditOutlined style={{ color: "rgba(0,0,0,.85)" }} /> 2084 <EditOutlined style={{ color: "rgba(0,0,0,.85)" }} />
src/components/Common/CommonNewBill.js
@@ -1073,11 +1073,11 @@ class CommonNewBill extends Component { @@ -1073,11 +1073,11 @@ class CommonNewBill extends Component {
1073 } 1073 }
1074 } else if (showConfig?.sName === "sInstruct") { 1074 } else if (showConfig?.sName === "sInstruct") {
1075 /* 指令集弹窗 */ 1075 /* 指令集弹窗 */
1076 - const sInstructJsonString = sValue;  
1077 - this.props.onSaveState({  
1078 - visibleInstructField: true,  
1079 - sInstructJsonString,  
1080 - }); 1076 + // const sInstructJsonString = sValue;
  1077 + // this.props.onSaveState({
  1078 + // visibleInstructField: true,
  1079 + // sInstructJsonString,
  1080 + // });
1081 } 1081 }
1082 }; 1082 };
1083 /* 拿到赋值字段 */ 1083 /* 拿到赋值字段 */
src/components/Common/InstructSetSetting/index.js
@@ -7,8 +7,7 @@ import styles from &quot;./index.less&quot;; @@ -7,8 +7,7 @@ import styles from &quot;./index.less&quot;;
7 import { Input, Button, Space } from "antd-v4"; 7 import { Input, Button, Space } from "antd-v4";
8 import { MinusOutlined, CloseOutlined } from "@ant-design/icons"; 8 import { MinusOutlined, CloseOutlined } from "@ant-design/icons";
9 9
10 -const IFRAMEURL = "http://project.xlyprint.cn";  
11 -// const IFRAMEURL = "http://localhost:9099"; 10 +const IFRAMEURL = location.hostname === "localhost" ? "http://localhost:9099" : "http://project.xlyprint.cn";
12 11
13 const InstructSetSetting = (props = {}) => { 12 const InstructSetSetting = (props = {}) => {
14 const { instructSetSettingVisible } = props; 13 const { instructSetSettingVisible } = props;