待办区域数据剥离
This commit is contained in:
		
							parent
							
								
									83c81c9864
								
							
						
					
					
						commit
						495b1836c9
					
				@ -177,6 +177,7 @@ class Home extends React.Component {
 | 
				
			|||||||
      timeNow: "上午好",
 | 
					      timeNow: "上午好",
 | 
				
			||||||
      workData: [],
 | 
					      workData: [],
 | 
				
			||||||
      workTotal: "",
 | 
					      workTotal: "",
 | 
				
			||||||
 | 
					      workTotalData:[],
 | 
				
			||||||
      tableKey: "1",
 | 
					      tableKey: "1",
 | 
				
			||||||
      formVisible: false,
 | 
					      formVisible: false,
 | 
				
			||||||
      noticeTitle: "",
 | 
					      noticeTitle: "",
 | 
				
			||||||
@ -471,7 +472,7 @@ class Home extends React.Component {
 | 
				
			|||||||
    }
 | 
					    }
 | 
				
			||||||
  };
 | 
					  };
 | 
				
			||||||
  workClick = (e) => {
 | 
					  workClick = (e) => {
 | 
				
			||||||
    this.showEditModal(
 | 
					    this.showTableEditModal(
 | 
				
			||||||
      e.SOURCE_DATA_ID,
 | 
					      e.SOURCE_DATA_ID,
 | 
				
			||||||
      e.SOURCE_FORMCODE,
 | 
					      e.SOURCE_FORMCODE,
 | 
				
			||||||
      e.ID,
 | 
					      e.ID,
 | 
				
			||||||
@ -497,6 +498,44 @@ class Home extends React.Component {
 | 
				
			|||||||
      return "已办";
 | 
					      return "已办";
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
  }
 | 
					  }
 | 
				
			||||||
 | 
					  showTableEditModal= (dataId, formCode, TaskID, title, taskCode) => {
 | 
				
			||||||
 | 
					    // this.props.dispatch({
 | 
				
			||||||
 | 
					    //   type: "app/getDataByPost",
 | 
				
			||||||
 | 
					    //   url: "BI/BIController/getVersion",
 | 
				
			||||||
 | 
					    //   onComplete: (ret) => {
 | 
				
			||||||
 | 
					    //     if (ret > config.version) {
 | 
				
			||||||
 | 
					    //       window.localStorage.clear();
 | 
				
			||||||
 | 
					    //       message.success("清除成功,即将重新加载页面", 2, () => {
 | 
				
			||||||
 | 
					    //         setTimeout(() => window.location.reload(true), 500);
 | 
				
			||||||
 | 
					    //       });
 | 
				
			||||||
 | 
					    //     }
 | 
				
			||||||
 | 
					    //   },
 | 
				
			||||||
 | 
					    // });
 | 
				
			||||||
 | 
					    const newtmpData = {
 | 
				
			||||||
 | 
					      data: {
 | 
				
			||||||
 | 
					        id: dataId,
 | 
				
			||||||
 | 
					        TaskID: TaskID,
 | 
				
			||||||
 | 
					        onCancel: this.handleTableCancel,
 | 
				
			||||||
 | 
					        taskCode: taskCode,
 | 
				
			||||||
 | 
					        tableKey: this.state.tableKey,
 | 
				
			||||||
 | 
					        homeReload: true,
 | 
				
			||||||
 | 
					      },
 | 
				
			||||||
 | 
					      formCode: formCode,
 | 
				
			||||||
 | 
					    };
 | 
				
			||||||
 | 
					    this.setState(
 | 
				
			||||||
 | 
					      {
 | 
				
			||||||
 | 
					        noticeTitle: title,
 | 
				
			||||||
 | 
					        taskCode: taskCode,
 | 
				
			||||||
 | 
					        tmpData: newtmpData,
 | 
				
			||||||
 | 
					        currActivatedMenu: "",
 | 
				
			||||||
 | 
					      },
 | 
				
			||||||
 | 
					      () => {
 | 
				
			||||||
 | 
					        this.setState({
 | 
				
			||||||
 | 
					          formVisible: true,
 | 
				
			||||||
 | 
					        });
 | 
				
			||||||
 | 
					      }
 | 
				
			||||||
 | 
					    );
 | 
				
			||||||
 | 
					  };
 | 
				
			||||||
  showEditModal = (dataId, formCode, TaskID, title, taskCode) => {
 | 
					  showEditModal = (dataId, formCode, TaskID, title, taskCode) => {
 | 
				
			||||||
    // this.props.dispatch({
 | 
					    // this.props.dispatch({
 | 
				
			||||||
    //   type: "app/getDataByPost",
 | 
					    //   type: "app/getDataByPost",
 | 
				
			||||||
@ -550,6 +589,11 @@ class Home extends React.Component {
 | 
				
			|||||||
    this.getBaseData(1, this.state.overDataKey);
 | 
					    this.getBaseData(1, this.state.overDataKey);
 | 
				
			||||||
    this.clearData();
 | 
					    this.clearData();
 | 
				
			||||||
  };
 | 
					  };
 | 
				
			||||||
 | 
					  handleTableCancel= () => {
 | 
				
			||||||
 | 
					    // 退出弹窗
 | 
				
			||||||
 | 
					    this.getBaseData(1, this.state.tableKey,5);
 | 
				
			||||||
 | 
					    this.clearData();
 | 
				
			||||||
 | 
					  };
 | 
				
			||||||
  closeModal = () => {
 | 
					  closeModal = () => {
 | 
				
			||||||
    this.setState({
 | 
					    this.setState({
 | 
				
			||||||
      formVisible: false,
 | 
					      formVisible: false,
 | 
				
			||||||
@ -594,10 +638,22 @@ class Home extends React.Component {
 | 
				
			|||||||
      onlyData: false,
 | 
					      onlyData: false,
 | 
				
			||||||
      onComplete: (ret) => {
 | 
					      onComplete: (ret) => {
 | 
				
			||||||
        if (ret && ret.IsSuccessful && ret.Data.newData) {
 | 
					        if (ret && ret.IsSuccessful && ret.Data.newData) {
 | 
				
			||||||
 | 
					          if(limit == 5) {
 | 
				
			||||||
            this.setState({
 | 
					            this.setState({
 | 
				
			||||||
              workData: ret.Data.newData,
 | 
					              workData: ret.Data.newData,
 | 
				
			||||||
            workTotal: ret.Data,
 | 
					              // workTotal: ret.Data,
 | 
				
			||||||
            });
 | 
					            });
 | 
				
			||||||
 | 
					          }else{
 | 
				
			||||||
 | 
					            this.setState({
 | 
				
			||||||
 | 
					              // workData: ret.Data.newData,
 | 
				
			||||||
 | 
					              workTotal: ret.Data,
 | 
				
			||||||
 | 
					              workTotalData:ret.Data.newData,
 | 
				
			||||||
 | 
					            });
 | 
				
			||||||
 | 
					          }
 | 
				
			||||||
 | 
					          // this.setState({
 | 
				
			||||||
 | 
					          //   workData: ret.Data.newData,
 | 
				
			||||||
 | 
					          //   workTotal: ret.Data,
 | 
				
			||||||
 | 
					          // });
 | 
				
			||||||
        }
 | 
					        }
 | 
				
			||||||
      },
 | 
					      },
 | 
				
			||||||
    });
 | 
					    });
 | 
				
			||||||
@ -1480,7 +1536,7 @@ class Home extends React.Component {
 | 
				
			|||||||
            </Form>
 | 
					            </Form>
 | 
				
			||||||
            <Table
 | 
					            <Table
 | 
				
			||||||
              // rowSelection={rowSelection}
 | 
					              // rowSelection={rowSelection}
 | 
				
			||||||
              dataSource={this.state.workData}
 | 
					              dataSource={this.state.workTotalData}
 | 
				
			||||||
              columns={this.state.searchColumns}
 | 
					              columns={this.state.searchColumns}
 | 
				
			||||||
              onChange={(num) =>
 | 
					              onChange={(num) =>
 | 
				
			||||||
                this.getBaseInfoData(num, this.state.currentpageIndex, null)
 | 
					                this.getBaseInfoData(num, this.state.currentpageIndex, null)
 | 
				
			||||||
@ -1558,7 +1614,7 @@ class Home extends React.Component {
 | 
				
			|||||||
              </Row>
 | 
					              </Row>
 | 
				
			||||||
            </Form>
 | 
					            </Form>
 | 
				
			||||||
            <Table
 | 
					            <Table
 | 
				
			||||||
              dataSource={this.state.workData}
 | 
					              dataSource={this.state.workTotalData}
 | 
				
			||||||
              columns={this.state.searchColumns}
 | 
					              columns={this.state.searchColumns}
 | 
				
			||||||
              onChange={(num) =>
 | 
					              onChange={(num) =>
 | 
				
			||||||
                this.getBaseInfoData(num, this.state.currentpageIndex, null)
 | 
					                this.getBaseInfoData(num, this.state.currentpageIndex, null)
 | 
				
			||||||
 | 
				
			|||||||
		Loading…
	
		Reference in New Issue
	
	Block a user