public WeiXinSignature( IHttpContextAccessor httpContextAccessor, IOptions <MpWeiXinOptions> wxOption) { this.httpContextAccessor = httpContextAccessor; config = wxOption.Value; }
public AccessTokenRequest( IOptions <MpWeiXinOptions> wxOption) { _MpWeiXinOptions = wxOption.Value; grant_type = "client_credential"; appid = _MpWeiXinOptions.AppId; secret = _MpWeiXinOptions.AppSecret; }
public WebAuthAccessTokenRequest( IOptions <MpWeiXinOptions> wxOption ) { config = wxOption.Value; appid = config.AppId; secret = config.AppSecret; }
public WxAccessTokenService( IDistributedCache cache, ILogger <WxAccessTokenService> logger, IOptions <MpWeiXinOptions> wxOption, WxHelper wxHelper, AccessTokenRequest accessTokenRequest) { this.cache = cache; this.logger = logger; config = wxOption.Value; this.wxHelper = wxHelper; this.accessTokenRequest = accessTokenRequest; }
/// <summary> /// ctor /// </summary> public WxJsSdkService( IDistributedCache cache, ILogger <WxJsSdkService> logger, IOptions <MpWeiXinOptions> wxOption, WxHelper wxHelper, WxAccessTokenService accessTokenSvc ) { this.cache = cache; this.logger = logger; this.accessTokenSvc = accessTokenSvc; this.wxHelper = wxHelper; config = wxOption.Value; }