一、買家投訴
文件路徑:shop/controllers/Buyer/Service/ComplainCtl.php
視圖:shop/views/default/Buyer/Service/ComplainCtl/add.php
投訴表單提交:`$('#form').validator({})`
方法:addComplain()
~~~
$add_flag = $complain_id = $this->complainBaseModel->addBase($field, true);
check_rs($add_flag, $rs_row);
$field2['complain_id'] = $complain_id;
$field2['goods_id'] = $goods['goods_id'];
$field2['goods_name'] = $goods['goods_name'];
$field2['goods_price'] = $goods['goods_price'];
$field2['goods_num'] = $goods['order_goods_num'];
$field2['goods_image'] = $goods['goods_image'];
$field2['complain_message'] = $complain_content;
$field2['order_goods_id'] = $goods_id;
$field2['order_goods_type'] = 1;
$field2['order_id'] = $goods['order_id'];
$add_flag = $this->complainGoodsModel->addGoods($field2);
~~~
二、平臺審核
文件路徑:shop/controllers/Api/Trade/ComplainCtl.php
視圖:shop_admin/view/default/Trade/ComplainCtl/complain.php
JS:shop_admin/static/default/js/controllers/trade/complain/complain_list.js
三、賣家申訴
文件路徑:shop/controllers/Seller/Service/ComplainCtl.php
視圖:shop/views/default/Seller/Service/ComplainCtl/detail.php
`<input id="handle_submit" type="button" class="button button_red bbc_seller_submit_btns" value="<?=__('確認提交')?>">`
申訴提交表單驗證:
~~~
$('#form').validator({
ignore: ':hidden',
theme: 'yellow_right',
timely: 1,
stopOnError: false,
fields: field,
valid: function (form)
{
//表單驗證通過,提交表單
$.ajax({
url: ajax_url,
data: $("#form").serialize(),
success: function (a)
{
if (a.status == 200)
{
location.href = "./index.php?ctl=Seller_Service_Complain&met=index&act=detail&id=<?=$data['id']?>";
}
else
{
Public.tips.error('<?=__('操作失敗!')?>');
}
}
});
}
}).on("click", "#handle_submit", function (e)
{
$(e.delegateTarget).trigger("validate");
});
~~~
三、買賣雙方對話
* 賣家:
文件路徑:shop/controllers/Seller/Service/ComplainCtl.php
視圖:shop/views/default/Seller/Service/ComplainCtl/detail.php
方法:publishComplainTalk()
~~~
$("#btn_publish").click(function ()
{
if ($("#complain_talk").val() == '')
{
Public.tips.error("<?=__('對話不能為空')?>");
}
else
{
publish_complain_talk();
}
});
//發布對話
function publish_complain_talk()
{
$.ajax({
type: 'POST',
url: SITE_URL + '?ctl=Buyer_Service_Complain&met=publishComplainTalk&typ=json',
cache: false,
data: "complain_id=" + complain_id + "&complain_talk=" + encodeURIComponent($("#complain_talk").val()),
dataType: 'json',
error: function ()
{
Public.tips.error("<?=__('對話發送失敗')?>");
},
success: function (d)
{
if (d.msg == 'success')
{
$("#complain_talk").val('');
Public.tips.success("<?=__('對話發送成功')?>");
get_complain_talk();
}
else
{
Public.tips.error("<?=__('對話發送失敗')?>");
}
}
});
}
~~~
~~~
$Complain_TalkModel = new Complain_TalkModel();
$flag = $Complain_TalkModel->addTalk($filed);
~~~
* 買家:
文件路徑:shop/controllers/Buyer/Service/ComplainCtl.php
視圖:shop/views/default/Buyer/Service/ComplainCtl/detail.php
~~~
$("#btn_publish").click(function ()
{
if ($("#complain_talk").val() == '')
{
Public.tips.error("<?=__('對話不能為空')?>");
}
else
{
publish_complain_talk();
}
});
//發布對話
function publish_complain_talk()
{
$.ajax({
type: 'POST',
url: SITE_URL + '?ctl=Buyer_Service_Complain&met=publishComplainTalk&typ=json',
cache: false,
data: "complain_id=" + complain_id + "&complain_talk=" + encodeURIComponent($("#complain_talk").val()),
dataType: 'json',
error: function ()
{
Public.tips.error("<?=__('對話發送失敗')?>");
},
success: function (d)
{
if (d.msg == 'success')
{
$("#complain_talk").val('');
Public.tips.success("<?=__('對話發送成功')?>");
get_complain_talk();
}
else
{
Public.tips.error("<?=__('對話發送失敗')?>");
}
}
});
}
~~~
方法:publishComplainTalk()
~~~
$Complain_TalkModel = new Complain_TalkModel();
$flag = $Complain_TalkModel->addTalk($filed);
~~~
四、平臺仲裁
文件路徑:shop/controllers/Api/Trade/ComplainCtl.php
視圖:shop_admin/view/default/Trade/ComplainCtl/getComplainInfo.php
JS:shop_admin/static/default/js/controllers/trade/complain/progress.js
關閉投訴、處理意見:
~~~
$('#close_form').validator({
ignore: ':hidden',
theme: 'yellow_bottom',
timely: 1,
stopOnError: true,
fields: {
'final_handle_message': 'required;'
},
valid: function (form)
{
parent.$.dialog.confirm('確認關閉此投訴?', function ()
{
Public.ajaxPost(SITE_URL + '?ctl=Trade_Complain&met=handleComplain&typ=json', $("#close_form").serialize(), function (data)
{
if (data.status == 200)
{
parent.Public.tips({content: '操作成功!'});
window.location.href = SITE_URL + "?ctl=Trade_Complain&met=complain&state=5";
}
else
{
parent.Public.tips({type: 1, content: data.msg || '操作無法成功,請稍后重試!'});
}
});
},
function ()
{
});
},
}).on("click", "a#btn_handle_submit", function (e)
{
$(e.delegateTarget).trigger("validate");
});
~~~
五、店鋪投訴管理
文件路徑:shop/controllers/Seller/Service/ComplainCtl.php
* 投訴狀態:1-新投訴、2-待申訴、3-對話中、4-待仲裁、5-已關閉
~~~
const COMPLAIN_FRESH = 1;
const COMPLAIN_APPEAL = 2;
const COMPLAIN_TALK = 3;
const COMPLAIN_HANDLE = 4;
const COMPLAIN_FINISH = 5;
public static $state = array(
'1' => 'new',
'2' => 'appeal',//投訴通過轉給被投訴人
'3' => 'talk',//被投訴人已申訴
'4' => 'handle',//提交仲裁
'5' => 'finish',
);
~~~
* 視圖:根據URL獲得參數act的值,判斷視圖
~~~
if ($act == "detail")
{
$data = $this->detail();
$this->view->setMet('detail');
}
else
{
//index.php(視圖)
}
~~~
1.投訴管理列表
視圖:shop/views/default/Seller/Service/ComplainCtl/index.php
方法:index()
~~~
$data = $this->complainBaseModel->getBaseList($cond_row, array('complain_datetime' => 'DESC'), $page, $rows);
~~~
2.查看投訴詳情
視圖:shop/views/default/Seller/Service/ComplainCtl/detail.php
方法:detail()
~~~
$data = $this->complainBaseModel->getComplainBase($cond_row);
$data['good'] = $this->complainGoodsModel->getOneByWhere(array("complain_id" => $complain_id));
~~~
六、用戶投訴管理
1.投訴列表
文件路徑:shop/controllers/Buyer/Service/ComplainCtl.php -> index()
視圖:shop/views/default/Buyer/Service/ComplainCtl/index.php
~~~
$Yf_Page = new Yf_Page();
$Yf_Page->listRows = 10;
$rows = $Yf_Page->listRows;
$offset = request_int('firstRow', 0);
$page = ceil_r($offset / $rows);
$state = request_int("status");
$cond_row['user_id_accuser'] = Perm::$userId; //店鋪ID
if ($state)
{
$cond_row['complain_state'] = $state;
}
$data = $this->complainBaseModel->getBaseList($cond_row, array('complain_datetime' => 'DESC'), $page, $rows);
~~~
2.投訴詳情
文件路徑:shop/controllers/Buyer/Service/ComplainCtl.php
視圖:shop/views/default/Buyer/Service/ComplainCtl/index.php
方法:detail()
~~~
//根據獲取到的act的值判斷視圖
if ($act == "detail")
{
$data = $this->detail();
$this->view->setMet('detail');
$d = $data;
}
$data = $this->complainBaseModel->getComplainBase($cond_row);
$data['good'] = $this->complainGoodsModel->getOneByWhere(array("complain_id" => $complain_id));
$data['id'] = $complain_id;
$data['order'] = $this->orderBaseModel->getOneByWhere(array('order_id' => $data['good']['order_id']));
$data['ordergoods'] = $this->orderGoodsModel->getOneByWhere(array('order_goods_id' => $data['good']['order_goods_id']));
$data['shop'] = $this->shopBaseModel->getOne($data['user_id_accused']);
$shop_company = $this->shopCompanyModel->getOne($data['user_id_accused']);
$data['shop']['shop_company_address'] = $shop_company['shop_company_address'];
~~~
- 序言
- 系統要求
- 版本更新日志
- 遠豐商城技術對接說明
- 開發指導
- 系統架構
- 負載集群
- 云存儲
- 框架內容
- 基礎
- 開發規范
- 目錄結構
- 架構
- 架構總覽
- 數據庫
- 數據庫連接
- 基本使用
- 緩存
- 配置
- 路由
- 數據字典
- ucenter
- shop
- paycenter
- ucenter_admin
- shop_admin
- paycenter_admin
- shop1
- shop2
- shop3
- 通訊內容
- 商家中心
- 頂部導航欄
- 店鋪信息欄
- 店鋪及商品提示欄
- 交易提示欄
- 銷售情況統計欄
- 集群架構圖
- 單品銷量排行欄
- 店鋪運營推廣欄
- 平臺聯系方式欄
- 訂單物流
- 商品
- 商品列表
- 商品詳情
- 商品發布與編輯
- 分銷商品
- 關聯版式
- 商品規格
- 圖片空間
- 淘寶導入
- 訂單流程
- 交易訂單
- 訂單退款/退貨
- 促銷
- 團購管理
- 加價購
- 限時折扣
- 滿即送
- 代金券管理
- 分銷
- 店鋪
- 店鋪設置
- 自銷產品供應商
- 實體店鋪
- 品牌申請
- 店鋪信息
- 消費者保障服務
- 門店賬號
- 分銷商--產品供應商
- 分銷明細
- 批發市場
- 商家微信公眾號
- 售后服務
- 咨詢管理
- 投訴管理
- 退款管理
- 退貨管理
- 雜項
- 遠程上傳圖片
- 接口(廢棄,參考最外層接口項)
- 接口說明
- 品牌
- 商品規格
- 商品類型
- 商品分類
- 商品
- 訂單
- 商品/店鋪收藏
- 足跡
- 退款及退貨
- 商家店鋪
- 會員
- 入駐協議
- 訂單接口
- 商品接口
- 訂單物流接口
- 商家中心接口
- 促銷接口
- 快遞鳥物流接口
- 代金券接口
- 首頁版塊
- 團購
- 平臺紅包
- 限時折扣接口
- 拼團接口
- wap首頁模板
- JS
- 銀聯支付
- 多語言
- 商品評分
- 圖片加載
- 買家申請退款退貨
- 商家退款退貨
- 平臺退款退貨
- 添加發票
- 提交訂單
- 確認訂單
- 運費銷售區域
- 獲取會員地址
- 充值
- 導出XLS
- 商城系統集成
- 多語言實現
- 三級分銷推廣鏈接發展推廣員
- app.ini.php
- 去分銷
- 版本更新
- 物流支持
- 運營人員建議
- 業務邏輯
- 統計結算
- 客服消息
- 賬號
- 三級分銷
- IM
- 配置
- 平臺帳號
- 活動數據表說明
- 接口
- 數據庫中間鍵
- MyCat的優勢
- 概念說明
- Mycat的下載及安裝
- 參數配置案列
- Mycat讀寫分離
- 基本命令
- 常見錯誤