Quellcode durchsuchen

double更改为decimal,修改数据库

LT069288 vor 3 Monaten
Ursprung
Commit
d8587b374c

+ 1235 - 0
UniformMaterialManagementSystem/Migrations/20240819011940_ModifyDoubleToDecimal.Designer.cs

@@ -0,0 +1,1235 @@
+// <auto-generated />
+using System;
+using Microsoft.EntityFrameworkCore;
+using Microsoft.EntityFrameworkCore.Infrastructure;
+using Microsoft.EntityFrameworkCore.Migrations;
+using Microsoft.EntityFrameworkCore.Storage.ValueConversion;
+using UniformMaterialManagementSystem.Data;
+
+#nullable disable
+
+namespace UniformMaterialManagementSystem.Migrations
+{
+    [DbContext(typeof(SqliteContext))]
+    [Migration("20240819011940_ModifyDoubleToDecimal")]
+    partial class ModifyDoubleToDecimal
+    {
+        /// <inheritdoc />
+        protected override void BuildTargetModel(ModelBuilder modelBuilder)
+        {
+#pragma warning disable 612, 618
+            modelBuilder.HasAnnotation("ProductVersion", "7.0.20");
+
+            modelBuilder.Entity("UniformMaterialManagementSystem.Entities.Company", b =>
+                {
+                    b.Property<Guid>("Guid")
+                        .ValueGeneratedOnAdd()
+                        .HasColumnType("TEXT");
+
+                    b.Property<string>("Address")
+                        .HasMaxLength(100)
+                        .HasColumnType("TEXT");
+
+                    b.Property<string>("Category")
+                        .IsRequired()
+                        .HasMaxLength(50)
+                        .HasColumnType("TEXT");
+
+                    b.Property<string>("Code")
+                        .IsRequired()
+                        .HasMaxLength(50)
+                        .HasColumnType("TEXT");
+
+                    b.Property<bool>("IsEnabled")
+                        .HasColumnType("INTEGER");
+
+                    b.Property<string>("Manager")
+                        .HasMaxLength(50)
+                        .HasColumnType("TEXT");
+
+                    b.Property<string>("Name")
+                        .IsRequired()
+                        .HasMaxLength(50)
+                        .HasColumnType("TEXT");
+
+                    b.Property<string>("Note")
+                        .HasMaxLength(100)
+                        .HasColumnType("TEXT");
+
+                    b.Property<string>("ShortName")
+                        .IsRequired()
+                        .HasMaxLength(50)
+                        .HasColumnType("TEXT");
+
+                    b.Property<string>("SystemCode")
+                        .HasMaxLength(50)
+                        .HasColumnType("TEXT");
+
+                    b.HasKey("Guid");
+
+                    b.ToTable("Companies");
+                });
+
+            modelBuilder.Entity("UniformMaterialManagementSystem.Entities.Contract", b =>
+                {
+                    b.Property<Guid>("Guid")
+                        .ValueGeneratedOnAdd()
+                        .HasColumnType("TEXT");
+
+                    b.Property<byte[]>("ApplyAttachment")
+                        .HasColumnType("BLOB");
+
+                    b.Property<byte[]>("Attachment")
+                        .HasColumnType("BLOB");
+
+                    b.Property<bool>("ChangedStatus")
+                        .HasColumnType("INTEGER");
+
+                    b.Property<Guid>("CompanyGuid")
+                        .HasColumnType("TEXT");
+
+                    b.Property<string>("ContractNo")
+                        .IsRequired()
+                        .HasMaxLength(50)
+                        .HasColumnType("TEXT");
+
+                    b.Property<DateTime>("EditDate")
+                        .HasColumnType("TEXT");
+
+                    b.Property<string>("EditUser")
+                        .IsRequired()
+                        .HasMaxLength(50)
+                        .HasColumnType("TEXT");
+
+                    b.Property<bool>("ExportStatus")
+                        .HasColumnType("INTEGER");
+
+                    b.Property<Guid>("PurchaseCompanyGuid")
+                        .HasColumnType("TEXT");
+
+                    b.Property<DateTime>("SigningDate")
+                        .HasColumnType("TEXT");
+
+                    b.Property<string>("Telephone")
+                        .IsRequired()
+                        .HasMaxLength(50)
+                        .HasColumnType("TEXT");
+
+                    b.Property<int>("Year")
+                        .HasColumnType("INTEGER");
+
+                    b.HasKey("Guid");
+
+                    b.HasIndex("CompanyGuid");
+
+                    b.HasIndex("PurchaseCompanyGuid");
+
+                    b.ToTable("Contracts");
+                });
+
+            modelBuilder.Entity("UniformMaterialManagementSystem.Entities.ContractDetail", b =>
+                {
+                    b.Property<Guid>("Guid")
+                        .ValueGeneratedOnAdd()
+                        .HasColumnType("TEXT");
+
+                    b.Property<Guid>("ContractGuid")
+                        .HasColumnType("TEXT");
+
+                    b.Property<decimal>("ContractQty")
+                        .HasColumnType("TEXT");
+
+                    b.Property<DateTime>("DeliveryTime")
+                        .HasColumnType("TEXT");
+
+                    b.Property<string>("InspectStatus")
+                        .IsRequired()
+                        .HasMaxLength(50)
+                        .HasColumnType("TEXT");
+
+                    b.Property<decimal>("InspectedQty")
+                        .HasColumnType("TEXT");
+
+                    b.Property<Guid>("MaterialGuid")
+                        .HasColumnType("TEXT");
+
+                    b.Property<decimal>("ReduceQuantity")
+                        .HasColumnType("TEXT");
+
+                    b.Property<decimal>("ShippedQuantity")
+                        .HasColumnType("TEXT");
+
+                    b.Property<bool>("ShippedStatus")
+                        .HasColumnType("INTEGER");
+
+                    b.Property<decimal>("UnitPrice")
+                        .HasColumnType("TEXT");
+
+                    b.HasKey("Guid");
+
+                    b.HasIndex("ContractGuid");
+
+                    b.HasIndex("MaterialGuid");
+
+                    b.ToTable("ContractDetails");
+                });
+
+            modelBuilder.Entity("UniformMaterialManagementSystem.Entities.DeliveryReceipt", b =>
+                {
+                    b.Property<Guid>("Guid")
+                        .ValueGeneratedOnAdd()
+                        .HasColumnType("TEXT");
+
+                    b.Property<string>("ApplyNo")
+                        .IsRequired()
+                        .HasColumnType("TEXT");
+
+                    b.Property<string>("CompanyName")
+                        .IsRequired()
+                        .HasColumnType("TEXT");
+
+                    b.Property<Guid>("ContractGuid")
+                        .HasColumnType("TEXT");
+
+                    b.Property<string>("ContractNo")
+                        .IsRequired()
+                        .HasColumnType("TEXT");
+
+                    b.Property<decimal>("ContractQty")
+                        .HasColumnType("TEXT");
+
+                    b.Property<DateTime>("ContractSigningDate")
+                        .HasColumnType("TEXT");
+
+                    b.Property<bool>("IsExportDelivery")
+                        .HasColumnType("INTEGER");
+
+                    b.Property<bool>("IsExportReceive")
+                        .HasColumnType("INTEGER");
+
+                    b.Property<bool>("IsExportUsage")
+                        .HasColumnType("INTEGER");
+
+                    b.Property<byte[]>("Licence")
+                        .HasColumnType("BLOB");
+
+                    b.Property<string>("ProductName")
+                        .IsRequired()
+                        .HasColumnType("TEXT");
+
+                    b.Property<string>("PurchaseCompanyName")
+                        .IsRequired()
+                        .HasColumnType("TEXT");
+
+                    b.Property<string>("ReceivedCompanyName")
+                        .IsRequired()
+                        .HasColumnType("TEXT");
+
+                    b.Property<DateTime?>("ReceivedDate")
+                        .HasColumnType("TEXT");
+
+                    b.Property<string>("ReceivedMan")
+                        .HasColumnType("TEXT");
+
+                    b.Property<int?>("ReceivedPackets")
+                        .HasColumnType("INTEGER");
+
+                    b.Property<decimal?>("ReceivedQty")
+                        .HasColumnType("TEXT");
+
+                    b.Property<string>("ReceivedStatus")
+                        .HasColumnType("TEXT");
+
+                    b.Property<string>("ReceivedTel")
+                        .HasColumnType("TEXT");
+
+                    b.Property<DateTime>("ShippedDate")
+                        .HasColumnType("TEXT");
+
+                    b.Property<string>("ShippedMan")
+                        .HasColumnType("TEXT");
+
+                    b.Property<int>("ShippedPackets")
+                        .HasColumnType("INTEGER");
+
+                    b.Property<decimal>("ShippedQty")
+                        .HasColumnType("TEXT");
+
+                    b.Property<string>("ShippedTel")
+                        .HasColumnType("TEXT");
+
+                    b.Property<int>("WorkYear")
+                        .HasColumnType("INTEGER");
+
+                    b.HasKey("Guid");
+
+                    b.ToTable("DeliveryReceipts");
+                });
+
+            modelBuilder.Entity("UniformMaterialManagementSystem.Entities.DeliveryReceiptDetail", b =>
+                {
+                    b.Property<Guid>("Guid")
+                        .ValueGeneratedOnAdd()
+                        .HasColumnType("TEXT");
+
+                    b.Property<string>("BatchNo")
+                        .IsRequired()
+                        .HasColumnType("TEXT");
+
+                    b.Property<Guid>("DeliveryReceiptGuid")
+                        .HasColumnType("TEXT");
+
+                    b.Property<string>("PacketNo")
+                        .IsRequired()
+                        .HasColumnType("TEXT");
+
+                    b.Property<decimal?>("ReceiveQuantity")
+                        .HasColumnType("TEXT");
+
+                    b.Property<string>("ShipNote")
+                        .HasColumnType("TEXT");
+
+                    b.Property<decimal>("ShippedQuantity")
+                        .HasColumnType("TEXT");
+
+                    b.Property<decimal?>("UsageQuantity")
+                        .HasColumnType("TEXT");
+
+                    b.Property<string>("UsageStatus")
+                        .HasColumnType("TEXT");
+
+                    b.HasKey("Guid");
+
+                    b.HasIndex("DeliveryReceiptGuid");
+
+                    b.ToTable("DeliveryReceiptDetails");
+                });
+
+            modelBuilder.Entity("UniformMaterialManagementSystem.Entities.FactoryLicense", b =>
+                {
+                    b.Property<Guid>("Guid")
+                        .ValueGeneratedOnAdd()
+                        .HasColumnType("TEXT");
+
+                    b.Property<string>("ApproveUser")
+                        .HasMaxLength(50)
+                        .HasColumnType("TEXT");
+
+                    b.Property<string>("AuditUser")
+                        .HasMaxLength(50)
+                        .HasColumnType("TEXT");
+
+                    b.Property<string>("Department")
+                        .IsRequired()
+                        .HasMaxLength(50)
+                        .HasColumnType("TEXT");
+
+                    b.Property<string>("EditUser")
+                        .IsRequired()
+                        .HasMaxLength(50)
+                        .HasColumnType("TEXT");
+
+                    b.Property<DateTime>("FactoryDate")
+                        .HasColumnType("TEXT");
+
+                    b.Property<decimal>("FactoryQuantity")
+                        .HasColumnType("TEXT");
+
+                    b.Property<Guid>("InspectApplyGuid")
+                        .HasColumnType("TEXT");
+
+                    b.Property<string>("LicenseListNo")
+                        .IsRequired()
+                        .HasMaxLength(50)
+                        .HasColumnType("TEXT");
+
+                    b.Property<string>("LicenseNo")
+                        .IsRequired()
+                        .HasMaxLength(50)
+                        .HasColumnType("TEXT");
+
+                    b.Property<DateTime>("SignDate")
+                        .HasColumnType("TEXT");
+
+                    b.HasKey("Guid");
+
+                    b.HasIndex("InspectApplyGuid");
+
+                    b.ToTable("FactoryLicenses");
+                });
+
+            modelBuilder.Entity("UniformMaterialManagementSystem.Entities.InspectApply", b =>
+                {
+                    b.Property<Guid>("Guid")
+                        .ValueGeneratedOnAdd()
+                        .HasColumnType("TEXT");
+
+                    b.Property<string>("ApplyDescription")
+                        .HasMaxLength(1000)
+                        .HasColumnType("TEXT");
+
+                    b.Property<string>("ApplyNo")
+                        .IsRequired()
+                        .HasMaxLength(50)
+                        .HasColumnType("TEXT");
+
+                    b.Property<DateTime?>("ApplyReceiveDate")
+                        .HasColumnType("TEXT");
+
+                    b.Property<string>("ApplyUser")
+                        .IsRequired()
+                        .HasMaxLength(50)
+                        .HasColumnType("TEXT");
+
+                    b.Property<string>("BatchNo")
+                        .IsRequired()
+                        .HasMaxLength(50)
+                        .HasColumnType("TEXT");
+
+                    b.Property<string>("Company")
+                        .IsRequired()
+                        .HasMaxLength(50)
+                        .HasColumnType("TEXT");
+
+                    b.Property<Guid>("CompanyGuid")
+                        .HasColumnType("TEXT");
+
+                    b.Property<DateTime>("EndProductDate")
+                        .HasColumnType("TEXT");
+
+                    b.Property<int>("ExportStatus")
+                        .HasColumnType("INTEGER");
+
+                    b.Property<string>("InspCategory")
+                        .IsRequired()
+                        .HasMaxLength(50)
+                        .HasColumnType("TEXT");
+
+                    b.Property<DateTime>("InspDate")
+                        .HasColumnType("TEXT");
+
+                    b.Property<decimal>("InspQuantity")
+                        .HasColumnType("TEXT");
+
+                    b.Property<byte[]>("InspReport")
+                        .HasColumnType("BLOB");
+
+                    b.Property<string>("InspReportNo")
+                        .IsRequired()
+                        .HasMaxLength(50)
+                        .HasColumnType("TEXT");
+
+                    b.Property<bool>("LicenseStatus")
+                        .HasColumnType("INTEGER");
+
+                    b.Property<Guid>("MaterialGuid")
+                        .HasColumnType("TEXT");
+
+                    b.Property<string>("ProductName")
+                        .IsRequired()
+                        .HasMaxLength(50)
+                        .HasColumnType("TEXT");
+
+                    b.Property<bool>("ReportStatus")
+                        .HasColumnType("INTEGER");
+
+                    b.Property<bool>("SampleStatus")
+                        .HasColumnType("INTEGER");
+
+                    b.Property<DateTime>("StartProductDate")
+                        .HasColumnType("TEXT");
+
+                    b.Property<int>("Year")
+                        .HasColumnType("INTEGER");
+
+                    b.HasKey("Guid");
+
+                    b.HasIndex("CompanyGuid");
+
+                    b.HasIndex("MaterialGuid");
+
+                    b.ToTable("InspectApplies");
+                });
+
+            modelBuilder.Entity("UniformMaterialManagementSystem.Entities.InspectApplyContractDetail", b =>
+                {
+                    b.Property<Guid>("Guid")
+                        .ValueGeneratedOnAdd()
+                        .HasColumnType("TEXT");
+
+                    b.Property<Guid>("ApplyGuid")
+                        .HasColumnType("TEXT");
+
+                    b.Property<string>("ApplyNo")
+                        .IsRequired()
+                        .HasMaxLength(50)
+                        .HasColumnType("TEXT");
+
+                    b.Property<Guid>("ContractDetailGuid")
+                        .HasColumnType("TEXT");
+
+                    b.Property<string>("ContractNo")
+                        .IsRequired()
+                        .HasMaxLength(50)
+                        .HasColumnType("TEXT");
+
+                    b.Property<decimal>("InspectQty")
+                        .HasColumnType("TEXT");
+
+                    b.Property<string>("PurchaseCompany")
+                        .IsRequired()
+                        .HasMaxLength(50)
+                        .HasColumnType("TEXT");
+
+                    b.Property<string>("PurchaseCompanyShortName")
+                        .IsRequired()
+                        .HasMaxLength(50)
+                        .HasColumnType("TEXT");
+
+                    b.Property<string>("SigningDate")
+                        .IsRequired()
+                        .HasMaxLength(50)
+                        .HasColumnType("TEXT");
+
+                    b.Property<decimal>("UnInspectQty")
+                        .HasColumnType("TEXT");
+
+                    b.HasKey("Guid");
+
+                    b.HasIndex("ApplyGuid");
+
+                    b.ToTable("InspectApplyContractDetails");
+                });
+
+            modelBuilder.Entity("UniformMaterialManagementSystem.Entities.InspectApplyDetail", b =>
+                {
+                    b.Property<Guid>("Guid")
+                        .ValueGeneratedOnAdd()
+                        .HasColumnType("TEXT");
+
+                    b.Property<Guid>("ApplyGuid")
+                        .HasColumnType("TEXT");
+
+                    b.Property<string>("ApplyNo")
+                        .IsRequired()
+                        .HasMaxLength(50)
+                        .HasColumnType("TEXT");
+
+                    b.Property<string>("Note")
+                        .HasMaxLength(50)
+                        .HasColumnType("TEXT");
+
+                    b.Property<string>("PacketNo")
+                        .IsRequired()
+                        .HasMaxLength(50)
+                        .HasColumnType("TEXT");
+
+                    b.Property<decimal>("Quantity")
+                        .HasColumnType("TEXT");
+
+                    b.Property<bool>("ShippedStatus")
+                        .HasColumnType("INTEGER");
+
+                    b.HasKey("Guid");
+
+                    b.HasIndex("ApplyGuid");
+
+                    b.ToTable("InspectApplyDetails");
+                });
+
+            modelBuilder.Entity("UniformMaterialManagementSystem.Entities.InspectionOrganization", b =>
+                {
+                    b.Property<Guid>("Guid")
+                        .ValueGeneratedOnAdd()
+                        .HasColumnType("TEXT");
+
+                    b.Property<string>("Address")
+                        .IsRequired()
+                        .HasMaxLength(50)
+                        .HasColumnType("TEXT");
+
+                    b.Property<string>("Contacts")
+                        .IsRequired()
+                        .HasMaxLength(50)
+                        .HasColumnType("TEXT");
+
+                    b.Property<bool>("IsEnabled")
+                        .HasColumnType("INTEGER");
+
+                    b.Property<string>("Name")
+                        .IsRequired()
+                        .HasMaxLength(50)
+                        .HasColumnType("TEXT");
+
+                    b.Property<int>("OrderNo")
+                        .HasColumnType("INTEGER");
+
+                    b.Property<string>("Telephone")
+                        .IsRequired()
+                        .HasMaxLength(50)
+                        .HasColumnType("TEXT");
+
+                    b.HasKey("Guid");
+
+                    b.ToTable("InspectionOrganizations");
+                });
+
+            modelBuilder.Entity("UniformMaterialManagementSystem.Entities.InspectionReport", b =>
+                {
+                    b.Property<Guid>("Guid")
+                        .ValueGeneratedOnAdd()
+                        .HasColumnType("TEXT");
+
+                    b.Property<string>("Conclusion")
+                        .IsRequired()
+                        .HasMaxLength(50)
+                        .HasColumnType("TEXT");
+
+                    b.Property<string>("ConclusionDesc")
+                        .IsRequired()
+                        .HasMaxLength(1000)
+                        .HasColumnType("TEXT");
+
+                    b.Property<string>("Department")
+                        .IsRequired()
+                        .HasMaxLength(50)
+                        .HasColumnType("TEXT");
+
+                    b.Property<string>("EditUser")
+                        .IsRequired()
+                        .HasMaxLength(50)
+                        .HasColumnType("TEXT");
+
+                    b.Property<Guid>("InspectApplyGuid")
+                        .HasColumnType("TEXT");
+
+                    b.Property<bool>("IsSample")
+                        .HasColumnType("INTEGER");
+
+                    b.Property<string>("ReportBasis")
+                        .IsRequired()
+                        .HasMaxLength(200)
+                        .HasColumnType("TEXT");
+
+                    b.Property<string>("ReportDesc")
+                        .IsRequired()
+                        .HasMaxLength(1000)
+                        .HasColumnType("TEXT");
+
+                    b.Property<string>("ReportNo")
+                        .IsRequired()
+                        .HasMaxLength(50)
+                        .HasColumnType("TEXT");
+
+                    b.Property<DateTime>("ReportTime")
+                        .HasColumnType("TEXT");
+
+                    b.HasKey("Guid");
+
+                    b.HasIndex("InspectApplyGuid");
+
+                    b.ToTable("InspectionReports");
+                });
+
+            modelBuilder.Entity("UniformMaterialManagementSystem.Entities.InspectionReportDetail", b =>
+                {
+                    b.Property<Guid>("Guid")
+                        .ValueGeneratedOnAdd()
+                        .HasColumnType("TEXT");
+
+                    b.Property<Guid>("InspectionReportGuid")
+                        .HasColumnType("TEXT");
+
+                    b.Property<string>("Inspector")
+                        .IsRequired()
+                        .HasMaxLength(50)
+                        .HasColumnType("TEXT");
+
+                    b.Property<string>("JobCategory")
+                        .IsRequired()
+                        .HasMaxLength(50)
+                        .HasColumnType("TEXT");
+
+                    b.Property<string>("SupervisionUnit")
+                        .IsRequired()
+                        .HasMaxLength(50)
+                        .HasColumnType("TEXT");
+
+                    b.HasKey("Guid");
+
+                    b.HasIndex("InspectionReportGuid");
+
+                    b.ToTable("InspectionReportDetails");
+                });
+
+            modelBuilder.Entity("UniformMaterialManagementSystem.Entities.Material", b =>
+                {
+                    b.Property<Guid>("Guid")
+                        .ValueGeneratedOnAdd()
+                        .HasColumnType("TEXT");
+
+                    b.Property<string>("CategoryCode")
+                        .IsRequired()
+                        .HasMaxLength(50)
+                        .HasColumnType("TEXT");
+
+                    b.Property<bool>("IsEnabled")
+                        .HasColumnType("INTEGER");
+
+                    b.Property<string>("MeasureUnit")
+                        .IsRequired()
+                        .HasMaxLength(50)
+                        .HasColumnType("TEXT");
+
+                    b.Property<string>("Name")
+                        .IsRequired()
+                        .HasMaxLength(50)
+                        .HasColumnType("TEXT");
+
+                    b.Property<string>("NormName")
+                        .HasMaxLength(50)
+                        .HasColumnType("TEXT");
+
+                    b.Property<string>("Note")
+                        .HasMaxLength(100)
+                        .HasColumnType("TEXT");
+
+                    b.Property<string>("Specification")
+                        .IsRequired()
+                        .HasMaxLength(50)
+                        .HasColumnType("TEXT");
+
+                    b.Property<string>("VarietyCode")
+                        .IsRequired()
+                        .HasMaxLength(50)
+                        .HasColumnType("TEXT");
+
+                    b.HasKey("Guid");
+
+                    b.ToTable("Materials");
+                });
+
+            modelBuilder.Entity("UniformMaterialManagementSystem.Entities.MenuItem", b =>
+                {
+                    b.Property<Guid>("Guid")
+                        .ValueGeneratedOnAdd()
+                        .HasColumnType("TEXT");
+
+                    b.Property<string>("Icon")
+                        .HasMaxLength(100)
+                        .HasColumnType("TEXT");
+
+                    b.Property<bool>("IsEnabled")
+                        .HasColumnType("INTEGER");
+
+                    b.Property<bool>("IsVisible")
+                        .HasColumnType("INTEGER");
+
+                    b.Property<string>("Name")
+                        .IsRequired()
+                        .HasMaxLength(50)
+                        .HasColumnType("TEXT");
+
+                    b.Property<int>("OrderIndex")
+                        .HasColumnType("INTEGER");
+
+                    b.Property<Guid?>("ParentGuid")
+                        .HasColumnType("TEXT");
+
+                    b.Property<string>("Path")
+                        .HasMaxLength(100)
+                        .HasColumnType("TEXT");
+
+                    b.HasKey("Guid");
+
+                    b.HasIndex("ParentGuid");
+
+                    b.ToTable("MenuItems");
+                });
+
+            modelBuilder.Entity("UniformMaterialManagementSystem.Entities.Role", b =>
+                {
+                    b.Property<Guid>("Guid")
+                        .ValueGeneratedOnAdd()
+                        .HasColumnType("TEXT");
+
+                    b.Property<string>("Description")
+                        .IsRequired()
+                        .HasMaxLength(100)
+                        .HasColumnType("TEXT");
+
+                    b.Property<bool>("IsEnabled")
+                        .HasColumnType("INTEGER");
+
+                    b.Property<string>("Name")
+                        .IsRequired()
+                        .HasMaxLength(50)
+                        .HasColumnType("TEXT");
+
+                    b.HasKey("Guid");
+
+                    b.ToTable("Roles");
+                });
+
+            modelBuilder.Entity("UniformMaterialManagementSystem.Entities.RoleMenuItem", b =>
+                {
+                    b.Property<Guid>("MenuItemGuid")
+                        .HasColumnType("TEXT");
+
+                    b.Property<Guid>("RoleGuid")
+                        .HasColumnType("TEXT");
+
+                    b.HasKey("MenuItemGuid", "RoleGuid");
+
+                    b.HasIndex("RoleGuid");
+
+                    b.ToTable("RoleMenuItems");
+                });
+
+            modelBuilder.Entity("UniformMaterialManagementSystem.Entities.SampleRegistration", b =>
+                {
+                    b.Property<Guid>("Guid")
+                        .ValueGeneratedOnAdd()
+                        .HasColumnType("TEXT");
+
+                    b.Property<string>("BatchNo")
+                        .IsRequired()
+                        .HasMaxLength(50)
+                        .HasColumnType("TEXT");
+
+                    b.Property<string>("Department")
+                        .IsRequired()
+                        .HasMaxLength(50)
+                        .HasColumnType("TEXT");
+
+                    b.Property<DateTime>("EditTime")
+                        .HasColumnType("TEXT");
+
+                    b.Property<string>("EditUser")
+                        .IsRequired()
+                        .HasMaxLength(50)
+                        .HasColumnType("TEXT");
+
+                    b.Property<Guid>("InspectApplyGuid")
+                        .HasColumnType("TEXT");
+
+                    b.Property<string>("InspectionOrganization")
+                        .IsRequired()
+                        .HasMaxLength(500)
+                        .HasColumnType("TEXT");
+
+                    b.Property<string>("PacketNo")
+                        .IsRequired()
+                        .HasMaxLength(50)
+                        .HasColumnType("TEXT");
+
+                    b.Property<DateTime>("ProductDate")
+                        .HasColumnType("TEXT");
+
+                    b.Property<string>("ProductUsers")
+                        .HasMaxLength(100)
+                        .HasColumnType("TEXT");
+
+                    b.Property<decimal>("Quantity")
+                        .HasColumnType("TEXT");
+
+                    b.Property<string>("SampleNo")
+                        .IsRequired()
+                        .HasMaxLength(50)
+                        .HasColumnType("TEXT");
+
+                    b.Property<string>("SingleIndexItem")
+                        .HasMaxLength(50)
+                        .HasColumnType("TEXT");
+
+                    b.Property<string>("Telephone")
+                        .HasMaxLength(50)
+                        .HasColumnType("TEXT");
+
+                    b.Property<string>("TestingItem")
+                        .IsRequired()
+                        .HasMaxLength(50)
+                        .HasColumnType("TEXT");
+
+                    b.HasKey("Guid");
+
+                    b.HasIndex("InspectApplyGuid");
+
+                    b.ToTable("SampleRegistrations");
+                });
+
+            modelBuilder.Entity("UniformMaterialManagementSystem.Entities.SerialNumber", b =>
+                {
+                    b.Property<Guid>("Guid")
+                        .ValueGeneratedOnAdd()
+                        .HasColumnType("TEXT");
+
+                    b.Property<string>("CompanyCode")
+                        .IsRequired()
+                        .HasMaxLength(50)
+                        .HasColumnType("TEXT");
+
+                    b.Property<Guid>("CompanyGuid")
+                        .HasColumnType("TEXT");
+
+                    b.Property<string>("InspCategory")
+                        .IsRequired()
+                        .HasMaxLength(50)
+                        .HasColumnType("TEXT");
+
+                    b.Property<string>("MaxNumber")
+                        .IsRequired()
+                        .HasMaxLength(50)
+                        .HasColumnType("TEXT");
+
+                    b.Property<Guid>("SupervisionUnitGuid")
+                        .HasColumnType("TEXT");
+
+                    b.Property<int>("Year")
+                        .HasColumnType("INTEGER");
+
+                    b.HasKey("Guid");
+
+                    b.ToTable("SerialNumbers");
+                });
+
+            modelBuilder.Entity("UniformMaterialManagementSystem.Entities.SupervisionUnit", b =>
+                {
+                    b.Property<Guid>("Guid")
+                        .ValueGeneratedOnAdd()
+                        .HasColumnType("TEXT");
+
+                    b.Property<bool>("IsEnabled")
+                        .HasColumnType("INTEGER");
+
+                    b.Property<string>("Name")
+                        .IsRequired()
+                        .HasMaxLength(50)
+                        .HasColumnType("TEXT");
+
+                    b.Property<string>("Note")
+                        .HasMaxLength(100)
+                        .HasColumnType("TEXT");
+
+                    b.Property<string>("ShortName")
+                        .IsRequired()
+                        .HasMaxLength(50)
+                        .HasColumnType("TEXT");
+
+                    b.HasKey("Guid");
+
+                    b.ToTable("SupervisionUnits");
+                });
+
+            modelBuilder.Entity("UniformMaterialManagementSystem.Entities.User", b =>
+                {
+                    b.Property<Guid>("Guid")
+                        .ValueGeneratedOnAdd()
+                        .HasColumnType("TEXT");
+
+                    b.Property<Guid?>("CompanyGuid")
+                        .HasColumnType("TEXT");
+
+                    b.Property<string>("CompanyName")
+                        .HasMaxLength(50)
+                        .HasColumnType("TEXT");
+
+                    b.Property<string>("IdNumber")
+                        .IsRequired()
+                        .HasMaxLength(50)
+                        .HasColumnType("TEXT");
+
+                    b.Property<bool>("IsEnabled")
+                        .HasColumnType("INTEGER");
+
+                    b.Property<string>("LoginName")
+                        .IsRequired()
+                        .HasMaxLength(50)
+                        .HasColumnType("TEXT");
+
+                    b.Property<string>("Password")
+                        .IsRequired()
+                        .HasMaxLength(50)
+                        .HasColumnType("TEXT");
+
+                    b.Property<DateTime>("RegisterDate")
+                        .HasColumnType("TEXT");
+
+                    b.Property<string>("Salt")
+                        .IsRequired()
+                        .HasMaxLength(50)
+                        .HasColumnType("TEXT");
+
+                    b.Property<Guid>("SupervisionUnitGuid")
+                        .HasColumnType("TEXT");
+
+                    b.Property<string>("UserName")
+                        .IsRequired()
+                        .HasMaxLength(50)
+                        .HasColumnType("TEXT");
+
+                    b.HasKey("Guid");
+
+                    b.HasIndex("CompanyGuid");
+
+                    b.HasIndex("SupervisionUnitGuid");
+
+                    b.ToTable("Users");
+                });
+
+            modelBuilder.Entity("UniformMaterialManagementSystem.Entities.UserRole", b =>
+                {
+                    b.Property<Guid>("RoleGuid")
+                        .HasColumnType("TEXT");
+
+                    b.Property<Guid>("UserGuid")
+                        .HasColumnType("TEXT");
+
+                    b.HasKey("RoleGuid", "UserGuid");
+
+                    b.HasIndex("UserGuid");
+
+                    b.ToTable("UserRoles");
+                });
+
+            modelBuilder.Entity("UniformMaterialManagementSystem.Entities.Contract", b =>
+                {
+                    b.HasOne("UniformMaterialManagementSystem.Entities.Company", "Company")
+                        .WithMany()
+                        .HasForeignKey("CompanyGuid")
+                        .OnDelete(DeleteBehavior.Cascade)
+                        .IsRequired();
+
+                    b.HasOne("UniformMaterialManagementSystem.Entities.Company", "PurchaseCompany")
+                        .WithMany()
+                        .HasForeignKey("PurchaseCompanyGuid")
+                        .OnDelete(DeleteBehavior.Cascade)
+                        .IsRequired();
+
+                    b.Navigation("Company");
+
+                    b.Navigation("PurchaseCompany");
+                });
+
+            modelBuilder.Entity("UniformMaterialManagementSystem.Entities.ContractDetail", b =>
+                {
+                    b.HasOne("UniformMaterialManagementSystem.Entities.Contract", "Contract")
+                        .WithMany("ContractDetails")
+                        .HasForeignKey("ContractGuid")
+                        .OnDelete(DeleteBehavior.Cascade)
+                        .IsRequired();
+
+                    b.HasOne("UniformMaterialManagementSystem.Entities.Material", "Material")
+                        .WithMany()
+                        .HasForeignKey("MaterialGuid")
+                        .OnDelete(DeleteBehavior.Cascade)
+                        .IsRequired();
+
+                    b.Navigation("Contract");
+
+                    b.Navigation("Material");
+                });
+
+            modelBuilder.Entity("UniformMaterialManagementSystem.Entities.DeliveryReceiptDetail", b =>
+                {
+                    b.HasOne("UniformMaterialManagementSystem.Entities.DeliveryReceipt", null)
+                        .WithMany("DeliveryReceiptDetails")
+                        .HasForeignKey("DeliveryReceiptGuid")
+                        .OnDelete(DeleteBehavior.Cascade)
+                        .IsRequired();
+                });
+
+            modelBuilder.Entity("UniformMaterialManagementSystem.Entities.FactoryLicense", b =>
+                {
+                    b.HasOne("UniformMaterialManagementSystem.Entities.InspectApply", "InspectApply")
+                        .WithMany()
+                        .HasForeignKey("InspectApplyGuid")
+                        .OnDelete(DeleteBehavior.Cascade)
+                        .IsRequired();
+
+                    b.Navigation("InspectApply");
+                });
+
+            modelBuilder.Entity("UniformMaterialManagementSystem.Entities.InspectApply", b =>
+                {
+                    b.HasOne("UniformMaterialManagementSystem.Entities.Company", "MaterialCompany")
+                        .WithMany()
+                        .HasForeignKey("CompanyGuid")
+                        .OnDelete(DeleteBehavior.Cascade)
+                        .IsRequired();
+
+                    b.HasOne("UniformMaterialManagementSystem.Entities.Material", "Material")
+                        .WithMany()
+                        .HasForeignKey("MaterialGuid")
+                        .OnDelete(DeleteBehavior.Cascade)
+                        .IsRequired();
+
+                    b.Navigation("Material");
+
+                    b.Navigation("MaterialCompany");
+                });
+
+            modelBuilder.Entity("UniformMaterialManagementSystem.Entities.InspectApplyContractDetail", b =>
+                {
+                    b.HasOne("UniformMaterialManagementSystem.Entities.InspectApply", "InspectApply")
+                        .WithMany("InspectApplyContractDetails")
+                        .HasForeignKey("ApplyGuid")
+                        .OnDelete(DeleteBehavior.Cascade)
+                        .IsRequired();
+
+                    b.Navigation("InspectApply");
+                });
+
+            modelBuilder.Entity("UniformMaterialManagementSystem.Entities.InspectApplyDetail", b =>
+                {
+                    b.HasOne("UniformMaterialManagementSystem.Entities.InspectApply", "InspectApply")
+                        .WithMany("InspectApplyDetails")
+                        .HasForeignKey("ApplyGuid")
+                        .OnDelete(DeleteBehavior.Cascade)
+                        .IsRequired();
+
+                    b.Navigation("InspectApply");
+                });
+
+            modelBuilder.Entity("UniformMaterialManagementSystem.Entities.InspectionReport", b =>
+                {
+                    b.HasOne("UniformMaterialManagementSystem.Entities.InspectApply", "InspectApply")
+                        .WithMany()
+                        .HasForeignKey("InspectApplyGuid")
+                        .OnDelete(DeleteBehavior.Cascade)
+                        .IsRequired();
+
+                    b.Navigation("InspectApply");
+                });
+
+            modelBuilder.Entity("UniformMaterialManagementSystem.Entities.InspectionReportDetail", b =>
+                {
+                    b.HasOne("UniformMaterialManagementSystem.Entities.InspectionReport", "InspectionReport")
+                        .WithMany("InspectionReportDetails")
+                        .HasForeignKey("InspectionReportGuid")
+                        .OnDelete(DeleteBehavior.Cascade)
+                        .IsRequired();
+
+                    b.Navigation("InspectionReport");
+                });
+
+            modelBuilder.Entity("UniformMaterialManagementSystem.Entities.MenuItem", b =>
+                {
+                    b.HasOne("UniformMaterialManagementSystem.Entities.MenuItem", "Parent")
+                        .WithMany("Children")
+                        .HasForeignKey("ParentGuid")
+                        .OnDelete(DeleteBehavior.Restrict);
+
+                    b.Navigation("Parent");
+                });
+
+            modelBuilder.Entity("UniformMaterialManagementSystem.Entities.RoleMenuItem", b =>
+                {
+                    b.HasOne("UniformMaterialManagementSystem.Entities.MenuItem", "MenuItem")
+                        .WithMany("MenuRoles")
+                        .HasForeignKey("MenuItemGuid")
+                        .OnDelete(DeleteBehavior.Cascade)
+                        .IsRequired();
+
+                    b.HasOne("UniformMaterialManagementSystem.Entities.Role", "Role")
+                        .WithMany("RoleMenus")
+                        .HasForeignKey("RoleGuid")
+                        .OnDelete(DeleteBehavior.Cascade)
+                        .IsRequired();
+
+                    b.Navigation("MenuItem");
+
+                    b.Navigation("Role");
+                });
+
+            modelBuilder.Entity("UniformMaterialManagementSystem.Entities.SampleRegistration", b =>
+                {
+                    b.HasOne("UniformMaterialManagementSystem.Entities.InspectApply", "InspectApply")
+                        .WithMany()
+                        .HasForeignKey("InspectApplyGuid")
+                        .OnDelete(DeleteBehavior.Cascade)
+                        .IsRequired();
+
+                    b.Navigation("InspectApply");
+                });
+
+            modelBuilder.Entity("UniformMaterialManagementSystem.Entities.User", b =>
+                {
+                    b.HasOne("UniformMaterialManagementSystem.Entities.Company", "Company")
+                        .WithMany()
+                        .HasForeignKey("CompanyGuid");
+
+                    b.HasOne("UniformMaterialManagementSystem.Entities.SupervisionUnit", "SupervisionUnit")
+                        .WithMany()
+                        .HasForeignKey("SupervisionUnitGuid")
+                        .OnDelete(DeleteBehavior.Cascade)
+                        .IsRequired();
+
+                    b.Navigation("Company");
+
+                    b.Navigation("SupervisionUnit");
+                });
+
+            modelBuilder.Entity("UniformMaterialManagementSystem.Entities.UserRole", b =>
+                {
+                    b.HasOne("UniformMaterialManagementSystem.Entities.Role", "Role")
+                        .WithMany("UserRoles")
+                        .HasForeignKey("RoleGuid")
+                        .OnDelete(DeleteBehavior.Cascade)
+                        .IsRequired();
+
+                    b.HasOne("UniformMaterialManagementSystem.Entities.User", "User")
+                        .WithMany("UserRoles")
+                        .HasForeignKey("UserGuid")
+                        .OnDelete(DeleteBehavior.Cascade)
+                        .IsRequired();
+
+                    b.Navigation("Role");
+
+                    b.Navigation("User");
+                });
+
+            modelBuilder.Entity("UniformMaterialManagementSystem.Entities.Contract", b =>
+                {
+                    b.Navigation("ContractDetails");
+                });
+
+            modelBuilder.Entity("UniformMaterialManagementSystem.Entities.DeliveryReceipt", b =>
+                {
+                    b.Navigation("DeliveryReceiptDetails");
+                });
+
+            modelBuilder.Entity("UniformMaterialManagementSystem.Entities.InspectApply", b =>
+                {
+                    b.Navigation("InspectApplyContractDetails");
+
+                    b.Navigation("InspectApplyDetails");
+                });
+
+            modelBuilder.Entity("UniformMaterialManagementSystem.Entities.InspectionReport", b =>
+                {
+                    b.Navigation("InspectionReportDetails");
+                });
+
+            modelBuilder.Entity("UniformMaterialManagementSystem.Entities.MenuItem", b =>
+                {
+                    b.Navigation("Children");
+
+                    b.Navigation("MenuRoles");
+                });
+
+            modelBuilder.Entity("UniformMaterialManagementSystem.Entities.Role", b =>
+                {
+                    b.Navigation("RoleMenus");
+
+                    b.Navigation("UserRoles");
+                });
+
+            modelBuilder.Entity("UniformMaterialManagementSystem.Entities.User", b =>
+                {
+                    b.Navigation("UserRoles");
+                });
+#pragma warning restore 612, 618
+        }
+    }
+}

+ 296 - 0
UniformMaterialManagementSystem/Migrations/20240819011940_ModifyDoubleToDecimal.cs

@@ -0,0 +1,296 @@
+using Microsoft.EntityFrameworkCore.Migrations;
+
+#nullable disable
+
+namespace UniformMaterialManagementSystem.Migrations
+{
+    /// <inheritdoc />
+    public partial class ModifyDoubleToDecimal : Migration
+    {
+        /// <inheritdoc />
+        protected override void Up(MigrationBuilder migrationBuilder)
+        {
+            migrationBuilder.AlterColumn<decimal>(
+                name: "Quantity",
+                table: "SampleRegistrations",
+                type: "TEXT",
+                nullable: false,
+                oldClrType: typeof(double),
+                oldType: "REAL");
+
+            migrationBuilder.AlterColumn<decimal>(
+                name: "Quantity",
+                table: "InspectApplyDetails",
+                type: "TEXT",
+                nullable: false,
+                oldClrType: typeof(double),
+                oldType: "REAL");
+
+            migrationBuilder.AlterColumn<decimal>(
+                name: "UnInspectQty",
+                table: "InspectApplyContractDetails",
+                type: "TEXT",
+                nullable: false,
+                oldClrType: typeof(double),
+                oldType: "REAL");
+
+            migrationBuilder.AlterColumn<decimal>(
+                name: "InspectQty",
+                table: "InspectApplyContractDetails",
+                type: "TEXT",
+                nullable: false,
+                oldClrType: typeof(double),
+                oldType: "REAL");
+
+            migrationBuilder.AlterColumn<decimal>(
+                name: "InspQuantity",
+                table: "InspectApplies",
+                type: "TEXT",
+                nullable: false,
+                oldClrType: typeof(double),
+                oldType: "REAL");
+
+            migrationBuilder.AlterColumn<decimal>(
+                name: "FactoryQuantity",
+                table: "FactoryLicenses",
+                type: "TEXT",
+                nullable: false,
+                oldClrType: typeof(double),
+                oldType: "REAL");
+
+            migrationBuilder.AlterColumn<decimal>(
+                name: "ShippedQty",
+                table: "DeliveryReceipts",
+                type: "TEXT",
+                nullable: false,
+                oldClrType: typeof(double),
+                oldType: "REAL");
+
+            migrationBuilder.AlterColumn<decimal>(
+                name: "ReceivedQty",
+                table: "DeliveryReceipts",
+                type: "TEXT",
+                nullable: true,
+                oldClrType: typeof(double),
+                oldType: "REAL",
+                oldNullable: true);
+
+            migrationBuilder.AlterColumn<decimal>(
+                name: "ContractQty",
+                table: "DeliveryReceipts",
+                type: "TEXT",
+                nullable: false,
+                oldClrType: typeof(double),
+                oldType: "REAL");
+
+            migrationBuilder.AlterColumn<decimal>(
+                name: "UsageQuantity",
+                table: "DeliveryReceiptDetails",
+                type: "TEXT",
+                nullable: true,
+                oldClrType: typeof(double),
+                oldType: "REAL",
+                oldNullable: true);
+
+            migrationBuilder.AlterColumn<decimal>(
+                name: "ShippedQuantity",
+                table: "DeliveryReceiptDetails",
+                type: "TEXT",
+                nullable: false,
+                oldClrType: typeof(double),
+                oldType: "REAL");
+
+            migrationBuilder.AlterColumn<decimal>(
+                name: "ReceiveQuantity",
+                table: "DeliveryReceiptDetails",
+                type: "TEXT",
+                nullable: true,
+                oldClrType: typeof(double),
+                oldType: "REAL",
+                oldNullable: true);
+
+            migrationBuilder.AlterColumn<decimal>(
+                name: "UnitPrice",
+                table: "ContractDetails",
+                type: "TEXT",
+                nullable: false,
+                oldClrType: typeof(double),
+                oldType: "REAL");
+
+            migrationBuilder.AlterColumn<decimal>(
+                name: "ShippedQuantity",
+                table: "ContractDetails",
+                type: "TEXT",
+                nullable: false,
+                oldClrType: typeof(double),
+                oldType: "REAL");
+
+            migrationBuilder.AlterColumn<decimal>(
+                name: "ReduceQuantity",
+                table: "ContractDetails",
+                type: "TEXT",
+                nullable: false,
+                oldClrType: typeof(double),
+                oldType: "REAL");
+
+            migrationBuilder.AlterColumn<decimal>(
+                name: "InspectedQty",
+                table: "ContractDetails",
+                type: "TEXT",
+                nullable: false,
+                oldClrType: typeof(double),
+                oldType: "REAL");
+
+            migrationBuilder.AlterColumn<decimal>(
+                name: "ContractQty",
+                table: "ContractDetails",
+                type: "TEXT",
+                nullable: false,
+                oldClrType: typeof(double),
+                oldType: "REAL");
+        }
+
+        /// <inheritdoc />
+        protected override void Down(MigrationBuilder migrationBuilder)
+        {
+            migrationBuilder.AlterColumn<double>(
+                name: "Quantity",
+                table: "SampleRegistrations",
+                type: "REAL",
+                nullable: false,
+                oldClrType: typeof(decimal),
+                oldType: "TEXT");
+
+            migrationBuilder.AlterColumn<double>(
+                name: "Quantity",
+                table: "InspectApplyDetails",
+                type: "REAL",
+                nullable: false,
+                oldClrType: typeof(decimal),
+                oldType: "TEXT");
+
+            migrationBuilder.AlterColumn<double>(
+                name: "UnInspectQty",
+                table: "InspectApplyContractDetails",
+                type: "REAL",
+                nullable: false,
+                oldClrType: typeof(decimal),
+                oldType: "TEXT");
+
+            migrationBuilder.AlterColumn<double>(
+                name: "InspectQty",
+                table: "InspectApplyContractDetails",
+                type: "REAL",
+                nullable: false,
+                oldClrType: typeof(decimal),
+                oldType: "TEXT");
+
+            migrationBuilder.AlterColumn<double>(
+                name: "InspQuantity",
+                table: "InspectApplies",
+                type: "REAL",
+                nullable: false,
+                oldClrType: typeof(decimal),
+                oldType: "TEXT");
+
+            migrationBuilder.AlterColumn<double>(
+                name: "FactoryQuantity",
+                table: "FactoryLicenses",
+                type: "REAL",
+                nullable: false,
+                oldClrType: typeof(decimal),
+                oldType: "TEXT");
+
+            migrationBuilder.AlterColumn<double>(
+                name: "ShippedQty",
+                table: "DeliveryReceipts",
+                type: "REAL",
+                nullable: false,
+                oldClrType: typeof(decimal),
+                oldType: "TEXT");
+
+            migrationBuilder.AlterColumn<double>(
+                name: "ReceivedQty",
+                table: "DeliveryReceipts",
+                type: "REAL",
+                nullable: true,
+                oldClrType: typeof(decimal),
+                oldType: "TEXT",
+                oldNullable: true);
+
+            migrationBuilder.AlterColumn<double>(
+                name: "ContractQty",
+                table: "DeliveryReceipts",
+                type: "REAL",
+                nullable: false,
+                oldClrType: typeof(decimal),
+                oldType: "TEXT");
+
+            migrationBuilder.AlterColumn<double>(
+                name: "UsageQuantity",
+                table: "DeliveryReceiptDetails",
+                type: "REAL",
+                nullable: true,
+                oldClrType: typeof(decimal),
+                oldType: "TEXT",
+                oldNullable: true);
+
+            migrationBuilder.AlterColumn<double>(
+                name: "ShippedQuantity",
+                table: "DeliveryReceiptDetails",
+                type: "REAL",
+                nullable: false,
+                oldClrType: typeof(decimal),
+                oldType: "TEXT");
+
+            migrationBuilder.AlterColumn<double>(
+                name: "ReceiveQuantity",
+                table: "DeliveryReceiptDetails",
+                type: "REAL",
+                nullable: true,
+                oldClrType: typeof(decimal),
+                oldType: "TEXT",
+                oldNullable: true);
+
+            migrationBuilder.AlterColumn<double>(
+                name: "UnitPrice",
+                table: "ContractDetails",
+                type: "REAL",
+                nullable: false,
+                oldClrType: typeof(decimal),
+                oldType: "TEXT");
+
+            migrationBuilder.AlterColumn<double>(
+                name: "ShippedQuantity",
+                table: "ContractDetails",
+                type: "REAL",
+                nullable: false,
+                oldClrType: typeof(decimal),
+                oldType: "TEXT");
+
+            migrationBuilder.AlterColumn<double>(
+                name: "ReduceQuantity",
+                table: "ContractDetails",
+                type: "REAL",
+                nullable: false,
+                oldClrType: typeof(decimal),
+                oldType: "TEXT");
+
+            migrationBuilder.AlterColumn<double>(
+                name: "InspectedQty",
+                table: "ContractDetails",
+                type: "REAL",
+                nullable: false,
+                oldClrType: typeof(decimal),
+                oldType: "TEXT");
+
+            migrationBuilder.AlterColumn<double>(
+                name: "ContractQty",
+                table: "ContractDetails",
+                type: "REAL",
+                nullable: false,
+                oldClrType: typeof(decimal),
+                oldType: "TEXT");
+        }
+    }
+}

+ 34 - 34
UniformMaterialManagementSystem/Migrations/SqliteContextModelSnapshot.cs

@@ -133,8 +133,8 @@ namespace UniformMaterialManagementSystem.Migrations
                     b.Property<Guid>("ContractGuid")
                         .HasColumnType("TEXT");
 
-                    b.Property<double>("ContractQty")
-                        .HasColumnType("REAL");
+                    b.Property<decimal>("ContractQty")
+                        .HasColumnType("TEXT");
 
                     b.Property<DateTime>("DeliveryTime")
                         .HasColumnType("TEXT");
@@ -144,23 +144,23 @@ namespace UniformMaterialManagementSystem.Migrations
                         .HasMaxLength(50)
                         .HasColumnType("TEXT");
 
-                    b.Property<double>("InspectedQty")
-                        .HasColumnType("REAL");
+                    b.Property<decimal>("InspectedQty")
+                        .HasColumnType("TEXT");
 
                     b.Property<Guid>("MaterialGuid")
                         .HasColumnType("TEXT");
 
-                    b.Property<double>("ReduceQuantity")
-                        .HasColumnType("REAL");
+                    b.Property<decimal>("ReduceQuantity")
+                        .HasColumnType("TEXT");
 
-                    b.Property<double>("ShippedQuantity")
-                        .HasColumnType("REAL");
+                    b.Property<decimal>("ShippedQuantity")
+                        .HasColumnType("TEXT");
 
                     b.Property<bool>("ShippedStatus")
                         .HasColumnType("INTEGER");
 
-                    b.Property<double>("UnitPrice")
-                        .HasColumnType("REAL");
+                    b.Property<decimal>("UnitPrice")
+                        .HasColumnType("TEXT");
 
                     b.HasKey("Guid");
 
@@ -192,8 +192,8 @@ namespace UniformMaterialManagementSystem.Migrations
                         .IsRequired()
                         .HasColumnType("TEXT");
 
-                    b.Property<double>("ContractQty")
-                        .HasColumnType("REAL");
+                    b.Property<decimal>("ContractQty")
+                        .HasColumnType("TEXT");
 
                     b.Property<DateTime>("ContractSigningDate")
                         .HasColumnType("TEXT");
@@ -231,8 +231,8 @@ namespace UniformMaterialManagementSystem.Migrations
                     b.Property<int?>("ReceivedPackets")
                         .HasColumnType("INTEGER");
 
-                    b.Property<double?>("ReceivedQty")
-                        .HasColumnType("REAL");
+                    b.Property<decimal?>("ReceivedQty")
+                        .HasColumnType("TEXT");
 
                     b.Property<string>("ReceivedStatus")
                         .HasColumnType("TEXT");
@@ -249,8 +249,8 @@ namespace UniformMaterialManagementSystem.Migrations
                     b.Property<int>("ShippedPackets")
                         .HasColumnType("INTEGER");
 
-                    b.Property<double>("ShippedQty")
-                        .HasColumnType("REAL");
+                    b.Property<decimal>("ShippedQty")
+                        .HasColumnType("TEXT");
 
                     b.Property<string>("ShippedTel")
                         .HasColumnType("TEXT");
@@ -280,17 +280,17 @@ namespace UniformMaterialManagementSystem.Migrations
                         .IsRequired()
                         .HasColumnType("TEXT");
 
-                    b.Property<double?>("ReceiveQuantity")
-                        .HasColumnType("REAL");
+                    b.Property<decimal?>("ReceiveQuantity")
+                        .HasColumnType("TEXT");
 
                     b.Property<string>("ShipNote")
                         .HasColumnType("TEXT");
 
-                    b.Property<double>("ShippedQuantity")
-                        .HasColumnType("REAL");
+                    b.Property<decimal>("ShippedQuantity")
+                        .HasColumnType("TEXT");
 
-                    b.Property<double?>("UsageQuantity")
-                        .HasColumnType("REAL");
+                    b.Property<decimal?>("UsageQuantity")
+                        .HasColumnType("TEXT");
 
                     b.Property<string>("UsageStatus")
                         .HasColumnType("TEXT");
@@ -329,8 +329,8 @@ namespace UniformMaterialManagementSystem.Migrations
                     b.Property<DateTime>("FactoryDate")
                         .HasColumnType("TEXT");
 
-                    b.Property<double>("FactoryQuantity")
-                        .HasColumnType("REAL");
+                    b.Property<decimal>("FactoryQuantity")
+                        .HasColumnType("TEXT");
 
                     b.Property<Guid>("InspectApplyGuid")
                         .HasColumnType("TEXT");
@@ -405,8 +405,8 @@ namespace UniformMaterialManagementSystem.Migrations
                     b.Property<DateTime>("InspDate")
                         .HasColumnType("TEXT");
 
-                    b.Property<double>("InspQuantity")
-                        .HasColumnType("REAL");
+                    b.Property<decimal>("InspQuantity")
+                        .HasColumnType("TEXT");
 
                     b.Property<byte[]>("InspReport")
                         .HasColumnType("BLOB");
@@ -470,8 +470,8 @@ namespace UniformMaterialManagementSystem.Migrations
                         .HasMaxLength(50)
                         .HasColumnType("TEXT");
 
-                    b.Property<double>("InspectQty")
-                        .HasColumnType("REAL");
+                    b.Property<decimal>("InspectQty")
+                        .HasColumnType("TEXT");
 
                     b.Property<string>("PurchaseCompany")
                         .IsRequired()
@@ -488,8 +488,8 @@ namespace UniformMaterialManagementSystem.Migrations
                         .HasMaxLength(50)
                         .HasColumnType("TEXT");
 
-                    b.Property<double>("UnInspectQty")
-                        .HasColumnType("REAL");
+                    b.Property<decimal>("UnInspectQty")
+                        .HasColumnType("TEXT");
 
                     b.HasKey("Guid");
 
@@ -521,8 +521,8 @@ namespace UniformMaterialManagementSystem.Migrations
                         .HasMaxLength(50)
                         .HasColumnType("TEXT");
 
-                    b.Property<double>("Quantity")
-                        .HasColumnType("REAL");
+                    b.Property<decimal>("Quantity")
+                        .HasColumnType("TEXT");
 
                     b.Property<bool>("ShippedStatus")
                         .HasColumnType("INTEGER");
@@ -827,8 +827,8 @@ namespace UniformMaterialManagementSystem.Migrations
                         .HasMaxLength(100)
                         .HasColumnType("TEXT");
 
-                    b.Property<double>("Quantity")
-                        .HasColumnType("REAL");
+                    b.Property<decimal>("Quantity")
+                        .HasColumnType("TEXT");
 
                     b.Property<string>("SampleNo")
                         .IsRequired()