操作日志和数据同步用户体验及逻辑优化
This commit is contained in:
@@ -1,28 +1,35 @@
|
|||||||
<div class="system-main-container">
|
<div class="system-main-container">
|
||||||
<div class="system-main-content card">
|
<div class="system-main-content card">
|
||||||
<div nz-row>
|
<div>
|
||||||
<div nz-col nzSpan="8">
|
<div class="dip mr-5">
|
||||||
<nz-form-item >
|
<nz-form-item>
|
||||||
<nz-form-label class="left">请求的消息类型</nz-form-label>
|
<nz-form-label class="mr-1" style="vertical-align:top">请求的消息类型</nz-form-label>
|
||||||
<nz-form-control nzSpan="10">
|
<nz-form-control style="display:inline-block">
|
||||||
<nz-select style="width: 160px;" [(ngModel)]="selectedValue" nzAllowClear nzPlaceHolder="Choose">
|
<nz-select style="width: 200px;" [(ngModel)]="selectedValue" nzAllowClear nzPlaceHolder="Choose">
|
||||||
<nz-option nzValue="1" nzLabel="日航班计划"></nz-option>
|
<nz-option nzValue="1" nzLabel="日航班计划"></nz-option>
|
||||||
</nz-select>
|
</nz-select>
|
||||||
</nz-form-control>
|
</nz-form-control>
|
||||||
</nz-form-item>
|
</nz-form-item>
|
||||||
</div>
|
</div>
|
||||||
<div nz-col nzSpan="9">
|
<div class="dip">
|
||||||
<nz-form-item >
|
<nz-form-item>
|
||||||
<nz-form-label class="left">时间</nz-form-label>
|
<nz-form-label class="mr-1" style="vertical-align:top">时间</nz-form-label>
|
||||||
<nz-form-control nzSpan="20">
|
<nz-form-control style="display:inline-block">
|
||||||
<nz-range-picker [(ngModel)]="dateRange" (ngModelChange)="onChange($event)" nzShowTime></nz-range-picker>
|
<nz-date-picker class="mr-2" [nzShowToday]="false" [nzDisabledDate]="disabledStartDate" [nzShowTime]="{nzFormat:'HH:mm'}" nzFormat="yyyy-MM-dd HH:mm"
|
||||||
</nz-form-control>
|
[(ngModel)]="startValue" nzPlaceHolder="请选择开始日期" (ngModelChange)="onStartChange($event)"
|
||||||
</nz-form-item>
|
(nzOnOpenChange)="handleStartOpenChange($event)">
|
||||||
</div>
|
</nz-date-picker>
|
||||||
</div>
|
<nz-date-picker [nzShowToday]="false" [nzDisabledDate]="disabledEndDate" [nzShowTime]="{nzFormat:'HH:mm'}" nzFormat="yyyy-MM-dd HH:mm"
|
||||||
<div class="user-footer">
|
[(ngModel)]="endValue" nzPlaceHolder="请选择结束时间" [nzOpen]="endOpen" (ngModelChange)="onEndChange($event)"
|
||||||
<button (click)='save()' nz-button nzType="primary" class="mr10" [disabled]='!dateRange'>确定</button>
|
(nzOnOpenChange)="handleEndOpenChange($event)">
|
||||||
<button (click)='cancel()' nz-button nzType="default">取消</button>
|
</nz-date-picker>
|
||||||
</div>
|
</nz-form-control>
|
||||||
</div>
|
</nz-form-item>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="user-footer">
|
||||||
|
<button (click)='save()' nz-button nzType="primary" class="mr10" [disabled]='!dateRange'>确定</button>
|
||||||
|
<!-- <button (click)='cancel()' nz-button nzType="default">取消</button> -->
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
@@ -1,54 +1,88 @@
|
|||||||
import { Component, OnInit } from '@angular/core';
|
import { Component, OnInit } from '@angular/core';
|
||||||
import { HttpClientService } from '../../../services/http-client.service';
|
import { HttpClientService } from '../../../services/http-client.service';
|
||||||
import { Router } from '@angular/router';
|
import { Router } from '@angular/router';
|
||||||
import { NzMessageService,NzModalRef, NzModalService } from 'ng-zorro-antd';
|
import { NzMessageService, NzModalRef, NzModalService } from 'ng-zorro-antd';
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'app-data-synchronize',
|
selector: 'app-data-synchronize',
|
||||||
templateUrl: './data-synchronize.component.html',
|
templateUrl: './data-synchronize.component.html',
|
||||||
styleUrls: ['./data-synchronize.component.scss']
|
styleUrls: ['./data-synchronize.component.scss']
|
||||||
})
|
})
|
||||||
export class DataSynchronizeComponent implements OnInit {
|
export class DataSynchronizeComponent implements OnInit {
|
||||||
selectedValue:any='1';
|
selectedValue: any = '1';
|
||||||
dateRange:any='';
|
dateRange: any = '';
|
||||||
search:any={
|
search: any = {
|
||||||
startDate:'',
|
startDate: '',
|
||||||
endDate:''
|
endDate: ''
|
||||||
}
|
}
|
||||||
constructor(
|
constructor(
|
||||||
private http:HttpClientService,
|
private http: HttpClientService,
|
||||||
private message: NzMessageService,
|
private message: NzMessageService,
|
||||||
private modal: NzModalService,
|
) { }
|
||||||
) { }
|
|
||||||
|
|
||||||
ngOnInit() {
|
endOpen: boolean = false;
|
||||||
}
|
startValue: Date = null;
|
||||||
onChange(result: Date): void {
|
endValue: Date = null;
|
||||||
this.search.startDate=this.changeDate(result[0]);
|
|
||||||
this.search.endDate=this.changeDate(result[1]);
|
|
||||||
|
|
||||||
}
|
|
||||||
//日期时间处理
|
|
||||||
changeDate(time){
|
|
||||||
var date = new Date(time);
|
|
||||||
var Y = date.getFullYear()+'';
|
|
||||||
var M = (date.getMonth()+1 < 10 ? '0'+(date.getMonth()+1) : date.getMonth()+1)+'';
|
|
||||||
var D = (date.getDate()<10?'0'+date.getDate():date.getDate())+'';
|
|
||||||
var h = (date.getHours()<10?'0'+date.getHours():date.getHours())+'' ;
|
|
||||||
var m = (date.getMinutes()<10?'0'+date.getMinutes():date.getMinutes())+'';
|
|
||||||
var s = date.getSeconds()<10?'0'+date.getSeconds():date.getSeconds()+'';
|
|
||||||
return Y+'-'+M+'-'+D+' '+h+':'+m+':'+s;
|
|
||||||
}
|
|
||||||
|
|
||||||
//保存
|
ngOnInit() {
|
||||||
save(){
|
}
|
||||||
this.http.post('/msgexchangeapi/schd/sync',this.search).subscribe((json)=>{
|
|
||||||
if(json.is_success){
|
disabledStartDate = (startValue: Date): boolean => {
|
||||||
this.message.success(`提交成功!`);
|
if (!startValue || !this.endValue) {
|
||||||
}else{
|
return false;
|
||||||
this.message.error(`提交失败!`);
|
}
|
||||||
}
|
return startValue.getTime() >= this.endValue.getTime();
|
||||||
})
|
};
|
||||||
}
|
|
||||||
|
disabledEndDate = (endValue: Date): boolean => {
|
||||||
|
if (!endValue || !this.startValue) {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
return endValue.getTime() <= this.startValue.getTime();
|
||||||
|
};
|
||||||
|
|
||||||
|
onStartChange(date: Date): void {
|
||||||
|
this.startValue = date;
|
||||||
|
this.search.startDate = this.changeDate(date)
|
||||||
|
}
|
||||||
|
|
||||||
|
onEndChange(date: Date): void {
|
||||||
|
this.endValue = date;
|
||||||
|
this.search.endDate = this.changeDate(date)
|
||||||
|
console.log(this.search.endDate)
|
||||||
|
}
|
||||||
|
|
||||||
|
handleStartOpenChange(open: boolean): void {
|
||||||
|
if (!open && this.startValue) {
|
||||||
|
this.endOpen = true;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
handleEndOpenChange(open: boolean): void {
|
||||||
|
this.endOpen = open;
|
||||||
|
}
|
||||||
|
|
||||||
|
//日期时间处理
|
||||||
|
changeDate(time) {
|
||||||
|
var date = new Date(time);
|
||||||
|
var Y = date.getFullYear() + '';
|
||||||
|
var M = (date.getMonth() + 1 < 10 ? '0' + (date.getMonth() + 1) : date.getMonth() + 1) + '';
|
||||||
|
var D = (date.getDate() < 10 ? '0' + date.getDate() : date.getDate()) + '';
|
||||||
|
var h = (date.getHours() < 10 ? '0' + date.getHours() : date.getHours()) + '';
|
||||||
|
var m = (date.getMinutes() < 10 ? '0' + date.getMinutes() : date.getMinutes()) + '';
|
||||||
|
var s = date.getSeconds() < 10 ? '0' + date.getSeconds() : date.getSeconds() + '';
|
||||||
|
return Y + '-' + M + '-' + D + ' ' + h + ':' + m ;
|
||||||
|
}
|
||||||
|
|
||||||
|
//保存
|
||||||
|
save() {
|
||||||
|
this.http.post('/msgexchangeapi/schd/sync', this.search).subscribe((json) => {
|
||||||
|
if (json.is_success) {
|
||||||
|
this.message.success(`提交成功!`);
|
||||||
|
} else {
|
||||||
|
this.message.error(`提交失败!`);
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,63 +1,67 @@
|
|||||||
<div class="system-main-container">
|
<div class="system-main-container">
|
||||||
<div class="user-manage">
|
<div class="user-manage">
|
||||||
<div class="system-main-content card" id="main-box">
|
<div class="system-main-content card" id="main-box-logs">
|
||||||
|
<div class="search-box">
|
||||||
<div class="search-box">
|
<div class="dip mr-5">
|
||||||
<div nz-row>
|
<nz-form-item>
|
||||||
<div nz-col nzSpan="8">
|
<nz-form-label class="mr-1" style="vertical-align:top">关键词</nz-form-label>
|
||||||
<nz-form-item >
|
<nz-form-control style="display:inline-block">
|
||||||
<nz-form-label class="left">关键词</nz-form-label>
|
<input nz-input [(ngModel)]='search.keyword' placeholder="请输入关键词">
|
||||||
<nz-form-control nzSpan="17">
|
</nz-form-control>
|
||||||
<input nz-input [(ngModel)]='search.keyword' placeholder="请输入关键词">
|
</nz-form-item>
|
||||||
</nz-form-control>
|
</div>
|
||||||
</nz-form-item>
|
<div class="dip mr-4">
|
||||||
</div>
|
<nz-form-item>
|
||||||
<div nz-col nzSpan="9">
|
<nz-form-label class="mr-1" style="vertical-align:top">时间</nz-form-label>
|
||||||
<nz-form-item >
|
<nz-form-control style="display:inline-block">
|
||||||
<nz-form-label class="left">时间</nz-form-label>
|
<nz-date-picker [nzShowToday]="false" class="mr-2" [nzDisabledDate]="disabledStartDate" nzShowTime nzFormat="yyyy-MM-dd HH:mm:ss"
|
||||||
<nz-form-control nzSpan="20">
|
[(ngModel)]="startValue" nzPlaceHolder="请选择开始时间" (ngModelChange)="onStartChange($event)"
|
||||||
<nz-range-picker [(ngModel)]="dateRange" (ngModelChange)="onChange($event)" nzShowTime></nz-range-picker>
|
(nzOnOpenChange)="handleStartOpenChange($event)">
|
||||||
</nz-form-control>
|
</nz-date-picker>
|
||||||
</nz-form-item>
|
<nz-date-picker [nzShowToday]="false" [nzDisabledDate]="disabledEndDate" nzShowTime nzFormat="yyyy-MM-dd HH:mm:ss"
|
||||||
</div>
|
[(ngModel)]="endValue" nzPlaceHolder="请选择结束时间" [nzOpen]="endOpen"
|
||||||
<div nz-col nzSpan="6">
|
(ngModelChange)="onEndChange($event)" (nzOnOpenChange)="handleEndOpenChange($event)">
|
||||||
<nz-form-item >
|
</nz-date-picker>
|
||||||
<nz-form-control nzSpan="24">
|
</nz-form-control>
|
||||||
<button class="mr10" nz-button nzType="primary" (click)="queryTable()"><i nz-icon type="search"></i>查询</button>
|
</nz-form-item>
|
||||||
<button (click)="reset()" nz-button nzType="primary"><i nz-icon type="sync" theme="outline"></i>重置</button>
|
</div>
|
||||||
</nz-form-control>
|
<div class="dip">
|
||||||
</nz-form-item>
|
<nz-form-item>
|
||||||
</div>
|
<nz-form-control>
|
||||||
|
<button class="mr10" nz-button nzType="primary" (click)="queryTable()"><i nz-icon type="search"></i>查询</button>
|
||||||
</div>
|
<button (click)="reset()" nz-button nzType="primary"><i nz-icon type="sync" theme="outline"></i>重置</button>
|
||||||
</div>
|
</nz-form-control>
|
||||||
<app-request-status *ngIf='statusParamsTable.status!=4' [statusParams]='statusParamsTable'></app-request-status>
|
</nz-form-item>
|
||||||
<div class="table-box" *ngIf='statusParamsTable.status==3||statusParamsTable.status==4||statusParamsTable.status==0'>
|
</div>
|
||||||
<nz-table [nzShowPagination]='false' #dataSet [nzData]="tableData">
|
</div>
|
||||||
<thead>
|
<app-request-status *ngIf='statusParamsTable.status!=4' [statusParams]='statusParamsTable'></app-request-status>
|
||||||
<tr>
|
<div class="table-box" *ngIf='statusParamsTable.status==3||statusParamsTable.status==4||statusParamsTable.status==0'>
|
||||||
<th>序号</th>
|
<nz-table [nzShowPagination]='false' #dataSet [nzData]="tableData">
|
||||||
<th>用户名</th>
|
<thead>
|
||||||
<th>模块</th>
|
<tr>
|
||||||
<th>操作内容</th>
|
<th>序号</th>
|
||||||
<th>操作时间</th>
|
<th>用户名</th>
|
||||||
</tr>
|
<th>模块</th>
|
||||||
</thead>
|
<th>操作内容</th>
|
||||||
<tbody>
|
<th>操作时间</th>
|
||||||
<tr *ngFor="let item of dataSet.data;let i=index">
|
</tr>
|
||||||
<td>{{i+1}}</td>
|
</thead>
|
||||||
<td>{{item.user_name}}</td>
|
<tbody>
|
||||||
<td>{{item.model_name}}</td>
|
<tr *ngFor="let item of dataSet.data;let i=index">
|
||||||
<td>{{item.summary}}</td>
|
<td>{{i+1}}</td>
|
||||||
<td>{{item.log_datetime| date:'yyyy-MM-dd HH:mm:ss'}}</td>
|
<td>{{item.user_name}}</td>
|
||||||
</tr>
|
<td>{{item.model_name}}</td>
|
||||||
</tbody>
|
<td>{{item.summary}}</td>
|
||||||
</nz-table>
|
<td>{{item.log_datetime| date:'yyyy-MM-dd HH:mm:ss'}}</td>
|
||||||
<div class="page-box" *ngIf="statusParamsTable.status==3">
|
</tr>
|
||||||
<nz-pagination [nzPageIndex]="search.page_index" (nzPageIndexChange)='pageChange($event)' [nzPageSize]='search.page_size' [nzTotal]="collectionSize"></nz-pagination>
|
</tbody>
|
||||||
</div>
|
</nz-table>
|
||||||
</div>
|
<div class="page-box" *ngIf="statusParamsTable.status==3">
|
||||||
|
<nz-pagination [nzPageIndex]="search.page_index" (nzPageIndexChange)='pageChange($event)'
|
||||||
</div>
|
[nzPageSize]='search.page_size' [nzTotal]="collectionSize"></nz-pagination>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
@@ -3,94 +3,126 @@ import { HttpClientService } from '../../../services/http-client.service';
|
|||||||
import { Router } from '@angular/router';
|
import { Router } from '@angular/router';
|
||||||
import { NzMessageService } from 'ng-zorro-antd';
|
import { NzMessageService } from 'ng-zorro-antd';
|
||||||
|
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'app-operation-logs',
|
selector: 'app-operation-logs',
|
||||||
templateUrl: './operation-logs.component.html',
|
templateUrl: './operation-logs.component.html',
|
||||||
styleUrls: ['./operation-logs.component.scss']
|
styleUrls: ['./operation-logs.component.scss']
|
||||||
})
|
})
|
||||||
export class OperationLogsComponent implements OnInit {
|
export class OperationLogsComponent implements OnInit {
|
||||||
collectionSize:any ;
|
collectionSize: any;
|
||||||
public tableData:any=[];
|
public tableData: any = [];
|
||||||
statusParamsTable:any={ //获取用户列表接口的状态,0请求失败 1请求前 2请求中 3请求成功,有数据 4请求成功,无数据
|
statusParamsTable: any = { //获取用户列表接口的状态,0请求失败 1请求前 2请求中 3请求成功,有数据 4请求成功,无数据
|
||||||
status:1,
|
status: 1,
|
||||||
}
|
}
|
||||||
public search:any={
|
public search: any = {
|
||||||
page_index:'1',
|
page_index: '1',
|
||||||
page_size:'10',
|
page_size: '10',
|
||||||
date_start:'',
|
date_start: '',
|
||||||
date_end:'',
|
date_end: '',
|
||||||
keyword:'',
|
keyword: '',
|
||||||
orgId:'',
|
orgId: '',
|
||||||
}
|
}
|
||||||
logType:any={
|
logType: any = {
|
||||||
'LOGIN':'登录',
|
'LOGIN': '登录',
|
||||||
'LOGOUT':'退出',
|
'LOGOUT': '退出',
|
||||||
'USER_UI_SET':'修改用户设置',
|
'USER_UI_SET': '修改用户设置',
|
||||||
'USER_INFO_OPT':'增删改用户信息',
|
'USER_INFO_OPT': '增删改用户信息',
|
||||||
};
|
};
|
||||||
optType:any={
|
optType: any = {
|
||||||
'ADD':'新增',
|
'ADD': '新增',
|
||||||
'UPDATE':'修改',
|
'UPDATE': '修改',
|
||||||
'DELETE':'删除',
|
'DELETE': '删除',
|
||||||
};
|
};
|
||||||
dateRange = [];
|
|
||||||
constructor(
|
|
||||||
private http:HttpClientService,
|
|
||||||
private router:Router,
|
|
||||||
private message: NzMessageService,
|
|
||||||
) { }
|
|
||||||
|
|
||||||
ngOnInit() {
|
endOpen: boolean = false;
|
||||||
this.queryTable();
|
startValue: Date = null;
|
||||||
}
|
endValue: Date = null;
|
||||||
onChange(result: Date): void {
|
|
||||||
this.search.date_start=this.changeDate(result[0]);
|
constructor(
|
||||||
this.search.date_end=this.changeDate(result[1]);
|
private http: HttpClientService,
|
||||||
|
) { }
|
||||||
}
|
|
||||||
//日期时间处理
|
ngOnInit() {
|
||||||
changeDate(time){
|
this.queryTable();
|
||||||
var date = new Date(time);
|
}
|
||||||
var Y = date.getFullYear()+'';
|
|
||||||
var M = (date.getMonth()+1 < 10 ? '0'+(date.getMonth()+1) : date.getMonth()+1)+'';
|
disabledStartDate = (startValue: Date): boolean => {
|
||||||
var D = (date.getDate()<10?'0'+date.getDate():date.getDate())+'';
|
if (!startValue || !this.endValue) {
|
||||||
var h = (date.getHours()<10?'0'+date.getHours():date.getHours())+'' ;
|
return false;
|
||||||
var m = (date.getMinutes()<10?'0'+date.getMinutes():date.getMinutes())+'';
|
}
|
||||||
var s = date.getSeconds()<10?'0'+date.getSeconds():date.getSeconds()+'';
|
return startValue.getTime() >= this.endValue.getTime();
|
||||||
return Y+'-'+M+'-'+D+' '+h+':'+m+':'+s;
|
};
|
||||||
}
|
|
||||||
//重置,重置搜索条件
|
disabledEndDate = (endValue: Date): boolean => {
|
||||||
reset(){
|
if (!endValue || !this.startValue) {
|
||||||
this.search.page_index=1;
|
return false;
|
||||||
this.search.page_size=10;
|
}
|
||||||
this.search.keyword='';
|
return endValue.getTime() <= this.startValue.getTime();
|
||||||
this.search.date_start='';
|
};
|
||||||
this.search.date_end='';
|
|
||||||
this.queryTable();
|
onStartChange(date: Date): void {
|
||||||
}
|
this.startValue = date;
|
||||||
//获取列表
|
this.search.date_start = this.changeDate(date)
|
||||||
queryTable():void{
|
}
|
||||||
this.statusParamsTable.status=1;
|
|
||||||
this.tableData=[];
|
onEndChange(date: Date): void {
|
||||||
this.http.get('/sysapi/oplog/list',this.search).subscribe((json)=>{
|
this.endValue = date;
|
||||||
if(json.is_success){
|
this.search.date_end = this.changeDate(date)
|
||||||
this.tableData=json.body.recordList;
|
}
|
||||||
this.collectionSize=json.body.recordCount;
|
|
||||||
if(json.body.recordList&&json.body.recordList.length>0){
|
handleStartOpenChange(open: boolean): void {
|
||||||
this.statusParamsTable.status=3;
|
if (!open && this.startValue) {
|
||||||
}else{
|
this.endOpen = true;
|
||||||
this.statusParamsTable.status=4;
|
}
|
||||||
}
|
}
|
||||||
}else{
|
|
||||||
this.statusParamsTable.status=0;
|
handleEndOpenChange(open: boolean): void {
|
||||||
}
|
this.endOpen = open;
|
||||||
})
|
}
|
||||||
}
|
|
||||||
//翻页
|
//日期时间处理
|
||||||
pageChange(event){
|
changeDate(time) {
|
||||||
this.search.page_index=event;
|
var date = new Date(time);
|
||||||
this.queryTable();
|
var Y = date.getFullYear() + '';
|
||||||
}
|
var M = (date.getMonth() + 1 < 10 ? '0' + (date.getMonth() + 1) : date.getMonth() + 1) + '';
|
||||||
|
var D = (date.getDate() < 10 ? '0' + date.getDate() : date.getDate()) + '';
|
||||||
|
var h = (date.getHours() < 10 ? '0' + date.getHours() : date.getHours()) + '';
|
||||||
|
var m = (date.getMinutes() < 10 ? '0' + date.getMinutes() : date.getMinutes()) + '';
|
||||||
|
var s = date.getSeconds() < 10 ? '0' + date.getSeconds() : date.getSeconds() + '';
|
||||||
|
return Y + '-' + M + '-' + D + ' ' + h + ':' + m + ':' + s;
|
||||||
|
}
|
||||||
|
//重置,重置搜索条件
|
||||||
|
reset() {
|
||||||
|
this.search.page_index = 1;
|
||||||
|
this.search.page_size = 10;
|
||||||
|
this.search.keyword = '';
|
||||||
|
this.search.date_start = '';
|
||||||
|
this.startValue = null;
|
||||||
|
this.search.date_end = '';
|
||||||
|
this.endValue = null;
|
||||||
|
}
|
||||||
|
//获取列表
|
||||||
|
queryTable(): void {
|
||||||
|
this.statusParamsTable.status = 1;
|
||||||
|
this.tableData = [];
|
||||||
|
this.http.get('/sysapi/oplog/list', this.search).subscribe((json) => {
|
||||||
|
if (json.is_success) {
|
||||||
|
this.tableData = json.body.recordList;
|
||||||
|
this.collectionSize = json.body.recordCount;
|
||||||
|
if (json.body.recordList && json.body.recordList.length > 0) {
|
||||||
|
this.statusParamsTable.status = 3;
|
||||||
|
} else {
|
||||||
|
this.statusParamsTable.status = 4;
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
this.statusParamsTable.status = 0;
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
||||||
|
//翻页
|
||||||
|
pageChange(event) {
|
||||||
|
this.search.page_index = event;
|
||||||
|
this.queryTable();
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
<div class="system-main-container">
|
<div class="system-main-container">
|
||||||
<div class="card " id="main-box">
|
<div class="card " id="main-box-setting">
|
||||||
<nz-tabset [nzTabPosition]="'top'" [nzType]="'card'" class="self-main-content">
|
<nz-tabset [nzTabPosition]="'top'" [nzType]="'card'" class="self-main-content">
|
||||||
<nz-tab nzTitle="自定义显示列">
|
<nz-tab nzTitle="自定义显示列">
|
||||||
<div class="self-row-box">
|
<div class="self-row-box">
|
||||||
|
|||||||
@@ -41,9 +41,9 @@ export class PersonalSettingsComponent implements OnInit {
|
|||||||
|
|
||||||
ngOnInit() {
|
ngOnInit() {
|
||||||
// 页面监听 动态改变表单高度
|
// 页面监听 动态改变表单高度
|
||||||
$('#main-box').css('height', (document.documentElement.clientHeight - 106 + 'px'));
|
$('#main-box-setting').css('height', (document.documentElement.clientHeight - 106 + 'px'));
|
||||||
$(window).resize(function () {
|
$(window).resize(function () {
|
||||||
$('#main-box').css('height', (document.documentElement.clientHeight - 106 + 'px'));
|
$('#main-box-setting').css('height', (document.documentElement.clientHeight - 106 + 'px'));
|
||||||
})
|
})
|
||||||
//this.list=[{"COL_CODE":"FLNO", "COL_CN":"航班号", "COL_ORDER":"10"}, {"COL_CODE":"ALCD", "COL_CN":"航空公司", "COL_ORDER":"8"}, {"COL_CODE":"FLIN", "COL_CN":"航线类别", "COL_ORDER":"4"}, {"COL_CODE":"FLTY", "COL_CN":"航班类别", "COL_ORDER":"5"}, {"COL_CODE":"MVIN", "COL_CN":"航向指示", "COL_ORDER":"9"}, {"COL_CODE":"TRML", "COL_CN":"候机楼", "COL_ORDER":"7"}, {"COL_CODE":"RENO", "COL_CN":"飞机号", "COL_ORDER":"3"}, {"COL_CODE":"SODT", "COL_CN":"计划到达/出发", "COL_ORDER":"13"}, {"COL_CODE":"ESTT", "COL_CN":"预计到达/出发", "COL_ORDER":"14"}, {"COL_CODE":"ACTT", "COL_CN":"实际到达/出发", "COL_ORDER":"15"}, {"COL_CODE":"STND", "COL_CN":"停机位", "COL_ORDER":"16"}, {"COL_CODE":"ORDER", "COL_CN":"排序", "COL_ORDER":"17"} ]
|
//this.list=[{"COL_CODE":"FLNO", "COL_CN":"航班号", "COL_ORDER":"10"}, {"COL_CODE":"ALCD", "COL_CN":"航空公司", "COL_ORDER":"8"}, {"COL_CODE":"FLIN", "COL_CN":"航线类别", "COL_ORDER":"4"}, {"COL_CODE":"FLTY", "COL_CN":"航班类别", "COL_ORDER":"5"}, {"COL_CODE":"MVIN", "COL_CN":"航向指示", "COL_ORDER":"9"}, {"COL_CODE":"TRML", "COL_CN":"候机楼", "COL_ORDER":"7"}, {"COL_CODE":"RENO", "COL_CN":"飞机号", "COL_ORDER":"3"}, {"COL_CODE":"SODT", "COL_CN":"计划到达/出发", "COL_ORDER":"13"}, {"COL_CODE":"ESTT", "COL_CN":"预计到达/出发", "COL_ORDER":"14"}, {"COL_CODE":"ACTT", "COL_CN":"实际到达/出发", "COL_ORDER":"15"}, {"COL_CODE":"STND", "COL_CN":"停机位", "COL_ORDER":"16"}, {"COL_CODE":"ORDER", "COL_CN":"排序", "COL_ORDER":"17"} ]
|
||||||
this.defaultCols = [
|
this.defaultCols = [
|
||||||
|
|||||||
@@ -57,14 +57,15 @@ export class RoleManagementComponent implements OnInit {
|
|||||||
})
|
})
|
||||||
}
|
}
|
||||||
//重置,重置搜索条件
|
//重置,重置搜索条件
|
||||||
reset(){
|
// reset(){
|
||||||
this.search.page_index=1;
|
// this.search.page_index=1;
|
||||||
this.search.page_size=10;
|
// this.search.page_size=10;
|
||||||
this.search.role_name='';
|
// this.search.role_name='';
|
||||||
this.queryTable();
|
// this.queryTable();
|
||||||
}
|
// }
|
||||||
//获取列表
|
//获取列表
|
||||||
queryTable():void{
|
queryTable():void{
|
||||||
|
this.search.page_index=1;
|
||||||
this.statusParamsTable.status=1;
|
this.statusParamsTable.status=1;
|
||||||
this.tableData=[];
|
this.tableData=[];
|
||||||
this.http.get('/sysapi/setting/role/list',this.search).subscribe((json)=>{
|
this.http.get('/sysapi/setting/role/list',this.search).subscribe((json)=>{
|
||||||
|
|||||||
@@ -5,7 +5,7 @@
|
|||||||
<ul [hidden]='statusParamsTree.status!=3' id="treeDemo" class="ztree"></ul>
|
<ul [hidden]='statusParamsTree.status!=3' id="treeDemo" class="ztree"></ul>
|
||||||
</div>
|
</div>
|
||||||
<!-- <div nz-col nzSpan="1"></div> -->
|
<!-- <div nz-col nzSpan="1"></div> -->
|
||||||
<div class="system-main-content card" id="main-box">
|
<div class="system-main-content card" id="main-box-user">
|
||||||
<div class="search-box">
|
<div class="search-box">
|
||||||
<div class="dip mr-4">
|
<div class="dip mr-4">
|
||||||
<nz-form-item>
|
<nz-form-item>
|
||||||
|
|||||||
@@ -45,10 +45,10 @@ export class UserManagementComponent implements OnInit {
|
|||||||
ngOnInit() {
|
ngOnInit() {
|
||||||
// 页面监听 动态改变表单高度
|
// 页面监听 动态改变表单高度
|
||||||
$('#tree-box').css('height',(document.documentElement.clientHeight-106+'px'));
|
$('#tree-box').css('height',(document.documentElement.clientHeight-106+'px'));
|
||||||
$('#main-box').css('height',(document.documentElement.clientHeight-106+'px'));
|
$('#main-box-user').css('height',(document.documentElement.clientHeight-106+'px'));
|
||||||
$(window).resize(function(){
|
$(window).resize(function(){
|
||||||
$('#tree-box').css('height',(document.documentElement.clientHeight-126+'px'));
|
$('#tree-box').css('height',(document.documentElement.clientHeight-126+'px'));
|
||||||
$('#main-box').css('height',(document.documentElement.clientHeight-126+'px'));
|
$('#main-box-user').css('height',(document.documentElement.clientHeight-126+'px'));
|
||||||
})
|
})
|
||||||
this.initTree();
|
this.initTree();
|
||||||
this.queryTable();
|
this.queryTable();
|
||||||
@@ -96,15 +96,16 @@ export class UserManagementComponent implements OnInit {
|
|||||||
this.visible = false;
|
this.visible = false;
|
||||||
}
|
}
|
||||||
//重置,重置搜索条件
|
//重置,重置搜索条件
|
||||||
reset(){
|
// reset(){
|
||||||
this.search.page_index=1;
|
// this.search.page_index=1;
|
||||||
this.search.page_size=10;
|
// this.search.page_size=10;
|
||||||
this.search.real_name='';
|
// this.search.real_name='';
|
||||||
this.search.login_name='';
|
// this.search.login_name='';
|
||||||
this.queryTable();
|
// this.queryTable();
|
||||||
}
|
// }
|
||||||
//获取列表
|
//获取列表
|
||||||
queryTable():void{
|
queryTable():void{
|
||||||
|
this.search.page_index=1;
|
||||||
this.statusParamsTable.status=1;
|
this.statusParamsTable.status=1;
|
||||||
this.http.get('/sysapi/setting/user/list',this.search).subscribe((json)=>{
|
this.http.get('/sysapi/setting/user/list',this.search).subscribe((json)=>{
|
||||||
if(json.is_success){
|
if(json.is_success){
|
||||||
|
|||||||
Reference in New Issue
Block a user