Pman.Dialog.BAdminPasswordReset.bjs
[Pman.BAdmin] / Pman.Tab.bjs
1 {
2  "name" : "Pman.Tab",
3  "parent" : "",
4  "title" : "",
5  "path" : "/home/edward/gitlive/Pman.BAdmin/Pman.Tab.bjs",
6  "permname" : "",
7  "modOrder" : "001",
8  "strings" : {
9   "7b7bc2512ee1fedcd76bdc68926d4f7b" : "Administrator",
10   "0323de4f66a1700e2173e9bcdce02715" : "Logout",
11   "8f1e77e0d2be21da93cd4d9a939148f7" : "Change Password",
12   "617114bd6ef10884239510062dffa933" : "Your password has been changed",
13   "24efa7ee4511563b16144f39706d594f" : "Notice"
14  },
15  "items" : [
16   {
17    "listeners" : {
18     "render" : "function (_self)\n{\n\n}"
19    },
20    "xtype" : "Border",
21    "$ el" : "document.body",
22    "$ xns" : "Roo.bootstrap.layout",
23    "bool is_root" : true,
24    "items" : [
25     {
26      "String tabPosition" : "top",
27      "xtype" : "Region",
28      "string cls" : "pman-admin-center",
29      "$ xns" : "Roo.bootstrap.layout",
30      "Boolean alwaysShowTabs" : true,
31      "* prop" : "center"
32     },
33     {
34      "xtype" : "Region",
35      "Boolean hideTabs" : true,
36      "Number height" : 50,
37      "$ xns" : "Roo.bootstrap.layout",
38      "* prop" : "north",
39      "String overflow" : "visible"
40     },
41     {
42      "Boolean fitContainer" : true,
43      "xtype" : "Content",
44      "$ xns" : "Roo.bootstrap.panel",
45      "String region" : "north",
46      "items" : [
47       {
48        "String position" : "fixed-top",
49        "String cls" : "headroom animated slideDown  no-srButton pman-admin-header",
50        "Boolean srButton" : true,
51        "bool autohide" : true,
52        "xtype" : "NavHeaderbar",
53        "Boolean inverse" : false,
54        "Boolean desktopCenter" : false,
55        "$ String brand" : "'<img   cls=\"header-logo\" src=\"' +    Roo.BLANK_IMAGE_URL + '\">'",
56        "$ xns" : "Roo.bootstrap",
57        "items" : [
58         {
59          "String type" : "nav",
60          "xtype" : "NavGroup",
61          "String align" : "right",
62          "$ xns" : "Roo.bootstrap",
63          "items" : [
64           {
65            "listeners" : {
66             "render" : "function (_self)\n{\n    _this.user_box = this;\n    \n    this.el.setVisibilityMode(Roo.Element.DISPLAY);\n    \n    this.el.show();\n}"
67            },
68            "Boolean preventDefault" : true,
69            "| function updateBadge" : "function() { }",
70            "xtype" : "NavItem",
71            "$ html" : "Pman.Login.authUser.name + '<span style=\"margin-left: 5px;\" class=\"badge badge-primary\"></span>'",
72            "$ xns" : "Roo.bootstrap",
73            "String icon" : "fa fa-user",
74            "items" : [
75             {
76              "listeners" : {
77               "show" : "function (_self)\n{\n    var width = Roo.lib.Dom.getViewWidth();\n    \n    var xy = this.el.getXY();\n    this.el.setStyle('position', 'absolute');\n    \n    if(width < 480){\n        xy[0] = 0;\n        this.el.setXY(xy);\n        this.el.setStyle('width', width + 'px');\n    }\n}"
78              },
79              "Boolean allowDomMove" : false,
80              "String cls" : "user-menu",
81              "xtype" : "Menu",
82              "$ xns" : "Roo.bootstrap",
83              "* prop" : "menu",
84              "items" : [
85               {
86                "String cls" : "user-body",
87                "Boolean preventDefault" : true,
88                "xtype" : "MenuItem",
89                "$ xns" : "Roo.bootstrap",
90                "Boolean isContainer" : true,
91                "items" : [
92                 {
93                  "xtype" : "Row",
94                  "$ xns" : "Roo.bootstrap",
95                  "items" : [
96                   {
97                    "Number md" : 12,
98                    "xtype" : "Column",
99                    "$ xns" : "Roo.bootstrap",
100                    "items" : [
101                     {
102                      "xtype" : "Row",
103                      "$ xns" : "Roo.bootstrap",
104                      "items" : [
105                       {
106                        "listeners" : {
107                         "render" : "function (_self)\n{\n    this.el.dom.innerHTML = '<b>' + Pman.Login.authUser.name + '</b>';\n    \n}"
108                        },
109                        "Number md" : 12,
110                        "String cls" : "text-primary",
111                        "xtype" : "Column",
112                        "$ xns" : "Roo.bootstrap"
113                       },
114                       {
115                        "listeners" : {
116                         "render" : "function (_self)\n{\n   \n    this.el.dom.innerHTML = Pman.Login.authUser.email;\n    \n}"
117                        },
118                        "Number md" : 12,
119                        "xtype" : "Column",
120                        "$ xns" : "Roo.bootstrap",
121                        "String style" : "color:#777;"
122                       },
123                       {
124                        "Number md" : 12,
125                        "xtype" : "Column",
126                        "$ xns" : "Roo.bootstrap",
127                        "items" : [
128                         {
129                          "listeners" : {
130                           "render" : "function (_self)\n{\n    _this.super_admin_btn = this;\n    \n}",
131                           "click" : "function (_self, e)\n{\n    if(window.location.href.indexOf('_super_admin=1') * 1 != -1) {\n        window.open(baseURL,'_self');\n        return;\n    }\n    \n    window.open(baseURL + '?_super_admin=1','_self');\n}"
132                          },
133                          "String weight" : "link",
134                          "xtype" : "Button",
135                          "$ xns" : "Roo.bootstrap",
136                          "String html" : "Administrator",
137                          "String style" : "padding: 0px;text-decoration: none; color:#777;"
138                         }
139                        ]
140                       }
141                      ]
142                     }
143                    ]
144                   }
145                  ]
146                 }
147                ]
148               },
149               {
150                "listeners" : {
151                 "childrenrendered" : "function (_self)\n{\n    _this.super_admin_btn.hide();\n\n    if(Pman.Login.authUser.groups.indexOf('Administrators') * 1 != -1) {\n        _this.super_admin_btn.show();\n    }\n}"
152                },
153                "String cls" : "user-footer",
154                "Boolean preventDefault" : true,
155                "xtype" : "MenuItem",
156                "$ xns" : "Roo.bootstrap",
157                "Boolean isContainer" : true,
158                "items" : [
159                 {
160                  "xtype" : "Row",
161                  "$ xns" : "Roo.bootstrap",
162                  "items" : [
163                   {
164                    "Number md" : 6,
165                    "xtype" : "Column",
166                    "Number xs" : 6,
167                    "$ xns" : "Roo.bootstrap",
168                    "Number sm" : 6,
169                    "items" : [
170                     {
171                      "listeners" : {
172                       "click" : "function (e)\n{\n    var _self = this;\n    \n    Pman.Dialog.BAdminPassword.show(\n        {},\n        function(res) {\n            Roo.bootstrap.MessageBox.alert(_self._change_passwd_success_title, _self._change_passwd_success_body);\n        }\n    );\n    \n}"
173                      },
174                      "xtype" : "Button",
175                      "string _change_passwd_success_body" : "Your password has been changed",
176                      "$ xns" : "Roo.bootstrap",
177                      "String html" : "Change Password",
178                      "String style" : "text-transform:none;",
179                      "string _change_passwd_success_title" : "Notice"
180                     }
181                    ]
182                   },
183                   {
184                    "Number md" : 6,
185                    "xtype" : "Column",
186                    "Number xs" : 6,
187                    "$ xns" : "Roo.bootstrap",
188                    "String style" : "text-align: right;",
189                    "Number sm" : 6,
190                    "items" : [
191                     {
192                      "listeners" : {
193                       "click" : "function (e)\n{\n    window.onbeforeunload = false;\n    \n    \n    Roo.Ajax.request({\n            url : baseURL + '/Login',\n            method: 'POST',\n            params : { \n                logout : 1\n            },\n            success : function()\n            {\n                location.href = baseURL;\n            }\n        });\n\n}"
194                      },
195                      "xtype" : "Button",
196                      "$ xns" : "Roo.bootstrap",
197                      "String html" : "Logout",
198                      "String style" : "text-transform:none;"
199                     }
200                    ]
201                   }
202                  ]
203                 }
204                ]
205               }
206              ]
207             }
208            ]
209           }
210          ]
211         }
212        ]
213       }
214      ]
215     }
216    ]
217   }
218  ]
219 }