Changes for page ClassEditSheet
Last modified by Richard Johnson on 2021/05/07 19:19
Change comment:
Install extension [org.xwiki.platform:xwiki-platform-appwithinminutes-ui/11.2]
Summary
Details
- Page properties
-
- Content
-
... ... @@ -97,7 +97,6 @@ 97 97 #set ($fieldURL = $doc.getURL('edit', $escapetool.url({ 98 98 'xpage': 'plain', 99 99 'sheet': 'AppWithinMinutes.ClassEditSheet', 100 - 'template': 'AppWithinMinutes.ClassTemplate', 101 101 'field': $formFieldDoc.fullName, 102 102 'xeditmode': 'text' 103 103 }))) ... ... @@ -292,18 +292,12 @@ 292 292 #** 293 293 * Displays the input used to edit the specified property of the given object. The given object can be either an 294 294 * instance of an XWiki class or a class field. In the first case the property represents an object field and in the 295 - * second case the property represents a field meta property. We currently don't use custom display for metaproperty, 296 - * so in that case we fallback on displayEdit. 294 + * second case the property represents a field meta property. 297 297 *# 298 298 #macro (displayPropertyEditInput $property $prefix $object) 299 299 #set ($wrappedProperty = $property.propertyClass) 300 300 #if ($wrappedProperty.isCustomDisplayed($xcontext.context)) 301 - #set ($customDisplayer = $!xcontext.get('propertyCustomDisplayer').display($property, $prefix, $object)) 302 - #if ((! $customDisplayer) && ("$!customDisplayer" == "")) 303 - $doc.displayEdit($property, $prefix, $object) 304 - #else 305 - $customDisplayer 306 - #end 299 + $xcontext.get('propertyCustomDisplayer').display($property, $prefix, $object) 307 307 #else 308 308 $doc.displayEdit($property, $prefix, $object) 309 309 #end ... ... @@ -388,7 +388,6 @@ 388 388 * Display the edit class form. 389 389 *# 390 390 #macro (displayEditForm) 391 - #set ($discard = $xwiki.jsfx.use('js/scriptaculous/effects.js')) 392 392 #set ($discard = $xwiki.jsfx.use('js/scriptaculous/dragdrop.js')) 393 393 #set ($discard = $xwiki.jsx.use('AppWithinMinutes.ClassEditSheet')) 394 394 #set ($discard = $xwiki.ssx.use('AppWithinMinutes.ClassEditSheet')) ... ... @@ -439,7 +439,10 @@ 439 439 #try() 440 440 #set ($discard = $copyAsJob.join()) 441 441 #set ($copyAsJobStatus = $services.job.getJobStatus($copyAsJob.request.id)) 442 - #set ($errorMessage = $copyAsJobStatus.logTail.getFirstLogEvent('ERROR').toString()) 434 + #set ($errorLogs = $copyAsJobStatus.log.getLogs('ERROR')) 435 + #if ($errorLogs.size() > 0) 436 + #set ($errorMessage = $errorLogs.get(0).toString()) 437 + #end 443 443 #end 444 444 #end 445 445 #end ... ... @@ -619,10 +619,6 @@ 619 619 #set($discard = $sheetDoc.setParent($doc.documentReference.name)) 620 620 #set($discard = $sheetDoc.setContent($doc.getRenderedContent($sheetGeneratorDoc.content, 621 621 $sheetGeneratorDoc.syntax.toIdString(), 'plain/1.0'))) 622 - ## We assume for now that the output produced by the sheet generator uses the same syntax as the code of the sheet 623 - ## generator. We have to set the syntax because the default wiki syntax (used when creating new wiki pages) could 624 - ## be different than the one used by the sheet generator. 625 - #set($discard = $sheetDoc.setSyntax($sheetGeneratorDoc.syntax)) 626 626 #set($discard = $sheetDoc.setHidden(true)) 627 627 #set($discard = $sheetDoc.save($services.localization.render('platform.appwithinminutes.classEditorSheetSaveComment'), 628 628 $minorEdit)) ... ... @@ -648,7 +648,6 @@ 648 648 #set($translationsGeneratorDoc = $xwiki.getDocument('AppWithinMinutes.ClassTranslationsGenerator')) 649 649 #set($discard = $translationsDoc.setContent($doc.getRenderedContent($translationsGeneratorDoc.content, 650 650 $translationsGeneratorDoc.syntax.toIdString(), 'plain/1.0'))) 651 - #set($discard = $translationsDoc.setSyntaxId('plain/1.0')) 652 652 #set($discard = $translationsDoc.setHidden(true)) 653 653 #set($discard = $translationsDoc.save( 654 654 $services.localization.render('platform.appwithinminutes.classEditorTranslationsSaveComment'),