xuziqiang 4 months ago
parent
commit
1e72487b35
  1. 200
      hx-ai-intelligent/src/view/organizationManage/departmentManage/index.vue
  2. 14
      hx-ai-intelligent/src/view/organizationManage/usermanage/index.vue

200
hx-ai-intelligent/src/view/organizationManage/departmentManage/index.vue

@ -85,9 +85,16 @@
import { Modal } from 'ant-design-vue';
import { ExclamationCircleOutlined } from '@ant-design/icons-vue';
import { http } from '/nerv-lib/util/http';
import { uuid } from '@antv/x6/lib/util/string/uuid';
export default defineComponent({
name: 'authorityManageIndex',
name: 'AuthorityManageIndex',
setup() {
let formData = ref({});
let formData2 = ref({});
const activeKey = ref('1');
const activeKey2 = ref('1');
const disabled = ref(true);
const disabled2 = ref(true);
const ApartcheckedKeys = ref<string[]>([]);
const UsercheckedKeys = ref<string[]>([]);
@ -98,10 +105,66 @@
console.log('checkedKeys', UsercheckedKeys.value);
});
const activeKey = ref('1');
const activeKey2 = ref('1');
const disabled = ref(false);
const disabled2 = ref(false);
const opMap: any = {
type: 'add',
fuc: () => {},
record: {},
};
const apartmentTreeData = ref([
{
title: '铁路总局',
key: '0-0',
children: [
{ title: '济阳站', key: '0-0-0' },
{ title: '临沂站', key: '0-0-1' },
],
},
]);
const userTreeData = ref([
{
title: '产品总监',
key: '0-0',
children: [
{ title: '产品经理', key: '0-0-0' },
{ title: '产品助理', key: '0-0-1' },
],
},
]);
const apartmentAdminTreeData = [
{
title: '首页',
key: '0-0',
children: [
{
title: '控制台',
key: '0-0-0',
children: [
{ title: 'leaf', key: '0-0-0-0' },
{ title: 'leaf', key: '0-0-0-1' },
],
},
{
title: '用户管理',
key: '0-0-1',
children: [{ key: '0-0-1-0', title: 'sss' }],
},
],
},
];
const userAdminTreeData = ref([
{
title: '产品总监',
key: '0-0',
children: [
{ title: '产品经理1', key: '0-0-0' },
{ title: '产品经理2', key: '0-0-1' },
],
},
]);
const addApartment = () => {
disabled.value = false;
@ -110,6 +173,15 @@
const addApartmentSon = () => {
disabled.value = false;
};
const addUser = () => {
disabled2.value = false;
};
const addUserSon = () => {
disabled.value = false;
};
const deleteApartment = () => {
Modal.confirm({
title: '是否确认删除',
@ -122,13 +194,7 @@
class: 'test',
});
};
const addUser = () => {
disabled2.value = false;
};
const addUserSon = () => {
disabled.value = false;
};
const deleteUser = () => {
Modal.confirm({
title: '是否确认删除',
@ -143,14 +209,24 @@
};
const SelectApartmentTree = (selectedKeys: any, info: any) => {
disabled.value = false;
console.log(selectedKeys, 'selectedKeys');
console.log(info, 'info');
};
const SelectUserTree = (selectedKeys: any, info: any) => {
disabled2.value = false;
console.log(selectedKeys, 'selectedKeys');
console.log(info, 'info');
};
const CancelApartment = () => {
disabled.value = true;
};
const CancelUser = () => {
disabled2.value = true;
};
const ApartmentSelect = (selectedKeys: any, info: any) => {
console.log(selectedKeys, 'selectedKeys');
console.log(info, 'info');
@ -163,93 +239,23 @@
const ApartmentSure = () => {
disabled.value = !disabled.value;
opMap.fuc && opMap.fuc(formData.value);
console.log(formData.value.name, 'formData');
apartmentTreeData.value[0].children.push({
title: formData.value.name,
key: 'a1',
});
};
const UserSure = () => {
disabled2.value = !disabled2.value;
opMap.fuc && opMap.fuc(formData2.value);
console.log(formData2.value, 'formData2');
userTreeData.value[0].children.push({
title: formData2.value.departname,
key: 'a2',
});
};
const CancelApartment = () => {
disabled.value = true;
};
const CancelUser = () => {
disabled2.value = true;
};
const apartmentTreeData = [
{
title: '铁路总局',
key: '0-0',
children: [
{ title: '济阳站', key: '0-0-0' },
{ title: '临沂站', key: '0-0-1' },
],
},
];
const userTreeData = [
{
title: '产品总监',
key: '0-0',
children: [
{ title: '产品经理', key: '0-0-0' },
{ title: '产品助理', key: '0-0-1' },
],
},
];
const apartmentAdminTreeData = [
{
title: '首页',
key: '0-0',
children: [
{
title: '控制台',
key: '0-0-0',
children: [
{ title: 'leaf', key: '0-0-0-0' },
{ title: 'leaf', key: '0-0-0-1' },
],
},
{
title: '用户管理',
key: '0-0-1',
children: [{ key: '0-0-1-0', title: 'sss' }],
},
],
},
];
const userAdminTreeData = [
{
title: '首页',
key: '0-0',
children: [
{
title: '工作台',
key: '0-0-0',
children: [
{ title: 'leaf', key: '0-0-0-0' },
{ title: 'leaf', key: '0-0-0-1' },
],
},
{
title: '系统管理',
key: '0-0-1',
children: [{ key: '0-0-1-0', title: 'sss' }],
},
],
},
];
let formData = reactive({
department: '',
remark: '',
});
let formData2 = reactive({
department: '',
remark: '',
});
const formSchema = reactive([
{
field: 'field111',
@ -258,7 +264,7 @@
schemas: [
{
label: '部门名称',
field: 'department',
field: 'name',
component: 'NsInput',
componentProps: {
disabled: disabled,
@ -292,7 +298,7 @@
},
{
label: '部门编码',
field: 'department',
field: 'code',
component: 'NsInput',
componentProps: {
disabled: disabled,
@ -375,7 +381,7 @@
},
{
label: '节点编码',
field: 'department',
field: 'code',
component: 'NsInput',
componentProps: {
disabled: disabled2,
@ -390,7 +396,7 @@
},
{
label: '是否部门领导',
field: 'sex',
field: 'isleader',
component: 'NsRadioGroup',
componentProps: {
disabled: disabled2,

14
hx-ai-intelligent/src/view/organizationManage/usermanage/index.vue

@ -41,7 +41,7 @@
</div>
</div>
<div class="right">
<ns-view-list-table v-bind="tableConfig" :model="data" ref="mainRef" class="table" />
<ns-view-list-table v-bind="tableConfig" :model="data" ref="mainRef" />
</div>
<a-drawer
:width="1200"
@ -157,7 +157,7 @@
};
const handleOk = () => {
opMap.fuc && opMap.fuc(formData2.value);
// opMap.fuc && opMap.fuc(formData2.value);
addformvisible.value = false;
};
const handleClose = () => {
@ -646,8 +646,6 @@
}
.left {
width: 400px;
/* height: 95vh; */
// height: 92.7vh;
border-right: 5px solid rgb(229, 235, 240);
min-width: fit-content;
}
@ -661,17 +659,11 @@
}
.ns-table-title {
text-align: left;
height: 46px;
// height: 46px;
line-height: 46px;
font-size: 18px;
font-weight: bold;
user-select: text;
padding-left: 16px;
width: 100%;
}
.table {
/* width: 2000px; */
/* width: auto; */
}
.admin {
text-align: left;

Loading…
Cancel
Save