{% extends "base_page_frame.html" %}
{% block headjs %}
<link href="{{ MEDIA_URL }}/css/drag.css" rel="stylesheet" type="text/css" />
<script src="{{ MEDIA_URL }}/jslib/CDrag.js"></script>
<script src="{{ MEDIA_URL }}/jslib/excanvas.js"></script>
<script src="{{ MEDIA_URL }}/jslib/jquery.plot.js"></script>
<script src="{{ MEDIA_URL }}/jslib/worktable.js"></script>
<script type="text/javascript">
$(function(){
 	$("body").removeClass("indexBody");
	if($.browser.msie && parseFloat($.browser.version)>6){
		$("body").css({overflow:"hidden"})
	}		
    $("#DEL_CDrag").show();
    $("#ADD_CDrag").show();
    $(".icon_help_current").show();
    var surl="{{ request.surl }}";
    var dbapp_url="{{ request.dbapp_url }}";
    init_common_opt(surl,dbapp_url);
    {% if "mysite.att"|hasApp %}
        init_commom_search(surl,dbapp_url);
    {% endif %}
   // init_specday(surl,dbapp_url);
   // init_overtime(surl,dbapp_url);
   // init_checkexact(surl,dbapp_url);
   // alert("{{ LANGUAGE_CODE }}")
    //如果选择英文的就不让显示
    if($("#install_language").html()!="zh-cn"){
        $("#en_display_show").remove();
//        $("#en_displayN").html("ds");
        $("#en_displayN").attr("class","displayN");
        $("#en_displayN").next().attr("class","displayN");
    }
    
    //$("#en_displayN").remove();
   
    $("#id_panels").show();
});

</script>
{% endblock %}
{% load i18n %}
{% load dbapp_tags %}
{% block datalist_content %}

<div id="id_panels" class="rightBox1 displayN">
    <div class="move" id="root_row">
        <div class="div_title">
            <div class="title_close" title="{% trans '关闭' %}">
                <a href="#"></a>
            </div>
            <div class="title_minimize">
                <a href="#">
                </a>
            </div>
            <div class="title_a">　
            </div>
        </div>
        <div class="content">
        </div>
        
    </div>

   
    <div class="root">
        <div id="id_edit_container"></div><!-- 编辑用的div -->
        <div class="tools" >
            <!-- 获取安装信息，显示隐藏相应的模块 -->
            <a  id="install_language" class="displayN">{{installed_language}}</a>
            <a id="DEL_CDrag" class="displayN" href="javascript:void(0);">{% trans "[还原工作面板]" %}
            </a>&nbsp;&nbsp;
            <a id="ADD_CDrag" class="displayN" href="javascript:void(0);">{% trans "[自定义工作面板]" %}
            </a>
            <a href="{{ request.dbapp_url }}system/help/?p=/file/{{ LANGUAGE_CODE }}/help/worktable.html" target="_blank" title="{% trans '当前页帮助' %}" class="icon_help_current">&nbsp;
            </a>
        </div>
        <div class="cell_left floatL" id="m_1">
            <div class="line">　
            </div>
            <div style="line-height:1px;height:1px; overflow:hidden">&nbsp;
            </div>
            <div class="move" id="m_1_1_common_opt" style="display:block;">
                <div class="div_title">
                    <div class="title_close" title="{% trans '关闭' %}">
                        <a href="#"></a>
                    </div>
                    <div class="title_minimize">
                        <a href="#">
                        </a>
                    </div>
                    <div class="title_a">　
                    </div>
                </div>
                <div class="content">
                    <div id="id_common_opt">
                    	<table class="commom_opt commom_panel Link_blue1">
                            <tr>
                                <td>
                                    {% if request.user|HasPerm:"personnel.add_employee" %}
                                         <a href="javascript:void(0)" relgo="{{request.dbapp_url}}personnel/Employee/_new_/?_lock=1">{% trans "新增人员" %} </a>
                                    {% endif %}
                                </td>
                                <td>
                                    {% if  request.user|HasPerm:"personnel.add_issuecard"%}
                                         <a href="javascript:void(0)" relgo="{{request.dbapp_url}}personnel/IssueCard/_new_/">{% trans "人员发卡"  %} </a>
                                    {% endif %}
                                </td>
                            </tr>
                            <tr>
                                <td>
                                    {% if request.user|HasPerm:"personnel.add_department" %}
                                    <a href="javascript:void(0)" relgo="{{request.dbapp_url}}personnel/Department/_new_/"> {% trans "新增部门" %} </a>
                                    {% endif %}
                                </td>
                                
                                <td>
                                    {% if request.user|HasPerm:"personnel.add_area" %}
                                         <a   href="javascript:void(0)" relgo="{{request.dbapp_url}}personnel/Area/_new_/?_lock=1">{% trans "新增区域" %} </a>
                                    {% endif %}
                                </td>
                            </tr>
                    
                            {% if "mysite.att"|hasApp %}
                            <tr>
                                <td>
                                {% if not "mysite"|is_zkaccess_5to4 %}
                                    {% if request.user|HasPerm:"personnel.opregisterfinger_employee" %}
                                         <a   href="javascript:void(0)" relgoopt="{{request.dbapp_url}}personnel/Employee/_op_/OpRegisterFinger/"> {% trans "指纹登记" %} </a>
                                    {% endif %}
                                {% endif %}
                                </td>
                                
                                <td>
                                    {% if "mysite.att"|hasApp and not "mysite"|is_zkaccess_att and request.user|HasPerm:"personnel.add_leavelog" %}
                                         <a target="_blank"  href="javascript:void(0)" relgo="{{request.dbapp_url}}personnel/LeaveLog/_new_/">{% trans "新增人员离职" %} </a>
                                    {% endif %}
                                </td>
                            </tr>
                            <tr>
                                <td>
                                    {% if "mysite.att"|hasApp and not "mysite"|is_zkaccess_att and request.user|HasPerm:"att.opaddmanycheckexact_checkexact" %}
                                         <a href="javascript:void(0)" relgo="{{request.dbapp_url}}att/CheckExact/_op_/OpAddManyCheckExact/?_lock=1">{% trans "新增补签卡" %} </a>
                                    {% endif %}
                                </td>
                                {% if "mysite.att"|hasApp and not "mysite"|is_zkaccess_att %}
                                <td>
                                    {% if request.user|HasPerm:"att.opaddmanyuserid_empspecday" %}
                                        <a  href="javascript:void(0)" relgo="{{request.dbapp_url}}att/EmpSpecDay/_op_/OpAddManyUserID/?_lock=1">{% trans "请假" %} </a>
                                    {% endif %}
                                </td>
                                <td>
                                    {% if request.user|HasPerm:"contenttypes.can_AttCalculate" %}
                                         <a target="_blank" href="/{{request.surl}}att/AttCalculate/">{% trans "考勤计算" %} </a>
                                    {% endif %}
                                </td>
                                {% endif %}
                            </tr>
                            {% endif %}
                            
                            {% if "mysite.iaccess"|hasApp %}
                            <tr>
                                <td>
                                    {% if request.user|HasPerm:"iaccess.browse_accrtmonitor" %}
                                    <a target="_blank" href="/{{request.surl}}iaccess/ReportFormPage/">{% if "mysite.iaccess&mysite.att"|hasApp %}{% trans "查看门禁报表" %}{% else %}{% if "mysite.iaccess"|hasApp %}{% trans "查看报表" %}{% endif %}{% endif %}</a>
                                    {% endif %}
                                </td>
                                <td>
                                    {% if request.user|HasPerm:"contenttypes.can_DevRTMonitorPage" %}
                                    <a target="_blank" href="/{{request.surl}}iclock/DevRTMonitorPage/">{% if "mysite.iaccess&mysite.att"|hasApp %}{% trans "门禁设备监控" %}{% else %}{% if "mysite.iaccess"|hasApp %}{% trans "设备监控" %}{% endif %}{% endif %}</a>
                                    {% endif %}
                                </td>
                            </tr>
                            <tr>
                                <td>
                                    {% if request.user|HasPerm:"iaccess.add_accholidays" %}
                                        <a href="javascript:void(0)" relgo="{{request.dbapp_url}}iaccess/AccHolidays/_new_/?_lock=1">{% if "mysite.iaccess&mysite.att"|hasApp %}{% trans "新增门禁节假日" %}{% else %}{% if "mysite.iaccess"|hasApp %}{% trans "新增节假日" %}{% endif %}{% endif %}</a>
                                    {% endif %}
                                </td>
                            </tr>
                            
                            {% endif %}
                            <tr>
                            </tr>
                        </table>
                    </div>
                </div>
            </div>
            
            {% if "mysite.att"|hasApp and not "mysite"|is_zkaccess_att %}
                <div class="move" id="m_1_2_common_search" style="display:block;">
                    <div class="div_title">
                        <div class="title_close" title="{% trans '关闭' %}">
                            <a href="#"></a>
                        </div>
                        <div class="title_minimize">
                            <a href="#">
                            </a>
                        </div>
                        <div class="title_a">　
                        </div>
                    </div>
                    <div class="content">
                        	<table class="commom_search commom_panel Link_blue1">
                        		<tr>
                        			<td>
                        				{% if request.user|HasPerm:"personnel.browse_employee" %}
                        					 <a href="javascript:void(0)" searchfield="employee_num" relgo="/{{request.surl}}worktable/get_search_form/personnel/Employee/">
                        					 {% trans "人员查询" %}</a>
                        				{% endif %}
                        			</td>
                        			<td>
                        				{% if request.user|HasPerm:"personnel.browse_employee" %}
                        					 <a href="javascript:void(0)" searchfield="identitycard" relgo="/{{request.surl}}worktable/get_search_form/personnel/Employee/">
                        					 {% trans "身份证号查询" %}</a>
                        				{% endif %}
                        			</td>
                        		</tr>
                                <tr>
                                    <td>
                                        {% if request.user|HasPerm:"personnel.browse_issuecard" %}
                                             <a href="javascript:void(0)" searchfield="issuecard" relgo="/{{request.surl}}worktable/get_search_form/personnel/IssueCard/">{% trans "卡片查询" %} </a>
                                        {% endif %}
                                    </td>
                                    
                                    <td>
                                        {% if request.user|HasPerm:"personnel.browse_department" %}
                                             <a href="javascript:void(0)" searchfield="department" relgo="/{{request.surl}}worktable/get_search_form/personnel/Department/">{% trans "部门查询" %} </a>
                                        {% endif %}
                                    </td>
                                </tr>
                                {% if  "mysite.att"|hasApp %}
                                    <tr>
                                        <td>
                                            {% if request.user|HasPerm:"iclock.browse_device" %}
                                                 <a href="javascript:void(0)" searchfield="device" relgo="/{{request.surl}}worktable/get_search_form/iclock/Device/?device_type__exact=1">{% trans "考勤设备查询" %}</a>
                                            {% endif %}
                                        </td>
                                    
                                        <td>
                                            {% if request.user|HasPerm:"personnel.browse_leavelog" %}
                                                 <a href="javascript:void(0)"  searchfield="leave" relgo="/{{request.surl}}worktable/get_search_form/personnel/LeaveLog/">{% trans "离职人员查询" %} </a>
                                            {% endif %}
                                        </td>
                                    </tr>
                                    <tr>
                                        <td>
                                            {% if request.user|HasPerm:"iclock.browse_transaction" %}
                                                 <a href="javascript:void(0)" searchfield="translog" relgo="/{{request.surl}}worktable/get_search_form/iclock/Transaction/">{% trans "考勤原始数据查询" %} </a>
                                            {% endif %}
                                        </td>
                                        
                                        <td>
                                            {% if request.user|HasPerm:"personnel.browse_empchange" %}
                                                
                                                 <a id ="en_display_show" href="javascript:void(0)" searchfield="empchange" relgo="/{{request.surl}}worktable/get_search_form/personnel/EmpChange/">{% trans "员工调动查询" %}</a>
                                            {% endif %}
                                        </td>
                                    </tr>
                                    
                                    <tr>
                                        <td>
                                            {% if request.user|HasPerm:"att.browse_checkexact" %}
                                                 <a href="javascript:void(0)" searchfield="checkexact" relgo="/{{request.surl}}worktable/get_search_form/att/CheckExact/">{% trans "补签卡查询" %}</a>
                                            {% endif %}
                                        </td>
                                        <td>
                                            
                                        </td>
                                    </tr>
                                {% endif %}
                                
                            </table>
                    </div>
                </div>
            {% endif %}
            
            {% if not "mysite.att"|hasApp or "mysite"|is_zkaccess_att or not request.user|HasPerm:"personnel.add_employee"  or not request.user|HasPerm:"att.add_num_run" or not request.user|HasPerm:"contenttypes.can_AttCalculate" or not request.user|HasPerm:"iclock.add_device" or not request.user|HasPerm:"att.add_schclass" or not request.user|HasPerm:"att.opadduserofrun_user_of_run" and not request.user|HasPerm:"att.opaddtempshifts_user_of_run" %}
            {% else %}
            <div class="move" id="m_1_3_attquickstart" style="display:block;">
               <div class="div_title">
                   <div class="title_close" title="{% trans '关闭' %}">
                       <a href="#"></a>
                   </div>
                   <div class="title_minimize">
                       <a href="#">
                       </a>
                   </div>
                   <div class="title_a">　
                   </div>
               </div>
               <div class="content">
                   <table class="commom_panel Link_blue1">
                   		<tr>
                   			<td>
                                    <a target="_blank"  href="{{request.dbapp_url}}personnel/Employee/">{% trans "第一步:人员管理" %} </a>
                   			</td>
                   			<td>
                                    <a  target="_blank" href="{{request.dbapp_url}}iclock/device/">{% trans "第四步:设备管理" %} </a>
                   			</td>
                   		</tr>
                        <tr>
                            <td>
                                     <a target="_blank"  href="{{request.dbapp_url}}att/SchClass/">{% trans "第二步:时段设置" %} </a>
                            </td>
                            <td>
                                     <a  target="_blank" href="../../att/AttUserOfRun/">{% trans "第五步:为员工指定班次" %} </a>
                            </td>
                        </tr>
                        <tr>
                            <td>
                                     <a target="_blank"  href="{{request.dbapp_url}}att/NUM_RUN/">{% trans "第三步:班次设置" %}</a>
                            </td>
                            <td>
                                     <a target="_blank"  href="../../att/AttCalculate/">{% trans "第六步:考勤计算与报表" %} </a>
                                
                            </td>
                        </tr>	
                    </table>
               </div>
           </div>
           {% endif %}
        </div>
        <div class="cell_center floatR" id="m_2">
            <div class="line">　
            </div>
            <div style="line-height:1px;height:1px; overflow:hidden">&nbsp;
            </div>
            {% if "mysite.att"|hasApp and not "mysite"|is_zkaccess_att %}
                <div class="move" id="m_2_1_common_monitor" style="display:block;">
                   <div class="div_title">
                       <div class="title_close" title="{% trans '关闭' %}">
                           <a href="#"></a>
                       </div>
                       <div class="title_minimize">
                           <a href="#">
                           </a>
                       </div>
                       <div class="title_a">　
                       </div>
                   </div>
                   <div class="content">
                       <div class="common_monitor Link_blue1">
                       	<div id="id_datalist"></div>
                       </div>
                   </div>
                </div>
            {% endif %}
            
            {% if not "mysite.att"|hasApp or not request.user|HasPerm:"personnel.browse_employee" %}
            {% else %}
            <div class="move" id="m_2_2_empstructure" style="display:none;">
               <div class="div_title">
                   <div class="title_close" title="{% trans '关闭' %}">
                       <a href="#"></a>
                   </div>
                   <div class="title_minimize">
                       <a href="#">
                       </a>
                   </div>
                   <div class="title_a">　
                   </div>
               </div>
               <div class="content">
                    <div id="id_category">
                        <input type="radio" name="imgCategory" checked="checked" value='1' /><span>{% trans '按工龄' %} </span>
                        <input type="radio" name="imgCategory" value='2' /><span>{% trans '按性别' %} </span>
                        <input id="en_displayN"  type="radio" name="imgCategory" value='3' /><span>{% trans '按学历' %}</span>
                    </div>
                    <br />
                   <div id="id_empstructure" style="width:450px;height:200px;">
                   </div>
               </div>
            </div>
            {% endif %}

            {% if not "mysite.att"|hasApp or "mysite"|is_zkaccess_att or not request.user|HasPerm:"contenttypes.can_AttCalculate" %}
            {% else %}
                <div class="move" id="m_2_3_attrate" style="display:block;">
                   <div class="div_title">
                       <div class="title_close" title="{% trans '关闭' %}">
                           <a href="#"></a>
                       </div>
                       <div class="title_minimize">
                           <a href="#">
                           </a>
                       </div>
                       <div class="title_a">　
                       </div>
                   </div>
                   <div class="content">
                       <div id="id_attrate" style="width:450px;height:200px;">
                       </div>
                   </div>
                </div>
            {% endif %}
            {% if not "mysite.iaccess"|hasApp or not request.user|HasPerm:"iaccess.add_acctimeseg" or not request.user|HasPerm:"iaccess.add_acclevelset" or not request.user|HasPerm:"personnel.add_employee" or not request.user|HasPerm:"iclock.add_device" or not request.user|HasPerm:"iaccess.add_accholidays" or not request.user|HasPerm:"contenttypes.can_EmpLevelSetPage" or not request.user|HasPerm:"contenttypes.can_DoorSetPage" or not request.user|HasPerm:"contenttypes.can_RTMonitorPage" %}
            {% else %}
                <div class="move" id="m_2_4_accquickstart" style="display:block;">
                   <div class="div_title">
                       <div class="title_close" title="{% trans '关闭' %}">
                           <a href="#"></a>
                       </div>
                       <div class="title_minimize">
                           <a href="#">
                           </a>
                       </div>
                       <div class="title_a">　
                       </div>
                   </div>
                   <div class="content">
                       <div id="id_accquickstart"><!-- style="width:450px;height:100px;"-->
                            <table id="accquickstart" class="commom_panel Link_blue1">
                               <tr>
                               			<td>
                               				{% if request.user|HasPerm:"iclock.add_device" %}
                               					 <a  href="{{request.dbapp_url}}iclock/device/"  target="_blank">{% trans "第一步:设备管理" %}</a>
                               				{% endif %}
                               			</td>
                               			<td>
                               				{% if request.user|HasPerm:"contenttypes.can_DoorSetPage" %}
                               					 <a  href="/{{request.surl}}iaccess/DoorSetPage/"  target="_blank">{% trans "第五步:门设置" %}</a>
                               				{% endif %}
                               			</td>
                               		</tr>
                               		<tr>
                               			<td>
                               				{% if request.user|HasPerm:"personnel.add_employee" %}
                               					 <a  href="{{request.dbapp_url}}personnel/Employee/"  target="_blank">{% trans "第二步:人员管理" %}</a>
                               				{% endif %}
                               			</td>
                               			<td>
                               				{% if request.user|HasPerm:"iaccess.add_acclevelset" %}
                               				     <a  href="{{request.dbapp_url}}iaccess/AccLevelSet/" target="_blank">{% trans "第六步:建立门禁权限组" %} </a>
                               				{% endif %}
                               			</td>
                               		</tr>
                               		<tr>
                               			<td>
                               				{% if request.user|HasPerm:"iaccess.add_acctimeseg" %}
                               					 <a  href="{{request.dbapp_url}}iaccess/AccTimeSeg/" target="_blank">{% trans "第三步:时间段设置" %} </a>
                               				{% endif %}
                               			</td>
                               			<td>
                               				{% if request.user|HasPerm:"contenttypes.can_EmpLevelSetPage" %}
                               				     <a  href="/{{request.surl}}iaccess/EmpLevelSetPage/" target="_blank">{% trans "第七步:人员门禁权限设置" %} </a>
                               				{% endif %}
                               			</td>
                               		</tr>	
                               
                               		<tr>
                               			<td>
                               				{% if request.user|HasPerm:"iaccess.add_accholidays" %}
                               					 <a  href="{{request.dbapp_url}}iaccess/AccHolidays/" target="_blank">{% trans "第四步:节假日设置" %} </a>
                               				{% endif %}
                               			</td>
                               			<td>
                               				{% if request.user|HasPerm:"contenttypes.can_RTMonitorPage" %}
                               					   <a  href="../../iaccess/RTMonitorPage/" target="_blank">{% trans "第八步:实时监控" %} </a>
                               				{% endif %}
                               			</td>
                               		</tr>
                            </table>
                       </div>
                   </div>
                </div>
            {% endif %}
            
            
            </div>
        <div class="clearB">
        </div>
    </div>
</div>

{% endblock %}
