Poprawa obsługi wartości domyślnej i wpływu na cenę w szablonie atrybutów

This commit is contained in:
2025-07-29 14:48:56 +02:00
parent 580a615c54
commit 3a780ca979
2 changed files with 7 additions and 7 deletions

View File

@@ -9,13 +9,13 @@
<div class="row"> <div class="row">
<div class="col-lg-6"> <div class="col-lg-6">
<div class="mb20"> <div class="mb20">
<input type="radio" id="default_value<?=$this -> value['id'];?>" name="default_value" value="<?= ( $this -> i - 1 );?>" <? if ( $this -> value['is_default'] ):?>checked<? endif;?>> <input type="radio" id="default_value<?= $this -> value ? $this -> value['id'] : '0';?>" name="default_value" value="<?= ( $this -> i - 1 );?>" <? if ( $this -> value and $this -> value['is_default'] ):?>checked<? endif;?>>
<label for="default_value<?=$this -> value['id'];?>">Wartość domyślna</label> <label for="default_value<?= $this -> value ? $this -> value['id'] : '0';?>">Wartość domyślna</label>
</div> </div>
<div class="row form-group"> <div class="row form-group">
<div class="col-xs-8"> <div class="col-xs-8">
<div class="input-group"> <div class="input-group">
<input class="form-control" name="impact_on_the_price[]" type="text" value="<?= $this -> value['impact_on_the_price'];?>" placeholder="wpływ na cenę produktu..."> <input class="form-control" name="impact_on_the_price[]" type="text" value="<?= $this -> value ? $this -> value['impact_on_the_price'] : '';?>" placeholder="wpływ na cenę produktu...">
<span class="input-group-addon"> <span class="input-group-addon">
<i class="fa fa-usd"></i> <i class="fa fa-usd"></i>
</span> </span>
@@ -41,8 +41,8 @@
<? if ( $lg['status'] ):?> <? if ( $lg['status'] ):?>
<div id="tab<?= $this -> i;?>_<?= $lg['id'];?>" class="tab-pane <? if ( !$z++ ):?>active<? endif;?>"> <div id="tab<?= $this -> i;?>_<?= $lg['id'];?>" class="tab-pane <? if ( !$z++ ):?>active<? endif;?>">
<? if ( $this -> attribute['type'] == 0 ):?> <? if ( $this -> attribute['type'] == 0 ):?>
<input type="hidden" name="ids[<?= $lg['id'];?>][]" value="<?= $this -> value['id'];?>" /> <input type="hidden" name="ids[<?= $lg['id'];?>][]" value="<?= $this -> value ? $this -> value['id'] : '0';?>" />
<input type="text" class="name-<?= $i;?> form-control" name="name[<?= $lg['id'];?>][]" value="<?= $this -> value['languages'][$lg['id']]['name'];?>"> <input type="text" class="name-<?= $i;?> form-control" name="name[<?= $lg['id'];?>][]" value="<?= $this -> value ? $this -> value['languages'][$lg['id']]['name'] : '';?>">
<? endif;?> <? endif;?>
</div> </div>
<? endif;?> <? endif;?>

View File

@@ -12,8 +12,8 @@ $config['baselinker-start'] = '2021-10-14 22:00:00';
$config['tpay-api-secret'] = '89e2ec5db4aeaf04179228eae597a584f47bb018c7b2f8c71b7f5791cefc91c3'; $config['tpay-api-secret'] = '89e2ec5db4aeaf04179228eae597a584f47bb018c7b2f8c71b7f5791cefc91c3';
$config['redis']['host'] = '127.0.0.1'; $config['redis']['host'] = '127.0.0.1';
$config['redis']['port'] = 7001; $config['redis']['port'] = 16920;
$config['redis']['password'] = 'Tg%79Eex!!ZtJEK'; $config['redis']['password'] = 'QHCq064JeL4XFxGhzN1o6YbHjuLkOP9S';
$config['debug']['apilo'] = false; $config['debug']['apilo'] = false;