Skip to content

Commit 21cfda3

Browse files
authored
Merge pull request #69 from engalar/feat/widget-demo
feat: WidgetDemo baseline
2 parents d5eafe8 + 8a33ee1 commit 21cfda3

5 files changed

Lines changed: 619 additions & 1 deletion

File tree

Lines changed: 56 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,56 @@
1+
-- WidgetDemo: self-contained domain model (no external dependencies)
2+
-- Provides entities and enumerations for the widget showcase page.
3+
4+
CREATE MODULE WidgetDemo;
5+
CREATE MODULE ROLE WidgetDemo.User;
6+
7+
CREATE ENUMERATION WidgetDemo.ENUM_Priority (
8+
LOW 'Low',
9+
MEDIUM 'Medium',
10+
HIGH 'High',
11+
CRITICAL 'Critical'
12+
);
13+
14+
CREATE ENUMERATION WidgetDemo.ENUM_Status (
15+
DRAFT 'Draft',
16+
ACTIVE 'Active',
17+
COMPLETED 'Completed',
18+
ARCHIVED 'Archived'
19+
);
20+
21+
CREATE ENUMERATION WidgetDemo.ENUM_Category (
22+
GENERAL 'General',
23+
INPUT 'Input',
24+
DISPLAY 'Display',
25+
STRUCTURE 'Structure',
26+
DATA_DISPLAY 'Data Display'
27+
);
28+
29+
CREATE PERSISTENT ENTITY WidgetDemo.DemoItem (
30+
Title: String(unlimited) NOT NULL,
31+
Description: String(unlimited),
32+
Code: String(unlimited),
33+
Category: Enumeration(WidgetDemo.ENUM_Category) DEFAULT WidgetDemo.ENUM_Category.GENERAL,
34+
Priority: Enumeration(WidgetDemo.ENUM_Priority) DEFAULT WidgetDemo.ENUM_Priority.MEDIUM,
35+
ItemStatus: Enumeration(WidgetDemo.ENUM_Status) DEFAULT WidgetDemo.ENUM_Status.DRAFT,
36+
IsActive: Boolean DEFAULT true,
37+
Score: Integer DEFAULT 0,
38+
Amount: Decimal DEFAULT 0,
39+
DateCreated: DateTime,
40+
DueDate: DateTime,
41+
Progress: Decimal DEFAULT 0,
42+
Rating: Integer DEFAULT 3,
43+
Notes: String(unlimited),
44+
ImageUrl: String(unlimited)
45+
);
46+
47+
CREATE NON-PERSISTENT ENTITY WidgetDemo.Helper (
48+
Attribute: Enumeration(WidgetDemo.ENUM_Category) DEFAULT WidgetDemo.ENUM_Category.GENERAL
49+
);
50+
51+
CREATE ASSOCIATION WidgetDemo.Helper_DemoItem (
52+
FROM WidgetDemo.Helper TO WidgetDemo.DemoItem,
53+
Type: ReferenceSet
54+
);
55+
56+
GRANT WidgetDemo.User ON WidgetDemo.DemoItem (CREATE, DELETE, READ *, WRITE *);
Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
-- WidgetDemo: Button showcase snippet (referenced by 03-showcase-page)
2+
3+
CREATE SNIPPET WidgetDemo.SNIPPET_ButtonShowcase {
4+
ACTIONBUTTON btnInfo (Caption: 'Info Button', Action: CLOSE_PAGE, ButtonStyle: Info)
5+
ACTIONBUTTON btnLink (Caption: 'Link Button', Action: CLOSE_PAGE, ButtonStyle: Link)
6+
}

0 commit comments

Comments
 (0)