partkeepr

fork of partkeepr
git clone https://git.e1e0.net/partkeepr.git
Log | Files | Refs | Submodules | README | LICENSE

PartStockHistory.js (609B)


      1 Ext.define('PartKeepr.PartStockHistory', {
      2     extend: 'PartKeepr.AbstractStockHistoryGrid',
      3     alias: 'widget.PartStockHistory',
      4 
      5     part: null,
      6 
      7     initComponent: function ()
      8     {
      9         this.callParent();
     10 
     11         this.on("activate", this.onActivate, this);
     12     },
     13     /**
     14      * Called when the view is activated.
     15      */
     16     onActivate: function ()
     17     {
     18         var filter = Ext.create("PartKeepr.util.Filter", {
     19             property: 'part',
     20             operator: '=',
     21             value: this.part
     22         });
     23 
     24         this.store.clearFilter(true);
     25         this.store.addFilter(filter);
     26     }
     27 });