2011-09-30 03:25:37 +00:00
|
|
|
<?php
|
|
|
|
$this->headTitle($this->config->title->site);
|
|
|
|
$this->headTitle('后台管理');
|
|
|
|
$this->headTitle()->setSeparator(' - ');
|
|
|
|
$this->breadcrumb('<a href="/">首页</a>');
|
|
|
|
$this->breadcrumb('<a href="/admin">后台首页</a>');
|
|
|
|
$this->breadcrumb('元数据评审');
|
|
|
|
$this->breadcrumb()->setSeparator(' > ');
|
2013-05-14 08:57:30 +00:00
|
|
|
$this->theme->AppendPlus($this,'colorbox');
|
2011-09-30 03:25:37 +00:00
|
|
|
?>
|
2013-05-10 08:53:24 +00:00
|
|
|
<style>
|
|
|
|
table thead tr th {background:#EBF2F6;color:#444;}
|
|
|
|
.high{background:#444;color:#FFF;}
|
|
|
|
</style>
|
|
|
|
<div class="row-fluid">
|
|
|
|
<div class="span3">
|
|
|
|
<?= $this->partial('review/left.phtml'); ?>
|
|
|
|
</div>
|
|
|
|
<div class="span9">
|
|
|
|
<?php if ($this->msg or $this->messages) :?>
|
|
|
|
<div id="message">
|
|
|
|
<?php if ($this->msg) : ?>
|
|
|
|
<p><?php echo $this->msg; ?></p>
|
|
|
|
<?php endif; if ($this->messages): foreach($this->messages as $msg): ?>
|
|
|
|
<p><?php echo $msg; ?></p>
|
|
|
|
<?php endforeach;endif; ?>
|
|
|
|
</div>
|
|
|
|
<?php endif; ?>
|
2013-06-13 08:06:11 +00:00
|
|
|
<form method="get" id="search">
|
|
|
|
<input type="hidden" name="search" value='1' />
|
|
|
|
<input type="hidden" name="code" id="code" value="<?php echo $this->code; ?>" />
|
|
|
|
<div class="input-append">
|
|
|
|
<input type="text" class="q" name="keyword" value="<?php echo $this->keyword; ?>" tabindex="1" />
|
|
|
|
<div class="btn-group">
|
|
|
|
<button tabindex="-1" class="btn" type="submit">搜索</button>
|
|
|
|
<button tabindex="-1" data-toggle="dropdown" class="btn dropdown-toggle">
|
2013-06-16 15:38:17 +00:00
|
|
|
专题<span class="caret"></span>
|
2013-06-13 08:06:11 +00:00
|
|
|
</button>
|
|
|
|
<ul class="dropdown-menu">
|
|
|
|
<li><a href="javascript:void(0);" onclick="$('#code').val('');$('#search').submit()">所有专题</a></li>
|
|
|
|
<?php if(!empty($this->source)) { ?>
|
|
|
|
<?php foreach($this->source as $v) { ?>
|
2013-06-16 15:38:17 +00:00
|
|
|
<li<?php echo ($this->code==$v['id'])?' class="active"':''; ?>><a href="javascript:void(0);" onclick="$('#code').val('<?= $v['id'] ?>');$('#search').submit()"><?= $v['code'] ?></a></li>
|
2013-06-13 08:06:11 +00:00
|
|
|
<?php } }?>
|
|
|
|
</ul>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</form>
|
2013-05-10 08:53:24 +00:00
|
|
|
<table class="table table-bordered table-hover">
|
|
|
|
<thead>
|
|
|
|
<tr>
|
2013-06-09 09:39:16 +00:00
|
|
|
<th style="width:13px;"><input type="checkbox" class="select_rows" data-tbody="list" /></th>
|
2013-05-10 08:53:24 +00:00
|
|
|
<th width='500'>元数据标题</th>
|
|
|
|
<th width='80'>状态</th>
|
2013-05-14 08:57:30 +00:00
|
|
|
<th>接收时间</th>
|
|
|
|
<th>作者</th>
|
|
|
|
<th width="300">操作</th>
|
2013-05-10 08:53:24 +00:00
|
|
|
</tr>
|
|
|
|
</thead>
|
|
|
|
<?php if (count($this->paginator)): ?>
|
|
|
|
<tbody id="list">
|
|
|
|
<?php foreach ($this->paginator as $item): ?>
|
|
|
|
<tr>
|
2013-06-09 09:39:16 +00:00
|
|
|
<td><input type="checkbox" class="select_item" value="<?= $item['id']?>" /></td>
|
2013-05-14 08:57:30 +00:00
|
|
|
<td><?= $item['title']?> [
|
2013-05-24 00:35:07 +00:00
|
|
|
<a href="/service/geonetwork?url=metadata.edit?id=<?= $item['gid'] ?>" target="_blank">编辑</a> |
|
2013-05-14 08:57:30 +00:00
|
|
|
<a href="javascript:void(0);" rel="<?= $item['uuid']?>" class="version">版本</a>
|
|
|
|
]</td>
|
2013-05-10 08:53:24 +00:00
|
|
|
<td><?php
|
|
|
|
if($item['status'] == 0) echo "初始";
|
|
|
|
if($item['status'] == -1) echo "取消审核";
|
|
|
|
if($item['status'] == 1) echo "进入评审";
|
|
|
|
if($item['status'] == 2) echo "邀请专家";
|
|
|
|
if($item['status'] == 3) echo "专家接受邀请";
|
|
|
|
if($item['status'] == 4) echo "专家反馈";
|
|
|
|
if($item['status'] == 5) echo "已发布";
|
|
|
|
?></td>
|
2013-05-14 08:57:30 +00:00
|
|
|
<td><?php echo date("Y-m-d H:i",strtotime($item['ts_accepted']));?></td>
|
|
|
|
<td><?= $item['author']?></td>
|
2013-05-10 08:53:24 +00:00
|
|
|
<td>
|
|
|
|
<a href="/admin/review/invite/id/<?php echo $item['id'];?>">邀请专家</a>
|
|
|
|
<a href="/admin/review/changeadmin/id/<?php echo $item['id'];?>">更改管理员</a>
|
|
|
|
<a href="/admin/review/inreview/show/<?php echo $item['id'];?>">查看详细</a>
|
|
|
|
<a href="/admin/review/comments/ac/list/uuid/<?php echo $item['uuid'];?>">查看评审意见</a>
|
|
|
|
<a href="/admin/review/reply/uuid/<?php echo $item['uuid'];?>">意见反馈</a>
|
|
|
|
<a href='/admin/review/accept/cancel/<?php echo $item['id'];?>' onclick="return confirm('是否确定取消评审')">取消评审</a>
|
|
|
|
<a href="/admin/review/checkmail/id/<?php echo $item['id'];?>" style="color:#6C0">发布</a>
|
|
|
|
<a href="/admin/review/delete/id/<?php echo $item['id'];?>" style="color:#F00" onclick="return confirm('是否确定删除?该操作不可逆')">删除</a>
|
|
|
|
</td>
|
|
|
|
</tr>
|
|
|
|
<?php endforeach; ?>
|
|
|
|
</tbody>
|
|
|
|
<?php endif; ?>
|
|
|
|
</table>
|
2013-06-09 09:39:16 +00:00
|
|
|
<div><a class="btn btn-primary post">发布</a></div>
|
2013-05-10 08:53:24 +00:00
|
|
|
<div class="pagenavi"><?= $this->paginator; ?></div>
|
|
|
|
</div>
|
2011-09-30 03:25:37 +00:00
|
|
|
</div>
|
2013-05-10 08:53:24 +00:00
|
|
|
<script>
|
2013-06-09 09:39:16 +00:00
|
|
|
var sfadmin = {
|
|
|
|
def_data_tag : 'tbody',
|
|
|
|
def_select_input : '.select_item',
|
|
|
|
init: function() {
|
|
|
|
$('.select_rows').click(function () {
|
|
|
|
var tableid = $(this).data(sfadmin.def_data_tag);
|
|
|
|
$('#'+tableid).find(sfadmin.def_select_input).attr('checked', this.checked);
|
|
|
|
});
|
|
|
|
sfadmin.ajax.error();
|
|
|
|
},
|
|
|
|
getSelected : function(tableid){
|
|
|
|
if(tableid == "")
|
|
|
|
{
|
|
|
|
dom = $(sfadmin.def_select_input + ':checked');
|
|
|
|
}else{
|
|
|
|
dom = $(sfadmin.def_select_input + ':checked', '#'+tableid);
|
|
|
|
}
|
|
|
|
datas = new Array();
|
|
|
|
dom.each(function(index, element) {
|
|
|
|
datas.push($(this).val());
|
|
|
|
});
|
|
|
|
return datas;
|
|
|
|
},
|
|
|
|
ajax : {
|
|
|
|
error : function(){
|
|
|
|
$(document).ajaxError(function(event, request, settings) {
|
|
|
|
sfadmin.Alert("请求中发生错误");
|
|
|
|
})
|
|
|
|
}
|
|
|
|
},
|
|
|
|
Alert : function(content){
|
|
|
|
$.colorbox({width:'50%',html:'<div class="ajax_error"><div class="text"><h2>'+content+'</h2></div></div>'});
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2013-05-14 08:57:30 +00:00
|
|
|
$(document).ready(function(e) {
|
|
|
|
$('.version').click(function(){
|
|
|
|
$(this).getversion({'id':$(this).attr('rel')});
|
|
|
|
});
|
2013-06-09 09:39:16 +00:00
|
|
|
sfadmin.init();
|
|
|
|
$('.post').click(function(e) {
|
|
|
|
ids = getids();
|
|
|
|
if(!ids)
|
|
|
|
{
|
|
|
|
return false;
|
|
|
|
}
|
|
|
|
url = "/admin/review/post/" + '?' +ids;
|
|
|
|
self.location=url
|
|
|
|
});
|
2013-05-14 08:57:30 +00:00
|
|
|
});
|
2013-06-09 09:39:16 +00:00
|
|
|
function getids(){
|
|
|
|
id = sfadmin.getSelected('list');
|
|
|
|
if(id.length == '')
|
|
|
|
{
|
|
|
|
alert('请选择要操作的项目');
|
|
|
|
return false;
|
|
|
|
}
|
|
|
|
|
|
|
|
url_data = new Array();
|
|
|
|
|
|
|
|
for(i in id)
|
|
|
|
{
|
|
|
|
url_data.push('id[]='+id[i]);
|
|
|
|
}
|
|
|
|
|
|
|
|
data = url_data.join("&");
|
|
|
|
|
|
|
|
return data;
|
|
|
|
}
|
|
|
|
|
2013-05-14 08:57:30 +00:00
|
|
|
(function( $ ){
|
|
|
|
|
|
|
|
$.fn.getversion = function( options ) {
|
|
|
|
|
|
|
|
var settings = $.extend( {
|
|
|
|
id:'',
|
|
|
|
content : '',
|
|
|
|
}, options);
|
|
|
|
|
|
|
|
var methods = {
|
|
|
|
edit : function(id)
|
|
|
|
{
|
|
|
|
methods.creatWindow(id);
|
|
|
|
},
|
|
|
|
creatWindow : function(id){
|
|
|
|
$.colorbox({
|
|
|
|
initialHeight: '0',
|
|
|
|
initialWidth: '0',
|
|
|
|
html: methods.dialog,
|
|
|
|
opacity: '0.3',
|
|
|
|
onComplete: function(){
|
|
|
|
$('.confirm_yes').click(function(e){
|
|
|
|
e.preventDefault();
|
|
|
|
methods.submited(id);
|
|
|
|
$.colorbox.close();
|
|
|
|
});
|
|
|
|
$('.confirm_no').click(function(e){
|
|
|
|
e.preventDefault();
|
|
|
|
$.colorbox.close();
|
|
|
|
});
|
|
|
|
}
|
|
|
|
});
|
|
|
|
},
|
|
|
|
getVersion : function(uuid){
|
|
|
|
$.ajax({
|
|
|
|
'type':"POST",
|
|
|
|
'url':'/data/getversion',
|
|
|
|
'data':'ac=list&uuid='+uuid,
|
|
|
|
'success':methods.onLoad,
|
|
|
|
'timeout': 30000,
|
|
|
|
'error': function(){
|
|
|
|
alert('处理中出现错误,请刷新页面后重试');
|
|
|
|
return false;
|
|
|
|
}
|
|
|
|
});
|
|
|
|
},
|
|
|
|
onLoad : function(data){
|
|
|
|
if (typeof(data)=='object')
|
|
|
|
{
|
|
|
|
if(typeof(data.error)!='undefined')
|
|
|
|
{
|
|
|
|
alert("没有版本信息");return false;
|
|
|
|
}
|
|
|
|
if(typeof(data.list)!='undefined')
|
|
|
|
{
|
|
|
|
var html = "";
|
|
|
|
for(v in data.list)
|
|
|
|
{
|
|
|
|
html+='<li><p>'+data.list[v].changelog+'</p><p>'+data.list[v].ts_created+' by '+data.list[v].username+'</p></li>';
|
|
|
|
}
|
|
|
|
$.colorbox({'innerWidth':'50%','innerHeight':'80%','html':'<div class="datalist"><ul>'+html+'</ul></div>'});
|
|
|
|
}
|
|
|
|
}
|
|
|
|
else{
|
|
|
|
alert('出现错误,请稍后再试');return false;
|
|
|
|
}
|
|
|
|
},
|
|
|
|
dialog : function(content){
|
|
|
|
HTML = '<div class=""><div class="modal-header"><h3>修改文献</h3></div>'
|
|
|
|
+ '<div class="modal-body"><textarea class="span8" id="content_input_area">'+settings.content+'</textarea></div>'
|
|
|
|
+ '<div class="modal-footer"><a href="javascript:void(0);" class="btn btn-primary confirm_yes">是</a><a href="javascript:void(0);" class="btn confirm_no">否</a></div></div>';
|
|
|
|
return HTML;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
this.each(function() {
|
|
|
|
if( settings.id == '')
|
|
|
|
{
|
|
|
|
alert('参数错误');
|
|
|
|
}
|
|
|
|
methods.getVersion(settings.id);
|
|
|
|
});
|
|
|
|
|
|
|
|
};
|
|
|
|
})( jQuery );
|
2013-05-10 08:53:24 +00:00
|
|
|
</script>
|