{{include file="public/header" /}}

<!-- right content start  -->
<div class="content-right">
    <div class="content">
        <!-- form start -->
        <form class="am-form form-validation view-save" action="{{:PluginsAdminUrl('userloginrewardintegral', 'admin', 'save')}}" method="POST" request-type="ajax-url" request-value="{{:PluginsAdminUrl('userloginrewardintegral', 'admin', 'index')}}" enctype="multipart/form-data">
            <legend>
                <span class="fs-16">登录奖励积分</span>
                <a href="{{:PluginsAdminUrl('userloginrewardintegral', 'admin', 'index')}}" class="fr fs-14 m-t-5 am-icon-mail-reply"> 返回</a>
            </legend>

            <div class="am-form-group">
                <label>奖励积分</label>
                <input type="number" name="give_integral" placeholder="奖励积分" min="1" max="100000000" data-validation-message="奖励积分 1~100000000" class="am-radius" value="{{if empty($data)}}1{{else /}}{{$data.give_integral}}{{/if}}" required />
            </div>

            <div class="am-form-group">
                <label>是否日/次<span class="fs-12 fw-100 cr-999">（默认当日只赠送一次）</span></label>
                <div>
                    {{foreach $is_whether_list as $v}}
                        <label class="am-radio-inline m-r-10">
                            <input type="radio" name="is_day_once" value="{{$v.id}}" {{if isset($data['is_day_once']) and $data['is_day_once'] eq $v['id']}}checked="checked"{{else /}}{{if !isset($data['is_day_once']) and isset($v['checked']) and $v['checked'] eq true}}checked="checked"{{/if}}{{/if}} data-am-ucheck /> {{$v.name}}
                        </label>
                    {{/foreach}}
                </div>
            </div>

            <div class="am-form-group">
                <label>有效时间<span class="fs-12 fw-100 cr-999">（留空则不限制）</span></label>
                <div class="form-date">
                    <input type="text" autocomplete="off" name="time_start" class="Wdate am-radius" placeholder="起始时间" onclick="WdatePicker({firstDayOfWeek:1,dateFmt:'yyyy-MM-dd HH:mm:ss'})" {{if !empty($data['time_start'])}}value="{{$data.time_start}}"{{/if}}/>
                    <span>~</span>
                    <input type="text" autocomplete="off" class="Wdate am-radius" placeholder="结束时间" name="time_end" onclick="WdatePicker({firstDayOfWeek:1,dateFmt:'yyyy-MM-dd HH:mm:ss'})" {{if !empty($data['time_end'])}}value="{{$data.time_end}}"{{/if}}/>
                </div>
            </div>

            <div class="am-form-group">
                <button type="submit" class="am-btn am-btn-primary am-radius btn-loading-example am-btn-sm w100" data-am-loading="{loadingText:'处理中...'}">保存</button>
            </div>
        </form>
        <!-- form end -->
    </div>
</div>
<!-- right content end  -->
        
<!-- footer start -->
{{include file="public/footer" /}}
<!-- footer end -->