<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en">
<head>
	<meta http-equiv="Content-Type" content="text/html;charset=UTF-8">
	<title>{#$title#}</title>
	<meta name="author" content="骑士CMS" />
	<meta name="copyright" content="74cms.com" />
	<link rel="shortcut icon" href="{#$QISHI.site_dir#}favicon.ico" />
	<link rel="stylesheet" href="{#$QISHI.site_template#}css/user_common.css" />
	<link rel="stylesheet" href="{#$QISHI.site_template#}css/user_company.css" />
	<link rel="stylesheet" href="{#$QISHI.site_template#}css/datepicker.css" />
	<script src="{#$QISHI.site_template#}js/png24fix.js"></script>
	<script src="{#$QISHI.site_template#}js/jquery.js"></script>
	<script type="text/javascript" src="{#$QISHI.site_template#}js/jquery.datepicker.js"></script>
	<script src="{#$QISHI.site_template#}js/jquery.dropdown.js"></script>
	<script type="text/javascript" src="{#$QISHI.site_template#}js/jquery.checkboxui.js"></script>
	<script type="text/javascript" src="{#$QISHI.site_template#}js/jquery.checkboxrelated.js"></script>
	<script>
		$(document).ready(function() {
			$('input.date-picker').datePicker();
			dropdownform("#jobtype_menu", "#jobtype_name", "#jobtype", "#jobtype_cn"); // 职位类别
			// 发布职位
			$(".addjobs_but").click(function(event) {
				window.location.href='company_jobs.php?act=choose_addjobs';
			});
			//点击暂停
			$("#ButDisplay2").click(function(){
				$("form[name=form1]").attr("action",$("form[name=form1]").attr("action")+"&display2=1");
				$("form[name=form1]").submit()
			});
			//点击恢复
			$("#ButDisplay1").click(function(){
				$("form[name=form1]").attr("action",$("form[name=form1]").attr("action")+"&display1=1");
				$("form[name=form1]").submit()
			});
			//点击推广
			$("#recommend").click(function(){
				var jobtype=$("#recommend").attr("jobtype");
				var yid=$("#recommend").attr("yid");
				$.post("company_jobs.php",{act:jobs_tg,recommend:1,jobtype:jobtype,yid:yid},function(result){
					if(result=="ok"){
						var html='<img src="{#$QISHI.site_template#}images/73.gif" alt="" />';
						$("#tg_mg").html(html);
					}
				});
			});
			//取消推广
			$("#recommend2").click(function(){
				var yid=$("#recommend").attr("yid");
				$.post("company_jobs.php",{act:cancel_jobs_tg,recommend:0,yid:yid},function(result){
					if(result=="ok"){
						$("#tg_mg").html("");
					}
				});
			});
			// 美化checkbox
			checkboxui();
		});
	</script>
</head>
<body>
	{#include file="member_company/header.htm"#}
	<!-- 二级菜单 -->
	<div class="secondary_menu clearfix company_jobs">
		<ul >
			<li><a href="?act={#$act#}&tabletype=" {#if $smarty.get.tabletype==""#}class="sec_menu_li hashover"{#else#}class="sec_menu_li"{#/if#}>正在招聘</a></li>
			<li><a href="?act={#$act#}&tabletype=3" {#if $smarty.get.tabletype=="3"#}class="sec_menu_li hashover"{#else#}class="sec_menu_li"{#/if#}>审核中</a></li>
			<li><a href="?act={#$act#}&tabletype=4" {#if $smarty.get.tabletype=="4"#}class="sec_menu_li hashover"{#else#}class="sec_menu_li"{#/if#}>审核未通过</a></li>
			<li><a href="?act={#$act#}&tabletype=2" {#if $smarty.get.tabletype=="2"#}class="sec_menu_li hashover"{#else#}class="sec_menu_li"{#/if#}>已结束</a></li>
			<li><a href="?act={#$act#}&tabletype=1" {#if $smarty.get.tabletype=="1"#}class="sec_menu_li hashover"{#else#}class="sec_menu_li"{#/if#}>全部职位</a></li>
		</ul>
		<button class="addjobs_but"><i class="icon_plus_small"></i>&nbsp;发布职位</button>
	</div><!-- 二级菜单结束 -->
	<!-- 企业职位管理 -->
	<div class="container">
		<div class="company_jobs_manage">
			<form id="form2" name="form2" method="get" action="?act=jobs">
			<!-- 搜索 -->
			<div class="searchbar" style="height:50px;">
				<div class="optionlist nomr">
					<div class="l">发布日期</div>
					<span class="relative">
						<input value="{#$smarty.get.starttime#}" name="starttime" id="starttime" class="text input-medium span3 date-picker">
					</span>
				</div>
				<div class="optionlist">
					<div class="l" style="padding-left:5px;">到</div>
					<span class="relative">
						<input value="{#$smarty.get.endtime#}" name="endtime" id="endtime" class="text input-medium span3 date-picker">
					</span>
				</div>
				<div class="optionlist">
					<div class="l">职位类型</div>
					<span class="optionlist">
						<span id="jobtype_name" data-name="industries" class="LocalDataUIC simulation-text LocalDataUIC-simulation-text" style="font-size: 12px; height: 20px; width: 101px;" id="city_result_show">
							<span class="items" style="left: 6px; height: 20px;">{#$smarty.get.jobtype_cn|default:"全部"#}</span>
							<em class="selectui-drop" style="height: 30px; margin-top: -1px;" id="jobtype_menu"></em>
						</span>
						<ul class="droplist">
							<li><a id="" dataid="" title="全部" href="javascript:;">全部</a></li>
							<li><a id="0" dataid="0" title="初级职位" href="javascript:;">初级职位</a></li>
							<li><a id="1" dataid="1" title="中高端职位" href="javascript:;">中高端职位</a></li>
							<li><a id="2" dataid="2" title="委托职位" href="javascript:;">委托职位</a></li>
						</ul>
						<input type="hidden" value="{#if $smarty.get.jobtype!=''#}{#$smarty.get.jobtype#}{#else#}{#/if#}" name="jobtype" id="jobtype" />
						<input type="hidden" value="{#if $smarty.get.jobtype_cn!=''#}{#$smarty.get.jobtype_cn#}{#else#}全部{#/if#}" name="jobtype_cn" id="jobtype_cn" />
					</span>
				</div>
				<div class="optionlist">
					<input value="{#$smarty.get.keyword#}" name="keyword" id="keyword" class="text input-medium span200">
				</div>
				<div class="optionlist" style="margin-left:10px;">
					<input type="hidden" name="tabletype" value="{#$smarty.get.tabletype#}"/>
					<input type="submit" id="Butquery" class="btn_search" value="查询">
				</div>
				<div class="clear"></div>
			</div>
			<!-- 搜索 End-->
			</form>
			<form id="form1" name="form1" method="post" action="?act=jobs_perform">
			<div class="data-list">
				<table class="table table-text-center table-hover table-striped">
					<input type="hidden" name="y_id" id="y_id" value="">
					<thead>
			        	<tr>
			        		<th width="20">
			        			<input type="checkbox" class="checkbox" style="display:none;" autocomplete="off">
			        		</th>
				            <th width="110">职位名称</th>
				            <th width="80">工作地点</th>
				            <th width="50">应聘人选</th>
				            <th width="50">悬赏金额</th>
				            <th width="50">推荐简历</th>
				            <th width="120">操作</th>
				            <th width="130">时间范围</th>
				            {#if $smarty.get.tabletype=="2"#}
							<th width="60" align="center">结束时间</th>
							{#else#}
							<th width="60" align="center">刷新时间</th>
							{#/if#}
			        	</tr>
			    	</thead>
			    	<tbody id="testtab">
			    		{#if $jobs#}
						{#foreach from=$jobs item=li#}
						<tr>
							<td>
				            	<input type="checkbox" class="checkbox" name="y_id[]" value="{#$li.id#}" data="{#$li.id#}" style="display: none;margin-top:4px;" autocomplete="off">
				            </td>
				            <td>
				            	<a href="{#$li.jobs_url#}" class="jobs_name" title="{#$li.jobs_name#}">{#$li.jobs_name_#}</a>&nbsp;{#if $li.jobs_type==0#}<span class="jobs_level rank1" title="初级职位">初</span>{#elseif  $li.jobs_type==1#}<span class="jobs_level rank2" title="高级职位">高</span>{#else#}<span class="jobs_level rank3" title="赏金职位">赏</span>{#/if#}{#if $li.recommend!=0#}&nbsp;<img src="{#$QISHI.site_template#}images/73.gif" alt="" />{#/if#}<span id="tg_mg"></span>
				            </td>
				            <td title="{#$li.district_cn#}">{#$li.district_cn_#}</td>
				            <td><a href="company_recruitment.php?act=apply_jobs&job_id={#$li.id#}" class="jobs_b_a">{#$li.amount#}(<span>{#if $li.countresume!=0#}{#$li.countresume#}{#else#}0{#/if#}</span>)</a></td>
				            <td>{#if $li.jobs_type=="2"#}{#$li.reward#}元{#else#}/{#/if#}</td>
				            <td><a href="company_recruitment.php?act=recommend_resume_list&jobs_id={#$li.id#}&jobs_name={#$li.jobs_name#}" class="jobs_b_a">{#$li.countrecommend#}</a></td>
				            <td>
				            	{#if ($smarty.get.tabletype=="" || $smarty.get.tabletype=="1") && $li.user_status=="1"#}
									<a href="?act=jobs_perform&refresh=1&y_id={#$li.id#}">刷新</a>
									{#if $li.recommend==0 #}
										<a href="?act=jobs_perform&recommend1=1&y_id={#$li.id#}">热聘</a>
									{#else#}
										<a href="?act=jobs_perform&recommend2=1&y_id={#$li.id#}" >取消热聘</a>
									{#/if#}
								{#/if#}
								{#if $li.jobs_type!="2"#}
								<a href="?act=editjobs&id={#$li.id#}">修改</a>
								{#/if#}
								{#if $li.display=="1"#}
									<a href="?act=jobs_perform&display2=1&y_id={#$li.id#}">结束</a>
								{#else#}
									<a href="?act=jobs_perform&display1=1&y_id={#$li.id#}">恢复</a>
								{#/if#}
				            </td>
				            <td>{#$li.addtime|date_format:"%Y-%m-%d"#} 至 {#$li.deadline|date_format:"%Y-%m-%d"#}</td>
				            <td>
				            	{#if $smarty.get.tabletype=="2"#}
								{#$li.finishtime|date_format:"%Y-%m-%d"#}
								{#else#}
								{#$li.refreshtime|date_format:"%Y-%m-%d"#}
								{#/if#}
				            </td>
						</tr>
						{#/foreach#}
						{#else#}
						<tr class="company_jobs_table_item link_blue">
							<td colspan="9" style="border:0"><div class="com_jobs_s_txt">没有找到对应的职位信息！</div></td>
						</tr>
						{#/if#}
			    	</tbody>
			    	<tfoot>
			    		{#if $jobs#}
			    		<tr style="border:none;">
			    			<td><input type="checkbox" class="checkbox" style="display: none;margin-top:4px;" autocomplete="off"></td>
			    			<td class="text-left table-actions" colspan="3">
			    				{#if $smarty.get.tabletype==""#}
								<input type="submit" value="刷新" class="btn btn-light btn-small export" id="refresh" name="refresh"/>
								{#/if#}
								{#if $smarty.get.tabletype=="2" || $smarty.get.tabletype==""#}
								<input type="submit" value="恢复" class="btn btn-light btn-small allfavorites" id="ButDisplay1"/>
								{#/if#}
								{#if $smarty.get.tabletype!="2"#}
								<input type="submit" value="结束" class="btn btn-light btn-small link-batchview del" id="ButDisplay2"/>
								{#/if#}
				            		</td>
				           		<td class="pagerbar-actions-inline" colspan="5">
				           			{#if $page#}
		          					<!-- 分页 -->
							<div class="page h_page clearfix">
									{#$page#}
							</div>
							<!-- 分页结束 -->
							{#/if#}
		      				</td>
			    		</tr>
			    		{#/if#}
			    	</tfoot>
				</table>
			</div>
			</form>
		</div>
	</div>
	{#include file="./footer.htm"#}
</body>
</html>