[CLAUDE] Office: P11-D ItTicket auto-assign round-robin + SLA timer (Wave 2, Mig 46)
All checks were successful
Deploy SOLUTION_ERP / build-deploy (push) Successful in 4m17s

Mig 46 AddSlaFieldsToItTicket (SlaDueAt/SlaWarnedSent/SlaBreached). CreateItTicketHandler: round-robin least-loaded assign cho IT staff (dept Code=IT, tie-break Id) + SlaDueAt theo Priority (Urgent 4h/High 8h/Medium 24h/Low 72h). ItTicketSlaJob background (breach+warning notify, KHONG auto-transition). PUT /{id}/assign admin override. DbInitializer seed dept IT + 2 sample staff (nv.cao/nv.truong). FE ItTicketsPage +MaTicket+assignee+SLA badge (2 app SHA256 mirror). +9 test (191->200). Self-review PASS (seed<->query dept-code verified; em main solo review do session-limit kill reviewer-spawn).

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This commit is contained in:
pqhuy1987
2026-06-08 13:23:45 +07:00
parent 6a664298fa
commit dcf76f8a9f
14 changed files with 7149 additions and 19 deletions

View File

@ -0,0 +1,51 @@
using System;
using Microsoft.EntityFrameworkCore.Migrations;
#nullable disable
namespace SolutionErp.Infrastructure.Persistence.Migrations
{
/// <inheritdoc />
public partial class AddSlaFieldsToItTicket : Migration
{
/// <inheritdoc />
protected override void Up(MigrationBuilder migrationBuilder)
{
migrationBuilder.AddColumn<bool>(
name: "SlaBreached",
table: "ItTickets",
type: "bit",
nullable: false,
defaultValue: false);
migrationBuilder.AddColumn<DateTime>(
name: "SlaDueAt",
table: "ItTickets",
type: "datetime2",
nullable: true);
migrationBuilder.AddColumn<bool>(
name: "SlaWarnedSent",
table: "ItTickets",
type: "bit",
nullable: false,
defaultValue: false);
}
/// <inheritdoc />
protected override void Down(MigrationBuilder migrationBuilder)
{
migrationBuilder.DropColumn(
name: "SlaBreached",
table: "ItTickets");
migrationBuilder.DropColumn(
name: "SlaDueAt",
table: "ItTickets");
migrationBuilder.DropColumn(
name: "SlaWarnedSent",
table: "ItTickets");
}
}
}

View File

@ -3793,6 +3793,15 @@ namespace SolutionErp.Infrastructure.Persistence.Migrations
b.Property<DateTime?>("ResolvedAt")
.HasColumnType("datetime2");
b.Property<bool>("SlaBreached")
.HasColumnType("bit");
b.Property<DateTime?>("SlaDueAt")
.HasColumnType("datetime2");
b.Property<bool>("SlaWarnedSent")
.HasColumnType("bit");
b.Property<int>("Status")
.HasColumnType("int");