Skip to content

Commit

Permalink
chagpt impovment
Browse files Browse the repository at this point in the history
  • Loading branch information
ClicShopping committed Mar 20, 2023
1 parent 23635ae commit 36d0e2d
Show file tree
Hide file tree
Showing 28 changed files with 809 additions and 517 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
3.417
Improve Chatgpt
Fix manufacturer bug

--------------------
3.416
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -233,6 +233,7 @@ class="col-5 col-form-label"><?php echo $CLICSHOPPING_Categories->getDef('text_e
<div class="accordion" id="accordionExample">
<?php
for ($i = 0, $n = \count($languages); $i < $n; $i++) {
$languages_id = $languages[$i]['id'];
?>
<div class="accordion-item">
<h2 class="accordion-header" id="heading<?php $i; ?>">
Expand Down Expand Up @@ -264,36 +265,36 @@ class="col-1 col-form-label"><?php echo $CLICSHOPPING_Categories->getDef('text_c
</div>

<div class="separator"></div>
<div class="row" id="categoriesSeoTitle<?php echo $i; ?>">
<div class="row" id="categoriesSeoTitle<?php echo $languages_id; ?>">
<div class="col-md-10">
<div class="form-group row" data-index="<?php echo $i; ?>">
<div class="form-group row" data-index="<?php echo $languages_id; ?>">
<label for="<?php echo $CLICSHOPPING_Categories->getDef('text_products_page_title'); ?>" class="col-5 col-form-label"><?php echo $CLICSHOPPING_Categories->getDef('text_products_page_title'); ?></label>
<div class="col-md-7 input-group" id="categories_head_title_tag<?php echo $i; ?>">
<?php echo '&nbsp;' . HTML::inputField('categories_head_title_tag[' . $languages[$i]['id'] . ']', SeoAdmin::getcategoriesSeoTitle($cInfo->categories_id, $languages[$i]['id']), 'maxlength="70" size="77" id="categories_head_title_tag_' . $i . '"', false); ?>
<div class="col-md-7 input-group" id="categories_head_title_tag<?php echo $languages_id; ?>">
<?php echo HTML::inputField('categories_head_title_tag[' . $languages[$i]['id'] . ']', SeoAdmin::getcategoriesSeoTitle($cInfo->categories_id, $languages[$i]['id']), 'maxlength="70" size="77" id="categories_head_title_tag_' . $languages_id . '"', false); ?>
</div>
</div>
</div>
</div>

<div class="separator"></div>
<div class="row" id="categoriesSeoDescription<?php echo $i; ?>">
<div class="row" id="categoriesSeoDescription<?php echo $languages_id; ?>">
<div class="col-md-6">
<div class="form-group row" data-index="<?php echo $i; ?>">
<label for="<?php echo $CLICSHOPPING_Categories->getDef('text_products_header_description'); ?>" class="col-1 col-form-label"><?php echo $CLICSHOPPING_Categories->getDef('text_products_header_description'); ?></label>
<div class="col-md-8 input-group" id="categories_head_desc_tag<?php echo $i; ?>">
<?php echo HTML::textAreaField('categories_head_desc_tag[' . $languages[$i]['id'] . ']', SeoAdmin::getcategoriesSeoDescription($cInfo->categories_id, $languages[$i]['id']), '110', '5', 'id="categories_head_desc_tag_' . $i . '"'); ?>
<div class="form-group row" data-index="<?php echo $languages_id; ?>">
<label for="<?php echo $CLICSHOPPING_Categories->getDef('text_products_header_description'); ?>" class="col-5 col-form-label"><?php echo $CLICSHOPPING_Categories->getDef('text_products_header_description'); ?></label>
<div class="col-md-8 input-group" id="categories_head_desc_tag<?php echo $languages_id; ?>">
<?php echo HTML::textAreaField('categories_head_desc_tag[' . $languages[$i]['id'] . ']', SeoAdmin::getcategoriesSeoDescription($cInfo->categories_id, $languages[$i]['id']), '110', '5', 'id="categories_head_desc_tag_' . $languages_id . '"'); ?>
</div>
</div>
</div>
</div>

<div class="separator"></div>
<div class="row" id="categoriesSeoKeywords<?php echo $i; ?>">
<div class="row" id="categoriesSeoKeywords<?php echo $languages_id; ?>">
<div class="col-md-10">
<div class="form-group row" data-index="<?php echo $i; ?>">
<div class="form-group row" data-index="<?php echo $languages_id; ?>">
<label for="<?php echo $CLICSHOPPING_Categories->getDef('text_products_keywords'); ?>" class="col-5 col-form-label"><?php echo $CLICSHOPPING_Categories->getDef('text_products_keywords'); ?></label>
<div class="col-md-7 input-group" id="categories_head_keywords_tag<?php echo $i; ?>">
<?php echo HTML::inputField('categories_head_keywords_tag[' . $languages[$i]['id'] . ']', SeoAdmin::getCategoriesSeoKeywords($cInfo->categories_id, $languages[$i]['id']), 'maxlength="70" size="77" id="categories_head_keywords_tag_' . $i . '"', false); ?>
<div class="col-md-7 input-group" id="categories_head_keywords_tag<?php echo $languages_id; ?>">
<?php echo HTML::inputField('categories_head_keywords_tag[' . $languages[$i]['id'] . ']', SeoAdmin::getCategoriesSeoKeywords($cInfo->categories_id, $languages[$i]['id']), 'maxlength="70" size="77" id="categories_head_keywords_tag_' . $languages_id . '"', false); ?>
</div>
</div>
</div>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ public static function getManufacturerNameById(int $id) :string
* @param int|null $id
* @return mixed
*/
public static function getManufacturerName(?int $id = null):array|string
public static function getManufacturerName(?int $id = null) :array|string
{
$CLICSHOPPING_Db = Registry::get('Db');

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -272,6 +272,7 @@ class="float-start"><?php echo $CLICSHOPPING_Manufacturers->getDef('title_manufa
echo $CLICSHOPPING_Wysiwyg::getWysiwyg();

for ($i = 0, $n = \count($languages); $i < $n; $i++) {
$languages_id = $languages[$i]['id'];
?>
<div class="accordion-item">
<h2 class="accordion-header" id="heading<?php $i; ?>">
Expand All @@ -290,36 +291,36 @@ class="float-start"><?php echo $CLICSHOPPING_Manufacturers->getDef('title_manufa
<div id="collapseOne" class="accordion-collapse collapse <?php echo $show; ?>" aria-labelledby="heading<?php $i; ?>" data-bs-parent="#accordionExample">
<div class="accordion-body">
<div class="separator"></div>
<div class="row" id="manufacturerSeoTitle<?php echo $i; ?>">
<div class="row" id="manufacturerSeoTitle<?php echo $languages_id; ?>">
<div class="col-md-10">
<div class="form-group row" data-index="<?php echo $i; ?>">
<div class="form-group row" data-index="<?php echo $languages_id; ?>">
<label for="<?php echo $CLICSHOPPING_Manufacturers->getDef('text_manufacturer_seo_title'); ?>" class="col-5 col-form-label"><?php echo $CLICSHOPPING_Manufacturers->getDef('text_manufacturer_seo_title'); ?></label>
<div class="col-md-7 input-group" id="manufacturer_seo_title<?php echo $i; ?>">
<?php echo HTML::inputField('manufacturer_seo_title[' . $languages[$i]['id'] . ']', SeoAdmin::getManufacturerSeoTitle($Qmanufacturers->valueInt('manufacturers_id') ?? null, $languages[$i]['id']), 'maxlength="70" size="77" id="manufacturer_seo_title_' . $i . '"', false); ?>
<div class="col-md-7 input-group" id="manufacturer_seo_title<?php echo $languages_id; ?>">
<?php echo HTML::inputField('manufacturer_seo_title[' . $languages_id . ']', SeoAdmin::getManufacturerSeoTitle($Qmanufacturers->valueInt('manufacturers_id') ?? null, $languages_id), 'maxlength="70" size="77" id="manufacturer_seo_title_' . $languages_id . '"', false); ?>
</div>
</div>
</div>
</div>

<div class="separator"></div>
<div class="row" id="manufacturerSeoDescription<?php echo $i; ?>">
<div class="row" id="manufacturerSeoDescription<?php echo $languages_id; ?>">
<div class="col-md-6">
<div class="form-group row" data-index="<?php echo $i; ?>">
<div class="form-group row" data-index="<?php echo $languages_id; ?>">
<label for="<?php echo $CLICSHOPPING_Manufacturers->getDef('title_manufacturer_seo_description'); ?>" class="col-1 col-form-label"><?php echo $CLICSHOPPING_Manufacturers->getDef('title_manufacturer_seo_description'); ?></label>
<div class="col-md-8 input-group" id="manufacturer_seo_description<?php echo $i; ?>">
<?php echo HTML::textAreaField('manufacturer_seo_description[' . $languages[$i]['id'] . ']', SeoAdmin::getManufacturerSeoDescription($Qmanufacturers->valueInt('manufacturers_id') ?? null, $languages[$i]['id']), '110', '5', 'id="manufacturer_seo_description_' . $i . '"'); ?>
<div class="col-md-8 input-group" id="manufacturer_seo_description<?php echo $languages_id; ?>">
<?php echo HTML::textAreaField('manufacturer_seo_description[' . $languages_id . ']', SeoAdmin::getManufacturerSeoDescription($Qmanufacturers->valueInt('manufacturers_id') ?? null, $languages_id), '110', '5', 'id="manufacturer_seo_description_' . $languages_id . '"'); ?>
</div>
</div>
</div>
</div>

<div class="separator"></div>
<div class="row" id="manufacturerSeoKeywords<?php echo $i; ?>">
<div class="row" id="manufacturerSeoKeywords<?php echo $languages_id; ?>">
<div class="col-md-10">
<div class="form-group row" data-index="<?php echo $i; ?>">
<div class="form-group row" data-index="<?php echo $languages_id; ?>">
<label for="<?php echo $CLICSHOPPING_Manufacturers->getDef('title_manufacturer_seo_keywords'); ?>" class="col-5 col-form-label"><?php echo $CLICSHOPPING_Manufacturers->getDef('title_manufacturer_seo_keywords'); ?></label>
<div class="col-md-7 input-group" id="manufacturer_seo_keyword<?php echo $i; ?>">
<?php echo HTML::inputField('manufacturer_seo_keyword[' . $languages[$i]['id'] . ']', SeoAdmin::getManufacturerSeoKeyword($Qmanufacturers->valueInt('manufacturers_id') ?? null, $languages[$i]['id']), 'maxlength="70" size="77" id="manufacturer_seo_keyword_' . $i . '"', false); ?>
<div class="col-md-7 input-group" id="manufacturer_seo_keyword<?php echo $languages_id; ?>">
<?php echo HTML::inputField('manufacturer_seo_keyword[' . $languages_id . ']', SeoAdmin::getManufacturerSeoKeyword($Qmanufacturers->valueInt('manufacturers_id') ?? null, $languages_id), 'maxlength="70" size="77" id="manufacturer_seo_keyword_' . $languages_id . '"', false); ?>
</div>
</div>
</div>
Expand Down
Loading

0 comments on commit 36d0e2d

Please sign in to comment.