[-] BO : Do not copy link_rewrite from title if cms already has one
This commit is contained in:
@@ -110,10 +110,10 @@ class AdminCmsControllerCore extends AdminController
|
|||||||
'type' => 'text',
|
'type' => 'text',
|
||||||
'label' => $this->l('Meta title:'),
|
'label' => $this->l('Meta title:'),
|
||||||
'name' => 'meta_title',
|
'name' => 'meta_title',
|
||||||
'id' => 'name', // for copy2friendlyUrl compatibility
|
'id' => 'name', // for copyMeta2friendlyURL compatibility
|
||||||
'lang' => true,
|
'lang' => true,
|
||||||
'required' => true,
|
'required' => true,
|
||||||
'class' => 'copy2friendlyUrl',
|
'class' => 'copyMeta2friendlyURL',
|
||||||
'hint' => $this->l('Invalid characters:').' <>;=#{}',
|
'hint' => $this->l('Invalid characters:').' <>;=#{}',
|
||||||
'size' => 50
|
'size' => 50
|
||||||
),
|
),
|
||||||
|
|||||||
+2
-1
@@ -119,7 +119,8 @@ function copy2friendlyURL()
|
|||||||
|
|
||||||
function copyMeta2friendlyURL()
|
function copyMeta2friendlyURL()
|
||||||
{
|
{
|
||||||
$('#input_link_rewrite_' + id_language).val(str2url($('#name_' + id_language).val().replace(/^[0-9]+\./, ''), 'UTF-8'));
|
if (!$('input[name="id_cms"]').length)
|
||||||
|
$('#link_rewrite_' + id_language).val(str2url($('#name_' + id_language).val().replace(/^[0-9]+\./, ''), 'UTF-8'));
|
||||||
}
|
}
|
||||||
|
|
||||||
function updateCurrentText()
|
function updateCurrentText()
|
||||||
|
|||||||
Reference in New Issue
Block a user