Fixed: Addressed feedback changes

This commit is contained in:
amit sharma
2026-09-16 11:39:02 +05:30
parent fc4da61ab1
commit f4a29d7924
72 changed files with 308 additions and 309 deletions

View File

@@ -184,10 +184,10 @@ class AdminFeaturesControllerCore extends AdminController
$image = "<img class='img-thumbnail img-responsive' style='max-width:100px' src='".$img_url."'>";
}
$this->toolbar_title = $this->l('Add a new stay feature');
$this->toolbar_title = $this->l('Add a new room feature');
$this->fields_form = array(
'legend' => array(
'title' => $this->l('Stay feature'),
'title' => $this->l('Room feature'),
'icon' => 'icon-info-sign'
),
'input' => array(
@@ -197,16 +197,16 @@ class AdminFeaturesControllerCore extends AdminController
'name' => 'name',
'lang' => true,
'size' => 33,
'hint' => $this->l('Enter a name for the stay feature. Invalid characters:').' <>;=#{}',
'hint' => $this->l('Enter a name for the room feature. Invalid characters:').' <>;=#{}',
'required' => true
),
array(
'type' => 'file',
'label' => $this->l('Stay Feature Logo'),
'label' => $this->l('Room Feature Logo'),
'name' => 'logo',
'image' => $img_exist ? $image : false,
'display_image' => true,
'hint' => $this->l('Upload a stay feature logo.'),
'hint' => $this->l('Upload a room feature logo.'),
'required' => true
)
)
@@ -242,13 +242,13 @@ class AdminFeaturesControllerCore extends AdminController
if (empty($this->display)) {
$this->page_header_toolbar_btn['new_feature'] = array(
'href' => self::$currentIndex.'&addfeature&token='.$this->token,
'desc' => $this->l('Add new stay feature', null, null, false),
'desc' => $this->l('Add new room feature', null, null, false),
'icon' => 'process-icon-new'
);
// $this->page_header_toolbar_btn['new_feature_value'] = array(
// 'href' => self::$currentIndex.'&addfeature_value&id_feature='.(int)Tools::getValue('id_feature').'&token='.$this->token,
// 'desc' => $this->l('Add new stay feature value', null, null, false),
// 'desc' => $this->l('Add new room feature value', null, null, false),
// 'icon' => 'process-icon-new'
// );
}
@@ -256,7 +256,7 @@ class AdminFeaturesControllerCore extends AdminController
if ($this->display == 'view') {
$this->page_header_toolbar_btn['new_feature_value'] = array(
'href' => self::$currentIndex.'&addfeature_value&id_feature='.(int)Tools::getValue('id_feature').'&token='.$this->token,
'desc' => $this->l('Add new stay feature value', null, null, false),
'desc' => $this->l('Add new room feature value', null, null, false),
'icon' => 'process-icon-new'
);
}
@@ -302,7 +302,7 @@ class AdminFeaturesControllerCore extends AdminController
case 'view':
$this->toolbar_btn['newAttributes'] = array(
'href' => self::$currentIndex.'&addfeature_value&id_feature='.(int)Tools::getValue('id_feature').'&token='.$this->token,
'desc' => $this->l('Add new stay feature values')
'desc' => $this->l('Add new room feature values')
);
$this->toolbar_btn['back'] = array(
'href' => self::$currentIndex.'&token='.$this->token,
@@ -320,12 +320,12 @@ class AdminFeaturesControllerCore extends AdminController
switch ($this->display) {
case 'edit':
$bread_extended[] = $this->l('Edit New Stay Feature');
$bread_extended[] = $this->l('Edit New Room Feature');
$this->addMetaTitle($bread_extended[count($bread_extended) - 1]);
break;
case 'add':
$bread_extended[] = $this->l('Add New Stay Feature');
$bread_extended[] = $this->l('Add New Room Feature');
$this->addMetaTitle($bread_extended[count($bread_extended) - 1]);
break;
@@ -376,13 +376,13 @@ class AdminFeaturesControllerCore extends AdminController
$this->fields_form[0]['form'] = array(
'legend' => array(
'title' => $this->l('Stay feature value'),
'title' => $this->l('Room feature value'),
'icon' => 'icon-info-sign'
),
'input' => array(
array(
'type' => 'select',
'label' => $this->l('Stay feature'),
'label' => $this->l('Room feature'),
'name' => 'id_feature',
'options' => array(
'query' => Feature::getFeatures($this->context->language->id),
@@ -450,7 +450,7 @@ class AdminFeaturesControllerCore extends AdminController
$helper->allow_employee_form_lang = $this->allow_employee_form_lang;
$helper->fields_value = $this->getFieldsValue($feature_value);
$helper->toolbar_btn = $this->toolbar_btn;
$helper->title = $this->l('Add a new stay feature value');
$helper->title = $this->l('Add a new room feature value');
$this->content .= $helper->generateForm($this->fields_form);
}
@@ -488,7 +488,7 @@ class AdminFeaturesControllerCore extends AdminController
}
} else {
$url = '<a href="index.php?tab=AdminPerformance&token='.Tools::getAdminTokenLite('AdminPerformance').'#featuresDetachables">'.$this->l('Performance').'</a>';
$this->displayWarning(sprintf($this->l('This stay feature has been disabled. You can activate it here: %s.'), $url));
$this->displayWarning(sprintf($this->l('This room feature has been disabled. You can activate it here: %s.'), $url));
}
$this->context->smarty->assign(
@@ -647,7 +647,7 @@ class AdminFeaturesControllerCore extends AdminController
// upload feature image
$imgPath = _PS_IMG_DIR_.'rf/'.$objFeature->id.'.jpg';
if (!ImageManager::resize($featureImage['tmp_name'], $imgPath)) {
$this->errors[] = $this->l('Some error occurred while uploding stay feature logo. Please try again.');
$this->errors[] = $this->l('Some error occurred while uploding room feature logo. Please try again.');
}
}
}