rhymix/modules/point/tpl/config.html
Kijin Sung a22e69b7ec Merge branch 'develop' of https://github.com/xpressengine/xe-core (1.8.14)
Conflicts:
	classes/context/Context.class.php
	modules/point/tpl/config.html
2015-12-02 14:38:23 +09:00

201 lines
9.8 KiB
HTML

<!--#include("./header.html")-->
<div cond="$XE_VALIDATOR_MESSAGE && $XE_VALIDATOR_ID == 'modules/point/tpl/config/1'" class="message {$XE_VALIDATOR_MESSAGE_TYPE}">
<p>{$XE_VALIDATOR_MESSAGE}</p>
</div>
<form ruleset="insertConfig" action="./" method="post" id="point_module_config_form" class="x_form-horizontal">
<input type="hidden" name="module" value="point" />
<input type="hidden" name="act" value="procPointAdminInsertConfig" />
<input type="hidden" name="xe_validator_id" value="modules/point/tpl/config/1" />
<section class="section default">
<h1>{$lang->is_default}</h1>
<div class="x_control-group module_io">
<label for="able_module" class="x_control-label">{$lang->point_io}</label>
<div class="x_controls" style="padding-top:3px">
<input type="checkbox" name="able_module" id="able_module" value="Y" checked="checked"|cond="!$config->able_module||$config->able_module=='Y'" />
<span class="x_help-inline">{$lang->about_point_io}</span>
</div>
</div>
<div class="x_control-group">
<label for="max_level" class="x_control-label">{$lang->max_level}</label>
<div class="x_controls">
<input type="number" min="0" max="1000" value="{$config->max_level}" name="max_level" id="max_level" />
{$lang->about_max_level}
</div>
</div>
<div class="x_control-group">
<label for="point_name" class="x_control-label">{$lang->point_name}</label>
<div class="x_controls">
<input type="text" value="{$config->point_name}" name="point_name" id="point_name" style="width:50px" />
{$lang->about_point_name}
</div>
</div>
<div class="x_control-group">
<label class="x_control-label">{$lang->give_point}</label>
<div class="x_controls">
<input type="number" value="{$config->signup_point}" name="signup_point" id="signup_point" style="text-align:right" /> :
<label for="signup_point" class="x_inline">{$lang->point_signup}</label>
<br />
<input type="number" value="{$config->login_point}" name="login_point" id="login_point" style="text-align:right" /> :
<label for="login_point" class="x_inline">{$lang->cmd_login}</label>
<br />
<input type="number" name="insert_document" value="{$config->insert_document}" id="insert_document" style="text-align:right" /> :
<label for="insert_document" class="x_inline">{$lang->point_insert_document}</label>
<br />
<input type="number" name="insert_comment" value="{$config->insert_comment}" id="insert_comment" style="text-align:right" /> :
<label for="insert_comment" class="x_inline">{$lang->point_insert_comment}</label>
<br />
<input type="number" name="upload_file" value="{$config->upload_file}" id="upload_file" style="text-align:right" /> :
<label for="upload_file" class="x_inline">{$lang->point_upload_file}</label>
<br />
<input type="number" name="download_file" value="{$config->download_file}" id="download_file" style="text-align:right" /> :
<label for="download_file" class="x_inline">{$lang->point_download_file}</label>
<br />
<input type="number" name="read_document" value="{$config->read_document}" id="read_document" style="text-align:right" /> :
<label for="read_document" class="x_inline">{$lang->point_read_document}</label>
<br />
<input type="number" name="voted" value="{$config->voted}" style="text-align:right" id="voted" /> :
<label for="voted" class="x_inline">{$lang->point_voted}</label>
<br />
<input type="number" name="blamed" value="{$config->blamed}" id="blamed" style="text-align:right" /> :
<label for="blamed" class="x_inline">{$lang->point_blamed}</label>
<br />
<input type="number" name="voted_comment" value="{$config->voted_comment}" style="text-align:right" id="voted_comment" /> :
<label for="voted_comment" class="x_inline">{$lang->comment} {$lang->point_voted}</label>
<br />
<input type="number" name="blamed_comment" value="{$config->blamed_comment}" id="blamed_comment" style="text-align:right" /> :
<label for="blamed_comment" class="x_inline">{$lang->comment} {$lang->point_blamed}</label>
</div>
</div>
<div class="x_control-group">
<label for="level_icon" class="x_control-label">{$lang->level_icon}</label>
<div class="x_controls">
<select name="level_icon" id="level_icon">
<!--@foreach($level_icon_list as $key => $val)-->
<option value="{$val}" selected="selected"|cond="$config->level_icon == $val">{$val}</option>
<!--@end-->
</select>
<span class="x_help-inline">{$lang->about_level_icon}</span>
</div>
</div>
<div class="x_control-group">
<label for="disable_download" class="x_control-label">{$lang->disable_download}</label>
<div class="x_controls" style="padding-top:3px">
<input type="checkbox" name="disable_download" id="disable_download" value="Y" checked="checked"|cond="$config->disable_download=='Y'" />
{$lang->about_disable_download}
</div>
</div>
<div class="x_control-group">
<label for="disable_read_document" class="x_control-label">{$lang->disable_read_document}</label>
<div class="x_controls" style="padding-top:3px">
<input type="checkbox" name="disable_read_document" id="disable_read_document" value="Y" checked="checked"|cond="$config->disable_read_document=='Y'" />
{$lang->about_disable_read_document}
</div>
</div>
<div class="x_clearfix btnArea">
<span class="x_pull-right"><input class="x_btn x_btn-primary" type="submit" value="{$lang->cmd_save}" /></span>
</div>
</section>
<section class="section">
<h1>{$lang->point_link_group}</h1>
<div class="x_clearfix" style="margin-bottom:-10px">
<p class="x_pull-left">{$lang->about_point_link_group}</p>
<div class="x_pull-right">
<label for="group_reset_y" class="x_inline"><input type="radio" name="group_reset" id="group_reset_y" value="Y" checked="checked"|cond="$config->group_reset != 'N'" /> {$lang->point_group_reset_and_add}</label>
<label for="group_reset_n" class="x_inline"><input type="radio" name="group_reset" id="group_reset_n" value="N" checked="checked"|cond="$config->group_reset == 'N'" /> {$lang->point_group_add_only}</label>
</div>
</div>
<div class="x_control-group" loop="$group_list => $key,$val">
<label class="x_control-label" for="point_group_{$key}">{$val->title}</label>
<div class="x_controls">
<input cond="$val->is_default != 'Y'" type="number" min="0" max="1000" value="{$config->point_group[$key]}" name="point_group_{$key}" id="point_group_{$key}" style="width:50px" />
&nbsp;{$lang->level}
<span cond="$val->is_default == 'Y'" style="display:inline-block;padding-top:3px">{$lang->default_group}</span>
</div>
</div>
<div class="x_clearfix btnArea">
<span class="x_pull-right"><input class="x_btn x_btn-primary" type="submit" value="{$lang->cmd_save}" /></span>
</div>
</section>
<section class="section">
{@$point_group = @array_flip($config->point_group)}
<h1>{$lang->level_point}</h1>
<div class="x_clearfix">
<p class="x_pull-left">{$lang->expression}</p>
<span class="x_pull-right x_input-append">
<input type="text" value="{$config->expression}" placeholder="Math.pow(i,2) * 90" size="30" class="level_expression" />
<button type="button" class="x_btn calc_point">{$lang->level_point_calc}</button>
<button type="button" class="x_btn calc_point _reset">{$lang->cmd_exp_reset}</button>
</span>
</div>
<table class="x_table x_table-striped x_table-hover">
<tr>
<th scope="col">{$lang->level}</th>
<th scope="col">{$lang->level_icon}</th>
<th scope="col">{$lang->point}</th>
<th scope="col">{$lang->member_group}</th>
</tr>
<tr>
<td>1</td>
<td><img src="{getUrl()}/modules/point/icons/{$config->level_icon}/1.gif" alt="1" /></td>
<td><label for="level_step_1" style="margin:0"><input type="number" id="level_step_1" name="level_step_1" value="{$config->level_step[1]}" style="width:120px;text-align:right" /> {$config->point_name}</label></td>
{@$point_group_item = $point_group[1]}
{@$title=array()}
<!--@if($point_group_item)-->
<!--@if($config->group_reset != 'N')-->
{@$title[0] = $group_list[$point_group_item.'']->title}
<!--@else-->
{@$title[] = $group_list[$point_group_item.'']->title}
<!--@end-->
<!--@end-->
<td>{implode(', ', $title)}</td>
</tr>
<!--@for($i=2;$i<=$config->max_level;$i++)-->
{@$point_group_item = $point_group[$i]}
<!--@if($point_group_item)-->
<!--@if($config->group_reset != 'N')-->
{@$title[0] = $group_list[$point_group_item.'']->title}
<!--@else-->
{@$title[] = $group_list[$point_group_item.'']->title}
<!--@end-->
<!--@end-->
<tr class="row{(($i-1)%2+1)}">
<td>{$i}</td>
<td><img src="{getUrl()}/modules/point/icons/{$config->level_icon}/{$i}.gif" alt="{$i}" /></td>
<td><label for="level_step_{$i}" style="margin:0"><input type="number" id="level_step_{$i}" name="level_step_{$i}" value="{$config->level_step[$i]}" style="width:120px;text-align:right" /> {$config->point_name}</label></td>
<td>{implode(', ', $title)}</td>
</tr>
<!--@end-->
</table>
<div class="x_clearfix">
<span class="x_pull-right"><input class="x_btn x_btn-primary" type="submit" value="{$lang->cmd_save}" /></span>
</div>
</section>
<section class="section">
<h1>{$lang->cmd_point_recal}</h1>
<p><input class="x_btn x_btn-warning" type="button" value="{$lang->cmd_point_recal}" onclick="doPointRecal()" /></p>
<p>{$lang->about_cmd_point_recal}</p>
<p id="pointReCal"></p>
</section>
</form>
<script>
jQuery(function($){
var point_module_cfg = $('#point_module_config_form .default .x_control-group:not(.module_io), #point_module_config_form .section:not(.default),.x_nav-tabs>li:not(.x_active)');
if(!$('#able_module').is(':checked'))
{
point_module_cfg.hide();
}
$('#able_module').change(function(){
if($(this).is(':checked')){
point_module_cfg.slideDown(200);
} else {
point_module_cfg.slideUp(200);
}
});
});
</script>
<div class="admin-forum-container" data-chak-categories="XE설정:포인트"></div>