You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
pocketcommunityweb/src/app/visitor/visitor/visitor.component.html

54 lines
2.3 KiB

<form [formGroup]="queryForm">
<!-- 预约人-->
<div class="input-group mb-3 mx-auto col-4">
<div class="input-group-prepend">
<span class="input-group-text">{{ 'visitor.username' | translate }}</span>
</div>
<input type="text" class="form-control text-center" [class.is-invalid]="getValue('appointment').invalid"
[placeholder]="'tip.input' | translate:{value:'visitor.username'|translate}"
formControlName="appointment" aria-label="appointment"/>
<div class="input-group-prepend">
<button class="btn btn-outline-secondary" type="button"
(click)="loadAll(1)">{{'button.search'|translate}}</button>
</div>
<div class="invalid-feedback font-weight-bold text-center">
{{'tip.notnull' | translate:{value: 'visitor.username'|translate} }}
</div>
</div>
</form>
<app-page [pageData]="visitors" [currentPage]="currentPage" (voted)="loadAll($event)"></app-page>
<table class="table">
<thead>
<tr>
<th scope="col" class="text-center">{{'visitor.username'|translate}}</th>
<th scope="col" class="text-center">{{'visitor.time'|translate}}</th>
<th scope="col" class="text-center">{{'visitor.notes'|translate}}</th>
<th scope="col" class="text-center">{{'visitor.admin'|translate}}</th>
<th scope="col" class="text-center">{{'visitor.status'|translate}}</th>
<th scope="col" class="text-center">{{'visitor.action'|translate}}</th>
</tr>
</thead>
<tbody>
<ng-container *ngIf="visitors">
<tr *ngFor="let visitor of visitors.list">
<td class="text-center">{{visitor.appointment}}</td>
<td class="text-center">{{visitor.time|date:'yyyy-MM-dd HH:mm'}}</td>
<td class="text-center">{{visitor.notes}}</td>
<td class="text-center">{{visitor.managerName}}</td>
<td class="text-center">{{'visitor.' + visitor.status|translate}}</td>
<td>
<div class="text-center" *ngIf="visitor.status===uncheck;">
<button class="btn btn-primary mr-3" (click)="check(visitor.id,ok)">{{'visitor.ok'|translate}}</button>
<button class="btn btn-info" (click)="check(visitor.id,fail)">{{'visitor.fail'|translate}}</button>
</div>
</td>
</tr>
</ng-container>
</tbody>
</table>
<app-page [pageData]="visitors" [currentPage]="currentPage" (voted)="loadAll($event)"></app-page>