Compare commits

..

No commits in common. "fb4894b1da7468aeb56b346faad497a155825418" and "505341635d2cca46ad217e18d809c18a72f04860" have entirely different histories.

31 changed files with 113 additions and 422 deletions

View File

@ -34,17 +34,6 @@ public class PlayletUserAppController {
} }
} }
@ResponseBody
@PostMapping(value = "/onlyLoginByOpenid")
@ApiOperation(value = "单纯通过openid登录系统", httpMethod = "POST")
public Result<PlayletUser> onlyLoginByOpenid(@RequestParam(value = "openid") String openid){
try {
return Result.success(playletUserAppService.onlyLoginByOpenid(openid));
}catch (Exception e){
return Result.error(e.getMessage());
}
}
@ResponseBody @ResponseBody
@PostMapping(value = "/loginByPhone") @PostMapping(value = "/loginByPhone")
@ApiOperation(value = "小程序通过手机验证码登录系统", httpMethod = "POST") @ApiOperation(value = "小程序通过手机验证码登录系统", httpMethod = "POST")
@ -67,17 +56,6 @@ public class PlayletUserAppController {
} }
} }
@ResponseBody
@PostMapping(value = "/addPlayletUser")
@ApiOperation(value = "新增短剧用户", httpMethod = "POST")
public Result<PlayletUser> addPlayletUser(@RequestBody PlayletUser playletUser){
try {
return Result.success(playletUserAppService.addPlayletUser(playletUser));
}catch (Exception e){
return Result.error(e.getMessage());
}
}
@ResponseBody @ResponseBody
@PostMapping(value = "/updatePlayletUser") @PostMapping(value = "/updatePlayletUser")
@ApiOperation(value = "修改用户资料", httpMethod = "POST") @ApiOperation(value = "修改用户资料", httpMethod = "POST")

View File

@ -1,9 +1,6 @@
package com.playlet.web.controller.system; package com.playlet.web.controller.system;
import java.util.List; import java.util.List;
import com.playlet.system.domain.PlayletUser;
import com.playlet.system.service.IPlayletUserService;
import org.apache.shiro.authz.annotation.RequiresPermissions; import org.apache.shiro.authz.annotation.RequiresPermissions;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller; import org.springframework.stereotype.Controller;
@ -37,9 +34,6 @@ public class PlayletAdviceFeedbackController extends BaseController
@Autowired @Autowired
private IPlayletAdviceFeedbackService playletAdviceFeedbackService; private IPlayletAdviceFeedbackService playletAdviceFeedbackService;
@Autowired
private IPlayletUserService iPlayletUserService;
@RequiresPermissions("playlet:feedback:view") @RequiresPermissions("playlet:feedback:view")
@GetMapping() @GetMapping()
public String feedback() public String feedback()
@ -57,15 +51,6 @@ public class PlayletAdviceFeedbackController extends BaseController
{ {
startPage(); startPage();
List<PlayletAdviceFeedback> list = playletAdviceFeedbackService.selectPlayletAdviceFeedbackList(playletAdviceFeedback); List<PlayletAdviceFeedback> list = playletAdviceFeedbackService.selectPlayletAdviceFeedbackList(playletAdviceFeedback);
list.forEach(model->{
if(model.getUserId() != null){
PlayletUser user = iPlayletUserService.getById(model.getUserId());
if(user != null){
model.setUserName(user.getNickName());
model.setUserPhone(user.getPhone());
}
}
});
return getDataTable(list); return getDataTable(list);
} }

View File

@ -26,7 +26,7 @@ import com.playlet.common.core.page.TableDataInfo;
* @date 2024-03-18 * @date 2024-03-18
*/ */
@Controller @Controller
@RequestMapping("/system/playlet/type") @RequestMapping("/system/playletType")
public class PlayletItemTypeController extends BaseController { public class PlayletItemTypeController extends BaseController {
private String prefix = "system/playlet/type"; private String prefix = "system/playlet/type";

View File

@ -26,7 +26,7 @@ import com.playlet.common.core.page.TableDataInfo;
* @date 2024-03-10 * @date 2024-03-10
*/ */
@Controller @Controller
@RequestMapping("/system/playlet/message") @RequestMapping("/system/playletMessage")
public class PlayletMessageController extends BaseController public class PlayletMessageController extends BaseController
{ {
private String prefix = "system/playlet/message"; private String prefix = "system/playlet/message";

View File

@ -122,6 +122,6 @@ public class PlayletUserController extends BaseController
@ResponseBody @ResponseBody
public AjaxResult remove(String ids) public AjaxResult remove(String ids)
{ {
return toAjax(playletUserService.deletePlayletUserByIds(ids)); return toAjax(playletUserService.deletePlayletUserByIDs(ids));
} }
} }

View File

@ -8,10 +8,6 @@ import lombok.RequiredArgsConstructor;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*; import org.springframework.web.bind.annotation.*;
import org.springframework.web.multipart.MultipartFile; import org.springframework.web.multipart.MultipartFile;
import org.springframework.web.multipart.MultipartHttpServletRequest;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
/** /**
* <p>文件上传</p> * <p>文件上传</p>
@ -36,19 +32,4 @@ public class OssFileController {
} }
} }
@PostMapping(value = "/uploadFromPlaylet")
@ResponseBody
public Result<String> uploadFile(MultipartFile file) {
try {
// String name = request.getParameter("name");
// 转型为MultipartHttpRequest
// MultipartHttpServletRequest multipartRequest = (MultipartHttpServletRequest) request;
// 获得实际
// MultipartFile file= multipartRequest.getFile(name);
// 上传后返回的文件路径
return Result.success(ossService.upload(file));
} catch (Exception e) {
return Result.error(e.getMessage());
}
}
} }

View File

@ -44,8 +44,4 @@ public interface PlayletUserAppService {
*/ */
PageInfo<PlayletUser> getPlayletUserPage(PlayletUser playletUser, Integer pageNum, Integer pageSize); PageInfo<PlayletUser> getPlayletUserPage(PlayletUser playletUser, Integer pageNum, Integer pageSize);
PlayletUser onlyLoginByOpenid(String openid);
PlayletUser addPlayletUser(PlayletUser playletUser) throws Exception;
} }

View File

@ -28,24 +28,6 @@ public class PlayletUserAppServiceImpl implements PlayletUserAppService {
private final StringRedisTemplate stringRedisTemplate; private final StringRedisTemplate stringRedisTemplate;
@Override
public PlayletUser addPlayletUser(PlayletUser playletUser) throws Exception{
String alreadyCode = stringRedisTemplate.opsForValue().get(RedisConstants.SMS_CODE_PREFIX + playletUser.getPhone());
if(StringUtils.isEmpty(alreadyCode)){
throw new Exception("验证码已过期!");
}
if(!alreadyCode.equals(playletUser.getCode())){
throw new Exception("短信验证码错误!");
}
playletUser.setCreateBy(PlayletConstants.DEFAULT_CREATE);
playletUser.setCreateTime(new Date());
iPlayletUserService.save(playletUser);
playletUser.setCode("PLAYLET_" + playletUser.getId());
iPlayletUserService.updateById(playletUser);
return playletUser;
}
@Override @Override
public PlayletUser getByOpenId(String openid, String parentId) { public PlayletUser getByOpenId(String openid, String parentId) {
PlayletUser playletUser = iPlayletUserService.lambdaQuery().eq(PlayletUser::getOpenId, openid).one(); PlayletUser playletUser = iPlayletUserService.lambdaQuery().eq(PlayletUser::getOpenId, openid).one();
@ -64,11 +46,6 @@ public class PlayletUserAppServiceImpl implements PlayletUserAppService {
return playletUser; return playletUser;
} }
@Override
public PlayletUser onlyLoginByOpenid(String openid) {
return iPlayletUserService.lambdaQuery().eq(PlayletUser::getOpenId, openid).one();
}
@Override @Override
public PlayletUser getByPhone(PlayUserReq playUserReq) throws Exception{ public PlayletUser getByPhone(PlayUserReq playUserReq) throws Exception{
String alreadyCode = stringRedisTemplate.opsForValue().get(RedisConstants.SMS_CODE_PREFIX + playUserReq.getPhone()); String alreadyCode = stringRedisTemplate.opsForValue().get(RedisConstants.SMS_CODE_PREFIX + playUserReq.getPhone());

View File

@ -4,7 +4,7 @@
<meta charset="utf-8"> <meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0"> <meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0">
<title>追风者</title> <title>追风者</title>
<meta name="description" content="登录种草达人系统"> <meta name="description" content="登录麻雀短剧系统">
<link href="../static/css/bootstrap.min.css" th:href="@{/css/bootstrap.min.css}" rel="stylesheet"/> <link href="../static/css/bootstrap.min.css" th:href="@{/css/bootstrap.min.css}" rel="stylesheet"/>
<link href="../static/css/font-awesome.min.css" th:href="@{/css/font-awesome.min.css}" rel="stylesheet"/> <link href="../static/css/font-awesome.min.css" th:href="@{/css/font-awesome.min.css}" rel="stylesheet"/>
<link href="../static/css/style.min.css" th:href="@{/css/style.min.css}" rel="stylesheet"/> <link href="../static/css/style.min.css" th:href="@{/css/style.min.css}" rel="stylesheet"/>
@ -29,7 +29,7 @@
<!-- <h1><img alt="[ 若依 ]" src="../static/ruoyi.png" th:src="@{/ruoyi.png}"></h1>--> <!-- <h1><img alt="[ 若依 ]" src="../static/ruoyi.png" th:src="@{/ruoyi.png}"></h1>-->
<!-- </div>--> <!-- </div>-->
<div class="m-b"></div> <div class="m-b"></div>
<h4>欢迎使用 <strong>种草达人 后台管理系统</strong></h4> <h4>欢迎使用 <strong>麻雀短剧 后台管理系统</strong></h4>
<ul class="m-b"> <ul class="m-b">
<li><i class="fa fa-arrow-circle-o-right m-r-xs"></i> SpringBoot</li> <li><i class="fa fa-arrow-circle-o-right m-r-xs"></i> SpringBoot</li>
<li><i class="fa fa-arrow-circle-o-right m-r-xs"></i> Mybatis-plus</li> <li><i class="fa fa-arrow-circle-o-right m-r-xs"></i> Mybatis-plus</li>

View File

@ -2,7 +2,6 @@
<html lang="zh" xmlns:th="http://www.thymeleaf.org" > <html lang="zh" xmlns:th="http://www.thymeleaf.org" >
<head> <head>
<th:block th:include="include :: header('新增短剧广告管理')" /> <th:block th:include="include :: header('新增短剧广告管理')" />
<th:block th:include="include :: bootstrap-fileinput-css"/>
</head> </head>
<body class="white-bg"> <body class="white-bg">
<div class="wrapper wrapper-content animated fadeInRight ibox-content"> <div class="wrapper wrapper-content animated fadeInRight ibox-content">
@ -14,25 +13,19 @@
</div> </div>
</div> </div>
<div class="form-group"> <div class="form-group">
<label class="col-sm-3 control-label">广告:</label> <label class="col-sm-3 control-label">广告url</label>
<div class="col-sm-8"> <div class="col-sm-8">
<input name="url" type="text" hidden> <input name="url" class="form-control" type="text">
<div class="file-loading">
<input id="urlFile" name="file" type="file">
</div>
</div> </div>
</div> </div>
<div class="form-group"> <div class="form-group">
<label class="col-sm-3 control-label">详情页:</label> <label class="col-sm-3 control-label">详情页url</label>
<div class="col-sm-8"> <div class="col-sm-8">
<input name="detailUrl" type="text" hidden> <input name="detailUrl" class="form-control" type="text">
<div class="file-loading">
<input id="detailFile" name="file" type="file">
</div>
</div> </div>
</div> </div>
<div class="form-group"> <div class="form-group">
<label class="col-sm-3 control-label">序:</label> <label class="col-sm-3 control-label">号,1.2.3.4</label>
<div class="col-sm-8"> <div class="col-sm-8">
<input name="seq" class="form-control" type="text"> <input name="seq" class="form-control" type="text">
</div> </div>
@ -46,7 +39,6 @@
</form> </form>
</div> </div>
<th:block th:include="include :: footer" /> <th:block th:include="include :: footer" />
<th:block th:include="include :: bootstrap-fileinput-js"/>
<script th:inline="javascript"> <script th:inline="javascript">
var prefix = ctx + "system/playlet/banner" var prefix = ctx + "system/playlet/banner"
$("#form-banner-add").validate({ $("#form-banner-add").validate({
@ -58,44 +50,6 @@
$.operate.save(prefix + "/add", $('#form-banner-add').serialize()); $.operate.save(prefix + "/add", $('#form-banner-add').serialize());
} }
} }
// 详情页
// 单图上传
$("#urlFile").fileinput({
uploadUrl: ctx + 'tool/oss/uploadFromPlaylet',
maxFileCount: 1,
dropZoneEnabled: false, //是否显示拖拽区域
showPreview: false,
autoReplace: true
}).on('fileuploaded', function (event, data, previewId, index) {
console.log(data);
if(data.response.success){
$("input[name='url']").val(data.response.msg)
}else {
alert("上传失败!");
}
}).on('fileremoved', function (event, id, index) {
$("input[name='" + event.currentTarget.id + "']").val('')
$("input[name='url']").val('')
})
// 详情页
$("#detailFile").fileinput({
uploadUrl: ctx + 'tool/oss/uploadFromPlaylet',
maxFileCount: 1,
dropZoneEnabled: false, //是否显示拖拽区域
showPreview: false,
autoReplace: true
}).on('fileuploaded', function (event, data, previewId, index) {
if(data.response.success){
$("input[name='detailUrl']").val(data.response.msg)
}else {
alert("上传失败!");
}
}).on('fileremoved', function (event, id, index) {
$("input[name='" + event.currentTarget.id + "']").val('')
$("input[name='detailUrl']").val('')
})
</script> </script>
</body> </body>
</html> </html>

View File

@ -27,9 +27,9 @@
<a class="btn btn-success" onclick="$.operate.add()" shiro:hasPermission="system:banner:add"> <a class="btn btn-success" onclick="$.operate.add()" shiro:hasPermission="system:banner:add">
<i class="fa fa-plus"></i> 添加 <i class="fa fa-plus"></i> 添加
</a> </a>
<!-- <a class="btn btn-primary single disabled" onclick="$.operate.edit()" shiro:hasPermission="system:banner:edit">--> <a class="btn btn-primary single disabled" onclick="$.operate.edit()" shiro:hasPermission="system:banner:edit">
<!-- <i class="fa fa-edit"></i> 修改--> <i class="fa fa-edit"></i> 修改
<!-- </a>--> </a>
<a class="btn btn-danger multiple disabled" onclick="$.operate.removeAll()" shiro:hasPermission="system:banner:remove"> <a class="btn btn-danger multiple disabled" onclick="$.operate.removeAll()" shiro:hasPermission="system:banner:remove">
<i class="fa fa-remove"></i> 删除 <i class="fa fa-remove"></i> 删除
</a> </a>
@ -70,19 +70,11 @@
}, },
{ {
field: 'url', field: 'url',
title: '广告封面', title: '广告封面'
formatter: function(value) {
if (value != null && value !== ''){return '<a target="_blank" href="' + value+ '" download="false">封面图片<a/>';}
else {return '<a><a/>'}
}
}, },
{ {
field: 'detailUrl', field: 'detailUrl',
title: '详情页', title: '详情页'
formatter: function(value) {
if (value != null && value !== ''){return '<a target="_blank" href="' + value+ '" download="false">详情图片<a/>';}
else {return '<a><a/>'}
}
}, },
{ {
field: 'seq', field: 'seq',
@ -113,7 +105,7 @@
align: 'center', align: 'center',
formatter: function(value, row, index) { formatter: function(value, row, index) {
var actions = []; var actions = [];
// actions.push('<a class="btn btn-success btn-xs ' + editFlag + '" href="javascript:void(0)" onclick="$.operate.edit(\'' + row.id + '\')"><i class="fa fa-edit"></i>编辑</a> '); actions.push('<a class="btn btn-success btn-xs ' + editFlag + '" href="javascript:void(0)" onclick="$.operate.edit(\'' + row.id + '\')"><i class="fa fa-edit"></i>编辑</a> ');
actions.push('<a class="btn btn-danger btn-xs ' + removeFlag + '" href="javascript:void(0)" onclick="$.operate.remove(\'' + row.id + '\')"><i class="fa fa-remove"></i>删除</a>'); actions.push('<a class="btn btn-danger btn-xs ' + removeFlag + '" href="javascript:void(0)" onclick="$.operate.remove(\'' + row.id + '\')"><i class="fa fa-remove"></i>删除</a>');
return actions.join(''); return actions.join('');
} }

View File

@ -69,7 +69,6 @@
$(function() { $(function() {
$('.summernote').summernote({ $('.summernote').summernote({
lang: 'zh-CN', lang: 'zh-CN',
height: 300,
dialogsInBody: true, dialogsInBody: true,
callbacks: { callbacks: {
onChange: function(contents, $edittable) { onChange: function(contents, $edittable) {

View File

@ -51,7 +51,6 @@
$(function() { $(function() {
$('.summernote').summernote({ $('.summernote').summernote({
lang: 'zh-CN', lang: 'zh-CN',
height: 300,
dialogsInBody: true, dialogsInBody: true,
callbacks: { callbacks: {
onChange: function(contents, $edittable) { onChange: function(contents, $edittable) {

View File

@ -67,16 +67,7 @@
}, },
{ {
field: 'userId', field: 'userId',
title: '反馈用户id', title: '反馈用户id'
visible: false
},
{
field: 'userName',
title: '反馈人名称'
},
{
field: 'userPhone',
title: '反馈人电话'
}, },
{ {
field: 'type', field: 'type',

View File

@ -39,7 +39,6 @@
$(function() { $(function() {
$('.summernote').summernote({ $('.summernote').summernote({
lang: 'zh-CN', lang: 'zh-CN',
height: 300,
dialogsInBody: true, dialogsInBody: true,
callbacks: { callbacks: {
onChange: function(contents, $edittable) { onChange: function(contents, $edittable) {

View File

@ -7,6 +7,12 @@
<body class="white-bg"> <body class="white-bg">
<div class="wrapper wrapper-content animated fadeInRight ibox-content"> <div class="wrapper wrapper-content animated fadeInRight ibox-content">
<form class="form-horizontal m" id="form-item-add"> <form class="form-horizontal m" id="form-item-add">
<div class="form-group">
<label class="col-sm-3 control-label">备注信息:</label>
<div class="col-sm-8">
<input name="remark" class="form-control" type="text">
</div>
</div>
<div class="form-group"> <div class="form-group">
<label class="col-sm-3 control-label is-required">视频名称:</label> <label class="col-sm-3 control-label is-required">视频名称:</label>
<div class="col-sm-8"> <div class="col-sm-8">
@ -70,12 +76,6 @@
</div> </div>
</div> </div>
</div> </div>
<div class="form-group">
<label class="col-sm-3 control-label">备注信息:</label>
<div class="col-sm-8">
<input name="remark" class="form-control" type="text">
</div>
</div>
</form> </form>
</div> </div>
<th:block th:include="include :: footer" /> <th:block th:include="include :: footer" />

View File

@ -82,19 +82,11 @@
}, },
{ {
field: 'coverPic', field: 'coverPic',
title: '视频封面图', title: '视频封面图'
formatter: function(value) {
if (value != null && value !== ''){return '<a target="_blank" href="' + value+ '" download="false">详情图片<a/>';}
else {return '<a><a/>'}
}
}, },
{ {
field: 'connectSite', field: 'connectSite',
title: '连接地址', title: '连接地址'
formatter: function(value) {
if (value != null && value !== ''){return '<a target="_blank" href="' + value+ '" download="false">详情图片<a/>';}
else {return '<a><a/>'}
}
}, },
{ {
field: 'releaseDate', field: 'releaseDate',

View File

@ -2,7 +2,6 @@
<html lang="zh" xmlns:th="http://www.thymeleaf.org" > <html lang="zh" xmlns:th="http://www.thymeleaf.org" >
<head> <head>
<th:block th:include="include :: header('新增短剧公告')" /> <th:block th:include="include :: header('新增短剧公告')" />
<th:block th:include="include :: summernote-css" />
</head> </head>
<body class="white-bg"> <body class="white-bg">
<div class="wrapper wrapper-content animated fadeInRight ibox-content"> <div class="wrapper wrapper-content animated fadeInRight ibox-content">
@ -19,19 +18,10 @@
<input name="title" class="form-control" type="text"> <input name="title" class="form-control" type="text">
</div> </div>
</div> </div>
<div class="form-group">
<label class="col-sm-3 control-label">消息类型:</label>
<div class="col-sm-8">
<select name="type" class="form-control m-b" th:with="type=${@dict.getType('sys_message_type')}">
<option th:each="dict : ${type}" th:text="${dict.dictLabel}" th:value="${dict.dictValue}"></option>
</select>
</div>
</div>
<div class="form-group"> <div class="form-group">
<label class="col-sm-3 control-label">公告详情:</label> <label class="col-sm-3 control-label">公告详情:</label>
<div class="col-sm-8"> <div class="col-sm-8">
<input type="hidden" class="form-control" name="content"> <input name="detail" class="form-control" type="text">
<div class="summernote" id="detail"></div>
</div> </div>
</div> </div>
<div class="form-group"> <div class="form-group">
@ -43,7 +33,6 @@
</form> </form>
</div> </div>
<th:block th:include="include :: footer" /> <th:block th:include="include :: footer" />
<th:block th:include="include :: summernote-js" />
<script th:inline="javascript"> <script th:inline="javascript">
var prefix = ctx + "system/playlet/message" var prefix = ctx + "system/playlet/message"
$("#form-message-add").validate({ $("#form-message-add").validate({
@ -55,44 +44,6 @@
$.operate.save(prefix + "/add", $('#form-message-add').serialize()); $.operate.save(prefix + "/add", $('#form-message-add').serialize());
} }
} }
$(function() {
$('.summernote').summernote({
lang: 'zh-CN',
dialogsInBody: true,
height : 300,
callbacks: {
onChange: function(contents, $edittable) {
$("input[name='" + this.id + "']").val(contents);
},
onImageUpload: function(files) {
var obj = this;
var data = new FormData();
data.append("file", files[0]);
$.ajax({
type: "post",
url: ctx + "common/upload",
data: data,
cache: false,
contentType: false,
processData: false,
dataType: 'json',
success: function(result) {
if (result.code == web_status.SUCCESS) {
$('#' + obj.id).summernote('insertImage', result.url);
} else {
$.modal.alertError(result.msg);
}
},
error: function(error) {
$.modal.alertWarning("图片上传失败。");
}
});
}
}
});
});
</script> </script>
</body> </body>
</html> </html>

View File

@ -1,7 +1,6 @@
<!DOCTYPE html> <!DOCTYPE html>
<html lang="zh" xmlns:th="http://www.thymeleaf.org" > <html lang="zh" xmlns:th="http://www.thymeleaf.org" >
<head> <head>
<th:block th:include="include :: summernote-css" />
<th:block th:include="include :: header('修改短剧公告')" /> <th:block th:include="include :: header('修改短剧公告')" />
</head> </head>
<body class="white-bg"> <body class="white-bg">
@ -20,19 +19,10 @@
<input name="title" th:field="*{title}" class="form-control" type="text"> <input name="title" th:field="*{title}" class="form-control" type="text">
</div> </div>
</div> </div>
<div class="form-group">
<label class="col-sm-3 control-label">消息类型:</label>
<div class="col-sm-8">
<select name="type" class="form-control m-b" th:with="type=${@dict.getType('sys_message_type')}">
<option th:each="dict : ${type}" th:text="${dict.dictLabel}" th:value="${dict.dictValue}" th:field="*{type}"></option>
</select>
</div>
</div>
<div class="form-group"> <div class="form-group">
<label class="col-sm-3 control-label">公告详情:</label> <label class="col-sm-3 control-label">公告详情:</label>
<div class="col-sm-8"> <div class="col-sm-8">
<input type="hidden" class="form-control" th:field="*{detail}"> <input name="detail" th:field="*{detail}" class="form-control" type="text">
<div class="summernote" id="detail"></div>
</div> </div>
</div> </div>
<div class="form-group"> <div class="form-group">
@ -44,7 +34,6 @@
</form> </form>
</div> </div>
<th:block th:include="include :: footer" /> <th:block th:include="include :: footer" />
<th:block th:include="include :: summernote-js" />
<script th:inline="javascript"> <script th:inline="javascript">
var prefix = ctx + "system/playlet/message"; var prefix = ctx + "system/playlet/message";
$("#form-message-edit").validate({ $("#form-message-edit").validate({
@ -56,46 +45,6 @@
$.operate.save(prefix + "/edit", $('#form-message-edit').serialize()); $.operate.save(prefix + "/edit", $('#form-message-edit').serialize());
} }
} }
$(function() {
$('.summernote').each(function(i) {
$('#' + this.id).summernote({
lang: 'zh-CN',
dialogsInBody: true,
callbacks: {
onChange: function(contents, $edittable) {
$("input[name='" + this.id + "']").val(contents);
},
onImageUpload: function(files) {
var obj = this;
var data = new FormData();
data.append("file", files[0]);
$.ajax({
type: "post",
url: ctx + "common/upload",
data: data,
cache: false,
contentType: false,
processData: false,
dataType: 'json',
success: function(result) {
if (result.code == web_status.SUCCESS) {
$('#' + obj.id).summernote('insertImage', result.url);
} else {
$.modal.alertError(result.msg);
}
},
error: function(error) {
$.modal.alertWarning("图片上传失败。");
}
});
}
}
});
var content = $("input[name='" + this.id + "']").val();
$('#' + this.id).summernote('code', content);
})
});
</script> </script>
</body> </body>
</html> </html>

View File

@ -50,7 +50,6 @@
<script th:inline="javascript"> <script th:inline="javascript">
var editFlag = [[${@permission.hasPermi('system:message:edit')}]]; var editFlag = [[${@permission.hasPermi('system:message:edit')}]];
var removeFlag = [[${@permission.hasPermi('system:message:remove')}]]; var removeFlag = [[${@permission.hasPermi('system:message:remove')}]];
var typeDict = [[${@dict.getType('sys_message_type')}]];
var prefix = ctx + "system/playlet/message"; var prefix = ctx + "system/playlet/message";
$(function() { $(function() {
@ -83,11 +82,7 @@
}, },
{ {
field: 'type', field: 'type',
title: '弹出显示', title: '弹出显示'
align: 'center',
formatter: function(value, row, index) {
return $.table.selectDictLabel(typeDict, value);
}
}, },
{ {
field: 'createBy', field: 'createBy',

View File

@ -63,7 +63,6 @@
$(function() { $(function() {
$('.summernote').summernote({ $('.summernote').summernote({
lang: 'zh-CN', lang: 'zh-CN',
height : 300,
dialogsInBody: true, dialogsInBody: true,
callbacks: { callbacks: {
onChange: function(contents, $edittable) { onChange: function(contents, $edittable) {

View File

@ -114,8 +114,7 @@
}, },
{ {
field: 'detailContent', field: 'detailContent',
title: '富文本详情', title: '富文本详情'
visible: false
}, },
{ {
field: 'relativeUrl', field: 'relativeUrl',

View File

@ -2,7 +2,6 @@
<html lang="zh" xmlns:th="http://www.thymeleaf.org" > <html lang="zh" xmlns:th="http://www.thymeleaf.org" >
<head> <head>
<th:block th:include="include :: header('新增短剧客服管理')" /> <th:block th:include="include :: header('新增短剧客服管理')" />
<th:block th:include="include :: bootstrap-fileinput-css"/>
</head> </head>
<body class="white-bg"> <body class="white-bg">
<div class="wrapper wrapper-content animated fadeInRight ibox-content"> <div class="wrapper wrapper-content animated fadeInRight ibox-content">
@ -14,12 +13,9 @@
</div> </div>
</div> </div>
<div class="form-group"> <div class="form-group">
<label class="col-sm-3 control-label">客服二维码</label> <label class="col-sm-3 control-label">添加图片地址</label>
<div class="col-sm-8"> <div class="col-sm-8">
<input name="url" type="text" hidden> <input name="url" class="form-control" type="text">
<div class="file-loading">
<input id="urlFile" name="file" type="file">
</div>
</div> </div>
</div> </div>
<div class="form-group"> <div class="form-group">
@ -31,7 +27,6 @@
</form> </form>
</div> </div>
<th:block th:include="include :: footer" /> <th:block th:include="include :: footer" />
<th:block th:include="include :: bootstrap-fileinput-js"/>
<script th:inline="javascript"> <script th:inline="javascript">
var prefix = ctx + "system/playlet/service" var prefix = ctx + "system/playlet/service"
$("#form-service-add").validate({ $("#form-service-add").validate({
@ -43,25 +38,6 @@
$.operate.save(prefix + "/add", $('#form-service-add').serialize()); $.operate.save(prefix + "/add", $('#form-service-add').serialize());
} }
} }
// 详情页
$("#urlFile").fileinput({
uploadUrl: ctx + 'tool/oss/uploadFromPlaylet',
maxFileCount: 1,
dropZoneEnabled: false, //是否显示拖拽区域
showPreview: false,
autoReplace: true
}).on('fileuploaded', function (event, data, previewId, index) {
console.log(data);
if(data.response.success){
$("input[name='url']").val(data.response.msg)
}else {
alert("上传失败!");
}
}).on('fileremoved', function (event, id, index) {
$("input[name='" + event.currentTarget.id + "']").val('')
$("input[name='url']").val('')
})
</script> </script>
</body> </body>
</html> </html>

View File

@ -27,9 +27,9 @@
<a class="btn btn-success" onclick="$.operate.add()" shiro:hasPermission="playlet:service:add"> <a class="btn btn-success" onclick="$.operate.add()" shiro:hasPermission="playlet:service:add">
<i class="fa fa-plus"></i> 添加 <i class="fa fa-plus"></i> 添加
</a> </a>
<!-- <a class="btn btn-primary single disabled" onclick="$.operate.edit()" shiro:hasPermission="playlet:service:edit">--> <a class="btn btn-primary single disabled" onclick="$.operate.edit()" shiro:hasPermission="playlet:service:edit">
<!-- <i class="fa fa-edit"></i> 修改--> <i class="fa fa-edit"></i> 修改
<!-- </a>--> </a>
<a class="btn btn-danger multiple disabled" onclick="$.operate.removeAll()" shiro:hasPermission="playlet:service:remove"> <a class="btn btn-danger multiple disabled" onclick="$.operate.removeAll()" shiro:hasPermission="playlet:service:remove">
<i class="fa fa-remove"></i> 删除 <i class="fa fa-remove"></i> 删除
</a> </a>
@ -101,7 +101,7 @@
align: 'center', align: 'center',
formatter: function(value, row, index) { formatter: function(value, row, index) {
var actions = []; var actions = [];
// actions.push('<a class="btn btn-success btn-xs ' + editFlag + '" href="javascript:void(0)" onclick="$.operate.edit(\'' + row.id + '\')"><i class="fa fa-edit"></i>编辑</a> '); actions.push('<a class="btn btn-success btn-xs ' + editFlag + '" href="javascript:void(0)" onclick="$.operate.edit(\'' + row.id + '\')"><i class="fa fa-edit"></i>编辑</a> ');
actions.push('<a class="btn btn-danger btn-xs ' + removeFlag + '" href="javascript:void(0)" onclick="$.operate.remove(\'' + row.id + '\')"><i class="fa fa-remove"></i>删除</a>'); actions.push('<a class="btn btn-danger btn-xs ' + removeFlag + '" href="javascript:void(0)" onclick="$.operate.remove(\'' + row.id + '\')"><i class="fa fa-remove"></i>删除</a>');
return actions.join(''); return actions.join('');
} }

View File

@ -51,7 +51,6 @@
var editFlag = [[${@permission.hasPermi('system:user:edit')}]]; var editFlag = [[${@permission.hasPermi('system:user:edit')}]];
var removeFlag = [[${@permission.hasPermi('system:user:remove')}]]; var removeFlag = [[${@permission.hasPermi('system:user:remove')}]];
var prefix = ctx + "system/playlet/user"; var prefix = ctx + "system/playlet/user";
var statusDict = [[${@dict.getType('playlet_status')}]];
$(function() { $(function() {
var options = { var options = {
@ -69,10 +68,6 @@
title: '主键', title: '主键',
visible: false visible: false
}, },
{
field: 'code',
title: '编码'
},
{ {
field: 'phone', field: 'phone',
title: '手机号' title: '手机号'
@ -97,14 +92,6 @@
field: 'parentId', field: 'parentId',
title: '父级代理' title: '父级代理'
}, },
{
field: 'status',
title: '短剧状态',
align: 'center',
formatter: function(value, row, index) {
return $.table.selectDictLabel(statusDict, value);
}
},
{ {
field: 'createBy', field: 'createBy',
title: '创建人' title: '创建人'
@ -130,8 +117,8 @@
align: 'center', align: 'center',
formatter: function(value, row, index) { formatter: function(value, row, index) {
var actions = []; var actions = [];
actions.push('<a class="btn btn-success btn-xs ' + editFlag + '" href="javascript:void(0)" onclick="$.operate.edit(\'' + row.id + '\')"><i class="fa fa-edit"></i>编辑</a> '); actions.push('<a class="btn btn-success btn-xs ' + editFlag + '" href="javascript:void(0)" onclick="$.operate.edit(\'' + row.ID + '\')"><i class="fa fa-edit"></i>编辑</a> ');
actions.push('<a class="btn btn-danger btn-xs ' + removeFlag + '" href="javascript:void(0)" onclick="$.operate.remove(\'' + row.id + '\')"><i class="fa fa-remove"></i>删除</a>'); actions.push('<a class="btn btn-danger btn-xs ' + removeFlag + '" href="javascript:void(0)" onclick="$.operate.remove(\'' + row.ID + '\')"><i class="fa fa-remove"></i>删除</a>');
return actions.join(''); return actions.join('');
} }
}] }]

View File

@ -1,7 +1,6 @@
package com.playlet.system.domain; package com.playlet.system.domain;
import com.baomidou.mybatisplus.annotation.IdType; import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId; import com.baomidou.mybatisplus.annotation.TableId;
import com.playlet.common.core.domain.BaseEntity; import com.playlet.common.core.domain.BaseEntity;
import com.baomidou.mybatisplus.annotation.TableName; import com.baomidou.mybatisplus.annotation.TableName;
@ -34,12 +33,6 @@ public class PlayletAdviceFeedback extends BaseEntity
@ApiModelProperty(value = "反馈用户id") @ApiModelProperty(value = "反馈用户id")
private Long userId; private Long userId;
@TableField(exist = false)
private String userName;
@TableField(exist = false)
private String userPhone;
/** 类型 01.功能建议 02.客服投诉 03.其他 */ /** 类型 01.功能建议 02.客服投诉 03.其他 */
@Excel(name = "类型 01.功能建议 02.客服投诉 03.其他") @Excel(name = "类型 01.功能建议 02.客服投诉 03.其他")
@ApiModelProperty(value = "类型 01.功能建议 02.客服投诉 03.其他") @ApiModelProperty(value = "类型 01.功能建议 02.客服投诉 03.其他")

View File

@ -15,10 +15,10 @@ public interface PlayletUserMapper extends BaseMapper<PlayletUser>
/** /**
* 查询短剧用户 * 查询短剧用户
* *
* @param id 短剧用户主键 * @param ID 短剧用户主键
* @return 短剧用户 * @return 短剧用户
*/ */
public PlayletUser selectPlayletUserById(Long id); public PlayletUser selectPlayletUserByID(Long ID);
/** /**
* 查询短剧用户列表 * 查询短剧用户列表
@ -47,16 +47,16 @@ public interface PlayletUserMapper extends BaseMapper<PlayletUser>
/** /**
* 删除短剧用户 * 删除短剧用户
* *
* @param id 短剧用户主键 * @param ID 短剧用户主键
* @return 结果 * @return 结果
*/ */
public int deletePlayletUserById(Long id); public int deletePlayletUserByID(Long ID);
/** /**
* 批量删除短剧用户 * 批量删除短剧用户
* *
* @param Ids 需要删除的数据主键集合 * @param IDs 需要删除的数据主键集合
* @return 结果 * @return 结果
*/ */
public int deletePlayletUserByIds(String[] ids); public int deletePlayletUserByIDs(String[] IDs);
} }

View File

@ -15,10 +15,10 @@ public interface IPlayletUserService extends IService<PlayletUser>
/** /**
* 查询短剧用户 * 查询短剧用户
* *
* @param id 短剧用户主键 * @param ID 短剧用户主键
* @return 短剧用户 * @return 短剧用户
*/ */
public PlayletUser selectPlayletUserByID(Long id); public PlayletUser selectPlayletUserByID(Long ID);
/** /**
* 查询短剧用户列表 * 查询短剧用户列表
@ -47,16 +47,16 @@ public interface IPlayletUserService extends IService<PlayletUser>
/** /**
* 批量删除短剧用户 * 批量删除短剧用户
* *
* @param ids 需要删除的短剧用户主键集合 * @param IDs 需要删除的短剧用户主键集合
* @return 结果 * @return 结果
*/ */
public int deletePlayletUserByIds(String ids); public int deletePlayletUserByIDs(String IDs);
/** /**
* 删除短剧用户信息 * 删除短剧用户信息
* *
* @param id 短剧用户主键 * @param ID 短剧用户主键
* @return 结果 * @return 结果
*/ */
public int deletePlayletUserById(Long id); public int deletePlayletUserByID(Long ID);
} }

View File

@ -25,13 +25,13 @@ public class PlayletUserServiceImpl extends ServiceImpl<PlayletUserMapper, Playl
/** /**
* 查询短剧用户 * 查询短剧用户
* *
* @param id 短剧用户主键 * @param ID 短剧用户主键
* @return 短剧用户 * @return 短剧用户
*/ */
@Override @Override
public PlayletUser selectPlayletUserByID(Long id) public PlayletUser selectPlayletUserByID(Long ID)
{ {
return playletUserMapper.selectPlayletUserById(id); return playletUserMapper.selectPlayletUserByID(ID);
} }
/** /**
@ -75,24 +75,24 @@ public class PlayletUserServiceImpl extends ServiceImpl<PlayletUserMapper, Playl
/** /**
* 批量删除短剧用户 * 批量删除短剧用户
* *
* @param ids 需要删除的短剧用户主键 * @param IDs 需要删除的短剧用户主键
* @return 结果 * @return 结果
*/ */
@Override @Override
public int deletePlayletUserByIds(String ids) public int deletePlayletUserByIDs(String IDs)
{ {
return playletUserMapper.deletePlayletUserByIds(Convert.toStrArray(ids)); return playletUserMapper.deletePlayletUserByIDs(Convert.toStrArray(IDs));
} }
/** /**
* 删除短剧用户信息 * 删除短剧用户信息
* *
* @param id 短剧用户主键 * @param ID 短剧用户主键
* @return 结果 * @return 结果
*/ */
@Override @Override
public int deletePlayletUserById(Long id) public int deletePlayletUserByID(Long ID)
{ {
return playletUserMapper.deletePlayletUserById(id); return playletUserMapper.deletePlayletUserByID(ID);
} }
} }

View File

@ -34,7 +34,6 @@
<if test="updateTime != null "> and UPDATE_TIME = #{updateTime}</if> <if test="updateTime != null "> and UPDATE_TIME = #{updateTime}</if>
<if test="remark != null and remark != ''"> and REMARK = #{remark}</if> <if test="remark != null and remark != ''"> and REMARK = #{remark}</if>
</where> </where>
order by seq asc
</select> </select>
<select id="selectPlayletBannerById" parameterType="Long" resultMap="PlayletBannerResult"> <select id="selectPlayletBannerById" parameterType="Long" resultMap="PlayletBannerResult">

View File

@ -5,62 +5,62 @@
<mapper namespace="com.playlet.system.mapper.PlayletUserMapper"> <mapper namespace="com.playlet.system.mapper.PlayletUserMapper">
<resultMap type="PlayletUser" id="PlayletUserResult"> <resultMap type="PlayletUser" id="PlayletUserResult">
<result property="id" column="id" /> <result property="id" column="ID" />
<result property="code" column="code" /> <result property="code" column="code" />
<result property="phone" column="phone" /> <result property="phone" column="PHONE" />
<result property="nickName" column="nick_name" /> <result property="nickName" column="NICK_NAME" />
<result property="password" column="password" /> <result property="password" column="PASSWORD" />
<result property="icon" column="icon" /> <result property="icon" column="ICON" />
<result property="agencyId" column="agency_id" /> <result property="agencyId" column="AGENCY_ID" />
<result property="parentId" column="parent_id" /> <result property="parentId" column="PARENT_ID" />
<result property="status" column="status" /> <result property="status" column="status" />
<result property="createBy" column="create_by" /> <result property="createBy" column="CREATE_BY" />
<result property="createTime" column="create_time" /> <result property="createTime" column="CREATE_TIME" />
<result property="updateBy" column="update_by" /> <result property="updateBy" column="UPDATE_BY" />
<result property="updateTime" column="update_time" /> <result property="updateTime" column="UPDATE_TIME" />
<result property="remark" column="remark" /> <result property="remark" column="REMARK" />
</resultMap> </resultMap>
<sql id="selectPlayletUserVo"> <sql id="selectPlayletUserVo">
select id, code, phone, nick_name, password, icon, agency_id, parent_id, status, create_by, create_time, update_by, update_time, remark from playlet_user select ID, code, PHONE, NICK_NAME, PASSWORD, ICON, AGENCY_ID, PARENT_ID, status, CREATE_BY, CREATE_TIME, UPDATE_BY, UPDATE_TIME, REMARK from playlet_user
</sql> </sql>
<select id="selectPlayletUserList" parameterType="PlayletUser" resultMap="PlayletUserResult"> <select id="selectPlayletUserList" parameterType="PlayletUser" resultMap="PlayletUserResult">
<include refid="selectPlayletUserVo"/> <include refid="selectPlayletUserVo"/>
<where> <where>
<if test="phone != null and phone != ''"> and phone = #{phone}</if> <if test="phone != null and phone != ''"> and PHONE = #{phone}</if>
<if test="nickName != null and nickName != ''"> and nick_name like concat('%', #{nickName}, '%')</if> <if test="nickName != null and nickName != ''"> and NICK_NAME like concat('%', #{nickName}, '%')</if>
<if test="password != null and password != ''"> and password = #{password}</if> <if test="password != null and password != ''"> and PASSWORD = #{password}</if>
<if test="icon != null and icon != ''"> and icon = #{icon}</if> <if test="icon != null and icon != ''"> and ICON = #{icon}</if>
<if test="agencyId != null and agencyId != ''"> and agency_id = #{agencyId}</if> <if test="agencyId != null and agencyId != ''"> and AGENCY_ID = #{agencyId}</if>
<if test="parentId != null and parentId != ''"> and parent_id = #{parentId}</if> <if test="parentId != null and parentId != ''"> and PARENT_ID = #{parentId}</if>
<if test="createBy != null and createBy != ''"> and create_by = #{createBy}</if> <if test="createBy != null and createBy != ''"> and CREATE_BY = #{createBy}</if>
<if test="createTime != null "> and create_time = #{createTime}</if> <if test="createTime != null "> and CREATE_TIME = #{createTime}</if>
<if test="updateBy != null and updateBy != ''"> and update_by = #{updateBy}</if> <if test="updateBy != null and updateBy != ''"> and UPDATE_BY = #{updateBy}</if>
<if test="updateTime != null "> and update_time = #{updateTime}</if> <if test="updateTime != null "> and UPDATE_TIME = #{updateTime}</if>
<if test="remark != null and remark != ''"> and remark = #{remark}</if> <if test="remark != null and REMARK != ''"> and REMARK = #{REMARK}</if>
</where> </where>
</select> </select>
<select id="selectPlayletUserById" parameterType="Long" resultMap="PlayletUserResult"> <select id="selectPlayletUserByID" parameterType="Long" resultMap="PlayletUserResult">
<include refid="selectPlayletUserVo"/> <include refid="selectPlayletUserVo"/>
where id = #{id} where ID = #{ID}
</select> </select>
<insert id="insertPlayletUser" parameterType="PlayletUser" useGeneratedKeys="true" keyProperty="ID"> <insert id="insertPlayletUser" parameterType="PlayletUser" useGeneratedKeys="true" keyProperty="ID">
insert into playlet_user insert into playlet_user
<trim prefix="(" suffix=")" suffixOverrides=","> <trim prefix="(" suffix=")" suffixOverrides=",">
<if test="phone != null">phone,</if> <if test="phone != null">PHONE,</if>
<if test="nickName != null">nick_name,</if> <if test="nickName != null">NICK_NAME,</if>
<if test="password != null">password,</if> <if test="password != null">PASSWORD,</if>
<if test="icon != null">icon,</if> <if test="icon != null">ICON,</if>
<if test="agencyId != null">agency_id,</if> <if test="agencyId != null">AGENCY_ID,</if>
<if test="parentId != null">parent_id,</if> <if test="parentId != null">PARENT_ID,</if>
<if test="createBy != null">create_by,</if> <if test="createBy != null">CREATE_BY,</if>
<if test="createTime != null">create_time,</if> <if test="createTime != null">CREATE_TIME,</if>
<if test="updateBy != null">update_by,</if> <if test="updateBy != null">UPDATE_BY,</if>
<if test="updateTime != null">update_time,</if> <if test="updateTime != null">UPDATE_TIME,</if>
<if test="remark != null">remark,</if> <if test="remark != null">REMARK,</if>
</trim> </trim>
<trim prefix="values (" suffix=")" suffixOverrides=","> <trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="phone != null">#{phone},</if> <if test="phone != null">#{phone},</if>
@ -80,30 +80,30 @@
<update id="updatePlayletUser" parameterType="PlayletUser"> <update id="updatePlayletUser" parameterType="PlayletUser">
update playlet_user update playlet_user
<trim prefix="SET" suffixOverrides=","> <trim prefix="SET" suffixOverrides=",">
<if test="phone != null">phone = #{phone},</if> <if test="phone != null">PHONE = #{phone},</if>
<if test="nickName != null">nick_name = #{nickName},</if> <if test="nickName != null">NICK_NAME = #{nickName},</if>
<if test="password != null">password = #{password},</if> <if test="password != null">PASSWORD = #{password},</if>
<if test="icon != null">icon = #{icon},</if> <if test="icon != null">ICON = #{icon},</if>
<if test="agencyId != null">agency_id = #{agencyId},</if> <if test="agencyId != null">AGENCY_ID = #{agencyId},</if>
<if test="parentId != null">parent_id = #{parentId},</if> <if test="parentId != null">PARENT_ID = #{parentId},</if>
<if test="status != null">status = #{status},</if> <if test="status != null">status = #{status},</if>
<if test="createBy != null">create_by = #{createBy},</if> <if test="createBy != null">CREATE_BY = #{createBy},</if>
<if test="createTime != null">create_time = #{createTime},</if> <if test="createTime != null">CREATE_TIME = #{createTime},</if>
<if test="updateBy != null">update_by = #{updateBy},</if> <if test="updateBy != null">UPDATE_BY = #{updateBy},</if>
<if test="updateTime != null">update_time = #{updateTime},</if> <if test="updateTime != null">UPDATE_TIME = #{updateTime},</if>
<if test="remark != null">remark = #{remark},</if> <if test="remark != null">REMARK = #{remark},</if>
</trim> </trim>
where id = #{id} where ID = #{id}
</update> </update>
<delete id="deletePlayletUserById" parameterType="Long"> <delete id="deletePlayletUserByID" parameterType="Long">
delete from playlet_user where id = #{id} delete from playlet_user where ID = #{id}
</delete> </delete>
<delete id="deletePlayletUserByIds" parameterType="String"> <delete id="deletePlayletUserByIDs" parameterType="String">
delete from playlet_user where id in delete from playlet_user where ID in
<foreach item="id" collection="array" open="(" separator="," close=")"> <foreach item="ID" collection="array" open="(" separator="," close=")">
#{id} #{ID}
</foreach> </foreach>
</delete> </delete>