Prechádzať zdrojové kódy

[FIX] ajuste en el pdf

Rodney Elpidio Enciso Arias 6 rokov pred
rodič
commit
11629ca28f

+ 19 - 9
static/src/js/reports/report_stock_athletic.js

@@ -686,15 +686,25 @@ function report_stock_athletic(reporting){
           var state = self.$el.find('#current-state').val();
           var filter = [];
 
-          if(company && company){
-            var ResCompany = _.filter(self.ResCompany, function(item){
-              return item.id == company;
-            });
-            filter.push({
-              title:'Empresa',
-              value: ResCompany[0].name,
-            });
-          }
+            if(company && company){
+                if(company && company != 9999999){
+                    var ResCompany = _.filter(self.ResCompany, function(item){
+                        return item.id == company;
+                    });
+                    filter.push({
+                      title:'Empresa',
+                      value: ResCompany[0].name,
+                    });
+                }else{
+                    var ResCompany = self.ResCompany[0].name;
+                    filter.push({
+                        title:'Empresa',
+                        value: ResCompany,
+                    });
+                }
+
+
+            }
 
           if(location && location != 9999999){
             var StockLocation =  _.filter(self.StockLocation,function (item) {