mirror of
https://github.com/silverstripe/silverstripe-cms
synced 2024-10-22 08:05:56 +02:00
Merge pull request #217 from ryanwachtl/fixing-update-url-from-title
BUG Fixing Update URLSegment from Title behavior.
This commit is contained in:
commit
0a92c81002
@ -29,7 +29,7 @@
|
||||
|
||||
var form = self.parents('form');
|
||||
var url_segment = $('.field.urlsegment', form).find(':text');
|
||||
var live_url_segment = $('input[name=LiveURLSegment]', form);
|
||||
var live_link = $('input[name=LiveLink]', form);
|
||||
|
||||
self._addActions();
|
||||
|
||||
@ -40,7 +40,7 @@
|
||||
self.data('OrigVal', title);
|
||||
|
||||
// Criteria for defining a "new" page
|
||||
if ((url_segment.val().indexOf('new') == 0) && live_url_segment.val() == '') {
|
||||
if ((url_segment.val().indexOf('new') == 0) && live_link.val() == '') {
|
||||
self.updateURLSegment(title);
|
||||
} else {
|
||||
$('.update', self.parent()).show();
|
||||
|
Loading…
Reference in New Issue
Block a user