mirror of
http://git.coreshop.cn/jianweie/coreshoppro.git
synced 2025-12-06 17:23:26 +08:00
【优化】取消文章后台发布缩略图限制,优化数据出口及列表展示。
This commit is contained in:
@@ -18,7 +18,7 @@
|
|||||||
<view class="coreshop-bg-white coreshop-margin-10">
|
<view class="coreshop-bg-white coreshop-margin-10">
|
||||||
<view class="coreshop-flex coreshop-solid-bottom coreshop-justify-between coreshop-flex-nowrap coreshop-padding-top-10 coreshop-padding-bottom-10 coreshop-padding-left-10 coreshop-padding-right-10" v-for="item in list" :key="item.id" @click="goArticleDetail(item.id)">
|
<view class="coreshop-flex coreshop-solid-bottom coreshop-justify-between coreshop-flex-nowrap coreshop-padding-top-10 coreshop-padding-bottom-10 coreshop-padding-left-10 coreshop-padding-right-10" v-for="item in list" :key="item.id" @click="goArticleDetail(item.id)">
|
||||||
<view class="coreshop-flex coreshop-flex-nowrap">
|
<view class="coreshop-flex coreshop-flex-nowrap">
|
||||||
<u--image width="25px" height="25px" :src="item.coverImage" mode="aspectFill" :showLoading="true"></u--image>
|
<u--image width="25px" height="25px" :src="item.coverImage? item.coverImage : '/static/images/common/empty.png'" mode="aspectFill" :showLoading="true"></u--image>
|
||||||
<view class="u-line-2 coreshop-padding-left-5 coreshop-font-14">{{item.title}}</view>
|
<view class="u-line-2 coreshop-padding-left-5 coreshop-font-14">{{item.title}}</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="coreshop-text-gray coreshop-text-right coreshop-justify-end">
|
<view class="coreshop-text-gray coreshop-text-right coreshop-justify-end">
|
||||||
|
|||||||
@@ -36,7 +36,7 @@
|
|||||||
<div class="layui-form-item">
|
<div class="layui-form-item">
|
||||||
<label for="coverImage" class="layui-form-label">封面图</label>
|
<label for="coverImage" class="layui-form-label">封面图</label>
|
||||||
<div class="layui-input-inline layui-inline-10">
|
<div class="layui-input-inline layui-inline-10">
|
||||||
<input name="coverImage" id="coverImage" lay-verType="tips" lay-verify="required" class="layui-input" placeholder="请上传封面图" lay-reqText="请上传封面图" />
|
<input name="coverImage" id="coverImage" lay-verType="tips" class="layui-input" placeholder="请上传封面图" lay-reqText="请上传封面图" />
|
||||||
</div>
|
</div>
|
||||||
<div class="layui-input-inline">
|
<div class="layui-input-inline">
|
||||||
<img class="coreshop-upload-img" id="viewImgBoxcoverImage" src="{{ layui.setter.noImagePicUrl }}">
|
<img class="coreshop-upload-img" id="viewImgBoxcoverImage" src="{{ layui.setter.noImagePicUrl }}">
|
||||||
@@ -63,7 +63,7 @@
|
|||||||
</div>
|
</div>
|
||||||
<label for="isPub" class="layui-form-label">是否发布</label>
|
<label for="isPub" class="layui-form-label">是否发布</label>
|
||||||
<div class="layui-input-inline layui-inline-2">
|
<div class="layui-input-inline layui-inline-2">
|
||||||
<input type="checkbox" lay-filter="switch" name="isPub" id="isPub" lay-skin="switch" lay-text="开启|关闭">
|
<input type="checkbox" lay-filter="switch" name="isPub" id="isPub" lay-skin="switch" lay-text="开启|关闭" checked="checked">
|
||||||
</div>
|
</div>
|
||||||
<label for="isDel" class="layui-form-label">是否删除</label>
|
<label for="isDel" class="layui-form-label">是否删除</label>
|
||||||
<div class="layui-input-inline layui-inline-2">
|
<div class="layui-input-inline layui-inline-2">
|
||||||
|
|||||||
@@ -37,7 +37,7 @@
|
|||||||
<div class="layui-form-item">
|
<div class="layui-form-item">
|
||||||
<label for="coverImage" class="layui-form-label">封面图</label>
|
<label for="coverImage" class="layui-form-label">封面图</label>
|
||||||
<div class="layui-input-inline layui-inline-10">
|
<div class="layui-input-inline layui-inline-10">
|
||||||
<input name="coverImage" id="coverImage" lay-verType="tips" lay-verify="required" class="layui-input" value="{{d.data.model.coverImage || '' }}" placeholder="请上传封面图" lay-reqText="请上传封面图" />
|
<input name="coverImage" id="coverImage" lay-verType="tips" class="layui-input" value="{{d.data.model.coverImage || '' }}" placeholder="请上传封面图" lay-reqText="请上传封面图" />
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="layui-input-inline">
|
<div class="layui-input-inline">
|
||||||
@@ -115,7 +115,7 @@
|
|||||||
}
|
}
|
||||||
});
|
});
|
||||||
editor.setData(d.data.model.contentBody);
|
editor.setData(d.data.model.contentBody);
|
||||||
|
|
||||||
//封面图图片上传
|
//封面图图片上传
|
||||||
$('#upBtncoverImage').click(function () {
|
$('#upBtncoverImage').click(function () {
|
||||||
cropperImg.cropImg({
|
cropperImg.cropImg({
|
||||||
|
|||||||
@@ -114,12 +114,12 @@ namespace CoreCms.Net.Web.WebApi.Controllers
|
|||||||
var where = PredicateBuilder.True<CoreCmsArticle>();
|
var where = PredicateBuilder.True<CoreCmsArticle>();
|
||||||
if (entity.id > 0)
|
if (entity.id > 0)
|
||||||
{
|
{
|
||||||
where = where.And(p => p.isDel == false && p.typeId == entity.id);
|
where = where.And(p => p.isDel == false && p.typeId == entity.id && p.isPub == true);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
var typeId = articleType.FirstOrDefault()!.id;
|
var typeId = articleType.FirstOrDefault()!.id;
|
||||||
where = where.And(p => p.isDel == false && p.typeId == typeId);
|
where = where.And(p => p.isDel == false && p.typeId == typeId && p.isPub == true);
|
||||||
}
|
}
|
||||||
var list = await _articleServices.QueryPageAsync(where, p => p.createTime, OrderByType.Desc, entity.page, entity.limit);
|
var list = await _articleServices.QueryPageAsync(where, p => p.createTime, OrderByType.Desc, entity.page, entity.limit);
|
||||||
jm.data = new
|
jm.data = new
|
||||||
@@ -168,7 +168,7 @@ namespace CoreCms.Net.Web.WebApi.Controllers
|
|||||||
jm.data = model;
|
jm.data = model;
|
||||||
return jm;
|
return jm;
|
||||||
|
|
||||||
}
|
}
|
||||||
#endregion
|
#endregion
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user