$.get('http://47.104.244.134:8080/cartlist.do', { token: aa }).done(function(data) { console.log(data) for (var i = 0; i < data.length; i++) { var html = ''; html += ` <ul class="order_lists"> <li class="list_chk"> <input type="checkbox" class="son_check"> <label for="checkbox_2"></label> </li> <li class="list_con"> <div class="list_img"><a href="javascript:;"><img src="${data[i].goods.picurl}" alt=""></a></div> <div class="list_text"><a href="javascript:;">${data[i].goods.name}</a></div> </li> <li class="list_info"> ${data[i].createtime} </li> <li class="list_price"> <p class="price">¥${data[i].goods.price} </li> <li class="list_amount"> <div class="amount_box"> <a href="javascript:;" class="reduce reSty">-</a> <input type="text" value="${data[i].count}" class="sum"> <a href="javascript:;" class="plus">+</a> </div> </li> <li class="list_sum"> <p class="sum_price">¥${data[i].goods.price * data[i].count} </li> <li class="list_op"> <p class="del"><a href="javascript:;" class="delBtn">移除商品</a> </li> </ul> ` $('.order_content').append(html);
点击结算跳转在哪加啊,,我加了location.href但是不打勾也可以跳转,,
有个BUG 当全选中后 刷新页面 此时默认所有的选项还是选中的 点击任意一个 总价为所有的价钱之和减去点击的这一个