%PDF- %PDF-
Direktori : /home/waritko/jetty-distribution-9.4.21.v20190926/webapps/ROOT/skins/flamingo/ |
Current File : //home/waritko/jetty-distribution-9.4.21.v20190926/webapps/ROOT/skins/flamingo/renameStep1.vm |
### ### Rename document template, step 1: choose new name + updated backlinks + updated parents ### ## TODO: check if this information should be displayed? #set($titleToDisplay = $services.localization.render('core.rename.title', [$escapetool.xml($doc.plainTitle), $doc.getURL()])) <div class="xcontent"> #template('contentheader.vm') #template('refactoring_macros.vm') #template('locationPicker_macros.vm') #set ($sourcePageIsTerminal = $doc.documentReference.name != $services.model.getEntityReference('DOCUMENT', 'default').name) <form action="?xpage=rename&step=2" method="post" id="rename" class="xform"> <div class="hidden"> ## CSRF prevention <input type="hidden" name="form_token" value="$!{services.csrf.getToken()}" /> ## Perform the rename asynchronously. <input type="hidden" name="async" value="true" /> </div> <div class="row"> <div class="col-xs-12 col-lg-6"> <dl> ##------------ ## Source Page ##------------ #displaySourceDocument({ 'label': 'core.rename.source.label', 'hint': 'core.rename.source.hint' }) ##--------------- ## Children field ##--------------- #displayChildrenCheckbox({ 'label': 'core.rename.children.label', 'hint': 'core.rename.children.hint' }) ##------------ ## Links field ##------------ #displayLinksCheckbox({ 'label': 'core.rename.links.label', 'hint': 'core.rename.links.hint' }) ##-------------------- ## Auto redirect field ##-------------------- ## We set Autoredirect to off by default for the following reasons: ## - Several users have reported a usability issue about automatic redirects. The way they express it is the ## following: "I have duplicates pages in my wiki. I don't understand why this is happening. I'm choosing to ## rename pages and not to copy them but I still get duplicates in the Navigation panel". ## - Automatic redirects are especially useful for public wikis where users can have bookmark on pages and you ## don't want to break them. It can also be useful for internal wikis but it's less an issue. ## - Even for public wikis not all pages need automatic redirects. Technical pages don't need them for example. ## - We don't have management UIs for redirects FTM and reducing the number of redirects make the wiki easier ## to manage. ## In the future we'll offer a config option to define the default behavior, see ## http://jira.xwiki.org/browse/XWIKI-13384 #set ($checked = $request.autoRedirect == 'true') <dt> <label> <input type="checkbox" name="autoRedirect" value="true" #if ($checked)checked="checked"#end /> $services.localization.render('core.rename.autoRedirect.label') </label> ## The value submitted when the checkbox is not checked, used to preserve the form state. <input type="hidden" name="autoRedirect" value="false" /> </dt> <dd> <span class="xHint">$services.localization.render('core.rename.autoRedirect.hint')</span> </dd> </dl> </div> <div class="col-xs-12 col-lg-6"> ##------------ ## Target Page ##------------ #set ($parentReference = $doc.documentReference.parent) #set ($name = $doc.documentReference.name) #if (!$sourcePageIsTerminal) #set ($name = $parentReference.name) #set ($parentReference = $parentReference.parent) #end #locationPicker({ 'id': 'target', 'title': { 'label': 'core.rename.target.title.label', 'hint': 'core.rename.target.title.hint', 'name': 'newPageTitle', 'value': $doc.plainTitle, 'placeholder': 'core.create.name.placeholder' }, 'preview': { 'label': 'core.rename.target.location.label', 'hint': 'core.rename.target.location.hint' }, 'wiki': { 'label': 'core.rename.target.wiki.label', 'hint': 'core.rename.target.wiki.hint', 'name': 'newWikiName', 'value': $doc.wiki }, 'parent': { 'label': 'core.rename.target.parent.label', 'hint': 'core.rename.target.parent.hint', 'name': 'newSpaceName', 'reference': $parentReference, 'placeholder': 'core.create.spaceReference.placeholder' }, 'name': { 'label': 'core.rename.target.name.label', 'hint': 'core.rename.target.name.hint', 'name': 'newPageName', 'value': $name, 'placeholder': 'core.create.name.placeholder' } }) ## ------------------------------------- ## Target Page Type (for advanced users) ## ------------------------------------- #maybeDisplayTerminalCheckbox({ 'label': 'core.rename.target.terminal.label', 'hint': 'core.rename.target.terminal.hint' }) </div> </div> <div class="buttons"> <span class="buttonwrapper"> <input type="submit" value="$services.localization.render('core.rename.submit')" class="button" /> </span> <span class="buttonwrapper"> <a class="secondary button" href="$doc.getURL()">$services.localization.render('cancel')</a> </span> </div> </form> </div>