0011102: popup window error ins some modules
authorPhilipp Schüle <p.schuele@metaways.de>
Thu, 2 Jul 2015 11:59:18 +0000 (13:59 +0200)
committerStefanie Stamer <s.stamer@metaways.de>
Thu, 2 Jul 2015 12:15:47 +0000 (14:15 +0200)
removes obsolete activities panel from supppliers, contracts and
purchase invoices edit dialogs

https://forge.tine20.org/view.php?id=11102

Change-Id: Ie834dc427483b56417e22b3b737753d0fda5459a
Reviewed-on: https://gerrit.tine20.org/tine20/3142
Reviewed-by: Stefanie Stamer <s.stamer@metaways.de>
Tested-by: Stefanie Stamer <s.stamer@metaways.de>
tine20/Sales/js/ContractEditDialog.js
tine20/Sales/js/PurchaseInvoiceEditDialog.js
tine20/Sales/js/SupplierEditDialog.js

index b72928a..2e058de 100644 (file)
@@ -32,6 +32,7 @@ Ext.namespace('Tine.Sales');
 Tine.Sales.ContractEditDialog = Ext.extend(Tine.widgets.dialog.EditDialog, {
     windowWidth: 800,
     windowHeight: 600,
+    displayNotes: true,
 
     /**
      * autoset
@@ -65,21 +66,10 @@ Tine.Sales.ContractEditDialog = Ext.extend(Tine.widgets.dialog.EditDialog, {
         this.autoGenerateNumber = (Tine.Sales.registry.get('config').contractNumberGeneration.value == 'auto') ? true : false;
         this.validateNumber = Tine.Sales.registry.get('config').contractNumberValidation.value;
 
-        this.initToolbar();
-        
         Tine.Sales.ContractEditDialog.superclass.initComponent.call(this);
     },
     
     /**
-     * initializes the toolbar
-     */
-    initToolbar: function() {
-        var addNoteButton = new Tine.widgets.activities.ActivitiesAddButton({});
-
-        Tine.Sales.ContractEditDialog.superclass.initToolbar.call(this);
-    },
-    
-    /**
      * called on multiple edit
      *
      * @return {Boolean}
@@ -348,11 +338,7 @@ Tine.Sales.ContractEditDialog = Ext.extend(Tine.widgets.dialog.EditDialog, {
                         })
                     ]
                 }]
-            }, this.productGridPanel, new Tine.widgets.activities.ActivitiesTabPanel({
-                app: this.appName,
-                record_id: this.record.id,
-                record_model: this.appName + '_Model_' + this.recordClass.getMeta('modelName')
-            })]
+            }]
         };
     }
 });
index 45672cf..4ea23c2 100644 (file)
@@ -30,16 +30,11 @@ Tine.Sales.PurchaseInvoiceEditDialog = Ext.extend(Tine.widgets.dialog.EditDialog
     /**
      * @private
      */
-    tbarItems: null,
     evalGrants: false,
     
     windowWidth: 900,
     windowHeight: 700,
-    
-    initComponent: function() {
-        this.tbarItems = [{xtype: 'widget-activitiesaddbutton'}];
-        Tine.Sales.PurchaseInvoiceEditDialog.superclass.initComponent.call(this);
-    },
+    displayNotes: true,
     
     /**
      * is form valid?
@@ -319,7 +314,7 @@ Tine.Sales.PurchaseInvoiceEditDialog = Ext.extend(Tine.widgets.dialog.EditDialog
             name: 'discount',
             decimalSeparator: Tine.Tinebase.registry.get('decimalSeparator'),
             fieldLabel: this.app.i18n._('Discount (%)'),
-            columnWidth: 1/4,
+            columnWidth: 1/4
             //listeners: {
             //    scope: this,
             //    spin: this.calcGross.createDelegate(this),
@@ -351,7 +346,7 @@ Tine.Sales.PurchaseInvoiceEditDialog = Ext.extend(Tine.widgets.dialog.EditDialog
                                 name: 'number',
                                 fieldLabel: this.app.i18n._('Invoice Number'),
                                 columnWidth: 1/4,
-                                allowBlank: false,
+                                allowBlank: false
                                 //readOnly: ! Tine.Tinebase.common.hasRight('set_invoice_number', 'Sales'),
                                 //emptyText: this.app.i18n._('automatically set...')
                             }, {
@@ -376,7 +371,7 @@ Tine.Sales.PurchaseInvoiceEditDialog = Ext.extend(Tine.widgets.dialog.EditDialog
                                     xtype: 'extuxclearabledatefield',
                                     name: 'overdue_at',
                                     fieldLabel: this.app.i18n._('Overdue date'),
-                                    columnWidth: 1/4,
+                                    columnWidth: 1/4
                                     //emptyText: (this.record.get('is_auto') == 1) ? this.app.i18n._('automatically set...') : ''
                             }], [
                                 this.priceNetField,
@@ -390,7 +385,7 @@ Tine.Sales.PurchaseInvoiceEditDialog = Ext.extend(Tine.widgets.dialog.EditDialog
                                     name: 'discount_until',
                                     //allowBlank: false,
                                     fieldLabel: this.app.i18n._('Discount until'),
-                                    columnWidth: 1/4,
+                                    columnWidth: 1/4
                                     //emptyText: (this.record.get('is_auto') == 1) ? this.app.i18n._('automatically set...') : ''
                                 }
                             ]
@@ -411,13 +406,13 @@ Tine.Sales.PurchaseInvoiceEditDialog = Ext.extend(Tine.widgets.dialog.EditDialog
                                     xtype: 'extuxclearabledatefield',
                                     name: 'dunned_at',
                                     fieldLabel: this.app.i18n._('Dun date'),
-                                    columnWidth: 1/4,
+                                    columnWidth: 1/4
                                 }, {
                                     xtype: 'extuxclearabledatefield',
                                     name: 'payed_at',
                                     //allowBlank: false,
                                     fieldLabel: this.app.i18n._('Payed at'),
-                                    columnWidth: 1/4,
+                                    columnWidth: 1/4
                                     //emptyText: (this.record.get('is_auto') == 1) ? this.app.i18n._('automatically set...') : ''
                                 },
                                 // is_payed
@@ -496,12 +491,6 @@ Tine.Sales.PurchaseInvoiceEditDialog = Ext.extend(Tine.widgets.dialog.EditDialog
                             requiredGrant: 'editGrant'
                         }]
                     }),
-                    new Tine.widgets.activities.ActivitiesPanel({
-                        app: 'Sales',
-                        showAddNoteForm: false,
-                        border: false,
-                        bodyStyle: 'border:1px solid #B5B8C8;'
-                    }),
                     new Tine.widgets.tags.TagPanel({
                         app: 'Sales',
                         border: false,
index f53aef9..275637f 100644 (file)
@@ -25,11 +25,7 @@ Ext.ns('Tine.Sales');
 Tine.Sales.SupplierEditDialog = Ext.extend(Tine.widgets.dialog.EditDialog, {
     windowWidth: 900,
     windowHeight: 800,
-    
-    initComponent: function() {
-        this.tbarItems = [{xtype: 'widget-activitiesaddbutton'}];
-        Tine.Sales.SupplierEditDialog.superclass.initComponent.call(this);
-    },
+    displayNotes: true,
     
     /**
      * 
@@ -379,12 +375,6 @@ Tine.Sales.SupplierEditDialog = Ext.extend(Tine.widgets.dialog.EditDialog, {
                             requiredGrant: 'editGrant'
                         }]
                     }),
-                    new Tine.widgets.activities.ActivitiesPanel({
-                        app: 'Sales',
-                        showAddNoteForm: false,
-                        border: false,
-                        bodyStyle: 'border:1px solid #B5B8C8;'
-                    }),
                     new Tine.widgets.tags.TagPanel({
                         app: 'Sales',
                         border: false,