This commit is contained in:
2018-08-29 15:17:44 +00:00
parent 8c1d448ade
commit 5828f617e8
8 changed files with 16 additions and 63 deletions

View File

@@ -18,11 +18,7 @@ Changes needed to routes??
CODING WORK
+++++++++++
Overall plan for now: anything standing in the way of making the initial client shell UI needs to be done first, everything else can wait
- Audit log
- Make sure trial generated data generates log events so that we can properly test with huge dataset
- Users, etc
- Test with huge dataset
Overall plan for now: anything standing in the way of making the initial client shell UI needs to be done first, everything else can wait
- Remove CREATED from all *business* objects now that event log tracks it
- V7 Import: check for efficiency changes after seeing how seeder needed to be optimized
- Also need to see about event log working with it, should it attempt to keep the v7 created / modifed or start afresh

View File

@@ -54,8 +54,7 @@ namespace AyaNova.Biz
Tag outObj = new Tag()
{
Name = inObj,
OwnerId = userId,
Created = System.DateTime.UtcNow
OwnerId = userId
};

View File

@@ -9,7 +9,7 @@ namespace AyaNova.Models
{
public long Id { get; set; }
public uint ConcurrencyToken { get; set; }
public DateTime Created { get; set; }//time it was uploaded not original file creation time, we don't have that
[Required]
public long OwnerId { get; set; }
//-----------------------------------------
@@ -25,13 +25,5 @@ namespace AyaNova.Models
public string ContentType { get; set; }//mime type
public string Notes { get; set; }
public FileAttachment()
{
Created = System.DateTime.UtcNow;
}
}
}
//"AttachToObjectType and / or AttachToObjectId public AuthorizationRoles Roles { get; set; }
}

View File

@@ -19,15 +19,7 @@ namespace AyaNova.Models
[Required]
public string Name { get; set; }
public bool? Stock { get; set; }
public DateTime Created { get; set; }
public Locale()
{
Created = System.DateTime.UtcNow;
}
//Relationship
//was this but..

View File

@@ -10,7 +10,6 @@ namespace AyaNova.Models
public partial class Tag
{
public long Id { get; set; }
public DateTime Created { get; set; }
public uint ConcurrencyToken { get; set; }
[Required]
@@ -18,13 +17,5 @@ namespace AyaNova.Models
[Required]
public string Name { get; set; }//max 35 characters ascii set
public Tag()
{
Created = System.DateTime.UtcNow;
}
}
}

View File

@@ -13,7 +13,6 @@ namespace AyaNova.Models
public uint ConcurrencyToken { get; set; }
[Required]
public long OwnerId { get; set; }
public DateTime Created { get; set; }
[Required]
public long TagId { get; set; }
@@ -22,12 +21,5 @@ namespace AyaNova.Models
[Required]
public AyaType TagToObjectType { get; set; }
public TagMap()
{
Created = System.DateTime.UtcNow;
}
}
}

View File

@@ -8,7 +8,6 @@ namespace AyaNova.Models
public partial class User
{
public long Id { get; set; }
public DateTime Created { get; set; }
public uint ConcurrencyToken { get; set; }
[Required]
public long OwnerId { get; set; }
@@ -21,12 +20,5 @@ namespace AyaNova.Models
public DateTime? DlKeyExpire { get; set; }
public long LocaleId { get; set; }
public User()
{
Created = System.DateTime.UtcNow;
}
}
}

View File

@@ -120,13 +120,6 @@ namespace AyaNova.Util
{
LogUpdateMessage(log);
//create locale text tables
exec("CREATE TABLE alocale (id BIGSERIAL PRIMARY KEY, ownerid bigint not null, name varchar(255) not null, stock bool, created timestamp not null)");
exec("CREATE UNIQUE INDEX localename_idx ON alocale (name)");
exec("CREATE TABLE alocaleitem (id BIGSERIAL PRIMARY KEY, localeid bigint not null REFERENCES alocale (id), key text not null, display text not null)");
exec("CREATE INDEX localeitemlid_key_idx ON alocaleitem (localeid,key)");
//create aevent biz event log table
exec("CREATE TABLE aevent (id BIGSERIAL PRIMARY KEY, created timestamp not null, ownerid bigint not null," +
"ayid bigint not null, aytype integer not null, ayevent integer not null, textra varchar(255))");
@@ -136,11 +129,17 @@ namespace AyaNova.Util
// exec("CREATE INDEX ayid_idx ON aevent (ayid);");
// exec("CREATE INDEX aytype_idx ON aevent (aytype);");
//Prime the db with the default LOCALES
//create locale text tables
exec("CREATE TABLE alocale (id BIGSERIAL PRIMARY KEY, ownerid bigint not null, name varchar(255) not null, stock bool, created timestamp not null)");
exec("CREATE UNIQUE INDEX localename_idx ON alocale (name)");
exec("CREATE TABLE alocaleitem (id BIGSERIAL PRIMARY KEY, localeid bigint not null REFERENCES alocale (id), key text not null, display text not null)");
exec("CREATE INDEX localeitemlid_key_idx ON alocaleitem (localeid,key)");
//Load the default LOCALES
AyaNova.Biz.PrimeData.PrimeLocales(ct);
//Add user table
exec("CREATE TABLE auser (id BIGSERIAL PRIMARY KEY, created timestamp not null, ownerid bigint not null, name varchar(255) not null, " +
exec("CREATE TABLE auser (id BIGSERIAL PRIMARY KEY, ownerid bigint not null, name varchar(255) not null, " +
"login text not null, password text not null, salt text not null, roles integer not null, localeid bigint REFERENCES alocale (id), " +
"dlkey text, dlkeyexpire timestamp)");
@@ -185,7 +184,7 @@ namespace AyaNova.Util
{
LogUpdateMessage(log);
exec("CREATE TABLE afileattachment (id BIGSERIAL PRIMARY KEY, created timestamp not null, ownerid bigint not null," +
exec("CREATE TABLE afileattachment (id BIGSERIAL PRIMARY KEY, ownerid bigint not null," +
"attachtoobjectid bigint not null, attachtoobjecttype integer not null, " +
"storedfilename text not null, displayfilename text not null, contenttype text, notes text)");
@@ -202,9 +201,9 @@ namespace AyaNova.Util
{
LogUpdateMessage(log);
exec("CREATE TABLE atag (id BIGSERIAL PRIMARY KEY, ownerid bigint not null, name varchar(35) not null, created timestamp not null)");
exec("CREATE TABLE atag (id BIGSERIAL PRIMARY KEY, ownerid bigint not null, name varchar(35) not null)");
exec("CREATE UNIQUE INDEX tagname_idx ON atag (name);");
exec("CREATE TABLE atagmap (id BIGSERIAL PRIMARY KEY, created timestamp not null, ownerid bigint not null," +
exec("CREATE TABLE atagmap (id BIGSERIAL PRIMARY KEY, ownerid bigint not null," +
"tagid bigint not null REFERENCES atag (id), tagtoobjectid bigint not null, tagtoobjecttype integer not null)");
setSchemaLevel(++currentSchema);