|
|
@@ -3333,7 +3333,7 @@ jQuery(document).ready(function(){
|
|
|
<?php
|
|
|
//}
|
|
|
|
|
|
- $oferty_opcje_all = PokazOfertyHelper::get_oferty_opcje_all($building);
|
|
|
+ $oferty_opcje_all = PokazOfertyHelper::get_oferty_opcje_all($building, $com = $oferty_filters['f_COM']['value']);
|
|
|
$oferty_opcje_cols = PokazOfertyHelper::get_oferty_opcje_visible_cols();
|
|
|
//echo'<pre style="max-height:200px;overflow:auto;border:1px solid red;">$oferty_opcje: ';print_r($oferty_opcje);echo'</pre>';
|
|
|
//echo'<pre style="max-height:200px;overflow:auto;border:1px solid red;">';print_r($oferty_group_add_info ['labels']);echo'</pre>';
|
|
|
@@ -4820,7 +4820,21 @@ class PokazOfertyHelper {
|
|
|
return $oferty_opcje;
|
|
|
}
|
|
|
|
|
|
- public static function get_oferty_opcje_all($building) {
|
|
|
+ public static function get_oferty_opcje_all($building, $com = '') {
|
|
|
+ // [f_COM] => Array:
|
|
|
+ // [label] => COMPANY
|
|
|
+ // [values] => Array:
|
|
|
+ // [BIALL-NET] => t0.`P_SERVICE_COMPANY`='BN'
|
|
|
+ // [NETDAY] => t0.`P_SERVICE_COMPANY`='NETDAY'
|
|
|
+ // [default] => BIALL-NET
|
|
|
+ // [value] => NETDAY
|
|
|
+ $sql_where_rewir_add_company = '';
|
|
|
+ if ($com == 'BIALL-NET') {
|
|
|
+ $sql_where_rewir_add_company = " and o.`P_SERVICE_COMPANY`='BN' ";
|
|
|
+ } else if ($com == 'NETDAY') {
|
|
|
+ $sql_where_rewir_add_company = " and o.`P_SERVICE_COMPANY`='NETDAY' ";
|
|
|
+ }
|
|
|
+
|
|
|
$db = DB::getDB();
|
|
|
$oferty_opcje = array();// [ service ] => array(ID => {oferta})
|
|
|
$oferty_costs = self::get_offers_costs_by_offer_ids();
|
|
|
@@ -4864,7 +4878,7 @@ class PokazOfertyHelper {
|
|
|
from `USERS2_OFFERS` as o
|
|
|
where o.`P_SERVICE` in('OPCJE', 'OPCJA_TVC', 'OPCJA_TEL')
|
|
|
{$sqlStatus}
|
|
|
- and o.`P_SERVICE_COMPANY`='BN'
|
|
|
+ {$sql_where_rewir_add_company}
|
|
|
{$sqlRewir}
|
|
|
order by o.`ID_PRODUKT` desc, o.`P_CONTRACT_PRICE` desc
|
|
|
";
|