Pman.Dialog.CoreNotifyRecurKeywords.bjs
[Pman.Core] / Pman.Dialog.CoreNotifyRecurKeywords.bjs
1 {
2  "name" : "Pman.Dialog.CoreNotifyRecurKeywords",
3  "parent" : "",
4  "title" : "",
5  "path" : "/home/edward/gitlive/Pman.Core/Pman.Dialog.CoreNotifyRecurKeywords.bjs",
6  "permname" : "",
7  "modOrder" : "001",
8  "strings" : {
9   "ea4788705e6873b424c65e91c2846b19" : "Cancel",
10   "e0aa021e21dddbd6d8cecec71e9cf564" : "OK",
11   "790f855c2139f2faecb810519e90b833" : "Add Notification Keywords"
12  },
13  "items" : [
14   {
15    "listeners" : {
16     "show" : "function (_self)\n{\n    \n}"
17    },
18    "modal" : true,
19    "collapsible" : false,
20    "background" : true,
21    "title" : "Add Notification Keywords",
22    "xtype" : "LayoutDialog",
23    "width" : 400,
24    "$ xns" : "Roo",
25    "closable" : false,
26    "resizable" : false,
27    "height" : 150,
28    "items" : [
29     {
30      "xtype" : "LayoutRegion",
31      "$ xns" : "Roo",
32      "titlebar" : false,
33      "* prop" : "center"
34     },
35     {
36      "region" : "center",
37      "fitToFrame" : true,
38      "background" : true,
39      "xtype" : "ContentPanel",
40      "$ xns" : "Roo",
41      "items" : [
42       {
43        "listeners" : {
44         "|actioncomplete" : "function (_self, action)\n{\n  if (action.type == 'setdata') {\n        \n        if(_this.data.id){\n            _this.dialog.el.mask(\"Loading\");\n            this.load({ method: 'GET', params: { '_id' : _this.data.id }}); \n        }\n        \n        return;\n    }\n    if (action.type == 'load') {\n        _this.dialog.el.unmask();\n        return;\n    }\n    if (action.type == 'submit' ) {\n        _this.dialog.el.unmask();\n        _this.dialog.hide();\n\n        if (_this.callback) {\n           _this.callback.call(_this, action.result.data);\n        }\n        _this.form.reset();\n    }\n}\n",
45         "|rendered" : "function (form)\n{\n   _this.form = form;\n}"
46        },
47        "$ url" : "baseURL + '/Roo/Core_notify_recur.php'",
48        "xtype" : "Form",
49        "method" : "POST",
50        "style" : "margin: 5px",
51        "$ xns" : "Roo.form",
52        "items" : [
53         {
54          "xtype" : "Hidden",
55          "$ xns" : "Roo.form",
56          "name" : "id"
57         }
58        ]
59       }
60      ]
61     },
62     {
63      "listeners" : {
64       "|click" : "function() {\n    _this.form.reset();\n    _this.dialog.hide();\n}"
65      },
66      "text" : "Cancel",
67      "xtype" : "Button",
68      "$ xns" : "Roo",
69      "* prop" : "buttons[]"
70     },
71     {
72      "listeners" : {
73       "|click" : "function() {\n\n    var name =     _this.form.findField('name').getValue();\n    name = name.toUpperCase().replace(/[^A-Z]+/g, '');\n    if (!name.length) {\n        Roo.MessageBox.alert(\"Error\",\"Please fill in a valid name\");\n        return;\n    }\n    _this.form.findField('name').setValue(name);\n \n    _this.form.doAction('submit');\n    \n}"
74      },
75      "text" : "OK",
76      "xtype" : "Button",
77      "$ xns" : "Roo",
78      "* prop" : "buttons[]"
79     }
80    ]
81   }
82  ]
83 }