This commit is contained in:
@@ -103,8 +103,8 @@ namespace AyaNova.Models
|
||||
[AUSESBANKING] [bit] NOT NULL,
|
||||
[ACONTRACTID] [uniqueidentifier] NULL,
|
||||
[ACONTRACTEXPIRES] [datetime] NULL,
|
||||
[ALASTWORKORDERID] [uniqueidentifier] NULL,
|
||||
[ALASTSERVICEDATE] [datetime] NULL,
|
||||
[ALASTWORKORDERID] [uniqueidentifier] NULL,//dropped case 3536
|
||||
[ALASTSERVICEDATE] [datetime] NULL,//dropped case 3536
|
||||
[ADEFAULTSERVICETEMPLATEID] [uniqueidentifier] NULL,
|
||||
[ACONTACTNOTES] [ntext] NULL,
|
||||
[ACONTACT] [nvarchar](500) NULL,
|
||||
|
||||
@@ -15,14 +15,35 @@ namespace AyaNova.Models
|
||||
public long Id { get; set; }
|
||||
public uint Concurrency { get; set; }
|
||||
|
||||
[Required]
|
||||
public string Name { get; set; }
|
||||
public bool Active { get; set; }
|
||||
public string Notes { get; set; }
|
||||
public string Wiki { get; set; }
|
||||
public string CustomFields { get; set; }
|
||||
public List<string> Tags { get; set; }
|
||||
|
||||
[Required]
|
||||
public string Serial { get; set; }
|
||||
[Required]
|
||||
public long CustomerId { get; set; }
|
||||
public long? ParentUnitId { get; set; }
|
||||
public long? UnitModelId { get; set; }
|
||||
public bool UnitHasOwnAddress { get; set; }
|
||||
public bool BoughtHere { get; set; }
|
||||
public long? PurchasedFromVendorId { get; set; }
|
||||
public string Receipt { get; set; }
|
||||
public DateTime? PurchasedDate { get; set; }
|
||||
public string Description { get; set; }
|
||||
public long? ReplacedByUnitId { get; set; }
|
||||
public bool OverrideModelWarranty { get; set; }
|
||||
public int? WarrantyLength { get; set; }
|
||||
public string WarrantyTerms { get; set; }
|
||||
public bool UsesBanking { get; set; }
|
||||
public bool Metered { get; set; }
|
||||
public bool LifeTimeWarranty { get; set; }
|
||||
public string Text1 { get; set; }
|
||||
public string Text2 { get; set; }
|
||||
public string Text3 { get; set; }
|
||||
public string Text4 { get; set; }
|
||||
|
||||
public Unit()
|
||||
{
|
||||
@@ -32,6 +53,63 @@ namespace AyaNova.Models
|
||||
[NotMapped, JsonIgnore]
|
||||
public AyaType AyaType { get => AyaType.Unit; }
|
||||
|
||||
//convenience links
|
||||
[JsonIgnore]
|
||||
public Customer Customer { get; set; }
|
||||
[JsonIgnore]
|
||||
public UnitModel UnitModel { get; set; }
|
||||
[JsonIgnore]
|
||||
public Unit ParentUnit { get; set; }
|
||||
[JsonIgnore]
|
||||
public Vendor PurchasedFromVendor { get; set; }
|
||||
[JsonIgnore]
|
||||
public Unit ReplacedByUnit { get; set; }
|
||||
|
||||
|
||||
}//eoc
|
||||
|
||||
}//eons
|
||||
/*
|
||||
|
||||
CREATE TABLE [dbo].[AUNIT](
|
||||
[AID] [uniqueidentifier] NOT NULL,
|
||||
[ACREATED] [datetime] NOT NULL,
|
||||
[AMODIFIED] [datetime] NOT NULL,
|
||||
[AACTIVE] [bit] NOT NULL,
|
||||
[ACREATOR] [uniqueidentifier] NOT NULL,
|
||||
[AMODIFIER] [uniqueidentifier] NOT NULL,
|
||||
[ASERIAL] [nvarchar](255) NOT NULL,// MIGRATE: Can't make this unique, but *can* make it unique with the model id UNIQUE(aserial,aunitmodelid) to catch dupes
|
||||
[ANOTES] [ntext] NULL,
|
||||
[ACLIENTID] [uniqueidentifier] NULL,
|
||||
[APARENTUNITID] [uniqueidentifier] NULL,
|
||||
[AUNITMODELID] [uniqueidentifier] NULL,
|
||||
[AUNITHASOWNADDRESS] [bit] NOT NULL,//do we need this? it only ever drove the UI, but I guess that's still valid
|
||||
[ABOUGHTHERE] [bit] NOT NULL,
|
||||
[APURCHASEDFROMID] [uniqueidentifier] NULL,
|
||||
[ARECEIPT] [nvarchar](255) NULL,
|
||||
[APURCHASEDDATE] [datetime] NULL,
|
||||
[ADESCRIPTION] [nvarchar](255) NULL,
|
||||
[AREPLACEDBYUNITID] [uniqueidentifier] NULL,
|
||||
[AOVERRIDEMODELWARRANTY] [bit] NOT NULL,
|
||||
[AWARRANTYTERMS] [nvarchar](255) NULL,
|
||||
[ACUSTOM2] [ntext] NULL,
|
||||
[ACUSTOM3] [ntext] NULL,
|
||||
[ACUSTOM4] [ntext] NULL,
|
||||
[ACUSTOM5] [ntext] NULL,
|
||||
[ACUSTOM6] [ntext] NULL,
|
||||
[ACUSTOM7] [ntext] NULL,
|
||||
[ACUSTOM8] [ntext] NULL,
|
||||
[ACUSTOM9] [ntext] NULL,
|
||||
[ACUSTOM0] [ntext] NULL,
|
||||
[ACUSTOM1] [ntext] NULL,
|
||||
[AUSESBANKING] [bit] NOT NULL,
|
||||
[AMETERED] [bit] NOT NULL,
|
||||
[ALIFETIMEWARRANTY] [bit] NOT NULL,
|
||||
[AWARRANTYLENGTH] [int] NULL,
|
||||
[ALASTWORKORDERID] [uniqueidentifier] NULL,//MIGRATE: DROP as per case 3536, will determine live from query instead if necessary
|
||||
[ALASTSERVICEDATE] [datetime] NULL,//MIGRATE: DROP case 3536
|
||||
[ATEXT1] [nvarchar](255) NULL,
|
||||
[ATEXT2] [nvarchar](255) NULL,
|
||||
[ATEXT3] [nvarchar](255) NULL,
|
||||
[ATEXT4] [nvarchar](255) NULL,
|
||||
*/
|
||||
Reference in New Issue
Block a user