@ -36,7 +36,7 @@
}
};
zNodes =<? PHP echo json_encode ( $informationList ); ?> ;
zNodes =<? php echo json_encode ( $informationList ); ?> ;
function onClickzTree(e, treeId, treeNode, clickFlag) {
var urlReQuery = "<?php echo site_url ( 'information/edit/' ); ?> ";
@ -487,9 +487,37 @@
filebrowserUploadUrl: '/wysiwyg/ckfinder/core/connector/php/connector.php?command=QuickUpload& type=image',
contentsCss:'<?php echo $this -> config -> item ( "css_source_" . $this -> config -> item ( "site_code" )); ?> '
});
//如果是cht站点, 默认显示手机预览框
switch_preview_tree();
};
function switch_preview_tree(){
if($("#preview_box").is(":hidden")){
update_preview();
$("#preview_box").show();
$("#tree_box").hide();
}else{
$("#preview_box").hide();
$("#tree_box").show();
}
}
function update_preview() {
//考虑做成异步操作,降低页面卡顿
var iframe = document.createElement('iframe');
iframe.setAttribute('frameBorder', '0');
iframe.setAttribute('id', 'previewIframe');
iframe.setAttribute('height', '100%');
iframe.setAttribute('width', '100%');
iframe.setAttribute('name', 'AMP Playground Output');
$('#preview_box').html('');
$('#preview_box').append(iframe);
var html_code=$('#mobile_first_template').text().replace('<!-- @CUSTOM - CONENT@ --> ',editor.getData());
var doc = iframe.contentDocument || iframe.document;
doc.open();
doc.write(html_code);
doc.close();
}
//新闻日历
$(function () {
@ -522,17 +550,18 @@
< / script >
< div class = "container-fluid" >
< div class = "row" >
< div class = "col-sm-5 nopadding hidden-xs" style = "box-shadow: 4px 0px 5px #e0e0e0; margin-right: 7px;margin-left: -7px; ">
< div class = "col-sm-5 nopadding hidden-xs" style = "box-shadow: 4px 0px 5px #e0e0e0; ">
< div class = "well nopadding" style = "border:none !important;padding-top:0px;" >
< div class = "preview_box" id = "preview_box" style = "height: 800px;display: none;" > < / div >
< div id = "tree_box" >
< ul id = "treeDemo" name = "treeDemo" class = "ztree" style = "height:1035px;overflow-x:auto;" > < / ul >
< ul class = "nav nav-list" >
< li class = "nav-header" >
< a href = " <?php echo site_url ( 'welcome/create_infomation_urls/' . $information -> is_id ); ?> " target = "_blank" class = "col-sm-5" title = "批量更新静态化页面" >< i class = "text-muted glyphicon glyphicon-retweet" ></ i ></ a >
< a href = " <?php echo site_url ( 'welcome/create_infomation_urls/' . $information -> is_id . '/amp' ); ?> " target = "_blank" class = "col-sm-5" title = "批量更新AMP页面" >< i class = "glyphicon glyphicon-flash" ></ i ></ a >
< / li >
< / ul >
< / div >
< / div >
< / div >
@ -547,7 +576,7 @@
< div class = "col-xs-24" >
< div class = "row" >
< div class = "col-xs-24 btn-sm" > < / div >
< div class = "col-xs-7" >
< div class = "col-xs-7" > < a href = "javascript:void(0);" onclick = "switch_preview_tree()" > < i class = "glyphicon glyphicon-indent-right" > < / i > < / a >
< label >
信息标题 & IC_ID: <?php echo $information -> ic_id ; ?>
< / label >
@ -567,8 +596,7 @@ $amp_build_url = "/amp_app/?icid=" . $information->ic_id . "&is_path=" . $inform
$PcAmpChecked = 'checked';
} else {
$PcAmpChecked = '';
}
?>
} ?>
< style type = "text/css" > # PcAmp { color : #069 ; cursor : pointer ; } # PcAmp input { position : relative ; top : 2 px ; } < / style >
< label id = "PcAmp" >
< input type = "checkbox" <?php echo ( $PcAmpChecked ); ?> >
@ -590,7 +618,8 @@ $amp_build_url = "/amp_app/?icid=" . $information->ic_id . "&is_path=" . $inform
}
});
< / script >
<?php } ?>
<?php
}?>
<?php if ( $information -> amp_status === '1' ) { ?>
< label title = "AMP页面编辑" >< a href = " <?php echo site_url ( 'amp/edit/' . $information -> ic_id ); ?> " target = "_blank" >< i class = "glyphicon glyphicon-flash" ></ i ></ a ></ label >
<?php } ?>
@ -619,7 +648,9 @@ if ($embody == 1) {
< div class = "col-xs-12 nopadding-R" >
< div class = "col-xs-24 nopadding" > 链接地址
< a href = "javascript:void(0);" onclick = "format_url()" title = "格式化URL" > < i class = "glyphicon glyphtext-muted glyphicon glyphicon-flag text-muted" > < / i > < / a >
< a href = "javascript:void(0);" onclick = "goto_page();" id = "goto_page_button" name = "goto_page_button" target = "_blank" title = "查看" > < i class = "glyphicon glyphtext-muted glyphicon glyphicon-eye-open text-muted" > < / i > < / a >
<?php if ( $information -> ic_sitecode == 'cht' ) { ?>
< a href = "javascript:void(0);" onclick = "goto_test_page();" id = "goto_test_page_button" name = "goto_test_page_button" target = "_blank" title = "查看测试页面" > < i class = "glyphicon glyphtext-muted glyphicon glyphicon-random text-muted" > < / i > < / a >
<?php } ?>
@ -629,6 +660,7 @@ if ($embody == 1) {
<?php if ( $information -> ic_sitecode == 'ah' ) { ?>
< a href = "javascript:void(0);" onclick = "goto_ahtest_page();" id = "goto_test_page_button" name = "goto_test_page_button" target = "_blank" title = "查看测试页面" > < i class = "glyphicon glyphtext-muted glyphicon glyphicon-random text-muted" > < / i > < / a >
<?php } ?>
< a href = "javascript:void(0);" style = "float: right;" onclick = "update_preview()" title = "刷新预览" > < i class = "glyphicon glyphicon-refresh text-muted" > < / i > < / a >
< / div >
< input class = "form-control col-xs-24" type = "text" id = "ic_url" name = "ic_url" value = " <?php echo $information -> ic_url ; ?> " >
< / div >
@ -681,8 +713,7 @@ if ($embody == 1) {
if (!empty($setting_website_nav)) {
$setting_website_nav_active = trim(get_meta($information->ic_id, 'meta_website_nav'));
foreach ($setting_website_nav as $item) {
$strcasecmp_nav = strcasecmp($setting_website_nav_active, $item->im_value);
?>
$strcasecmp_nav = strcasecmp($setting_website_nav_active, $item->im_value); ?>
< option <?php echo $strcasecmp_nav == 0 ? 'selected' : false ; ?> value = " <?php echo $item -> im_value ?> " > <?php echo $item -> im_value ?> </ option >
<?php
}
@ -821,8 +852,7 @@ if (!empty($setting_website_nav)) {
< div class = "col-sm-5 <?php
if ($information->ic_ht_area_type != 'c' & & $information->ic_sitecode!="ct") {
echo 'hidden';
}
?>">
} ?>">
< label > 景点评论数
< a href = "javascript:void(0);" onclick = "meta('delete', ' <?php echo $information -> ic_id ; ?> ', 'meta_review_count', $('#meta_review_count').val())" >< i class = "text-muted glyphicon glyphicon-remove" ></ i ></ a >
< a href = "javascript:void(0);" onclick = "meta('save', ' <?php echo $information -> ic_id ; ?> ', 'meta_review_count', $('#meta_review_count').val())" >< i class = "text-muted glyphicon glyphicon-hdd" ></ i ></ a >
@ -860,8 +890,7 @@ if ($information->ic_ht_area_type == 'c') {
echo 'col-sm-4';
} else {
echo 'col-sm-9';
}
?>">
} ?>">
< label > 显示作者
< a href = "javascript:void(0);" onclick = "meta('delete', ' <?php echo $information -> ic_id ; ?> ', 'meta_show_author', $('#meta_show_author').val())" >< i class = "text-muted glyphicon glyphtext-muted glyphicon glyphicon-remove" ></ i ></ a >
< a href = "javascript:void(0);" onclick = "meta('save', ' <?php echo $information -> ic_id ; ?> ', 'meta_show_author', $('#meta_show_author').val())" >< i class = "text-muted glyphicon glyphtext-muted glyphicon glyphicon-hdd" ></ i ></ a >
@ -902,7 +931,8 @@ if ($information->ic_ht_area_type == 'c') {
< div class = "col-sm-19" >
< / div >
< / div >
<?php } ?>
<?php
} ?>
< div class = "row" >
< div class = "col-xs-24" >
< label > 自定义导航
@ -917,7 +947,8 @@ if ($information->ic_ht_area_type == 'c') {
< / div >
<?php } ?>
<?php
}?>
< label > og:title
@ -1430,10 +1461,10 @@ $meta_subnavi_arr = array(
< select name = "ic_type" id = "ic_type" class = "form-control" onselect = "" >
<?php
foreach ($infoTypeList as $key => $value) {
$value == $information->ic_type ? $select_str = 'selected' : $select_str = '';
?>
$value == $information->ic_type ? $select_str = 'selected' : $select_str = ''; ?>
< option <?php echo $select_str ; ?> value = " <?php echo $value ; ?> " > <?php echo $key ; ?> </ option >
<?php } ?>
<?php
}?>
< / select >
<?php if ( $rootInformation -> ic_ht_area_type == 'pd' ) { ?>
< div id = "bind_product_code" >
@ -1449,10 +1480,10 @@ foreach ($infoTypeList as $key => $value) {
< select name = "ic_template" id = "ic_template" class = "form-control" >
<?php
foreach ($templateList as $key => $value) {
$value == $information->ic_template ? $select_str = 'selected' : $select_str = '';
?>
$value == $information->ic_template ? $select_str = 'selected' : $select_str = ''; ?>
< option <?php echo $select_str ; ?> value = " <?php echo $value ; ?> " > <?php echo $key ; ?> </ option >
<?php } ?>
<?php
}?>
< / select >
< label > 是否作为面包屑显示< / label >
@ -1477,17 +1508,17 @@ foreach ($editor_list as $editor_item) {
if (!$hasselected & & !empty($information->ic_content) & & $information->ic_url_title != 'New Information' & & $editor_item->OPI_Code == 'PKL') {
$select_str = 'selected';
}
}
?>
} ?>
< option <?php echo $select_str ; ?> value = " <?php echo $editor_item -> OPI_Code ; ?> " > <?php echo $editor_item -> OPI_Name ; ?> </ option >
<?php } ?>
<?php
}?>
< option value = "" > -< / option >
<?php
foreach ($author_list as $author_item) {
($author_item->a_id == $information->ic_author) ? $select_str = 'selected' : $select_str = '';
?>
($author_item->a_id == $information->ic_author) ? $select_str = 'selected' : $select_str = ''; ?>
< option <?php echo $select_str ; ?> value = " <?php echo $author_item -> a_id ; ?> " > <?php echo $author_item -> a_name ; ?> </ option >
<?php } ?>
<?php
}?>
< / select >
< label > 是否发布< / label >
@ -1515,7 +1546,11 @@ foreach ($author_list as $author_item) {
<?php if ( in_array ( $this -> config -> item ( 'site_code' ), array ( 'cht' , 'ah' , 'gm' ))) { ?>
< label class = "checkbox col-xs-24" style = "font-weight: normal;margin-top:0;padding-left: 21px;" >
< input type = "checkbox" name = "auto_update_amp" id = "auto_update_amp" <?php if ( $information -> amp_status === '2' ) { echo 'disabled' ;} ?> value = "true" /> AMP更新 <?php if ( $information -> amp_status === '2' ) { echo '<i class="glyphicon glyphicon-hand-up" title="手动管理,不会自动更新"></i>' ;} ?>
< input type = "checkbox" name = "auto_update_amp" id = "auto_update_amp" <?php if ( $information -> amp_status === '2' ) {
echo 'disabled';
}?> value="true" />AMP更新 <?php if ( $information -> amp_status === '2' ) {
echo '< i class = "glyphicon glyphicon-hand-up" title = "手动管理,不会自动更新" > < / i > ';
}?>
< / label >
<?php } ?>
@ -1585,6 +1620,9 @@ foreach ($author_list as $author_item) {
< / div >
< / div >
< textarea id = "mobile_first_template" style = "display: none;" > <?php if ( ! empty ( $mobile_first_template )){ echo $mobile_first_template ;} ?> </ textarea >
<!-- Trippest bokun窗口 -->
< div class = "modal fade" id = "NoPermissionModal" >
< div class = "modal-dialog modal-lg" >
@ -1612,5 +1650,3 @@ foreach ($author_list as $author_item) {
});
< / script >
<!-- Trippest bokun窗口 -->