mirror of
https://code.equilibrium.co.ao/ITO/doneit-web.git
synced 2026-04-19 04:57:52 +00:00
add model
This commit is contained in:
@@ -0,0 +1,26 @@
|
||||
import { environment } from 'src/environments/environment';
|
||||
import { models } from 'src/plugin/src';
|
||||
const { ArrayField, JsonField} = models.indexedDB.fields;
|
||||
|
||||
export class CalendarEventModel extends models.Model {
|
||||
startTime = models.CharField()
|
||||
endTime = models.CharField()
|
||||
allDay = models.BooleanField()
|
||||
event = JsonField({blank:true})
|
||||
calendarName = models.CharField()
|
||||
profile = models.CharField()
|
||||
id = models.CharField()
|
||||
CalendarId = models.CharField()
|
||||
}
|
||||
|
||||
export class EventForToday extends models.Model {
|
||||
|
||||
}
|
||||
|
||||
|
||||
models.register({
|
||||
databaseName: 'agenda'+environment.version.lastCommitNumber + environment.id,
|
||||
type: 'indexedDB',
|
||||
version: 14,
|
||||
models: [CalendarEventModel, EventForToday]
|
||||
})
|
||||
@@ -61,7 +61,14 @@ export class ActionModel extends models.Model{
|
||||
ActionType = models.CharField()
|
||||
}
|
||||
|
||||
export class PublicationModel extends models.Model{
|
||||
|
||||
export class PublicationFolderModel extends models.Model{
|
||||
DateBegin = models.CharField()
|
||||
Description = models.CharField()
|
||||
Detail = models.CharField()
|
||||
}
|
||||
|
||||
export class PublicationDetailsModel extends models.Model{
|
||||
DateIndex = models.CharField()
|
||||
DocumentId = models.IntegerField({unique: true})
|
||||
ProcessId = models.CharField()
|
||||
@@ -74,12 +81,6 @@ export class PublicationModel extends models.Model{
|
||||
OrganicEntityId = models.IntegerField()
|
||||
}
|
||||
|
||||
models.register({
|
||||
databaseName: 'actions'+environment.version.lastCommitNumber + environment.id,
|
||||
type: 'indexedDB',
|
||||
version: 14,
|
||||
models: [PublicationModel, ActionModel]
|
||||
})
|
||||
|
||||
export class WebtrixUserModel extends models.Model {
|
||||
FullName = models.CharField()
|
||||
@@ -98,5 +99,5 @@ models.register({
|
||||
databaseName: 'actions'+environment.version.lastCommitNumber + environment.id,
|
||||
type: 'indexedDB',
|
||||
version: 14,
|
||||
models: [PublicationModel, ActionModel]
|
||||
models: [PublicationDetailsModel, ActionModel, PublicationFolderModel]
|
||||
})
|
||||
|
||||
Reference in New Issue
Block a user