diff options
Diffstat (limited to 'view')
31 files changed, 191 insertions, 145 deletions
diff --git a/view/css/mod_settings.css b/view/css/mod_settings.css index 4236b3dff..d8786eed2 100644 --- a/view/css/mod_settings.css +++ b/view/css/mod_settings.css @@ -9,20 +9,3 @@ .channel-menu { margin-top: 24px; } - -.zat-example { - color: red; -} - -#atoken-index { - width: 100%; -} - -#atoken-index td:nth-child(1){ - padding: 7px 3px 7px 10px; - white-space: nowrap; -} - -.atoken-index-tool { - padding: 7px 10px; -} diff --git a/view/css/mod_tokens.css b/view/css/mod_tokens.css new file mode 100644 index 000000000..ac3bd90d7 --- /dev/null +++ b/view/css/mod_tokens.css @@ -0,0 +1,16 @@ +.zat-example { + color: red; +} + +#atoken-index { + width: 100%; +} + +#atoken-index td:nth-child(1){ + padding: 7px 3px 7px 10px; + white-space: nowrap; +} + +.atoken-index-tool { + padding: 7px 10px; +} diff --git a/view/js/main.js b/view/js/main.js index 17f94dd16..48277f5cc 100644 --- a/view/js/main.js +++ b/view/js/main.js @@ -41,6 +41,8 @@ $.ajaxSetup({cache: false}); $(document).ready(function() { $(document).on('click focus', '.comment-edit-form', handle_comment_form); + $(document).on('click', '.conversation-settings-link', getConversationSettings); + $(document).on('click', '#settings_module_ajax_submit', postConversationSettings); jQuery.timeago.settings.strings = { prefixAgo : aStr['t01'], @@ -122,6 +124,33 @@ $(document).ready(function() { }); +function getConversationSettings() { + $.get('settings/conversation/?f=&aj=1',function(data) { + $('#conversation_settings_body').html(data); + }); + + + +} + +function postConversationSettings() { + $.post( + 'settings/conversation', + $('#settings_module_ajax_form').serialize() + "&auto_update=" + next_page + ); + + if(next_page === 1) { + page_load = true; + } + + $('#conversation_settings').modal('hide'); + + if(timer) clearTimeout(timer); + timer = setTimeout(updateInit,100); + + return false; +} + function datasrc2src(selector) { $(selector).each(function(i, el) { $(el).attr("src", $(el).data("src")); diff --git a/view/pdl/mod_uexport.pdl b/view/pdl/mod_uexport.pdl index 37c85c765..ed1f77c5a 100644 --- a/view/pdl/mod_uexport.pdl +++ b/view/pdl/mod_uexport.pdl @@ -1,5 +1,4 @@ [region=aside] -[widget=settings_menu][/widget] [/region] [region=right_aside] [widget=notifications][/widget] diff --git a/view/theme/redbasic/css/style.css b/view/theme/redbasic/css/style.css index a9ea29ba1..4f0658477 100644 --- a/view/theme/redbasic/css/style.css +++ b/view/theme/redbasic/css/style.css @@ -1677,11 +1677,9 @@ dl.bb-dl > dd > li { .form-group.checkbox > div > input:disabled + label .onoffswitch-switch { - background-color: red; - border-radius: 3px; + background-color: red; opacity: 0.3; filter:alpha(opacity=30); - } diff --git a/view/theme/redbasic/php/config.php b/view/theme/redbasic/php/config.php index f98182739..0a779529d 100644 --- a/view/theme/redbasic/php/config.php +++ b/view/theme/redbasic/php/config.php @@ -54,6 +54,7 @@ class RedbasicConfig { $arr['converse_width']=get_pconfig(local_channel(),"redbasic","converse_width"); $arr['top_photo']=get_pconfig(local_channel(),"redbasic","top_photo"); $arr['reply_photo']=get_pconfig(local_channel(),"redbasic","reply_photo"); + $arr['advanced_theming'] = get_pconfig(local_channel(), 'redbasic', 'advanced_theming'); return $this->form($arr); } @@ -80,15 +81,15 @@ class RedbasicConfig { set_pconfig(local_channel(), 'redbasic', 'converse_width', $_POST['redbasic_converse_width']); set_pconfig(local_channel(), 'redbasic', 'top_photo', $_POST['redbasic_top_photo']); set_pconfig(local_channel(), 'redbasic', 'reply_photo', $_POST['redbasic_reply_photo']); + set_pconfig(local_channel(), 'redbasic', 'advanced_theming', $_POST['redbasic_advanced_theming']); } } function form($arr) { - if(feature_enabled(local_channel(),'advanced_theming')) + if(get_pconfig(local_channel(), 'redbasic', 'advanced_theming')) $expert = 1; - $o .= replace_macros(get_markup_template('theme_settings.tpl'), array( '$submit' => t('Submit'), '$baseurl' => z_root(), @@ -112,6 +113,7 @@ class RedbasicConfig { '$converse_width' => array('redbasic_converse_width',t('Set maximum width of content region in pixel'),$arr['converse_width'], t('Leave empty for default width')), '$top_photo' => array('redbasic_top_photo', t('Set size of conversation author photo'), $arr['top_photo']), '$reply_photo' => array('redbasic_reply_photo', t('Set size of followup author photos'), $arr['reply_photo']), + '$advanced_theming' => ['redbasic_advanced_theming', t('Show advanced settings'), $arr['advanced_theming'], '', [t('No'), t('Yes')]] )); return $o; diff --git a/view/theme/redbasic/tpl/theme_settings.tpl b/view/theme/redbasic/tpl/theme_settings.tpl index 7c552b49e..cc403f0a7 100644 --- a/view/theme/redbasic/tpl/theme_settings.tpl +++ b/view/theme/redbasic/tpl/theme_settings.tpl @@ -1,6 +1,7 @@ {{include file="field_checkbox.tpl" field=$narrow_navbar}} {{include file="field_input.tpl" field=$converse_width}} {{include file="field_input.tpl" field=$font_size}} +{{include file="field_checkbox.tpl" field=$advanced_theming}} {{if $expert}} {{include file="field_colorinput.tpl" field=$nav_bg}} {{include file="field_colorinput.tpl" field=$nav_icon_colour}} diff --git a/view/tpl/abook_edit.tpl b/view/tpl/abook_edit.tpl index d72258fa0..6ff7bffcd 100755 --- a/view/tpl/abook_edit.tpl +++ b/view/tpl/abook_edit.tpl @@ -485,7 +485,7 @@ </div> {{if $permcat_enable}} - <a href="settings/permcats" class="pull-right"><i class="fa fa-plus"></i> {{$permcat_new}}</a> + <a href="permcats" class="pull-right"><i class="fa fa-plus"></i> {{$permcat_new}}</a> {{include file="field_select.tpl" field=$permcat}} {{/if}} diff --git a/view/tpl/admin_account_edit.tpl b/view/tpl/admin_account_edit.tpl index 3329c0025..1cbb9af0b 100644 --- a/view/tpl/admin_account_edit.tpl +++ b/view/tpl/admin_account_edit.tpl @@ -8,7 +8,6 @@ {{include file="field_password.tpl" field=$pass1}} {{include file="field_password.tpl" field=$pass2}} -{{include file="field_select.tpl" field=$account_level}} {{include file="field_select.tpl" field=$account_language}} {{include file="field_input.tpl" field=$service_class}} diff --git a/view/tpl/admin_site.tpl b/view/tpl/admin_site.tpl index c3f8177c2..c644bc973 100755 --- a/view/tpl/admin_site.tpl +++ b/view/tpl/admin_site.tpl @@ -42,9 +42,6 @@ {{include file="field_input.tpl" field=$sitename}} - {{include file="field_select.tpl" field=$techlevel}} - {{include file="field_checkbox.tpl" field=$techlock}} - {{include file="field_textarea.tpl" field=$banner}} {{include file="field_textarea.tpl" field=$siteinfo}} {{include file="field_textarea.tpl" field=$admininfo}} diff --git a/view/tpl/channels.tpl b/view/tpl/channels.tpl index f484b49e5..695b3b30f 100755 --- a/view/tpl/channels.tpl +++ b/view/tpl/channels.tpl @@ -9,9 +9,11 @@ {{$channel_usage_message}} </div> {{/if}} + {{if $desc}} <div id="channels-desc" class="section-content-info-wrapper"> {{$desc}} </div> + {{/if}} {{foreach $all_channels as $chn}} {{include file="channel.tpl" channel=$chn}} {{/foreach}} diff --git a/view/tpl/conv_frame.tpl b/view/tpl/conv_frame.tpl index 8aa865076..c6b3b0d9b 100755 --- a/view/tpl/conv_frame.tpl +++ b/view/tpl/conv_frame.tpl @@ -4,5 +4,16 @@ <div id="page-spinner" class="spinner-wrapper"> <div class="spinner m"></div> </div> - - +<div class="modal" id="conversation_settings" tabindex="-1" role="dialog" aria-labelledby="conversation_settings_label" aria-hidden="true"> + <div class="modal-dialog"> + <div class="modal-content"> + <div class="modal-header"> + <h3 class="modal-title" id="conversation_settings_label">{{$conversation_tools}}</h3> + <button type="button" class="close" data-dismiss="modal" aria-hidden="true">×</button> + </div> + <div class="modal-body" id="conversation_settings_body"> + {{$wait}} + </div> + </div><!-- /.modal-content --> + </div><!-- /.modal-dialog --> +</div><!-- /.modal --> diff --git a/view/tpl/conv_item.tpl b/view/tpl/conv_item.tpl index 05c3d7ae0..5720a2a5f 100755 --- a/view/tpl/conv_item.tpl +++ b/view/tpl/conv_item.tpl @@ -183,6 +183,10 @@ <div class="dropdown-divider"></div> <a class="dropdown-item" href="dreport/{{$item.mid}}">{{$item.dreport}}</a> {{/if}} + {{if $item.settings}} + <div class="dropdown-divider"></div> + <a class="dropdown-item conversation-settings-link" href="" data-toggle="modal" data-target="#conversation_settings">{{$item.settings}}</a> + {{/if}} </div> </div> </div> @@ -210,7 +214,7 @@ <div class="modal-dialog"> <div class="modal-content"> <div class="modal-header"> - <h4 class="modal-title">{{$response.count}} {{$response.button}}</h4> + <h3 class="modal-title">{{$response.count}} {{$response.button}}</h3> <button type="button" class="close" data-dismiss="modal" aria-hidden="true">×</button> </div> <div class="modal-body response-list"> diff --git a/view/tpl/defperms.tpl b/view/tpl/defperms.tpl index 5273ee91b..29f642cff 100755 --- a/view/tpl/defperms.tpl +++ b/view/tpl/defperms.tpl @@ -17,7 +17,7 @@ <p>{{$permnote_self}}</p> </div> {{if $permcat_enable}} - <a href="settings/permcats" class="pull-right"><i class="fa fa-plus"></i> {{$permcat_new}}</a> + <a href="permcats" class="pull-right"><i class="fa fa-plus"></i> {{$permcat_new}}</a> {{include file="field_select.tpl" field=$permcat}} {{/if}} diff --git a/view/tpl/generic_addon_settings.tpl b/view/tpl/generic_addon_settings.tpl index 875c97feb..ae603056b 100644 --- a/view/tpl/generic_addon_settings.tpl +++ b/view/tpl/generic_addon_settings.tpl @@ -1,4 +1,4 @@ -<div class="panel"> +<div class="panel" id="settings"> <div class="section-subtitle-wrapper" role="tab" id="{{$addon.0}}-settings"> <h3> <a title="{{$addon.2}}" data-toggle="collapse" data-target="#{{$addon.0}}-settings-content" href="#" aria-controls="{{$addon.0}}-settings-content"> diff --git a/view/tpl/jot.tpl b/view/tpl/jot.tpl index 2137baf9b..4eae33d13 100755 --- a/view/tpl/jot.tpl +++ b/view/tpl/jot.tpl @@ -43,7 +43,9 @@ {{/if}} <div id="jot-text-wrap"> <div id="profile-jot-tools" class="btn-group d-none"> + {{if $is_owner}} <a id="profile-jot-settings" class="btn btn-outline-secondary btn-sm border-0" href="/settings/editor/?f=&rpath=/{{$return_path}}"><i class="fa fa-cog"></i></a> + {{/if}} {{if $reset}} <button id="profile-jot-reset" class="btn btn-outline-secondary btn-sm border-0" title="{{$reset}}" onclick="itemCancel(); return false;"> <i class="fa fa-close"></i> @@ -212,7 +214,7 @@ <div class="modal-dialog"> <div class="modal-content"> <div class="modal-header"> - <h4 class="modal-title" id="expiryModalLabel">{{$jotnets_label}}</h4> + <h3 class="modal-title" id="expiryModalLabel">{{$jotnets_label}}</h3> <button type="button" class="close" data-dismiss="modal" aria-hidden="true">×</button> </div> <div class="modal-body"> @@ -239,7 +241,7 @@ <div class="modal-dialog"> <div class="modal-content"> <div class="modal-header"> - <h4 class="modal-title" id="expiryModalLabel">{{$expires}}</h4> + <h3 class="modal-title" id="expiryModalLabel">{{$expires}}</h3> <button type="button" class="close" data-dismiss="modal" aria-hidden="true">×</button> </div> <div class="modal-body form-group" style="width:90%"> @@ -266,7 +268,7 @@ <div class="modal-dialog"> <div class="modal-content"> <div class="modal-header"> - <h4 class="modal-title" id="createdModalLabel">{{$future_txt}}</h4> + <h3 class="modal-title" id="createdModalLabel">{{$future_txt}}</h3> <button type="button" class="close" data-dismiss="modal" aria-hidden="true">×</button> </div> <div class="modal-body form-group" style="width:90%"> @@ -293,7 +295,7 @@ <div class="modal-dialog"> <div class="modal-content"> <div class="modal-header"> - <h4 class="modal-title" id="embedPhotoModalLabel">{{$embedPhotosModalTitle}}</h4> + <h3 class="modal-title" id="embedPhotoModalLabel">{{$embedPhotosModalTitle}}</h3> <button type="button" class="close" data-dismiss="modal" aria-hidden="true">×</button> </div> <div class="modal-body" id="embedPhotoModalBody" > diff --git a/view/tpl/new_channel.tpl b/view/tpl/new_channel.tpl index 51880e1f6..8d72df55b 100755 --- a/view/tpl/new_channel.tpl +++ b/view/tpl/new_channel.tpl @@ -13,23 +13,25 @@ </div> {{/if}} {{/if}} - <form action="new_channel" method="post" id="newchannel-form"> - {{if $default_role}} - <input type="hidden" name="permissions_role" value="{{$default_role}}" /> - {{else}} - {{include file="field_select_grouped.tpl" field=$role}} - {{/if}} - - {{include file="field_input.tpl" field=$name}} - - {{include file="field_input.tpl" field=$nickname}} - <button class="btn btn-primary" type="submit" id="newchannel-submit-button">{{$submit}}</button> - - - <div id="newchannel-submit-end" class="clear"></div> - - <div id="newchannel-import-link" class="descriptive-paragraph" >{{$label_import}}</div> - <div id="newchannel-import-end" class="clear"></div> - </form> + {{if $canadd}} + <form action="new_channel" method="post" id="newchannel-form"> + {{if $default_role}} + <input type="hidden" name="permissions_role" value="{{$default_role}}" /> + {{else}} + {{include file="field_select_grouped.tpl" field=$role}} + {{/if}} + + {{include file="field_input.tpl" field=$name}} + + {{include file="field_input.tpl" field=$nickname}} + <button class="btn btn-primary" type="submit" id="newchannel-submit-button">{{$submit}}</button> + + + <div id="newchannel-submit-end" class="clear"></div> + + <div id="newchannel-import-link" class="descriptive-paragraph" >{{$label_import}}</div> + <div id="newchannel-import-end" class="clear"></div> + </form> + {{/if}} </div> </div> diff --git a/view/tpl/notes.tpl b/view/tpl/notes.tpl index c6d5d8a73..67da5ff37 100644 --- a/view/tpl/notes.tpl +++ b/view/tpl/notes.tpl @@ -1,5 +1,13 @@ +{{if $app}} +<div class="generic-content-wrapper"> + <div class="section-title-wrapper"> + <h2>{{$banner}}</h2> + </div> + <div class="section-content-wrapper"> +{{else}} <div class="widget"> <h3>{{$banner}}</h3> +{{/if}} <textarea name="note_text" id="note-text">{{$text}}</textarea> <script> var noteSaveTimer = null; @@ -32,4 +40,7 @@ noteSaveTimer = setTimeout(noteSaveChanges,10000); } </script> +{{if $app}} +</div> +{{/if}} </div> diff --git a/view/tpl/settings_oauth.tpl b/view/tpl/oauth.tpl index 811cfcec5..881e22e99 100755 --- a/view/tpl/settings_oauth.tpl +++ b/view/tpl/oauth.tpl @@ -4,13 +4,13 @@ </div> <div class="section-content-tools-wrapper"> -<form action="settings/oauth" method="post" autocomplete="off"> +<form action="oauth" method="post" autocomplete="off"> <input type='hidden' name='form_security_token' value='{{$form_security_token}}'> <div id="profile-edit-links"> <ul> <li> - <a id="profile-edit-view-link" href="{{$baseurl}}/settings/oauth/add">{{$add}}</a> + <a id="profile-edit-view-link" href="{{$baseurl}}/oauth/add">{{$add}}</a> </li> </ul> </div> @@ -25,8 +25,8 @@ {{/if}} {{/if}} {{if $app.my}} - <a href="{{$baseurl}}/settings/oauth/edit/{{$app.client_id}}" title="{{$edit}}"><i class="fa fa-pencil btn btn-outline-secondary"></i></a> - <a href="{{$baseurl}}/settings/oauth/delete/{{$app.client_id}}?t={{$form_security_token}}" title="{{$delete}}"><i class="fa fa-trash-o btn btn-outline-secondary"></i></a> + <a href="{{$baseurl}}/oauth/edit/{{$app.client_id}}" title="{{$edit}}"><i class="fa fa-pencil btn btn-outline-secondary"></i></a> + <a href="{{$baseurl}}/oauth/delete/{{$app.client_id}}?t={{$form_security_token}}" title="{{$delete}}"><i class="fa fa-trash-o btn btn-outline-secondary"></i></a> {{/if}} </div> {{/foreach}} diff --git a/view/tpl/settings_oauth2.tpl b/view/tpl/oauth2.tpl index f3bf59a12..a5b48ffce 100755 --- a/view/tpl/settings_oauth2.tpl +++ b/view/tpl/oauth2.tpl @@ -8,13 +8,13 @@ <div id="profile-edit-links"> <ul> <li> - <a id="profile-edit-view-link" href="{{$baseurl}}/settings/oauth2/add">{{$add}}</a> + <a id="profile-edit-view-link" href="{{$baseurl}}/oauth2/add">{{$add}}</a> </li> </ul> </div> {{foreach $apps as $app}} -<form action="settings/oauth2" method="post" autocomplete="off"> +<form action="oauth2" method="post" autocomplete="off"> <input type='hidden' name='form_security_token' value='{{$form_security_token}}'> <input type='hidden' name='name' value='{{$app.client_id}}'> <div class='oauthapp'> @@ -25,8 +25,8 @@ {{/if}} {{/if}} {{if $app.my}} - <a href="{{$baseurl}}/settings/oauth2/edit/{{$app.client_id}}" title="{{$edit}}"><i class="fa fa-pencil btn btn-outline-secondary"></i></a> - <a href="{{$baseurl}}/settings/oauth2/delete/{{$app.client_id}}?t={{$form_security_token}}" title="{{$delete}}"><i class="fa fa-trash-o btn btn-outline-secondary"></i></a> + <a href="{{$baseurl}}/oauth2/edit/{{$app.client_id}}" title="{{$edit}}"><i class="fa fa-pencil btn btn-outline-secondary"></i></a> + <a href="{{$baseurl}}/oauth2/delete/{{$app.client_id}}?t={{$form_security_token}}" title="{{$delete}}"><i class="fa fa-trash-o btn btn-outline-secondary"></i></a> {{/if}} </div> </form> diff --git a/view/tpl/settings_oauth2_edit.tpl b/view/tpl/oauth2_edit.tpl index 399c64977..399c64977 100755 --- a/view/tpl/settings_oauth2_edit.tpl +++ b/view/tpl/oauth2_edit.tpl diff --git a/view/tpl/settings_oauth_edit.tpl b/view/tpl/oauth_edit.tpl index e44b44723..e44b44723 100755 --- a/view/tpl/settings_oauth_edit.tpl +++ b/view/tpl/oauth_edit.tpl diff --git a/view/tpl/settings_permcats.tpl b/view/tpl/permcats.tpl index bbbd41669..442b3e11a 100644 --- a/view/tpl/settings_permcats.tpl +++ b/view/tpl/permcats.tpl @@ -8,7 +8,7 @@ {{$desc}} </div> - <form action="settings/permcats" id="settings-permcats-form" method="post" autocomplete="off" > + <form action="permcats" id="settings-permcats-form" method="post" autocomplete="off" > <input type='hidden' name='form_security_token' value='{{$form_security_token}}'> {{include file="field_input.tpl" field=$name}} @@ -17,10 +17,10 @@ </div> </div> - <div class="panel"> + <div class="panel" id="permission-settings"> <div class="section-subtitle-wrapper" role="tab" id="perms-tool"> <h3> - <a data-toggle="collapse" data-parent="#contact-edit-tools" href="#perms-tool-collapse" aria-expanded="true" aria-controls="perms-tool-collapse"> + <a data-toggle="collapse" data-parent="#permission-settings" href="#perms-tool-collapse" aria-expanded="true" aria-controls="perms-tool-collapse"> {{$permlbl}} </a> </h3> @@ -50,8 +50,8 @@ <table id="permcat-index"> {{foreach $permcats as $k => $v}} <tr class="permcat-row-{{$k}}"> - <td width="99%"><a href="settings/permcats/{{$k}}">{{$v}}</a></td> - <td width="1%"><i class="fa fa-trash-o drop-icons" onClick="dropItem('/settings/permcats/{{$k}}/drop', '.permcat-row-{{$k}}')"></i></td> + <td width="99%"><a href="permcats/{{$k}}">{{$v}}</a></td> + <td width="1%"><i class="fa fa-trash-o drop-icons" onClick="dropItem('permcats/{{$k}}/drop', '.permcat-row-{{$k}}')"></i></td> </tr> {{/foreach}} </table> diff --git a/view/tpl/settings.tpl b/view/tpl/settings.tpl index 74863a5db..7980bc696 100755 --- a/view/tpl/settings.tpl +++ b/view/tpl/settings.tpl @@ -172,27 +172,28 @@ </div> <div id="miscellaneous-settings-collapse" class="collapse" role="tabpanel" aria-labelledby="miscellaneous-settings" data-parent="#settings" > <div class="section-content-tools-wrapper"> - {{if $profselect}} - <label for="contact-profile-selector">{{$profseltxt}}</label> - {{$profselect}} - {{/if}} - {{if $menus}} - <div class="form-group channel-menu"> - <label for="channel_menu">{{$menu_desc}}</label> - <select name="channel_menu" class="form-control"> - {{foreach $menus as $menu }} - <option value="{{$menu.name}}" {{$menu.selected}} >{{$menu.name}} </option> - {{/foreach}} - </select> - </div> - {{/if}} - {{if $misc_addon}} - {{$misc_addon}} - {{/if}} - - <div class="settings-submit-wrapper" > - <button type="submit" name="submit" class="btn btn-primary">{{$submit}}</button> - </div> + <div class="form-group"> + {{if $profselect}} + <label for="contact-profile-selector">{{$profseltxt}}</label> + {{$profselect}} + {{/if}} + {{if $menus}} + <div class="form-group channel-menu"> + <label for="channel_menu">{{$menu_desc}}</label> + <select name="channel_menu" class="form-control"> + {{foreach $menus as $menu }} + <option value="{{$menu.name}}" {{$menu.selected}}>{{$menu.name}}</option> + {{/foreach}} + </select> + </div> + {{/if}} + {{if $misc_addon}} + {{$misc_addon}} + {{/if}} + </div> + <div class="settings-submit-wrapper" > + <button type="submit" name="submit" class="btn btn-primary">{{$submit}}</button> + </div> </div> </div> </div> diff --git a/view/tpl/settings_account.tpl b/view/tpl/settings_account.tpl index dd1d0d0c9..3eacf3f7a 100755 --- a/view/tpl/settings_account.tpl +++ b/view/tpl/settings_account.tpl @@ -12,12 +12,6 @@ {{include file="field_password.tpl" field=$password1}} {{include file="field_password.tpl" field=$password2}} - {{if ! $techlock}} - {{include file="field_select.tpl" field=$techlevel}} - {{else}} - <input type="hidden" name="techlevel" value="{{$techlevel.2}}" /> - {{/if}} - <div class="settings-submit-wrapper" > <button type="submit" name="submit" class="btn btn-primary">{{$submit}}</button> </div> diff --git a/view/tpl/settings_addon.tpl b/view/tpl/settings_addon.tpl index b5665f579..93bf3d083 100644 --- a/view/tpl/settings_addon.tpl +++ b/view/tpl/settings_addon.tpl @@ -3,11 +3,20 @@ <h2>{{$title}}</h2> </div> <div class="section-content-wrapper"> + {{if $action_url}} <form action="{{$action_url}}" method="post" autocomplete="off"> - <input type='hidden' name='form_security_token' value='{{$form_security_token}}'> - {{$content}} - <div class="settings-submit-wrapper" > - <button type="submit" name="submit" class="btn btn-primary">{{$submit}}</button> - </div> + {{/if}} + {{if $form_security_token}} + <input type='hidden' name='form_security_token' value='{{$form_security_token}}'> + {{/if}} + {{$content}} + {{if $submit}} + <div class="settings-submit-wrapper" > + <button type="submit" name="submit" class="btn btn-primary">{{$submit}}</button> + </div> + {{/if}} + {{if $action_url}} + </form> + {{/if}} </div> </div> diff --git a/view/tpl/settings_display.tpl b/view/tpl/settings_display.tpl index 7600038ea..c93efb4aa 100755 --- a/view/tpl/settings_display.tpl +++ b/view/tpl/settings_display.tpl @@ -58,21 +58,13 @@ <div class="section-content-wrapper"> {{include file="field_input.tpl" field=$ajaxint}} {{include file="field_input.tpl" field=$itemspage}} - {{include file="field_input.tpl" field=$channel_divmore_height}} - {{include file="field_input.tpl" field=$network_divmore_height}} {{include file="field_checkbox.tpl" field=$nosmile}} {{include file="field_checkbox.tpl" field=$channel_menu}} {{include file="field_checkbox.tpl" field=$title_tosource}} - {{include file="field_checkbox.tpl" field=$channel_list_mode}} - {{include file="field_checkbox.tpl" field=$network_list_mode}} {{include file="field_checkbox.tpl" field=$user_scalable}} {{include file="field_checkbox.tpl" field=$preload_images}} {{include file="field_checkbox.tpl" field=$manual_update}} - {{if $expert}} - <div class="form-group"> - <a class="btn btn-outline-secondary "href="pdledit">{{$layout_editor}}</a> - </div> - {{/if}} + {{include file="field_checkbox.tpl" field=$start_menu}} <div class="settings-submit-wrapper" > <button type="submit" name="submit" class="btn btn-primary">{{$submit}}</button> </div> diff --git a/view/tpl/settings_features.tpl b/view/tpl/settings_features.tpl index 998199c8e..12c4f44f3 100755 --- a/view/tpl/settings_features.tpl +++ b/view/tpl/settings_features.tpl @@ -1,31 +1,10 @@ -<script> - $(document).ready(function() { - $('#id_techlevel').change(function() { - var techlvl = $('#id_techlevel').val(); - window.location.href='{{$baseurl}}/settings/features?f=&techlevel=' + techlvl; - }); - }); -</script> - <div class="generic-content-wrapper"> <div class="section-title-wrapper"> <h2>{{$title}}</h2> </div> <form action="settings/features" method="post" autocomplete="off"> <input type='hidden' name='form_security_token' value='{{$form_security_token}}'> - {{if ! $techlock}} - <div class="section-content-tools-wrapper"> - {{include file="field_select.tpl" field=$techlevel}} - </div> - {{else}} - <input type="hidden" name="techlevel" value="{{$techlevel.2}}" /> - {{/if}} - {{if $hiddens}} - {{foreach $hiddens as $k => $v}} - <input type="hidden" name="feature_{{$k}}" value="{{$v}}" /> - {{/foreach}} - {{/if}} <div class="panel-group" id="settings" role="tablist" aria-multiselectable="true"> {{foreach $features as $g => $f}} <div class="panel"> diff --git a/view/tpl/settings_module.tpl b/view/tpl/settings_module.tpl index cabefc3e5..03d16d1d7 100755 --- a/view/tpl/settings_module.tpl +++ b/view/tpl/settings_module.tpl @@ -4,15 +4,19 @@ </div> <div class="section-content-wrapper"> <form action="{{$action_url}}" method="post" autocomplete="off"> - <input type='hidden' name='form_security_token' value='{{$form_security_token}}'> - {{if $rpath}} - <input type='hidden' name='rpath' value='{{$rpath}}'> - {{/if}} - {{foreach $features as $feature}} - {{include file="field_checkbox.tpl" field=$feature}} - {{/foreach}} - <div class="settings-submit-wrapper" > - <button type="submit" name="submit" class="btn btn-primary">{{$submit}}</button> - </div> + <input type='hidden' name='form_security_token' value='{{$form_security_token}}'> + {{if $rpath}} + <input type='hidden' name='rpath' value='{{$rpath}}'> + {{/if}} + {{foreach $features as $feature}} + {{include file="field_checkbox.tpl" field=$feature}} + {{/foreach}} + {{if $extra_settings_html}} + {{$extra_settings_html}} + {{/if}} + <div class="settings-submit-wrapper" > + <button type="submit" name="submit" class="btn btn-primary">{{$submit}}</button> + </div> + </form> </div> </div> diff --git a/view/tpl/settings_module_ajax.tpl b/view/tpl/settings_module_ajax.tpl new file mode 100644 index 000000000..bd7b6f3df --- /dev/null +++ b/view/tpl/settings_module_ajax.tpl @@ -0,0 +1,11 @@ +<form id="settings_module_ajax_form" action="{{$action_url}}" method="post" autocomplete="off"> + <input type='hidden' name='form_security_token' value='{{$form_security_token}}'> + <input type='hidden' name='aj' value='1'> + {{foreach $features as $feature}} + {{include file="field_checkbox.tpl" field=$feature}} + {{/foreach}} + <div class="settings-submit-wrapper" > + <button id="settings_module_ajax_submit" type="submit" name="submit" class="btn btn-primary">{{$submit}}</button> + </div> +</form> + diff --git a/view/tpl/settings_tokens.tpl b/view/tpl/tokens.tpl index 48190c00c..587965832 100644 --- a/view/tpl/settings_tokens.tpl +++ b/view/tpl/tokens.tpl @@ -8,7 +8,7 @@ {{$desc}} </div> - <form action="settings/tokens" id="settings-account-form" method="post" autocomplete="off" > + <form action="tokens" id="settings-account-form" method="post" autocomplete="off" > <input type='hidden' name='form_security_token' value='{{$form_security_token}}'> {{if $atoken}}<input type="hidden" name="atoken_id" value="{{$atoken.atoken_id}}" />{{/if}} {{include file="field_input.tpl" field=$name}} @@ -19,10 +19,10 @@ </div> </div> - <div class="panel"> + <div class="panel" id="permission-settings"> <div class="section-subtitle-wrapper" role="tab" id="perms-tool"> <h3> - <a data-toggle="collapse" data-parent="#contact-edit-tools" href="#perms-tool-collapse" aria-expanded="true" aria-controls="perms-tool-collapse"> + <a data-toggle="collapse" data-parent="#permission-settings" href="#perms-tool-collapse" aria-expanded="true" aria-controls="perms-tool-collapse"> {{$permlbl}} </a> </h3> @@ -61,8 +61,8 @@ <table id="atoken-index"> {{foreach $tokens as $t}} <tr id="atoken-index-{{$t.atoken_id}}" class="atoken-index-row"> - <td width="99%"><a href="settings/tokens/{{$t.atoken_id}}">{{$t.atoken_name}}</a></td> - <td width="1%" class="atoken-index-tool"><i class="fa fa-trash-o drop-icons" onClick="dropItem('/settings/tokens/{{$t.atoken_id}}/drop', '#atoken-index-{{$t.atoken_id}}')"></i></td> + <td width="99%"><a href="tokens/{{$t.atoken_id}}">{{$t.atoken_name}}</a></td> + <td width="1%" class="atoken-index-tool"><i class="fa fa-trash-o drop-icons" onClick="dropItem('tokens/{{$t.atoken_id}}/drop', '#atoken-index-{{$t.atoken_id}}')"></i></td> </tr> {{/foreach}} </table> |