Exemplo n.º 1
0
        /// <summary>
        /// 注册微信支付TenpayV3
        /// </summary>
        /// <param name="registerService">RegisterService</param>
        /// <param name="tenPayV3Info">微信支付(新版本 V3)参数</param>
        /// <param name="name">公众号唯一标识名称</param>
        /// <param name="userId"></param>
        /// <param name="tenantId"></param>
        /// <returns></returns>
        public static IRegisterService UseYoYoSenparcTenpayV3 <UserKeyType, TenantKeyType>(this IRegisterService registerService, Func <TenPayV3Info> tenPayV3Info, string name, UserKeyType userId = default(UserKeyType), TenantKeyType tenantId = default(TenantKeyType))
        {
            RegisterV3InfoCollection <UserKeyType, TenantKeyType> .Register(userId, tenantId, tenPayV3Info().MchId);

            return(registerService.RegisterTenpayV3(tenPayV3Info, name));
        }
Exemplo n.º 2
0
        /// <summary>
        /// 根据 SenparcWeixinSetting 自动注册微信支付Tenpay(注意:新注册账号请使用 UseYoYoSenparcTenpayV3!
        /// </summary>
        /// <param name="registerService">RegisterService</param>
        /// <param name="weixinSettingForTenpayV3">ISenparcWeixinSetting</param>
        /// <param name="name">统一标识,如果为null,则使用 SenparcWeixinSetting.ItemKey </param>
        /// <param name="userId"></param>
        /// <param name="tenantId"></param>
        /// <returns></returns>
        public static IRegisterService UseYoYoSenparcTenpayV3 <UserKeyType, TenantKeyType>(this IRegisterService registerService, ISenparcWeixinSettingForTenpayV3 weixinSettingForTenpayV3, string name, UserKeyType userId = default(UserKeyType), TenantKeyType tenantId = default(TenantKeyType))
        {
            RegisterV3InfoCollection <UserKeyType, TenantKeyType> .Register(userId, tenantId, weixinSettingForTenpayV3.TenPayV3_MchId);

            return(registerService.RegisterTenpayV3(weixinSettingForTenpayV3, name));
        }
Exemplo n.º 3
0
 /// <summary>
 /// 根据 SenparcWeixinSetting 自动注册微信支付Tenpay(注意:新注册账号请使用 UseYoYoSenparcTenpayV3!
 /// </summary>
 /// <param name="registerService">RegisterService</param>
 /// <param name="weixinSettingForTenpayV3">ISenparcWeixinSetting</param>
 /// <param name="name">统一标识,如果为null,则使用 SenparcWeixinSetting.ItemKey </param>
 /// <param name="userId"></param>
 /// <param name="tenantId"></param>
 /// <returns></returns>
 public static IRegisterService UseYoYoSenparcTenpayV3(this IRegisterService registerService, ISenparcWeixinSettingForTenpayV3 weixinSettingForTenpayV3, string name, long userId, long tenantId)
 {
     RegisterV3InfoCollection.Register(userId, tenantId, weixinSettingForTenpayV3.TenPayV3_MchId);
     return(registerService.RegisterTenpayV3(weixinSettingForTenpayV3, name));
 }
Exemplo n.º 4
0
 /// <summary>
 /// 注册微信支付TenpayV3
 /// </summary>
 /// <param name="registerService">RegisterService</param>
 /// <param name="tenPayV3Info">微信支付(新版本 V3)参数</param>
 /// <param name="name">公众号唯一标识名称</param>
 /// <param name="userId"></param>
 /// <param name="tenantId"></param>
 /// <returns></returns>
 public static IRegisterService UseYoYoSenparcTenpayV3(this IRegisterService registerService, Func <TenPayV3Info> tenPayV3Info, string name, long userId, long tenantId)
 {
     RegisterV3InfoCollection.Register(userId, tenantId, tenPayV3Info().MchId);
     return(registerService.RegisterTenpayV3(tenPayV3Info, name));
 }