27 changed files with 222 additions and 165 deletions
@ -1,53 +1,10 @@ |
|||||||
<div class="orbox" id="orbox"> |
<div class="box"> |
||||||
<div class="topbox"> |
<div class="nav"> |
||||||
<div class="lefttop"> |
<ul> |
||||||
<span>菜单列表</span> |
<li [routerLink]="['/basicInfo/unit']" routerLinkActive="router-link-active">基本信息</li> |
||||||
<!-- <span><img style="vertical-align: top;" src="../../../assets/images/icon/orgrey.png" alt=""> |
</ul> |
||||||
{{totalCount}}个</span> --> |
|
||||||
</div> |
</div> |
||||||
<div class="righttop"> |
<div class="content"> |
||||||
<!-- <form nz-form [formGroup]="validateForm" (ngSubmit)="submitForm()"> |
<router-outlet></router-outlet> |
||||||
<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> |
||||||
</div> |
</div> |
||||||
<div class="treeTitle"> |
|
||||||
<span>菜单名称</span> |
|
||||||
<span>操作</span> |
|
||||||
</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> |
|
@ -1,80 +1,36 @@ |
|||||||
.orbox { |
.box { |
||||||
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; |
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 { |
.nav { |
||||||
height: 36px; |
width: 200px; |
||||||
display: flex; |
height: 100%; |
||||||
|
background: #2c4dc1; |
||||||
button { |
|
||||||
margin-left: 16px; |
|
||||||
} |
|
||||||
|
|
||||||
nz-input-group { |
ul { |
||||||
height: 32px; |
li { |
||||||
} |
height: 48px; |
||||||
|
line-height: 48px; |
||||||
|
cursor: pointer; |
||||||
} |
} |
||||||
} |
} |
||||||
|
|
||||||
.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 { |
.router-link-active { |
||||||
font-size: 15px; |
background: #fff; |
||||||
|
|
||||||
} |
} |
||||||
|
|
||||||
.operation { |
.content { |
||||||
position: absolute; |
flex: 1; |
||||||
right: 0; |
|
||||||
|
|
||||||
span { |
|
||||||
margin-left: 40px; |
|
||||||
} |
} |
||||||
|
|
||||||
span:nth-child(1), |
.router-link-active { |
||||||
span:nth-child(2), |
color: black; |
||||||
span:nth-child(3) { |
|
||||||
color: #2399FF; |
|
||||||
} |
} |
||||||
|
|
||||||
.grey{ |
.content { |
||||||
color: rgba(0, 13, 33, 0.48)!important; |
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