|
|
(7 intermediate revisions by 3 users not shown) |
Line 9: |
Line 9: |
| </noinclude><includeonly><!-- | | </noinclude><includeonly><!-- |
| | | |
− | -->{{#vardefine:@allow sidebar edit |{{#ifingroup:user |{{#if:{{#urlget:veaction}}{{#urlget:action}}||yes}} }} }}<!-- | + | -->{{Csp default sidebar |
− | | + | |$pageData={{{$pageData|}}} |
− | --><div class="tab-content">
| + | |$classData={{{$classData|}}} |
− | <div class="card tab-pane fade show active" id="sidebar-view">
| |
− | <div class="card-header">{{#ifeq:{{#var:@allow sidebar edit}} |yes |<span style="float:right">{{#widget:Button link |class=btn btn-secondary |buttontext=Edit |onclick=ShowTab('#sidebar-edit') }}</span>}}
| |
− | <b class="d-block">{{#caprint:$base[Base properties][Class]}}</b>
| |
− | {{#caprint:$base[Base properties][Title]}} | |
− | </div><!-- end of .card-header -->
| |
− | <div class="card-body">
| |
− | {{Sidebar item
| |
− | |Value={{#caprint:$class[Page properties][Short description]}}
| |
− | |Cols=0-12
| |
| }} | | }} |
− | </div><!-- end of .card-body -->
| + | {{Show SEO in sidebar}}<!-- |
− | </div><!-- end of .card
| |
− | | |
− | -->{{#ifeq:{{#var:@allow sidebar edit}} |yes |<wsform action="addToWiki" class="tab-pane fade" id="sidebar-edit">
| |
− | <div class="card"><!--
| |
− | | |
− | // wsedits for base properties
| |
− | -->{{#tag:wsedit ||target={{PAGEID}} |template=Base properties |formfield=Title |mwslot=ws-base-props}}<!--
| |
− | | |
− | // wscreate or wsedits for page properties
| |
− | // use casize to check if the slot already exists. Then wsedit, else wscreate.
| |
− | -->{{#if:{{#casize:$class}}
| |
− | |{{#tag:wsedit ||target={{PAGEID}} |template=Page properties |formfield=Short description |mwslot=ws-class-props}}
| |
− | |<wscreate mwwrite="{{FULLPAGENAME}}" mwtemplate="Page properties" mwslot="ws-class-props" mwfields="Short description" />
| |
− | }}<!-- end of #if -->
| |
− | | |
− | <div class="card-header"><span style="float:right">{{#widget:Button link |class=btn btn-secondary |buttontext=Close |onclick=ShowTab('#sidebar-view') }}</span>
| |
− | <b class="d-block">{{#caprint:$base[Base properties][Class]}}</b>
| |
− | {{#caprint:$base[Base properties][Title]}}
| |
− | </div><!-- end of .card-header -->
| |
− | <div class="card-body">
| |
− | {{Sidebar item
| |
− | |Label=Title
| |
− | |Value={{#tag:wsfield ||type=text |name=Title |required=required |class=form-control |value={{#caprint:$base[Base properties][Title]}} }}
| |
− | }}
| |
− | {{Sidebar item
| |
− | |Label=Short description
| |
− | |Value={{#tag:wsfield ||type=textarea |name=Short description |class=form-control |value={{#caprint:$class[Page properties][Short description]}} }}
| |
− | }}
| |
− | | |
− | <div class="text-right">
| |
− | {{#widget:Button link |class=btn btn-secondary |buttontext=Close |onclick=ShowTab('#sidebar-view') }} | |
− | <wsfield type="submit" value="Save" class="btn btn-primary" />
| |
− | </div>
| |
− | </div><!-- end of .card-body -->
| |
− | </div><!-- end of .card -->
| |
− | </wsform>|}}<!-- end of #ifeq @allow sidebar edit == yes -->
| |
− | </div><!-- end of .tab-content
| |
| | | |
| --></includeonly> | | --></includeonly> |