Pman.Dialog.CoreNotifyRefer.bjs
authorAlan Knowles <alan@roojs.com>
Wed, 16 May 2012 05:01:05 +0000 (13:01 +0800)
committerAlan Knowles <alan@roojs.com>
Wed, 16 May 2012 05:01:05 +0000 (13:01 +0800)
Pman.Dialog.CoreNotifyRefer.js

Pman.Dialog.CoreNotifyRefer.bjs
Pman.Dialog.CoreNotifyRefer.js

index 805a01d..38ff784 100644 (file)
                                                         {
                                                             "*prop": "store",
                                                             "xtype": "SimpleStore",
-                                                            "|data": "[ \n    [ 'HOURLY' , 'Hourly at' ] ,\n       [ 'DAILY' , 'Daily at'] ,\n        [ 'WEEKLY' , 'Weekly at'] ,\n         [ 'Montly' , 'Montly at'] \n]",
+                                                            "|data": "(function() { \n    var ret = [];\n    Roo.each(Date.dayNames, function(d) {\n        ret.push([ d.substring(0,3).toUpperCase(), d ]);\n    });\n    return ret;\n})()",
                                                             "|fields": "['code', 'title']",
                                                             "|sortInfo": "{ field : 'title', direction: 'ASC' }",
                                                             "|xns": "Roo.data"
index 71e4e25..3242416 100644 (file)
@@ -317,12 +317,13 @@ Pman.Dialog.CoreNotifyRefer = {
                                         store : {
                                             xtype: 'SimpleStore',
                                             xns: Roo.data,
-                                            data : [ 
-                                                [ 'HOURLY' , 'Hourly at' ] ,
-                                                   [ 'DAILY' , 'Daily at'] ,
-                                                    [ 'WEEKLY' , 'Weekly at'] ,
-                                                     [ 'Montly' , 'Montly at'] 
-                                            ],
+                                            data : (function() { 
+                                                var ret = [];
+                                                Roo.each(Date.dayNames, function(d) {
+                                                    ret.push([ d.substring(0,3).toUpperCase(), d ]);
+                                                });
+                                                return ret;
+                                            })(),
                                             fields : ['code', 'title'],
                                             sortInfo : { field : 'title', direction: 'ASC' }
                                         }