feat(api): .NET 10 multi-tenant REST API

Full backend implementation:
- Multi-tenant cafe/restaurant management (menus, orders, tables, staff)
- POS order flow with ZarinPal and Snappfood payment integration
- OTP authentication via Kavenegar SMS
- QR digital menu with public discover/finder endpoints
- Customer loyalty, coupons, CRM
- PostgreSQL via EF Core, Redis for caching/sessions
- Background jobs, webhook handlers
- Full migration history

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
This commit is contained in:
soroush.asadi
2026-05-27 21:33:48 +03:30
parent 03376b3ea1
commit ef15fd6247
472 changed files with 120358 additions and 0 deletions
@@ -0,0 +1,10 @@
namespace Meezi.Core.Enums;
public enum CashTransactionType
{
OrderPayment = 0,
Refund = 1,
Expense = 2,
Withdrawal = 3,
Deposit = 4
}
+8
View File
@@ -0,0 +1,8 @@
namespace Meezi.Core.Enums;
public enum CouponType
{
Percentage = 0,
FixedAmount = 1,
FreeItem = 2
}
+9
View File
@@ -0,0 +1,9 @@
namespace Meezi.Core.Enums;
public enum CustomerGroup
{
Regular = 0,
Vip = 1,
New = 2,
Employee = 3
}
+9
View File
@@ -0,0 +1,9 @@
namespace Meezi.Core.Enums;
public enum DeliveryPlatform
{
Direct = 0,
Snappfood = 1,
Tap30 = 2,
Digikala = 3
}
+10
View File
@@ -0,0 +1,10 @@
namespace Meezi.Core.Enums;
public enum DemoRequestStatus
{
New = 0,
Contacted = 1,
DemoScheduled = 2,
Converted = 3,
Rejected = 4
}
+11
View File
@@ -0,0 +1,11 @@
namespace Meezi.Core.Enums;
public enum EmployeeRole
{
Owner = 0,
Manager = 1,
Cashier = 2,
Waiter = 3,
Chef = 4,
Delivery = 5
}
+11
View File
@@ -0,0 +1,11 @@
namespace Meezi.Core.Enums;
public enum ExpenseCategory
{
Supplies = 0,
Utilities = 1,
Salary = 2,
Rent = 3,
Maintenance = 4,
Other = 5
}
+8
View File
@@ -0,0 +1,8 @@
namespace Meezi.Core.Enums;
public enum LeaveStatus
{
Pending = 0,
Approved = 1,
Rejected = 2
}
+11
View File
@@ -0,0 +1,11 @@
namespace Meezi.Core.Enums;
public enum OrderSource
{
Pos = 0,
GuestQr = 1,
Kiosk = 2,
SnappFood = 3,
Tap30 = 4,
Digikala = 5
}
+11
View File
@@ -0,0 +1,11 @@
namespace Meezi.Core.Enums;
public enum OrderStatus
{
Pending = 0,
Confirmed = 1,
Preparing = 2,
Ready = 3,
Delivered = 4,
Cancelled = 5
}
+8
View File
@@ -0,0 +1,8 @@
namespace Meezi.Core.Enums;
public enum OrderType
{
DineIn = 0,
Takeaway = 1,
Delivery = 2
}
+8
View File
@@ -0,0 +1,8 @@
namespace Meezi.Core.Enums;
public enum PaymentMethod
{
Cash = 0,
Card = 1,
Credit = 2
}
+31
View File
@@ -0,0 +1,31 @@
namespace Meezi.Core.Enums;
public enum PaymentProvider
{
ZarinPal = 0,
Tara = 1,
SnappPay = 2
}
public static class PaymentProviderIds
{
public const string ZarinPal = "zarinpal";
public const string Tara = "tara";
public const string SnappPay = "snapppay";
public static PaymentProvider? Parse(string? id) => id?.Trim().ToLowerInvariant() switch
{
ZarinPal => PaymentProvider.ZarinPal,
Tara => PaymentProvider.Tara,
SnappPay => PaymentProvider.SnappPay,
_ => null
};
public static string ToId(PaymentProvider provider) => provider switch
{
PaymentProvider.ZarinPal => ZarinPal,
PaymentProvider.Tara => Tara,
PaymentProvider.SnappPay => SnappPay,
_ => ZarinPal
};
}
+9
View File
@@ -0,0 +1,9 @@
namespace Meezi.Core.Enums;
public enum PaymentStatus
{
Pending = 0,
Completed = 1,
Failed = 2,
Refunded = 3
}
+9
View File
@@ -0,0 +1,9 @@
namespace Meezi.Core.Enums;
public enum PlanTier
{
Free = 0,
Pro = 1,
Business = 2,
Enterprise = 3
}
@@ -0,0 +1,9 @@
namespace Meezi.Core.Enums;
public enum QueueTicketStatus
{
Waiting = 0,
Called = 1,
Done = 2,
Cancelled = 3
}
+12
View File
@@ -0,0 +1,12 @@
namespace Meezi.Core.Enums;
public enum ReservationStatus
{
Pending = 0,
Confirmed = 1,
Cancelled = 2,
/// <summary>Guest arrived; order may be open at POS.</summary>
Seated = 3,
/// <summary>Paid and visit finished.</summary>
Completed = 4
}
+7
View File
@@ -0,0 +1,7 @@
namespace Meezi.Core.Enums;
public enum ShiftStatus
{
Open = 0,
Closed = 1
}
+8
View File
@@ -0,0 +1,8 @@
namespace Meezi.Core.Enums;
public enum ShiftType
{
Morning = 0,
Evening = 1,
DayOff = 2
}
@@ -0,0 +1,9 @@
namespace Meezi.Core.Enums;
public enum StockMovementKind
{
Manual = 0,
OrderDeduction = 1,
OrderRestore = 2,
Purchase = 3
}
@@ -0,0 +1,8 @@
namespace Meezi.Core.Enums;
public enum SubscriptionPaymentStatus
{
Pending = 0,
Completed = 1,
Failed = 2
}
@@ -0,0 +1,8 @@
namespace Meezi.Core.Enums;
public enum SupportTicketPriority
{
Low = 0,
Normal = 1,
High = 2
}
@@ -0,0 +1,10 @@
namespace Meezi.Core.Enums;
public enum SupportTicketStatus
{
Open = 0,
InProgress = 1,
WaitingMerchant = 2,
Resolved = 3,
Closed = 4
}
+9
View File
@@ -0,0 +1,9 @@
namespace Meezi.Core.Enums;
public enum TableBoardStatus
{
Free = 0,
Busy = 1,
Reserved = 2,
Cleaning = 3
}
@@ -0,0 +1,7 @@
namespace Meezi.Core.Enums;
public enum TicketMessageSenderKind
{
Merchant = 0,
Admin = 1
}
@@ -0,0 +1,12 @@
namespace Meezi.Core.Enums;
/// <summary>Platform-agnostic delivery order status before mapping to <see cref="OrderStatus"/>.</summary>
public enum UnifiedDeliveryStatus
{
Pending = 0,
Confirmed = 1,
Preparing = 2,
Ready = 3,
Delivered = 4,
Cancelled = 5
}