Some basic usage related to el-form components

the-checkbox

01.description

multi-select radio button

02. Scene example

Need to show whether some of her status exists for each piece of data

03. Code display 

<el-checkbox v-model="query.isAutoAccptncsign" true-label='1' false-label='0' :disabled="ifReview?true:false">自动发起承兑应答</el-checkbox>

04. Summary

v-model is bound to the corresponding attribute value

true-label refers to the tick mark when the attribute value is '1'

fasle-label refers to the attribute value to be unchecked when the value is '0'

Disabled is whether to disable

el-input 

01.description

input input box

02. Scene example

Login and the like, add editing and other scenarios

03. Code display 

<el-input v-model="query.draweeBankNo" :disabled="true" :placeholder="ifReview?'':'请输入'" />




​

04. Summary

v-model is bound to the corresponding attribute value

placeholder is a prompt

Disabled is whether to disable

el-select 

 01.description

inpout input with drop-down option box

02. Scene example

Use when the input box needs a drop-down box option

03. Code display 


<el-select v-else-if="tagType == 'list'" v-model="dictValue" :multiple="multiple" :filterable="filterable"
    :clearable="isClearable" :placeholder="placeholder" :disabled="disabled" :size="selectSize" @change="handleInput">
    <el-option v-for="(item, key) in dictOptions" :key="key" :label="item" :value="key">{
   
   { item }}</el-option>
  </el-select>

​

04. Summary

Whether v-if is displayed

v-model is the value of the two-way binding

clearable is a function that can be cleared

size is a matter of size

@change is the method to get the corresponding value when changing the value

multiple is whether to select multiple

filterable is whether to display matching options, for example, the value you search for will appear the same as the value of option

Guess you like

Origin blog.csdn.net/2201_75705263/article/details/132333347