From 7a2c61df609a199967a3ea04ebada9f1e37379e8 Mon Sep 17 00:00:00 2001
From: xufenglei <xufenglei>
Date: Fri, 22 Dec 2017 16:00:10 +0800
Subject: [PATCH] 编辑账户

---
 src/app/routes/systems/account/account.component.html |  118 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++-
 1 files changed, 115 insertions(+), 3 deletions(-)

diff --git a/src/app/routes/systems/account/account.component.html b/src/app/routes/systems/account/account.component.html
index e3b28d5..57015ce 100644
--- a/src/app/routes/systems/account/account.component.html
+++ b/src/app/routes/systems/account/account.component.html
@@ -1,3 +1,115 @@
-<p>
-  account works!
-</p>
+<pro-header [title]="'������������'"></pro-header>
+<nz-card [nzBordered]="false">
+	<form nz-form (ngSubmit)="load(true)" [nzLayout]="'inline'">
+		<div nz-row [nzGutter]="24">
+			<div nz-col [nzSpan]="8" class="mb-md">
+				<div nz-form-item class="d-flex">
+					<div nz-form-label>
+						<label>������</label>
+					</div>
+					<div nz-form-control class="flex-1">
+						<nz-input [(ngModel)]="query.accountName" name="name" [nzSize]="'large'" [nzPlaceHolder]="'���������������'"></nz-input>
+					</div>
+				</div>
+			</div>
+			<div nz-col [nzSpan]="8" class="mb-md">
+				<div nz-form-item class="d-flex">
+					<div nz-form-label>
+						<label>������</label>
+					</div>
+					<div nz-form-control class="flex-1">
+						<nz-input [(ngModel)]="query.mobile" name="mobile" [nzSize]="'large'" [nzPlaceHolder]="'���������������'"></nz-input>
+					</div>
+				</div>
+			</div>
+			<div nz-col [nzSpan]="8" class="mb-md">
+				<div nz-form-item class="d-flex">
+					<div nz-form-label>
+						<label>������������</label>
+					</div>
+					<div nz-form-control class="flex-1">
+						<nz-select [(ngModel)]="query.isDelete" name="isDelete" [nzSize]="'large'" >
+							<nz-option *ngFor="let option of options" [nzLabel]="option.label" [nzValue]="option.value" ></nz-option>
+						</nz-select>
+					</div>
+				</div>
+			</div>
+			<div nz-col [nzSpan]="8" class="mb-md">
+				<button nz-button type="submit" [nzType]="'primary'"
+					[nzLoading]="loading" [nzSize]="'large'">������</button>
+				<button nz-button type="reset" [nzSize]="'large'" class="mx-sm">������</button>
+			</div>
+		</div>
+	</form>
+
+	<div class="mb-md">
+		<button nz-button (click)="add()" [nzType]="'primary'" [nzSize]="'large'">
+			<i class="anticon anticon-plus"></i><span>������</span>
+		</button>
+		<ng-container *ngIf="selectedRows.length > 0"> &nbsp;
+		<button nz-button [nzSize]="'large'" (click)="remove()">������������</button>
+		</ng-container>
+	</div>
+
+	<div class="mb-md">
+		<nz-alert [nzType]="'info'" [nzShowIcon]="true"> 
+			<span alert-body>
+				 ���������<strong class="text-primary">{{selectedRows.length}}</strong>���
+			</span> 
+		</nz-alert>
+	</div>
+
+	<nz-table   #nzTable 
+				[nzDataSource]="data" 
+				[nzLoading]="http.loading"
+				[nzTotal]="total" 
+				[(nzPageIndex)]="query.pageIndex"
+				[nzPageSize]="query.pageSize" 
+				[nzShowTotal]="true"
+				(nzPageIndexChange)="load()"
+				(nzDataChange)="dataChange($event)">
+		<thead nz-thead>
+			<tr>
+				<th nz-th [nzCheckbox]="true">
+					<label nz-checkbox [(ngModel)]="allChecked" [nzIndeterminate]="indeterminate" (ngModelChange)="checkAll($event)"></label>
+				</th>
+				<th nz-th><span>������</span></th>
+				<th nz-th><span>������</span></th>
+				<th nz-th><span>������������</span></th>
+				<th nz-th><span>���������</span></th>
+				<!-- <th nz-th><span>������</span></th> -->
+				<th nz-th><span>������</span></th>
+				<th nz-th><span>������������</span></th>
+				<th nz-th>
+					<span>������������</span> 
+					<nz-table-sort [(nzValue)]="sortMap.updatedAt" (nzValueChange)="sort('expire_time', $event)"></nz-table-sort>
+				</th>
+				<th nz-th><span>������</span></th>
+			</tr>
+		</thead>
+		<tbody nz-tbody>
+			<tr nz-tbody-tr *ngFor="let account of nzTable.data">
+				<td nz-td [nzCheckbox]="true">
+					<label nz-checkbox [(ngModel)]="account.checked" (ngModelChange)="refreshStatus($event)"></label>
+				</td>
+				<td nz-td>{{account.accountName}}</td>
+				<td nz-td>{{account.mobile}}</td>
+				<td nz-td>{{account.email}}</td>
+				<td nz-td>{{account.weixin}}</td>
+				<!-- <td nz-td>{{account.password}}</td> -->
+				<td nz-td>{{account.organizationId}}</td>
+				<td nz-td>{{format_date(account.createTime)}}</td>
+				<td nz-td>{{format_date(account.expireTime)}}</td>
+				<td nz-td>
+					<a (click)="edit(account)">������</a> 
+					<ng-container *ngIf="account.isDelete == '0'">
+						<span nz-table-divider></span> 
+						<nz-popconfirm  [nzTitle]="'���������������������������?'" [nzOkText]="'Yes'" [nzCancelText]="'No'" (nzOnConfirm)="delete(account)" > 
+							<a nz-popconfirm>������</a>
+						</nz-popconfirm>
+					</ng-container>
+				</td>
+			</tr>
+		</tbody>
+	</nz-table>
+</nz-card>

--
Gitblit v1.8.0