<div nz-row class="breadcrumbs">
    <div nz-col nzSpan="16">
        <nz-breadcrumb class="padding-8-0">
            <nz-breadcrumb-item>
                首页
            </nz-breadcrumb-item>
            <nz-breadcrumb-item>
                <a>工作总览</a>
            </nz-breadcrumb-item>
            <nz-breadcrumb-item>
                工作提醒
            </nz-breadcrumb-item>
        </nz-breadcrumb>
    </div>
    <div nz-col nzSpan="8" class="text-right">
        <button (click)="ngOnInit()" nz-button nzType="primary"><i class="anticon anticon-sync"></i></button>
        <smart-full-screen></smart-full-screen>
    </div>
</div>
<div nz-row [nzGutter]="4" class="search-form">
    <div nz-col nzSpan="16">
        <span class="main-color margin-right-15">状&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;态:</span>
        <nz-radio-group [(ngModel)]="obj.status">
            <label *ngFor="let item of msgType" (click)="search()" nz-radio-button
                   [nzValue]="item.value">{{item.label}}</label>
        </nz-radio-group>
    </div>
    <div nz-col nzSpan="6">
        <input type="text" (keyup.enter)="search()" nz-input [(ngModel)]="obj.keyword" placeholder="提醒标题、功能模块">
    </div>
    <div nz-col nzSpan="2">
        <button (click)="search()"
                nz-button nzType="default"><i class="anticon anticon-search"></i>搜索
        </button>
    </div>
</div>
<div nz-row [nzGutter]="4" class="search-form">
    <div nz-col nzSpan="16">
        <span class="main-color margin-right-15">提醒时间:</span>
        <nz-radio-group [(ngModel)]="time.type">
            <label *ngFor="let item of timeType" (click)="changeTimeType()" nz-radio-button
                   [nzValue]="item.value">{{item.label}}</label>
        </nz-radio-group>
    </div>
    <div nz-col nzSpan="8">
        <ng-container *ngIf="time.type == '99'">
            <nz-date-picker
                    [nzFormat]="timeFormat"
                    [(ngModel)]="time.startTime"
                    nzPlaceHolder="开始时间"></nz-date-picker>
            <nz-date-picker
                    [nzFormat]="timeFormat"
                    [(ngModel)]="time.endTime"
                    nzPlaceHolder="结束时间"></nz-date-picker>
        </ng-container>
    </div>
</div>

<nz-table #nzTable [nzData]="page.list" [nzLoading]="page.isLoading" [nzFrontPagination]="false"
          [nzTotal]="page.totalNum"
          [nzPageIndex]="page.pageNum" [nzPageSize]="page.pageCount" (nzPageIndexChange)="change($event)">
    <thead>
    <tr>
        <th>提醒标题</th>
        <th>提醒时间</th>
        <th>功能模块</th>
        <th>提醒内容</th>
        <th>状态</th>
        <th>操作</th>
    </tr>
    </thead>
    <tbody>
    <tr *ngFor="let data of nzTable.data">
        <td>{{data.title}}</td>
        <td>{{data.remindTime | date:'yyyy-MM-dd HH:mm:ss'}}</td>
        <td>{{data.moduleName}}</td>
        <td>{{data.content}}</td>
        <td>
            <span *ngIf="data.status == 0">未读</span>
            <span *ngIf="data.status == 1">已读</span>
        </td>
        <td class="handle main-color">
            <span (click)="setReady(data,'go')">查看详情</span>
            <span *ngIf="data.status == 0" (click)="setReady(data,'not')">设为已读</span>
        </td>
    </tr>
    </tbody>
</nz-table>
