|
@@ -2,9 +2,10 @@
|
|
|
<template>
|
|
|
<div :class="['inpbox',{'check':item.select},{'exclu':exclu}]">
|
|
|
<span class="prefix" v-if="msg.prefix">{{msg.prefix}}</span>
|
|
|
- <div class="inp" @click="preClick">
|
|
|
+ <!-- <div class="inp" @click="preClick"> -->
|
|
|
<input :type="msg.type=='number'?'tel':'text'"
|
|
|
:placeholder="msg.placeholder"
|
|
|
+ :style="{'width':msg.prefix&&msg.suffix?'33%':(msg.prefix || msg.suffix?'50%':'100%')}"
|
|
|
:disabled="exclu"
|
|
|
:maxlength="msg.type=='number'?10:''"
|
|
|
:class="[{'exclu':exclu},{'cancel':item.select==0}]"
|
|
@@ -12,7 +13,7 @@
|
|
|
@click="handleCli"
|
|
|
@blur="handleBlur"
|
|
|
@input="changeVal">
|
|
|
- </div>
|
|
|
+ <!-- </div> -->
|
|
|
<span class="suffix" v-if="msg.suffix">{{msg.suffix}}</span>
|
|
|
</div>
|
|
|
</template>
|
|
@@ -59,6 +60,7 @@ import { getExpStr} from '@utils/tools';
|
|
|
e.stopPropagation();
|
|
|
},
|
|
|
handleCli(e){
|
|
|
+ e.stopPropagation();
|
|
|
// const select = this.item.select;
|
|
|
if(!this.select){//聚焦时自动选中该项
|
|
|
this.$emit('handleSelec');
|
|
@@ -80,11 +82,15 @@ import { getExpStr} from '@utils/tools';
|
|
|
.inpbox{
|
|
|
color:#7C828E;
|
|
|
display: inline-block;
|
|
|
- .inp{
|
|
|
+ width: 94%;
|
|
|
+ white-space: normal;
|
|
|
+ vertical-align: middle;
|
|
|
+ // padding-right: .3rem;
|
|
|
+ /* height: .42rem;
|
|
|
+ line-height: .42rem; */
|
|
|
+ /* .inp{
|
|
|
display: inline-block;
|
|
|
vertical-align: top;
|
|
|
- // position: relative;
|
|
|
- // top:1px;
|
|
|
input{
|
|
|
color: #4F50FF;
|
|
|
font-size: .28rem;
|
|
@@ -92,11 +98,24 @@ import { getExpStr} from '@utils/tools';
|
|
|
border-radius: 0;
|
|
|
padding-left: .05rem;
|
|
|
}
|
|
|
+ } */
|
|
|
+ .prefix,.suffix{
|
|
|
+ display: inline-block;
|
|
|
+ vertical-align: middle;
|
|
|
+ }
|
|
|
+ input{
|
|
|
+ height: .42rem;
|
|
|
+ color: #4F50FF;
|
|
|
+ font-size: .28rem;
|
|
|
+ border-bottom: 1px solid #DFE0E4 !important;
|
|
|
+ border-radius: 0;
|
|
|
+ padding-left: .05rem;
|
|
|
}
|
|
|
.check{//选中
|
|
|
color: #4F50FF;
|
|
|
}
|
|
|
- .inp .exclu{ //互斥
|
|
|
+ // .inp .exclu{ //互斥
|
|
|
+ .exclu{ //互斥
|
|
|
color:#e6e7e9 !important;
|
|
|
}
|
|
|
.cancel{ //取消
|