186 lines
32 KiB
PHP
186 lines
32 KiB
PHP
<?php /*a:4:{s:73:"/www/wwwroot/app.cxhxy.dev.1nww.com/app/admin/view/wechat/send/index.html";i:1700552721;s:69:"/www/wwwroot/app.cxhxy.dev.1nww.com/app/admin/view/layout/layout.html";i:1700552721;s:88:"/www/wwwroot/app.cxhxy.dev.1nww.com/app/admin/view/../../admin/view/wechat/send/add.html";i:1700552721;s:89:"/www/wwwroot/app.cxhxy.dev.1nww.com/app/admin/view/../../admin/view/wechat/send/edit.html";i:1700552721;}*/ ?>
|
||
<!DOCTYPE html>
|
||
<html lang="en">
|
||
<head>
|
||
<meta charset="utf-8" />
|
||
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
|
||
<title>管理后台 - <?php echo htmlentities($web['name']); ?></title>
|
||
<meta name="author" content="<?php echo htmlentities($web['name']); ?>">
|
||
<meta name="keywords" content="<?php echo htmlentities($web['keywords']); ?>">
|
||
<meta name="description" content="<?php echo htmlentities($web['description']); ?>">
|
||
<meta name="viewport" content="width=device-width, initial-scale=1" />
|
||
<meta name="referrer" content="no-referrer-when-downgrade">
|
||
<meta http-equiv="Cache-Control" content="no-siteapp" />
|
||
<link rel="icon" type="image/png" href="/favicon.png" />
|
||
<link rel="stylesheet" href="/assets/plugins/amazeui/amazeui.css?v=<?php echo htmlentities($version); ?>" />
|
||
<link rel="stylesheet" href="/assets/css/hema.app.css?v=<?php echo htmlentities($version); ?>" />
|
||
<link rel="stylesheet" href="/addons/upload/css/file.library.css?v=<?php echo htmlentities($version); ?>" />
|
||
<link rel="stylesheet" href="/assets/plugins/iconfont/iconfont.css?v=<?php echo htmlentities($version); ?>">
|
||
<script src="/assets/plugins/jquery/jquery.min.js?v=<?php echo htmlentities($version); ?>"></script>
|
||
<script src="/assets/plugins/iconfont/iconfont.js?v=<?php echo htmlentities($version); ?>"></script>
|
||
<script>
|
||
BASE_URL = '<?php echo isset($base_url) ? $base_url : ''; ?>';
|
||
STORE_URL = '<?php echo isset($store_url) ? $store_url : ''; ?>';
|
||
APPLET_ID = '<?php echo isset($applet_id) ? $applet_id : 0; ?>';
|
||
</script>
|
||
</head>
|
||
<body data-type="">
|
||
<div class="am-g tpl-g">
|
||
<!-- 头部 -->
|
||
<header class="tpl-header">
|
||
<!-- 右侧内容 -->
|
||
<div class="tpl-header-fluid">
|
||
<!-- 侧边切换 -->
|
||
<div class="am-fl tpl-header-button switch-button"> <i class="iconfont iconzhedie"></i> </div>
|
||
<!-- 刷新页面 -->
|
||
<div class="am-fl tpl-header-button refresh-button"> <i class="iconfont iconshuaxin"></i> </div>
|
||
<!-- 其它功能-->
|
||
<div class="am-fr tpl-header-navbar">
|
||
<ul>
|
||
<!-- 当前版本 -->
|
||
<li class="am-text-sm">
|
||
<a href="javascript:void(0);" class="hemaphp-upgrade">
|
||
<small style="color:#ccc;">版本:V<?php echo htmlentities($version); ?></small>
|
||
<?php if($is_new): ?>
|
||
<div class="news"></div>
|
||
<?php endif; ?>
|
||
</a>
|
||
</li>
|
||
<!-- 欢迎语 -->
|
||
<li class="am-text-sm">
|
||
<div class="am-dropdown" data-am-dropdown="{boundary: '.am-topbar'}">
|
||
<div class="am-topbar-btn am-dropdown-toggle" data-am-dropdown-toggle>
|
||
<img src="/assets/img/avatar.png" />
|
||
<?php echo htmlentities((isset($user['user']['user_name']) && ($user['user']['user_name'] !== '')?$user['user']['user_name']:'')); ?>
|
||
<span class="am-icon-caret-down"></span>
|
||
</div>
|
||
<ul class="am-dropdown-content">
|
||
<li><a href="<?php echo url('passport/renew'); ?>">修改密码</a></li>
|
||
<li><a href="<?php echo url('passport/logout'); ?>">安全退出</a></li>
|
||
</ul>
|
||
</div>
|
||
</li>
|
||
</ul>
|
||
</div>
|
||
</div>
|
||
</header> <!-- 侧边导航栏 -->
|
||
<div class="left-sidebar dis-flex">
|
||
<?php $menus = $menus ?: []; $group = $group ?: 0; $second = isset($menus[$group]['submenu']) ? $menus[$group]['submenu'] : []?>
|
||
<!-- 一级菜单 -->
|
||
<ul class="sidebar-nav">
|
||
<li class="sidebar-nav-heading">管理后台</li> <?php foreach($menus as $key=>$item): ?> <li
|
||
class="sidebar-nav-link"> <a
|
||
href="<?php echo isset($item['index']) ? url($item['index']) : 'javascript:void(0);'; ?>"
|
||
class="<?php echo !empty($item['active']) ? 'active' : ''; ?>"> <?php if((isset($item['is_svg']) && ($item['is_svg'] == true))): ?>
|
||
<svg class="icon sidebar-nav-link-logo" aria-hidden="true">
|
||
<use xlink:href="#<?php echo htmlentities($item['icon']); ?>"></use>
|
||
</svg> <?php else: ?> <i class="iconfont sidebar-nav-link-logo <?php echo htmlentities($item['icon']); ?>"
|
||
style="{isset($item.color) ? 'color:'.$item.color.';' : '' }"></i> <?php endif; ?> <?php echo htmlentities($item['name']); ?>
|
||
</a> </li> <?php endforeach; ?>
|
||
</ul> <!-- 子级菜单--> <?php if((sizeof($second) > 0)): ?> <ul class="left-sidebar-second">
|
||
<li class="sidebar-second-title"><?php echo htmlentities($menus[$group]['name']); ?></li>
|
||
<li class="sidebar-second-item"> <?php foreach($second as $key=>$item): if((!isset($item['submenu']))): ?>
|
||
<!-- 二级菜单--> <a href="<?php echo url($item['index']); ?>" class="<?php echo !empty($item['active']) ? 'active' : ''; ?>">
|
||
<?php echo htmlentities($item['name']); ?> </a> <?php else: ?>
|
||
<!-- 三级菜单-->
|
||
<div class="sidebar-third-item"> <a href="javascript:void(0);"
|
||
class="sidebar-nav-sub-title <?php echo !empty($item['active']) ? 'active' : ''; ?>"> <i
|
||
class="iconfont icongengduo"></i> <?php echo htmlentities($item['name']); ?> </a>
|
||
<ul class="sidebar-third-nav-sub"> <?php foreach($item['submenu'] as $third): ?> <li> <a
|
||
class="<?php echo !empty($third['active']) ? 'active' : ''; ?>" href="<?php echo url($third['index']); ?>">
|
||
<?php echo htmlentities($third['name']); ?> </a> </li> <?php endforeach; ?> </ul>
|
||
</div> <?php endif; ?> <?php endforeach; ?>
|
||
</li>
|
||
</ul> <?php endif; ?>
|
||
</div> <!-- 内容区域 start -->
|
||
<div class="tpl-content-wrapper <?php echo sizeof($second) == 0 ? 'no-sidebar-second' : ''; ?>"> <div class="row-content am-cf">
|
||
|
||
<div class="row">
|
||
|
||
<div class="am-u-sm-12 am-u-md-12 am-u-lg-12">
|
||
|
||
<div class="widget am-cf">
|
||
|
||
<div class="widget-head am-cf">
|
||
|
||
<div class="widget-title am-cf">群发消息列表</div>
|
||
|
||
</div>
|
||
<?php if($wechat AND $wechat['status']['value'] == 1): ?>
|
||
<div class="tips am-margin-bottom-sm am-u-sm-12">
|
||
|
||
<div class="pre-info">
|
||
|
||
<p> 每日可群发100次,但是用户每月只能接收4条。</p>
|
||
|
||
</div>
|
||
|
||
</div>
|
||
|
||
<div class="widget-body am-fr">
|
||
|
||
<div class="am-u-sm-12 am-u-md-6 am-u-lg-6">
|
||
|
||
<div class="am-form-group">
|
||
|
||
<div class="am-btn-toolbar">
|
||
|
||
<div class="am-btn-group am-btn-group-sm">
|
||
|
||
<a href="javascript:void(0);" class="hema-add am-btn am-btn-primary am-radius">
|
||
|
||
<span class="am-icon-plus"></span> 添加
|
||
|
||
</a>
|
||
|
||
</div>
|
||
|
||
</div>
|
||
|
||
</div>
|
||
|
||
</div>
|
||
|
||
<div class="am-scrollable-horizontal am-u-sm-12">
|
||
|
||
<table width="100%" class="am-table am-table-hover tpl-table-black">
|
||
|
||
<thead>
|
||
|
||
<tr>
|
||
|
||
<th>消息编号</th>
|
||
|
||
<th>任务ID</th>
|
||
|
||
<th>消息标题</th>
|
||
|
||
<th>消息类型</th>
|
||
|
||
<th>群发状态</th>
|
||
|
||
<th>群发人数</th>
|
||
|
||
<th>成功人数</th>
|
||
|
||
<th>添加时间</th>
|
||
|
||
<th>操作</th>
|
||
|
||
</tr>
|
||
|
||
</thead>
|
||
|
||
<tbody>
|
||
|
||
<?php if(!$list->isEmpty()): foreach($list as $item): ?>
|
||
|
||
<tr>
|
||
|
||
<td class="am-text-middle"><?php echo htmlentities($item['wechat_batch_send_id']); ?></td>
|
||
|
||
<td class="am-text-middle"><?php echo !empty($item['msg_id']) ? htmlentities($item['msg_id']) : '--'; ?></td>
|
||
|
||
<td class="am-text-middle">
|
||
|
||
<p class="item-title"><?php echo htmlentities($item['title']); ?></p>
|
||
|
||
</td>
|
||
|
||
<td class="am-text-middle"><?php echo htmlentities($item['msg_type']['text']); ?></td>
|
||
|
||
<td class="am-text-middle">
|
||
|
||
<span class="<?php echo $item['status']['value']<40 ? 'x-color-green' : 'x-color-red'; ?>">
|
||
|
||
<?php echo htmlentities($item['status']['text']); ?>
|
||
|
||
</span>
|
||
|
||
</td>
|
||
|
||
<td class="am-text-middle"><?php echo $item['fans_count']>0 ? htmlentities($item['fans_count']) : '--'; ?></td>
|
||
|
||
<td class="am-text-middle"><?php echo $item['send_count']>0 ? htmlentities($item['send_count']) : '--'; ?></td>
|
||
|
||
<td class="am-text-middle"><?php echo htmlentities($item['create_time']); ?></td>
|
||
|
||
<td class="am-text-middle">
|
||
|
||
<div class="tpl-table-black-operation">
|
||
|
||
<a href="javascript:;" class="hema-send tpl-table-black-operation-green"
|
||
|
||
data-id="<?php echo htmlentities($item['wechat_batch_send_id']); ?>">
|
||
|
||
<i class="am-icon-send"></i> 群发
|
||
|
||
</a>
|
||
|
||
<a href="javascript:;" class="hema-edit" data-id="<?php echo htmlentities($item['wechat_batch_send_id']); ?>">
|
||
|
||
<i class="am-icon-pencil"></i> 编辑
|
||
|
||
</a>
|
||
|
||
<a href="javascript:;" class="hema-del tpl-table-black-operation-del"
|
||
|
||
data-id="<?php echo htmlentities($item['wechat_batch_send_id']); ?>">
|
||
|
||
<i class="am-icon-trash"></i> 删除
|
||
|
||
</a>
|
||
|
||
</div>
|
||
|
||
</td>
|
||
|
||
</tr>
|
||
|
||
<?php endforeach; else: ?>
|
||
|
||
<tr>
|
||
|
||
<td colspan="9" class="am-text-center">暂无记录</td>
|
||
|
||
</tr>
|
||
|
||
<?php endif; ?>
|
||
|
||
</tbody>
|
||
|
||
</table>
|
||
|
||
</div>
|
||
|
||
<div class="am-u-lg-12 am-cf">
|
||
|
||
<div class="am-fr"><?php echo $list->render(); ?> </div>
|
||
|
||
<div class="am-fr pagination-total am-margin-right">
|
||
|
||
<div class="am-vertical-align-middle">总记录:<?php echo $list->total(); ?></div>
|
||
|
||
</div>
|
||
|
||
</div>
|
||
|
||
</div>
|
||
<?php else: ?>
|
||
<div class="tips am-margin-bottom-sm am-u-sm-12">
|
||
<div class="pre-error">未绑定授权公众号</div>
|
||
</div>
|
||
<?php endif; ?>
|
||
</div>
|
||
|
||
</div>
|
||
|
||
</div>
|
||
|
||
</div>
|
||
|
||
<!-- 添加 -->
|
||
|
||
|
||
|
||
|
||
<script id="tpl-add" type="text/template">
|
||
|
||
|
||
|
||
|
||
<div class="am-padding-xs am-padding-top-sm">
|
||
|
||
|
||
|
||
|
||
<div class="am-form-group">
|
||
|
||
|
||
|
||
|
||
<label class="am-u-sm-3 am-u-lg-2 am-form-label form-require">消息类型 </label>
|
||
|
||
|
||
|
||
|
||
<div class="am-u-sm-9 am-u-end">
|
||
|
||
|
||
|
||
|
||
<select class="msg_type" name="data[msg_type]" style="width:150px;" required>
|
||
|
||
|
||
|
||
|
||
<option value="">请选择消息类型</option>
|
||
|
||
|
||
|
||
|
||
<option value="news">图文消息</option>
|
||
|
||
|
||
|
||
|
||
<option value="text">文本消息</option>
|
||
|
||
|
||
|
||
|
||
<option value="image">图片消息</option>
|
||
|
||
|
||
|
||
|
||
<option value="video">视频消息</option>
|
||
|
||
|
||
|
||
|
||
<option value="voice">语音消息</option>
|
||
|
||
|
||
|
||
|
||
<option value="music">音乐消息</option>
|
||
|
||
|
||
|
||
|
||
<option value="wxcard">卡券消息</option>
|
||
|
||
|
||
|
||
|
||
</select>
|
||
|
||
|
||
|
||
|
||
</div>
|
||
|
||
|
||
|
||
|
||
</div>
|
||
|
||
|
||
|
||
|
||
<div class="am-form-group">
|
||
|
||
|
||
|
||
|
||
<label class="am-u-sm-3 am-u-lg-2 am-form-label form-require">消息标题 </label>
|
||
|
||
|
||
|
||
|
||
<div class="am-u-sm-9 am-u-end">
|
||
|
||
|
||
|
||
|
||
<input type="text" class="tpl-form-input" name="data[title]" value="" required>
|
||
|
||
|
||
|
||
|
||
</div>
|
||
|
||
|
||
|
||
|
||
</div>
|
||
|
||
|
||
|
||
|
||
<div class="am-form-group material-content">
|
||
|
||
|
||
|
||
|
||
<label class="am-u-sm-3 am-u-lg-2 am-form-label form-require">
|
||
|
||
|
||
|
||
|
||
消息内容 <span class="tpl-form-line-small-title text-no">
|
||
|
||
|
||
|
||
|
||
<text class="material-wxcard">CARD_ID</text>
|
||
|
||
|
||
|
||
|
||
<text class="media-id">MEDIA_ID</text>
|
||
|
||
|
||
|
||
|
||
</span>
|
||
|
||
|
||
|
||
|
||
</label>
|
||
|
||
|
||
|
||
|
||
<div class="am-u-sm-9 am-u-end">
|
||
|
||
|
||
|
||
|
||
<input type="text" class="tpl-form-input" name="data[content]" required>
|
||
|
||
|
||
|
||
|
||
<small class="material-news">获取 <a href="<?php echo url('wechat.material.text/index'); ?>" target="_blank">图文素材MEDIA_ID</a></small>
|
||
|
||
|
||
|
||
|
||
<small class="material-image">获取 <a href="<?php echo url('wechat.material.image/index'); ?>" target="_blank">图片素材MEDIA_ID</a></small>
|
||
|
||
|
||
|
||
|
||
<small class="material-video">获取 <a href="<?php echo url('wechat.material.video/index'); ?>" target="_blank">视频素材MEDIA_ID</a></small>
|
||
|
||
|
||
|
||
|
||
<small class="material-voice">获取 <a href="<?php echo url('wechat.material.voice/index'); ?>" target="_blank">语音素材MEDIA_ID</a></small>
|
||
|
||
|
||
|
||
|
||
</div>
|
||
|
||
|
||
|
||
|
||
</div>
|
||
|
||
|
||
|
||
|
||
<div class="am-form-group material-image">
|
||
|
||
|
||
|
||
|
||
<label class="am-u-sm-3 am-u-lg-2 am-form-label form-require">推荐语 </label>
|
||
|
||
|
||
|
||
|
||
<div class="am-u-sm-9 am-u-end">
|
||
|
||
|
||
|
||
|
||
<input type="text" class="tpl-form-input" name="data[recommend]" value="" required>
|
||
|
||
|
||
|
||
|
||
</div>
|
||
|
||
|
||
|
||
|
||
</div>
|
||
|
||
|
||
|
||
|
||
<div class="am-form-group material-image">
|
||
|
||
|
||
|
||
|
||
<label class="am-u-sm-3 am-u-lg-2 am-form-label form-require">开启评论 </label>
|
||
|
||
|
||
|
||
|
||
<div class="am-u-sm-9 am-u-end">
|
||
|
||
|
||
|
||
|
||
<label class="am-radio-inline">
|
||
|
||
|
||
|
||
|
||
<input type="radio" name="data[need_open_comment]" value="1" data-am-ucheck checked>
|
||
|
||
|
||
|
||
|
||
开启
|
||
|
||
|
||
|
||
|
||
</label>
|
||
|
||
|
||
|
||
|
||
<label class="am-radio-inline">
|
||
|
||
|
||
|
||
|
||
<input type="radio" name="data[need_open_comment]" value="0" data-am-ucheck>
|
||
|
||
|
||
|
||
|
||
关闭
|
||
|
||
|
||
|
||
|
||
</label>
|
||
|
||
|
||
|
||
|
||
</div>
|
||
|
||
|
||
|
||
|
||
</div>
|
||
|
||
|
||
|
||
|
||
<div class="am-form-group material-image">
|
||
|
||
|
||
|
||
|
||
<label class="am-u-sm-3 am-u-lg-2 am-form-label form-require">谁可评论 </label>
|
||
|
||
|
||
|
||
|
||
<div class="am-u-sm-9 am-u-end">
|
||
|
||
|
||
|
||
|
||
<label class="am-radio-inline">
|
||
|
||
|
||
|
||
|
||
<input type="radio" name="data[only_fans_can_comment]" value="1" data-am-ucheck checked>
|
||
|
||
|
||
|
||
|
||
粉丝
|
||
|
||
|
||
|
||
|
||
</label>
|
||
|
||
|
||
|
||
|
||
<label class="am-radio-inline">
|
||
|
||
|
||
|
||
|
||
<input type="radio" name="data[only_fans_can_comment]" value="0" data-am-ucheck>
|
||
|
||
|
||
|
||
|
||
所有人
|
||
|
||
|
||
|
||
|
||
</label>
|
||
|
||
|
||
|
||
|
||
</div>
|
||
|
||
|
||
|
||
|
||
</div>
|
||
|
||
|
||
|
||
|
||
<div class="am-form-group material-image">
|
||
|
||
|
||
|
||
|
||
<label class="am-u-sm-3 am-u-lg-2 am-form-label form-require">素材描述 </label>
|
||
|
||
|
||
|
||
|
||
<div class="am-u-sm-9 am-u-end">
|
||
|
||
|
||
|
||
|
||
<input type="text" class="tpl-form-input" name="data[description]" value="" required>
|
||
|
||
|
||
|
||
|
||
</div>
|
||
|
||
|
||
|
||
|
||
</div>
|
||
|
||
|
||
|
||
|
||
<div class="am-form-group material-news">
|
||
|
||
|
||
|
||
|
||
<label class="am-u-sm-3 am-u-lg-2 am-form-label form-require">判定为转载时 </label>
|
||
|
||
|
||
|
||
|
||
<div class="am-u-sm-9 am-u-end">
|
||
|
||
|
||
|
||
|
||
<label class="am-radio-inline">
|
||
|
||
|
||
|
||
|
||
<input type="radio" name="data[send_ignore_reprint]" value="0" data-am-ucheck checked>
|
||
|
||
|
||
|
||
|
||
停止群发
|
||
|
||
|
||
|
||
|
||
</label>
|
||
|
||
|
||
|
||
|
||
<label class="am-radio-inline">
|
||
|
||
|
||
|
||
|
||
<input type="radio" name="data[send_ignore_reprint]" value="1" data-am-ucheck>
|
||
|
||
|
||
|
||
|
||
继续群发
|
||
|
||
|
||
|
||
|
||
</label>
|
||
|
||
|
||
|
||
|
||
</div>
|
||
|
||
|
||
|
||
|
||
</div>
|
||
|
||
|
||
|
||
|
||
</div>
|
||
|
||
|
||
|
||
|
||
</script>
|
||
|
||
|
||
|
||
|
||
|
||
|
||
<!-- 编辑 -->
|
||
|
||
|
||
|
||
|
||
<script id="tpl-edit" type="text/template">
|
||
|
||
|
||
|
||
|
||
<div class="am-padding-xs am-padding-top-sm">
|
||
|
||
|
||
|
||
|
||
<div class="am-form-group">
|
||
|
||
|
||
|
||
|
||
<label class="am-u-sm-3 am-u-lg-2 am-form-label form-require">消息类型 </label>
|
||
|
||
|
||
|
||
|
||
<div class="am-u-sm-9 am-u-end">
|
||
|
||
|
||
|
||
|
||
<select class="msg_type" name="data[msg_type]" style="width:150px;" required>
|
||
|
||
|
||
|
||
|
||
<option value="">请选择消息类型</option>
|
||
|
||
|
||
|
||
|
||
<option value="news" {{ model.msg_type.value == 'news' ? ' selected':'' }}>图文消息</option>
|
||
|
||
|
||
|
||
|
||
<option value="text" {{ model.msg_type.value == 'text' ? ' selected':'' }}>文本消息</option>
|
||
|
||
|
||
|
||
|
||
<option value="image" {{ model.msg_type.value == 'image' ? ' selected':'' }}>图片消息</option>
|
||
|
||
|
||
|
||
|
||
<option value="video" {{ model.msg_type.value == 'video' ? ' selected':'' }}>视频消息</option>
|
||
|
||
|
||
|
||
|
||
<option value="voice" {{ model.msg_type.value == 'voice' ? ' selected':'' }}>语音消息</option>
|
||
|
||
|
||
|
||
|
||
<option value="music" {{ model.msg_type.value == 'music' ? ' selected':'' }}>音乐消息</option>
|
||
|
||
|
||
|
||
|
||
<option value="wxcard" {{ model.msg_type.value == 'wxcard' ? ' selected':'' }}>卡券消息</option>
|
||
|
||
|
||
|
||
|
||
</select>
|
||
|
||
|
||
|
||
|
||
</div>
|
||
|
||
|
||
|
||
|
||
</div>
|
||
|
||
|
||
|
||
|
||
<div class="am-form-group">
|
||
|
||
|
||
|
||
|
||
<label class="am-u-sm-3 am-u-lg-2 am-form-label form-require">消息标题 </label>
|
||
|
||
|
||
|
||
|
||
<div class="am-u-sm-9 am-u-end">
|
||
|
||
|
||
|
||
|
||
<input type="text" class="tpl-form-input" name="data[title]" value="{{ model.title }}" required>
|
||
|
||
|
||
|
||
|
||
</div>
|
||
|
||
|
||
|
||
|
||
</div>
|
||
|
||
|
||
|
||
|
||
<div class="am-form-group material-content">
|
||
|
||
|
||
|
||
|
||
<label class="am-u-sm-3 am-u-lg-2 am-form-label form-require">
|
||
|
||
|
||
|
||
|
||
消息内容 <span class="tpl-form-line-small-title text-no">
|
||
|
||
|
||
|
||
|
||
<text class="material-wxcard">CARD_ID</text>
|
||
|
||
|
||
|
||
|
||
<text class="media-id">MEDIA_ID</text>
|
||
|
||
|
||
|
||
|
||
</span>
|
||
|
||
|
||
|
||
|
||
</label>
|
||
|
||
|
||
|
||
|
||
<div class="am-u-sm-9 am-u-end">
|
||
|
||
|
||
|
||
|
||
<input type="text" class="tpl-form-input" name="data[content]" value="{{ model.content }}" required>
|
||
|
||
|
||
|
||
|
||
<small class="material-news">获取 <a href="<?php echo url('wechat.material.text/index'); ?>" target="_blank">图文素材MEDIA_ID</a></small>
|
||
|
||
|
||
|
||
|
||
<small class="material-image">获取 <a href="<?php echo url('wechat.material.image/index'); ?>" target="_blank">图片素材MEDIA_ID</a></small>
|
||
|
||
|
||
|
||
|
||
<small class="material-video">获取 <a href="<?php echo url('wechat.material.video/index'); ?>" target="_blank">视频素材MEDIA_ID</a></small>
|
||
|
||
|
||
|
||
|
||
<small class="material-voice">获取 <a href="<?php echo url('wechat.material.voice/index'); ?>" target="_blank">语音素材MEDIA_ID</a></small>
|
||
|
||
|
||
|
||
|
||
</div>
|
||
|
||
|
||
|
||
|
||
</div>
|
||
|
||
|
||
|
||
|
||
<div class="am-form-group material-image">
|
||
|
||
|
||
|
||
|
||
<label class="am-u-sm-3 am-u-lg-2 am-form-label form-require">推荐语 </label>
|
||
|
||
|
||
|
||
|
||
<div class="am-u-sm-9 am-u-end">
|
||
|
||
|
||
|
||
|
||
<input type="text" class="tpl-form-input" name="data[recommend]" value="{{ model.recommend }}" required>
|
||
|
||
|
||
|
||
|
||
</div>
|
||
|
||
|
||
|
||
|
||
</div>
|
||
|
||
|
||
|
||
|
||
<div class="am-form-group material-image">
|
||
|
||
|
||
|
||
|
||
<label class="am-u-sm-3 am-u-lg-2 am-form-label form-require">开启评论 </label>
|
||
|
||
|
||
|
||
|
||
<div class="am-u-sm-9 am-u-end">
|
||
|
||
|
||
|
||
|
||
<label class="am-radio-inline">
|
||
|
||
|
||
|
||
|
||
<input type="radio" name="data[need_open_comment]" value="1" data-am-ucheck {{ model.need_open_comment == 1 ? 'checked' : '' }}>
|
||
|
||
|
||
|
||
|
||
开启
|
||
|
||
|
||
|
||
|
||
</label>
|
||
|
||
|
||
|
||
|
||
<label class="am-radio-inline">
|
||
|
||
|
||
|
||
|
||
<input type="radio" name="data[need_open_comment]" value="0" data-am-ucheck {{ model.need_open_comment == 0 ? 'checked' : '' }}>
|
||
|
||
|
||
|
||
|
||
关闭
|
||
|
||
|
||
|
||
|
||
</label>
|
||
|
||
|
||
|
||
|
||
</div>
|
||
|
||
|
||
|
||
|
||
</div>
|
||
|
||
|
||
|
||
|
||
<div class="am-form-group material-image">
|
||
|
||
|
||
|
||
|
||
<label class="am-u-sm-3 am-u-lg-2 am-form-label form-require">谁可评论 </label>
|
||
|
||
|
||
|
||
|
||
<div class="am-u-sm-9 am-u-end">
|
||
|
||
|
||
|
||
|
||
<label class="am-radio-inline">
|
||
|
||
|
||
|
||
|
||
<input type="radio" name="data[only_fans_can_comment]" value="1" data-am-ucheck {{ model.only_fans_can_comment == 1 ? 'checked' : '' }}>
|
||
|
||
|
||
|
||
|
||
粉丝
|
||
|
||
|
||
|
||
|
||
</label>
|
||
|
||
|
||
|
||
|
||
<label class="am-radio-inline">
|
||
|
||
|
||
|
||
|
||
<input type="radio" name="data[only_fans_can_comment]" value="0" data-am-ucheck {{ model.only_fans_can_comment == 0 ? 'checked' : '' }}>
|
||
|
||
|
||
|
||
|
||
所有人
|
||
|
||
|
||
|
||
|
||
</label>
|
||
|
||
|
||
|
||
|
||
</div>
|
||
|
||
|
||
|
||
|
||
</div>
|
||
|
||
|
||
|
||
|
||
<div class="am-form-group material-image">
|
||
|
||
|
||
|
||
|
||
<label class="am-u-sm-3 am-u-lg-2 am-form-label form-require">素材描述 </label>
|
||
|
||
|
||
|
||
|
||
<div class="am-u-sm-9 am-u-end">
|
||
|
||
|
||
|
||
|
||
<input type="text" class="tpl-form-input" name="data[description]" value="{{ model.description }}" required>
|
||
|
||
|
||
|
||
|
||
</div>
|
||
|
||
|
||
|
||
|
||
</div>
|
||
|
||
|
||
|
||
|
||
<div class="am-form-group material-news">
|
||
|
||
|
||
|
||
|
||
<label class="am-u-sm-3 am-u-lg-2 am-form-label form-require">判定为转载时 </label>
|
||
|
||
|
||
|
||
|
||
<div class="am-u-sm-9 am-u-end">
|
||
|
||
|
||
|
||
|
||
<label class="am-radio-inline">
|
||
|
||
|
||
|
||
|
||
<input type="radio" name="data[send_ignore_reprint]" value="0" data-am-ucheck {{ model.send_ignore_reprint == 0 ? 'checked' : '' }}>
|
||
|
||
|
||
|
||
|
||
停止群发
|
||
|
||
|
||
|
||
|
||
</label>
|
||
|
||
|
||
|
||
|
||
<label class="am-radio-inline">
|
||
|
||
|
||
|
||
|
||
<input type="radio" name="data[send_ignore_reprint]" value="1" data-am-ucheck {{ model.send_ignore_reprint == 1 ? 'checked' : '' }}>
|
||
|
||
|
||
|
||
|
||
继续群发
|
||
|
||
|
||
|
||
|
||
</label>
|
||
|
||
|
||
|
||
|
||
</div>
|
||
|
||
|
||
|
||
|
||
</div>
|
||
|
||
|
||
|
||
|
||
</div>
|
||
|
||
|
||
|
||
|
||
</script>
|
||
|
||
|
||
|
||
|
||
|
||
|
||
<script>
|
||
|
||
$(function () {
|
||
|
||
//添加
|
||
|
||
$('.hema-add').on('click', function () {
|
||
|
||
$.showAction({
|
||
|
||
title: '添加',
|
||
|
||
area: '750px',
|
||
|
||
content: template('tpl-add', {}),
|
||
|
||
uCheck: true,
|
||
|
||
success: function ($content) {
|
||
|
||
var $image = $('.material-image'), $news = $('.material-news'), $text = $('.material-text'), $video = $('.material-video'), $voice = $('.material-voice'), $music = $('.material-music'), $wxcard = $('.material-wxcard'), $contt = $('.material-content'), $text_no = $('.text-no'), $media_id = $('.media-id');
|
||
|
||
$image.hide();
|
||
|
||
$news.hide();
|
||
|
||
$text.hide();
|
||
|
||
$video.hide();
|
||
|
||
$voice.hide();
|
||
|
||
$music.hide();
|
||
|
||
$wxcard.hide();
|
||
|
||
$contt.hide();
|
||
|
||
$text_no.hide();
|
||
|
||
$media_id.hide();
|
||
|
||
$('.msg_type').change(() => {
|
||
|
||
$image.hide();
|
||
|
||
$news.hide();
|
||
|
||
$text.hide();
|
||
|
||
$video.hide();
|
||
|
||
$voice.hide();
|
||
|
||
$music.hide();
|
||
|
||
$wxcard.hide();
|
||
|
||
$contt.hide();
|
||
|
||
$text_no.hide();
|
||
|
||
$media_id.hide();
|
||
|
||
var msg_type = $('.msg_type').val();
|
||
|
||
if(msg_type != ''){
|
||
|
||
$contt.show();
|
||
|
||
}
|
||
|
||
if(msg_type == "text"){
|
||
|
||
$text.show();
|
||
|
||
}else{
|
||
|
||
$text_no.show();
|
||
|
||
}
|
||
|
||
if(msg_type == "wxcard"){
|
||
|
||
$wxcard.show();
|
||
|
||
}else{
|
||
|
||
$media_id.show();
|
||
|
||
}
|
||
|
||
if(msg_type == "image"){
|
||
|
||
$image.show();
|
||
|
||
}
|
||
|
||
if(msg_type == "news"){
|
||
|
||
$news.show();
|
||
|
||
}
|
||
|
||
if(msg_type == "video"){
|
||
|
||
$video.show();
|
||
|
||
}
|
||
|
||
if(msg_type == "voice"){
|
||
|
||
$voice.show();
|
||
|
||
}
|
||
|
||
if(msg_type == "music"){
|
||
|
||
$music.show();
|
||
|
||
}
|
||
|
||
});
|
||
|
||
$('#my-form').formPost({
|
||
|
||
url: "<?php echo url('wechat.send/add'); ?>"
|
||
|
||
});
|
||
|
||
},
|
||
|
||
btn2: function ($content) {
|
||
|
||
return true;
|
||
|
||
}
|
||
|
||
});
|
||
|
||
});
|
||
|
||
//编辑
|
||
|
||
$('.hema-edit').on('click', function () {
|
||
|
||
var data = $(this).data();
|
||
|
||
$.get("<?php echo url('wechat.send/edit'); ?>?id=" + data.id, function (result) {
|
||
|
||
if(result.code == 0){
|
||
|
||
$.show_error(result.msg);
|
||
|
||
return false;
|
||
|
||
}
|
||
|
||
$.showAction({
|
||
|
||
title: '编辑',
|
||
|
||
area: '750px',
|
||
|
||
content: template('tpl-edit', {model:result.data.model}),
|
||
|
||
uCheck: true,
|
||
|
||
success: function ($content) {
|
||
|
||
var $image = $('.material-image'), $news = $('.material-news'), $text = $('.material-text'), $video = $('.material-video'), $voice = $('.material-voice'), $music = $('.material-music'), $wxcard = $('.material-wxcard'), $contt = $('.material-content'), $text_no = $('.text-no'), $media_id = $('.media-id');
|
||
|
||
$image.hide();
|
||
|
||
$news.hide();
|
||
|
||
$text.hide();
|
||
|
||
$video.hide();
|
||
|
||
$voice.hide();
|
||
|
||
$music.hide();
|
||
|
||
$wxcard.hide();
|
||
|
||
$text_no.hide();
|
||
|
||
$media_id.hide();
|
||
|
||
$contt.show();
|
||
|
||
if(result.data.model.msg_type.value == "text"){
|
||
|
||
$text.show();
|
||
|
||
}else{
|
||
|
||
$text_no.show();
|
||
|
||
}
|
||
|
||
if(result.data.model.msg_type.value == "wxcard"){
|
||
|
||
$wxcard.show();
|
||
|
||
}else{
|
||
|
||
$media_id.show();
|
||
|
||
}
|
||
|
||
if(result.data.model.msg_type.value == "image"){
|
||
|
||
$image.show();
|
||
|
||
}
|
||
|
||
if(result.data.model.msg_type.value == "news"){
|
||
|
||
$news.show();
|
||
|
||
}
|
||
|
||
if(result.data.model.msg_type.value == "video"){
|
||
|
||
$video.show();
|
||
|
||
}
|
||
|
||
if(result.data.model.msg_type.value == "voice"){
|
||
|
||
$voice.show();
|
||
|
||
}
|
||
|
||
if(result.data.model.msg_type.value == "music"){
|
||
|
||
$music.show();
|
||
|
||
}
|
||
|
||
$('.msg_type').change(() => {
|
||
|
||
$image.hide();
|
||
|
||
$news.hide();
|
||
|
||
$text.hide();
|
||
|
||
$video.hide();
|
||
|
||
$voice.hide();
|
||
|
||
$music.hide();
|
||
|
||
$wxcard.hide();
|
||
|
||
$contt.hide();
|
||
|
||
$text_no.hide();
|
||
|
||
$media_id.hide();
|
||
|
||
var msg_type = $('.msg_type').val();
|
||
|
||
if(msg_type != ''){
|
||
|
||
$contt.show();
|
||
|
||
}
|
||
|
||
if(msg_type == "text"){
|
||
|
||
$text.show();
|
||
|
||
}else{
|
||
|
||
$text_no.show();
|
||
|
||
}
|
||
|
||
if(msg_type == "wxcard"){
|
||
|
||
$wxcard.show();
|
||
|
||
}else{
|
||
|
||
$media_id.show();
|
||
|
||
}
|
||
|
||
if(msg_type == "image"){
|
||
|
||
$image.show();
|
||
|
||
}
|
||
|
||
if(msg_type == "news"){
|
||
|
||
$news.show();
|
||
|
||
}
|
||
|
||
if(msg_type == "video"){
|
||
|
||
$video.show();
|
||
|
||
}
|
||
|
||
if(msg_type == "voice"){
|
||
|
||
$voice.show();
|
||
|
||
}
|
||
|
||
if(msg_type == "music"){
|
||
|
||
$music.show();
|
||
|
||
}
|
||
|
||
});
|
||
|
||
$('#my-form').formPost({
|
||
|
||
url: "<?php echo url('wechat.send/edit'); ?>?id=" + data.id
|
||
|
||
});
|
||
|
||
},
|
||
|
||
btn2: function ($content) {
|
||
|
||
return true;
|
||
|
||
}
|
||
|
||
});
|
||
|
||
});
|
||
|
||
});
|
||
|
||
// 删除
|
||
|
||
$('.hema-del').del('id', "<?php echo url('wechat.send/delete'); ?>");
|
||
|
||
|
||
|
||
// 群发
|
||
|
||
$('.hema-send').del('id', "<?php echo url('wechat.send/status'); ?>",'确定要进行群发?');
|
||
|
||
|
||
|
||
});
|
||
|
||
</script>
|
||
|
||
|
||
|
||
</div>
|
||
<!-- 内容区域 end -->
|
||
<div class="am-modal am-modal-loading am-modal-no-btn" tabindex="-1" id="addons-loading"></div>
|
||
</div>
|
||
<script src="/assets/plugins/vue/vue.min.js?v=<?php echo htmlentities($version); ?>"></script>
|
||
<script src="/assets/plugins/layer/layer.js?v=<?php echo htmlentities($version); ?>"></script>
|
||
<script src="/assets/plugins/jquery/jquery.form.min.js?v=<?php echo htmlentities($version); ?>"></script>
|
||
<script src="/assets/plugins/amazeui/amazeui.min.js?v=<?php echo htmlentities($version); ?>"></script>
|
||
<script src="/assets/js/hema.app.js?v=<?php echo htmlentities($version); ?>"></script>
|
||
<script src="/assets/js/webuploader.html5only.js?v=<?php echo htmlentities($version); ?>"></script>
|
||
<script src="/assets/js/art-template.js?v=<?php echo htmlentities($version); ?>"></script>
|
||
<script src="/addons/upload/js/file.library.js?v=<?php echo htmlentities($version); ?>"></script>
|
||
<script>
|
||
$(function() {
|
||
// 状态操作
|
||
$('.hemaphp-upgrade').click(function () {
|
||
var is_new = '<?php echo htmlentities($is_new); ?>';
|
||
if(is_new){
|
||
layer.confirm('您确定要进行升级?', {
|
||
title: '友情提示',
|
||
icon: 0,
|
||
btn:['取消','确定'],
|
||
skin: 'layui-layer-hema',
|
||
cancel : function(){
|
||
// 你点击右上角 X 回调
|
||
},
|
||
btn1:function(index,layero){
|
||
layer.close(index);
|
||
},
|
||
btn2:function(index){
|
||
$("#addons-loading").html('<div class="am-modal-dialog"><div class="am-modal-hd">系统升级中,请等待...</div><div class="am-modal-bd"><span class="am-icon-spinner am-icon-spin"></span></div></div>');
|
||
$("#addons-loading").modal('open');
|
||
$.post('/admin/addon/hemaphpUpgrade', {}, function (result) {
|
||
$("#addons-loading").modal('close');
|
||
if(typeof(result) == 'string'){
|
||
result = JSON.parse(result);
|
||
}
|
||
result.code === 1 ? $.show_success(result.msg, result.url) : $.show_error(result.msg);
|
||
});
|
||
layer.close(index);
|
||
},
|
||
end:function() {
|
||
//所有操作都会执行
|
||
}
|
||
});
|
||
return true;
|
||
}
|
||
$.show_error('已是最新版本');
|
||
});
|
||
});
|
||
</script>
|
||
</body>
|
||
</html>
|