Commit 6dbd5f69 by 施宇

Merge branch 'sy_xbyh_191113'

parents 37f512a2 3d3521aa
...@@ -40,7 +40,7 @@ ...@@ -40,7 +40,7 @@
<script type="text/html" id="zqTpl"> <script type="text/html" id="zqTpl">
<div class="my_xj_list clr "> <div class="my_xj_list clr ">
{{# layui.each(d, function(index, item){ }} {{# layui.each(d, function(index, item){ }}
<div class="my_xj_item fl boxsiz" style="cursor:pointer" userid="{{item.inquiry_items_id}}"> <div class="my_xj_item fl boxsiz" style="cursor:pointer" inquiryid="{{item.inquiry_items_id}}" userid="{{item.user_id}}">
<div class="item_top clr"> <div class="item_top clr">
<div class="fl num ellipsis">{{item.goods_name}}</div> <div class="fl num ellipsis">{{item.goods_name}}</div>
</div> </div>
......
...@@ -125,7 +125,7 @@ ...@@ -125,7 +125,7 @@
<script type="text/html" id="xjhtml"> <script type="text/html" id="xjhtml">
<div class="my_xj_list clr "> <div class="my_xj_list clr ">
{{# layui.each(d, function(index, item){ }} {{# layui.each(d, function(index, item){ }}
<div class="my_xj_item fl boxsiz xj_item" style="cursor:pointer" userid="{{item.inquiry_items_id}}"> <div class="my_xj_item fl boxsiz xj_item" style="cursor:pointer" inquiryid="{{item.inquiry_items_id}}" userid="{{item.user_id}}">
<div class="item_top clr"> <div class="item_top clr">
<div class="fl num ellipsis">{{item.goods_name}}</div> <div class="fl num ellipsis">{{item.goods_name}}</div>
</div> </div>
......
...@@ -58,8 +58,15 @@ $(function () { ...@@ -58,8 +58,15 @@ $(function () {
self.getData(index,1) self.getData(index,1)
}); });
$('.roborder_content').on('click','.my_xj_item',function(){ $('.roborder_content').on('click','.my_xj_item',function(){
var inquiryid = $(this).attr('inquiryid');
var userid = $(this).attr('userid'); var userid = $(this).attr('userid');
window.location.href = "/quotedetail?id=" + userid var cookieUserId = Util.getCookie('user_id') || '';
if (userid == cookieUserId) {
//自己查看自己的
window.location.href = "/inquirydetail?id=" + inquiryid
} else {
window.location.href = "/quotedetail?id=" + inquiryid
}
}); });
//编辑 //编辑
// $('.edit_div').click(function () { // $('.edit_div').click(function () {
......
...@@ -129,20 +129,27 @@ $(function () { ...@@ -129,20 +129,27 @@ $(function () {
} }
}); });
$('.goods_data_list').on('click', '.xj_item', function () { $('.goods_data_list').on('click', '.xj_item', function () {
var inquiryid = $(this).attr('inquiryid');
var userid = $(this).attr('userid'); var userid = $(this).attr('userid');
window.location.href = "/quotedetail?id=" + userid var cookieUserId = Util.getCookie('user_id') || '';
if (userid == cookieUserId) {
//自己查看自己的
window.location.href = "/inquirydetail?id=" + inquiryid
} else {
window.location.href = "/quotedetail?id=" + inquiryid
}
}); });
$('.goods_data_list').on('click', '.sp_item', function () { $('.goods_data_list').on('click', '.sp_item', function () {
var goodid = $(this).attr('goodid'); var goodid = $(this).attr('goodid');
var eleuserid = $(this).attr('userid'); var eleuserid = $(this).attr('userid');
var userid = Util.getCookie('user_id') || ""; var userid = Util.getCookie('user_id') || "";
var type; var type;
if(userid === eleuserid){ if (userid === eleuserid) {
type = 1 type = 1
}else{ } else {
type = 2 type = 2
} }
window.location.href = "/gooddetail?type="+ type +"&id=" + goodid window.location.href = "/gooddetail?type=" + type + "&id=" + goodid
}); });
$('.goods_data_list').on('click', '.lx_cus', function () { $('.goods_data_list').on('click', '.lx_cus', function () {
Util.setCookie('customer', Util.getRequest('key') || "", 1, cookieHostname) Util.setCookie('customer', Util.getRequest('key') || "", 1, cookieHostname)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment