提交 0f9cd389 authored 作者: 钟是志's avatar 钟是志

Merge remote-tracking branch 'origin/master'

...@@ -13,6 +13,7 @@ import styles from './index.less'; ...@@ -13,6 +13,7 @@ import styles from './index.less';
export default function HistoryForm(props) { export default function HistoryForm(props) {
const { data, isNewForm } = props; const { data, isNewForm } = props;
console.log(data,isNewForm)
return ( return (
<div> <div>
{data.hisTaskForm.formKeys && data.hisTaskForm.formKeys.length > 0 {data.hisTaskForm.formKeys && data.hisTaskForm.formKeys.length > 0
......
import React, { useState, useEffect } from 'react'; import React, { useState, useEffect } from 'react';
import { Form, Spin } from 'antd'; import { Form, Spin } from 'antd';
import { router } from 'umi';
import Shell from '@/baseComponent/Shell'; import Shell from '@/baseComponent/Shell';
import HistoryForm from '@/webPublic/FormInsertDiy/HistoryForm'; import HistoryForm from '@/webPublic/FormInsertDiy/HistoryForm';
import { getHistoryFormDetail } from '../../Services'; import { getHistoryFormDetail } from '../../Services';
import withGoBack from '@/highOrderComponent/withGoBack'; import withGoBack from '@/highOrderComponent/withGoBack';
import SubmitButton from '@/webPublic/one_stop_public/AffairButton/SumbitButton';
import { ModalInfo } from '@/baseComponent/Modal'; import { ModalInfo } from '@/baseComponent/Modal';
import { router } from 'umi'; import AuditButton from '../AuditButton';
// 查看详情, 传申报数据的code // 查看详情, 传申报数据的code
let DetailPage = ({ form, code, appId }) => { let DetailPage = ({ form, code }) => {
const [data, setData] = useState(null); const [data, setData] = useState(null);
const [loading, setLoading] = useState(false); const [loading, setLoading] = useState(false);
...@@ -39,9 +39,11 @@ let DetailPage = ({ form, code, appId }) => { ...@@ -39,9 +39,11 @@ let DetailPage = ({ form, code, appId }) => {
isNewForm={data.isSecond ?? false} // 是否渲染需要当前用户填写的审核表单 为false只会渲染历史回显表单 isNewForm={data.isSecond ?? false} // 是否渲染需要当前用户填写的审核表单 为false只会渲染历史回显表单
/> />
{data.isSecond && ( {data.isSecond && (
<div style={{ padding: 16, textAlign: 'center' }}> <AuditButton
<SubmitButton form={form} appId={appId} text="提交" callback={submitCb} /> data={data} // 为 'affair/getIdFormDetail' 接口请求到的数据
</div> callback={submitCb} // 提交完成后回调函数
form={form} // form表单控件
/>
)} )}
</> </>
)} )}
......
...@@ -890,9 +890,7 @@ class FormList extends React.Component { ...@@ -890,9 +890,7 @@ class FormList extends React.Component {
if(document.querySelector('#previewDiv')){ if(document.querySelector('#previewDiv')){
isMobile = true isMobile = true
} }
let showDiv = document.querySelector('#mobelDiv')? let showDiv = document.querySelector('#mobelDiv')&&document.querySelector('#mobelDiv')?.parentNode.clientWidth
document.querySelector('#mobelDiv')?.parentNode.clientWidth
:1100
const parentMethods = { const parentMethods = {
handleAdd: this.handleAdd, handleAdd: this.handleAdd,
handleModalVisible: this.handleModalVisible, handleModalVisible: this.handleModalVisible,
...@@ -968,6 +966,9 @@ class FormList extends React.Component { ...@@ -968,6 +966,9 @@ class FormList extends React.Component {
if(isEmpty(item)){ if(isEmpty(item)){
return item return item
} }
if(index === this.columns.length-1){
return item
}
let width = item.width?item.width:150 let width = item.width?item.width:150
if(!item.width){ if(!item.width){
item.width = 150 item.width = 150
...@@ -980,7 +981,6 @@ class FormList extends React.Component { ...@@ -980,7 +981,6 @@ class FormList extends React.Component {
){ ){
this.columns[this.columns.length-2].width = '' this.columns[this.columns.length-2].width = ''
AllWidth+=100 AllWidth+=100
// this.columns.push({})
} }
} }
const xxxx = <><Card bordered={false} bodyStyle={{padding:0}}> const xxxx = <><Card bordered={false} bodyStyle={{padding:0}}>
...@@ -1036,7 +1036,7 @@ class FormList extends React.Component { ...@@ -1036,7 +1036,7 @@ class FormList extends React.Component {
<div <div
id='mobelDiv' id='mobelDiv'
style={{ style={{
overflow:'auto', overflow:'hidden',
width: isMobile?showMobileDiv:showDiv, width: isMobile?showMobileDiv:showDiv,
height: '100%' height: '100%'
}} }}
...@@ -1044,7 +1044,8 @@ class FormList extends React.Component { ...@@ -1044,7 +1044,8 @@ class FormList extends React.Component {
<div <div
> >
<StandardTable {
showDiv&&<StandardTable
showHeader={this.props.showHeader!=null?this.props.showHeader:true} showHeader={this.props.showHeader!=null?this.props.showHeader:true}
noSelectRow={rights==null|| !rights.includes('delete') } noSelectRow={rights==null|| !rights.includes('delete') }
rowKey="id" rowKey="id"
...@@ -1057,6 +1058,7 @@ class FormList extends React.Component { ...@@ -1057,6 +1058,7 @@ class FormList extends React.Component {
onChange={this.handleStandardTableChange} onChange={this.handleStandardTableChange}
loading={this.props.loading} loading={this.props.loading}
/> />
}
</div> </div>
</div> </div>
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论