diff --git a/src/app/pages/today-warning/today-warning.component.scss b/src/app/pages/today-warning/today-warning.component.scss
index 16a8d2c..1b26d4a 100644
--- a/src/app/pages/today-warning/today-warning.component.scss
+++ b/src/app/pages/today-warning/today-warning.component.scss
@@ -99,30 +99,3 @@
}
}
-
-//遮罩层
-::ng-deep .vertical-center-modal {
- display: flex;
- align-items: center;
- justify-content: center;
-}
-
-::ng-deep .ant-modal-body {
- background: #072549;
- height: 660px;
- padding: 5px;
- // border: 1px solid #8eb9e3;
- box-shadow: 0 0 3px #8eb9e3;
- color: #fff;
-}
-
-::ng-deep .ant-modal-close-x {
- width: 36px;
- height: 36px;
- line-height: 36px;
- color: white;
-}
-
-::ng-deep .vertical-center-modal .ant-modal {
- top: 0;
-}
diff --git a/src/app/service/tree.service.ts b/src/app/service/tree.service.ts
index f6c9713..8753b54 100644
--- a/src/app/service/tree.service.ts
+++ b/src/app/service/tree.service.ts
@@ -18,13 +18,13 @@ export class TreeService {
parentNode.children = []
}
- if (parentNode.children.length == 0) {
- item.isTop = true;
- } else {
- item.isTop = false;
- parentNode.children[parentNode.children.length -1].isBottom = false;
- }
- item.isBottom = true;
+ // if (parentNode.children.length == 0) {
+ // item.isTop = true;
+ // } else {
+ // item.isTop = false;
+ // parentNode.children[parentNode.children.length -1].isBottom = false;
+ // }
+ // item.isBottom = true;
parentNode.children.push(item)
}else{
diff --git a/src/app/system-management/navigation/navigation.component.html b/src/app/system-management/navigation/navigation.component.html
index 2b28ba1..3ab03ce 100644
--- a/src/app/system-management/navigation/navigation.component.html
+++ b/src/app/system-management/navigation/navigation.component.html
@@ -1 +1,38 @@
-
系统管理页面
+
+
+
+
+

+
+
+
+

+
+
Administrator
+
管理员
+
+
+
+
+
+ Hey,欢迎登录中化油站可视化智能安全管理系统
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/app/system-management/navigation/navigation.component.scss b/src/app/system-management/navigation/navigation.component.scss
index e69de29..3a4a07a 100644
--- a/src/app/system-management/navigation/navigation.component.scss
+++ b/src/app/system-management/navigation/navigation.component.scss
@@ -0,0 +1,78 @@
+nz-layout {
+ width: 100%;
+ height: 100%;
+ color: #fff;
+ font-size: 16px !important;
+}
+
+nz-sider {
+ background: #001B3B;
+ display: flex;
+ flex-direction: column;
+ align-items: center;
+
+ .logo {
+ width: 100%;
+ display: flex;
+ justify-content: center;
+ margin-top: 40px;
+ }
+
+ .headPortrait {
+ display: flex;
+ flex-direction: column;
+ align-items: center;
+ margin-top: 46px;
+ margin-bottom: 46px;
+
+ .photograph {
+ // width: 140px;
+ // height: 140px;
+ // border: 4px solid #FFFFFF;
+ // opacity: 1;
+ // border-radius: 32px;
+ }
+
+ span {
+ margin-top: 18px;
+ }
+ }
+
+ .nav {
+ ul {
+ li {
+ width: 300px;
+ height: 40px;
+ cursor: pointer;
+ display: flex;
+ align-items: center;
+ justify-content: left;
+ margin-bottom: 16px;
+ box-sizing: border-box;
+ padding-left: 26%;
+ img{
+ margin-right: 8px;
+ }
+ }
+
+ .router-link-active {
+ background: linear-gradient(90deg, rgba(0, 13, 33, 0) 0%, #2399FF 52%, rgba(0, 13, 33, 0) 100%);
+ }
+ }
+ }
+}
+
+nz-header {
+ height: 56px;
+ background: #FFFFFF;
+ display: flex;
+ align-items: center;
+ justify-content: space-between;
+ padding: 0 16px;
+}
+
+nz-content {
+ background: #F2F2F2;
+ box-sizing: border-box;
+ padding: 16px;
+}
diff --git a/src/app/system-management/navigation/navigation.component.ts b/src/app/system-management/navigation/navigation.component.ts
index 18be053..d9b293a 100644
--- a/src/app/system-management/navigation/navigation.component.ts
+++ b/src/app/system-management/navigation/navigation.component.ts
@@ -11,5 +11,7 @@ export class NavigationComponent implements OnInit {
ngOnInit(): void {
}
-
+ signOut() {
+ // history.go(-1);
+ }
}
diff --git a/src/app/system-management/organization/addor/addor.component.html b/src/app/system-management/organization/addor/addor.component.html
new file mode 100644
index 0000000..ab9ed73
--- /dev/null
+++ b/src/app/system-management/organization/addor/addor.component.html
@@ -0,0 +1,21 @@
+
+
+
diff --git a/src/app/system-management/organization/addor/addor.component.scss b/src/app/system-management/organization/addor/addor.component.scss
new file mode 100644
index 0000000..e69de29
diff --git a/src/app/system-management/organization/addor/addor.component.ts b/src/app/system-management/organization/addor/addor.component.ts
new file mode 100644
index 0000000..3a5dc13
--- /dev/null
+++ b/src/app/system-management/organization/addor/addor.component.ts
@@ -0,0 +1,26 @@
+import { Component, OnInit, Input } from '@angular/core';
+import { NzModalRef } from 'ng-zorro-antd/modal';
+import { FormBuilder, FormGroup, Validators } from '@angular/forms';
+import { HttpClient } from '@angular/common/http';
+@Component({
+ selector: 'app-addor',
+ templateUrl: './addor.component.html',
+ styleUrls: ['./addor.component.scss']
+})
+export class AddorComponent implements OnInit {
+
+ @Input() title?: string;
+ @Input() subtitle?: string;
+ validateForm!: FormGroup;
+ constructor(private modal: NzModalRef, private fb: FormBuilder, private http: HttpClient) { }
+
+ ngOnInit(): void {
+ this.validateForm = this.fb.group({
+ name: [null, [Validators.required]]
+ });
+ }
+ destroyModal(): void {
+ this.modal.destroy({ data: 'this the result data' });
+ }
+
+}
diff --git a/src/app/system-management/organization/editor/editor.component.html b/src/app/system-management/organization/editor/editor.component.html
new file mode 100644
index 0000000..4769623
--- /dev/null
+++ b/src/app/system-management/organization/editor/editor.component.html
@@ -0,0 +1,21 @@
+
+
+
diff --git a/src/app/system-management/organization/editor/editor.component.scss b/src/app/system-management/organization/editor/editor.component.scss
new file mode 100644
index 0000000..e69de29
diff --git a/src/app/system-management/organization/editor/editor.component.ts b/src/app/system-management/organization/editor/editor.component.ts
new file mode 100644
index 0000000..c7a7805
--- /dev/null
+++ b/src/app/system-management/organization/editor/editor.component.ts
@@ -0,0 +1,27 @@
+import { Component, OnInit, Input } from '@angular/core';
+import { NzModalRef } from 'ng-zorro-antd/modal';
+import { FormBuilder, FormGroup, Validators } from '@angular/forms';
+import { HttpClient } from '@angular/common/http';
+@Component({
+ selector: 'app-editor',
+ templateUrl: './editor.component.html',
+ styleUrls: ['./editor.component.scss']
+})
+export class EditorComponent implements OnInit {
+
+ @Input() data?: any;
+ validateForm!: FormGroup;
+ constructor(private modal: NzModalRef, private fb: FormBuilder, private http: HttpClient) { }
+
+ ngOnInit(): void {
+ this.validateForm = this.fb.group({
+ name: [null, [Validators.required]],
+ power: [null, [Validators.required]]
+ });
+ }
+ destroyModal(): void {
+ this.modal.destroy({ data: 'this the result data' });
+ }
+
+
+}
diff --git a/src/app/system-management/organization/organization.component.html b/src/app/system-management/organization/organization.component.html
index 414c783..4bcf388 100644
--- a/src/app/system-management/organization/organization.component.html
+++ b/src/app/system-management/organization/organization.component.html
@@ -1 +1,43 @@
-
organization works!
+
+
+
+
组织机构列表
+
{{totalCount}}个单位
+
+
+
+
+
+
+
+
+
+
+ 组织机构
+ 操作
+
+
+
+
+
+ {{ node.title }}
+
+ 新增
+ 编辑
+ 删除
+
+
+
+
diff --git a/src/app/system-management/organization/organization.component.scss b/src/app/system-management/organization/organization.component.scss
index e69de29..a365d13 100644
--- a/src/app/system-management/organization/organization.component.scss
+++ b/src/app/system-management/organization/organization.component.scss
@@ -0,0 +1,78 @@
+.orbox {
+ width: 100%;
+ height: 100%;
+ overflow-y: auto;
+ background: #fff;
+ box-sizing: border-box;
+ padding: 20px;
+ font-size: 15px;
+}
+
+.topbox {
+ width: 700px;
+ height: 36px;
+ display: flex;
+ align-items: center;
+ justify-content: space-between;
+
+ .lefttop {
+ span:nth-child(1) {
+ color: #000D21;
+ margin-right: 16px;
+ }
+
+ span:nth-child(2) {
+ color: rgba(36, 36, 36, 0.24);
+ }
+ }
+
+ .righttop {
+ height: 36px;
+ display: flex;
+
+ button {
+ margin-left: 16px;
+ }
+
+ nz-input-group {
+ height: 32px;
+ }
+ }
+}
+
+.treeTitle {
+ width: 700px;
+ height: 36px;
+ line-height: 36px;
+ display: flex;
+ justify-content: space-between;
+ color: #000D21;
+ box-sizing: border-box;
+ padding-left: 30px;
+ padding-right: 180px;
+ background: rgba(145, 204, 255, 0.2);
+ margin: 12px 0;
+}
+
+.nodebox {
+ font-size: 15px;
+
+}
+
+.operation {
+ position: absolute;
+ right: 0;
+
+ span {
+ margin-left: 40px;
+ }
+
+ span:nth-child(1),
+ span:nth-child(2) {
+ color: #2399FF;
+ }
+
+ span:nth-child(3) {
+ color: rgba(0, 13, 33, 0.48);
+ }
+}
diff --git a/src/app/system-management/organization/organization.component.ts b/src/app/system-management/organization/organization.component.ts
index b7e9eee..3629aaa 100644
--- a/src/app/system-management/organization/organization.component.ts
+++ b/src/app/system-management/organization/organization.component.ts
@@ -1,15 +1,182 @@
-import { Component, OnInit } from '@angular/core';
-
+import { HttpClient } from '@angular/common/http';
+import { Component, OnInit, AfterViewInit, ViewChild, ViewContainerRef } from '@angular/core';
+import { TreeService } from 'src/app/service/tree.service';
+import { NzFormatEmitEvent, NzTreeComponent, NzTreeNodeOptions } from 'ng-zorro-antd/tree';
+import { FormBuilder, FormGroup, Validators } from '@angular/forms';
+import { NzModalService } from 'ng-zorro-antd/modal';
+import { NzMessageService } from 'ng-zorro-antd/message';
+import { AddorComponent } from './addor/addor.component';
+import { EditorComponent } from './editor/editor.component';
@Component({
selector: 'app-organization',
templateUrl: './organization.component.html',
styleUrls: ['./organization.component.scss']
})
export class OrganizationComponent implements OnInit {
-
- constructor() { }
+ validateForm!: FormGroup;
+ constructor(private fb: FormBuilder, private http: HttpClient, private toTree: TreeService, private modal: NzModalService, private message: NzMessageService, private viewContainerRef: ViewContainerRef) { }
ngOnInit(): void {
+ this.validateForm = this.fb.group({
+ search: [null]
+ });
+ this.getAllOrganization()
+ }
+ //搜索框提交
+ submitForm(): void {
+ console.log(12345)
+ for (const i in this.validateForm.controls) {
+ this.validateForm.controls[i].markAsDirty();
+ this.validateForm.controls[i].updateValueAndValidity();
+ }
+ }
+
+ //获取所有组织机构
+ searchValue = '';
+ nzExpandAll = false;
+ totalCount:string
+ getAllOrganization() {
+ this.http.get('/api/services/app/Organization/GetAll').subscribe((data: any) => {
+ this.totalCount = data.result.totalCount
+ // console.log('组织机构',data.result.totalCount)
+ data.result.items.forEach(element => {
+ element.key = element.code
+ element.title = element.displayName
+ element.selectable = false
+ });
+ this.nodes = [...this.toTree.toTree(data.result.items)]
+ // this.nzExpandAll = true;
+ this.nzTreeComponent.getExpandedNodeList().forEach((item) => {
+ this.defaultExpandedKeys.push(item.key)
+ })
+ })
+ }
+
+
+ @ViewChild('nzTreeComponent', { static: false }) nzTreeComponent!: NzTreeComponent;
+
+ defaultExpandedKeys = [];
+
+ nodes: any[] = []
+
+ nzClick(event: NzFormatEmitEvent): void {
+ // console.log(event);
+ console.log('展开节点', this.nzTreeComponent.getExpandedNodeList())
+
+
}
+ nzCheck(event: NzFormatEmitEvent): void {
+ console.log(event);
+ }
+
+ // nzSelectedKeys change
+ nzSelect(keys: string[]): void {
+ console.log(keys, this.nzTreeComponent.getSelectedNodeList());
+ }
+
+ ngAfterViewInit(): void {
+ // get node by key: '10011'
+ console.log(this.nzTreeComponent.getTreeNodeByKey('10011'));
+ // use tree methods
+ console.log(
+ this.nzTreeComponent.getTreeNodes(),
+ this.nzTreeComponent.getCheckedNodeList(),
+ this.nzTreeComponent.getSelectedNodeList(),
+ this.nzTreeComponent.getExpandedNodeList()
+ );
+ }
+
+ addOr(node?: any) {
+ const modal = this.modal.create({
+ nzTitle: node ? '新增组织机构' : '新增一级组织机构',
+ nzContent: AddorComponent,
+ nzViewContainerRef: this.viewContainerRef,
+ nzWidth: 288,
+ nzComponentParams: {
+ title: '',
+ subtitle: ''
+ },
+ nzOnOk: async () => {
+ console.log('hhhhhhh', instance.validateForm)
+ if (instance.validateForm.valid) {
+ await new Promise(resolve => {
+ let body = {
+
+ }
+ this.http.post('/api/services/app/User/Create', body).subscribe(data => {
+ resolve(data)
+ this.message.create('success', '创建成功!');
+ return true
+ }, err => {
+ resolve(err)
+ this.message.create('warning', '创建失败');
+ return false
+ })
+ })
+ } else {
+ this.message.create('warning', '请填写完整!');
+ return false
+ }
+ }
+ });
+ const instance = modal.getContentComponent();
+
+ }
+ editOr(node) {
+ console.log(node)
+ const modal = this.modal.create({
+ nzTitle: '编辑组织机构',
+ nzContent: EditorComponent,
+ nzViewContainerRef: this.viewContainerRef,
+ nzWidth: 288,
+ nzComponentParams: {
+ data: node,
+ },
+ nzOnOk: async () => {
+ console.log('hhhhhhh', instance.validateForm)
+ if (instance.validateForm.valid) {
+ await new Promise(resolve => {
+ let body = {
+
+ }
+ this.http.post('/api/services/app/User/Create', body).subscribe(data => {
+ resolve(data)
+ this.message.create('success', '编辑成功!');
+ return true
+ }, err => {
+ resolve(err)
+ this.message.create('warning', '创建失败');
+ return false
+ })
+ })
+ } else {
+ this.message.create('warning', '请填写完整!');
+ return false
+ }
+ }
+ });
+ const instance = modal.getContentComponent();
+ }
+ deleteOr(item) {
+ console.log(item)
+ this.modal.confirm({
+ nzTitle: `确定要删除${item.title}这个机构吗?`,
+ nzOkText: '确定',
+ nzOkType: 'danger',
+ nzOnOk: () => {
+ this.http.delete('/api/services/app/Role/Delete', {
+ params: {
+ Id: item.id
+ }
+ }).subscribe(data => {
+ this.message.create('success', '删除成功!');
+ })
+ },
+ nzCancelText: '取消',
+ nzOnCancel: () => {
+
+ }
+ });
+ }
}
diff --git a/src/app/system-management/role/addrole/addrole.component.html b/src/app/system-management/role/addrole/addrole.component.html
new file mode 100644
index 0000000..1727024
--- /dev/null
+++ b/src/app/system-management/role/addrole/addrole.component.html
@@ -0,0 +1,21 @@
+
+
+
diff --git a/src/app/system-management/role/addrole/addrole.component.scss b/src/app/system-management/role/addrole/addrole.component.scss
new file mode 100644
index 0000000..e69de29
diff --git a/src/app/system-management/role/addrole/addrole.component.ts b/src/app/system-management/role/addrole/addrole.component.ts
new file mode 100644
index 0000000..030d7e4
--- /dev/null
+++ b/src/app/system-management/role/addrole/addrole.component.ts
@@ -0,0 +1,38 @@
+import { Component, OnInit, Input } from '@angular/core';
+import { NzModalRef } from 'ng-zorro-antd/modal';
+import { FormBuilder, FormGroup, Validators } from '@angular/forms';
+import { HttpClient } from '@angular/common/http';
+@Component({
+ selector: 'app-addrole',
+ templateUrl: './addrole.component.html',
+ styleUrls: ['./addrole.component.scss']
+})
+export class AddroleComponent implements OnInit {
+
+ @Input() title?: string;
+ @Input() subtitle?: string;
+ validateForm!: FormGroup;
+ constructor(private modal: NzModalRef, private fb: FormBuilder, private http: HttpClient) { }
+
+ ngOnInit(): void {
+ this.loadMore();
+ this.validateForm = this.fb.group({
+ name: [null, [Validators.required]],
+ power: [null, [Validators.required]]
+ });
+ }
+ destroyModal(): void {
+ this.modal.destroy({ data: 'this the result data' });
+ }
+ optionList = [];
+ isLoading = false;
+ //获取权限列表
+ loadMore() {
+ this.isLoading = true;
+ this.http.get('/api/services/app/Role/GetAllPermissions').subscribe((data:any) => {
+ this.isLoading = false;
+ this.optionList = data.result.items
+ console.log('所有权限',data)
+ })
+ }
+}
diff --git a/src/app/system-management/role/editrole/editrole.component.html b/src/app/system-management/role/editrole/editrole.component.html
new file mode 100644
index 0000000..7db4fd5
--- /dev/null
+++ b/src/app/system-management/role/editrole/editrole.component.html
@@ -0,0 +1,18 @@
+
+
+
diff --git a/src/app/system-management/role/editrole/editrole.component.scss b/src/app/system-management/role/editrole/editrole.component.scss
new file mode 100644
index 0000000..e69de29
diff --git a/src/app/system-management/role/editrole/editrole.component.ts b/src/app/system-management/role/editrole/editrole.component.ts
new file mode 100644
index 0000000..2dae734
--- /dev/null
+++ b/src/app/system-management/role/editrole/editrole.component.ts
@@ -0,0 +1,38 @@
+import { FormBuilder, FormGroup, Validators } from '@angular/forms';
+import { Component, OnInit, Input } from '@angular/core';
+import { NzModalRef } from 'ng-zorro-antd/modal';
+import { HttpClient } from '@angular/common/http';
+@Component({
+ selector: 'app-editrole',
+ templateUrl: './editrole.component.html',
+ styleUrls: ['./editrole.component.scss']
+})
+export class EditroleComponent implements OnInit {
+
+ @Input() data?: any;
+ validateForm!: FormGroup;
+ constructor(private modal: NzModalRef, private fb: FormBuilder, private http: HttpClient) { }
+
+ multipleValue:any
+ ngOnInit(): void {
+ this.multipleValue = this.data.grantedPermissions
+ this.loadMore();
+ this.validateForm = this.fb.group({
+ name: [null, [Validators.required]],
+ power: [null, [Validators.required]]
+ });
+ }
+ destroyModal(): void {
+ this.modal.destroy({ data: 'this the result data' });
+ }
+
+ optionList = [];
+ //获取权限列表
+ loadMore() {
+ this.http.get('/api/services/app/Role/GetAllPermissions').subscribe((data:any) => {
+ this.optionList = data.result.items
+ console.log('所有权限',data)
+ })
+ }
+
+}
diff --git a/src/app/system-management/role/role.component.html b/src/app/system-management/role/role.component.html
index ce1bd50..dd622e4 100644
--- a/src/app/system-management/role/role.component.html
+++ b/src/app/system-management/role/role.component.html
@@ -1 +1,38 @@
-
role works!
+
+
+
+
+
+
+ 角色 |
+ 权限 |
+ 创建/修改时间 |
+ 操作 |
+
+
+
+
+ {{data.name}} |
+
+ {{item.displayName}}
+ |
+
+ {{(data.lastModificationTime ? data.lastModificationTime : data.creationTime) | date:"yyyy-MM-dd HH:mm:ss"}}
+ |
+
+ 编辑
+ 删除
+ |
+
+
+
+
+
diff --git a/src/app/system-management/role/role.component.scss b/src/app/system-management/role/role.component.scss
index e69de29..44dcc71 100644
--- a/src/app/system-management/role/role.component.scss
+++ b/src/app/system-management/role/role.component.scss
@@ -0,0 +1,54 @@
+.roleBox {
+ width: 100%;
+ height: 100%;
+ background: #FFFFFF;
+ box-sizing: border-box;
+ padding: 20px;
+ overflow: hidden;
+ display: flex;
+ flex-direction: column;
+
+ tbody {
+ tr {
+ td {
+ span {
+ margin-right: 18px;
+ }
+ }
+ td:nth-child(1){
+ padding-left: 40px;
+ }
+ }
+ .operation {
+ a {
+ color: #2399FF;
+ margin-right: 8px;
+ }
+ a:last-child {
+ color: rgba(0, 13, 33, 0.48);
+ }
+ }
+
+ }
+}
+
+.topbox {
+ width: 100%;
+ height: 36px;
+ display: flex;
+ align-items: center;
+ justify-content: space-between;
+ margin-bottom: 12px;
+
+ .lefttop {
+ span {
+ color: #000D21;
+ }
+ }
+}
+
+.tablebox {
+ flex: 1;
+ overflow-y: auto;
+
+}
diff --git a/src/app/system-management/role/role.component.ts b/src/app/system-management/role/role.component.ts
index dbd7a84..41abbde 100644
--- a/src/app/system-management/role/role.component.ts
+++ b/src/app/system-management/role/role.component.ts
@@ -1,5 +1,11 @@
-import { Component, OnInit } from '@angular/core';
+import { Component, OnInit, TemplateRef, ViewContainerRef } from '@angular/core';
+import { FormBuilder, FormGroup, Validators } from '@angular/forms';
+import { NzModalService } from 'ng-zorro-antd/modal';
+import { NzMessageService } from 'ng-zorro-antd/message';
+import { HttpClient } from '@angular/common/http';
+import { AddroleComponent } from './addrole/addrole.component';
+import { EditroleComponent } from './editrole/editrole.component';
@Component({
selector: 'app-role',
templateUrl: './role.component.html',
@@ -7,9 +13,126 @@ import { Component, OnInit } from '@angular/core';
})
export class RoleComponent implements OnInit {
- constructor() { }
+
+ constructor(private modal: NzModalService, private viewContainerRef: ViewContainerRef, private message: NzMessageService, private http: HttpClient) { }
ngOnInit(): void {
+ this.getAllRoles()
+ }
+
+ listOfData: any[] = [];
+
+ //获取角色列表
+
+ getAllRoles() {
+ this.http.get('/api/services/app/Role/GetAll').subscribe((data: any) => {
+ console.log('角色列表', data.result.items)
+ this.listOfData = data.result.items
+ })
+ }
+
+ addRole(): void {
+ const modal = this.modal.create({
+ nzTitle: '新增角色',
+ nzContent: AddroleComponent,
+ nzViewContainerRef: this.viewContainerRef,
+ nzWidth: 288,
+ nzComponentParams: {},
+ nzOnOk: async () => {
+ if (instance.validateForm.valid) {
+ await new Promise(resolve => {
+ console.log('表单信息', instance.validateForm)
+ let arr = []
+ instance.validateForm.value.power.forEach(element => {
+ arr.push(element.name)
+ });
+ let body = {
+ name: instance.validateForm.value.name,
+ DisplayName: instance.validateForm.value.name,
+ grantedPermissions: arr
+ }
+ this.http.post('/api/services/app/Role/Create', body).subscribe(data => {
+ resolve(data)
+ this.message.create('success', '创建成功!');
+ this.getAllRoles()
+ return true
+ })
+ })
+ } else {
+ this.message.create('warning', '请填写完整!');
+ return false
+ }
+ }
+ });
+ const instance = modal.getContentComponent();
+ modal.afterOpen.subscribe(() => console.log('[afterOpen] emitted!'));
+ // Return a result when closed
+ modal.afterClose.subscribe(result => console.log('[afterClose] The result is:', result));
+ }
+
+
+ edit(item) {
+ const modal = this.modal.create({
+ nzTitle: '编辑角色',
+ nzContent: EditroleComponent,
+ nzViewContainerRef: this.viewContainerRef,
+ nzWidth: 288,
+ nzComponentParams: {
+ data: item
+ },
+ nzOnOk: async () => {
+ if (instance.validateForm.valid) {
+ await new Promise(resolve => {
+ console.log('表单信息', instance.validateForm)
+ let arr = []
+ instance.validateForm.value.power.forEach(element => {
+ arr.push(element.name ? element.name : element)
+ });
+ let body = {
+ id: item.id,
+ name: instance.validateForm.value.name,
+ DisplayName: instance.validateForm.value.name,
+ grantedPermissions: arr
+ }
+ this.http.put('/api/services/app/Role/Update', body).subscribe(data => {
+ resolve(data)
+ this.message.create('success', '修改成功!');
+ this.getAllRoles()
+ return true
+ })
+ })
+ } else {
+ this.message.create('warning', '请填写完整!');
+ return false
+ }
+ }
+ });
+ const instance = modal.getContentComponent();
+ modal.afterOpen.subscribe(() => console.log('[afterOpen] emitted!'));
+ // Return a result when closed
+ modal.afterClose.subscribe(result => console.log('[afterClose] The result is:', result));
}
+ delete(item) {
+ console.log(item)
+ this.modal.confirm({
+ nzTitle: `确定要删除${item.name}这个角色吗?`,
+ nzOkText: '确定',
+ nzOkType: 'danger',
+ nzOnOk: () => {
+ this.http.delete('/api/services/app/Role/Delete', {
+ params: {
+ Id: item.id
+ }
+ }).subscribe(data => {
+ this.message.create('success', '删除成功!');
+ this.getAllRoles()
+ })
+ },
+ nzCancelText: '取消',
+ nzOnCancel: () => {
+
+ }
+ });
+ }
}
diff --git a/src/app/system-management/system-management-routing.module.ts b/src/app/system-management/system-management-routing.module.ts
index 54f7104..843186b 100644
--- a/src/app/system-management/system-management-routing.module.ts
+++ b/src/app/system-management/system-management-routing.module.ts
@@ -1,14 +1,15 @@
import { Routes, RouterModule } from '@angular/router';
import { NgModule } from '@angular/core';
-import {AuthGuard} from '../auth.guard'
+import { AuthGuard } from '../auth.guard'
+import { RoleComponent } from './role/role.component';
+import { OrganizationComponent } from './organization/organization.component';
+import { UserComponent } from './user/user.component';
const routes: Routes = [
- // { path: 'plan', component: PlanComponent },
- // { path: 'warning/petrolStation', component: TodayWarningComponent },
- // { path: 'warning/admin', component: TodayWarningAdminComponent },
- // { path: 'records/petrolStation', component: CriminalRecordsComponent },
- // { path: 'records/admin', component: CriminalRecordsAdminComponent }
+ { path: 'organization', component: OrganizationComponent },
+ { path: 'user', component: UserComponent },
+ { path: 'role', component: RoleComponent }
];
@NgModule({
diff --git a/src/app/system-management/system-management.module.ts b/src/app/system-management/system-management.module.ts
index a757a84..870c5a5 100644
--- a/src/app/system-management/system-management.module.ts
+++ b/src/app/system-management/system-management.module.ts
@@ -5,14 +5,50 @@ import { OrganizationComponent } from './organization/organization.component';
import { UserComponent } from './user/user.component';
import { RoleComponent } from './role/role.component';
import { NavigationComponent } from './navigation/navigation.component';
-
-
-
+import { NzLayoutModule } from 'ng-zorro-antd/layout';
+import { NzIconModule } from 'ng-zorro-antd/icon';
+import { NzTableModule } from 'ng-zorro-antd/table';
+import { NzDropDownModule } from 'ng-zorro-antd/dropdown';
+import { NzPaginationModule } from 'ng-zorro-antd/pagination';
+import { NzInputModule } from 'ng-zorro-antd/input';
+import { NzButtonModule } from 'ng-zorro-antd/button';
+import { NzFormModule } from 'ng-zorro-antd/form';
+import { FormsModule, ReactiveFormsModule } from '@angular/forms';
+import { NzModalModule } from 'ng-zorro-antd/modal';
+import { AdduserComponent } from './user/adduser/adduser.component';
+import { EdituserComponent } from './user/edituser/edituser.component';
+import { NzSelectModule } from 'ng-zorro-antd/select';
+import { NzMessageModule } from 'ng-zorro-antd/message';
+import { NzTreeModule } from 'ng-zorro-antd/tree';
+import { AddroleComponent } from './role/addrole/addrole.component';
+import { EditroleComponent } from './role/editrole/editrole.component';
+import { NzSpinModule } from 'ng-zorro-antd/spin';
+import { NzTreeSelectModule } from 'ng-zorro-antd/tree-select';
+import { AddorComponent } from './organization/addor/addor.component';
+import { EditorComponent } from './organization/editor/editor.component';
@NgModule({
- declarations: [OrganizationComponent, UserComponent, RoleComponent, NavigationComponent],
+ declarations: [OrganizationComponent, UserComponent, RoleComponent, NavigationComponent, AdduserComponent, EdituserComponent, AddroleComponent, EditroleComponent, AddorComponent, EditorComponent],
imports: [
CommonModule,
- SystemRoutingModule
- ]
+ SystemRoutingModule,
+ NzLayoutModule,
+ NzIconModule,
+ NzTableModule,
+ NzDropDownModule,
+ NzPaginationModule,
+ NzInputModule,
+ NzButtonModule,
+ NzFormModule,
+ FormsModule,
+ ReactiveFormsModule,
+ NzModalModule,
+ NzSelectModule,
+ NzMessageModule,
+ NzTreeModule,
+ NzSpinModule,
+ NzTreeSelectModule
+ ],
+ entryComponents :[AdduserComponent,EdituserComponent,AddroleComponent,EditroleComponent,AddorComponent,EditorComponent]
+
})
export class SystemManagementModule { }
diff --git a/src/app/system-management/user/adduser/adduser.component.html b/src/app/system-management/user/adduser/adduser.component.html
new file mode 100644
index 0000000..954b570
--- /dev/null
+++ b/src/app/system-management/user/adduser/adduser.component.html
@@ -0,0 +1,39 @@
+
+
+
diff --git a/src/app/system-management/user/adduser/adduser.component.scss b/src/app/system-management/user/adduser/adduser.component.scss
new file mode 100644
index 0000000..e69de29
diff --git a/src/app/system-management/user/adduser/adduser.component.ts b/src/app/system-management/user/adduser/adduser.component.ts
new file mode 100644
index 0000000..290dbbc
--- /dev/null
+++ b/src/app/system-management/user/adduser/adduser.component.ts
@@ -0,0 +1,54 @@
+import { Component, OnInit, Input } from '@angular/core';
+import { NzModalRef } from 'ng-zorro-antd/modal';
+import { FormBuilder, FormGroup, Validators } from '@angular/forms';
+import { HttpClient } from '@angular/common/http';
+import { TreeService } from 'src/app/service/tree.service';
+@Component({
+ selector: 'app-adduser',
+ templateUrl: './adduser.component.html',
+ styleUrls: ['./adduser.component.scss']
+})
+export class AdduserComponent implements OnInit {
+
+ @Input() title?: string;
+ @Input() subtitle?: string;
+ validateForm!: FormGroup;
+ constructor(private modal: NzModalRef, private fb: FormBuilder, private http: HttpClient, private toTree: TreeService) { }
+
+ ngOnInit(): void {
+ this.validateForm = this.fb.group({
+ account: [null, [Validators.required]],
+ name: [null, [Validators.required]],
+ organization: [null, [Validators.required]],
+ role: [null, [Validators.required]],
+ phonenum: [null, [Validators.required]]
+ });
+
+ this.getAllRoles()
+ this.getAllOrganization()
+ }
+ destroyModal(): void {
+ this.modal.destroy({ data: 'this the result data' });
+ }
+
+ listOfData: any[] = [];
+
+ //获取角色列表
+ getAllRoles() {
+ this.http.get('/api/services/app/Role/GetAll').subscribe((data: any) => {
+ console.log('角色列表', data.result.items)
+ this.listOfData = data.result.items
+ })
+ }
+ //获取所有组织机构
+ nodes:any = []
+ getAllOrganization() {
+ this.http.get('/api/services/app/Organization/GetAll').subscribe((data: any) => {
+ data.result.items.forEach(element => {
+ element.key = element.code
+ element.title = element.displayName
+ });
+ this.nodes = [...this.toTree.toTree(data.result.items)]
+ })
+ }
+}
diff --git a/src/app/system-management/user/edituser/edituser.component.html b/src/app/system-management/user/edituser/edituser.component.html
new file mode 100644
index 0000000..dc1a983
--- /dev/null
+++ b/src/app/system-management/user/edituser/edituser.component.html
@@ -0,0 +1,39 @@
+
+
+
diff --git a/src/app/system-management/user/edituser/edituser.component.scss b/src/app/system-management/user/edituser/edituser.component.scss
new file mode 100644
index 0000000..e69de29
diff --git a/src/app/system-management/user/edituser/edituser.component.ts b/src/app/system-management/user/edituser/edituser.component.ts
new file mode 100644
index 0000000..89b8f2b
--- /dev/null
+++ b/src/app/system-management/user/edituser/edituser.component.ts
@@ -0,0 +1,57 @@
+import { Component, OnInit, Input } from '@angular/core';
+import { NzModalRef } from 'ng-zorro-antd/modal';
+import { FormBuilder, FormGroup, Validators } from '@angular/forms';
+import { HttpClient } from '@angular/common/http';
+import { TreeService } from 'src/app/service/tree.service';
+
+@Component({
+ selector: 'app-edituser',
+ templateUrl: './edituser.component.html',
+ styleUrls: ['./edituser.component.scss']
+})
+export class EdituserComponent implements OnInit {
+
+ @Input() data?: any;
+ validateForm!: FormGroup;
+ constructor(private modal: NzModalRef, private fb: FormBuilder, private http: HttpClient, private toTree: TreeService) { }
+
+ ngOnInit(): void {
+ this.validateForm = this.fb.group({
+ account: [null, [Validators.required]],
+ name: [null, [Validators.required]],
+ organization: [null, [Validators.required]],
+ role: [null, [Validators.required]],
+ phonenum: [null, [Validators.required]]
+ });
+
+
+ console.log(this.data)
+ this.getAllRoles()
+ this.getAllOrganization()
+ }
+ destroyModal(): void {
+ this.modal.destroy({ data: 'this the result data' });
+ }
+
+ listOfData: any[] = [];
+
+ //获取角色列表
+ getAllRoles() {
+ this.http.get('/api/services/app/Role/GetAll').subscribe((data: any) => {
+ console.log('角色列表', data.result.items)
+ this.listOfData = data.result.items
+ })
+ }
+ //获取所有组织机构
+ nodes:any = []
+ getAllOrganization() {
+ this.http.get('/api/services/app/Organization/GetAll').subscribe((data: any) => {
+ data.result.items.forEach(element => {
+ element.key = element.code
+ element.title = element.displayName
+ });
+ this.nodes = [...this.toTree.toTree(data.result.items)]
+ })
+ }
+
+}
diff --git a/src/app/system-management/user/user.component.html b/src/app/system-management/user/user.component.html
index d039bb7..22c1157 100644
--- a/src/app/system-management/user/user.component.html
+++ b/src/app/system-management/user/user.component.html
@@ -1 +1,63 @@
-
user works!
+
+
+
+ 用户列表
+ {{usersNum}}名用户
+
+
+
+
+
+
+
+
+
+
+ |
+ 账号 |
+ 姓名 |
+ 角色 |
+ 所属机构 |
+ 操作 |
+
+
+
+
+  |
+ {{ data.userName }} |
+ {{ data.name }} |
+
+ {{item}}
+ |
+
+
+ 自营
+
+ {{data.organization}}
+ |
+
+ 编辑
+ 重置密码
+ 删除
+ |
+
+
+
+
+
+
diff --git a/src/app/system-management/user/user.component.scss b/src/app/system-management/user/user.component.scss
index e69de29..2cf35a9 100644
--- a/src/app/system-management/user/user.component.scss
+++ b/src/app/system-management/user/user.component.scss
@@ -0,0 +1,87 @@
+.userBox {
+ width: 100%;
+ height: 100%;
+ background: #FFFFFF;
+ box-sizing: border-box;
+ padding: 20px;
+ overflow: hidden;
+ display: flex;
+ flex-direction: column;
+
+ thead {}
+
+ tbody {
+ tr {
+ td:nth-child(1) {
+ text-align: right;
+ }
+ }
+
+ .operation {
+ a {
+ color: #2399FF;
+ margin-right: 18px;
+ }
+
+ a:last-child {
+ color: rgba(0, 13, 33, 0.48);
+ }
+ }
+ }
+}
+
+.topbox {
+ width: 100%;
+ height: 36px;
+ display: flex;
+ align-items: center;
+ justify-content: space-between;
+ margin-bottom: 12px;
+
+ .lefttop {
+ span:nth-child(1) {
+ color: #000D21;
+ margin-right: 16px;
+ }
+
+ span:nth-child(2) {
+ color: rgba(36, 36, 36, 0.24);
+ }
+ }
+
+ .righttop {
+ display: flex;
+
+ button {
+ margin-left: 16px;
+ }
+
+ nz-input-group {
+ height: 32px;
+ }
+ }
+}
+
+.tablebox {
+ flex: 1;
+ overflow-y: auto;
+}
+
+.pagination {
+ margin: 15px 0;
+ display: flex;
+ align-items: center;
+ justify-content: center;
+}
+
+.ortype {
+ width: 36px;
+ height: 20px;
+ background: #2399FF;
+ opacity: 1;
+ border-radius: 2px;
+ font-size: 12px;
+ margin-right: 8px;
+ color: #fff;
+ text-align: center;
+}
diff --git a/src/app/system-management/user/user.component.ts b/src/app/system-management/user/user.component.ts
index 5df0c83..955db12 100644
--- a/src/app/system-management/user/user.component.ts
+++ b/src/app/system-management/user/user.component.ts
@@ -1,15 +1,193 @@
-import { Component, OnInit } from '@angular/core';
-
+import { Component, OnInit, TemplateRef, ViewContainerRef } from '@angular/core';
+import { FormBuilder, FormGroup, Validators } from '@angular/forms';
+import { NzModalService } from 'ng-zorro-antd/modal';
+import { AdduserComponent } from './adduser/adduser.component';
+import { NzMessageService } from 'ng-zorro-antd/message';
+import { HttpClient } from '@angular/common/http';
+import { EdituserComponent } from './edituser/edituser.component';
@Component({
selector: 'app-user',
templateUrl: './user.component.html',
styleUrls: ['./user.component.scss']
})
export class UserComponent implements OnInit {
-
- constructor() { }
+ validateForm!: FormGroup;
+ constructor(private fb: FormBuilder, private modal: NzModalService, private viewContainerRef: ViewContainerRef, private message: NzMessageService, private http: HttpClient) { }
ngOnInit(): void {
+ this.validateForm = this.fb.group({
+ search: [null]
+ });
+ this.getAllUsers()
+ }
+
+
+ //获取所有用户
+ usersLIst: any = []
+ usersNum:string
+
+ SkipCount: number = 0 //0 16 32 48
+ MaxResultCount: number = 16
+ getAllUsers() {
+ let params = {
+ SkipCount: String(this.SkipCount),
+ MaxResultCount: String(this.MaxResultCount)
+ }
+ this.http.get('/api/services/app/User/GetAll', {
+ params: params
+ }).subscribe((data: any) => {
+ this.usersLIst = data.result.items
+ this.usersNum = data.result.totalCount
+ console.log('所有用户', this.usersLIst)
+ })
}
+ pageChange($event){
+ console.log('页码改变',$event)
+ }
+
+
+
+ //搜索框提交
+ submitForm(): void {
+ console.log(12345)
+ for (const i in this.validateForm.controls) {
+ this.validateForm.controls[i].markAsDirty();
+ this.validateForm.controls[i].updateValueAndValidity();
+ }
+ }
+
+ //新增用户
+ addUser(): void {
+ const modal = this.modal.create({
+ nzTitle: '新增用户',
+ nzContent: AdduserComponent,
+ nzViewContainerRef: this.viewContainerRef,
+ nzWidth: 288,
+ nzComponentParams: {
+ title: '',
+ subtitle: ''
+ },
+ nzOnOk: async () => {
+ console.log('hhhhhhh', instance.validateForm)
+ if (instance.validateForm.valid) {
+ await new Promise(resolve => {
+ let body = {
+ userName: instance.validateForm.value.account,
+ name: instance.validateForm.value.name,
+ organizationId: instance.validateForm.value.organization,
+ roleNames: instance.validateForm.value.role,
+ phoneNumber: instance.validateForm.value.phonenum,
+ isActive: true
+ }
+ this.http.post('/api/services/app/User/Create', body).subscribe(data => {
+ resolve(data)
+ this.message.create('success', '创建成功!');
+ this.getAllUsers()
+ return true
+ }, err => {
+ resolve(err)
+ this.message.create('warning', '创建失败');
+ return false
+ })
+ })
+ } else {
+ this.message.create('warning', '请填写完整!');
+ return false
+ }
+ }
+ });
+ const instance = modal.getContentComponent();
+ modal.afterOpen.subscribe(() => console.log('[afterOpen] emitted!'));
+ // Return a result when closed
+ modal.afterClose.subscribe(result => console.log('[afterClose] The result is:', result));
+ }
+
+ //编辑用户
+ editUser(data): void {
+ const modal = this.modal.create({
+ nzTitle: '编辑用户',
+ nzContent: EdituserComponent,
+ nzViewContainerRef: this.viewContainerRef,
+ nzWidth: 288,
+ nzComponentParams: {
+ data: data,
+ },
+ nzOnOk: async () => {
+ console.log('hhhhhhh', instance.validateForm)
+ if (instance.validateForm.valid) {
+ await new Promise(resolve => {
+ let body = {
+ userName: instance.validateForm.value.account,
+ name: instance.validateForm.value.name,
+ organizationId: instance.validateForm.value.organization,
+ roleNames: instance.validateForm.value.role,
+ phoneNumber: instance.validateForm.value.phonenum,
+ isActive: true
+ }
+ this.http.post('/api/services/app/User/Create', body).subscribe(data => {
+ resolve(data)
+ this.message.create('success', '创建成功!');
+ this.getAllUsers()
+ return true
+ }, err => {
+ resolve(err)
+ this.message.create('warning', '创建失败');
+ return false
+ })
+ })
+ } else {
+ this.message.create('warning', '请填写完整!');
+ return false
+ }
+ }
+ });
+ const instance = modal.getContentComponent();
+ }
+
+ //重置密码
+ resetPassword(item) {
+ this.modal.confirm({
+ nzTitle: `确定要重置${item.userName}这个账户的密码吗?`,
+ nzOkText: '确定',
+ nzOkType: 'primary',
+ nzOnOk: () => {
+ this.http.delete('/api/services/app/Role/Delete', {
+ params: {
+ Id: item.id
+ }
+ }).subscribe(data => {
+ this.message.create('success', '重置成功!');
+ this.getAllUsers()
+ })
+ },
+ nzCancelText: '取消',
+ nzOnCancel: () => {
+
+ }
+ });
+ }
+
+ //删除
+ delete(item) {
+ this.modal.confirm({
+ nzTitle: `确定要删除${item.userName}这个账户吗?`,
+ nzOkText: '确定',
+ nzOkType: 'danger',
+ nzOnOk: () => {
+ this.http.delete('/api/services/app/Role/Delete', {
+ params: {
+ Id: item.id
+ }
+ }).subscribe(data => {
+ this.message.create('success', '删除成功!');
+ this.getAllUsers()
+ })
+ },
+ nzCancelText: '取消',
+ nzOnCancel: () => {
+
+ }
+ });
+ }
}
diff --git a/src/app/ui/tabbar/tabbar.component.html b/src/app/ui/tabbar/tabbar.component.html
index 15c0c56..523028d 100644
--- a/src/app/ui/tabbar/tabbar.component.html
+++ b/src/app/ui/tabbar/tabbar.component.html
@@ -16,7 +16,9 @@
- - 系统管理
+ - 基本信息
+ - 器材信息
+ - 系统管理
- 退出系统
diff --git a/src/app/ui/tabbar/tabbar.component.ts b/src/app/ui/tabbar/tabbar.component.ts
index 5d2dada..776f81d 100644
--- a/src/app/ui/tabbar/tabbar.component.ts
+++ b/src/app/ui/tabbar/tabbar.component.ts
@@ -59,9 +59,12 @@ export class TabbarComponent implements OnInit {
this.cookieService.set("refreshToken", '', new Date(new Date().getTime() + 1), '/');
this.router.navigate(['/login'])
}
- system(){
- this.router.navigate(['/system'])
+
+ navChange(router){
+ this.router.navigate([router])
}
+
+
//修改密码
changpsw() {
// let dialogRef = this.dialog.open(ChangepasswordComponent, { width: '348.000051px' });
diff --git a/src/assets/images/icon/admin.png b/src/assets/images/icon/admin.png
new file mode 100644
index 0000000..f7f11ef
Binary files /dev/null and b/src/assets/images/icon/admin.png differ
diff --git a/src/assets/images/icon/organization.png b/src/assets/images/icon/organization.png
new file mode 100644
index 0000000..6fc46c2
Binary files /dev/null and b/src/assets/images/icon/organization.png differ
diff --git a/src/assets/images/icon/orgrey.png b/src/assets/images/icon/orgrey.png
new file mode 100644
index 0000000..b29d3f9
Binary files /dev/null and b/src/assets/images/icon/orgrey.png differ
diff --git a/src/assets/images/icon/power.png b/src/assets/images/icon/power.png
new file mode 100644
index 0000000..d9e9600
Binary files /dev/null and b/src/assets/images/icon/power.png differ
diff --git a/src/assets/images/icon/role.png b/src/assets/images/icon/role.png
new file mode 100644
index 0000000..9ec88e9
Binary files /dev/null and b/src/assets/images/icon/role.png differ
diff --git a/src/assets/images/icon/user.png b/src/assets/images/icon/user.png
new file mode 100644
index 0000000..6962ffd
Binary files /dev/null and b/src/assets/images/icon/user.png differ
diff --git a/src/assets/images/user.png b/src/assets/images/user.png
new file mode 100644
index 0000000..95dd792
Binary files /dev/null and b/src/assets/images/user.png differ
diff --git a/src/assets/images/userbig.png b/src/assets/images/userbig.png
new file mode 100644
index 0000000..e3a8388
Binary files /dev/null and b/src/assets/images/userbig.png differ
diff --git a/src/styles.scss b/src/styles.scss
index 92c1a83..f53bed5 100644
--- a/src/styles.scss
+++ b/src/styles.scss
@@ -102,15 +102,5 @@ h1 {
font-size: 16px;
}
-//滚动条样式
-::-webkit-scrollbar {
- width: 10px;
-}
-::-webkit-scrollbar-thumb {
- background-image: linear-gradient(#2495f8, #1c73c2,#0a3d6a, #061d3c);
-}
-::-webkit-scrollbar-track {
- background-color: #061d3c;
-}
diff --git a/src/theme.less b/src/theme.less
index 6c9653c..88ed239 100644
--- a/src/theme.less
+++ b/src/theme.less
@@ -1,59 +1,29 @@
@import "../node_modules/ng-zorro-antd/ng-zorro-antd.less";
-// @component-background: #002552;
-
-
-
-@border-color-base: #91CCFF;
-
-@select-background: transparent;
-
-.ant-select-single:not(.ant-select-customize-input) .ant-select-selector,
-.ant-picker,
-.ant-btn {
- border-radius: 0px;
-}
-.ant-btn:hover, .ant-btn:focus, .ant-btn:active, .ant-btn.active{
- // background: #083461;
-}
-//select picker 小剪头
-.ant-select-arrow,
-.ant-picker-separator {
- color: #36A2FF;
-}
-
-//日期选择器
-@input-placeholder-color: #345d85;
-
-.ant-picker-suffix,
-.ant-picker-input>input {
- color: rgba(145, 204, 255, 0.95);
-}
+//分页器
+#recordsboxadmin,
+#recordsbox {
-//弹窗遮罩层
-.ant-modal-mask {
- background: rgba(0, 0, 0, 0.05);
-}
+ .ant-pagination-total-text,
+ .ant-pagination-options-quick-jumper {
+ color: white
+ }
-//分页器
-.ant-pagination-total-text,
-.ant-pagination-options-quick-jumper {
- color: white
-}
+ .ant-pagination-item a,
+ .ant-pagination-prev .ant-pagination-item-link,
+ .ant-pagination-next .ant-pagination-item-link,
+ .ant-pagination-options-quick-jumper input {
+ color: white;
+ background: #0e2f4e;
+ }
-.ant-pagination-item a,
-.ant-pagination-prev .ant-pagination-item-link,
-.ant-pagination-next .ant-pagination-item-link,
-.ant-pagination-options-quick-jumper input {
- color: white;
- background: #0e2f4e;
+ .ant-pagination-item-active a {
+ background: #107495;
+ }
}
-.ant-pagination-item-active a {
- background: #107495;
-}
//查询重置按钮
@@ -156,3 +126,111 @@
-webkit-font-size: 16px !important;
}
}
+
+//表格
+#userBox,
+#roleBox {
+ .ant-table-thead>tr>th {
+ background: rgba(145, 204, 255, 0.15);
+ }
+}
+
+@select-background: transparent;
+@border-color-base: #91CCFF;
+
+//日期选择器
+// @input-placeholder-color: #345d85;
+#recordsboxadmin,
+#recordsbox,
+#warningbox,
+#warningboxadmin {
+ ::-webkit-input-placeholder {
+ /* WebKit browsers */
+ color: #345d85;
+ }
+
+ //滚动条样式
+ ::-webkit-scrollbar {
+ width: 10px;
+ }
+
+ ::-webkit-scrollbar-thumb {
+ background-image: linear-gradient(#2495f8, #1c73c2, #0a3d6a, #061d3c);
+ }
+
+ ::-webkit-scrollbar-track {
+ background-color: #061d3c;
+ }
+
+
+
+
+ .ant-select-single:not(.ant-select-customize-input) .ant-select-selector,
+ .ant-picker,
+ .ant-btn {
+ border-radius: 0px;
+ }
+
+ //select picker 小剪头
+ .ant-select-arrow,
+ .ant-picker-separator {
+ color: #36A2FF;
+ }
+
+ //日期选择器
+ // @input-placeholder-color: #345d85;
+
+ .ant-picker-suffix,
+ .ant-picker-input>input {
+ color: rgba(145, 204, 255, 0.95);
+ }
+
+
+ //弹窗遮罩层
+ .ant-modal-mask {
+ background: rgba(0, 0, 0, 0.05);
+ }
+
+ //遮罩层
+ .vertical-center-modal {
+ display: flex;
+ align-items: center;
+ justify-content: center;
+ }
+
+ .ant-modal-body {
+ background: #072549;
+ height: 660px;
+ padding: 5px;
+ // border: 1px solid #8eb9e3;
+ box-shadow: 0 0 3px #8eb9e3;
+ color: #fff;
+ }
+
+ .ant-modal-close-x {
+ width: 36px;
+ height: 36px;
+ line-height: 36px;
+ color: white;
+ }
+
+ .vertical-center-modal .ant-modal {
+ top: 0;
+ }
+}
+
+// //弹窗遮罩层
+// .ant-modal-mask {
+// background: rgba(0, 0, 0, 0.05);
+// }
+
+
+#orbox {
+ nz-tree {
+ width: 660px;
+ }
+
+ nz-tree-node {
+ position: relative;
+ }
+}