Render Admin Quick Form Edit
Form to allow Admin users to quickly edit all fields in form on any topic

07 July 2020 - 15:58 | Version 2 |

Documentation

Implementation

%STARTINCLUDE%%IF{"'%BASEWEB%.%BASETOPIC%'/form.name != ''" 
   then="<a href='$percntSCRIPTURL{view}$percnt/%WEB%/%TOPIC%?skin=text;section=editform;SOURCE=%BASEWEB%.%BASETOPIC%' class='jqUIDialogLink {modal:true}'><img src='$percntICONURL{uweb-bo12}$percnt'> Quick Edit Form</a> $percntJQREQUIRE{\"ui::dialog, ui::button\"}$percnt"}%%STOPINCLUDE%

Edit Form

Parameters:
  • SOURCE - Topic referenced for form.

%STARTSECTION{"editform"}%%JQTHEME{"foswiki"}%
<div title="Quick Edit form" class="jqUIDialog { modal:true, resizable:true, draggable:true, width:800, maxWidth: 800, autoCenter:true }">
<form name='quickEditForm' id='quickEditForm' action='%SCRIPTURL{"save"}%/%URLPARAM{"SOURCE"}%' method='post' >
%RENDERFOREDIT{topic="%URLPARAM{"SOURCE"}%" 
  form="%QUERY{"'%URLPARAM{"SOURCE"}%'/form.name"}%"
  format="<div class='foswikiFormStep'> 
    $n<label>$title:</label> $percntIF{\"'$type'='textarea'\" 
      then=\"<br /><textarea name='$name' rows='5' cols='70'>$value</textarea>\" 
      else=\"<input type='text' name='$name' size='50' value='$value' >\" 
     }$percnt </div>" 
  separator=" $n" 
  include=".*"
  autolink="off" 
  hideempty="off"
}%
  <a class="jqUIDialogButton jqUIDialogSubmit jqUIDialogClose {icon:'ui-icon-circle-check'}" >%MAKETEXT{"Save"}%</a>
  <a class="jqUIDialogButton jqUIDialogClose {icon:'ui-icon-cancel'}">%MAKETEXT{"Cancel"}%</a>
</form>
</div>
%ENDSECTION{"editform"}%

Test

Quick Edit Form

© 2024 Lynnwood Brown

This file is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version. For more details read the LICENSE.

This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY, to the extent permitted by law; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

This site is powered by FoswikiCopyright © by the contributing authors. All material on this collaboration platform is the property of the contributing authors.
Ideas, requests, problems regarding Middle Fork Home Wiki? Send feedback
Syndicate this site RSS