mirror of
http://git.coreshop.cn/jianweie/coreshoppro.git
synced 2026-02-06 00:49:48 +08:00
【新增】新增微信扫码支付功能,对接PC端。
【新增】增加DTO类库,将逐步完善dto层。 【修复】修复【分类】切换后,切换回来未清零原始数据,导致更新数据重复的问题。 【调整】移除模板库功能,防止出现审核因为模板库页面存在而导致的审核失败。暂将模板库的代码存放到会员QQ群内,方便下载使用。 【调整】代码生成器【Repository.tpl】移除Cache手动增删改,【SqlSugarSetup】增加sqlsugar自动检测增删改后清理二级缓存。 【调整】后端新增秒杀独立组件,用于区分团购及秒杀的差异,首页新增秒杀组件。 【优化】重写首页所有组件样式及接口数据获取效率。 【优化】优化拼团,秒杀,团购,接龙数据获取逻辑,提升列表及详情页面数据获取效率。 【优化】调整拼团,秒杀,团购,服务商品推广海报为新式海报效果。增加服务商品推广海报。 【优化】清理h5相关代码判断,移除h5支付组件,提高响应速度。 【优化】移除小程序前端冗余代码。加快代码执行效率。
This commit is contained in:
@@ -61,7 +61,7 @@
|
||||
method: 'POST',
|
||||
toolbar: '#LAY-app-getGroupIds-toolbar',
|
||||
defaultToolbar: null,
|
||||
where: { types: 3 },
|
||||
where: { id: 3 },
|
||||
height: 'full-260',//无面包屑127,搜索框189,1行62
|
||||
page: true,
|
||||
limit: 30,
|
||||
@@ -70,8 +70,8 @@
|
||||
cols: [
|
||||
[
|
||||
{ type: "checkbox", fixed: "left" },
|
||||
{ field: 'id', title: '', width: 60, sort: false },
|
||||
{ field: 'name', title: '团购(秒杀)名称', sort: false },
|
||||
{ field: 'id', title: '序列', width: 60, sort: false },
|
||||
{ field: 'name', title: '团购名称', sort: false },
|
||||
{ field: 'sort', title: '权重', sort: false, width: 105 },
|
||||
]
|
||||
],
|
||||
|
||||
132
CoreCms.Net.Web.Admin/wwwroot/views/common/getSeckillIds.html
Normal file
132
CoreCms.Net.Web.Admin/wwwroot/views/common/getSeckillIds.html
Normal file
@@ -0,0 +1,132 @@
|
||||
<script type="text/html" template lay-done="layui.data.done(d);">
|
||||
|
||||
</script>
|
||||
<script type="text/html" id="LAY-app-GetSeckillIds-toolbar">
|
||||
<div class="layui-form coreshop-toolbar-search-form">
|
||||
<div class="layui-form-item">
|
||||
<div class="layui-inline">
|
||||
<div class="layui-input-inline">
|
||||
<input type="text" name="name" id="name" placeholder="请输入秒杀名称" class="layui-input">
|
||||
</div>
|
||||
</div>
|
||||
<div class="layui-inline">
|
||||
<button class="layui-btn layui-btn-sm" lay-submit lay-filter="LAY-app-CoreCmsPromotion-search"><i class="layui-icon layui-icon-search"></i>筛选</button>
|
||||
</div>
|
||||
<div class="layui-inline"><div class="layui-form-mid">您选择了:<span id="tagGroupsNum">0</span>个秒杀</div></div>
|
||||
<button class="layui-btn layui-btn-sm float-right" lay-submit lay-filter="LAY-app-CoreCmsCommon-GetSeckillIds-submit" style="float: right"><i class="layui-icon layui-icon-add-1"></i>提交选项</button>
|
||||
</div>
|
||||
</div>
|
||||
</script>
|
||||
<div class="noDefaultToolbar">
|
||||
<table id="LAY-app-CoreCmsPromotion-tableBox" lay-filter="LAY-app-CoreCmsPromotion-tableBox"></table>
|
||||
</div>
|
||||
|
||||
<script>
|
||||
var ids = {};
|
||||
var table_data = new Array();
|
||||
var indexData;
|
||||
var debug = layui.setter.debug;
|
||||
layui.data.done = function (d) {
|
||||
//开启调试情况下获取接口赋值数据
|
||||
if (debug) { console.log(d); }
|
||||
|
||||
indexData = d.data;
|
||||
layui.use(['index', 'table', 'laydate', 'util', 'coreHelper'],
|
||||
function () {
|
||||
var $ = layui.$
|
||||
, admin = layui.admin
|
||||
, table = layui.table
|
||||
, form = layui.form
|
||||
, laydate = layui.laydate
|
||||
, setter = layui.setter
|
||||
, coreHelper = layui.coreHelper
|
||||
, util = layui.util
|
||||
, view = layui.view;
|
||||
|
||||
//重载form
|
||||
form.render();
|
||||
var searchwhere;
|
||||
//监听搜索
|
||||
form.on('submit(LAY-app-CoreCmsPromotion-search)',
|
||||
function (data) {
|
||||
var field = data.field;
|
||||
searchwhere = field;
|
||||
//执行重载
|
||||
table.reloadData('LAY-app-CoreCmsPromotion-tableBox', { where: field });
|
||||
});
|
||||
//数据绑定
|
||||
table.render({
|
||||
elem: '#LAY-app-CoreCmsPromotion-tableBox',
|
||||
url: layui.setter.apiUrl + 'Api/Tools/TagPromotions',
|
||||
method: 'POST',
|
||||
toolbar: '#LAY-app-GetSeckillIds-toolbar',
|
||||
defaultToolbar: null,
|
||||
where: { id: 4 },
|
||||
height: 'full-260',//无面包屑127,搜索框189,1行62
|
||||
page: true,
|
||||
limit: 30,
|
||||
limits: [10, 15, 20, 25, 30, 50, 100, 200],
|
||||
text: { none: '暂无相关数据' },
|
||||
cols: [
|
||||
[
|
||||
{ type: "checkbox", fixed: "left" },
|
||||
{ field: 'id', title: '序列', width: 60, sort: false },
|
||||
{ field: 'name', title: '秒杀名称', sort: false },
|
||||
{ field: 'sort', title: '权重', sort: false, width: 105 },
|
||||
]
|
||||
],
|
||||
done: function (res, curr, count) {
|
||||
//数据表格加载完成时调用此函数
|
||||
//如果是异步请求数据方式,res即为你接口返回的信息。
|
||||
//如果是直接赋值的方式,res即为:{data: [], count: 99} data为当前页数据、count为数据总长度
|
||||
|
||||
//设置全部数据到全局变量
|
||||
table_data = res.data;
|
||||
|
||||
//在缓存中找到id ,然后设置data表格中的选中状态
|
||||
//循环所有数据,找出对应关系,设置checkbox选中状态
|
||||
for (var i = 0; i < res.data.length; i++) {
|
||||
if (ids[res.data[i].id]) {
|
||||
//这里才是真正的有效勾选
|
||||
res.data[i]["LAY_CHECKED"] = 'true';
|
||||
//找到对应数据改变勾选样式,呈现出选中效果
|
||||
var index = res.data[i]['LAY_TABLE_INDEX'];
|
||||
$('#LAY-app-CoreCmsPromotion-tableBox + div .layui-table-body tr[data-index=' + index + '] input[type="checkbox"]').prop('checked', true);
|
||||
$('#LAY-app-CoreCmsPromotion-tableBox + div .layui-table-body tr[data-index=' + index + '] input[type="checkbox"]').next().addClass('layui-form-checked');
|
||||
}
|
||||
}
|
||||
//设置全选checkbox的选中状态,只有改变LAY_CHECKED的值, table.checkStatus才能抓取到选中的状态
|
||||
var checkStatus = layui.table.checkStatus('LAY-app-CoreCmsPromotion-tableBox');
|
||||
if (checkStatus.isAll) {
|
||||
$('#LAY-app-CoreCmsPromotion-tableBox + div .layui-table-header th[data-field="0"] input[type="checkbox"]').prop('checked', true);
|
||||
$('#LAY-app-CoreCmsPromotion-tableBox + div .layui-table-header th[data-field="0"] input[type="checkbox"]').next().addClass('layui-form-checked');
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
//监听表格复选框选择
|
||||
layui.table.on('checkbox(LAY-app-CoreCmsPromotion-tableBox)', function (obj) {
|
||||
if (obj.checked) {
|
||||
if (obj.type == 'one') {
|
||||
ids[obj.data.id] = obj.data;
|
||||
} else {
|
||||
for (var i = 0; i < table_data.length; i++) {
|
||||
ids[table_data[i].id] = table_data[i];
|
||||
}
|
||||
}
|
||||
//the_val[obj.data.id] = obj.data;
|
||||
} else {
|
||||
if (obj.type == 'one') {
|
||||
delete ids[obj.data.id];
|
||||
} else {
|
||||
for (var i = 0; i < table_data.length; i++) {
|
||||
delete ids[table_data[i].id];
|
||||
}
|
||||
}
|
||||
}
|
||||
$('#tagGroupsNum').html(Object.getOwnPropertyNames(ids).length);
|
||||
});
|
||||
|
||||
});
|
||||
};
|
||||
</script>
|
||||
@@ -225,7 +225,7 @@
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<!-- 团购秒杀 -->
|
||||
<!-- 团购 -->
|
||||
<div v-if="item.type === 'groupPurchase'" class="drag clearfix lay-goods slide group">
|
||||
<div class="goods-head">
|
||||
<div>{{item.value.title}}</div>
|
||||
@@ -248,6 +248,29 @@
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<!-- 秒杀 -->
|
||||
<div v-if="item.type === 'seckill'" class="drag clearfix lay-goods slide group">
|
||||
<div class="goods-head">
|
||||
<div>{{item.value.title}}</div>
|
||||
</div>
|
||||
<div class="group-item" v-for="(goods,key) in item.value.list" :key="key">
|
||||
<div class="group-image">
|
||||
<img src="/static/images/common/empty-banner.png" alt="">
|
||||
</div>
|
||||
<div class="group-detail">
|
||||
<p class="group-name twolist-hidden">
|
||||
{{goods.name||'此处显示商品名称'}}
|
||||
</p>
|
||||
<p class="group-price">{{goods.price||'¥99.00'}}</p>
|
||||
<p class="group-time">
|
||||
<span>剩余:</span><span class="time">21</span>:<span class="time">30</span>:<span class="time">45</span>
|
||||
</p>
|
||||
<span class="buy-icon">
|
||||
<img src="/static/images/common/ic-car.png" alt="">
|
||||
</span>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<!-- 拼团 -->
|
||||
<div v-if="item.type === 'pinTuan'" class="drag clearfix lay-goods slide group">
|
||||
<div class="goods-head">
|
||||
@@ -684,7 +707,7 @@
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
<!-- 团购秒杀 -->
|
||||
<!-- 团购 -->
|
||||
<template v-if="selectWg.type=='groupPurchase'">
|
||||
<div>
|
||||
<div class="select_seller_goods_box">
|
||||
@@ -718,7 +741,46 @@
|
||||
</el-form-item>
|
||||
<div class="pl25">
|
||||
<p class="layout-tip">
|
||||
团购秒杀数据请到 促销管理 - <a href="javascript:;" lay-href="/promotion/group/">团购秒杀列表</a>中管理
|
||||
团购数据请到 促销管理 - <a href="javascript:;" lay-href="/promotion/group/">团购秒杀列表</a>中管理
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
<!-- 秒杀 -->
|
||||
<template v-if="selectWg.type=='seckill'">
|
||||
<div>
|
||||
<div class="select_seller_goods_box">
|
||||
<input type="hidden" name="params[goodsId]" value="">
|
||||
<ul id="selectSeckillGoods" class="sellect_seller_goods_list clearfix">
|
||||
<draggable element="ul" :list="selectWg.value.list" :options="{group:{ name:'selectGoodsList'}, ghostClass: 'ghost',animation: 150}">
|
||||
<li v-for="(goods,key) in selectWg.value.list" :key="key">
|
||||
<i class="layui-icon layui-icon-close-fill icon-delete" @click="handleDeleteGoods(key)"></i>
|
||||
<!--<img :src="goods.image" alt="">-->
|
||||
<div class="left">
|
||||
<img src="/static/images/common/empty-banner.png" alt="">
|
||||
</div>
|
||||
<div class="right">
|
||||
<p>{{goods.name}}</p>
|
||||
</div>
|
||||
</li>
|
||||
</draggable>
|
||||
</ul>
|
||||
<div class="addImg" @click="selectSeckillGoods">
|
||||
<i class="iconfontCustom icon-icon-test"></i>
|
||||
<span>选择商品</span>
|
||||
</div>
|
||||
</div>
|
||||
<hr class="divider">
|
||||
</hr>
|
||||
<el-form-item label="商品组名称">
|
||||
<input type="text" v-model="selectWg.value.title" class="selectLinkVal">
|
||||
</el-form-item>
|
||||
<el-form-item label="显示数量">
|
||||
<input type="number" v-model.number="selectWg.value.limit" min="1" class="number-input">
|
||||
</el-form-item>
|
||||
<div class="pl25">
|
||||
<p class="layout-tip">
|
||||
秒杀数据请到 促销管理 - <a href="javascript:;" lay-href="/promotion/group/">团购秒杀列表</a>中管理
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user