修改微信模块

This commit is contained in:
Anyon 2020-07-15 11:12:16 +08:00
parent f471835e51
commit 16e5dc7ea5
6 changed files with 19 additions and 21 deletions

View File

@ -3,7 +3,7 @@
{block name='content'}
<div class="header"><span>{:date('H:i')}</span></div>
<div class="container">
<div class="logo">A</div>
<div class="logo">Ta</div>
<div class="content"><img src="{$content|default=''}" alt="img"></div>
</div>
{/block}

View File

@ -3,7 +3,7 @@
{block name='content'}
<div class="header"><span>{:date('H:i')}</span></div>
<div class="container">
<div class="logo">A</div>
<div class="logo">Ta</div>
<div class="content arrow">
<div class="content-title">{$title|default=''}</div>
<div class="content-content">{$desc|default=''}</div>

View File

@ -3,9 +3,7 @@
{block name='content'}
<div class="header"><span>{:date('H:i')}</span></div>
<div class="container">
{notempty name='news.articles'}
{foreach $news.articles as $k => $v}
{if $k < 1}
{notempty name='news.articles'} {foreach $news.articles as $k => $v} {if $k < 1}
<a href="{:url('wechat/api.review/view')}?id={$v.id}" style='background-image:url("{$v.local_url}")'>
{if $v.title}<span>{$v.title}</span>{/if}
</a>
@ -16,9 +14,7 @@
<span style='background-image:url("{$v.local_url}");'></span>
</a>
<div class="hr-line-dashed"></div>
{/if}
{/foreach}
{else}
{/if} {/foreach} {else}
<div class="info"><h3>404</h3> 访问资源不存在哦!</div>
{/notempty}
</div>
@ -32,10 +28,11 @@
}
.header span {
padding: 5px;
font-size: 8px;
background: #ccc;
border-radius: 10%
padding: 1px 5px;
font-size: 12px;
line-height: 12px;
background: #aaa;
box-shadow: 0 0 3px #666
}
.container {
@ -43,7 +40,7 @@
display: block;
margin: 5vw auto;
position: relative;
box-shadow: 0 0 3px #ccc
box-shadow: 0 0 3px #333
}
.container a {

View File

@ -3,7 +3,7 @@
{block name='content'}
<div class="header"><span>{:date('H:i')}</span></div>
<div class="container">
<div class="logo">A</div>
<div class="logo">Ta</div>
<div class="content arrow">{$content|default=''}</div>
</div>
{/block}

View File

@ -37,8 +37,8 @@
<div class="nowrap think-box-shadow" style="width:910px">
<div class='mobile-preview inline-block'>
<div class='mobile-header'>公众号</div>
<div class='mobile-body'>
<iframe id="phone-preview" frameborder="0" marginheight="0" marginwidth="0"></iframe>
<div class='mobile-body' data-iframe-box>
<!-- <iframe id="phone-preview" frameborder="0" marginheight="0" marginwidth="0"></iframe>-->
</div>
</div>
<div class="keys-container inline-block absolute margin-left-10 margin-right-15">
@ -203,13 +203,14 @@
var $body = $('body');
// 刷新预览显示
function showReview(params, src) {
function showReview(params, location) {
if (params['type'] === 'news') {
src = '{:url("@wechat/api.review/news")}?id=_id_'.replace('_id_', params.content);
location = '{:url("@wechat/api.review/news")}?id=_id_'.replace('_id_', params.content);
} else {
src = '{:url("@wechat/api.review/_type_")}?'.replace('_type_', params.type) + $.param(params || {});
location = '{:url("@wechat/api.review/_type_")}?'.replace('_type_', params.type) + $.param(params || {});
}
$('#phone-preview').attr('src', src);
var iframe = '<iframe id="phone-preview" frameborder="0" marginheight="0" marginwidth="0"></iframe>';
$('[data-iframe-box]').empty().append($(iframe).attr('src', location));
}
$body.off('change', '[name="news_id"]').on('change', '[name="news_id"]', function () {

2
vendor/services.php vendored
View File

@ -1,5 +1,5 @@
<?php
// This file is automatically generated at:2020-07-15 09:47:12
// This file is automatically generated at:2020-07-15 10:23:46
declare (strict_types = 1);
return array (
0 => 'think\\app\\Service',