Refactor: Update Protobuf references to CMSMicroservice across multiple components

- Changed Protobuf imports from FrontOffice.BFF to CMSMicroservice in Profile components (EditAddressDialog, Index, PaymentCallback, Personal, Settings).
- Updated CheckoutSummary, OrderDetail, OrderTracking, and Orders pages to use new UserOrder Protobuf definitions.
- Refactored WalletService, PackageService, and other utility services to align with new Protobuf structure.
- Adjusted appsettings.json for local development URL.
- Removed unused validators and simplified validation logic in AuthDialog.
- Enhanced ClubMembershipContractDialog to utilize new OtpToken service for OTP handling.
This commit is contained in:
masoodafar-web
2026-02-03 00:02:16 +03:30
parent 26ce7fd2b6
commit eab978188a
40 changed files with 261 additions and 258 deletions
@@ -1,6 +1,7 @@
using FrontOffice.BFF.UserOrder.Protobuf.Protos.UserOrder;
using CMSMicroservice.Protobuf.Protos.UserOrder;
using FrontOffice.Main.Utilities;
using Microsoft.AspNetCore.Components;
using Messages = CMSMicroservice.Protobuf.Protos;
namespace FrontOffice.Main.Pages.Store;
@@ -22,23 +23,23 @@ public partial class OrderDetail : ComponentBase
private static string FormatPrice(long price) => string.Format("{0:N0} تومان", price);
private string GetStatusText(PaymentStatus orderPaymentStatus)
private string GetStatusText(Messages.PaymentStatus orderPaymentStatus)
{
return orderPaymentStatus switch
{
PaymentStatus.Pending => "در انتظار پرداخت",
PaymentStatus.Success => "پرداخت شده",
PaymentStatus.Reject => "پرداخت ناموفق",
Messages.PaymentStatus.Pending => "در انتظار پرداخت",
Messages.PaymentStatus.Success => "پرداخت شده",
Messages.PaymentStatus.Reject => "پرداخت ناموفق",
_ => "نامشخص",
};
}
private string GetPaymentMethodText(PaymentMethod orderPaymentMethod)
private string GetPaymentMethodText(Messages.PaymentMethod orderPaymentMethod)
{
return orderPaymentMethod switch
{
PaymentMethod.Wallet => "کیف پول",
PaymentMethod.Ipg => "درگاه پرداخت اینترنتی",
Messages.PaymentMethod.Wallet => "کیف پول",
Messages.PaymentMethod.Ipg => "درگاه پرداخت اینترنتی",
_ => "نامشخص",
};
}