{template "header.html"}

<link href="{THEME_PATH}assets/global/plugins/bootstrap-daterangepicker/daterangepicker.min.css" rel="stylesheet" type="text/css" />
<link href="{THEME_PATH}assets/global/plugins/bootstrap-datepicker/css/bootstrap-datepicker3.min.css" rel="stylesheet" type="text/css" />
<link href="{THEME_PATH}assets/global/plugins/bootstrap-timepicker/css/bootstrap-timepicker.min.css" rel="stylesheet" type="text/css" />
<link href="{THEME_PATH}assets/global/plugins/bootstrap-datetimepicker/css/bootstrap-datetimepicker.min.css" rel="stylesheet" type="text/css" />
<script src="{THEME_PATH}assets/global/plugins/bootstrap-datepicker/js/bootstrap-datepicker.finecms.js" type="text/javascript"></script>

<script type="text/javascript">
    if (App.isAngularJsApp() === false) {
        jQuery(document).ready(function() {
            if (jQuery().datepicker) {
                $('.date-picker').datepicker({
                    rtl: App.isRTL(),
                    orientation: "left",
                    autoclose: true
                });
            }
        });
    }
</script>

<div class="note note-danger">
    <p>确保网站目录必须有可写权限</p>
</div>

<div class="portlet light bordered " style="margin-bottom: 30px">
    <div class="portlet-title">
        <div class="caption">
            <i class="fa fa-home font-dark"></i>
            <span class="caption-subject font-dark"> {dr_lang('网站')}</span>
        </div>
    </div>
    <div class="portlet-body">
        <label><button type="button" onclick="dr_admin_menu_ajax('/index.php?c=home&m=html', 1)" class="btn blue"> <i class="fa fa-file-o"></i> {dr_lang('生成首页')} </button></label>

        <label><button type="button" onclick="dr_bfb('{dr_lang('生成共享栏目')}', '', '{dr_url('html/category_index')}')" class="btn green"> <i class="fa fa-reorder"></i> {dr_lang('生成共享栏目')} </button></label>
    </div>
</div>

{loop $module $i $mod}
<div class="portlet light bordered">
    <div class="portlet-title">
        <div class="caption">
            <i class="{$mod.icon} font-dark"></i>
            <span class="caption-subject font-dark"> {$mod.name}</span>
        </div>
    </div>
    <div class="portlet-body">
        <form id="myform{$i}">
            <div class="form-body">
                <div class="form-group row">

                    {if !$mod.share}
                        <div class="col-md-3">
                            <label><button type="button" onclick="dr_admin_menu_ajax('/index.php?s={$mod.dirname}&c=html&m=index', 1)" class="btn blue"> <i class="fa fa-home"></i> {dr_lang('生成模块首页')} </button></label>

                            <label><button type="button" onclick="dr_bfb('{dr_lang('生成栏目')}', '', '{dr_url('html/category_index')}&app={$mod.dirname}')" class="btn green"> <i class="fa fa-reorder"></i> {dr_lang('生成栏目')} </button></label>

                        </div>
                    {/if}
                    <div class="col-md-3">

                        <div class="input-group date-picker input-daterange" data-date="" data-date-format="yyyy-mm-dd">
                            <input type="text" class="form-control" value="{$param.date_form}" name="date_form">
                            <span class="input-group-addon"> {dr_lang('到')} </span>
                            <input type="text" class="form-control" value="{$param.date_to}" name="date_to">
                        </div>
                    </div>
                    <label class="col-md-1 control-label">
                        <button type="button" onclick="dr_bfb('{dr_lang('生成内容')}', 'myform{$i}', '{dr_url('html/show_index')}&app={$mod.dirname}')" class="btn dark"> <i class="fa fa-th-large"></i> {dr_lang('生成内容')} </button>
                    </label>
                </div>
            </div>
        </form>
    </div>
</div>
{/loop}

{template "footer.html"}