Ignore:
Timestamp:
Jul 23, 2012, 6:16:34 PM (12 years ago)
Author:
mistic100
Message:

add option to block permissions recalculation

Location:
extensions/SmartAlbums/admin
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • extensions/SmartAlbums/admin/config.php

    r16104 r16939  
    66{
    77  $conf['SmartAlbums']['update_on_upload'] = isset($_POST['update_on_upload']);
     8  $conf['SmartAlbums']['smart_is_forbidden'] = isset($_POST['smart_is_forbidden']);
    89 
    910  conf_update_param('SmartAlbums', serialize($conf['SmartAlbums']));
     
    1112}
    1213
    13 $template->assign(array(
    14   'update_on_upload' => $conf['SmartAlbums']['update_on_upload'],
    15 ));
     14$template->assign($conf['SmartAlbums']);
    1615
    1716$template->set_filename('SmartAlbums_content', dirname(__FILE__).'/template/config.tpl');
  • extensions/SmartAlbums/admin/template/config.tpl

    r16104 r16939  
     1{html_head}{literal}
     2<style type="text/css">
     3.showInfo {
     4  position:static;
     5  display:inline-block;
     6  padding:1px 6px !important;
     7  width:auto;
     8  font-size:0.8em;
     9  line-height:1.2em;
     10}
     11</style>
     12{/literal}{/html_head}
     13
     14{footer_script require="jquery"}
     15jQuery(".showInfo").tipTip({ldelim}
     16    delay: 0,
     17    fadeIn: 200,
     18    fadeOut: 200,
     19    maxWidth: '300px',
     20    defaultPosition:"right"
     21  });
     22{/footer_script}
     23
    124<div class="titrePage">
    225        <h2>SmartAlbums</h2>
    326</div>
    427
    5 <form method="post" action="" class="properties" ENCTYPE="multipart/form-data">
    6         <fieldset>
    7                 <legend>{'Configuration'|@translate}</legend>     
     28<form method="post" action="" class="properties">
     29        <fieldset id="commentsConf">
    830                <ul>                   
    931                        <li>
    1032        <label>
    11           <span class="property">{'Update albums on file upload'|@translate}</span>
    1233          <input type="checkbox" name="update_on_upload" value="true" {if $update_on_upload}checked="checked"{/if}/>
    13           {'(can cause slowdowns)'|@translate}
     34          <b>{'Update albums on file upload'|@translate}</b>
     35          <a class="showInfo" title="{'can cause slowdowns'|@translate}">i</a>
     36        </label>
     37                        </li>
     38      <li>
     39        <label>
     40          <input type="checkbox" name="smart_is_forbidden" value="true" {if $smart_is_forbidden}checked="checked"{/if}/>
     41          <b>{'Exclude SmartAlbums from permissions management'|@translate}</b>
     42          <a class="showInfo" title="{'SmartAlbums are considered private for everyone, and a user can see it\'s content only if available in another album he has access to.'|@translate}">i</a>
    1443        </label>
    1544                        </li>
     
    1746        </fieldset>
    1847               
    19         <p><input class="submit" type="submit" value="{'Submit'|@translate}" name="submit" /></p>
     48        <p class="formButtons"><input class="submit" type="submit" value="{'Submit'|@translate}" name="submit" /></p>
    2049</form>
Note: See TracChangeset for help on using the changeset viewer.