<!-- BEGIN CONTENT -->
<div class="page-content-wrapper">
    <div class="page-content">
        <!-- BEGIN PAGE HEADER-->
        <h3 class="page-title">
            {$shcontrollname}
        </h3>
        <div class="page-bar">
            <ul class="page-breadcrumb">
                {$breadcrumbs}
            </ul>
        </div>
        <!-- END PAGE HEADER-->
        <!-- BEGIN PAGE CONTENT-->
        <div class="row">
            <div class="col-md-12">
                <div class="portlet light bg-inverse">
                    <div class="portlet-title">
                        <div class="caption">
                            <i class="icon-equalizer font-red-sunglo"></i>
                            <span class="caption-subject font-red-sunglo bold uppercase">Setting in {$shcontrollname} for "{$role->name}"</span>
                        </div>
                        <div class="actions" id="nestable_list_menu">


                            <a class="btn default btn-xs blue tooltips" href="{$hosturl}/controllers/{$controllname}.php?ac=show" data-container="body" data-placement="top" data-original-title="Show">
                                <i class="icon-list"></i>
                                Show items
                            </a>

                        </div>
                    </div>
                    <div class="portlet-body form">
                        <!-- BEGIN FORM-->
                        <form action="{$hosturl}/controllers/{$controllname}.php?ac=insetting" method="post" class="form-horizontal" id="role_form">
                            <div class="form-body">
                                <!-- tabs -->
                                <input type="hidden" name="roleid" value="{$role->id}"/>
                                <div class="row">
                                    <div class="tabbable tabbable-custom tabbable-noborder ">
                                        <ul class="nav nav-tabs">
                                            <li class="active">
                                                <a href="#tab_setting_1" data-toggle="tab">
                                                    <i class="icon-notebook"></i>
                                                    Menu permissions
                                                </a>
                                            </li>
                                            <li>
                                                <a href="#tab_setting_2" data-toggle="tab">
                                                    <i class="icon-crop"></i>
                                                    Controls permissions </a>
                                            </li>

                                            <li>
                                                <a href="#tab_setting_3" data-toggle="tab">
                                                    <i class="icon-crop"></i>
                                                    Buttons  </a>
                                            </li>
                                        </ul>

                                        <div class="tab-content mysettingrole">
                                            <div class="tab-pane active" id="tab_setting_1">
                                                <div class="dd" id="nestable_list_2">
                                                    <ol class="dd-list rolemenucheck">
                                                        {$dismenu}
                                                    </ol>
                                                </div>
                                            </div>

                                            <div class="tab-pane fade" id="tab_setting_2">
                                                <div class="panel-group accordion" id="accordion3">
                                                    {assign var=count value=1}
                                                    <input type="hidden" name="itrcontroll" value="{$controlls|@count}"/>
                                                    {foreach $controlls as $single}
                                                    <div class="panel panel-default">
                                                        <div class="panel-heading">
                                                            <h4 class="panel-title">
                                                                <a class="accordion-toggle accordion-toggle-styled collapsed" data-toggle="collapse" data-parent="#accordion3" href="#collapse_controll_{$count}">
                                                                    {$single->label} </a>
                                                            </h4>
                                                        </div>
                                                        <div id="collapse_controll_{$count}" class="panel-collapse collapse">
                                                            <div class="panel-body">
                                                                <ul class="list-group">
                                                                    {assign var=incount value=1}
                                                                    <input type="hidden" name="itrcontrollprop{$count}" value="{$single->props|@count}"/>
                                                                    {foreach $single->props as $sin }
                                                                    <li class="list-group-item row nomargin custompadding">
                                                                        <div class="col-md-4">
                                                                            <label class="radio-inline"> <i class="icon-arrow-right"></i> {$sin->proplabel}</label></div>
                                                                        <input type="hidden" name="controllpropid{$count}{$incount}" value="{$sin->id}"/>
                                                                        <div  class="col-md-3 pull-right forroleradio">
                                                                            <div class="radio-list">
                                                                                <label class="radio-inline">
                                                                                    <input class="controllcheckyes control_prop_role_item" data-controlpropid="{$sin->id}" type="radio" name="proprolecheck{$count}{$incount}" value="1" {if $sin->rolevalue eq 1} checked {/if}/>
                                                                                    Access </label>
                                                                                <label class="radio-inline">
                                                                                    <input  class="controllcheckno control_prop_role_item" data-controlpropid="{$sin->id}" type="radio" name="proprolecheck{$count}{$incount}" value="0" {if $sin->rolevalue eq 0} checked {/if}/>
                                                                                    Deny</label>
                                                                            </div>
                                                                        </div>
                                                                    </li>
                                                                    {capture assign=incount}{$incount+1}{/capture}
                                                                    {/foreach}
                                                                </ul>
                                                            </div>
                                                        </div>
                                                    </div>
                                                    {capture assign=count}{$count+1}{/capture}
                                                    {/foreach}
                                                </div>

                                            </div>

                                            <div class="tab-pane" id="tab_setting_3">
                                                <div >
                                                    <ol class="dd-list">
                                                        {$drawBtn}
                                                    </ol>
                                                </div>
                                            </div>

                                        </div>

                                    </div>
                                </div>



                            </div>
                            <div class="form-actions">
                                <div class="row">
                                    <div class="col-md-offset-3 col-md-4">
                                    </div>
                                </div>
                            </div>
                        </form>
                        <!-- END FORM-->


                    </div>
                </div>
            </div>
        </div>
        <!-- END PAGE CONTENT-->
    </div>
</div>
<!-- END CONTENT -->