// 设备
export default {
  name: 'my-input',
  render(h) {
    const data = this.obj
    const inputAttrs = {
      placeholder: '请输入',
      required: data.required
    }
    const inputAttrs1 = {
      placeholder: '根据编号带出',
      required: data.required
    }
    return (
      <div>
        <el-form-item label='设备编号' required={this.obj.required == 1}
                      style="width:100%;margin-bottom:10px!important">
          <el-input v-model={data.equipmentNum} attrs={inputAttrs} vOn:blur={() => {
            console.log('input blur')
          }}></el-input>
        </el-form-item>
        <el-form-item label='设备名称' required={this.obj.required == 1}
                      style="width:100%;margin-bottom:10px!important">
          <el-input v-model={data.equipmentName} attrs={inputAttrs1} vOn:blur={() => {
            console.log('input blur')
          }}></el-input>
        </el-form-item>
        <el-form-item label='所属地点' required={this.obj.required == 1}
                      style="width:100%;margin-bottom:10px!important">
          <el-input v-model={data.equipmentLocal} attrs={inputAttrs1} vOn:blur={() => {
            console.log('input blur')
          }}></el-input>
        </el-form-item>
      </div>
    );
  },
  props: {
    obj: {
      type: Object,
      default: {}
    }
  }
}
