<template>
  <a-drawer
    width="45%"
    :title="formTitle"
    :label-col="4"
    :wrapper-col="14"
    :visible="open"
    :body-style="{height:'calc(100vh - 100px)',overflow:'auto'}"
    @close="cancel">
    <a-form-model ref="form" :model="form" :rules="rules" layout="vertical">
      <a-spin :spinning="spinning" :delay="delayTime" tip="Loading...">
      <a-row :gutter="32">
        <a-col :span="12" >
          <a-form-model-item label="风险类型" prop="type">
            <a-select
              placeholder="请选择风险类型"
              v-model="form.type"
              :getPopupContainer="
                triggerNode => {
                  return triggerNode.parentNode || document.body
                }
              "
              style="width: 100%"
              allow-clear>
              <a-select-option v-for="(d, index) in typeOptions" :key="index" :value="Number(d.dictValue)">{{ d.dictLabel }}</a-select-option>
            </a-select>
          </a-form-model-item>
        </a-col>
        <a-col :span="12">
          <a-form-model-item label="关键词" prop="keywords">
            <a-input v-model="form.keywords" placeholder="请输入关键词"/>
          </a-form-model-item>
        </a-col>
        <a-col :span="12">
          <a-form-model-item label="特货代码" prop="specialCode">
            <a-input v-model="form.specialCode" placeholder="请输入特货代码"/>
          </a-form-model-item>
        </a-col>
      </a-row>
      </a-spin>
       <div class="bottom-control">
              <a-space>
              <a-button @click="cancel">
                  取消
              </a-button>
              <a-button type="primary" @click="submitForm">
                  保存
              </a-button>
              </a-space>
       </div>
    </a-form-model>
  </a-drawer>
</template>
<script>
import RiskGoodsNameKeySuggestEditForm from './RiskGoodsNameKeySuggestForm'
export default {
  ...RiskGoodsNameKeySuggestEditForm
}
</script>
