<template>
  <div>
    <el-form-item label="上传信息获取脚本"></el-form-item>
    <el-form-item label-width="0">
      <el-input
        v-model="optionModel.vabupload2_scriptCode"
        placeholder="默认/intf/getHxFileUploadConfig"
      ></el-input>
    </el-form-item>
    <el-form-item label="上传参数定义" label-width="150px">
      <a
        href="javascript:void(0);"
        class="a-link link-oneLind"
        @click="editEventHandler('vabupload2_uploadParam', params)"
      >
        <span>{{ optionModel.vabupload2_uploadParam }}</span>
        <i class="el-icon-edit"></i>
      </a>
    </el-form-item>
    <el-form-item label="删除参数定义" label-width="150px">
      <a
        href="javascript:void(0);"
        class="a-link link-oneLind"
        @click="editEventHandler('vabupload2_deleteParam', deleteParam)"
      >
        <span>{{ optionModel.vabupload2_deleteParam }}</span>
        <i class="el-icon-edit"></i>
      </a>
    </el-form-item>
    <el-form-item label="获取文件参数定义" label-width="150px">
      <a
        href="javascript:void(0);"
        class="a-link link-oneLind"
        @click="editEventHandler('vabupload2_getFileParam', params)"
      >
        <span>{{ optionModel.vabupload2_getFileParam }}</span>
        <i class="el-icon-edit"></i>
      </a>
    </el-form-item>
    <el-form-item :label="i18nt('隐藏删除按钮')">
      <el-switch v-model="optionModel.hideRemoveButton"></el-switch>
    </el-form-item>
  </div>
</template>

<script>
import i18n from "../../../../utils/i18n";
import eventMixin from "../../../../../../components/xform/form-designer/setting-panel/property-editor/event-handler/eventMixin";
export default {
  name: "field-vabUpload2-editor",
  mixins: [i18n, eventMixin],
  props: {
    designer: Object,
    selectedWidget: Object,
    optionModel: Object,
  },
  data() {
    return {
      params: ["dataId", "formCode"],
      deleteParam: ["dataId", "formCode", "param"],
    };
  },
};
</script>

<style scoped></style>
