提交 17294f9c authored 作者: 钟是志's avatar 钟是志

30041 学籍管理--班级信息,,,点击空白

上级 ca3a6264
...@@ -39,12 +39,19 @@ class Index extends React.Component { ...@@ -39,12 +39,19 @@ class Index extends React.Component {
getFormDetail = (workId) => { getFormDetail = (workId) => {
const { dataBaseId } = this.state; const { dataBaseId } = this.state;
service.getFormDetail(workId).then((response) => { service.getFormDetail(workId)
.then((response) => {
if (typeof response.unifiedServicePatternModel === 'undefined') { if (typeof response.unifiedServicePatternModel === 'undefined') {
return false; return false;
} }
destructionFunc.destructionGetDetail(response).then((x) => { destructionFunc.destructionGetDetail(response)
const { addFields, tableInfo, allConfigSetInfo, searchCondition } = x; .then((x) => {
const {
addFields,
tableInfo,
allConfigSetInfo,
searchCondition
} = x;
this.setState( this.setState(
{ {
addFields, addFields,
...@@ -61,8 +68,17 @@ class Index extends React.Component { ...@@ -61,8 +68,17 @@ class Index extends React.Component {
}; };
giveDetailColumns = () => { giveDetailColumns = () => {
const { columns, workId, dataBaseId, addFields, tableInfo } = this.state; const {
const { showPrint, routerConfig } = this.props; columns,
workId,
dataBaseId,
addFields,
tableInfo
} = this.state;
const {
showPrint,
routerConfig
} = this.props;
const process_status = columns.find((x) => { const process_status = columns.find((x) => {
return x.name === 'process_status'; return x.name === 'process_status';
}); });
...@@ -101,7 +117,8 @@ class Index extends React.Component { ...@@ -101,7 +117,8 @@ class Index extends React.Component {
getColumn = () => { getColumn = () => {
const { workId } = this.state; const { workId } = this.state;
service.getColumns(workId).then((response) => { service.getColumns(workId)
.then((response) => {
if (!response || !Array.isArray(response)) { if (!response || !Array.isArray(response)) {
response = []; response = [];
} }
...@@ -137,7 +154,8 @@ class Index extends React.Component { ...@@ -137,7 +154,8 @@ class Index extends React.Component {
if (workId) { if (workId) {
this.getColumn(); this.getColumn();
} else { } else {
service.getId(pathname).then((x) => { service.getId(pathname)
.then((x) => {
this.setState( this.setState(
{ {
workId: x.workId, workId: x.workId,
...@@ -171,6 +189,18 @@ class Index extends React.Component { ...@@ -171,6 +189,18 @@ class Index extends React.Component {
if (!workId) { if (!workId) {
return null; return null;
} }
if (Array.isArray(columns)){
let d = [];
for (let item of columns) {
if (item.dataIndex !== 'operationDiy') {
d.push({
key: item.dataIndex,
title: item.title,
});
}
}
console.log(JSON.stringify(d));
}
return ( return (
<AuditPage <AuditPage
hasBatchAudit={hasBatchAudit} hasBatchAudit={hasBatchAudit}
...@@ -192,5 +222,5 @@ class Index extends React.Component { ...@@ -192,5 +222,5 @@ class Index extends React.Component {
export default function Pr(props) { export default function Pr(props) {
const { routerConfig } = useContext(CreateC); const { routerConfig } = useContext(CreateC);
return <Index {...props} routerConfig={routerConfig} />; return <Index {...props} routerConfig={routerConfig}/>;
} }
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论