<!--处理事件-->
<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-item>
                事件编号：{{event?.id}}
            </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>
    <div nz-col nzSpan="12">
        <h2>事件信息</h2>
        <div nz-row>
            <div nz-col nzSpan="4">事件编号:</div>
            <div nz-col nzSpan="1"></div>
            <div nz-col nzSpan="7">{{event?.id}}</div>
            <div nz-col nzSpan="4">提交时间:</div>
            <div nz-col nzSpan="1"></div>
            <div nz-col nzSpan="7">{{event?.createTime | date:"yyyy-MM-dd HH:mm:ss"}}</div>
        </div>
        <div nz-row>
            <div nz-col nzSpan="4">请求人:</div>
            <div nz-col nzSpan="1"></div>
            <div nz-col nzSpan="5">{{event?.requester}}</div>
            <div nz-col nzSpan="5">{{event?.requesterPhone}}</div>
        </div>
        <div nz-row>
            <div nz-col nzSpan="4">事件标题:</div>
            <div nz-col nzSpan="1"></div>
            <div nz-col nzSpan="7">{{event?.title}}</div>
            <div nz-col nzSpan="4">事件分类:</div>
            <div nz-col nzSpan="1"></div>
            <div nz-col nzSpan="7">{{event?.typeName}}</div>
        </div>
        <div nz-row>
            <div nz-col nzSpan="4">详细描述:</div>
            <div nz-col nzSpan="1"></div>
            <div nz-col nzSpan="7">{{event?.description}}</div>
        </div>
        <div nz-row>
            <div nz-col nzSpan="4">附件:</div>
            <div nz-col nzSpan="1"></div>
            <div nz-col nzSpan="7">
                <ng-container *ngIf="event?.fileName">
                    {{event?.fileName}}<span (click)="downLoad()" class="main-color cursor">下载</span>

                </ng-container>
            </div>
        </div>

        <h2>流转记录</h2>
        <ng-container *ngFor="let item of transforsList;">
            <div nz-row>
                <div nz-col nzSpan="4">{{item.requesterName}}</div>
                <div nz-col class="text-center" nzSpan="2">转派给</div>
                <div nz-col nzSpan="7">{{item.operatorInfo[1]}}</div>
            </div>
        </ng-container>
        <div nz-row>
            <div nz-col class="line-height-32" nzSpan="7">无法处理，我要转派</div>
            <div nz-col nzSpan="5">
                <button (click)="showTransforModal()" nz-button><span>转派</span></button>
            </div>
        </div>
    </div>
    <div nz-col nzSpan="12">
        <h2>已解决，填写处理结果</h2>
        <div nz-row>
            <div nz-col nzSpan="5"><span class="color-red">*</span>处理结果:</div>
            <div nz-col nzSpan="19">
                <nz-radio-group [(ngModel)]="obj.operateStatus">
                    <label nz-radio nzValue="0">未解决</label>
                    <label nz-radio nzValue="1">部分解决</label>
                    <label nz-radio nzValue="2">已解决</label>
                </nz-radio-group>
            </div>
        </div>
        <div nz-row>
            <div nz-col nzSpan="5" class="line-height-32"><span class="color-red">*</span>完成时间:</div>
            <div nz-col nzSpan="19">
                <nz-date-picker [(ngModel)]="date" nzFormat="yyyy-MM-dd"></nz-date-picker>
                <nz-time-picker [(ngModel)]="time"></nz-time-picker>
            </div>
        </div>
        <div nz-row>
            <div nz-col nzSpan="5" class="line-height-32">关联资产:</div>
            <div nz-col nzSpan="19">
                <button (click)="showInventoryModal()" nz-button><span>选择</span></button>
                <p class="margin-top-10" *ngFor="let item of linkList;let i = index">
                    <span class="margin-right-5">{{item.inventoryNo}}</span>
                    <span class="margin-right-5">{{item.name}}</span>
                    <span>{{item.typename}}</span>
                    <i (click)="deleteInventory(i)" class="anticon anticon-close margin-right-5"></i>
                </p>
            </div>
        </div>
        <div nz-row>
            <div nz-col nzSpan="5" class="line-height-32">关联费用:</div>
            <div nz-col nzSpan="19">
                <button (click)="showCostModal()" nz-button><span>添加</span></button>
                <p class="margin-top-10" *ngFor="let item of eventCostList;let i = index">
                    <span class="margin-right-5">
                        <ng-container *ngIf="item.costTypeId == '0'">委外费用</ng-container>
                        <ng-container *ngIf="item.costTypeId == '1'">物料费用</ng-container>
                        <ng-container *ngIf="item.costTypeId == '2'">其他</ng-container>
                    </span>
                    <span class="margin-right-5">{{item.amount}}</span>
                    <i (click)="deleteCost(i)" class="anticon anticon-close margin-right-5"></i>
                </p>
            </div>
        </div>
        <div nz-row>
            <div nz-col nzSpan="5" class="line-height-32">违规通报:</div>
            <div nz-col nzSpan="19">
                <button (click)="showNotiModal()" nz-button><span>添加</span></button>
                <p class="margin-top-10" *ngFor="let item of eventViolationVOList;let i = index">
                    <span class="margin-right-5">{{item.title}}</span>
                    <span class="margin-right-5">{{item.projectName}}</span>
                    <i (click)="deleteNoti(i)" class="anticon anticon-close margin-right-5"></i>
                </p>
            </div>
        </div>
        <div nz-row>
            <div nz-col nzSpan="5"><span class="color-red">*</span>处理情况:</div>
            <div nz-col nzSpan="19">
                <textarea [(ngModel)]="obj.operateResult" id="tyoeDescribe" row="4" nz-input></textarea>
            </div>
        </div>
        <p>
            <button (click)="save()" nz-button><span>确定</span></button>
        </p>
    </div>
</div>

<!--关联资产-->
<smart-link-inventory #smartLinkInventory (done)="setLink($event)"></smart-link-inventory>

<!--转派-->
<smart-transfor #smartTransfor (done)="success($event)"></smart-transfor>

<!--关联费用-->
<smart-cost-releation #smartCostReleation (done)="getCostReleation($event)"></smart-cost-releation>

<!--违规通报-->
<smart-violation-notification #smartVioNoti (done)="getNoti($event)"></smart-violation-notification>
