Skip to content

Commit a41a2f1

Browse files
committed
Demo: added a multi-select field for "projects".
1 parent b280ac0 commit a41a2f1

File tree

3 files changed

+35
-23
lines changed

3 files changed

+35
-23
lines changed

less/demo.less

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -122,7 +122,7 @@ h1,h2,h3,h4{
122122
[data-eid="todo"],
123123
[data-eid="contact"] {
124124
.evol-cards-body > .panel {
125-
height: 160px !important;
125+
height: 205px !important;
126126
}
127127
}
128128
[data-eid="winecellar"] .evol-cards-body {

ui-models/todo.data.js

Lines changed: 22 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -1,28 +1,28 @@
11
var uiModels = uiModels || {};
22
uiModels.todo_data = [
3-
{id: '1', title: 'Release Evolutility v1', priority: '3', category: 'others', complete: false, description: '10 generic views + a ui-modeling language.', notes:''},
4-
{id: '2', title: 'Fix open bugs', duedate: '2014-07-25', priority: '3', category: 'work', complete: false, description: 'bla bla'},
5-
{id: '3', title: 'Testing App', duedate: '2014-06-11', priority: '3', category: 'work', complete: false, description: 'test'},
6-
{id: '4', title: 'Prepare demo', duedate: '2014-05-12', priority: '1', category: 'work', complete: false, description: 'Check this out'},
7-
{id: '5', title: 'Test latest code', priority: '5', category: 'misc', complete: true, description: 'notes for my test todo task.'},
8-
{id: '6', title: 'Car wash', priority: '4', category: 'work', complete: false},
9-
{id: '7', title: 'Watch Inception', duedate: '2014-01-10', priority: '5', category: 'fun', complete: true},
10-
{id: '8', title: 'Test TODO', duedate: '2015-01-01', priority: '1', category: 'work', complete: true, description: 'Test TODO '},
3+
{id: '1', title: 'Release Evolutility v1', priority: '3', category: 'others', complete: false, project:['1','2','3'], description: '10 generic views + a ui-modeling language.', notes:''},
4+
{id: '2', title: 'Fix open bugs', duedate: '2014-07-25', priority: '3', category: 'work', project:['1','2'], complete: false, description: 'bla bla'},
5+
{id: '3', title: 'Testing App', duedate: '2014-06-11', priority: '3', category: 'work', complete: false, project:['1', '2','3'], description: 'test'},
6+
{id: '4', title: 'Prepare demo', duedate: '2014-05-12', priority: '1', category: 'work', complete: false, project:['4'], description: 'Check this out'},
7+
{id: '5', title: 'Test latest code', priority: '5', category: 'misc', complete: true, project:['1','2','3'], description: 'notes for my test todo task.'},
8+
{id: '6', title: 'Car wash', priority: '4', category: 'work', project:['10'], complete: false},
9+
{id: '7', title: 'Watch Inception', duedate: '2014-01-10', priority: '5', category: 'fun', project:['10'], complete: true},
10+
{id: '8', title: 'Test TODO', duedate: '2015-01-01', priority: '1', category: 'work', project:['2','3'], complete: true, description: 'Test TODO '},
1111
{id: '9', title: 'Dentist', priority: '3', category: 'home', complete: true},
12-
{id: '10', title: 'French translation', priority: '4', category: 'work', complete: true},
13-
{id: '11', title: 'Italian translation', priority: '4', category: 'work'},
14-
{id: '12', title: 'Chinese translation', priority: '4', category: 'work'},
15-
{id: '13', title: 'Japanese translation', priority: '4', category: 'work'},
16-
{id: '14', title: 'German translation', priority: '4', category: 'work'},
17-
{id: '15', title: 'Russian translation', priority: '4', category: 'work'},
18-
{id: '16', title: 'Polish translation', priority: '4', category: 'work'},
19-
{id: '17', title: 'Klingon translation', priority: '4', category: 'work'},
20-
{id: '18', title: 'Code optimization', duedate: '2015-01-01', priority: '4', category: 'work', complete: false},
21-
{id: '19', title: 'Setup demo server', priority: '2', category: 'work', complete: false},
22-
{id: '20', title: 'Add sample data', duedate: '2014-04-23', priority: '3', category: 'work', complete: true},
23-
{id: '21', title: 'Make proposal', priority: '2', category: 'misc', complete: false},
24-
{id: '22', title: 'Checkout cool restaurant', priority: '3', category: 'home', complete: false},
25-
{id: '23', title: 'Kill the vampires', priority: '3', category: 'others'}
12+
{id: '10', title: 'French translation', priority: '4', category: 'work', project:['5'], complete: true},
13+
{id: '11', title: 'Italian translation', priority: '4', category: 'work', project:['5']},
14+
{id: '12', title: 'Chinese translation', priority: '4', category: 'work', project:['5']},
15+
{id: '13', title: 'Japanese translation', priority: '4', category: 'work', project:['5']},
16+
{id: '14', title: 'German translation', priority: '4', category: 'work', project:['5']},
17+
{id: '15', title: 'Russian translation', priority: '4', category: 'work', project:['5']},
18+
{id: '16', title: 'Polish translation', priority: '4', category: 'work', project:['5']},
19+
{id: '17', title: 'Klingon translation', priority: '4', category: 'work', project:['5']},
20+
{id: '18', title: 'Code optimization', duedate: '2015-01-01', priority: '4', category: 'work', project:['1','2','4'], complete: false},
21+
{id: '19', title: 'Setup demo server', priority: '2', category: 'work', complete: false, project:['4']},
22+
{id: '20', title: 'Add sample data', duedate: '2014-04-23', priority: '3', category: 'work', project:['1','2','3'], complete: true},
23+
{id: '21', title: 'Make proposal', priority: '2', category: 'misc', project:['4'], complete: false},
24+
{id: '22', title: 'Checkout cool restaurant', priority: '3', category: 'fun', project: ['4','10'], complete: false},
25+
{id: '23', title: 'Kill the vampires', priority: '3', project:['10'], category: 'others'}
2626
];
2727

2828
if(typeof module === "object" && typeof module.exports === "object"){

ui-models/todo.js

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -59,6 +59,18 @@ uiModels.todo = {
5959
{
6060
type: 'panel', label: 'Task Description', label2:'and Notes', width: 100,
6161
elements: [
62+
{
63+
id: 'project', attribute: 'project', type: 'list', label: 'Projects', width: 100, inMany: true,
64+
list: [
65+
{id: '1', text: 'Project 1'},
66+
{id: '2', text: 'Project 2'},
67+
{id: '3', text: 'Project 3'},
68+
{id: '4', text: 'Top Secret Project'},
69+
{id: '5', text: 'Translation'},
70+
{id: '10', text: 'Other'}
71+
],
72+
typeChart:'bars'
73+
},
6274
{
6375
id: 'description', attribute: 'description', type: 'textmultiline',
6476
label: 'Description',

0 commit comments

Comments
 (0)