evolutility
Advanced tools
Comparing version 0.5.0 to 1.0.0
{ | ||
"name": "evolutility", | ||
"version": "0.5", | ||
"version": "1.0.0", | ||
"homepage": "https://github.com/evoluteur/evolutility", | ||
"dependencies": { | ||
"jquery": "2.1.1", | ||
"backbone": "1.1.2", | ||
"jquery": "2.1.4", | ||
"backbone": "1.2", | ||
"backbone.localStorage": "v1.1.16", | ||
"underscore": "1.8.2", | ||
"underscore": "1.8.3", | ||
"d3": "3.5.5", | ||
"bootstrap": "v3.3.2", | ||
"bootstrap-datepicker": "1.3.1", | ||
"bootstrap": "3.3.4", | ||
"bootstrap-datepicker": "1.4.0", | ||
"select2": "3.5.2" | ||
}, | ||
"resolutions": { | ||
"bootstrap": "3.3.2", | ||
"backbone": "1.1.2" | ||
} | ||
} |
@@ -1,2 +0,2 @@ | ||
/* evolutility v0.5 sample UI-models and data: todo, addressbook, wine cellar. */ | ||
/* evolutility v1.0 sample UI-models and data: todo, addressbook, wine cellar. */ | ||
var uiModels=uiModels||{};uiModels.todo_data=[{id:"1",title:"Release Evolutility v1",priority:"3",category:"others",complete:!1,description:"10 generic views + a ui-modeling language.",notes:""},{id:"2",title:"Fix open bugs",duedate:"2014-07-25",priority:"3",category:"work",complete:!1,description:"bla bla"},{id:"3",title:"Testing App",duedate:"2014-06-11",priority:"3",category:"work",complete:!1,description:"test"},{id:"4",title:"Prepare demo",duedate:"2014-05-12",priority:"1",category:"work",complete:!1,description:"Check this out"},{id:"5",title:"Test latest code",priority:"5",category:"misc",complete:!0,description:"notes for my test todo task."},{id:"6",title:"Car wash",priority:"4",category:"work",complete:!1},{id:"7",title:"Watch Inception",duedate:"2014-01-10",priority:"5",category:"fun",complete:!0},{id:"8",title:"Test TODO",duedate:"2015-01-01",priority:"1",category:"work",complete:!0,description:"Test TODO "},{id:"9",title:"Car wash",priority:"4",category:"work",complete:!1},{id:"10",title:"French translation",priority:"4",category:"work"},{id:"11",title:"Italian translation",priority:"4",category:"work"},{id:"12",title:"Chinese translation",priority:"4",category:"work"},{id:"13",title:"Japanese translation",priority:"4",category:"work"},{id:"14",title:"German translation",priority:"4",category:"work"},{id:"15",title:"Russian translation",priority:"4",category:"work"},{id:"16",title:"Polish translation",priority:"4",category:"work"},{id:"17",title:"Klingon translation",priority:"4",category:"work"},{id:"18",title:"Code optimization",duedate:"2015-01-01",priority:"4",category:"work",complete:!1},{id:"19",title:"Setup demo server",priority:"2",category:"work",complete:!1},{id:"20",title:"Add sample data",duedate:"2014-04-23",priority:"3",category:"work",complete:!0},{id:"21",title:"Make proposal",priority:"2",category:"misc",complete:!1},{id:"22",title:"Checkout cool restaurant",priority:"3",category:"home",complete:!1},{id:"23",title:"Kill the vampires",priority:"3",category:"others"}];var uiModels=uiModels||{};uiModels.contact_data=[{id:"1",lastname:"Smallwood",firstname:"Diane",jobtitle:"Director",company:"EasyDoesIt",email:"vsw@EasyDoesIt.com",phone:"415 234 4323",phonehome:"415 378 3577",phonecell:"415 135 3454",web:"http://EasyDoesIt.com",address1:"12, Liverpool Street",city:"San Francisco",state:"CA",zip:"94123",country:"US",category:"4"},{id:"2",lastname:"Shackleford ",firstname:"Rusty ",email:"rustyshackleford@gmail.com",address1:"123 Main Street",city:"Dallas",state:"TX",country:"US",category:"3"},{id:"3",lastname:"Inoue",firstname:"Akemi",jobtitle:"QA Engineer",company:"Testing evol-utility",email:"test@test.com",phone:"423 233 3523",phonehome:"423 523 4523",address1:"5665 Poplar Street",city:"San Jose",state:"CA",zip:"93112",country:"US",category:"3"},{id:"4",lastname:"Reina Moyano",firstname:"Sergio",jobtitle:"Mr",company:"Innova Creaciones",email:"sreina@innovacreaciones.es",phone:"411 444 2222",phonehome:"411 576 4566",phonecell:"411 579 4566",fax:"411 444 2224",address1:"654 Union Street",address2:"#203",city:"San Francisco",state:"CA",zip:"94567",country:"US",category:"3"},{id:"5",lastname:"Paulus",firstname:"Henry",company:"TEST the TEST",phone:"652 491 2345",address1:"1234 That Street",city:"San Mateo",state:"CA",zip:"94401",country:"US",category:"2"},{id:"6",lastname:"Dupond",firstname:"Patrick",jobtitle:"Sales Manager",company:"Au Bon Pain",email:"pdupond@aubonpain.fr",phone:"45 456 414 45",url:"http://aubonpain.fr",city:"Paris",state:"",country:"FR",category:"1"},{id:"7",lastname:"Giulieri",firstname:"Olivier",company:"Evolutility",city:"San Mateo",state:"",email:"olivier@evolutility.org",url:"http://www.evol-utility.org"},{id:"8",lastname:"Martin",firstname:"Mary",jobtitle:"President",company:"Acme Corp",email:"pm@acme.com",phone:"444 580 7007",phonehome:"449 512 0230",phonecell:"589 499 2065",address1:"123 Redville Lane",city:"Musnonville",state:"NH",zip:"03434",category:"1"},{id:"9",lastname:"Munar",firstname:"Roman",jobtitle:"Mr",company:"Informatics",email:"romano@informatics.com",phone:"322 234 5143",phonehome:"322 784 3453",phonecell:"322 538 2568",fax:"322 234 5345",url:"http://roman.munar.com",address1:"Washington",address2:"Buendia",city:"Makati",state:"",zip:"1300",country:"PH",category:"3"},{id:"10",lastname:"Smith",firstname:"George",company:"Blabla",email:"george@blabla.com",web:"http://www.blabla.com",phone:"415 123 1234",phonecell:"415 789 4556",address1:"768 5th Ave",city:"San Francisco",state:"CA",zip:"93123",country:"US",category:"1"},{id:"11",lastname:"Kumar",firstname:"Madhukar",jobtitle:"CEO",company:"CoolWeb",email:"mkumar@coolweb.com",web:"http://www.coolweb.com",phone:"7225 8252",phonecell:"7325 8245",address1:"434 Cool Place",city:"Bengaluru",state:"",country:"IN",category:"4"},{id:"12",lastname:"Cheng",firstname:"Chris",jobtitle:"CTO",company:"MyGreatCorporation",email:"ccheng@MyGreatCorporation.com",phonecell:"650 234 8245",city:"Sunnyvalle",state:"CA",country:"US",category:"4"}];var uiModels=uiModels||{};uiModels.winecellar_data=[{name:"Macrostie",label_img:"wine/macrostie.gif",vintage:2008,winery:"Mc Williams",bsize:"750",type:"red",price:20,grape:"chard",country:"US",region:"Sonoma",buying_date:"2008-05-12",value:24,purchased:24,remaining:16,drink_from:2009,drink_to:2020,peak_from:2014,peak_to:2017,degustations:[{ddate:"2008-05-08",robe:"light",nose:"fruity",taste:"fruity",notes:"too young"},{ddate:"2011-03-10",robe:"light",nose:"light fruit",taste:"",notes:""},{ddate:"2012-12-12",robe:"light",nose:"light fruit",taste:"",notes:"Great"}]},{name:"Château d'Yquem",label_img:"wine/yquem.gif",vintage:2012,winery:"Lur Saluces",bsize:"750",type:"white",grape:"sem",buying_date:"2012-12-12",price:399,value:460,drink_from:2012,drink_to:2017,purchased:3,remaining:1,country:"FR",region:"Bordeaux",area:"Sauternes and Barsac",score_parker:92,score_winespectator:94,degustations:[{ddate:"2013-04-23",robe:"golden",nose:"fruity",taste:"incredible"},{ddate:"2013-05-12",robe:"clear",nose:"strong and sweet",taste:"outstanding"}]},{name:"Château St Jean",label_img:"wine/stjean.gif",vintage:2008,winery:"Ch St Jean",bsize:"750",type:"red",price:34,value:32,purchased:12,remaining:5,drink_from:2009,grape:"shiraz",country:"FR",score_parker:68,score_winespectator:72,degustations:[{ddate:"2013-24-12",robe:"thick",nose:"strong",taste:"good",notes:"Great w/ beef."}]},{name:"Vine Cliff",label_img:"wine/vinecliff.gif",vintage:2013,winery:"Vine Cliff",bsize:"750",type:"red",buying_date:"2013-05-05",price:28,drink_from:2014,grape:"merlo",country:"US",score_parker:67,score_winespectator:62,degustations:[{ddate:"2013-05-05",robe:"light",nose:"strong",taste:"good"},{ddate:"2013-08-05",robe:"light",nose:"strong",taste:"good"},{ddate:"2013-08-18",robe:"light",nose:"strong",taste:"ok"}]},{name:"Château Montelena",label_img:"wine/montelena.gif",vintage:2005,winery:"Château Montelena",bsize:"1500",grape:"merlo",type:"red",drink_from:2005,region:"California",price:62,value:32,purchased:12,remaining:8,country:"US",score_parker:64,score_winespectator:64,degustations:[{ddate:"2012-05-05",nose:"strong+",taste:"excellent"},{ddate:"2013-10-22",robe:"rich",nose:"strong",taste:"very good"}]}];var uiModels=uiModels||{};uiModels.comics_data=[{title:"Do Androids Dream Of Electric Sheep?",genre:"sf",authors:"Philip K Dick, Tony Parker",complete:!0,finished:!0,have:"1-6",haveNb:6,serieNb:6,language:"EN",notes:"",pix:"comics/androitsheep1.jpeg"},{title:"Saga",genre:"sf",authors:"Brian K. Vaughan and Fiona Staples",complete:!1,finished:!1,have:"1-3",haveNb:3,serieNb:4,language:"EN",notes:"",pix:"comics/saga1.jpeg"},{title:"Alim le Tanneur",genre:"hf",authors:"Wilfrid Lupano, Virginie Augustin",complete:!0,finished:!0,have:"1-4",haveNb:4,serieNb:4,language:"FR",notes:"",pix:"comics/alim1.jpg"},{title:"La Caste des Meta-Barons",genre:"sf",authors:"Alexandro Jodorowsky et Juan Gimenez",complete:!1,finished:!0,have:"1-5",haveNb:5,serieNb:8,language:"FR",notes:"",pix:"comics/metabaron1.jpeg"},{title:"Garulfo",genre:"humor",have:"1-6",haveNb:6,serieNb:6,lang:"FR",authors:"Alain Ayroles et Bruno Maïorana",complete:!0,finished:!0,notes:"",pix:"comics/garulfo1.jpeg"},{title:"Lanfeust de Troy",genre:"hf",authors:"Didier Tarquin, Christophe Arleston",complete:!0,finished:!0,have:"1-8",haveNb:8,serieNb:8,language:"FR",notes:"",pix:"comics/lanfeust1.jpeg"},{title:"Salammbo",genre:"fantasy",authors:"Philippe Druillet et Gustave Flaubert",complete:!0,finished:!0,have:"1-3",haveNb:3,serieNb:3,language:"FR",notes:"",pix:"comics/salammbo1.jpeg"},{title:"Blacksad",genre:"pol",authors:"Juan Díaz Canales et Juanjo Guarnido",complete:!0,finished:!1,have:"1-4",haveNb:4,serieNb:4,language:"FR",notes:"",pix:"comics/blacksad1.jpeg"},{title:"Carmen McCallum",genre:"sf",authors:"Fred Duval et Gess",complete:!1,finished:!1,have:"1-5",haveNb:5,serieNb:12,language:"FR",notes:"",pix:"comics/carmenmc1.jpeg"},{title:"Code McCallum",genre:"sf",authors:"Fred Duval et Didier Cassegrain",complete:!0,finished:!0,have:"5",haveNb:5,serieNb:5,language:"FR",notes:"",pix:"comics/codemc1.jpeg"},{title:"La Nef des Fous",genre:"nocat",authors:"Turf",complete:!0,finished:!0,have:"1-7",haveNb:7,serieNb:7,language:"FR",notes:"",pix:"comics/neffous1.jpeg"},{title:"La Quete de l'Oiseau du Temps",genre:"hf",authors:"Serge Le Tendre et Régis Loisel",complete:!0,finished:!0,have:"1-4",haveNb:4,serieNb:4,language:"FR",notes:"",pix:"comics/quete1.jpeg"},{title:"Le Lama Blanc",genre:"adv",authors:"Alejandro Jodorowsky et Georges Bess",complete:!0,finished:!0,have:"1-6",haveNb:6,serieNb:6,language:"FR",notes:"",pix:"comics/lama1.jpeg"},{title:"Le Surfer d'Argent",genre:"sh",authors:"Moebius, Stan Lee",complete:!0,finished:!0,have:"1",haveNb:1,serieNb:1,language:"FR",notes:"",pix:"comics/surfer.jpeg"},{title:"L'Incal",genre:"sf",authors:"Moebius et Alexandro Jodorowsky",complete:!0,finished:!0,have:"1-6",haveNb:6,serieNb:6,language:"FR",notes:"",pix:"comics/incal1.jpeg"},{title:"Ou le regard ne porte pas",genre:"",authors:"Pont et Abolin",complete:!0,finished:!0,have:"1,2",haveNb:2,serieNb:2,language:"FR",notes:"",pix:"comics/regard1.jpeg"},{title:"Péma Ling",genre:"hist",authors:"Georges Bess",complete:!0,finished:!0,have:"1-5",haveNb:5,serieNb:5,language:"FR",notes:"",pix:"comics/pemaling1.jpeg"},{title:"Sky Doll",genre:"fantasy",authors:"Alessandro Barbucci et Barbara Canepa",complete:!0,finished:!0,have:"1-3",haveNb:3,serieNb:3,language:"FR",notes:"",pix:"comics/skydoll1.jpeg"},{title:"Ronin",genre:"sf",authors:"Franck Miller",complete:!0,finished:!0,have:"1",haveNb:1,serieNb:1,language:"EN",notes:"",pix:"comics/ronin.jpeg"},{title:"Rising Stars",genre:"sh",authors:"Joe Michael Straczynski, Christian Zanier, Keu Cha et Ken Lashley",complete:!0,finished:!0,have:"1",haveNb:1,serieNb:1,language:"EN",notes:"",pix:"comics/risingstars.jpeg"},{title:"Le Fleau des Dieux",genre:"sf",authors:"Valérie Mangin et Aleksa Gajic",complete:!0,finished:!0,have:"1-6",haveNb:6,serieNb:6,language:"FR",notes:"",pix:"comics/fleaudieux1.jpeg"},{title:"The Shaolin Cowboy",genre:"fantasy",authors:"Geof Darrow and Lana and Andy Wachowski",complete:!0,finished:!0,have:"1",haveNb:1,serieNb:1,language:"EN",notes:"",pix:"comics/shaolin-cowboy.jpeg"},{title:"Tales of an Imperfect Future",genre:"sf",authors:"Alfonso Font",complete:!0,finished:!0,have:"1",haveNb:1,serieNb:1,language:"EN",notes:"",pix:"comics/imperfect-future.jpeg"},{title:"Ghost in the Shell",genre:"sf",authors:"Masamune Shirow",complete:!1,finished:!0,have:"1",haveNb:1,serieNb:2,language:"EN",notes:"",pix:"comics/ghost-in-the-shell.jpeg"}]; |
@@ -15,2 +15,5 @@ module.exports = function (grunt) { | ||
bannerDependencies: '/*\n <%= pkg.name %> v<%= pkg.version %> dependencies: \n' + | ||
' bootstrap 3.3.4, jquery 2.1.4, backbone 1.1.2, backbone.localStorage v1.1.7, underscore 1.8.3, d3 3.5.5, bootstrap-datepicker" 1.4.0, select2 3.5.2. */\n', | ||
// ************************************************************************************* | ||
@@ -20,4 +23,5 @@ // CONCAT | ||
concat: { | ||
vendors:{ | ||
dependencies:{ | ||
options: { | ||
banner: '<%= bannerDependencies %>', | ||
separator: ';\n' | ||
@@ -52,3 +56,3 @@ }, | ||
], | ||
dest: '<%= pkg.target %>/vendors.js' | ||
dest: '<%= pkg.target %>/dependencies.js' | ||
}, | ||
@@ -61,20 +65,20 @@ js:{ | ||
src: [ | ||
'js/ui.js', | ||
'js/ui-*.js', | ||
'js/dico/ui.js', | ||
'js/dico/ui-*.js', | ||
'js/i18n/EN.js', | ||
'js/dico.js', | ||
'js/d3-*.js', | ||
'js/dico/dico.js', | ||
'js/dico/d3-*.js', | ||
'js/many.js', | ||
'js/many-*.js', | ||
'js/one.js', | ||
'js/one-*.js', | ||
'!js/one-wizard.js', // NOT ! here | ||
'js/view-many/many.js', | ||
'js/view-many/many-*.js', | ||
'js/view-one/one.js', | ||
'js/view-one/one-*.js', | ||
'!js/view-one/one-wizard.js', // NOT ! here | ||
//'js/action.js', | ||
'js/action-*.js', | ||
//'js/view-action/action.js', | ||
'js/view-action/action-*.js', | ||
//'js/navbar.js', | ||
'js/toolbar.js', | ||
'js/app.js' | ||
'js/dico/toolbar.js', | ||
'js/dico/app.js' | ||
//'js/ui-models/dico/field.js', | ||
@@ -142,4 +146,7 @@ //'js/ui-models/dico/field-popup.js', | ||
'js/ui-models/apps/*.js', | ||
'js/ui-models/test/*.js' | ||
'js/ui-models/test/*.js', | ||
// --- testing stuff --- | ||
'!*-nogit.js' | ||
] | ||
@@ -176,5 +183,5 @@ }, | ||
}, | ||
vendors: { | ||
dependencies: { | ||
options: { | ||
banner: '/* <%= pkg.name %> v<%= pkg.version %> dependencies: \n jquery + backbone + underscore + backbone.localStorage + bootstrap-datepicker */', | ||
banner: '<%= bannerDependencies %>', | ||
mangle: true | ||
@@ -184,4 +191,4 @@ }, | ||
{ | ||
src: '<%= pkg.target %>/vendors.js', | ||
dest: '<%= pkg.target %>/vendors.min.js' | ||
src: '<%= pkg.target %>/dependencies.js', | ||
dest: '<%= pkg.target %>/dependencies.min.js' | ||
} | ||
@@ -211,3 +218,3 @@ ] | ||
files: { | ||
"dist/css/vendors.min.css": "less/vendors.less", | ||
"dist/css/dependencies.min.css": "less/dependencies.less", | ||
"dist/css/evolutility.min.css": "less/evol.less" | ||
@@ -241,5 +248,5 @@ } | ||
// Prod task(s). | ||
grunt.registerTask('prod', ['jshint', 'copy', 'dev', 'concat:demo', 'concat:vendors', 'less:prod', 'uglify']); | ||
grunt.registerTask('prod', ['jshint', 'copy', 'dev', 'concat:demo', 'concat:dependencies', 'less:prod', 'uglify']); | ||
}; | ||
@@ -67,3 +67,3 @@ // Evolutility Localization Library ENGLISH | ||
deleteX:'Delete {0}',// {0}=entity | ||
delete1:'Do you really want to delete the {0} "{1}"?', // {0}=entity {1}=leadfield value, | ||
delete1:'Do you really want to delete the {0} "{1}"?', // {0}=entity {1}=titlefield value, | ||
deleteN: 'Delete {0} {1}?', // delete 5 tasks | ||
@@ -73,3 +73,3 @@ deleted1:'{0} deleted.', // {0}=entity , | ||
notFound:'Item not found.', | ||
//this.setMessage(i18n.notFound, i18n.getLabel('notFoundMsg', this.uiModel.entity); | ||
//this.setMessage(i18n.notFound, i18n.getLabel('notFoundMsg', this.uiModel.name); | ||
notFoundMsg:'No {0} found.', | ||
@@ -108,3 +108,3 @@ notFoundMsgId:'No {0} found for ID="{1}".', | ||
validation:{ | ||
incomplete: 'Incomplete information', | ||
incomplete: 'Some information is missing or invalid.', | ||
invalid: 'Invalid format.', | ||
@@ -124,7 +124,7 @@ invalidList: '{0} values in "{1}" are invalid.', | ||
min:'"{0}" must be greater or equal to {1}.', | ||
maxlength:'"{0}" must be {1} characters long maximum.', | ||
minlength:'"{0}" must be at least {1} characters long.', | ||
minmaxlength:'"{0}" must be between {1} and {2} characters long.', | ||
regex:'"{0}" is not of the expected format.' | ||
//regex:'"{0}" must match the regular expression pattern for "{1}".' | ||
maxLength:'"{0}" must be {1} characters long maximum.', | ||
minLength:'"{0}" must be at least {1} characters long.', | ||
minMaxLength:'"{0}" must be between {1} and {2} characters long.', | ||
regExp:'"{0}" is not of the expected format.' | ||
//regExp:'"{0}" must match the regular expression pattern for "{1}".' | ||
}, | ||
@@ -143,4 +143,4 @@ | ||
export:{ | ||
ExportEntity: 'Export {0}', // {0}=entity | ||
ExportEntities: 'Export {0}', // {0}=entities | ||
ExportOne: 'Export {0}', // {0}=entity | ||
ExportMany: 'Export {0}', // {0}=entities | ||
preview:'Export preview', | ||
@@ -147,0 +147,0 @@ header: 'Header', |
@@ -6,7 +6,7 @@ var uiModels = uiModels || {}; | ||
label: 'Graphic Novels', | ||
entity: 'graphic novel serie', | ||
entities: 'graphic novel series', | ||
name: 'graphic novel serie', | ||
namePlural: 'graphic novel series', | ||
//icon: 'serie.gif', | ||
leadfield:'title', | ||
badge:function(m){ | ||
fnTitle: 'title', | ||
fnBadge: function(m){ | ||
var hNb=m.get('haveNb'), | ||
@@ -22,7 +22,7 @@ sNb=m.get('serieNb'); | ||
id: 'title', attribute: 'title', type: 'text', label: 'Title', required: true, | ||
maxlength: 255, | ||
width: 62, viewmany: true | ||
maxLength: 255, | ||
width: 62, inMany: true | ||
}, | ||
{ | ||
id: 'genre', attribute: 'genre', type: 'lov', label: 'Genre', width: 38, viewmany: true, | ||
id: 'genre', attribute: 'genre', type: 'lov', label: 'Genre', width: 38, inMany: true, | ||
list: [ | ||
@@ -45,7 +45,7 @@ {id: 'adv', text: 'Adventure'}, | ||
{ | ||
id: 'authors', attribute: 'authors', type: 'text', width: 62, viewmany: true, | ||
id: 'authors', attribute: 'authors', type: 'text', width: 62, inMany: true, | ||
label: 'Authors' | ||
}, | ||
{ | ||
id: 'language', attribute: 'language', type: 'lov', label: 'Language', width: 38, viewmany: false, | ||
id: 'language', attribute: 'language', type: 'lov', label: 'Language', width: 38, inMany: false, | ||
list: [ | ||
@@ -57,20 +57,20 @@ {id: 'FR', text: 'French'}, | ||
{ | ||
id: 'serieNb', attribute: 'serieNb', type: 'integer', width: 15, viewmany: false, | ||
label: 'Albums', viewcharts:false | ||
id: 'serieNb', attribute: 'serieNb', type: 'integer', width: 15, inMany: false, | ||
label: 'Albums', inCharts:false | ||
}, | ||
{ | ||
id: 'haveNb', attribute: 'haveNb', type: 'integer', width: 15, viewmany: false, | ||
label: 'Owned', viewcharts:false | ||
id: 'haveNb', attribute: 'haveNb', type: 'integer', width: 15, inMany: false, | ||
label: 'Owned', inCharts:false | ||
}, | ||
{ | ||
id: 'have', attribute: 'have', type: 'text', width: 32, viewmany: false, | ||
id: 'have', attribute: 'have', type: 'text', width: 32, inMany: false, | ||
label: 'have' | ||
}, | ||
{ | ||
id: 'complete', attribute: 'complete', type: 'boolean', width: 19, viewmany: true, | ||
label: 'Complete', labelfalse:'Incomplete', labeltrue:'Complete' | ||
id: 'complete', attribute: 'complete', type: 'boolean', width: 19, inMany: true, | ||
label: 'Complete', labelFalse:'Incomplete', labelTrue:'Complete' | ||
}, | ||
{ | ||
id: 'finished', attribute: 'finished', type: 'boolean', width: 19, viewmany: true, | ||
label: 'Finished', labeltrue:'Finished', labelfalse:'Unfinished' | ||
id: 'finished', attribute: 'finished', type: 'boolean', width: 19, inMany: true, | ||
label: 'Finished', labelTrue:'Finished', labelFalse:'Unfinished', css:'cBlue' | ||
}, | ||
@@ -88,4 +88,4 @@ { | ||
{ | ||
id: 'notes', attribute: 'notes', type: 'textmultiline', label: 'Notes', maxlength: 1000, | ||
width: 100, height: 6, viewmany: false | ||
id: 'notes', attribute: 'notes', type: 'textmultiline', label: 'Notes', maxLength: 1000, | ||
width: 100, height: 6, inMany: false | ||
} | ||
@@ -98,3 +98,3 @@ ] | ||
{ | ||
id: 'pix', attribute: 'pix', type: 'image', width: 100, viewmany: true, | ||
id: 'pix', attribute: 'pix', type: 'image', width: 100, inMany: true, | ||
label: 'Cover' | ||
@@ -101,0 +101,0 @@ } |
@@ -320,4 +320,4 @@ var contact_LOVs = { | ||
icon: 'contact.gif', | ||
entity: 'contact', entities: 'contacts', | ||
leadfield: function(model){ | ||
name: 'contact', namePlural: 'contacts', | ||
fnTitle: function(model){ | ||
return model.get('firstname')+' '+model.get('lastname'); | ||
@@ -330,23 +330,23 @@ }, | ||
{ | ||
type: 'text', id: 'lastname', label: 'Lastname', maxlength: 50, | ||
required: true, width: '62', viewmany: true | ||
type: 'text', id: 'lastname', label: 'Lastname', maxLength: 50, | ||
required: true, width: 62, inMany: true | ||
}, | ||
{ | ||
type: 'text', id: 'firstname', label: 'Firstname', maxlength: 50, | ||
required: true, width: 38, viewmany: true | ||
type: 'text', id: 'firstname', label: 'Firstname', maxLength: 50, | ||
required: true, width: 38, inMany: true | ||
}, | ||
{ | ||
type: 'text', id: 'jobtitle', label: 'Title', maxlength: 50, | ||
type: 'text', id: 'jobtitle', label: 'Title', maxLength: 50, | ||
width: 62 | ||
}, | ||
{ | ||
type: 'text', id: 'company', label: 'Company', maxlength: 50, | ||
width: 38, viewmany: true | ||
type: 'text', id: 'company', label: 'Company', maxLength: 50, | ||
width: 38, inMany: true | ||
}, | ||
{ | ||
type: 'email', id: 'email', label: 'email', maxlength: 255, | ||
width: 100, viewmany: true | ||
type: 'email', id: 'email', label: 'email', maxLength: 255, | ||
width: 100, inMany: true | ||
}, | ||
{ | ||
type: 'url', id: 'web', label: 'web', maxlength: 255, width: 100 | ||
type: 'url', id: 'web', label: 'web', maxLength: 255, width: 100 | ||
} | ||
@@ -359,12 +359,12 @@ ] | ||
{ | ||
type: 'text', id: 'phone', label: 'Work Phone', maxlength: 20, width: 100, mini:'1' | ||
type: 'text', id: 'phone', label: 'Work Phone', maxLength: 20, width: 100, mini:'1' | ||
}, | ||
{ | ||
type: 'text', id: 'phonehome', label: 'Home Phone', maxlength: 20, width: 100 | ||
type: 'text', id: 'phonehome', label: 'Home Phone', maxLength: 20, width: 100 | ||
}, | ||
{ | ||
type: 'text', id: 'phonecell', label: 'Cell.', maxlength: 20, width: 100, mini:'1' | ||
type: 'text', id: 'phonecell', label: 'Cell.', maxLength: 20, width: 100, mini:'1' | ||
}, | ||
{ | ||
type: 'text', id: 'fax', label: 'Fax', maxlength: 20, width: 100 | ||
type: 'text', id: 'fax', label: 'Fax', maxLength: 20, width: 100 | ||
} | ||
@@ -377,9 +377,9 @@ ] | ||
{ | ||
type: 'text', id: 'address1', label: 'Address', maxlength: 150, width: 100 | ||
type: 'text', id: 'address1', label: 'Address', maxLength: 150, width: 100 | ||
}, | ||
{ | ||
type: 'text', id: 'address2', label: '', labellist: 'Address 2', maxlength: 150, width: 100 | ||
type: 'text', id: 'address2', label: '', labellist: 'Address 2', maxLength: 150, width: 100 | ||
}, | ||
{ | ||
type: 'text', id: 'city', label: 'City', maxlength: 100, width: 62 | ||
type: 'text', id: 'city', label: 'City', maxLength: 100, width: 62 | ||
}, | ||
@@ -391,6 +391,6 @@ { | ||
{ | ||
type: 'text', id: 'zip', label: 'Zip', maxlength: 12, width: 15 | ||
type: 'text', id: 'zip', label: 'Zip', maxLength: 12, width: 15 | ||
}, | ||
{ | ||
type: 'lov', id: 'country', label: 'Country', maxlength: 60, width: 100, | ||
type: 'lov', id: 'country', label: 'Country', maxLength: 60, width: 100, | ||
list: contact_LOVs.countries | ||
@@ -405,15 +405,15 @@ } | ||
type: 'lov', id: 'category', label: 'Category', width: 100, | ||
viewmany: true, | ||
inMany: true, | ||
list: contact_LOVs.categories | ||
}, | ||
{ | ||
type: 'text', id: 'custom1', label: 'Custom 1', maxlength: 250, | ||
type: 'text', id: 'custom1', label: 'Custom 1', maxLength: 250, | ||
width: 100 | ||
}, | ||
{ | ||
type: 'text', id: 'custom2', label: 'Custom 2', maxlength: 250, | ||
type: 'text', id: 'custom2', label: 'Custom 2', maxLength: 250, | ||
width: 100 | ||
}, | ||
{ | ||
type: 'text', id: 'custom3', label: 'Custom 3', maxlength: 250, | ||
type: 'text', id: 'custom3', label: 'Custom 3', maxLength: 250, | ||
width: 100 | ||
@@ -420,0 +420,0 @@ } |
@@ -0,1 +1,3 @@ | ||
// Evolutility ui-model for a test object | ||
// because this ui-model is very repetitive, it is not a JSON but uses functions for repeted patterns ... | ||
@@ -15,23 +17,38 @@ var testLOV = [ | ||
var testLOV2 = [ | ||
{id:'red',text:'Red', icon:'wine/winered.gif'}, | ||
{id:'white',text:'White', icon:'wine/winewhite.gif'}, | ||
{id:'sweet',text:'Sweet', icon:'wine/winesweet.gif'}, | ||
{id:'spark',text:'Sparkling', icon:'wine/winespark.gif'}, | ||
{id:'rose',text:'Rose', icon:'wine/winerose.gif'} | ||
]; | ||
var fieldsPanelList = [ | ||
{id: 'pl1f1', type: 'text', label: 'Name', required:true, maxlength: 50, viewmany: true}, | ||
{id: 'pl1f2', type: 'text', label: 'Text', required:true, maxlength: 100, viewmany: true}, | ||
{id: 'pl1f3', type: 'lov', label: 'Sizes', required:true, list: testLOV, viewmany: true} | ||
{id: 'pl1f1', type: 'text', label: 'Name', required:true, maxLength: 50}, | ||
{id: 'pl1f2', type: 'text', label: 'Text', required:true, maxLength: 100}, | ||
{id: 'pl1f3', type: 'lov', label: 'Sizes', required:true, list: testLOV} | ||
], | ||
fieldsPanelList2 = [ | ||
{id: 'pl2f1', type: 'text', label: 'Name', maxlength: 50, viewmany: true}, | ||
{id: 'pl2f3', type: 'date', label: 'Date', viewmany: true}, | ||
{id: 'pl2f4', type: 'boolean', label: 'Bool', viewmany: true}, | ||
{id: 'pl2f2', type: 'text', label: 'Text', maxlength: 100, viewmany: true} | ||
{id: 'pl2f1', type: 'text', label: 'Name', maxLength: 50}, | ||
{id: 'pl2f3', type: 'date', label: 'Date', inMany: true}, | ||
{id: 'pl2f4', type: 'boolean', label: 'Bool'}, | ||
{id: 'pl2f2', type: 'text', label: 'Text', maxLength: 100} | ||
], | ||
fieldsPanelList3 = [ | ||
{id: 'pl3f1', type: 'text', label: 'Name', maxLength: 50}, | ||
{id: 'pl3f2', type: 'integer', label: 'Integer'}, | ||
{id: 'pl3f3', type: 'money', label: 'Money'}, | ||
{id: 'pl3f4', type: 'lov', label: 'Sizes', list: testLOV} | ||
]; | ||
function fieldTypePanel(id, label, labelPanel, css){ | ||
function fieldTypePanel(id, label, labelPanel, label2Panel, css){ | ||
var labelP = labelPanel || label || id, | ||
label2P = label2Panel, | ||
fields=[ | ||
{ | ||
id: id, | ||
id: id+'1', | ||
type: id, | ||
label: label, | ||
label: label+' 1', | ||
required: true, | ||
viewmany: true, | ||
inMany: true, | ||
width: 100 | ||
@@ -43,3 +60,6 @@ }, | ||
readonly: true, | ||
help: 'The field "' + label+' 2" is readonly.', | ||
groupable: false, | ||
colorable: false, | ||
sizable: false, | ||
help: 'The field "' + label+' 2" is the read-only version of "' + label+'". It\'s value is updated on save.', | ||
type: id, | ||
@@ -68,2 +88,3 @@ label: label+' 2', | ||
label: labelP, | ||
label2: label2P, | ||
width: 33, | ||
@@ -79,6 +100,6 @@ elements: fields, | ||
id: 'test', | ||
entity: 'test', | ||
entities: 'tests', | ||
name: 'test', | ||
namePlural: 'tests', | ||
title: 'Test Object', | ||
leadfield:'name', | ||
fnTitle:'name', | ||
icon:'color_wheel.png', | ||
@@ -90,2 +111,3 @@ elements: [ | ||
label: 'Test object', | ||
label2: 'with fields of all types.', | ||
width: 100, | ||
@@ -98,4 +120,4 @@ elements: [ | ||
required: true, | ||
maxlength: '150', | ||
viewmany: true, | ||
maxLength: '150', | ||
inMany: true, | ||
width: 100 | ||
@@ -107,9 +129,7 @@ } | ||
type: 'tab', | ||
label: 'Text & Lists', | ||
label: 'Text', | ||
elements: [ | ||
fieldTypePanel('text', 'Text', 'Text', 'panel-success'), | ||
fieldTypePanel('lov', 'List', 'List (value)', 'panel-warning'), | ||
fieldTypePanel('list', 'List mv', 'List (multiple values)', 'panel-warning'), | ||
fieldTypePanel('textmultiline', 'Large Text', '', 'panel-success'), | ||
fieldTypePanel('html', 'HTML') | ||
fieldTypePanel('text', 'Text', 'Text', '', 'panel-success'), | ||
fieldTypePanel('textmultiline', 'Large Text', '', 'multilines', 'panel-success'), | ||
fieldTypePanel('html', 'HTML', 'HTML', 'not fully implemented yet', 'panel-danger') | ||
] | ||
@@ -119,7 +139,47 @@ }, | ||
type: 'tab', | ||
label: 'Lists', | ||
elements: [ | ||
fieldTypePanel('lov', 'List', 'List', 'single value'), | ||
fieldTypePanel('list', 'List mv', 'List', 'multiple values'), | ||
{ | ||
type: 'panel', | ||
label: 'List', | ||
label2: 'with icons', | ||
width: 33, | ||
elements: [ | ||
{ | ||
id: 'lovicon1', | ||
type: 'lov', | ||
label: 'List', | ||
list:testLOV2, | ||
required: true, | ||
inMany: true, | ||
width: 100 | ||
}, | ||
{ | ||
id: 'lovicon2', | ||
type: 'lov', | ||
label: 'List 2', | ||
readonly: true, | ||
list:testLOV2, | ||
width: 100 | ||
}, | ||
{ | ||
id: 'lovicon3', | ||
type: 'lov', | ||
label: 'List 3', | ||
list: testLOV2, | ||
width: 100 | ||
} | ||
] | ||
} | ||
]//id==='html'?'not fully implemented yet':'' | ||
}, | ||
{ | ||
type: 'tab', | ||
label: 'Date & Time', | ||
elements: [ | ||
fieldTypePanel('date', 'Date', '', 'panel-default'), | ||
fieldTypePanel('time', 'Time', '', 'panel-info'), | ||
fieldTypePanel('datetime', 'Date and Time', '', 'panel-primary') | ||
fieldTypePanel('date', 'Date', '', '', 'panel-default'), | ||
fieldTypePanel('time', 'Time', '', '', 'panel-info'), | ||
fieldTypePanel('datetime', 'Date and Time', '', '', 'panel-primary') | ||
] | ||
@@ -133,3 +193,3 @@ }, | ||
fieldTypePanel('decimal', 'Decimal'), | ||
fieldTypePanel('money', 'Money', 'Money', 'panel-success') | ||
fieldTypePanel('money', 'Money', 'Money', '', 'panel-success') | ||
] | ||
@@ -141,3 +201,3 @@ }, | ||
elements: [ | ||
fieldTypePanel('boolean', 'Boolean'), | ||
fieldTypePanel('boolean', 'Boolean', 'Boolean', 'checkboxes'), | ||
fieldTypePanel('email', 'email'), | ||
@@ -153,3 +213,3 @@ fieldTypePanel('url', 'url') | ||
fieldTypePanel('color', 'Color'), | ||
fieldTypePanel('hidden', 'Hidden') | ||
fieldTypePanel('hidden', 'Hidden', '', 'but in the DOM', 'panel-default') | ||
] | ||
@@ -159,2 +219,90 @@ }, | ||
type: 'tab', | ||
label: 'Formula', | ||
elements: [ | ||
{ | ||
type: 'panel', label: 'Formula fields', width: 62, | ||
label2: 'Values are updated on save.', | ||
elements: [ | ||
{ | ||
id: 'ff1', attribute: 'ff1', type: 'formula', | ||
label: 'Formula Title', | ||
formula: function(m){ | ||
return 'The record name is "'+m.escape('name')+'".'; | ||
}, | ||
width: 100, inMany: true | ||
}, | ||
{ | ||
id: 'fftt', attribute: 'fftt', type: 'formula', | ||
label: 'Formula 2 Titles', | ||
formula: function(m){ | ||
return m.escape('name')+' '+m.escape('text'); | ||
}, | ||
width: 100, inMany: true | ||
}, | ||
{ | ||
id: 'fflink', attribute: 'fflink', type: 'formula', | ||
label: 'Google search for name', | ||
formula: function(m){ | ||
return '<a href="http://www.google.com/search?q='+ encodeURI(m.get('name')) + '" target="google">'+ m.escape('name') + ' on Google</a>'; | ||
}, | ||
width: 100, inMany: true | ||
} | ||
] | ||
}, | ||
{ | ||
type: 'panel', label: 'Items counts', width: 38, | ||
elements: [ | ||
{ | ||
id: 'ffc1', attribute: 'ffc1', type: 'formula', | ||
label: 'Number of items in Collection 1', | ||
labelmany: '# Coll.1', | ||
formula: function(m){ | ||
return (m.get('subCollec1')||[]).length; | ||
}, | ||
width: 100, inMany: true | ||
}, | ||
{ | ||
id: 'ffc2', attribute: 'ffc2', type: 'formula', | ||
label: 'Number of items in Collection 2', | ||
labelmany: '# Coll.2', | ||
formula: function(m){ | ||
return (m.get('subCollec2')||[]).length; | ||
}, | ||
width: 100, inMany: true | ||
}, | ||
{ | ||
id: 'ffc3', attribute: 'ffc3', type: 'formula', | ||
label: 'Number of items in Collection 3', | ||
labelmany: '# Coll.3', | ||
formula: function(m){ | ||
return (m.get('subCollec3')||[]).length; | ||
}, | ||
width: 100, inMany: true | ||
} | ||
] | ||
}, | ||
{ | ||
type: 'panel', label: 'Forest of Items', width: 100, | ||
label2: 'One tree for each item in the collections.', | ||
elements: [ | ||
{ | ||
id: 'ffforest', attribute: 'ffforest', type: 'formula', | ||
label: 'Trees', | ||
formula: function(m){ | ||
return _.map(m.get('subCollec1'), function(c){ | ||
return '<span class="glyphicon glyphicon-tree-conifer" aria-hidden="true"></span>'; | ||
}).join('')+_.map(m.get('subCollec2'), function(c){ | ||
return '<span class="glyphicon glyphicon-tree-deciduous" aria-hidden="true"></span>'; | ||
}).join('')+_.map(m.get('subCollec3'), function(c){ | ||
return '<span class="glyphicon glyphicon-apple" aria-hidden="true"></span>'; | ||
}).join(''); | ||
}, | ||
width: 100, inMany: true | ||
} | ||
] | ||
} | ||
] | ||
}, | ||
{ | ||
type: 'tab', | ||
label: 'Collections', | ||
@@ -164,3 +312,3 @@ elements: [ | ||
type: 'panel-list', | ||
css: 'panel-warning', | ||
css: 'panel-info', | ||
id:'subCollec1', | ||
@@ -174,3 +322,3 @@ attribute:'subCollec1', | ||
type: 'panel-list', | ||
css:'panel-danger', | ||
css:'panel-info', | ||
id:'subCollec2', | ||
@@ -181,2 +329,11 @@ attribute:'subCollec2', | ||
elements: fieldsPanelList2 | ||
}, | ||
{ | ||
type: 'panel-list', | ||
css: 'panel-primary', | ||
id:'subCollec3', | ||
attribute:'subCollec3', | ||
label: 'Collection 3', | ||
width: 100, | ||
elements: fieldsPanelList3 | ||
} | ||
@@ -183,0 +340,0 @@ ] |
@@ -6,6 +6,6 @@ var uiModels = uiModels || {}; | ||
label: 'To Do', | ||
entity: 'task', | ||
entities: 'tasks', | ||
name: 'task', | ||
namePlural: 'tasks', | ||
icon: 'todo.gif', | ||
leadfield:'title', | ||
fnTitle:'title', | ||
elements: [ | ||
@@ -18,10 +18,10 @@ { | ||
//placeholder: 'Call John', | ||
maxlength: 255, | ||
width: 100, viewmany: true | ||
maxLength: 255, | ||
width: 100, inMany: true | ||
}, | ||
{ | ||
id: 'duedate', attribute: 'duedate', type: 'date', label: 'Due Date', width: 62, viewmany: true | ||
id: 'duedate', attribute: 'duedate', type: 'date', label: 'Due Date', width: 62, inMany: true | ||
}, | ||
{ | ||
id: 'category', attribute: 'category', type: 'lov', label: 'Category', width: 38, viewmany: true, | ||
id: 'category', attribute: 'category', type: 'lov', label: 'Category', width: 38, inMany: true, | ||
list: [ | ||
@@ -34,3 +34,3 @@ {id: 'home', text: 'Home'}, | ||
], | ||
typechart:'bars' | ||
typeChart:'bars' | ||
} | ||
@@ -44,3 +44,3 @@ ] | ||
id: 'priority', attribute: 'priority', type: 'lov', label: 'Priority', required: true, | ||
width: 100, viewmany: true, | ||
width: 100, inMany: true, | ||
list: [ | ||
@@ -55,6 +55,6 @@ {id: '1', text: '1 - ASAP'}, | ||
{ | ||
id: 'complete', attribute: 'complete', type: 'boolean', width: 100, viewmany: true, | ||
id: 'complete', attribute: 'complete', type: 'boolean', width: 100, inMany: true, | ||
label: 'Complete', | ||
labelcharts:'Tasks completion', labeltrue: 'Complete', labelfalse:'Incomplete', | ||
typechart:'pie' | ||
labelCharts:'Tasks completion', labelTrue: 'Complete', labelFalse:'Incomplete', | ||
typeChart:'pie' | ||
} | ||
@@ -69,8 +69,8 @@ ] | ||
label: 'Description', | ||
maxlength: 1000, | ||
width: 62, height: 5, viewmany: false | ||
maxLength: 1000, | ||
width: 62, height: 5, inMany: false | ||
}, | ||
{ | ||
id: 'notes', attribute: 'notes', type: 'textmultiline', label: 'Notes', maxlength: 1000, | ||
width: 38, height: 5, viewmany: false | ||
id: 'notes', attribute: 'notes', type: 'textmultiline', label: 'Notes', maxLength: 1000, | ||
width: 38, height: 5, inMany: false | ||
} | ||
@@ -77,0 +77,0 @@ ] |
@@ -139,10 +139,10 @@ var winecellar_lovs = { | ||
id: 'winecellar', | ||
entity: 'wine', | ||
entities: 'wines', | ||
name: 'wine', | ||
namePlural: 'wines', | ||
label: 'Wine Cellar', | ||
icon: 'wine.gif', | ||
leadfield: function(model){ | ||
fnTitle: function(model){ | ||
return model.get('name')+' '+model.get('vintage'); | ||
}, | ||
badge:function(model){ | ||
fnBadge: function(model){ | ||
return model.get('remaining') || 0; | ||
@@ -161,4 +161,4 @@ }, | ||
required: true, | ||
maxlength: 150, | ||
viewmany: true, | ||
maxLength: 150, | ||
inMany: true, | ||
width: 62, | ||
@@ -172,4 +172,4 @@ help: 'Name of the wine as indicated on the label.' | ||
required: true, | ||
maxlength: 4, | ||
viewmany: true, | ||
maxLength: 4, | ||
inMany: true, | ||
width: 38, | ||
@@ -195,5 +195,5 @@ min: 1900, | ||
label: 'Winery', | ||
maxlength: 100, | ||
maxLength: 100, | ||
required: true, | ||
viewmany: true, | ||
inMany: true, | ||
width: '62', | ||
@@ -214,3 +214,3 @@ help: 'The establishment where this wine is made.' | ||
label: 'Grape', | ||
viewmany: false, | ||
inMany: false, | ||
width: 62, | ||
@@ -223,3 +223,3 @@ list: winecellar_lovs.grape | ||
label: 'Type', | ||
viewmany: true, | ||
inMany: true, | ||
width: 38, | ||
@@ -246,3 +246,3 @@ list: winecellar_lovs.type | ||
label: 'Region', | ||
maxlength: 100, | ||
maxLength: 100, | ||
width: 30 | ||
@@ -254,3 +254,3 @@ }, | ||
label: 'Area', | ||
maxlength: 100, | ||
maxLength: 100, | ||
width: 38 | ||
@@ -270,5 +270,5 @@ } | ||
label: 'Label', | ||
maxlength: 200, | ||
maxLength: 200, | ||
width: 100, | ||
viewmany: true | ||
inMany: true | ||
} | ||
@@ -298,3 +298,3 @@ ] | ||
label: 'Price', | ||
viewmany: true, | ||
inMany: true, | ||
width: 30 | ||
@@ -313,3 +313,3 @@ }, | ||
labellist: 'Purchased', | ||
maxlength: 10, | ||
maxLength: 10, | ||
width: 40 | ||
@@ -322,5 +322,5 @@ }, | ||
labeledit: 'Bottles Remaining', | ||
maxlength: 10, | ||
maxLength: 10, | ||
width: 60, | ||
viewcharts:false | ||
inCharts:false | ||
}, | ||
@@ -331,3 +331,3 @@ { | ||
label: 'Notes', | ||
maxlength: 150, | ||
maxLength: 150, | ||
width: 100, | ||
@@ -356,5 +356,5 @@ height: 2 | ||
labellist: 'Drink', | ||
labelcharts: 'Wines by Start drinking period', | ||
labelCharts: 'Wines by Start drinking period', | ||
placeholder: '2012', | ||
maxlength: 10, | ||
maxLength: 10, | ||
width: 50, | ||
@@ -368,4 +368,4 @@ min: 1900, | ||
label: 'to', | ||
labelcharts: 'Wines by End drinking period', | ||
maxlength: 4, | ||
labelCharts: 'Wines by End drinking period', | ||
maxLength: 4, | ||
width: 50, | ||
@@ -379,4 +379,4 @@ min: 1900, | ||
label: 'Peak from', | ||
labelcharts: 'Wines by Start peak period', | ||
maxlength: 4, | ||
labelCharts: 'Wines by Start peak period', | ||
maxLength: 4, | ||
width: 50, | ||
@@ -390,4 +390,4 @@ min: 1900, | ||
label: 'to', | ||
labelcharts: 'Wines by End peak period', | ||
maxlength: 4, | ||
labelCharts: 'Wines by End peak period', | ||
maxLength: 4, | ||
width: 50, | ||
@@ -401,3 +401,3 @@ min: 1900, | ||
label: 'Meal', | ||
maxlength: 200, | ||
maxLength: 200, | ||
width: 100, | ||
@@ -420,3 +420,3 @@ height: 2 | ||
list: winecellar_lovs.score, | ||
maxlength: 100, | ||
maxLength: 100, | ||
width: 100 | ||
@@ -428,6 +428,6 @@ }, | ||
label: 'Parker', | ||
labelcharts: 'Parker scores', | ||
labelCharts: 'Parker scores', | ||
min: 50, | ||
max: 100, | ||
maxlength: 3, | ||
maxLength: 3, | ||
width: 100 | ||
@@ -439,6 +439,6 @@ }, | ||
label: 'Wine Spectator', | ||
labelcharts: 'Wine Spectator scores', | ||
labelCharts: 'Wine Spectator scores', | ||
min: 0, | ||
max: 100, | ||
maxlength: 3, | ||
maxLength: 3, | ||
width: 100 | ||
@@ -462,8 +462,8 @@ } | ||
elements: [ | ||
{id: 'ddate', type: 'date', label: 'Date', maxlength: 20, viewmany: true, | ||
{id: 'ddate', type: 'date', label: 'Date', maxLength: 20, inMany: true, | ||
required:true}, | ||
{id: 'robe', type: 'text', label: 'Robe', maxlength: 100, viewmany: true}, | ||
{id: 'nose', type: 'text', label: 'Nose', maxlength: 100, viewmany: true}, | ||
{id: 'taste', type: 'text', label: 'Taste', maxlength: 100, viewmany: true}, | ||
{id: 'notes', type: 'textmultiline', label: 'Note', maxlength: 300, viewmany: true, width: 100, height: 2} | ||
{id: 'robe', type: 'text', label: 'Robe', maxLength: 100, inMany: true}, | ||
{id: 'nose', type: 'text', label: 'Nose', maxLength: 100, inMany: true}, | ||
{id: 'taste', type: 'text', label: 'Taste', maxLength: 100, inMany: true}, | ||
{id: 'notes', type: 'textmultiline', label: 'Note', maxLength: 300, inMany: true, width: 100, height: 2} | ||
] | ||
@@ -486,3 +486,3 @@ } | ||
label: 'Comments', | ||
maxlength: 500, | ||
maxLength: 500, | ||
width: 100, | ||
@@ -489,0 +489,0 @@ height: 8 |
@@ -29,6 +29,7 @@ // TODO cleanup | ||
id: 'entity', | ||
label: 'Object', | ||
icon: "cube.gif", | ||
entity: "object", | ||
entities: "objects", | ||
leadfield: "Title", | ||
name: "object", | ||
namePlural: "objects", | ||
fnTitle: "title", | ||
elements: [ | ||
@@ -45,6 +46,6 @@ { | ||
type: "text", | ||
id: "Title", | ||
attribute: "Title", | ||
maxlength: 100, | ||
viewmany: true, | ||
id: "title", | ||
attribute: "title", | ||
maxLength: 100, | ||
inMany: true, | ||
width: 52, | ||
@@ -58,4 +59,4 @@ required: true | ||
attribute: "id", | ||
maxlength: 20, | ||
viewmany: true, | ||
maxLength: 20, | ||
inMany: true, | ||
width: 18 | ||
@@ -68,3 +69,3 @@ }, | ||
attribute: "PUBLISH", | ||
viewmany: true, | ||
inMany: true, | ||
width: 20 | ||
@@ -88,7 +89,7 @@ } | ||
type: "text", | ||
id: "entity", | ||
attribute: "entity", | ||
id: "name", | ||
attribute: "name", | ||
required: true, | ||
maxlength: 50, | ||
viewmany: true, | ||
maxLength: 50, | ||
inMany: true, | ||
width: 62 | ||
@@ -100,6 +101,6 @@ }, | ||
type: "text", | ||
id: "entities", | ||
attribute: "entities", | ||
id: "namePlural", | ||
attribute: "namePlural", | ||
required: true, | ||
maxlength: 50, | ||
maxLength: 50, | ||
width: 38 | ||
@@ -112,3 +113,3 @@ }, | ||
attribute: "icon", | ||
maxlength: "50", | ||
maxLength: "50", | ||
width: 62, | ||
@@ -130,3 +131,3 @@ help: "example='contact.gif'" | ||
attribute: "description", | ||
maxlength: 250, | ||
maxLength: 250, | ||
width: 100, | ||
@@ -156,4 +157,4 @@ height: 4 | ||
attribute: "attribute", | ||
maxlength: 100, | ||
viewmany:true, | ||
maxLength: 100, | ||
inMany:true, | ||
//"link": "EvoDicoField.aspx?ID=@itemid", | ||
@@ -167,4 +168,4 @@ required: true | ||
attribute: "label", | ||
maxlength: 100, | ||
viewmany:true, | ||
maxLength: 100, | ||
inMany:true, | ||
required: true | ||
@@ -185,4 +186,4 @@ }, | ||
type: "boolean", | ||
id: "viewmany", | ||
attribute: "viewmany", | ||
id: "inMany", | ||
attribute: "inMany", | ||
width: 50, | ||
@@ -202,5 +203,5 @@ "img": "checkg.gif" | ||
type: "integer", | ||
id: "maxlength", | ||
attribute: "maxlength", | ||
maxlength: 3, | ||
id: "maxLength", | ||
attribute: "maxLength", | ||
maxLength: 3, | ||
width: 38 | ||
@@ -215,3 +216,3 @@ }, | ||
attribute: "width", | ||
maxlength: 3, | ||
maxLength: 3, | ||
width: 62 | ||
@@ -225,3 +226,3 @@ }, | ||
attribute: "height", | ||
maxlength: "3", | ||
maxLength: "3", | ||
width: 38 | ||
@@ -228,0 +229,0 @@ } |
@@ -30,5 +30,5 @@ function showIfNumber(m, uim){ | ||
icon: "edi_fld.png", | ||
entity: "field", | ||
entities: "fields", | ||
leadfield: 'label', | ||
name: "field", | ||
namePlural: "fields", | ||
fnTitle: 'label', | ||
elements: [ | ||
@@ -45,5 +45,5 @@ { | ||
help: "Field title for the user", | ||
maxlength: 100, | ||
maxLength: 100, | ||
required: true, | ||
viewmany: true, | ||
inMany: true, | ||
width: 100 | ||
@@ -68,5 +68,5 @@ } | ||
list:uiFieldTypes, | ||
maxlength: 100, | ||
maxLength: 100, | ||
required: true, | ||
viewmany: true, | ||
inMany: true, | ||
width: 100 | ||
@@ -80,7 +80,7 @@ }, | ||
type: "text", | ||
maxlength: 100, | ||
maxLength: 100, | ||
width: 62 | ||
}, | ||
{ | ||
id: 'colpix', | ||
id: 'eid', | ||
label: "ID", | ||
@@ -90,3 +90,3 @@ labellist: "ID", | ||
help: 'Field ID in the DOM = prefix + ID', | ||
maxlength: 100, | ||
maxLength: 100, | ||
width: 38 | ||
@@ -99,3 +99,3 @@ }, | ||
help: "example '$ 0.00'", | ||
maxlength: 30, | ||
maxLength: 30, | ||
width: 62 | ||
@@ -109,3 +109,3 @@ }, | ||
type: "text", | ||
maxlength: 20, | ||
maxLength: 20, | ||
width: 38 | ||
@@ -129,6 +129,6 @@ } | ||
label: "Required", | ||
//defaultvalue: false, | ||
//defaultValue: false, | ||
help: "Mandatory field", | ||
type: "boolean", | ||
viewmany: true, | ||
inMany: true, | ||
width: 50, | ||
@@ -140,3 +140,3 @@ img: "checkr.gif" | ||
label: "Read only", | ||
defaultvalue:false, | ||
defaultValue:false, | ||
help: "Users can view this field value but cannot modify it", | ||
@@ -148,3 +148,3 @@ type: "boolean", | ||
{ | ||
id:'minlength', | ||
id:'minLength', | ||
label: "Min. length", | ||
@@ -156,7 +156,7 @@ help: "Minimum number of characters required", | ||
{ | ||
id:'maxlength', | ||
id:'maxLength', | ||
label: "Max. length", | ||
help: "Maximum number of characters allowed", | ||
type: "integer", | ||
maxlength: 7, | ||
maxLength: 7, | ||
width: 50 | ||
@@ -173,3 +173,3 @@ }, | ||
type: "integer", | ||
maxlength: 4, | ||
maxLength: 4, | ||
width: 50 | ||
@@ -186,11 +186,11 @@ }, | ||
type: "integer", | ||
maxlength: 4, | ||
maxLength: 4, | ||
width: 50 | ||
}/*, | ||
{ | ||
id:'regex', | ||
id:'regExp', | ||
label: "Regular Expression", | ||
labellist: "RegExp", | ||
type: "integer", | ||
maxlength: 100, | ||
maxLength: 100, | ||
width: 100, | ||
@@ -217,7 +217,7 @@ help: 'Regular expression used to validate the field value.' | ||
type: "integer", | ||
maxlength: 3, | ||
maxLength: 3, | ||
width: 62 | ||
}, | ||
{ | ||
id:'viewmany', | ||
id:'inMany', | ||
label: "List", | ||
@@ -227,3 +227,3 @@ help: "Field shows in lists", | ||
type: "boolean", | ||
viewmany: true, | ||
inMany: true, | ||
width: 38 | ||
@@ -237,4 +237,4 @@ }, | ||
type: "integer", | ||
maxlength: 3, | ||
defaultvalue: 1, | ||
maxLength: 3, | ||
defaultValue: 1, | ||
max:30, | ||
@@ -246,7 +246,7 @@ width: 62 | ||
label: "Width", | ||
defaultvalue: 100, | ||
defaultValue: 100, | ||
help: "Relative width of the field (in percentage)", | ||
type: "integer", | ||
format: "0 '%'", | ||
maxlength: 3, | ||
maxLength: 3, | ||
width: 38 | ||
@@ -272,3 +272,3 @@ } | ||
type: "textmultiline", | ||
maxlength: 500, | ||
maxLength: 500, | ||
width: 100, | ||
@@ -275,0 +275,0 @@ height: 6 |
@@ -30,5 +30,5 @@ function showIfNumber(m, uim){ | ||
icon: "edi_fld.png", | ||
entity: "field", | ||
entities: "fields", | ||
leadfield: 'label', | ||
name: "field", | ||
namePlural: "fields", | ||
fnTitle: 'label', | ||
elements: [ | ||
@@ -45,5 +45,5 @@ { | ||
help: "Field title for the user", | ||
maxlength: 100, | ||
maxLength: 100, | ||
required: true, | ||
viewmany: true, | ||
inMany: true, | ||
width: 62 | ||
@@ -57,5 +57,5 @@ }, | ||
list:uiFieldTypes, | ||
maxlength: 100, | ||
maxLength: 100, | ||
required: true, | ||
viewmany: true, | ||
inMany: true, | ||
width: 38 | ||
@@ -69,7 +69,7 @@ }, | ||
type: "text", | ||
maxlength: 100, | ||
maxLength: 100, | ||
width: 62 | ||
}, | ||
{ | ||
id: 'colpix', | ||
id: 'eid', | ||
label: "ID", | ||
@@ -79,3 +79,3 @@ labellist: "ID", | ||
help: 'Field ID in the DOM = prefix + ID', | ||
maxlength: 100, | ||
maxLength: 100, | ||
width: 38 | ||
@@ -88,6 +88,51 @@ }, | ||
help: "example '$ 0.00'", | ||
maxlength: 30, | ||
maxLength: 30, | ||
width: 100 | ||
} | ||
] | ||
}, | ||
{ | ||
type: "panel", | ||
label: "Layout", | ||
width: 38, | ||
elements: [ | ||
{ | ||
id:'position', | ||
label: "Position", | ||
help: "Integer (do not have to be consecutive)", | ||
type: "integer", | ||
maxLength: 3, | ||
width: 62 | ||
}, | ||
{ | ||
id:'inMany', | ||
label: "List", | ||
help: "Field shows in lists", | ||
labellist: "List", | ||
type: "boolean", | ||
inMany: true, | ||
width: 38 | ||
}, | ||
{ | ||
id:'width', | ||
label: "Width", | ||
defaultValue: 100, | ||
help: "Relative width of the field (in percentage)", | ||
type: "integer", | ||
format: "0 '%'", | ||
maxLength: 3, | ||
width: 62 | ||
}, | ||
{ | ||
id:'height', | ||
attribute:'height', | ||
label: "Height", | ||
help: "Height in number of lines (for ''Textmultiline'' fields)", | ||
type: "integer", | ||
maxLength: 3, | ||
defaultValue: 1, | ||
max:30, | ||
width: 38 | ||
}, | ||
{ | ||
id: 'css', | ||
@@ -98,4 +143,4 @@ label: "CSS", | ||
type: "text", | ||
maxlength: 20, | ||
width: 38 | ||
maxLength: 20, | ||
width: 100 | ||
} | ||
@@ -107,3 +152,3 @@ ] | ||
label: "Validation", | ||
width: 38, | ||
width: 62, | ||
elements: [ | ||
@@ -113,6 +158,6 @@ { | ||
label: "Required", | ||
//defaultvalue: false, | ||
//defaultValue: false, | ||
help: "Mandatory field", | ||
type: "boolean", | ||
viewmany: true, | ||
inMany: true, | ||
width: 50, | ||
@@ -124,3 +169,3 @@ img: "checkr.gif" | ||
label: "Read only", | ||
defaultvalue:false, | ||
defaultValue:false, | ||
help: "Users can view this field value but cannot modify it", | ||
@@ -132,3 +177,3 @@ type: "boolean", | ||
{ | ||
id:'minlength', | ||
id:'minLength', | ||
label: "Min. length", | ||
@@ -140,7 +185,7 @@ help: "Minimum number of characters required", | ||
{ | ||
id:'maxlength', | ||
id:'maxLength', | ||
label: "Max. length", | ||
help: "Maximum number of characters allowed", | ||
type: "integer", | ||
maxlength: 7, | ||
maxLength: 7, | ||
width: 50 | ||
@@ -157,3 +202,3 @@ }, | ||
type: "integer", | ||
maxlength: 4, | ||
maxLength: 4, | ||
width: 50 | ||
@@ -170,58 +215,21 @@ }, | ||
type: "integer", | ||
maxlength: 4, | ||
maxLength: 4, | ||
width: 50 | ||
}/*, | ||
}, | ||
{ | ||
id:'regex', | ||
id:'regExp', | ||
label: "Regular Expression", | ||
labellist: "RegExp", | ||
type: "integer", | ||
maxlength: 100, | ||
width: 100, | ||
type: "text", | ||
maxLength: 100, | ||
width: 50, | ||
help: 'Regular expression used to validate the field value.' | ||
}*/ | ||
] | ||
}, | ||
{ | ||
type: "panel", | ||
label: "Layout", | ||
width: 62, | ||
elements: [ | ||
{ | ||
id:'position', | ||
label: "Position", | ||
help: "Integer (do not have to be consecutive)", | ||
type: "integer", | ||
maxlength: 3, | ||
width: 62 | ||
}, | ||
{ | ||
id:'viewmany', | ||
label: "List", | ||
help: "Field shows in lists", | ||
labellist: "List", | ||
type: "boolean", | ||
viewmany: true, | ||
width: 38 | ||
}, | ||
{ | ||
id:'height', | ||
attribute:'height', | ||
label: "Height", | ||
help: "Height in number of lines (for ''Textmultiline'' fields)", | ||
type: "integer", | ||
maxlength: 3, | ||
defaultvalue: 1, | ||
max:30, | ||
width: 62 | ||
}, | ||
{ | ||
id:'width', | ||
label: "Width", | ||
defaultvalue: 100, | ||
help: "Relative width of the field (in percentage)", | ||
type: "integer", | ||
format: "0 '%'", | ||
maxlength: 3, | ||
width: 38 | ||
id:'fnValidate', | ||
label: "Custom Validation Method", | ||
type: "text", | ||
maxLength: 100, | ||
width: 50, | ||
help: 'Name of Javascript function for validating the data.' | ||
} | ||
@@ -241,5 +249,5 @@ ] | ||
type: "textmultiline", | ||
maxlength: 500, | ||
maxLength: 500, | ||
width: 100, | ||
height: 4 | ||
height: 8 | ||
} | ||
@@ -246,0 +254,0 @@ ] |
@@ -8,5 +8,5 @@ // TODO cleanup | ||
icon: "edi_frm.png", | ||
entity: "object", | ||
entities: "objects", | ||
leadfield: "Title", | ||
name: "object", | ||
namePlural: "objects", | ||
fnTitle: "Title", | ||
elements: [ | ||
@@ -25,4 +25,4 @@ { | ||
attribute: "Title", | ||
maxlength: 100, | ||
viewmany: true, | ||
maxLength: 100, | ||
inMany: true, | ||
width: 80, | ||
@@ -36,3 +36,3 @@ required: true | ||
attribute: "PUBLISH", | ||
viewmany: true, | ||
inMany: true, | ||
width: 20 | ||
@@ -46,4 +46,4 @@ }, | ||
attribute: "id", | ||
maxlength: 100, | ||
viewmany: true, | ||
maxLength: 100, | ||
inMany: true, | ||
width: 100, | ||
@@ -68,7 +68,7 @@ readonly: true | ||
type: "text", | ||
id: "entity", | ||
attribute: "entity", | ||
id: "name", | ||
attribute: "name", | ||
required: true, | ||
maxlength: 50, | ||
viewmany: true, | ||
maxLength: 50, | ||
inMany: true, | ||
width: 62 | ||
@@ -80,6 +80,6 @@ }, | ||
type: "text", | ||
id: "entities", | ||
attribute: "entities", | ||
id: "namePlural", | ||
attribute: "namePlural", | ||
required: true, | ||
maxlength: 50, | ||
maxLength: 50, | ||
width: 38 | ||
@@ -92,3 +92,3 @@ }, | ||
attribute: "icon", | ||
maxlength: "50", | ||
maxLength: "50", | ||
width: 62, | ||
@@ -110,3 +110,3 @@ help: "example='contact.gif'" | ||
attribute: "Description", | ||
maxlength: 250, | ||
maxLength: 250, | ||
width: 100, | ||
@@ -136,3 +136,3 @@ height: 7 | ||
attribute: "Label", | ||
maxlength: 100, | ||
maxLength: 100, | ||
listmany:true | ||
@@ -150,3 +150,3 @@ //"link": "EvoDicoField.aspx?ID=@itemid" | ||
"dbcolumnreadlov": "label", | ||
maxlength: "50", | ||
maxLength: "50", | ||
"search": "1", | ||
@@ -164,3 +164,3 @@ "searchlist": "1", | ||
"dbtablelov": "EvoDico_vFieldType", | ||
maxlength: "100", | ||
maxLength: "100", | ||
"search": "1", | ||
@@ -204,3 +204,3 @@ "searchlist": "1", | ||
attribute: "fpos", | ||
maxlength: "3", | ||
maxLength: "3", | ||
"search": "0", | ||
@@ -218,3 +218,3 @@ "searchlist": "1", | ||
attribute: "Width", | ||
maxlength: "3", | ||
maxLength: "3", | ||
"search": "0", | ||
@@ -232,3 +232,3 @@ "searchlist": "1", | ||
attribute: "Height", | ||
maxlength: "3", | ||
maxLength: "3", | ||
"search": "0", | ||
@@ -264,3 +264,3 @@ "searchlist": "1", | ||
attribute: "Label", | ||
maxlength: "100", | ||
maxLength: "100", | ||
"link": "EvoDicoPanel.aspx?ID=@itemid", | ||
@@ -279,3 +279,3 @@ "search": "1", | ||
attribute: "ppos", | ||
maxlength: "3", | ||
maxLength: "3", | ||
"search": "0", | ||
@@ -292,3 +292,3 @@ "searchlist": "1", | ||
attribute: "Width", | ||
maxlength: "3", | ||
maxLength: "3", | ||
"search": "0", | ||
@@ -306,3 +306,3 @@ "searchlist": "1", | ||
attribute: "cssclass", | ||
maxlength: "100", | ||
maxLength: "100", | ||
"searchadv": "1", | ||
@@ -330,3 +330,3 @@ width: 38 | ||
attribute: "dbtable", | ||
maxlength: "100", | ||
maxLength: "100", | ||
"search": "1", | ||
@@ -346,3 +346,3 @@ "searchlist": "0", | ||
attribute: "dbwhere", | ||
maxlength: "50", | ||
maxLength: "50", | ||
"search": "0", | ||
@@ -361,3 +361,3 @@ "searchlist": "0", | ||
attribute: "dborder", | ||
maxlength: "50", | ||
maxLength: "50", | ||
"search": "0", | ||
@@ -375,3 +375,3 @@ "searchlist": "0", | ||
attribute: "dbcolumnlead", | ||
maxlength: "100", | ||
maxLength: "100", | ||
"searchlist": "0", | ||
@@ -389,3 +389,3 @@ "searchadv": "1", | ||
attribute: "dbcolumnpk", | ||
maxlength: "50", | ||
maxLength: "50", | ||
"search": "0", | ||
@@ -403,3 +403,3 @@ "searchlist": "0", | ||
attribute: "dbColumnicon", | ||
maxlength: "50", | ||
maxLength: "50", | ||
"search": "1", | ||
@@ -417,3 +417,3 @@ "searchlist": "0", | ||
attribute: "dbtableusers", | ||
maxlength: "100", | ||
maxLength: "100", | ||
"searchlist": "0", | ||
@@ -430,3 +430,3 @@ "searchadv": "0", | ||
attribute: "dbtablecomments", | ||
maxlength: "100", | ||
maxLength: "100", | ||
"searchlist": "0", | ||
@@ -451,3 +451,3 @@ "searchadv": "0", | ||
attribute: "spPaging", | ||
maxlength: "200", | ||
maxLength: "200", | ||
"search": "1", | ||
@@ -466,3 +466,3 @@ "searchlist": "0", | ||
attribute: "spLogin", | ||
maxlength: "200", | ||
maxLength: "200", | ||
"search": "0", | ||
@@ -480,3 +480,3 @@ "searchlist": "0", | ||
attribute: "spGet", | ||
maxlength: 200, | ||
maxLength: 200, | ||
"search": "0", | ||
@@ -495,3 +495,3 @@ "searchlist": "0", | ||
attribute: "spDelete", | ||
maxlength: "200", | ||
maxLength: "200", | ||
width: 100, | ||
@@ -521,3 +521,3 @@ height: 2 | ||
attribute: "Help", | ||
maxlength: "500", | ||
maxLength: "500", | ||
width: 100, | ||
@@ -542,3 +542,3 @@ height: 4 | ||
"readonly": "2", | ||
maxlength: 100, | ||
maxLength: 100, | ||
"searchlist": "1", | ||
@@ -551,3 +551,3 @@ "searchadv": "1", | ||
type: "textmultiline", | ||
maxlength: "500", | ||
maxLength: "500", | ||
id: "Help", | ||
@@ -554,0 +554,0 @@ attribute: "Help", |
@@ -6,5 +6,5 @@ | ||
icon: "edi_pnl.png", | ||
entity: "panel", | ||
entities: "panels", | ||
leadfield: 'label', | ||
name: "panel", | ||
namePlural: "panels", | ||
fnTitle: 'label', | ||
elements: [ | ||
@@ -22,5 +22,5 @@ { | ||
help: "Field title for the user", | ||
maxlength: 100, | ||
maxLength: 100, | ||
required: true, | ||
viewmany: true, | ||
inMany: true, | ||
width: 100 | ||
@@ -34,11 +34,11 @@ }, | ||
type: "text", | ||
maxlength: 20, | ||
maxLength: 20, | ||
width: 62 | ||
}, | ||
{ | ||
id: 'csslabel', | ||
id: 'cssLabel', | ||
label: "CSS label", | ||
help: "Stylesheet class name for the field label.", | ||
type: "text", | ||
maxlength: 20, | ||
maxLength: 20, | ||
width: 38 | ||
@@ -45,0 +45,0 @@ } |
{ | ||
"name": "evolutility", | ||
"version": "0.5.0", | ||
"version": "1.0.0", | ||
"copyright": "(c) 2015 Olivier Giulieri", | ||
@@ -5,0 +5,0 @@ "license": "AGPL-3.0", |
121
README.md
@@ -166,55 +166,88 @@ # Evolutility.js | ||
Here is the UI model used to configure all views for the ["To Do" app demo](http://evoluteur.github.io/evolutility/demo/index.html#todo/list): | ||
Here is the UI-model used to configure all views for the ["Graphic Novels" app demo](http://evoluteur.github.io/evolutility/demo/index.html#comics/cards): | ||
```javascript | ||
var UIModel_todo = { | ||
id: 'todo', | ||
label: 'To Do', | ||
entity: 'task', | ||
entities: 'tasks', | ||
icon: 'todo.gif', | ||
leadfield:'title', | ||
var uiModels_comics = { | ||
id: 'comics', | ||
label: 'Graphic Novels', | ||
name: 'graphic novel serie', | ||
namePlural: 'graphic novel series', | ||
fnTitle: 'title', | ||
fnBadge: function(m){ | ||
var hNb=m.get('haveNb'), | ||
sNb=m.get('serieNb'); | ||
return (hNb==sNb)?hNb:hNb+'/'+sNb; | ||
}, | ||
elements: [ | ||
{ | ||
type: 'panel', label: 'Task', width: 62, | ||
type: 'panel', label: 'Serie', width: 70, | ||
elements: [ | ||
{ | ||
id: 'title', type: 'text', label: 'Title', | ||
required: true, maxlength: 255, | ||
width: 100, viewmany: true | ||
id: 'title', attribute: 'title', type: 'text', label: 'Title', required: true, | ||
maxLength: 255, | ||
width: 62, inMany: true | ||
}, | ||
{ | ||
id: 'duedate', type: 'date', label: 'Due Date', | ||
width: 62, viewmany: true | ||
}, | ||
{ | ||
id: 'category', type: 'lov', label: 'Category', | ||
width: 38, viewmany: true, | ||
id: 'genre', attribute: 'genre', type: 'lov', label: 'Genre', width: 38, inMany: true, | ||
list: [ | ||
{id: 'home', text: 'Home'}, | ||
{id: 'work', text: 'Work'}, | ||
{id: 'fun', text: 'Fun'}, | ||
{id: 'others', text: 'Others'}, | ||
{id: 'misc', text: 'Misc.'} | ||
{id: 'adv', text: 'Adventure'}, | ||
{id: 'conte', text: 'Fairy tale'}, | ||
{id: 'eros', text: 'Erotic'}, | ||
{id: 'fantasy', text: 'Fantastic'}, | ||
{id: 'hf', text: 'Heroic Fantasy'}, | ||
{id: 'hist', text: 'Historic'}, | ||
{id: 'humor', text: 'Humor'}, | ||
{id: 'nocat', text: 'One of a kind'}, | ||
{id: 'youth', text: 'Youth'}, | ||
{id: 'pol', text: 'Thriller'}, | ||
{id: 'sf', text: 'Science-fiction'}, | ||
{id: 'sh', text: 'Super Heros'}, | ||
{id: 'wwest', text: 'Western'} | ||
] | ||
} | ||
] | ||
}, | ||
{ | ||
type: 'panel', label: 'Status', width: 38, | ||
elements: [ | ||
}, | ||
{ | ||
id: 'priority', type: 'lov', label: 'Priority', required: true, | ||
width: 100, viewmany: true, | ||
id: 'authors', attribute: 'authors', type: 'text', width: 62, inMany: true, | ||
label: 'Authors' | ||
}, | ||
{ | ||
id: 'language', attribute: 'language', type: 'lov', label: 'Language', width: 38, inMany: false, | ||
list: [ | ||
{id: '1', text: '1 - ASAP'}, | ||
{id: '2', text: '2 - Urgent'}, | ||
{id: '3', text: '3 - Important'}, | ||
{id: '4', text: '4 - Medium'}, | ||
{id: '5', text: '5 - Low'} | ||
{id: 'FR', text: 'French'}, | ||
{id: 'EN', text: 'English'} | ||
] | ||
}, | ||
{ | ||
id: 'complete', type: 'boolean', label: 'Complete', | ||
width: 100, viewmany: true | ||
id: 'serieNb', attribute: 'serieNb', type: 'integer', width: 15, inMany: false, | ||
label: 'Albums', inCharts:false | ||
}, | ||
{ | ||
id: 'haveNb', attribute: 'haveNb', type: 'integer', width: 15, inMany: false, | ||
label: 'Owned', inCharts:false | ||
}, | ||
{ | ||
id: 'have', attribute: 'have', type: 'text', width: 32, inMany: false, | ||
label: 'have' | ||
}, | ||
{ | ||
id: 'complete', attribute: 'complete', type: 'boolean', width: 19, inMany: true, | ||
label: 'Complete', labelFalse:'Incomplete', labelTrue:'Complete' | ||
}, | ||
{ | ||
id: 'finished', attribute: 'finished', type: 'boolean', width: 19, inMany: true, | ||
label: 'Finished', labelTrue:'Finished', labelFalse:'Unfinished', css:'cBlue' | ||
}, | ||
{ | ||
id:'amazon', label:'Amazon', type:'formula', width:100, css:'evol-ellipsis', | ||
formula:function(m){ | ||
var link=m.get('language')=='FR' ? | ||
'http://www.amazon.fr/s/ref=sr_nr_n_1?keywords=' | ||
:'http://www.amazon.com/s/ref=nb_sb_noss?field-keywords='; | ||
link+=encodeURI(m.get('title')+' '+m.get('authors')); | ||
return '<a target="a" href="'+link+'">'+link+'</a>'; | ||
} | ||
}, | ||
{ | ||
id: 'notes', attribute: 'notes', type: 'textmultiline', label: 'Notes', maxLength: 1000, | ||
width: 100, height: 6, inMany: false | ||
} | ||
@@ -224,8 +257,7 @@ ] | ||
{ | ||
type: 'panel', label: 'Notes', width: 100, | ||
type: 'panel', label: 'Cover', width: 30, | ||
elements: [ | ||
{ | ||
id: 'notes', type: 'textmultiline', label: 'Notes', | ||
maxlength: 1000, | ||
width: 100, height: 6, viewmany: false | ||
id: 'pix', attribute: 'pix', type: 'image', width: 100, inMany: true, | ||
label: 'Cover' | ||
} | ||
@@ -236,2 +268,3 @@ ] | ||
}; | ||
``` | ||
@@ -241,3 +274,3 @@ | ||
UI Models for the demo apps: | ||
UI-Models for the demo apps: | ||
[To Do list](http://github.com/evoluteur/evolutility/blob/master/js/ui-models/apps/todo.js), | ||
@@ -263,3 +296,3 @@ [AddressBook](http://github.com/evoluteur/evolutility/blob/master/js/ui-models/apps/contacts.js), | ||
Note: For convenience, all dependencies are minified together in a single file "vendors.min.js". The dependencies list is specified in "Gruntfile.js". | ||
Note: For convenience, all dependencies are minified together in a single file "dependencies.min.js". The dependencies list is specified in "Gruntfile.js". | ||
@@ -266,0 +299,0 @@ ## Documentation |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Minified code
QualityThis package contains minified code. This may be harmless in some cases where minified code is included in packaged libraries, however packages on npm should not minify code.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Network access
Supply chain riskThis module accesses the network.
Found 1 instance in 1 package
Minified code
QualityThis package contains minified code. This may be harmless in some cases where minified code is included in packaged libraries, however packages on npm should not minify code.
Found 1 instance in 1 package
No v1
QualityPackage is not semver >=1. This means it is not stable and does not support ^ ranges.
Found 1 instance in 1 package
2365361
142
18841
1
309
7