系统管理页面逻辑测试

This commit is contained in:
red-deng-deng 2021-11-15 13:48:17 +08:00
parent 2bf5dd19aa
commit ea7a304c9c
14 changed files with 184 additions and 64 deletions

View File

@ -125,10 +125,17 @@
margin-right: 0px!important;
}
.zent-card-body[data-zv="9.11.0"]{
max-height: 700px!important;
max-height: 440px!important;
overflow-y: scroll;
}
@media screen and (min-width: 1700px) {
.zent-card-body[data-zv="9.11.0"]{
max-height: 650px!important;
overflow-y: scroll;
}
}
.zent-form-error[data-zv="9.11.0"]{
color: #ed3b3b!important;
}

View File

@ -6,18 +6,21 @@ import React from 'react'
import Menu from "../menu/main.js"
export default class filterSelect extends React.Component {
constructor(props) {
static defaultProps = {
required:'*'
}
constructor(props) {
super(props);
this.state = {
}
}
render() {
const {labelname,prop,labelwidth,myClassName,id} = this.props
const {labelname,prop,labelwidth,myClassName,id,required} = this.props
return (
<div className ={ myClassName ? myClassName + " form-Item" :"form-Item"} id={id ? id : null} >
<div className="form-label" style={{width: labelwidth ? labelwidth : "180px" }}>
{labelname}
{labelname}
{required?<span className="mustwrite">*</span>:null}
</div>
<div className="form-compontent">
{this.props.children}

View File

@ -0,0 +1,6 @@
.mustwrite{
color: #ed3b3b;
margin-left: 2px;
font-weight: bold;
font-size: 16px;
}

View File

@ -71,7 +71,8 @@
}
.tfoot.hide {
visibility: hidden;
/* visibility: hidden; */
display: none;
}

View File

@ -296,7 +296,7 @@ export default class acclist extends React.Component{
}
{/* 进行 */}
{
this.state.activepage==0? <Grid
this.state.activepage==7? <Grid
spliteColor={'#fff'}
tableData={this.state.distdata11}
Column={Column}
@ -340,7 +340,7 @@ export default class acclist extends React.Component{
}
{/* 暂停 */}
{
this.state.activepage==0? <Grid
this.state.activepage==166? <Grid
spliteColor={'#fff'}
tableData={this.state.distdata2}
Column={Column}
@ -428,7 +428,7 @@ export default class acclist extends React.Component{
}
{/* 已作废 */}
{
this.state.activepage==0? <Grid
this.state.activepage==5? <Grid
spliteColor={'#fff'}
tableData={this.state.distdata4}
Column={Column}

View File

@ -1,5 +1,10 @@
.viewbody{
width: 100%;
height: 100%;
overflow-y: scroll;
}
.view{
max-width: 1520px;
min-width: 1248px;
margin: 0 auto;
min-width: 1248px;
margin: 24px auto;
}

View File

@ -13,11 +13,14 @@ export default class App extends React.Component {
}
render() {
return (
<div className="viewbody">
<div className="view">
<Statistics/>
<Advertisement/>
<Echarts/>
</div>
</div>
);
}
}

View File

@ -11,7 +11,7 @@
width: 100px;
}
.zent-form-actions{
margin-top: 150px!important;
margin-top: 50px!important;
}
#accadd .zent-form-horizontal[data-zv="9.11.0"] .zent-form-label{
justify-content: flex-start;

View File

@ -5,7 +5,7 @@ import Ipt from "../../../../../components/input/main"
import Form from "../../../../../components/form/main"
import FormItem from "../../../../../components/form-item/main"
import "../../../../../assets/comm.css"
import {Select,Button,ImageUpload ,onUpload} from "zent"
import {Select,Button,ImageUpload ,onUpload,Sweetalert} from "zent"
import Bus from "../../../../../assets/eventBus.js"
export default class adduserinfo extends React.Component{
constructor(props){
@ -21,7 +21,7 @@ export default class adduserinfo extends React.Component{
post:"",
station:"",
},
}
}
}
componentDidMount(e){
@ -66,18 +66,19 @@ export default class adduserinfo extends React.Component{
}
cancel(){
let model2 = { //数据模型不可少
account:"",
phone:"",
pwd:"",
name:"",
company:"",
deparment:"",
post:"",
station:"",
}
this.setState({model:model2});
this.refs.form1.cancel();
//取消二次弹出框
Sweetalert.confirm({
type:'warning',
closeBtn:true,
title:'确认操作',
content: <p>是否取消本次新增</p>,
onConfirm:()=>{
window.history.back()
},
onCancel: this.onCancel,
className:'questModal',
parentComponent: this
});
}
render(){
const options = [
@ -111,10 +112,11 @@ export default class adduserinfo extends React.Component{
],
pwd:[
{ type: "required", message: "请输入密码"},
{ type: "regExp", message: "格式不对",reg:"^[1][3,5,7,8][0-9]\\d{8}$"}
{ type: "regExp", message: "6-16位字符,数字+字母组成(字母区分大小写)",reg:"^(?![0-9]+$)(?![a-zA-Z]+$)[0-9A-Za-z]{6,16}$"}
],
name: [
{ type: "required", message: "请输入真实姓名"},
{ type: "required", message: "请输入真实姓名"},
{type:'regExp',message:'2-16字汉字组成',reg:"[\u4e00-\u9fa5]{2,7}"}
],
company:[
{ type: "required", message: "请选择公司"},
@ -136,7 +138,7 @@ export default class adduserinfo extends React.Component{
return(
<div id="addaccinfo">
<Form model={this.state.model} rules={rules} ref="form1" className="addform">
<FormItem labelname="账号" prop="account" id="account">
<FormItem labelname="账号" prop="account" id="account">
<Ipt onChange={(e)=>{
let model2 = this.state.model;
model2.account = e;
@ -155,7 +157,7 @@ export default class adduserinfo extends React.Component{
</FormItem>
<FormItem labelname=" 手机号" prop="phone">
<Ipt onChange={(e)=>{
<Ipt kind="tel" onChange={(e)=>{
let model2 = this.state.model;
model2.phone = e;
this.setState({model:model2})
@ -167,7 +169,7 @@ export default class adduserinfo extends React.Component{
this.setState({model:model2})
}}
value={this.state.model.phone} placeholder={"请输入手机号"} labelWidth={'0px'} maxLength={12} height={'36px'} width={'520px'} alignment={'left'}/>
value={this.state.model.phone} placeholder={"请输入手机号"} labelWidth={'0px'} maxLength={11} height={'36px'} width={'520px'} alignment={'left'}/>
</FormItem>
<FormItem labelname="密码" prop="pwd">
<Ipt onChange={(e)=>{
@ -181,7 +183,7 @@ export default class adduserinfo extends React.Component{
model2.pwd = "";
this.setState({model:model2})
}}
value={this.state.model.pwd} placeholder={"请输入密码"} labelWidth={'0px'} maxLength={12} height={'36px'} width={'520px'} alignment={'left'}/>
value={this.state.model.pwd} placeholder={"请输入密码"} labelWidth={'0px'} maxLength={16} height={'36px'} width={'520px'} alignment={'left'}/>
</FormItem>
<FormItem labelname="真实姓名" prop="name">
<Ipt onChange={(e)=>{
@ -196,7 +198,7 @@ export default class adduserinfo extends React.Component{
this.setState({model:model2})
}}
value={this.state.model.name} placeholder={"请输入真实姓名"} labelWidth={'0px'} maxLength={12} height={'36px'} width={'520px'} alignment={'left'}/>
value={this.state.model.name} placeholder={"请输入真实姓名"} labelWidth={'0px'} maxLength={16} height={'36px'} width={'520px'} alignment={'left'}/>
</FormItem>
<FormItem id="company" labelname="岗位" prop="company" myClassName="sel1">
<Select options={options} clearable placeholder="请选择公司" value={this.state.model.company} onChange={(e)=>{
@ -242,7 +244,7 @@ export default class adduserinfo extends React.Component{
className="zent-image-upload-demo"
maxSize={5 * 1024 * 1024}
tips="建议尺寸 30*30图片不超过 500kb"
maxAmount={1}
maxAmount={1}
onChange={this.onUploadChange}
onUpload={this.onUpload}
/>

View File

@ -22,7 +22,6 @@
margin: 0 auto;
height: 100px;
border-radius: 50px;
background: #00bfff!important;
// overflow: hidden;
.zent-image-upload-trigger[data-zv="9.11.0"]{
width: 100px;

View File

@ -15,12 +15,12 @@ const Column = [
prop:'username',
className: 'name',
type: "normal",
width:'200px'
width:'10%'
}, {
title: '手机号',
prop:'phone',
name: 'uv',
width:'300px',
width:'10%',
type: "normal",
}, {
title: '角色',
@ -28,7 +28,7 @@ const Column = [
prop:'role',
type: "normal",
defaultText: 0,
width:'auto'
width:'10%'
},
{
title: '岗位',
@ -36,7 +36,7 @@ const Column = [
type: "normal",
prop:'post',
defaultText: 'PM',
width:'auto'
width:'10%'
},
{
title: '姓名',
@ -44,12 +44,12 @@ const Column = [
type: "normal",
prop:'name',
defaultText: 0,
width:'auto',
width:'10%',
type: "normal",
},
{
title: '状态',
width:'auto',
width:'10%',
type: "slot",
name:'name',
prop:'status'
@ -59,7 +59,7 @@ const Column = [
name: 'time',
prop:'time',
defaultText: 0,
width:'auto',
width:'20%',
type: "normal",
},
@ -68,7 +68,7 @@ const Column = [
prop: 'opearo',
name: 'opearo',
type: "slot",
width:'130px',
width:'20%',
},
];
export default class acclist extends React.Component{
@ -77,12 +77,70 @@ export default class acclist extends React.Component{
this.state={
pageSize: 10,
checkedSmall: true,
tableHeight:600,
current: 2,
visible: false,
tabList:[{title:"账号列表"}],
accoutdata:[{username:'红噔噔',phone:'13541778893',role:'管理员',status:true,name:'红噔噔'
,time:'2021-00-04 13:48:45',post:'技术',opearo:'红噔噔'},{username:'红噔噔',phone:'13541778893',role:'管理员',status:true,name:'红噔噔'
,time:'2021-00-04 13:48:45',post:'技术',opearo:'红噔噔'},{username:'红噔噔',phone:'13541778893',role:'管理员',status:true,name:'红噔噔'
,time:'2021-00-04 13:48:45',post:'技术',opearo:'红噔噔'},{username:'红噔噔',phone:'13541778893',role:'管理员',status:true,name:'红噔噔'
,time:'2021-00-04 13:48:45',post:'技术',opearo:'红噔噔'},{username:'红噔噔',phone:'13541778893',role:'管理员',status:true,name:'红噔噔'
,time:'2021-00-04 13:48:45',post:'技术',opearo:'红噔噔'},{username:'红噔噔',phone:'13541778893',role:'管理员',status:true,name:'红噔噔'
,time:'2021-00-04 13:48:45',post:'技术',opearo:'红噔噔'},{username:'红噔噔',phone:'13541778893',role:'管理员',status:true,name:'红噔噔'
,time:'2021-00-04 13:48:45',post:'技术',opearo:'红噔噔'},{username:'红噔噔',phone:'13541778893',role:'管理员',status:true,name:'红噔噔'
,time:'2021-00-04 13:48:45',post:'技术',opearo:'红噔噔'},{username:'红噔噔',phone:'13541778893',role:'管理员',status:true,name:'红噔噔'
,time:'2021-00-04 13:48:45',post:'技术',opearo:'红噔噔'},{username:'红噔噔',phone:'13541778893',role:'管理员',status:true,name:'红噔噔'
,time:'2021-00-04 13:48:45',post:'技术',opearo:'红噔噔'},{username:'红噔噔',phone:'13541778893',role:'管理员',status:true,name:'红噔噔'
,time:'2021-00-04 13:48:45',post:'技术',opearo:'红噔噔'},{username:'红噔噔',phone:'13541778893',role:'管理员',status:true,name:'红噔噔'
,time:'2021-00-04 13:48:45',post:'技术',opearo:'红噔噔'},{username:'红噔噔',phone:'13541778893',role:'管理员',status:true,name:'红噔噔'
,time:'2021-00-04 13:48:45',post:'技术',opearo:'红噔噔'},{username:'红噔噔',phone:'13541778893',role:'管理员',status:true,name:'红噔噔'
,time:'2021-00-04 13:48:45',post:'技术',opearo:'红噔噔'},{username:'红噔噔',phone:'13541778893',role:'管理员',status:true,name:'红噔噔'
,time:'2021-00-04 13:48:45',post:'技术',opearo:'红噔噔'},{username:'红噔噔',phone:'13541778893',role:'管理员',status:true,name:'红噔噔'
,time:'2021-00-04 13:48:45',post:'技术',opearo:'红噔噔'},{username:'红噔噔',phone:'13541778893',role:'管理员',status:true,name:'红噔噔'
,time:'2021-00-04 13:48:45',post:'技术',opearo:'红噔噔'},{username:'红噔噔',phone:'13541778893',role:'管理员',status:true,name:'红噔噔'
,time:'2021-00-04 13:48:45',post:'技术',opearo:'红噔噔'},{username:'红噔噔',phone:'13541778893',role:'管理员',status:true,name:'红噔噔'
,time:'2021-00-04 13:48:45',post:'技术',opearo:'红噔噔'},{username:'红噔噔',phone:'13541778893',role:'管理员',status:true,name:'红噔噔'
,time:'2021-00-04 13:48:45',post:'技术',opearo:'红噔噔'},{username:'红噔噔',phone:'13541778893',role:'管理员',status:true,name:'红噔噔'
,time:'2021-00-04 13:48:45',post:'技术',opearo:'红噔噔'},{username:'红噔噔',phone:'13541778893',role:'管理员',status:true,name:'红噔噔'
,time:'2021-00-04 13:48:45',post:'技术',opearo:'红噔噔'},{username:'红噔噔',phone:'13541778893',role:'管理员',status:true,name:'红噔噔'
,time:'2021-00-04 13:48:45',post:'技术',opearo:'红噔噔'},{username:'红噔噔',phone:'13541778893',role:'管理员',status:true,name:'红噔噔'
,time:'2021-00-04 13:48:45',post:'技术',opearo:'红噔噔'},{username:'红噔噔',phone:'13541778893',role:'管理员',status:true,name:'红噔噔'
,time:'2021-00-04 13:48:45',post:'技术',opearo:'红噔噔'},{username:'红噔噔',phone:'13541778893',role:'管理员',status:true,name:'红噔噔'
,time:'2021-00-04 13:48:45',post:'技术',opearo:'红噔噔'},{username:'红噔噔',phone:'13541778893',role:'管理员',status:true,name:'红噔噔'
,time:'2021-00-04 13:48:45',post:'技术',opearo:'红噔噔'},{username:'红噔噔',phone:'13541778893',role:'管理员',status:true,name:'红噔噔'
,time:'2021-00-04 13:48:45',post:'技术',opearo:'红噔噔'},{username:'红噔噔',phone:'13541778893',role:'管理员',status:true,name:'红噔噔'
,time:'2021-00-04 13:48:45',post:'技术',opearo:'红噔噔'},{username:'红噔噔',phone:'13541778893',role:'管理员',status:true,name:'红噔噔'
,time:'2021-00-04 13:48:45',post:'技术',opearo:'红噔噔'},{username:'红噔噔',phone:'13541778893',role:'管理员',status:true,name:'红噔噔'
,time:'2021-00-04 13:48:45',post:'技术',opearo:'红噔噔'},{username:'红噔噔',phone:'13541778893',role:'管理员',status:true,name:'红噔噔'
,time:'2021-00-04 13:48:45',post:'技术',opearo:'红噔噔'},{username:'红噔噔',phone:'13541778893',role:'管理员',status:true,name:'红噔噔'
,time:'2021-00-04 13:48:45',post:'技术',opearo:'红噔噔'},{username:'红噔噔',phone:'13541778893',role:'管理员',status:true,name:'红噔噔'
,time:'2021-00-04 13:48:45',post:'技术',opearo:'红噔噔'},{username:'红噔噔',phone:'13541778893',role:'管理员',status:true,name:'红噔噔'
,time:'2021-00-04 13:48:45',post:'技术',opearo:'红噔噔'},{username:'红噔噔',phone:'13541778893',role:'管理员',status:true,name:'红噔噔'
,time:'2021-00-04 13:48:45',post:'技术',opearo:'红噔噔'},{username:'红噔噔',phone:'13541778893',role:'管理员',status:true,name:'红噔噔'
,time:'2021-00-04 13:48:45',post:'技术',opearo:'红噔噔'},{username:'红噔噔',phone:'13541778893',role:'管理员',status:true,name:'红噔噔'
,time:'2021-00-04 13:48:45',post:'技术',opearo:'红噔噔'},{username:'红噔噔',phone:'13541778893',role:'管理员',status:true,name:'红噔噔'
,time:'2021-00-04 13:48:45',post:'技术',opearo:'红噔噔'},{username:'红噔噔',phone:'13541778893',role:'管理员',status:true,name:'红噔噔'
,time:'2021-00-04 13:48:45',post:'技术',opearo:'红噔噔'},{username:'红噔噔',phone:'13541778893',role:'管理员',status:true,name:'红噔噔'
,time:'2021-00-04 13:48:45',post:'技术',opearo:'红噔噔'},{username:'红噔噔',phone:'13541778893',role:'管理员',status:true,name:'红噔噔'
,time:'2021-00-04 13:48:45',post:'技术',opearo:'红噔噔'},{username:'红噔噔',phone:'13541778893',role:'管理员',status:true,name:'红噔噔'
,time:'2021-00-04 13:48:45',post:'技术',opearo:'红噔噔'},{username:'红噔噔',phone:'13541778893',role:'管理员',status:true,name:'红噔噔'
,time:'2021-00-04 13:48:45',post:'技术',opearo:'红噔噔'},{username:'红噔噔',phone:'13541778893',role:'管理员',status:true,name:'红噔噔'
,time:'2021-00-04 13:48:45',post:'技术',opearo:'红噔噔'},{username:'红噔噔',phone:'13541778893',role:'管理员',status:true,name:'红噔噔'
,time:'2021-00-04 13:48:45',post:'技术',opearo:'红噔噔'},{username:'红噔噔',phone:'13541778893',role:'管理员',status:true,name:'红噔噔'
,time:'2021-00-04 13:48:45',post:'技术',opearo:'红噔噔'},{username:'红噔噔',phone:'13541778893',role:'管理员',status:true,name:'红噔噔'
,time:'2021-00-04 13:48:45',post:'技术',opearo:'红噔噔'},{username:'红噔噔',phone:'13541778893',role:'管理员',status:true,name:'红噔噔'
,time:'2021-00-04 13:48:45',post:'技术',opearo:'红噔噔'},{username:'红噔噔',phone:'13541778893',role:'管理员',status:true,name:'红噔噔'
,time:'2021-00-04 13:48:45',post:'技术',opearo:'红噔噔'},{username:'红噔噔',phone:'13541778893',role:'管理员',status:true,name:'红噔噔'
,time:'2021-00-04 13:48:45',post:'技术',opearo:'红噔噔'},{username:'红噔噔',phone:'13541778893',role:'管理员',status:true,name:'红噔噔'
,time:'2021-00-04 13:48:45',post:'技术',opearo:'红噔噔'},{username:'红噔噔',phone:'13541778893',role:'管理员',status:true,name:'红噔噔'
,time:'2021-00-04 13:48:45',post:'技术',opearo:'红噔噔'},{username:'红噔噔',phone:'13541778893',role:'管理员',status:true,name:'红噔噔'
,time:'2021-00-04 13:48:45',post:'技术',opearo:'红噔噔'},{username:'红噔噔',phone:'13541778893',role:'管理员',status:true,name:'红噔噔'
,time:'2021-00-04 13:48:45',post:'技术',opearo:'红噔噔'},{username:'红噔噔',phone:'13541778893',role:'管理员',status:true,name:'红噔噔'
,time:'2021-00-04 13:48:45',post:'技术',opearo:'红噔噔'},{username:'红噔噔',phone:'13541778893',role:'管理员',status:true,name:'红噔噔'
,time:'2021-00-04 13:48:45',post:'技术',opearo:'红噔噔'},{username:'红噔噔',phone:'13541778893',role:'管理员',status:true,name:'红噔噔'
,time:'2021-00-04 13:48:45',post:'技术',opearo:'红噔噔'},{username:'红噔噔',phone:'13541778893',role:'管理员',status:true,name:'红噔噔'
,time:'2021-00-04 13:48:45',post:'技术',opearo:'红噔噔'},{username:'红噔噔',phone:'13541778893',role:'管理员',status:true,name:'红噔噔'
,time:'2021-00-04 13:48:45',post:'技术',opearo:'红噔噔'}]
}
}
@ -146,12 +204,22 @@ export default class acclist extends React.Component{
}
//重置密码
resetpwd(){
console.log('重置密码');
this.setState({visible:true});
}
setVisible = visible => {
this.setState({ visible });
};
pageChange(e){
console.log(e);
}
componentWillMount(){
this.setState({tableHeight:window.innerHeight-390});
}
sureFn(){
// this.setVisible(false)
// this.refs.midify.onSubmit();
console.log(this);
}
render(){
window.time='2021-11-13 14:02:02'
return(
@ -169,6 +237,7 @@ export default class acclist extends React.Component{
spliteColor={'#fff'}
tableData={this.state.accoutdata}
Column={Column}
maxheight={this.state.tableHeight}
isMultiple={false}
countbarVisible={false}
isSwitch={false}
@ -204,7 +273,7 @@ export default class acclist extends React.Component{
onClose={() => this.setVisible(false)}
footer={
<p>
<Button onClick={() => this.setVisible(false)} type="primary">确定</Button>,
<Button onClick={this.sureFn.bind(this)} type="primary">确定</Button>,
<Button onClick={() => this.setVisible(false)}>取消</Button>
</p>
@ -212,7 +281,7 @@ export default class acclist extends React.Component{
title="重置密码"
>
<p>
<Modifypwd/>
<Modifypwd ref="midify"/>
</p>
</Dialog>

View File

@ -9,6 +9,7 @@ import {
Validators,
FormNumberInputField,
FormInputField,
Button,
FormSingleUploadField,
} from 'zent';
@ -38,22 +39,19 @@ function equalsPassword(value, ctx) {
// return null;
}
function idLength(value) {
if (value.length !== 10 && value.length !== 15) {
return {
name: 'idLength',
message: '证件号码是10位或者15位数字',
};
}
}
function Modifypwd() {
const form = Form.useForm(FormStrategy.View);
const onSubmit = React.useCallback(form => {
// 在onSubmit触发之前表单已校验通过
const value = form.getValue();
}, []);
return (
<Form
form={form}
layout="horizontal"
scrollToError
onSubmit={onSubmit}
>
<FormInputField
name="password"

View File

@ -1,6 +1,6 @@
import ReactDOM from 'react-dom';
import React, { Component } from 'react';
import { Card,Button,Pagination} from 'zent';
import { Card,Button,Notify,Sweetalert} from 'zent';
import "./add.less"
import "../../../../assets/comm.css"
import Ipt from "../../../../components/input/main"
@ -18,11 +18,27 @@ export default class addrole extends React.Component{
}
}
cancel(){
window.history.go(-1)
sessionStorage.setItem('pathname2','/system/role-list')
Sweetalert.confirm({
type:'warning',
closeBtn:true,
title:'确认操作',
content: <p>是否取消本次新增</p>,
onConfirm:()=>{
console.log(window);
window.history.go(-1)
sessionStorage.setItem('pathname2','/system/role-list')
},
onCancel: this.onCancel,
className:'questModal',
parentComponent: this
});
}
submit(){
this.refs.roleform.validator();
if(this.refs.roletree.state.checkedKeys.length<1){
Notify.error('请至少选中一个模块权限')
}
}
render(){
const rules = {
@ -50,7 +66,7 @@ export default class addrole extends React.Component{
value={this.state.model.role} placeholder={"请输入角色"} labelWidth={'0px'} maxLength={12} height={'36px'} width={'520px'} alignment={'left'}/>
</FormItem>
<FormItem labelname="设置权限" prop="setrole" id="setrole">
<Tree/>
<Tree ref="roletree"/>
</FormItem>
</Form>
</Card>

View File

@ -36,10 +36,21 @@ export default class acclist extends React.Component{
constructor(props){
super(props)
this.state={
rolelist:[{role:'管理员',time:'2021-11-05 15:25:23'},{role:'管理员',time:'2021-11-05 15:25:23'},{role:'管理员',time:'2021-11-05 15:25:23'}],
tabList:[{title:"角色列表"}]
rolelist:[{role:'管理员',time:'2021-11-05 15:25:23'},{role:'管理员',time:'2021-11-05 15:25:23'},{role:'管理员',time:'2021-11-05 15:25:23'},
{role:'管理员',time:'2021-11-05 15:25:23'},{role:'管理员',time:'2021-11-05 15:25:23'},{role:'管理员',time:'2021-11-05 15:25:23'},{role:'管理员',time:'2021-11-05 15:25:23'},{role:'管理员',time:'2021-11-05 15:25:23'},{role:'管理员',time:'2021-11-05 15:25:23'}
,{role:'管理员',time:'2021-11-05 15:25:23'},{role:'管理员',time:'2021-11-05 15:25:23'},{role:'管理员',time:'2021-11-05 15:25:23'}
,{role:'管理员',time:'2021-11-05 15:25:23'},{role:'管理员',time:'2021-11-05 15:25:23'},{role:'管理员',time:'2021-11-05 15:25:23'}],
tabList:[{title:"角色列表"},{role:'管理员',time:'2021-11-05 15:25:23'},{role:'管理员',time:'2021-11-05 15:25:23'},{role:'管理员',time:'2021-11-05 15:25:23'},
{role:'管理员',time:'2021-11-05 15:25:23'},{role:'管理员',time:'2021-11-05 15:25:23'},{role:'管理员',time:'2021-11-05 15:25:23'},{role:'管理员',time:'2021-11-05 15:25:23'},{role:'管理员',time:'2021-11-05 15:25:23'},{role:'管理员',time:'2021-11-05 15:25:23'}
,{role:'管理员',time:'2021-11-05 15:25:23'},{role:'管理员',time:'2021-11-05 15:25:23'},{role:'管理员',time:'2021-11-05 15:25:23'}
,{role:'管理员',time:'2021-11-05 15:25:23'},{role:'管理员',time:'2021-11-05 15:25:23'},{role:'管理员',time:'2021-11-05 15:25:23'}],
tabList:[{title:"角色列表"}],
tableHeight:600,
}
}
componentWillMount(){
this.setState({tableHeight:window.innerHeight-390});
}
clickFn(){
this.props.history.push('/system/role-add');
sessionStorage.setItem('pathname2','/system/role-add')
@ -65,7 +76,6 @@ export default class acclist extends React.Component{
<TabPage tabs={this.state.tabList}>
<p className="roletable">
<Button type="primary" icon="plus" onClick={this.clickFn.bind(this)}>新建角色</Button>
{/* <Button type="info">批量操作</Button> */}
</p>
<div className="table-container">
<Grid
@ -74,6 +84,7 @@ export default class acclist extends React.Component{
isMultiple={false}
countbarVisible={false}
isSwitch={false}
maxheight={this.state.tableHeight}
pageChange={(e)=>{
this.pageChange(e)
}}