export default {
  name: 'my-date',
  render(h) {
    const data = this.obj;
    const Attrs = {
      placeholder: data.fieldHint,
      required: data.required === 1,
      type: data.dateType
    };
    return (
      <el-form-item label={this.obj.fieldNm} required={this.obj.required == 1}
                    style="width:100%;margin-bottom:10px!important">
        <el-date-picker style="width:100%!important" size="small" v-model={data.fieldValue} attrs={Attrs}>
        </el-date-picker>
      </el-form-item>
    );
  },
  data() {
    return {
      date: ''
    };
  },
  props: {
    obj: {
      type: Object,
      default: {}
    }
  }
};
