27 changed files with 222 additions and 165 deletions
@ -1,53 +1,10 @@
|
||||
<div class="orbox" id="orbox"> |
||||
<div class="topbox"> |
||||
<div class="lefttop"> |
||||
<span>菜单列表</span> |
||||
<!-- <span><img style="vertical-align: top;" src="../../../assets/images/icon/orgrey.png" alt=""> |
||||
{{totalCount}}个</span> --> |
||||
</div> |
||||
<div class="righttop"> |
||||
<!-- <form nz-form [formGroup]="validateForm" (ngSubmit)="submitForm()"> |
||||
<nz-form-item> |
||||
<nz-form-control> |
||||
<nz-input-group nzPrefixIcon="search"> |
||||
<input type="text" nz-input placeholder="请输入单位" formControlName="search" [(ngModel)]="searchValue"/> |
||||
</nz-input-group> |
||||
</nz-form-control> |
||||
<button style="display: none;" type="submit"></button> |
||||
</nz-form-item> |
||||
</form> --> |
||||
<!-- <nz-input-group nzPrefixIcon="search"> |
||||
<input type="text" nz-input placeholder="请输入单位" [(ngModel)]="searchValue" /> |
||||
</nz-input-group> --> |
||||
<!-- <button nz-button nzType="primary" (click)="addOr()"><i nz-icon nzType="plus-circle" |
||||
nzTheme="outline"></i>新增</button> --> |
||||
</div> |
||||
<div class="box"> |
||||
<div class="nav"> |
||||
<ul> |
||||
<li [routerLink]="['/basicInfo/unit']" routerLinkActive="router-link-active">基本信息</li> |
||||
</ul> |
||||
</div> |
||||
<div class="treeTitle"> |
||||
<span>菜单名称</span> |
||||
<span>操作</span> |
||||
<div class="content"> |
||||
<router-outlet></router-outlet> |
||||
</div> |
||||
<!-- <nz-tree [nzHideUnMatched]='true' [nzSearchValue]="searchValue" #nzTreeComponent [nzData]="nodes" |
||||
[nzExpandAll]="nzExpandAll" [nzExpandedKeys]="defaultExpandedKeys" [nzTreeTemplate]="nzTreeTemplate" nzDraggable |
||||
nzBlockNode [nzExpandedIcon]="multiExpandedIconTpl"> |
||||
</nz-tree> |
||||
<ng-template #nzTreeTemplate let-node let-origin="origin"> |
||||
<div class="nodebox"> |
||||
<span class="name">{{ node.title }}</span> |
||||
<span class="operation"> |
||||
<span (click)="addOr(node)" *ngIf="!node.origin.isGasStation">新增</span> |
||||
<span (click)="editOr(node)">编辑</span> |
||||
<span [ngClass]="{'grey':node.origin.children && node.origin.children.length != 0}" |
||||
(click)="deleteOr(node)">删除</span> |
||||
</span> |
||||
</div> |
||||
</ng-template> |
||||
<ng-template #multiExpandedIconTpl let-node let-origin="origin"> |
||||
<ng-container *ngIf="node.children.length == 0; else elseTemplate"> |
||||
|
||||
</ng-container> |
||||
<ng-template #elseTemplate> |
||||
<i nz-icon [nzType]="node.isExpanded ? 'caret-down' : 'caret-right'" class="ant-tree-switcher-line-icon"></i> |
||||
</ng-template> |
||||
</ng-template> --> |
||||
</div> |
||||
</div> |
||||
|
@ -1,80 +1,36 @@
|
||||
.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), |
||||
span:nth-child(3) { |
||||
color: #2399FF; |
||||
} |
||||
|
||||
.grey{ |
||||
color: rgba(0, 13, 33, 0.48)!important; |
||||
.box { |
||||
display: flex; |
||||
} |
||||
|
||||
|
||||
.nav { |
||||
width: 200px; |
||||
height: 100%; |
||||
background: #2c4dc1; |
||||
|
||||
ul { |
||||
li { |
||||
height: 48px; |
||||
line-height: 48px; |
||||
cursor: pointer; |
||||
} |
||||
} |
||||
|
||||
} |
||||
|
||||
.router-link-active { |
||||
background: #fff; |
||||
} |
||||
|
||||
.content { |
||||
flex: 1; |
||||
} |
||||
|
||||
.router-link-active { |
||||
color: black; |
||||
} |
||||
|
||||
.content { |
||||
box-sizing: border-box; |
||||
padding: 8px; |
||||
background: #F6F5F8; |
||||
} |
||||
|
@ -0,0 +1 @@
|
||||
<button (click)="back()">返回</button> |
@ -0,0 +1,17 @@
|
||||
import { Component, OnInit } from '@angular/core'; |
||||
import { CustomReuseStrategy } from 'src/app/CustomReuseStrategy'; |
||||
@Component({ |
||||
selector: 'app-unit-details', |
||||
templateUrl: './unit-details.component.html', |
||||
styleUrls: ['./unit-details.component.scss'] |
||||
}) |
||||
export class UnitDetailsComponent implements OnInit { |
||||
|
||||
constructor() { } |
||||
|
||||
ngOnInit(): void { |
||||
} |
||||
back() { |
||||
window.history.back() |
||||
} |
||||
} |
@ -0,0 +1,2 @@
|
||||
<button (click)="next()">下一页</button> |
||||
<input placeholder="label" value="value"> |
@ -0,0 +1,6 @@
|
||||
p{ |
||||
color: black; |
||||
} |
||||
input{ |
||||
color: red; |
||||
} |
@ -0,0 +1,22 @@
|
||||
import { Component, OnInit } from '@angular/core'; |
||||
import { Router } from '@angular/router'; |
||||
|
||||
@Component({ |
||||
selector: 'app-unit', |
||||
templateUrl: './unit.component.html', |
||||
styleUrls: ['./unit.component.scss'] |
||||
}) |
||||
export class UnitComponent implements OnInit { |
||||
|
||||
constructor(private router: Router) { } |
||||
|
||||
ngOnInit(): void { |
||||
} |
||||
next() { |
||||
this.router.navigate(['/basicInfo/unit/details']); |
||||
} |
||||
ngOnDestroy(): void { |
||||
console.log('删除了6666666666666') |
||||
// CustomReuseStrategy.deleteRouteSnapshot('/basicInfo/unit');
|
||||
} |
||||
} |
Binary file not shown.
Binary file not shown.
Binary file not shown.
Loading…
Reference in new issue