<template>
  <el-form
    class="edit-form-main"
    v-bind="$attrs"
    v-on="listeners"
    ref="editForm"
    :style="style"
    :size="size"
    :label-width="labelWidth"
    :model="formModel"
    :rules="formRules"
    :disabled="formType === 'view' || formType === 'approval'"
    :inline="true">
    <slot></slot>
  </el-form>
</template>
<script>
  import { EditFormMixin } from './edit-form-mixin'
  import { componentConfig } from '@/comps/mixin/component-config'

  export default {
    name: 'CmsEditForm',
    mixins: [ EditFormMixin, componentConfig ],
    props: {
      style: {type: String}
    },
    provide: {
      init() {
        return this.initFun
      },
    },

  }
</script>

<style scoped lang="less">
</style>
