123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289 |
- {include file="public/layout" /}
- <body class="bodystyle" style="cursor: default; -moz-user-select: inherit;min-width:auto;">
- <div id="append_parent"></div>
- <div id="ajaxwaitid"></div>
- {include file="shop/left" /}
- <!-- <div class="page {empty name='$web_shopcomment_switch'}on-off_show{/empty}"> -->
- <div class="page min-hg-c-10">
- <!--遮罩给上面的class + on-off_show-->
- <!-- <div class="on-off_shade">
- <div class="on-off_shadeCon">
- <span>目前还没有开启商品评价功能,<a href="javascript:void(0);" data-url="{:url('ShopComment/ajax_open_close')}" data-value="{$web_navigation_switch}" onclick="ajax_open_close(this);">我要开启</a></span>
- </div>
- </div> -->
- <!-- <div class="fixed-bar">
- <div class="item-title">
- <a class="back_xin" href="javascript:history.back();" title="返回"><i class="iconfont e-fanhui"></i></a>
- <div class="subject">
- <h3>评价列表</h3>
- <h5></h5>
- </div>
- </div>
- </div> -->
- <div class="flexigrid">
- <div class="mDiv pt0">
- <div class="ftitle">
- <div class="fbutton">
- <a href="{:url('ShopComment/comment_add')}" >
- <div class="add" title="创建评价">
- <span><i class="layui-icon layui-icon-addition"></i>创建评价</span>
- </div>
- </a>
- </div>
- </div>
- <form class="navbar-form form-inline" id="postForm" action="{:url('ShopComment/comment_index')}" method="get" onsubmit="layer_loading('正在处理');">
- {$searchform.hidden|default=''}
- <div class="sDiv">
- <div class="sDiv2">
- <input type="text" size="50" name="order_code" value="{$Request.param.order_code}" class="qsbox" style="width: 200px;" placeholder="搜索订单号..."> <input type="submit" class="btn" value="搜索"> <i class="iconfont e-sousuo"></i>
- </div>
- <!-- {notempty name='$web_shopcomment_switch'}
- <a href="javascript:void(0);" data-url="{:url('ShopComment/ajax_open_close')}" data-value="{$web_shopcomment_switch}" onclick="ajax_open_close(this);">关闭评价</a>
- {/notempty} -->
- </div>
- </form>
- </div>
-
- <div class="hDiv">
- <div class="hDivBox">
- <table cellspacing="0" cellpadding="0" style="width: 100%">
- <thead>
- <tr>
- <th class="sign w40" axis="col0">
- <div class="tc"><input type="checkbox" autocomplete="off" class="checkAll"></div>
- </th>
-
- <th align="center" abbr="article_title" axis="col3" class="w250">
- <div class="text-l10 ">商品信息</div>
- </th>
-
- <th abbr="article_title" axis="col3" class="">
- <div style="text-align: left; padding-left: 10px;" class="">评价内容</div>
- </th>
-
- <th abbr="" axis="col6" class="w80">
- <div class="tc">来源</div>
- </th>
-
- <th abbr="" axis="col6" class="w120">
- <div class="tc">评价评分</div>
- </th>
-
- <th abbr="" axis="col6" class="w120">
- <div class="tc">用户</div>
- </th>
-
- <th abbr="" axis="col6" class="w80">
- <div class="tc">审核</div>
- </th>
-
- <th abbr="article_time" axis="col6" class="w160">
- <div class="tc">评价时间</div>
- </th>
-
- <th axis="col1" class="w150">
- <div class="tc">操作</div>
- </th>
- </tr>
- </thead>
- </table>
- </div>
- </div>
- <div class="bDiv" style="height: auto;">
- <div id="flexigrid" cellpadding="0" cellspacing="0" border="0">
- <table style="width: 100%">
- <tbody>
- {empty name="Comment"}
- <tr>
- <td class="no-data" align="center" axis="col0" colspan="50">
- <i class="fa fa-exclamation-circle"></i>没有符合条件的记录
- </td>
- </tr>
- {else/}
- {volist name="Comment" id="vo"}
- <tr>
- <td class="sign">
- <div class="w40 tc"> <input type="checkbox" autocomplete="off" name="ids[]" value="{$vo.comment_id}"> </div>
- </td>
-
- <td class="">
- <div class="w250 flex-row">
- <a href="{$vo.arcurl}" target="_blank"><img width="60" height="60" src="{$vo.product_img}"></a>
- <div>
- <a href="{$vo.arcurl}" target="_blank" class="ml5">{$vo.product_name}</a>
- </div>
-
- </div>
- </td>
-
- <td class="" style="width: 100%;">
- <div class="tl text-l10" > {$vo.content} </div>
- </td>
-
- <td class=""> <div class="w80 tc"> {eq name="$vo.systemComment" value="1"}后台{else/}客户{/eq} </div> </td>
-
- <td class=""> <div class="w120 tc"> <i class="z_comment-star z_star{$vo.total_score}"></i> </div> </td>
-
- <td class="">
- <div class="w120 tc">
- <a href="javascript:void(0);" data-href="{:url('Member/users_edit', array('id' => $vo['users_id']))}" onclick="openFullframe(this, '用户资料', '100%', '100%');"> <img style="width: 30px;height: 30px;margin:0px 5px!important;float: unset;margin: auto;border-radius: 100%;" src="{$vo.head_pic}" />{$vo.nickname} </a>
- </div>
- </td>
-
- <td class="">
- <div class="w80 tc">
- {eq name="$vo['is_show']" value='1'}
- <span class="yes" onClick="changeTableVal('shop_order_comment', 'comment_id', '{$vo.comment_id}', 'is_show', this);"><i class="fa fa-check-circle"></i>是</span>
- {else /}
- <span class="no" onClick="changeTableVal('shop_order_comment', 'comment_id', '{$vo.comment_id}', 'is_show', this);"><i class="fa fa-ban"></i>否</span>
- {/eq}
- </div>
- </td>
-
- <td class=""> <div class="w160 tc"> {$vo.add_time|MyDate='Y-m-d H:i:s',###} </div> </td>
-
- <td class="operation">
- <div class="w150 tc">
- <a href="{:url('ShopComment/comment_details', array('comment_id' => $vo['comment_id']))}" class="btn blue">详情</a>
- <i></i>
- <!-- <a class="btn blue">显示</a> -->
- <a href="javascript:void(0);" data-id="{$vo.comment_id}" data-admin_reply="{$vo.admin_reply.adminReply}" data-reply_time="{$vo.admin_reply.replyTime}" onclick="commentAdminReply(this);" class="btn blue">回复{notempty name="$vo.admin_reply.adminReply"}<em class="num">!</em>{/notempty}</a>
- <i></i>
- <a href="javascript:void(0);" data-url="{:url('ShopComment/comment_del')}" data-id="{$vo.comment_id}" onclick="delfun(this);" class="btn blue">删除</a>
- </div>
- </td>
- </tr>
- {/volist}
- {/empty}
- </tbody>
- </table>
- </div>
- <div class="iDiv" style="display: none;"></div>
- </div>
- {notempty name="Comment"}
- <div class="tDiv">
- <div class="tDiv2">
- <div class="fbutton checkboxall">
- <input type="checkbox" autocomplete="off" class="checkAll">
- </div>
- <div class="fbutton">
- <a onclick="batch_del(this, 'ids');" data-url="{:url('ShopComment/comment_del')}" class="layui-btn layui-btn-primary"><span>批量删除</span></a>
- </div>
- {include file="public/page" /}
- </div>
- <div style="clear:both"></div>
- </div>
- {/notempty}
- </div>
- </div>
- <script type="text/javascript">
- try{
- if (typeof(eval('is_conceal_1649209614'))=="function" && is_conceal_1649209614()){
- $(".page").css("margin-left","");
- $(".page").css("min-width","");
- }else{
- $(".page").css("margin-left","100px");
- $(".page").css("min-width","auto");
- }
- }catch(e){}
-
- $(function(){
- $('input[name*=ids]').click(function(){
- if ($('input[name*=ids]').length == $('input[name*=ids]:checked').length) {
- $('.checkAll').prop('checked','checked');
- } else {
- $('.checkAll').prop('checked', false);
- }
- });
- $('input[type=checkbox].checkAll').click(function(){
- $('input[type=checkbox]').prop('checked',this.checked);
- });
- });
-
- $(document).ready(function(){
- // 表格行点击选中切换
- $('#flexigrid > table>tbody >tr').click(function(){
- $(this).toggleClass('trSelected');
- });
-
- // 点击刷新数据
- $('.fa-refresh').click(function(){
- location.href = location.href;
- });
- });
-
- function ajax_open_close(obj, inc_type, name,value) {
- $.ajax({
- type : 'post',
- url : $(obj).attr('data-url'),
- data : {value:$(obj).attr('data-value'), _ajax:1},
- dataType : 'json',
- success : function(res){
- if(res.code == 1){
- window.location.reload();
- }else{
- showErrorMsg(res.msg);
- }
- },
- error: function(e){
- showErrorAlert(e.responseText);
- }
- })
- }
-
- // 商家快捷回复
- function commentAdminReply(obj) {
- var commentID = $(obj).attr('data-id') ? $(obj).attr('data-id') : 0;
- var reply_time = $(obj).attr('data-reply_time') ? $(obj).attr('data-reply_time') : 0;
- var admin_reply = $(obj).attr('data-admin_reply') ? $(obj).attr('data-admin_reply') : '';
- layer.prompt({
- formType: 2,
- shade: layer_shade,
- value: admin_reply,
- title: '请填写商家回复',
- btnAlign:'r',
- closeBtn: 3,
- id: 'adminReply',
- btn: ['确定', '取消'],
- area: ['300px', '100px'],
- success: function(layero, index) {
- $(".layui-layer-content").css('text-align', 'left');
- // 回复框字数限制
- $("#adminReply").find('textarea').attr('maxlength', '280');
- // 回复框标题
- $("#adminReply").prepend(msg);
- // 回复框更新时间
- if (parseInt(reply_time) !== 0) {
- var msg = '<br/><span style="color: #999; font-size: 12px;">最后更新:'+reply_time+'</span>';
- $("#adminReply").append(msg);
- }
- }
- }, function(adminReply, index, elem) {
- // 商家快捷回复
- addCommentAdminReply(commentID, adminReply);
- layer.close(index);
- });
- }
-
- // 商家快捷回复
- function addCommentAdminReply(commentID, adminReply) {
- $.ajax({
- type: 'post',
- url : "{:url('ShopComment/comment_admin_reply', ['_ajax'=>1])}",
- data: {comment_id: commentID, admin_reply: adminReply},
- dataType: 'json',
- success : function(res) {
- if (1 === parseInt(res.code)) {
- window.location.reload();
- } else {
- showErrorMsg(res.msg);
- }
- },
- error: function(e) {
- showErrorAlert(e.responseText);
- }
- });
- }
- </script>
-
- {include file="public/footer" /}
|