还原
This commit is contained in:
parent
99e14d9f6f
commit
827ce856f7
@ -1,19 +1,11 @@
|
|||||||
import React from 'react';
|
import React from 'react'
|
||||||
import { message } from 'antd/lib/index';
|
import { message } from "antd/lib/index";
|
||||||
import {
|
import { getPropertyData, extendInclude, extendRule, getDataFieldValue, setDataFieldValue, initFilter, guid } from "../../utils/common";
|
||||||
getPropertyData,
|
|
||||||
extendInclude,
|
|
||||||
extendRule,
|
|
||||||
getDataFieldValue,
|
|
||||||
setDataFieldValue,
|
|
||||||
initFilter,
|
|
||||||
guid,
|
|
||||||
} from '../../utils/common';
|
|
||||||
import moment from 'moment';
|
import moment from 'moment';
|
||||||
import storage from '../../utils/storage';
|
import storage from '../../utils/storage'
|
||||||
import config from '../../config.js';
|
import config from "../../config.js"
|
||||||
import { Button, Row, Col, Form, Input, Select, Upload, Icon, Modal, Spin, Table } from 'antd';
|
import { Button, Row, Col, Form, Input, Select, Upload, Icon, Modal, Spin,Table } from 'antd';
|
||||||
import { T } from 'antd/lib/upload/utils';
|
import { T } from "antd/lib/upload/utils";
|
||||||
/**
|
/**
|
||||||
* @return {string}
|
* @return {string}
|
||||||
*/
|
*/
|
||||||
@ -21,13 +13,11 @@ import { T } from 'antd/lib/upload/utils';
|
|||||||
|
|
||||||
export default {
|
export default {
|
||||||
onBeforeEdit(params) {
|
onBeforeEdit(params) {
|
||||||
const { isNew, dispatch, login, setFieldValueByBatch, setFieldEditable, setFieldVisible, stateData } = params
|
const { isNew, dispatch, login, setFieldValueByBatch, setFieldEditable, setFieldVisible,stateData } = params ? params : {};
|
||||||
? params
|
|
||||||
: {};
|
|
||||||
},
|
},
|
||||||
handleRenderHeadControl(params) {
|
handleRenderHeadControl(params) {
|
||||||
if (params.colConfig.field === 'Nav_DepartmentUser') {
|
if (params.colConfig.field === 'Nav_DepartmentUser') {
|
||||||
const columns = [
|
const columns =[
|
||||||
// { title: '序号', dataIndex: 'ROW_NO',
|
// { title: '序号', dataIndex: 'ROW_NO',
|
||||||
// render: (value, row, index) => {
|
// render: (value, row, index) => {
|
||||||
// if(!value)
|
// if(!value)
|
||||||
@ -36,43 +26,41 @@ export default {
|
|||||||
// }
|
// }
|
||||||
// }
|
// }
|
||||||
// },
|
// },
|
||||||
{ title: '员工编号', dataIndex: 'Nav_User.CODE', width: 200, align: 'left' },
|
{ title: '员工编号', dataIndex: 'Nav_User.CODE' , width: 200,align:"left"},
|
||||||
{ title: '员工名称', dataIndex: 'Nav_User.NAME', width: 200, align: 'left' },
|
{ title: '员工名称', dataIndex: 'Nav_User.NAME' , width: 200,align:"left"},
|
||||||
{ title: '岗位', dataIndex: 'Nav_User.Nav_Person.Nav_Post.NAME', width: 200, align: 'left' },
|
{ title: '岗位', dataIndex: 'Nav_User.Nav_Person.Nav_Post.NAME' , width: 200,align:"left"},
|
||||||
{ title: '角色', dataIndex: 'Nav_User.Nav_ApproveRole.NAME', width: 200, align: 'left' },
|
{ title: '角色', dataIndex: 'Nav_User.Nav_ApproveRole.NAME' , width: 200,align:"left"},
|
||||||
// {
|
{
|
||||||
// title: '启用标志', dataIndex: 'Nav_User.ENABLE_STATUS', render: (value, row, index) => {
|
title: '启用标志', dataIndex: 'Nav_User.ENABLE_STATUS', render: (value, row, index) => {
|
||||||
// if(value === 0)
|
if(value === 0)
|
||||||
// {
|
{
|
||||||
// return "启用"
|
return "启用"
|
||||||
// }
|
}
|
||||||
// if(value === 1)
|
if(value === 1)
|
||||||
// {
|
{
|
||||||
// return "禁用"
|
return "禁用"
|
||||||
// }
|
}
|
||||||
// }
|
}
|
||||||
// }
|
}
|
||||||
];
|
]
|
||||||
const style = { width: '62%', height: '150px', position: 'fixed', top: '400px' };
|
const style = { width: '62%', height: '150px', position: 'fixed', top: '400px'}
|
||||||
const data = params.record.Nav_DepartmentUser;
|
const data = params.record.Nav_DepartmentUser;
|
||||||
const paginationConfig = {
|
const paginationConfig = {
|
||||||
pageSizeOptions: ['5', '10', '20', '50', '100'],
|
pageSizeOptions: ['5', '10', '20', '50', '100'],
|
||||||
// current: this.state.loadParamJson.PageIndex,
|
// current: this.state.loadParamJson.PageIndex,
|
||||||
pageSize: 5,
|
pageSize: 5,
|
||||||
total: params.record.Nav_DepartmentUser?.length,
|
total: params.record.Nav_DepartmentUser?.length,
|
||||||
showSizeChanger: true,
|
showSizeChanger: true,
|
||||||
size: 'small',
|
size: 'small',
|
||||||
position: 'top',
|
position:'top',
|
||||||
showTotal: () => `共 ${params.record.Nav_DepartmentUser?.length} 条`,
|
showTotal: () => `共 ${params.record.Nav_DepartmentUser?.length} 条`
|
||||||
};
|
};
|
||||||
return (
|
return <>
|
||||||
<>
|
<div style={{margin:"360px 0 100px 0", height: '600px', position: 'fixed',width: '62%',}}>
|
||||||
<div style={{}}>
|
{/* pagination={paginationConfig} scroll={{y:150}} */}
|
||||||
{/* pagination={paginationConfig} scroll={{y:150}} */}
|
<Table size='small' columns={columns} dataSource={data} pagination={false} scroll={{ y: 250 }} />
|
||||||
<Table size="small" columns={columns} dataSource={data} pagination={false} scroll={{ x: 900, y: 250 }} />
|
</div>
|
||||||
</div>
|
|
||||||
</>
|
</>
|
||||||
);
|
|
||||||
}
|
}
|
||||||
},
|
}
|
||||||
};
|
}
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user