PHP8
[Pman.BAdmin] / Pman.Dialog.BAdminEmailPreview.js
1 //<script type="text/javascript">
2
3 // Auto generated file - created by app.Builder.js- do not edit directly (at present!)
4
5 Roo.namespace('Pman.Dialog');
6
7 Pman.Dialog.BAdminEmailPreview= function() {}
8 Roo.apply(Pman.Dialog.BAdminEmailPreview.prototype, {
9
10  _strings : {
11   '10e0d90d01ee3b134ee40b7ad31566a4' :"Message Preview",
12   '4cd8413207629a963225f4314b53adcd' :"Plain",
13   'd3d2e617335f08df83599665eef8a418' :"Close",
14   '4c4ad5fca2e7a3f74dbb1ced00381aa4' :"HTML"
15  },
16
17  dialog : false,
18  callback:  false,
19
20  show : function(data, cb)
21  {
22   if (!this.dialog) {
23    this.create();
24   }
25
26   this.callback = cb;
27   this.data = data;
28   this.dialog.show(this.data._el);
29   if (this.form) {
30    this.form.reset();
31    this.form.setValues(data);
32    this.form.fireEvent('actioncomplete', this.form,  { type: 'setdata', data: data });
33   }
34
35  },
36
37  create : function()
38  {
39   var _this = this;
40   this.dialog = Roo.factory({
41     xtype : 'Modal',
42     fitwindow : true,
43     title : _this._strings['10e0d90d01ee3b134ee40b7ad31566a4'] /* Message Preview */,
44     listeners : {
45      show : function (_self)
46       {
47       
48           _this.panel.load({
49               url: baseURL + '/Core/MessagePreview', 
50               params  : {
51                   _id : _this.data.id,
52                   _table : _this.data.module
53               },
54               method : 'GET'
55           });
56           
57           _this.hpanel.load({
58               url: baseURL + '/Core/MessagePreview', 
59               params  : {
60                   _as_html : 1,
61                   _id : _this.data.id,
62                   _table : _this.data.module
63               },
64               method : 'GET'
65           });
66       
67       }
68     },
69     xns : Roo.bootstrap,
70     '|xns' : 'Roo.bootstrap',
71     buttons : [
72      {
73       xtype : 'Button',
74       html : _this._strings['d3d2e617335f08df83599665eef8a418'] /* Close */,
75       name : 'close',
76       listeners : {
77        click : function (_self, e)
78         {
79             _this.dialog.hide();
80         }
81       },
82       xns : Roo.bootstrap,
83       '|xns' : 'Roo.bootstrap'
84      }
85     ],
86     items  : [
87      {
88       xtype : 'Border',
89       xns : Roo.bootstrap.layout,
90       '|xns' : 'Roo.bootstrap.layout',
91       center : {
92        xtype : 'Region',
93        alwaysShowTabs : true,
94        autoScroll : true,
95        tabPosition : 'top',
96        xns : Roo.bootstrap.layout,
97        '|xns' : 'Roo.bootstrap.layout'
98       },
99       items  : [
100        {
101         xtype : 'Content',
102         autoScroll : true,
103         region : 'center',
104         title : _this._strings['4cd8413207629a963225f4314b53adcd'] /* Plain */,
105         listeners : {
106          render : function (_self)
107           {
108               _this.panel = this;
109           }
110         },
111         xns : Roo.bootstrap.panel,
112         '|xns' : 'Roo.bootstrap.panel'
113        },
114        {
115         xtype : 'Content',
116         autoScroll : true,
117         background : true,
118         region : 'center',
119         title : _this._strings['4c4ad5fca2e7a3f74dbb1ced00381aa4'] /* HTML */,
120         listeners : {
121          render : function (_self)
122           {
123               _this.hpanel = this;
124           }
125         },
126         xns : Roo.bootstrap.panel,
127         '|xns' : 'Roo.bootstrap.panel'
128        }
129       ]
130      }
131     ]
132    }  );
133  }
134 });
135 Roo.apply(Pman.Dialog.BAdminEmailPreview, Pman.Dialog.BAdminEmailPreview.prototype);