This commit is contained in:
@@ -16,8 +16,8 @@ namespace AyaNova.DataList
|
|||||||
+ "left join aworkorder on (aworkorderitem.workorderid = aworkorder.id)";
|
+ "left join aworkorder on (aworkorderitem.workorderid = aworkorder.id)";
|
||||||
var RoleSet = BizRoles.GetRoleSet(DefaultListAType);
|
var RoleSet = BizRoles.GetRoleSet(DefaultListAType);
|
||||||
AllowedRoles = RoleSet.ReadFullRecord | RoleSet.Change;
|
AllowedRoles = RoleSet.ReadFullRecord | RoleSet.Change;
|
||||||
DefaultColumns = new List<string>() { "notedate", "UnitMeterReadingDescription", "Unit" };
|
DefaultColumns = new List<string>() { "UnitMeterReadingMeterDate", "UnitMeterReadingMeter", "UnitMeterReadingDescription" };
|
||||||
DefaultSortBy = new Dictionary<string, string>() { { "notedate", "-" } };
|
DefaultSortBy = new Dictionary<string, string>() { { "UnitMeterReadingMeterDate", "-" } };
|
||||||
|
|
||||||
FieldDefinitions = new List<DataListFieldDefinition>();
|
FieldDefinitions = new List<DataListFieldDefinition>();
|
||||||
|
|
||||||
@@ -28,7 +28,7 @@ namespace AyaNova.DataList
|
|||||||
AType = (int)AyaType.Unit,
|
AType = (int)AyaType.Unit,
|
||||||
UiFieldDataType = (int)UiFieldDataType.Text,
|
UiFieldDataType = (int)UiFieldDataType.Text,
|
||||||
SqlIdColumnName = "aunit.id",
|
SqlIdColumnName = "aunit.id",
|
||||||
SqlValueColumnName = "aunit.name",
|
SqlValueColumnName = "aunit.serial",
|
||||||
IsRowId = false
|
IsRowId = false
|
||||||
});
|
});
|
||||||
|
|
||||||
@@ -39,7 +39,7 @@ namespace AyaNova.DataList
|
|||||||
AType = (int)AyaType.UnitMeterReading,
|
AType = (int)AyaType.UnitMeterReading,
|
||||||
UiFieldDataType = (int)UiFieldDataType.Text,
|
UiFieldDataType = (int)UiFieldDataType.Text,
|
||||||
SqlIdColumnName = "aunitmeterreading.id",
|
SqlIdColumnName = "aunitmeterreading.id",
|
||||||
SqlValueColumnName = "aunitmeterreading.description",
|
SqlValueColumnName = "aunitmeterreading.notes",
|
||||||
IsRowId = false
|
IsRowId = false
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|||||||
@@ -94,7 +94,7 @@ namespace AyaNova.Biz
|
|||||||
public void DigestSearchText(UnitMeterReading obj, Search.SearchIndexProcessObjectParameters searchParams)
|
public void DigestSearchText(UnitMeterReading obj, Search.SearchIndexProcessObjectParameters searchParams)
|
||||||
{
|
{
|
||||||
if (obj != null)
|
if (obj != null)
|
||||||
searchParams.AddText(obj.Description)
|
searchParams.AddText(obj.Notes)
|
||||||
.AddText(obj.Meter);
|
.AddText(obj.Meter);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -14,7 +14,7 @@ namespace AyaNova.Models
|
|||||||
{
|
{
|
||||||
public long Id { get; set; }
|
public long Id { get; set; }
|
||||||
public uint Concurrency { get; set; }
|
public uint Concurrency { get; set; }
|
||||||
public string Description { get; set; }
|
public string Notes { get; set; }
|
||||||
public long Meter { get; set; }
|
public long Meter { get; set; }
|
||||||
public DateTime MeterDate { get; set; }
|
public DateTime MeterDate { get; set; }
|
||||||
public long UnitId { get; set; }
|
public long UnitId { get; set; }
|
||||||
|
|||||||
@@ -1119,7 +1119,7 @@ $BODY$ LANGUAGE PLPGSQL STABLE");
|
|||||||
+ "objectid BIGINT NOT NULL, notifysubscriptionid BIGINT NOT NULL, fail BOOL NOT NULL, error TEXT)");
|
+ "objectid BIGINT NOT NULL, notifysubscriptionid BIGINT NOT NULL, fail BOOL NOT NULL, error TEXT)");
|
||||||
|
|
||||||
//UNITMETERREADING
|
//UNITMETERREADING
|
||||||
await ExecQueryAsync("CREATE TABLE aunitmeterreading (id BIGINT GENERATED ALWAYS AS IDENTITY PRIMARY KEY, meterdate TIMESTAMP NOT NULL, description TEXT, "
|
await ExecQueryAsync("CREATE TABLE aunitmeterreading (id BIGINT GENERATED ALWAYS AS IDENTITY PRIMARY KEY, meterdate TIMESTAMP NOT NULL, notes TEXT, "
|
||||||
+ "meter BIGINT NOT NULL, unitid BIGINT NOT NULL REFERENCES aunit(id) ON DELETE CASCADE, workorderitemunitid BIGINT REFERENCES aworkorderitemunit(id) ON DELETE SET NULL)");
|
+ "meter BIGINT NOT NULL, unitid BIGINT NOT NULL REFERENCES aunit(id) ON DELETE CASCADE, workorderitemunitid BIGINT REFERENCES aworkorderitemunit(id) ON DELETE SET NULL)");
|
||||||
|
|
||||||
//LOGO
|
//LOGO
|
||||||
|
|||||||
Reference in New Issue
Block a user