| | |
| | | errInfo:"组织级别不能为空" |
| | | }, |
| | | { |
| | | limit:"maxin", |
| | | param:"2,50", |
| | | errInfo:"报修人名称必须在2至50字符之间" |
| | | limit:"num", |
| | | param:"", |
| | | errInfo:"组织级别错误" |
| | | }, |
| | | ], |
| | | 'addOrgInfo.parentOrgId':[ |
| | |
| | | }, |
| | | ], |
| | | 'addOrgInfo.description':[ |
| | | { |
| | | limit:"required", |
| | | param:"", |
| | | errInfo:"描述不能为空" |
| | | }, |
| | | |
| | | { |
| | | limit:"maxLength", |
| | | param:"200", |
| | |
| | | }, |
| | | clearAddOrgInfo:function(){ |
| | | vc.component.addOrgInfo = { |
| | | orgName:'', |
| | | orgLevel:'', |
| | | parentOrgId:'', |
| | | description:'', |
| | | orgName:'', |
| | | orgLevel:'', |
| | | parentOrgId:'', |
| | | description:'', |
| | | parentOrg:[] |
| | | }; |
| | | }, |
| | | _parentOrgInfo:function(){ |
| | | _addOrgListParentOrgInfo:function(){ |
| | | |
| | | |
| | | var _tmpOrgLevel = vc.component.addOrgInfo.orgLevel; |
| | | |
| | | if(_tmpOrgLevel > 1){ |
| | | _tmpOrgLevel = _tmpOrgLevel-1; |
| | | } |
| | | |
| | | var param = { |
| | | params:{ |
| | | orgLevel:vc.component.addOrgInfo.orgLevel |
| | | orgLevel:_tmpOrgLevel, |
| | | page: 1, |
| | | row: 30, |
| | | } |
| | | }; |
| | | |
| | | //发送get请求 |
| | | vc.http.get('addOrg', |
| | | 'getParentOrg', |
| | | 'list', |
| | | param, |
| | | function(json,res){ |
| | | var _orgManageInfo=JSON.parse(json); |
| | | vc.component.addOrgInfo.parentOrg = _orgManageInfo.orgs; |
| | | |
| | | },function(errInfo,error){ |
| | | console.log('请求失败处理'); |
| | | } |