mirror of
https://github.com/Sea-Haven-Industries/shoc-backend.git
synced 2026-09-30 04:53:11 +00:00
- Add InternalWONumber to WorkOrder model - Auto-generate 8-digit sequential numbers starting at 10000001 - Generate on new work order creation and DynamoDB sync - Include in GetWorkorderById and GetWorkOrderList responses - Add BackfillInternalWONumbers endpoint for existing records - Add migration for new column
28 lines
769 B
C#
28 lines
769 B
C#
using Microsoft.EntityFrameworkCore.Migrations;
|
|
|
|
#nullable disable
|
|
|
|
namespace Data.SeaHavenIndustries.Migrations
|
|
{
|
|
/// <inheritdoc />
|
|
public partial class AddInternalWONumber : Migration
|
|
{
|
|
/// <inheritdoc />
|
|
protected override void Up(MigrationBuilder migrationBuilder)
|
|
{
|
|
migrationBuilder.AddColumn<string>(
|
|
name: "InternalWONumber",
|
|
table: "workOrders",
|
|
type: "nvarchar(max)",
|
|
nullable: true);
|
|
}
|
|
|
|
/// <inheritdoc />
|
|
protected override void Down(MigrationBuilder migrationBuilder)
|
|
{
|
|
migrationBuilder.DropColumn(
|
|
name: "InternalWONumber",
|
|
table: "workOrders");
|
|
}
|
|
}
|
|
}
|