diff --git a/dist.zip b/dist.zip
deleted file mode 100644
index 7c4c28f..0000000
Binary files a/dist.zip and /dev/null differ
diff --git a/src/components/drawer/index.jsx b/src/components/drawer/index.jsx
index d7437d4..2cf757f 100644
--- a/src/components/drawer/index.jsx
+++ b/src/components/drawer/index.jsx
@@ -1,11 +1,21 @@
import React from 'react';
-import { Drawer, Space, Button, Dropdown, Menu, Table, Spin } from 'antd';
+import {
+ Drawer,
+ Space,
+ Button,
+ Dropdown,
+ Menu,
+ Table,
+ Spin,
+ Checkbox,
+} from 'antd';
import { OrgChartComponent } from '@/components/orgChart';
import * as d3 from 'd3';
import qs from 'qs';
import { message } from 'antd';
import jsPDF from 'jspdf';
import ExportJsonExcel from 'js-export-excel';
+import './index.less';
let addNodeChildFunc = null;
let orgChart = null;
@@ -21,6 +31,7 @@ export default class DrawerComponents extends React.Component {
dataSource: [],
columns: [],
spinning: true,
+ showJob: true,
};
}
@@ -51,11 +62,11 @@ export default class DrawerComponents extends React.Component {
}
//获取数据
- getDeatilDatas(rootId, type = 'chart') {
+ getDeatilDatas(rootId, type = 'chart', showJob = '1') {
this.setState({ spinning: true });
d3.json(
'/api/bs/hrmorganization/orgchart/getDepartmentDetail?' +
- qs.stringify({ detauleType: type, rootId: rootId }),
+ qs.stringify({ detauleType: type, rootId: rootId, showJob }),
).then((data) => {
//
if (type == 'chart') {
@@ -228,7 +239,7 @@ export default class DrawerComponents extends React.Component {
-
+
${d.data.fname}
@@ -293,7 +304,7 @@ export default class DrawerComponents extends React.Component {
};
onClose = () => {
- this.setState({ open: false, detailType: 'chart' });
+ this.setState({ open: false, detailType: 'chart', showJob: true });
};
changeDetail = () => {
@@ -306,8 +317,16 @@ export default class DrawerComponents extends React.Component {
};
render() {
- const { open, data, detailType, dataSource, columns, spinning } =
- this.state;
+ const {
+ rootId,
+ open,
+ data,
+ detailType,
+ dataSource,
+ columns,
+ spinning,
+ showJob,
+ } = this.state;
let arr = [];
if (detailType == 'chart') {
arr.push({ label: '导出图片', key: '1' });
@@ -329,6 +348,23 @@ export default class DrawerComponents extends React.Component {
}}
extra={
+ {
+ this.setState({
+ showJob: e.target.checked,
+ });
+ detailType == 'chart' &&
+ this.getDeatilDatas(
+ rootId,
+ detailType,
+ e.target.checked ? '1' : '0',
+ );
+ }}
+ >
+ 是否显示岗位
+
diff --git a/src/components/drawer/index.less b/src/components/drawer/index.less
index e69de29..e2403ec 100644
--- a/src/components/drawer/index.less
+++ b/src/components/drawer/index.less
@@ -0,0 +1,4 @@
+.dept-box:hover {
+ width: 500px;
+ text-align: left;
+}
diff --git a/src/components/topBar/index.jsx b/src/components/topBar/index.jsx
index 031c8e7..cee73cc 100644
--- a/src/components/topBar/index.jsx
+++ b/src/components/topBar/index.jsx
@@ -33,7 +33,7 @@ export class TopBar extends React.Component {
requestData: {
fclass: '0',
root: undefined,
- level: '3',
+ level: '2',
fisvitual: '0',
},
open: false,
@@ -246,16 +246,17 @@ export class TopBar extends React.Component {
- 显示层级:
+ 部门层级:
@@ -298,7 +299,7 @@ export class TopBar extends React.Component {
提示:版本操作耗时较长,请谨慎操作(版本仅记录当前维度的数据)
- 描述:
+ 主题:
diff --git a/src/pages/index.less b/src/pages/index.less
index 0186693..04f4d5d 100644
--- a/src/pages/index.less
+++ b/src/pages/index.less
@@ -3,9 +3,9 @@
}
.wrapper {
- background: #F7F9FD;
+ background: #f7f9fd;
}
.contentWrapper {
- background-color: #F7F9FD;
-}
\ No newline at end of file
+ background-color: #f7f9fd;
+}