？<template>
  <layout-form>
    <el-form
      :model="form"
      :loading="loading"
      :rules="rules"
      size="small"
      style="width: 100%"
      label-width="120px"
      ref="form"
    >
      <el-row>
        <Field
          label="事项编号"
          prop="matterNo"
          v-model="form.matterNo"
          span="18"
          placeholder="请输入事项编号"
        />
        <Field
          label="事项名称"
          prop="matterName"
          v-model="form.matterName"
          span="18"
          rows="5"
          type="textarea"
          placeholder="请输入事项名称"
        />
        <Field
          label="事项组名"
          prop="groupName"
          span="18"
          v-model="form.groupName"
          placeholder="请输入事项组名"
        />
        <Field
          label="区域编码"
          prop="areaCode"
          span="18"
          v-model="form.areaCode"
          placeholder="请输入区域编码"
        />
        <Field
          label="部门编号"
          prop="deptCode"
          span="18"
          v-model="form.deptCode"
          placeholder="请输入部门编号"
        />
        <Field
          label="部门名称"
          prop="deptName"
          span="18"
          v-model="form.deptName"
          placeholder="请输入部门名称"
        />
        <Field
          label="行政权力编号"
          prop="powerCode"
          span="18"
          v-model="form.powerCode"
          placeholder="请输入行政权力编号"
        />
        <Field
          label="主题编号"
          prop="themeCode"
          span="18"
          v-model="form.themeCode"
          placeholder="请输入主题编号"
        />
        <Field
          label="服务类型编号"
          prop="usertypeCode"
          span="18"
          v-model="form.usertypeCode"
          placeholder="请输入服务类型编号"
        />
        <Field
          label="事项详情链接"
          prop="url"
          span="18"
           type="textarea"
          v-model="form.url"
          placeholder="请输入事项详情链接"
        />
        <Field
          label="事项来源"
          prop="source"
          span="18"
          v-model="form.source"
          :enumData="dict.source"
          type="select"
        />
      </el-row>
      <form-buttons @submit="submitForm" />
    </el-form>
  </layout-form>
</template>

<script>
import form from "@/assets/mixins/form";
export default {
  mixins: [form],
    created() {

  },
  data() {
    return {
     toString: ["source"],
      rules: {
        matterNo: [
         
          { max: 64, message: "最多只能录入64个字符", trigger: "blur" },
        ],
        matterName: [
          
          { max: 65535, message: "最多只能录入65535个字符", trigger: "blur" },
        ],
        groupName: [
          { max: 64, message: "最多只能录入64个字符", trigger: "blur" },
        ],
        areaCode: [
          { max: 32, message: "最多只能录入32个字符", trigger: "blur" },
        ],
        deptCode: [
          { max: 32, message: "最多只能录入32个字符", trigger: "blur" },
        ],
        deptName: [
          { max: 64, message: "最多只能录入64个字符", trigger: "blur" },
        ],
        powerCode: [
          { max: 64, message: "最多只能录入64个字符", trigger: "blur" },
        ],
        themeCode: [
          { required: true, message: "请输入主题编号", trigger: "blur" },
          { max: 128, message: "最多只能录入128个字符", trigger: "blur" },
        ],
        usertypeCode: [
          { max: 64, message: "最多只能录入64个字符", trigger: "blur" },
        ],
        url: [
          { max: 1024, message: "最多只能录入1024个字符", trigger: "blur" }
        ],
      },
    };
  },
};
</script>