Refactor sales pipeline: ShopPO, Invoice, SysConfig models
Major refactor replacing Sale/Order with ShopPO → Invoice → LoadingSheet flow. Removed legacy Sale/Order models and features; introduced ShopPO, ShopPOItem, Invoice, LoadingSheetOrder, and SysConfig models. Updated related entities, enums, repositories, and controllers. Added new migrations for schema changes and system config. Overhauled business logic and DI registrations. Updated documentation with migration plan.
This commit is contained in:
@@ -1,73 +1,27 @@
|
||||
using Distribution.Models;
|
||||
using Distribution.Features.Stock;
|
||||
using Distribution.Models;
|
||||
|
||||
namespace Distribution.Features.Ride;
|
||||
|
||||
// Ride (DeliveryRun)
|
||||
public record RideResponse(
|
||||
Guid Id,
|
||||
RideType RideType,
|
||||
RideStatus Status,
|
||||
Guid VehicleId,
|
||||
string VehicleNumberPlate,
|
||||
Guid DriverProfileId,
|
||||
string DriverFullName,
|
||||
Guid RouteId,
|
||||
string RouteName,
|
||||
Guid SourceWarehouseId,
|
||||
string SourceWarehouseName,
|
||||
int Meterstart,
|
||||
int Meterend,
|
||||
DateTime? StartedAt,
|
||||
DateTime? ActivatedAt,
|
||||
DateTime? ClosedAt,
|
||||
DateTime CreatedAt);
|
||||
|
||||
public record CreateRideRequest(
|
||||
RideType RideType,
|
||||
Guid VehicleId,
|
||||
Guid DriverProfileId,
|
||||
Guid RouteId,
|
||||
Guid? SourceWarehouseId);
|
||||
int Meterstart);
|
||||
|
||||
public record AssignRideDriverRequest(Guid DriverProfileId);
|
||||
|
||||
public record ActivateRideRequest(int Meterstart);
|
||||
|
||||
public record CloseRideRequest(int Meterend);
|
||||
|
||||
public record RaiseCancelRequest(CancelRequestType TypeCode, string Reason);
|
||||
|
||||
// Cancel Request
|
||||
public record RideCancelRequestResponse(
|
||||
Guid Id,
|
||||
Guid RideId,
|
||||
CancelRequestType TypeCode,
|
||||
string Reason,
|
||||
Guid RequestedBy,
|
||||
DateTime RequestedAt,
|
||||
CancelRequestStatus Status,
|
||||
Guid? ApprovedBy,
|
||||
DateTime? ApprovedAt);
|
||||
|
||||
public record BreakdownAssistRideResponse(
|
||||
Guid RideId,
|
||||
Guid VehicleId,
|
||||
string VehicleNumberPlate,
|
||||
Guid DriverProfileId,
|
||||
string DriverFullName,
|
||||
Guid RouteId,
|
||||
string RouteName,
|
||||
List<StockBalanceResponse> StockLevels);
|
||||
|
||||
public record BreakdownAssistOrderResponse(
|
||||
Guid OrderId,
|
||||
Guid StoreId,
|
||||
string StoreName,
|
||||
DateTime OrderDate,
|
||||
decimal TotalAmount);
|
||||
|
||||
public record BreakdownAssistResponse(
|
||||
Guid RideId,
|
||||
List<BreakdownAssistRideResponse> ActiveRides,
|
||||
List<BreakdownAssistOrderResponse> OpenOrders);
|
||||
public record CancelRideRequest(CancelRequestType TypeCode, string Reason);
|
||||
|
||||
Reference in New Issue
Block a user