DataObjects/Cms_page.php
[Pman.Cms] / Pman.Tab.CmsCategoryType.bjs
1 {
2  "name" : "Pman.Tab.CmsCategoryType",
3  "parent" : "Pman.Tab.Cms",
4  "title" : "Pman.Tab.CmsCategoryType",
5  "path" : "/home/edward/gitlive/Pman.Cms/Pman.Tab.CmsCategoryType.bjs",
6  "permname" : "",
7  "modOrder" : "001",
8  "strings" : {
9   "8a50fa0a4557af5018e28054386cde1f" : "Category Types",
10   "512c3cbbc9d4e8f23edae03d7abc434e" : "No cms_category_type found",
11   "ec211f7c20af43e742bf2570c3cb84f9" : "Add",
12   "093a223e9365cd2675ea9389f321f640" : "Displaying cms_category_type{0} - {1} of {2}",
13   "7dce122004969d56ae2e0245cb754d35" : "Edit",
14   "f2a6c498fb90ee345d997f888fce3b18" : "Delete",
15   "49ee3087348e8d44e1feda1917443987" : "Name"
16  },
17  "items" : [
18   {
19    "listeners" : {
20     "|activate" : "function() {\n    _this.panel = this;\n    if (_this.grid) {\n        _this.grid.footer.onClick('first');\n    }\n    \n}"
21    },
22    "fitToframe" : true,
23    "background" : true,
24    "region" : "center",
25    "title" : "Category Types",
26    "xtype" : "GridPanel",
27    "fitContainer" : true,
28    "$ xns" : "Roo",
29    "tableName" : "cms_category_type",
30    "items" : [
31     {
32      "listeners" : {
33       "|rowdblclick" : "function (_self, rowIndex, e)\n{\n    if (!_this.dialog) {\n        return;\n    }\n    _this.dialog.show( this.getDataSource().getAt(rowIndex), function() {\n        _this.grid.footer.onClick('first');\n    }); \n}\n",
34       "|render" : "function() \n{\n    _this.grid = this; \n    _this.dialog = Pman.Dialog.CmsCategoryType;\n    if (_this.panel.active) {\n       this.footer.onClick('first');\n    }\n}"
35      },
36      "autoExpandColumn" : "name",
37      "xtype" : "Grid",
38      "loadMask" : true,
39      "$ xns" : "Roo.grid",
40      "* prop" : "grid",
41      "items" : [
42       {
43        "remoteSort" : true,
44        "xtype" : "Store",
45        "$ sortInfo" : "{ field : 'name', direction: 'ASC' }",
46        "$ xns" : "Roo.data",
47        "* prop" : "dataSource",
48        "items" : [
49         {
50          "$ url" : "baseURL + '/Roo/cms_category_type.php'",
51          "method" : "GET",
52          "xtype" : "HttpProxy",
53          "$ xns" : "Roo.data",
54          "* prop" : "proxy"
55         },
56         {
57          "id" : "id",
58          "root" : "data",
59          "xtype" : "JsonReader",
60          "$ xns" : "Roo.data",
61          "$ fields" : "[\n    {\n        'name': 'id',\n        'type': 'int'\n    },\n    {\n        'name': 'name',\n        'type': 'string'\n    }\n]",
62          "* prop" : "reader",
63          "totalProperty" : "total"
64         }
65        ]
66       },
67       {
68        "pageSize" : 25,
69        "xtype" : "PagingToolbar",
70        "emptyMsg" : "No cms_category_type found",
71        "$ xns" : "Roo",
72        "displayInfo" : true,
73        "displayMsg" : "Displaying cms_category_type{0} - {1} of {2}",
74        "* prop" : "footer"
75       },
76       {
77        "xtype" : "Toolbar",
78        "$ xns" : "Roo",
79        "* prop" : "toolbar",
80        "items" : [
81         {
82          "xtype" : "Fill",
83          "$ xns" : "Roo.Toolbar"
84         },
85         {
86          "listeners" : {
87           "|click" : "function()\n{\n    if (!_this.dialog) {\n        return;\n    }\n    _this.dialog.show( { id : 0 } , function() {\n        _this.grid.footer.onClick('first');\n   }); \n}\n"
88          },
89          "text" : "Add",
90          "xtype" : "Button",
91          "cls" : "x-btn-text-icon",
92          "$ icon" : "Roo.rootURL + 'images/default/dd/drop-add.gif'",
93          "$ xns" : "Roo.Toolbar"
94         },
95         {
96          "listeners" : {
97           "|click" : "function()\n{\n    var s = _this.grid.getSelectionModel().getSelections();\n    if (!s.length || (s.length > 1))  {\n        Roo.MessageBox.alert(\"Error\", s.length ? \"Select only one Row\" : \"Select a Row\");\n        return;\n    }\n    if (!_this.dialog) {\n        return;\n    }\n    _this.dialog.show(s[0].data, function() {\n        _this.grid.footer.onClick('first');\n    }); \n    \n}\n"
98          },
99          "text" : "Edit",
100          "xtype" : "Button",
101          "cls" : "x-btn-text-icon",
102          "$ icon" : "Roo.rootURL + 'images/default/tree/leaf.gif'",
103          "$ xns" : "Roo.Toolbar"
104         },
105         {
106          "listeners" : {
107           "|click" : "function()\n{\n     Pman.genericDelete(_this, 'cms_category_type'); \n}\n        "
108          },
109          "text" : "Delete",
110          "xtype" : "Button",
111          "cls" : "x-btn-text-icon",
112          "$ icon" : "rootURL + '/Pman/templates/images/trash.gif'",
113          "$ xns" : "Roo.Toolbar"
114         }
115        ]
116       },
117       {
118        "xtype" : "ColumnModel",
119        "header" : "Name",
120        "width" : 200,
121        "$ renderer" : "function(v) { return String.format('{0}', v); }",
122        "$ xns" : "Roo.grid",
123        "* prop" : "colModel[]",
124        "dataIndex" : "name"
125       }
126      ]
127     }
128    ]
129   }
130  ]
131 }