/// <summary> /// 合作伙伴注册 /// </summary> /// <param name="code"></param> /// <param name="comName"></param> /// <param name="Type"> Sub_contractor分包商,Supplier供应商 </param> /// <param name="realName"></param> /// <param name="Address"></param> /// <param name="comPhone"></param> /// <returns></returns> public JsonResult ReginPartnerJson(string code, string comName, string type, string realName, string Address, string comPhone) { try { DoShineMP.Models.PartnerType p = (DoShineMP.Models.PartnerType)Enum.Parse(typeof(DoShineMP.Models.PartnerType), type); if (partner.ReginPartner(WechatHelper.GetOpenidByCode(code), comName, p, realName, Address, comPhone) != null) { return(Json(new { msg = "Y" })); } else { return(Json(new { msg = "N" })); } } catch (Exception e) { return(Json(new { msg = "N" })); } }