DataObjects/pman.links.ini
[Pman.Core] / Pman.Dialog.CoreMailingListMessage.js
index ae8d82a..c39c5bc 100644 (file)
@@ -167,12 +167,15 @@ Pman.Dialog.CoreMailingListMessage = {
                                 listeners : {
                                     select : function (combo, record, index)
                                     {
-                                        Roo.log(record);
+                                       
                                     /*
                                         (function() { 
                                             combo.setValue('');
                                         }).defer(100);
                                     */    
+                                        if(!record){
+                                            return;
+                                        }
                                         _this.form.findField('bodytext').setValue(record.data.content);
                                     
                                     }
@@ -312,8 +315,9 @@ Pman.Dialog.CoreMailingListMessage = {
                                                     if(_this.data.id*1 > 0){
                                                         _this.dialog.el.mask("Loading");
                                                         this.load({ method: 'GET', params: { '_id' : _this.data.id }});
-                                            
-                                                        _this.html_preview.show();
+                                                        if(_this.data.module == 'crm'){
+                                                            _this.html_preview.show();
+                                                        }
                                                         _this.preview_btn.show();
                                                         
                                                     } else {