* splite the css and js.
* rewrite the ui code.
This commit is contained in:
@@ -0,0 +1 @@
|
||||
#users span{display:block; width:100px; float:left}
|
||||
@@ -0,0 +1,7 @@
|
||||
function checkall(checker, id)
|
||||
{
|
||||
$('#' + id + ' input').each(function()
|
||||
{
|
||||
$(this).attr("checked", checker.checked)
|
||||
});
|
||||
}
|
||||
@@ -0,0 +1,15 @@
|
||||
function check(checker, module)
|
||||
{
|
||||
$('#' + module + ' input').each(function()
|
||||
{
|
||||
$(this).attr("checked", checker.checked)
|
||||
});
|
||||
}
|
||||
|
||||
function checkall(checker)
|
||||
{
|
||||
$('input').each(function()
|
||||
{
|
||||
$(this).attr("checked", checker.checked)
|
||||
});
|
||||
}
|
||||
@@ -11,34 +11,32 @@
|
||||
*/
|
||||
?>
|
||||
<?php include '../../common/view/header.html.php';?>
|
||||
<div class='yui-d0'>
|
||||
<table align='center' class='table-1'>
|
||||
<caption class='caption-tl'>
|
||||
<div class='f-left'><?php echo $lang->group->browse;?></div>
|
||||
<div class='f-right'><?php echo html::a(inlink('create'), $lang->group->create);?></div>
|
||||
</caption>
|
||||
<tr class='colhead'>
|
||||
<th><?php echo $lang->group->id;?></th>
|
||||
<th><?php echo $lang->group->name;?></th>
|
||||
<th><?php echo $lang->group->desc;?></th>
|
||||
<th class='w-p60'><?php echo $lang->group->users;?></th>
|
||||
<th><?php echo $lang->actions;?></th>
|
||||
</tr>
|
||||
<?php foreach($groups as $group):?>
|
||||
<tr class='a-center'>
|
||||
<td><?php echo $group->id;?></td>
|
||||
<td><?php echo $group->name;?></td>
|
||||
<td class='a-left'><?php echo $group->desc;?></td>
|
||||
<td class='a-left'><?php foreach($groupUsers[$group->id] as $user) echo $user . ' ';?></td>
|
||||
<td>
|
||||
<?php common::printLink('group', 'managepriv', "groupID=$group->id", $lang->group->managePriv);?>
|
||||
<?php common::printLink('group', 'managemember', "groupID=$group->id", $lang->group->manageMember);?>
|
||||
<?php common::printLink('group', 'edit', "groupID=$group->id", $lang->edit);?>
|
||||
<?php common::printLink('group', 'copy', "groupID=$group->id", $lang->copy);?>
|
||||
<?php common::printLink('group', 'delete', "groupID=$group->id", $lang->delete, "hiddenwin");?>
|
||||
</td>
|
||||
</tr>
|
||||
<?php endforeach;?>
|
||||
</table>
|
||||
</div>
|
||||
<table align='center' class='table-1'>
|
||||
<caption class='caption-tl'>
|
||||
<div class='f-left'><?php echo $lang->group->browse;?></div>
|
||||
<div class='f-right'><?php echo html::a(inlink('create'), $lang->group->create);?></div>
|
||||
</caption>
|
||||
<tr class='colhead'>
|
||||
<th><?php echo $lang->group->id;?></th>
|
||||
<th><?php echo $lang->group->name;?></th>
|
||||
<th><?php echo $lang->group->desc;?></th>
|
||||
<th class='w-p60'><?php echo $lang->group->users;?></th>
|
||||
<th><?php echo $lang->actions;?></th>
|
||||
</tr>
|
||||
<?php foreach($groups as $group):?>
|
||||
<tr class='a-center'>
|
||||
<td><?php echo $group->id;?></td>
|
||||
<td><?php echo $group->name;?></td>
|
||||
<td class='a-left'><?php echo $group->desc;?></td>
|
||||
<td class='a-left'><?php foreach($groupUsers[$group->id] as $user) echo $user . ' ';?></td>
|
||||
<td>
|
||||
<?php common::printLink('group', 'managepriv', "groupID=$group->id", $lang->group->managePriv);?>
|
||||
<?php common::printLink('group', 'managemember', "groupID=$group->id", $lang->group->manageMember);?>
|
||||
<?php common::printLink('group', 'edit', "groupID=$group->id", $lang->edit);?>
|
||||
<?php common::printLink('group', 'copy', "groupID=$group->id", $lang->copy);?>
|
||||
<?php common::printLink('group', 'delete', "groupID=$group->id", $lang->delete, "hiddenwin");?>
|
||||
</td>
|
||||
</tr>
|
||||
<?php endforeach;?>
|
||||
</table>
|
||||
<?php include '../../common/view/footer.html.php';?>
|
||||
|
||||
@@ -11,24 +11,22 @@
|
||||
*/
|
||||
?>
|
||||
<?php include '../../common/view/header.html.php';?>
|
||||
<div class='yui-d0'>
|
||||
<form method='post' target='hiddenwin'>
|
||||
<table align='center' class='table-4'>
|
||||
<caption><?php echo $lang->group->copy;?></caption>
|
||||
<tr>
|
||||
<th class='rowhead'><?php echo $lang->group->name;?></th>
|
||||
<td><?php echo html::input('name', $group->name, "class='text-1'");?></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th class='rowhead'><?php echo $lang->group->desc;?></th>
|
||||
<td><?php echo html::textarea('desc', $group->desc, "rows='5' class='area-1'");?></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th class='rowhead'><?php echo $lang->group->option;?></th>
|
||||
<td><?php echo html::checkbox('options', $lang->group->copyOptions);?></td>
|
||||
</tr>
|
||||
<tr><td colspan='2' class='a-center'><?php echo html::submitButton();?></td></tr>
|
||||
</table>
|
||||
</form>
|
||||
</div>
|
||||
<form method='post' target='hiddenwin'>
|
||||
<table align='center' class='table-4'>
|
||||
<caption><?php echo $lang->group->copy;?></caption>
|
||||
<tr>
|
||||
<th class='rowhead'><?php echo $lang->group->name;?></th>
|
||||
<td><?php echo html::input('name', $group->name, "class='text-1'");?></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th class='rowhead'><?php echo $lang->group->desc;?></th>
|
||||
<td><?php echo html::textarea('desc', $group->desc, "rows='5' class='area-1'");?></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th class='rowhead'><?php echo $lang->group->option;?></th>
|
||||
<td><?php echo html::checkbox('options', $lang->group->copyOptions);?></td>
|
||||
</tr>
|
||||
<tr><td colspan='2' class='a-center'><?php echo html::submitButton();?></td></tr>
|
||||
</table>
|
||||
</form>
|
||||
<?php include '../../common/view/footer.html.php';?>
|
||||
|
||||
@@ -11,20 +11,18 @@
|
||||
*/
|
||||
?>
|
||||
<?php include '../../common/view/header.html.php';?>
|
||||
<div class='yui-d0'>
|
||||
<form method='post' target='hiddenwin'>
|
||||
<table align='center' class='table-4 a-left'>
|
||||
<caption><?php echo $lang->group->create;?></caption>
|
||||
<tr>
|
||||
<th class='rowhead'><?php echo $lang->group->name;?></th>
|
||||
<td><?php echo html::input('name', '', "class=text-1");?></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th class='rowhead'><?php echo $lang->group->desc;?></th>
|
||||
<td><?php echo html::textarea('desc', '', "rows=5 class=area-1");?></textarea></td>
|
||||
</tr>
|
||||
<tr><td colspan='2' class='a-center'><?php echo html::submitButton();?></td></tr>
|
||||
</table>
|
||||
</form>
|
||||
</div>
|
||||
<form method='post' target='hiddenwin'>
|
||||
<table align='center' class='table-4 a-left'>
|
||||
<caption><?php echo $lang->group->create;?></caption>
|
||||
<tr>
|
||||
<th class='rowhead'><?php echo $lang->group->name;?></th>
|
||||
<td><?php echo html::input('name', '', "class=text-1");?></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th class='rowhead'><?php echo $lang->group->desc;?></th>
|
||||
<td><?php echo html::textarea('desc', '', "rows=5 class=area-1");?></textarea></td>
|
||||
</tr>
|
||||
<tr><td colspan='2' class='a-center'><?php echo html::submitButton();?></td></tr>
|
||||
</table>
|
||||
</form>
|
||||
<?php include '../../common/view/footer.html.php';?>
|
||||
|
||||
@@ -11,20 +11,18 @@
|
||||
*/
|
||||
?>
|
||||
<?php include '../../common/view/header.html.php';?>
|
||||
<div class='yui-d0'>
|
||||
<form method='post' target='hiddenwin'>
|
||||
<table align='center' class='table-4'>
|
||||
<caption><?php echo $lang->group->edit;?></caption>
|
||||
<tr>
|
||||
<th class='rowhead'><?php echo $lang->group->name;?></th>
|
||||
<td><?php echo html::input('name', $group->name, "class='text-1'");?></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th class='rowhead'><?php echo $lang->group->desc;?></th>
|
||||
<td><?php echo html::textarea('desc', $group->desc, "rows='5' class='area-1'");?></td>
|
||||
</tr>
|
||||
<tr><td colspan='2' class='a-center'><?php echo html::submitButton();?></td></tr>
|
||||
</table>
|
||||
</form>
|
||||
</div>
|
||||
<form method='post' target='hiddenwin'>
|
||||
<table align='center' class='table-4'>
|
||||
<caption><?php echo $lang->group->edit;?></caption>
|
||||
<tr>
|
||||
<th class='rowhead'><?php echo $lang->group->name;?></th>
|
||||
<td><?php echo html::input('name', $group->name, "class='text-1'");?></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th class='rowhead'><?php echo $lang->group->desc;?></th>
|
||||
<td><?php echo html::textarea('desc', $group->desc, "rows='5' class='area-1'");?></td>
|
||||
</tr>
|
||||
<tr><td colspan='2' class='a-center'><?php echo html::submitButton();?></td></tr>
|
||||
</table>
|
||||
</form>
|
||||
<?php include '../../common/view/footer.html.php';?>
|
||||
|
||||
@@ -11,43 +11,31 @@
|
||||
*/
|
||||
?>
|
||||
<?php include '../../common/view/header.html.php';?>
|
||||
<script language="Javascript">
|
||||
function checkall(checker, id)
|
||||
{
|
||||
$('#' + id + ' input').each(function()
|
||||
{
|
||||
$(this).attr("checked", checker.checked)
|
||||
});
|
||||
}
|
||||
</script>
|
||||
<style>#users span{display:block; width:100px; float:left}</style>
|
||||
<div class='yui-d0'>
|
||||
<form method='post' target='hiddenwin'>
|
||||
<table align='center' class='table-1 a-left'>
|
||||
<caption><?php echo $group->name . $lang->colon . $lang->group->manageMember;?></caption>
|
||||
<tr>
|
||||
<th class='rowhead'><?php echo $lang->group->inside;?><input type='checkbox' onclick='checkall(this, "group");'></th>
|
||||
<td id='group' class='f-14px pv-10px'><?php $i = 1;?>
|
||||
<?php foreach($groupUsers as $account => $realname):?>
|
||||
<div class='w-p10 f-left'><?php echo '<span>' . html::checkbox('members', array($account => $realname), $account) . '</span>';?></div>
|
||||
<?php if(($i % 8) == 0) echo "<div class='c-both'></div>"; $i ++;?>
|
||||
<?php endforeach;?>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th class='rowhead'><?php echo $lang->group->outside;?><input type='checkbox' onclick='checkall(this, "other");'></th>
|
||||
<td id='other' class='f-14px pv-10px'><?php $i = 1;?>
|
||||
<?php foreach($otherUsers as $account => $realname):?>
|
||||
<div class='w-p10 f-left'><?php echo '<span>' . html::checkbox('members', array($account => $realname), '') . '</span>';?></div>
|
||||
<?php if(($i % 8) == 0) echo "<div class='c-both'></div>"; $i ++;?>
|
||||
<?php endforeach;?>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th class='rowhead'></th>
|
||||
<td class='a-center'><?php echo html::submitButton() . html::linkButton($lang->goback, $this->createLink('group', 'browse'));?></td>
|
||||
</tr>
|
||||
</table>
|
||||
</form>
|
||||
</div>
|
||||
<form method='post' target='hiddenwin'>
|
||||
<table align='center' class='table-1 a-left'>
|
||||
<caption><?php echo $group->name . $lang->colon . $lang->group->manageMember;?></caption>
|
||||
<tr>
|
||||
<th class='rowhead'><?php echo $lang->group->inside;?><input type='checkbox' onclick='checkall(this, "group");'></th>
|
||||
<td id='group' class='f-14px pv-10px'><?php $i = 1;?>
|
||||
<?php foreach($groupUsers as $account => $realname):?>
|
||||
<div class='w-p10 f-left'><?php echo '<span>' . html::checkbox('members', array($account => $realname), $account) . '</span>';?></div>
|
||||
<?php if(($i % 8) == 0) echo "<div class='c-both'></div>"; $i ++;?>
|
||||
<?php endforeach;?>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th class='rowhead'><?php echo $lang->group->outside;?><input type='checkbox' onclick='checkall(this, "other");'></th>
|
||||
<td id='other' class='f-14px pv-10px'><?php $i = 1;?>
|
||||
<?php foreach($otherUsers as $account => $realname):?>
|
||||
<div class='w-p10 f-left'><?php echo '<span>' . html::checkbox('members', array($account => $realname), '') . '</span>';?></div>
|
||||
<?php if(($i % 8) == 0) echo "<div class='c-both'></div>"; $i ++;?>
|
||||
<?php endforeach;?>
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<th class='rowhead'></th>
|
||||
<td class='a-center'><?php echo html::submitButton() . html::linkButton($lang->goback, $this->createLink('group', 'browse'));?></td>
|
||||
</tr>
|
||||
</table>
|
||||
</form>
|
||||
<?php include '../../common/view/footer.html.php';?>
|
||||
|
||||
@@ -11,54 +11,35 @@
|
||||
*/
|
||||
?>
|
||||
<?php include '../../common/view/header.html.php';?>
|
||||
<script language="Javascript">
|
||||
function check(checker, module)
|
||||
{
|
||||
$('#' + module + ' input').each(function()
|
||||
{
|
||||
$(this).attr("checked", checker.checked)
|
||||
});
|
||||
}
|
||||
|
||||
function checkall(checker)
|
||||
{
|
||||
$('input').each(function()
|
||||
{
|
||||
$(this).attr("checked", checker.checked)
|
||||
});
|
||||
}
|
||||
</script>
|
||||
<div class='yui-d0'>
|
||||
<form method='post' target='hiddenwin'>
|
||||
<table class='table-1 a-left'>
|
||||
<caption class='caption-tl'><?php echo $group->name . $lang->colon . $lang->group->managePriv;?></caption>
|
||||
<tr class='colhead'>
|
||||
<th><?php echo $lang->group->module;?></th>
|
||||
<th><?php echo $lang->group->method;?></th>
|
||||
</tr>
|
||||
<?php foreach($lang->resource as $moduleName => $moduleActions):?>
|
||||
<tr class='f-14px <?php echo cycle('even, bg-yellow');?>'>
|
||||
<th class='a-right'><?php echo $this->lang->$moduleName->common;?> <input type='checkbox' onclick='check(this, "<?php echo $moduleName;?>")'></td>
|
||||
<td id='<?php echo $moduleName;?>' class='pv-10px'>
|
||||
<?php $i = 1;?>
|
||||
<?php foreach($moduleActions as $action => $actionLabel):?>
|
||||
<div class='w-p20 f-left'><input type='checkbox' name='actions[<?php echo $moduleName;?>][]' value='<?php echo $action;?>' <?php if(isset($groupPrivs[$moduleName][$action])) echo "checked";?> />
|
||||
<?php if(isset($lang->group->newPriv[$moduleName][$actionLabel])):?>
|
||||
<font color="#FF0000"><?php echo $lang->$moduleName->$actionLabel;?></font>
|
||||
<?php else:?>
|
||||
<?php echo $lang->$moduleName->$actionLabel;?>
|
||||
<?php endif;?>
|
||||
</div>
|
||||
<?php if(($i % 4) == 0) echo "<div class='c-both'></div>"; $i ++;?>
|
||||
<?php endforeach;?>
|
||||
</td>
|
||||
</tr>
|
||||
<?php endforeach;?>
|
||||
<tr>
|
||||
<th class='rowhead'><?php echo $lang->group->checkall;?><input type='checkbox' onclick='checkall(this);'></th>
|
||||
<td class='a-center'><?php echo html::submitButton($lang->save, 'name="submit"') . html::linkButton($lang->goback, $this->createLink('group', 'browse'));?></td>
|
||||
</tr>
|
||||
</table>
|
||||
</form>
|
||||
</div>
|
||||
<form method='post' target='hiddenwin'>
|
||||
<table class='table-1 a-left'>
|
||||
<caption class='caption-tl'><?php echo $group->name . $lang->colon . $lang->group->managePriv;?></caption>
|
||||
<tr class='colhead'>
|
||||
<th><?php echo $lang->group->module;?></th>
|
||||
<th><?php echo $lang->group->method;?></th>
|
||||
</tr>
|
||||
<?php foreach($lang->resource as $moduleName => $moduleActions):?>
|
||||
<tr class='f-14px <?php echo cycle('even, bg-yellow');?>'>
|
||||
<th class='a-right'><?php echo $this->lang->$moduleName->common;?> <input type='checkbox' onclick='check(this, "<?php echo $moduleName;?>")'></td>
|
||||
<td id='<?php echo $moduleName;?>' class='pv-10px'>
|
||||
<?php $i = 1;?>
|
||||
<?php foreach($moduleActions as $action => $actionLabel):?>
|
||||
<div class='w-p20 f-left'><input type='checkbox' name='actions[<?php echo $moduleName;?>][]' value='<?php echo $action;?>' <?php if(isset($groupPrivs[$moduleName][$action])) echo "checked";?> />
|
||||
<?php if(isset($lang->group->newPriv[$moduleName][$actionLabel])):?>
|
||||
<font color="#FF0000"><?php echo $lang->$moduleName->$actionLabel;?></font>
|
||||
<?php else:?>
|
||||
<?php echo $lang->$moduleName->$actionLabel;?>
|
||||
<?php endif;?>
|
||||
</div>
|
||||
<?php if(($i % 4) == 0) echo "<div class='c-both'></div>"; $i ++;?>
|
||||
<?php endforeach;?>
|
||||
</td>
|
||||
</tr>
|
||||
<?php endforeach;?>
|
||||
<tr>
|
||||
<th class='rowhead'><?php echo $lang->group->checkall;?><input type='checkbox' onclick='checkall(this);'></th>
|
||||
<td class='a-center'><?php echo html::submitButton($lang->save, 'name="submit"') . html::linkButton($lang->goback, $this->createLink('group', 'browse'));?></td>
|
||||
</tr>
|
||||
</table>
|
||||
</form>
|
||||
<?php include '../../common/view/footer.html.php';?>
|
||||
|
||||
Reference in New Issue
Block a user