<clr-modal [(clrModalOpen)]="createSecrettplOpened" [clrModalSize]="'lg'" #modal>
  <h3 class="modal-title">{{secrettplTitle}}
    <wayne-modal-operate [modal]="modal" *ngIf="createSecrettplOpened"></wayne-modal-operate>
  </h3>
  <div class="modal-body">
    <form #secrettplForm="ngForm">
      <section class="form-block">
        <div class="form-group" style="padding-left: 135px;">
          <label for="secret_id" class="clr-col-md-3 form-group-label-override required">加密字典</label>
          <div class="select form-control">
            <select id="secret_id" [(ngModel)]="secrettpl.secretId" [disabled]="actionType==1" name="secret_id">
              <option *ngFor="let secret of secrets" [ngValue]="secret.id"
                      [selected]="secret.id === secrettpl.secretId">{{secret.name}}
              </option>
            </select>
          </div>
        </div>
        <div class="form-group" style="padding-left: 135px;">
          <label for="description"
                 class="clr-col-md-3 form-group-label-override">{{'TITLE.DESCRIPTION' | translate}}</label>
          <textarea id="description" [(ngModel)]="secrettpl.description"
                    name="description"
                    rows="3">
          </textarea>
        </div>
        <div class="form-group" style="padding-left: 135px;">
          <label for="template" class="clr-col-md-3 form-group-label-override">模版</label>
          <wayne-ace-editor-box></wayne-ace-editor-box>
        </div>
      </section>
    </form>
  </div>
  <div class="modal-footer">
    <button type="button" class="btn btn-outline" (click)="onCancel()">{{'BUTTON.CANCEL' | translate}}</button>
    <button type="button" class="btn btn-primary" [disabled]="!isValid"
            (click)="onSubmit()">{{'BUTTON.SUBMIT' | translate}}</button>
  </div>
</clr-modal>
