{
  template:'${tmpl}',
  data:function(){
      return {
          ldms:[],
      }
  },
  mounted:function(){
      this.ldms=[
          {
              "title":"公司信息完善",
              "colnum":1,
               ctls:[
                 {"type":"input","label":"公司名称","prop":"name","placeHolder":"请输入公司名称","style":"width:300px",rules:[  { "required": true, "message": ' ', "trigger": 'blur' },,]},
                 {"type":"input","label":"信用代码","prop":"creditCode","placeHolder":"信用代码","style":"width:300px"},
                 {"type":"upload","label":"营业执照","prop":"licenseUrl","disabled":false,"placeHolder":"","style":""},
                 {"type":"input","label":"备注","prop":"description","disabled":false,"placeHolder":"","style":"width:300px"},
                 {"type":"btn","label":"保存","prop":"btnLogin","placeHolder":"请输入手机号","style":{"width":"150px","margin-left":"135px","margin-top":"50px"},"face":"warning"},
              ]
          },
      ];
      this.$nextTick(()=>{
        if(companyinfo){
          this.$refs.loginFrm.setInitData(companyinfo);
        }
       
      });
    
  },
  created:function(){

  },
  methods:{
      validmethod:function (rule,value,callback) { 
          return callback();
      },
      saveclick:function (fm,prop){
          var self=this;
          var fm=this.$refs.loginFrm.getFormModel();
          this.$refs.loginFrm.overBtnLoading(prop);
          this.$refs.loginFrm.validate(function(v){
              if(v){
                  console.log(v);
                  self.$root.postReq("/web/auth/userCtl/bindCompany",{u:fm}).then(function(d){
                      if(d.status==0){
                          companyinfo=d.data;
                          self.$router.push("/");
                      }else{
                          self.$alert(d.msg, '提示', {
                              confirmButtonText: '确定',
                              callback: action => {
                              }
                            });
                      }
                    });
              }
          });
       },
   
  },
  vname:"gsb-fullcompanyinfo"
}
