Commit 10f3d4fb authored by xiaowenjie's avatar xiaowenjie
parents f63aadf8 cef72bc9
...@@ -75,6 +75,8 @@ import {PlanModalComponent} from './work/modal/plan-modal/plan-modal.component'; ...@@ -75,6 +75,8 @@ import {PlanModalComponent} from './work/modal/plan-modal/plan-modal.component';
import {SelectPersonComponent} from './modal/select-person/select-person.component'; import {SelectPersonComponent} from './modal/select-person/select-person.component';
import {SelectRoleComponent} from './modal/select-role/select-role.component'; import {SelectRoleComponent} from './modal/select-role/select-role.component';
import {SeparationComponent} from './system/modal/separation/separation.component'; import {SeparationComponent} from './system/modal/separation/separation.component';
import {SystemComponent} from './system/modal/system/system.component';
import {SecurityComponent} from './system/modal/security/security.component';
@NgModule({ @NgModule({
imports: [ imports: [
...@@ -149,7 +151,9 @@ import {SeparationComponent} from './system/modal/separation/separation.componen ...@@ -149,7 +151,9 @@ import {SeparationComponent} from './system/modal/separation/separation.componen
PlanModalComponent, PlanModalComponent,
SelectPersonComponent, SelectPersonComponent,
SelectRoleComponent, SelectRoleComponent,
SeparationComponent SeparationComponent,
SystemComponent,
SecurityComponent,
], ],
providers:[ providers:[
OverAllService, OverAllService,
......
...@@ -14,8 +14,7 @@ ...@@ -14,8 +14,7 @@
</div> </div>
<div nz-col [nzSpan]="12" style="text-align: right"> <div nz-col [nzSpan]="12" style="text-align: right">
<nz-dropdown [nzTrigger]="'click'"> <nz-dropdown [nzTrigger]="'click'">
<a nz-dropdown> <a nz-dropdown>{{userName}}<i class="anticon anticon-down"></i>
Admin <i class="anticon anticon-down"></i>
</a> </a>
<ul nz-menu> <ul nz-menu>
<li nz-menu-item>设置</li> <li nz-menu-item>设置</li>
......
...@@ -26,6 +26,7 @@ export class NavbarComponent implements OnInit ,AfterViewChecked{ ...@@ -26,6 +26,7 @@ export class NavbarComponent implements OnInit ,AfterViewChecked{
token: boolean; token: boolean;
isBool = false; isBool = false;
userName="";
constructor( constructor(
private loginService: LoginService, private loginService: LoginService,
private principal: Principal, private principal: Principal,
......
...@@ -18,37 +18,8 @@ ...@@ -18,37 +18,8 @@
</div> </div>
</div> </div>
<div nz-row class="search-form"> <!--系统管理员-->
<div nz-col nzSpan="16"> <smart-system #smartSystem></smart-system>
</div>
<div nz-col nzSpan="8" class="text-right"> <!--安全管理员-->
<input nz-input placeholder="角色/权限模块/资源权限"> <smart-security #smartSecurity></smart-security>
<button nz-button nzType="default"><i class="anticon anticon-search"></i>搜索</button>
</div>
</div>
<nz-tabset [nzTabPosition]="'top'" [nzType]="'card'">
<nz-tab *ngFor="let tab of tabs" [nzTitle]="tab">
<nz-table #basicTable [nzData]="dataSet">
<thead>
<tr>
<th>操作用户</th>
<th>操作内容</th>
<th>提交时间</th>
<th>审核状态</th>
<th>审核人</th>
<th>审核时间</th>
</tr>
</thead>
<tbody>
<tr *ngFor="let data of basicTable.data">
<td>{{data.key1}}</td>
<td>{{data.key2}}</td>
<td>{{data.key3}}</td>
<td>{{data.key4}}</td>
<td>{{data.key5}}</td>
<td>{{data.key6}}</td>
</tr>
</tbody>
</nz-table>
</nz-tab>
</nz-tabset>
<div nz-row class="search-form">
<div nz-col nzSpan="16">
</div>
<div nz-col nzSpan="8" class="text-right">
<input nz-input placeholder="角色/权限模块/资源权限">
<button nz-button nzType="default"><i class="anticon anticon-search"></i>搜索</button>
</div>
</div>
<nz-tabset [nzTabPosition]="'top'" [nzType]="'card'">
<nz-tab nzTitle="待审批">
<nz-table #basicTable [nzData]="noList">
<thead>
<tr>
<th>操作用户</th>
<th>操作内容</th>
<th>提交时间</th>
<th>审核状态</th>
<th>审核人</th>
<th>审核时间</th>
</tr>
</thead>
<tbody>
<tr *ngFor="let data of basicTable.data">
<td>{{data.entityName}}</td>
<td>{{data.key2}}</td>
<td>{{data.createTime | date:"yyyy-MM-dd HH:mm:ss"}}</td>
<td>
<span *ngIf="data.status == 0">审批通过</span>
<span *ngIf="data.status == 1">审批驳回</span>
<span *ngIf="data.status == 2">新增用户待审批</span>
<span *ngIf="data.status == 3">修改用户待审批</span>
<span *ngIf="data.status == 4">注销用户待审批</span>
<span *ngIf="data.status == 5">提交人主动撤回,进行重新提交或者删除当前提交</span>
<span *ngIf="data.status == 6">兼职待审批</span>
<span *ngIf="data.status == 7">撤销兼职待审批</span>
<span *ngIf="data.status == 8">改变组织待审批</span>
<span *ngIf="data.status == 9">改变组织退回</span>
<span *ngIf="data.status == 10">授予角色待审批</span>
<span *ngIf="data.status == 11">授予用户待审批</span>
<span *ngIf="data.status == 12">撤销角色待审批</span>
<span *ngIf="data.status == 13">撤销用户待审批</span>
<span *ngIf="data.status == 14">绑定组织待审批</span>
<span *ngIf="data.status == 15">冻结用户待审批</span>
<span *ngIf="data.status == 16">删除绑定组织待审批</span>
<span *ngIf="data.status == 17">恢复用户待审批</span>
<span *ngIf="data.status == 18">初始化密码待审批</span>
<span *ngIf="data.status == 19">复制用户待审批</span>
<span *ngIf="data.status == 20">置为临时角色待审批</span>
<span *ngIf="data.status == 21">置为永久角色待审批</span>
</td>
<td>{{data.key5}}</td>
<td>{{data.key6}}</td>
</tr>
</tbody>
</nz-table>
</nz-tab>
<nz-tab nzTitle="已审批">
<nz-table #basicTable [nzData]="areadyList">
<thead>
<tr>
<th>操作用户</th>
<th>操作内容</th>
<th>提交时间</th>
<th>审核状态</th>
<th>审核人</th>
<th>审核时间</th>
</tr>
</thead>
<tbody>
<tr *ngFor="let data of basicTable.data">
<td>{{data.entityName}}</td>
<td>{{data.key2}}</td>
<td>{{data.createTime | date:"yyyy-MM-dd HH:mm:ss"}}</td>
<td>
<span *ngIf="data.status == 0">审批通过</span>
<span *ngIf="data.status == 1">审批驳回</span>
<span *ngIf="data.status == 2">新增用户待审批</span>
<span *ngIf="data.status == 3">修改用户待审批</span>
<span *ngIf="data.status == 4">注销用户待审批</span>
<span *ngIf="data.status == 5">提交人主动撤回,进行重新提交或者删除当前提交</span>
<span *ngIf="data.status == 6">兼职待审批</span>
<span *ngIf="data.status == 7">撤销兼职待审批</span>
<span *ngIf="data.status == 8">改变组织待审批</span>
<span *ngIf="data.status == 9">改变组织退回</span>
<span *ngIf="data.status == 10">授予角色待审批</span>
<span *ngIf="data.status == 11">授予用户待审批</span>
<span *ngIf="data.status == 12">撤销角色待审批</span>
<span *ngIf="data.status == 13">撤销用户待审批</span>
<span *ngIf="data.status == 14">绑定组织待审批</span>
<span *ngIf="data.status == 15">冻结用户待审批</span>
<span *ngIf="data.status == 16">删除绑定组织待审批</span>
<span *ngIf="data.status == 17">恢复用户待审批</span>
<span *ngIf="data.status == 18">初始化密码待审批</span>
<span *ngIf="data.status == 19">复制用户待审批</span>
<span *ngIf="data.status == 20">置为临时角色待审批</span>
<span *ngIf="data.status == 21">置为永久角色待审批</span>
</td>
<td>{{data.key5}}</td>
<td>{{data.key6}}</td>
</tr>
</tbody>
</nz-table>
</nz-tab>
</nz-tabset>
import {Component, OnInit} from '@angular/core';
import {SystemService} from '../../system.service';
import {pageSize} from '../../../app.constants';
@Component({
selector: 'smart-security',
templateUrl: './security.component.html',
styles: []
})
export class SecurityComponent implements OnInit {
pageSize = pageSize;
//已审批
pageNoAlready = 1;
totalNumAlready;
areadyList = [];
//未审批
pageNoNo = 1;
totalNumNo;
noList = [];
constructor(private systemSer: SystemService) {
}
ngOnInit() {
this.getListAlready();
this.getListNo();
}
getListAlready() {
const data1 = {
pageNo: this.pageNoAlready,
pageSize: this.pageSize
};
this.systemSer.approveListSafeManager(data1).subscribe(
(res) => {
this.areadyList = res.data;
}
);
}
getListNo() {
const data1 = {
pageNo: this.pageNoNo,
pageSize: this.pageSize
};
this.systemSer.unapproveListSafeManager(data1).subscribe(
(res) => {
this.noList = res.data;
}
);
}
}
<div nz-row class="search-form">
<div nz-col nzSpan="16">
</div>
<div nz-col nzSpan="8" class="text-right">
<input nz-input placeholder="角色/权限模块/资源权限">
<button nz-button nzType="default"><i class="anticon anticon-search"></i>搜索</button>
</div>
</div>
<nz-tabset [nzTabPosition]="'top'" [nzType]="'card'">
<nz-tab nzTitle="待审批">
<nz-table #basicTable [nzData]="noList">
<thead>
<tr>
<th>操作用户</th>
<th>操作内容</th>
<th>提交时间</th>
<th>审核状态</th>
<th>审核人</th>
<th>审核时间</th>
</tr>
</thead>
<tbody>
<tr *ngFor="let data of basicTable.data">
<td>{{data.entityName}}</td>
<td>{{data.key2}}</td>
<td>{{data.createTime | date:"yyyy-MM-dd HH:mm:ss"}}</td>
<td>
<span *ngIf="data.status == 0">审批通过</span>
<span *ngIf="data.status == 1">审批驳回</span>
<span *ngIf="data.status == 2">新增用户待审批</span>
<span *ngIf="data.status == 3">修改用户待审批</span>
<span *ngIf="data.status == 4">注销用户待审批</span>
<span *ngIf="data.status == 5">提交人主动撤回,进行重新提交或者删除当前提交</span>
<span *ngIf="data.status == 6">兼职待审批</span>
<span *ngIf="data.status == 7">撤销兼职待审批</span>
<span *ngIf="data.status == 8">改变组织待审批</span>
<span *ngIf="data.status == 9">改变组织退回</span>
<span *ngIf="data.status == 10">授予角色待审批</span>
<span *ngIf="data.status == 11">授予用户待审批</span>
<span *ngIf="data.status == 12">撤销角色待审批</span>
<span *ngIf="data.status == 13">撤销用户待审批</span>
<span *ngIf="data.status == 14">绑定组织待审批</span>
<span *ngIf="data.status == 15">冻结用户待审批</span>
<span *ngIf="data.status == 16">删除绑定组织待审批</span>
<span *ngIf="data.status == 17">恢复用户待审批</span>
<span *ngIf="data.status == 18">初始化密码待审批</span>
<span *ngIf="data.status == 19">复制用户待审批</span>
<span *ngIf="data.status == 20">置为临时角色待审批</span>
<span *ngIf="data.status == 21">置为永久角色待审批</span>
</td>
<td>{{data.key5}}</td>
<td>{{data.key6}}</td>
</tr>
</tbody>
</nz-table>
</nz-tab>
<nz-tab nzTitle="已审批">
<nz-table #basicTable [nzData]="areadyList">
<thead>
<tr>
<th>操作用户</th>
<th>操作内容</th>
<th>提交时间</th>
<th>审核状态</th>
<th>审核人</th>
<th>审核时间</th>
</tr>
</thead>
<tbody>
<tr *ngFor="let data of basicTable.data">
<td>{{data.entityName}}</td>
<td>{{data.key2}}</td>
<td>{{data.createTime | date:"yyyy-MM-dd HH:mm:ss"}}</td>
<td>
<span *ngIf="data.status == 0">审批通过</span>
<span *ngIf="data.status == 1">审批驳回</span>
<span *ngIf="data.status == 2">新增用户待审批</span>
<span *ngIf="data.status == 3">修改用户待审批</span>
<span *ngIf="data.status == 4">注销用户待审批</span>
<span *ngIf="data.status == 5">提交人主动撤回,进行重新提交或者删除当前提交</span>
<span *ngIf="data.status == 6">兼职待审批</span>
<span *ngIf="data.status == 7">撤销兼职待审批</span>
<span *ngIf="data.status == 8">改变组织待审批</span>
<span *ngIf="data.status == 9">改变组织退回</span>
<span *ngIf="data.status == 10">授予角色待审批</span>
<span *ngIf="data.status == 11">授予用户待审批</span>
<span *ngIf="data.status == 12">撤销角色待审批</span>
<span *ngIf="data.status == 13">撤销用户待审批</span>
<span *ngIf="data.status == 14">绑定组织待审批</span>
<span *ngIf="data.status == 15">冻结用户待审批</span>
<span *ngIf="data.status == 16">删除绑定组织待审批</span>
<span *ngIf="data.status == 17">恢复用户待审批</span>
<span *ngIf="data.status == 18">初始化密码待审批</span>
<span *ngIf="data.status == 19">复制用户待审批</span>
<span *ngIf="data.status == 20">置为临时角色待审批</span>
<span *ngIf="data.status == 21">置为永久角色待审批</span>
</td>
<td>{{data.key5}}</td>
<td>{{data.key6}}</td>
</tr>
</tbody>
</nz-table>
</nz-tab>
</nz-tabset>
import { Component, OnInit } from '@angular/core';
import {SystemService} from '../../system.service';
import {pageSize} from '../../../app.constants';
@Component({
selector: 'smart-system',
templateUrl: './system.component.html',
styles: []
})
export class SystemComponent implements OnInit {
pageSize = pageSize;
//已审批
pageNoAlready = 1;
totalNumAlready;
areadyList = [];
//未审批
pageNoNo = 1;
totalNumNo;
noList = [];
constructor(private systemSer: SystemService) {
}
ngOnInit() {
this.getListAlready();
this.getListNo();
}
getListAlready() {
const data1 = {
pageNo: this.pageNoAlready,
pageSize: this.pageSize
};
this.systemSer.approveListSafeManager(data1).subscribe(
(res) => {
this.areadyList = res.data;
}
);
}
getListNo() {
const data1 = {
pageNo: this.pageNoNo,
pageSize: this.pageSize
};
this.systemSer.unApproveListSystemManager(data1).subscribe(
(res) => {
this.noList = res.data;
}
);
}
}
...@@ -99,4 +99,39 @@ export class SystemService { ...@@ -99,4 +99,39 @@ export class SystemService {
roleList(data): Observable<any>{ roleList(data): Observable<any>{
return this.http.get(SERVER_API_URL + '/user/roleList?'+this.toTree.toQuery(data) ); return this.http.get(SERVER_API_URL + '/user/roleList?'+this.toTree.toQuery(data) );
} }
//获取当前安全管理员已审批记录
approveListSafeManager(data): Observable<any>{
return this.http.get(SERVER_API_URL + '/approval/approveListSafeManager?'+this.toTree.toQuery(data) );
}
//获取当前安全管理员未审批记录
unapproveListSafeManager(data): Observable<any>{
return this.http.get(SERVER_API_URL + '/approval/unapproveListSafeManager?'+this.toTree.toQuery(data) );
}
//获取当前系统管理员的已审批记录
approveListSystemManager(data): Observable<any>{
return this.http.get(SERVER_API_URL + '/approval/approveListSystemManager?'+this.toTree.toQuery(data) );
}
//获取当前系统管理员的未审批记录
unApproveListSystemManager(data): Observable<any>{
return this.http.get(SERVER_API_URL + '/approval/unApproveListSystemManager?'+this.toTree.toQuery(data) );
}
//批量审批通过
approvalPass(data): Observable<any>{
return this.http.post(SERVER_API_URL + '/approval/pass', data);
}
//批量审批退回
approvalReject(data): Observable<any>{
return this.http.post(SERVER_API_URL + '/approval/reject', data);
}
//批量撤回审批
approvalRemove(data): Observable<any>{
return this.http.post(SERVER_API_URL + '/approval/remove', data);
}
} }
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