This commit is contained in:
2021-03-04 22:24:40 +00:00
parent 7927fce640
commit b7d546ef02
4 changed files with 46 additions and 6 deletions

View File

@@ -22,6 +22,12 @@ namespace AyaNova.Models
public string CustomFields { get; set; }
public List<string> Tags { get; set; }
//new for v8
//response
//discountservicerate (all service rates)
//discounttravelrate (all travel)
public Contract()
{
@@ -34,3 +40,36 @@ namespace AyaNova.Models
}//eoc
}//eons
/*
CREATE TABLE [dbo].[ACONTRACT](
[AID] [uniqueidentifier] NOT NULL,
[ACREATOR] [uniqueidentifier] NULL,
[AMODIFIER] [uniqueidentifier] NULL,
[ACREATED] [datetime] NULL,
[AMODIFIED] [datetime] NULL,
[ADISCOUNTPARTS] [decimal](19, 5) NULL,
[ANAME] [nvarchar](255) NULL,
[AACTIVE] [bit] NOT NULL,
[ANOTES] [ntext] NULL,
[ACONTRACTRATESONLY] [bit] NOT NULL,
[ACUSTOM1] [ntext] 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,
[AREGIONID] [uniqueidentifier] NULL,
CHILDREN
ContractRate - specific contract rates available to contract holding entities only
ContractTravel - specific contract travel rates only ''
ContractRateTagOverride - tags and discount / markup to apply collection
ContractTravelTagOverride - ''
ContractPartTagOverride - ''
*/

View File

@@ -29,6 +29,7 @@ namespace AyaNova.Models
[Required]
public decimal Charge { get; set; }
public string Unit { get; set; }
public bool ContractOnly { get; set; }
@@ -59,6 +60,6 @@ namespace AyaNova.Models
[ARATETYPE] [smallint] NOT NULL,//REMOVE SPLITTING INTO TRAVEL AND LABOR SEPERATELY
[ARATEUNITCHARGEDESCRIPTIONID] [uniqueidentifier] //TURN THIS INTO TEXT PLAIN AND SIMPLE,
[ACLIENTGROUPID] [uniqueidentifier] NULL, //TAG remove
[ACONTRACTRATE] [bit] NOT NULL,//THIS IS ONLY FOR THE UI, REMOVE IT
[ACONTRACTRATE] [bit] NOT NULL,
[AREGIONID] [uniqueidentifier] NULL,//tag, remove
*/

View File

@@ -29,12 +29,12 @@ namespace AyaNova.Models
[Required]
public decimal Charge { get; set; }
public string Unit { get; set; }
public bool ContractOnly { get; set; }
public TravelRate()
{
Tags = new List<string>();
Tags = new List<string>();
}
[NotMapped, JsonIgnore]
@@ -59,6 +59,6 @@ namespace AyaNova.Models
[ARATETYPE] [smallint] NOT NULL,//REMOVE SPLITTING INTO TRAVEL AND Travel SEPERATELY
[ARATEUNITCHARGEDESCRIPTIONID] [uniqueidentifier] //TURN THIS INTO TEXT PLAIN AND SIMPLE,
[ACLIENTGROUPID] [uniqueidentifier] NULL, //TAG remove
[ACONTRACTRATE] [bit] NOT NULL,//THIS IS ONLY FOR THE UI, REMOVE IT
[ACONTRACTRATE] [bit] NOT NULL,
[AREGIONID] [uniqueidentifier] NULL,//tag, remove
*/

View File

@@ -573,12 +573,12 @@ $BODY$ LANGUAGE PLPGSQL STABLE");
//SERVICERATE
await ExecQueryAsync("CREATE TABLE aservicerate (id BIGINT GENERATED ALWAYS AS IDENTITY PRIMARY KEY, name TEXT NOT NULL UNIQUE, active BOOL NOT NULL, "
+ "notes TEXT, wiki TEXT, customfields TEXT, tags VARCHAR(255) ARRAY, "
+ "accountnumber TEXT, unit TEXT, cost DECIMAL(19,4) NOT NULL default 0, charge DECIMAL(19,4) NOT NULL default 0)");
+ "accountnumber TEXT, unit TEXT, contractonly BOOL NOT NULL, cost DECIMAL(19,4) NOT NULL default 0, charge DECIMAL(19,4) NOT NULL default 0)");
//TRAVELRATE
await ExecQueryAsync("CREATE TABLE atravelrate (id BIGINT GENERATED ALWAYS AS IDENTITY PRIMARY KEY, name TEXT NOT NULL UNIQUE, active BOOL NOT NULL, "
+ "notes TEXT, wiki TEXT, customfields TEXT, tags VARCHAR(255) ARRAY, "
+ "accountnumber TEXT, unit TEXT, cost DECIMAL(19,4) NOT NULL default 0, charge DECIMAL(19,4) NOT NULL default 0)");
+ "accountnumber TEXT, unit TEXT, contractonly BOOL NOT NULL, cost DECIMAL(19,4) NOT NULL default 0, charge DECIMAL(19,4) NOT NULL default 0)");
//TAXCODE
await ExecQueryAsync("CREATE TABLE ataxcode (id BIGINT GENERATED ALWAYS AS IDENTITY PRIMARY KEY, name TEXT NOT NULL UNIQUE, active BOOL NOT NULL, "