Commit ec722cbb12cf94c17c4bef17689dc6a3bef010ac

Authored by chenxt
1 parent 3a596bfc

下拉框表格刷新

src/components/Common/CommonComponent/index.js
... ... @@ -803,11 +803,11 @@ export default class CommonComponent extends Component {
803 803 },
804 804 };
805 805 });
806   -
807 806 return (
808 807 <Option key="" className="select-table-option">
809 808 <div style={{ width: scrollX + 8, maxWidth: 'calc(100vw - 16px)', minWidth: '100%' }}>
810 809 <Table
  810 + key={Math.random()}
811 811 size="small"
812 812 className="select-table"
813 813 rowKey="sId"
... ...
src/mes/scheduledTasks/machineTasks/index.js
... ... @@ -539,7 +539,7 @@ const MachineTasks = baseProps =&gt; {
539 539 });
540 540 }
541 541 // 顶部表格配置
542   - const tableProps = {
  542 + let tableProps = {
543 543 ...commonBusiness.getTableTypes("slave0", props),
544 544 // data: [{ sId: "123" }],
545 545 tableProps: {
... ... @@ -578,10 +578,15 @@ const MachineTasks = baseProps =&gt; {
578 578 onTableBtnClick: item => {
579 579 props.onTableBtnClick(item);
580 580 },
581   - tableBtnsWidth: "200px",
  581 + tableBtnsWidth: "200px",
582 582 fixedHeight: "335px",
583 583 onCopyTo: handleCopyTo
584 584 };
  585 + const record = tableProps?.data?.[0] || {}
  586 + // 如果bManual为true的时候 操作栏加长
  587 + if (record && record.bManual) {
  588 + tableProps.tableBtnsWidth = '300px'
  589 + }
585 590 // 全部按钮事件
586 591 const tableAll = () => {
587 592 setSSrcNo("");
... ...