Commit 26bbb950 by zhangleyuan

feat:修改退出登录的文案

parent b9e37a2e
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
* @Author: 吴文洁 * @Author: 吴文洁
* @Date: 2019-09-10 18:26:03 * @Date: 2019-09-10 18:26:03
* @LastEditors: zhangleyuan * @LastEditors: zhangleyuan
* @LastEditTime: 2020-12-04 15:30:49 * @LastEditTime: 2020-12-07 16:46:18
* @Description: * @Description:
*/ */
import React , { useContext, useEffect ,useState}from 'react'; import React , { useContext, useEffect ,useState}from 'react';
...@@ -62,8 +62,8 @@ function Header(){ ...@@ -62,8 +62,8 @@ function Header(){
} }
function handleLogoutConfirm(){ function handleLogoutConfirm(){
return confirm({ return confirm({
title: "你确定要删除此讲师吗?", title: "你确定要退出登录吗?",
content: "删除后,讲师将不能登录系统,此操作不能被撤销", content: "退出后,需重新登录",
icon: <QuestionCircleOutlined />, icon: <QuestionCircleOutlined />,
okText: "删除", okText: "删除",
okType: "danger", okType: "danger",
......
.course-catalog-page{
.child-table{
thead{
display:none;
}
}
}
\ No newline at end of file
...@@ -18,7 +18,7 @@ import "./CourseCatalogPage.less"; ...@@ -18,7 +18,7 @@ import "./CourseCatalogPage.less";
import User from '@/common/js/user'; import User from '@/common/js/user';
const { confirm } = Modal; const { confirm } = Modal;
interface RecordTypes { interface RecordTypes {
children: any; child: any;
} }
function CourseCatalogPage() { function CourseCatalogPage() {
...@@ -133,7 +133,7 @@ function CourseCatalogPage() { ...@@ -133,7 +133,7 @@ function CourseCatalogPage() {
listData.map((item:any,index:any) => { listData.map((item:any,index:any) => {
item.type = "parent" item.type = "parent"
item.key = item.id; item.key = item.id;
item.children = []; item.child = [];
return item return item
}) })
...@@ -157,21 +157,20 @@ function CourseCatalogPage() { ...@@ -157,21 +157,20 @@ function CourseCatalogPage() {
parentId, parentId,
} }
StoreService.getAllSonCategory(param).then((res: any) => { StoreService.getAllSonCategory(param).then((res: any) => {
record.children= res.result || []; record.child= res.result || [];
record.children.map((item:any,index:any) => { record.child.map((item:any,index:any) => {
item.key= item.id item.key= item.id
return item return item
}) })
const _courseCatalogList =[...courseCatalogList]; const _courseCatalogList =[...courseCatalogList];
console.log("_courseCatalogList",_courseCatalogList); console.log("_courseCatalogList",_courseCatalogList);
setCourseCatalogList(_courseCatalogList) setCourseCatalogList(_courseCatalogList)
}); });
} }
return ( return (
<div className=" page employee-manage-page"> <div className=" page course-catalog-page">
<div className="page-content"> <div className="page-content">
<div className="content-header">员工管理</div> <div className="content-header">员工管理</div>
<div className="box"> <div className="box">
...@@ -188,11 +187,14 @@ function CourseCatalogPage() { ...@@ -188,11 +187,14 @@ function CourseCatalogPage() {
<Table <Table
columns={ parseColumn() } columns={ parseColumn() }
pagination={false} pagination={false}
expandedRowRender={(record:RecordTypes) => { expandedRowRender={(record:RecordTypes) => {
if(!record.children){ if(!record.child){
return return
} }
if (record.children.length === 0){ if (record.child.length !== 0){
return <Table columns={parseColumn()} dataSource={record.child} pagination={false} className="child-table"/>
}else{
return <div>还未添加任何子分类</div>; return <div>还未添加任何子分类</div>;
} }
}} }}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment