diff --git a/src/components/input/main.js b/src/components/input/main.js index 8863bb6c..b2c3d741 100644 --- a/src/components/input/main.js +++ b/src/components/input/main.js @@ -93,7 +93,9 @@ import classNames from 'classnames' if(this.props.placeholder.length>10){ this.setState({'focus':0}); } - + if(this.props.onfocusFn){ + this.props.onfocusFn(e.target.value); + } } //失去焦点 losefofn(e){ diff --git a/src/pages/distributor/adddistributorinfo/adddistributorinfo.js b/src/pages/distributor/adddistributorinfo/adddistributorinfo.js index fd584b42..29f22778 100644 --- a/src/pages/distributor/adddistributorinfo/adddistributorinfo.js +++ b/src/pages/distributor/adddistributorinfo/adddistributorinfo.js @@ -403,6 +403,9 @@ export default class adduserinfo extends React.Component{ } changeType(e){ this.setState({pwdtype:e}); + } + changeKind(){ + this.setState({pwdtype:'password'}); } render(){ const companyOptions =this.state.companyList; @@ -479,7 +482,8 @@ this.setState({pwdtype:e}); this.setState({model:model2}) }} disabled={this.state.disabled} - countShow= {true} + countShow= {true} + onfocusFn={(e)=>this.changeKind()} onClearItem={(e)=>{ let model2 = this.state.model; model2.password = ''; diff --git a/src/pages/distributor/list/list.js b/src/pages/distributor/list/list.js index 708d458a..14a56042 100644 --- a/src/pages/distributor/list/list.js +++ b/src/pages/distributor/list/list.js @@ -31,13 +31,13 @@ const Column = [ type: "normal", width:'20%' }, - // { - // title: '余额', - // name: 'balance', - // type: "normal", - // prop:'balance', - // width:'auto' - // }, + { + title: '主体名称', + name: 'subject', + type: "normal", + prop:'subject', + width:'auto' + }, // { // title: '累计消费', // name: 'money', diff --git a/src/pages/system/account/add/adduserinfo/adduserinfo.js b/src/pages/system/account/add/adduserinfo/adduserinfo.js index b4306b22..1eefe275 100644 --- a/src/pages/system/account/add/adduserinfo/adduserinfo.js +++ b/src/pages/system/account/add/adduserinfo/adduserinfo.js @@ -321,6 +321,9 @@ export default class adduserinfo extends React.Component{ }) }).catch(err=>{ }); +} +changeKind(){ + this.setState({pwdtype:'password'}); } cancel(){ //取消二次弹出框 @@ -422,6 +425,7 @@ export default class adduserinfo extends React.Component{ }} markedShow={(e)=>{this.changeType(e)}} kind={this.state.pwdtype} disabled={this.state.disabled} + onfocusFn={(e)=>this.changeKind()} onClearItem={(e)=>{ let model2 = this.state.model; model2.password = "";