public InternalServiceCallVo Build() { var hasErrorFields = this.ValidateByAttribute(); if (hasErrorFields.Any()) { throw PodException.BuildException(new InvalidParameter(hasErrorFields)); } return(new InternalServiceCallVo(this)); }
public SearchSubProductVo Build() { var hasErrorFields = this.ValidateByAttribute(); if (hasErrorFields.Any()) { throw PodException.BuildException(new InvalidParameter(hasErrorFields)); } return(new SearchSubProductVo(this)); }
public BuyCreditByAmountVo Build() { var hasErrorFields = this.ValidateByAttribute(); if (hasErrorFields.Any()) { throw PodException.BuildException(new InvalidParameter(hasErrorFields)); } return(new BuyCreditByAmountVo(this)); }
public SsoService(ClientInfo clientInfo) { var hasErrorFields = clientInfo.Validate(); if (hasErrorFields.Any()) { throw PodException.BuildException(new InvalidParameter(hasErrorFields)); } this.clientInfo = clientInfo; }
public LicensePlateReaderVo Build() { var hasErrorFields = this.ValidateByAttribute(); if (hasErrorFields.Any()) { throw PodException.BuildException(new InvalidParameter(hasErrorFields)); } return(new LicensePlateReaderVo(this)); }
public GetInvoiceListAsFileVo Build() { var hasErrorFields = this.ValidateByAttribute(); if (hasErrorFields.Any()) { throw PodException.BuildException(new InvalidParameter(hasErrorFields)); } return(new GetInvoiceListAsFileVo(this)); }
public PayInvoiceByWalletVo Build() { var hasErrorFields = this.ValidateByAttribute(); if (hasErrorFields.Any()) { throw PodException.BuildException(new InvalidParameter(hasErrorFields)); } return(new PayInvoiceByWalletVo(this)); }
public BookingAvailabilityVo Build() { var hasErrorFields = this.ValidateByAttribute(); if (hasErrorFields.Any()) { throw PodException.BuildException(new InvalidParameter(hasErrorFields)); } return(new BookingAvailabilityVo(this)); }
public AddUserAndBusinessVo Build() { var hasErrorFields = this.ValidateByAttribute(); if (hasErrorFields.Any()) { throw PodException.BuildException(new InvalidParameter(hasErrorFields)); } return(new AddUserAndBusinessVo(this)); }
public ConfirmEditProfileVo Build() { var hasErrorFields = this.ValidateByAttribute(); if (hasErrorFields.Any()) { throw PodException.BuildException(new InvalidParameter(hasErrorFields)); } return(new ConfirmEditProfileVo(this)); }
public PushNotificationByAppIdVo Build() { var hasErrorFields = this.ValidateByAttribute(); if (hasErrorFields.Any()) { throw PodException.BuildException(new InvalidParameter(hasErrorFields)); } return(new PushNotificationByAppIdVo(this)); }
public DealerProductPermissionListVo Build() { var hasErrorFields = this.ValidateByAttribute(); if (hasErrorFields.Any()) { throw PodException.BuildException(new InvalidParameter(hasErrorFields)); } return(new DealerProductPermissionListVo(this)); }
public DirectionVo Build() { var hasErrorFields = this.ValidateFieldAndPropertyByAttribute(); if (hasErrorFields.Any()) { throw PodException.BuildException(new InvalidParameter(hasErrorFields)); } return(new DirectionVo(this)); }
public GetTagTreeCategoryListVo Build() { var hasErrorFields = this.ValidateByAttribute(); if (hasErrorFields.Any()) { throw PodException.BuildException(new InvalidParameter(hasErrorFields)); } return(new GetTagTreeCategoryListVo(this)); }
public UpdateDirectWithdrawVo Build() { var hasErrorFields = this.ValidateByAttribute(); if (hasErrorFields.Any()) { throw PodException.BuildException(new InvalidParameter(hasErrorFields)); } return(new UpdateDirectWithdrawVo(this)); }
public RevokeTokenVo Build() { var hasErrorFields = this.ValidateByAttribute(); if (hasErrorFields.Any()) { throw PodException.BuildException(new InvalidParameter(hasErrorFields)); } return(new RevokeTokenVo(this)); }
public AddAutoSettlementVo Build() { var hasErrorFields = this.ValidateByAttribute(); if (hasErrorFields.Any()) { throw PodException.BuildException(new InvalidParameter(hasErrorFields)); } return(new AddAutoSettlementVo(this)); }
public DeactivateVoucherVo Build() { var hasErrorFields = this.ValidateByAttribute(); if (hasErrorFields.Any()) { throw PodException.BuildException(new InvalidParameter(hasErrorFields)); } return(new DeactivateVoucherVo(this)); }
public VerifyAndCloseInvoiceVo Build() { var hasErrorFields = this.ValidateByAttribute(); if (hasErrorFields.Any()) { throw PodException.BuildException(new InvalidParameter(hasErrorFields)); } return(new VerifyAndCloseInvoiceVo(this)); }
public SendInvoicePaymentSmsVo Build() { var hasErrorFields = this.ValidateByAttribute(); if (hasErrorFields.Any()) { throw PodException.BuildException(new InvalidParameter(hasErrorFields)); } return(new SendInvoicePaymentSmsVo(this)); }
public SubscriptionPlanListVo Build() { var hasErrorFields = this.ValidateByAttribute(); if (hasErrorFields.Any()) { throw PodException.BuildException(new InvalidParameter(hasErrorFields)); } return(new SubscriptionPlanListVo(this)); }
/// <summary> /// برای نمایش فاکتور به کاربر باید او را به آدرس موجود در خروجی هدایت نمایید /// </summary> public LinkSrv GetLink(ResultSrv <ServiceCallResultSrv <PrivateCallSrv> > output) { var hashCode = ((PrivateCallSrv)output.Result.Result).Result; if (string.IsNullOrEmpty(hashCode)) { throw PodException.BuildException(new InvalidParameter(new KeyValuePair <string, string>("HashCode", "The field is required."))); } return(new LinkSrv { HashCode = hashCode, RedirectUrl = $"{BaseUrl.PrivateCallAddress}/v1/pbc/preinvoice/{hashCode}" }); }
public GetShebaByCardNumberVo Build() { var hasErrorFields = this.ValidateByAttribute(); if (hasErrorFields.Any()) { throw PodException.BuildException(new InvalidParameter(hasErrorFields)); } var dataToSign = "{" + $"\"UserName\":\"{userName}\",\"CardNumber\":\"{cardNumber}\",\"Timestamp\":\"{timestamp = DateTime.Now.ToString("yyyy/MM/dd HH:mm:ss:fff")}\"" + "}"; signature = dataToSign.GetBankingSignature(privateKey, HashAlgorithmName.SHA1); return(new GetShebaByCardNumberVo(this)); }
public static void GetResult(IRestResponse restResponse, out string output) { if (restResponse.IsSuccessful) { output = $"-- {(int)restResponse.StatusCode}-The operation was successful"; } else { if (restResponse.ErrorException != null) { OnFailure(restResponse); } throw PodException.BuildException(new DeveloperException((int)restResponse.StatusCode, restResponse.Content)); } }
public static void GetResult <T>(IRestResponse <T> restResponse, out T output) { if (restResponse.IsSuccessful) { output = restResponse.Data; } else { if (restResponse.ErrorException != null) { OnFailure(restResponse); } throw PodException.BuildException(new DeveloperException((int)restResponse.StatusCode, restResponse.Content)); } }
public GetTransferStateVo Build() { var hasErrorFields = this.ValidateByAttribute(); if (hasErrorFields.Any()) { throw PodException.BuildException(new InvalidParameter(hasErrorFields)); } string dataToSign = "{" + $"\"UserName\":\"{userName}\",\"Date\":\"{date}\",\"PaymentId\":\"{paymentId}\"" + $",\"Timestamp\":\"{timestamp = DateTime.Now.ToString("yyyy/MM/dd HH:mm:ss:fff")}\"" + "}"; signature = dataToSign.GetBankingSignature(privateKey, HashAlgorithmName.SHA1); return(new GetTransferStateVo(this)); }
public SingleProductVo Build() { var hasErrorFields = this.ValidateFieldAndPropertyByAttribute(); var attCodeError = ValidateAttributeTempCode(attTemplateCode); if (attCodeError.Key != null) { hasErrorFields.Add(attCodeError); } if (hasErrorFields.Any()) { throw PodException.BuildException(new InvalidParameter(hasErrorFields)); } return(new SingleProductVo(this)); }
public DefineCreditVoucherVo Build() { var hasErrorFields = this.ValidateByAttribute(); var hashCodeError = VoucherContentVo.ValidateHashCodeCount(vouchersContent); if (hashCodeError.Key != null) { hasErrorFields.Add(hashCodeError); } if (hasErrorFields.Any()) { throw PodException.BuildException(new InvalidParameter(hasErrorFields)); } return(new DefineCreditVoucherVo(this)); }
public static void GetResult <T>(IRestResponse <ResultSrv <T> > restResponse, out ResultSrv <T> output) { output = new ResultSrv <T>(); if (restResponse.IsSuccessful) { var resultSrv = restResponse.Data; if (resultSrv.HasError) { throw PodException.BuildException(new DeveloperException(resultSrv.ErrorCode, resultSrv.Message, resultSrv)); } output = resultSrv; } else { OnFailure(restResponse); } }
public PayaServiceVo Build() { var hasErrorFields = this.ValidateByAttribute(); if (hasErrorFields.Any()) { throw PodException.BuildException(new InvalidParameter(hasErrorFields)); } var dataToSign = "{" + $"\"UserName\":\"{userName}\",\"SourceDepositNumber\":\"{sourceDepositNumber}\",\"FileUniqueIdentifier\":\"{fileUniqueIdentifier}\"" + $",\"TransferMoneyBillNumber\":\"{transferMoneyBillNumber}\",\"BatchPayaItemInfos\":{batchPayaItemInfosJson}" + $",\"Timestamp\":\"{timestamp = DateTime.Now.ToString("yyyy/MM/dd HH:mm:ss:fff")}\"" + "}"; signature = dataToSign.GetBankingSignature(privateKey, HashAlgorithmName.SHA1); return(new PayaServiceVo(this)); }