Pman.Tab.XtupleArAging.bjs
authorAlan Knowles <alan@roojs.com>
Thu, 5 Dec 2013 03:41:45 +0000 (11:41 +0800)
committerAlan Knowles <alan@roojs.com>
Thu, 5 Dec 2013 03:41:45 +0000 (11:41 +0800)
Pman.Tab.XtupleArAging.js

Pman.Tab.XtupleArAging.bjs
Pman.Tab.XtupleArAging.js

index 4e7659f..ab02d02 100644 (file)
                                             "header": "Doc Type",
                                             "width": 40,
                                             "xtype": "ColumnModel",
-                                            "|renderer": "function(v) { return String.format('{0}', v); }",
+                                            "|renderer": "function(v) {\n    switch(v) {\n        case 'I':\n            return \"Invoice\";\n        case 'C':\n            return \"Credit Memo\";        \n        case 'D':\n            return \"Debit Memo\";                    \n        case 'R':\n            return \"Cash Receipt\";        \n        default:\n             return String.format('{0}', v); \n     }\n }",
                                             "|xns": "Roo.grid"
                                         },
                                         {
index 2736437..dfa324d 100644 (file)
@@ -366,7 +366,20 @@ Pman.Tab.XtupleArAging = new Roo.XComponent({
                                     dataIndex : 'araging_doctype',
                                     header : 'Doc Type',
                                     width : 40,
-                                    renderer : function(v) { return String.format('{0}', v); }
+                                    renderer : function(v) {
+                                        switch(v) {
+                                            case 'I':
+                                                return "Invoice";
+                                            case 'C':
+                                                return "Credit Memo";        
+                                            case 'D':
+                                                return "Debit Memo";                    
+                                            case 'R':
+                                                return "Cash Receipt";        
+                                            default:
+                                                 return String.format('{0}', v); 
+                                         }
+                                     }
                                 },
                                 {
                                     xtype: 'ColumnModel',