一系列接口补充
This commit is contained in:
parent
37334fc66c
commit
4b16f24db1
|
|
@ -0,0 +1,51 @@
|
||||||
|
package com.playlet.web.controller.app;
|
||||||
|
|
||||||
|
import com.github.pagehelper.PageInfo;
|
||||||
|
import com.playlet.common.core.domain.Result;
|
||||||
|
import com.playlet.system.domain.PlayletUserExpandAccount;
|
||||||
|
import com.playlet.web.service.app.PlayletExpandService;
|
||||||
|
import io.swagger.annotations.Api;
|
||||||
|
import io.swagger.annotations.ApiOperation;
|
||||||
|
import lombok.RequiredArgsConstructor;
|
||||||
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
|
import org.springframework.web.bind.annotation.*;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* <p>短剧*扩展账号管理</p>
|
||||||
|
* @author clunt
|
||||||
|
*/
|
||||||
|
@Api(tags = "短剧*扩展账号管理")
|
||||||
|
@RestController
|
||||||
|
@RequestMapping(value = "/app/expand")
|
||||||
|
@RequiredArgsConstructor(onConstructor = @__(@Autowired))
|
||||||
|
public class PlayletExpandAppController {
|
||||||
|
|
||||||
|
private final PlayletExpandService playletExpandService;
|
||||||
|
|
||||||
|
@ResponseBody
|
||||||
|
@PostMapping("/getPageList")
|
||||||
|
@ApiOperation(value = "分页查询短剧扩展账号列表")
|
||||||
|
public Result<PageInfo<PlayletUserExpandAccount>> getPageList(@RequestBody PlayletUserExpandAccount expandAccount,
|
||||||
|
@RequestParam(value = "pageNum")Integer pageNum,
|
||||||
|
@RequestParam(value = "pageSize")Integer pageSize) {
|
||||||
|
return Result.success(playletExpandService.getPageList(expandAccount, pageNum, pageSize));
|
||||||
|
}
|
||||||
|
|
||||||
|
@ResponseBody
|
||||||
|
@PostMapping("/getList")
|
||||||
|
@ApiOperation(value = "查询短剧扩展账号列表")
|
||||||
|
public Result<List<PlayletUserExpandAccount>> getList(@RequestBody PlayletUserExpandAccount expandAccount) {
|
||||||
|
return Result.success(playletExpandService.getList(expandAccount));
|
||||||
|
}
|
||||||
|
|
||||||
|
@ResponseBody
|
||||||
|
@PostMapping("/addAccount")
|
||||||
|
@ApiOperation(value = "新增扩展账号")
|
||||||
|
public Result<String> addAccount(@RequestBody PlayletUserExpandAccount expandAccount) {
|
||||||
|
playletExpandService.addAccount(expandAccount);
|
||||||
|
return Result.success();
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,29 @@
|
||||||
|
package com.playlet.web.controller.app;
|
||||||
|
|
||||||
|
import com.playlet.common.core.domain.Result;
|
||||||
|
import com.playlet.system.domain.PlayletPlatformFlow;
|
||||||
|
import com.playlet.web.service.app.PlayletFlowAppService;
|
||||||
|
import io.swagger.annotations.Api;
|
||||||
|
import io.swagger.annotations.ApiOperation;
|
||||||
|
import lombok.RequiredArgsConstructor;
|
||||||
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
|
import org.springframework.web.bind.annotation.*;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
@Api(tags = "短剧*挂载配置")
|
||||||
|
@RestController
|
||||||
|
@RequestMapping(value = "/app/flow")
|
||||||
|
@RequiredArgsConstructor(onConstructor = @__(@Autowired))
|
||||||
|
public class PlayletPlatformFlowAppController {
|
||||||
|
|
||||||
|
private final PlayletFlowAppService playletFlowAppService;
|
||||||
|
|
||||||
|
@ResponseBody
|
||||||
|
@PostMapping("/getList")
|
||||||
|
@ApiOperation(value = "查询挂载配置列表")
|
||||||
|
public Result<List<PlayletPlatformFlow>> getList(@RequestBody PlayletPlatformFlow platformFlow) {
|
||||||
|
return Result.success(playletFlowAppService.getFlowList(platformFlow));
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
@ -7,6 +7,7 @@ import com.playlet.common.core.domain.AjaxResult;
|
||||||
import com.playlet.common.core.domain.Result;
|
import com.playlet.common.core.domain.Result;
|
||||||
import com.playlet.common.enums.BusinessType;
|
import com.playlet.common.enums.BusinessType;
|
||||||
import com.playlet.system.domain.PlayletTask;
|
import com.playlet.system.domain.PlayletTask;
|
||||||
|
import com.playlet.system.domain.PlayletUserTask;
|
||||||
import com.playlet.web.service.app.PlayletTaskAppService;
|
import com.playlet.web.service.app.PlayletTaskAppService;
|
||||||
import io.swagger.annotations.Api;
|
import io.swagger.annotations.Api;
|
||||||
import io.swagger.annotations.ApiOperation;
|
import io.swagger.annotations.ApiOperation;
|
||||||
|
|
@ -66,14 +67,38 @@ public class PlayletTaskAppController extends BaseController {
|
||||||
return Result.success(playletTaskAppService.selectPlayletTaskById(taskId));
|
return Result.success(playletTaskAppService.selectPlayletTaskById(taskId));
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
@ApiOperation(value = "接受任务")
|
||||||
* 新增保存任务
|
@PostMapping("/acceptTask")
|
||||||
*/
|
|
||||||
@PostMapping("/addDesignate")
|
|
||||||
@ResponseBody
|
@ResponseBody
|
||||||
public AjaxResult addSave(@RequestBody PlayletTask playletTask) {
|
public Result<String> acceptTask(@RequestBody PlayletUserTask playletUserTask) {
|
||||||
return toAjax(playletTaskAppService.userDesignateTask(playletTask));
|
try {
|
||||||
|
playletTaskAppService.userDesignateTask(playletUserTask);
|
||||||
|
return Result.success();
|
||||||
|
}catch (Exception e){
|
||||||
|
log.error("接任务报错:{}", e.getMessage(), e);
|
||||||
|
return Result.error(e.getMessage());
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ApiOperation(value = "推广我的任务")
|
||||||
|
@PostMapping("/promotionTask")
|
||||||
|
@ResponseBody
|
||||||
|
public Result<String> promotionTask(@RequestBody PlayletUserTask playletUserTask) {
|
||||||
|
try {
|
||||||
|
return Result.success(playletTaskAppService.promotionTask(playletUserTask), "操作成功");
|
||||||
|
}catch (Exception e){
|
||||||
|
log.error("推广任务报错:{}", e.getMessage(), e);
|
||||||
|
return Result.error(e.getMessage());
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@ApiOperation(value = "分页查询我的推广")
|
||||||
|
@PostMapping("/getPromotionTaskPage")
|
||||||
|
@ResponseBody
|
||||||
|
public Result<PageInfo<PlayletUserTask>> getPromotionTaskPage(@RequestBody PlayletUserTask playletUserTask,
|
||||||
|
@RequestParam(value = "pageNum") Integer pageNum,
|
||||||
|
@RequestParam(value = "pageSize") Integer pageSize) {
|
||||||
|
return Result.success(playletTaskAppService.getPromotionTaskPage(playletUserTask, pageNum, pageSize));
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -32,7 +32,7 @@ public class PlayletUserAccountAppController {
|
||||||
*/
|
*/
|
||||||
@ResponseBody
|
@ResponseBody
|
||||||
@PostMapping("/getAccountList")
|
@PostMapping("/getAccountList")
|
||||||
@ApiOperation(value = "分页查询短剧基础列表")
|
@ApiOperation(value = "分页查询基础列表")
|
||||||
public Result<PageInfo<PlayletUserAccount>> getAccountList(@RequestBody PlayletUserAccount playletUserAccount,
|
public Result<PageInfo<PlayletUserAccount>> getAccountList(@RequestBody PlayletUserAccount playletUserAccount,
|
||||||
@RequestParam(value = "pageNum", defaultValue = "1") Integer pageNum,
|
@RequestParam(value = "pageNum", defaultValue = "1") Integer pageNum,
|
||||||
@RequestParam(value = "pageSize", defaultValue = "10") Integer pageSize) {
|
@RequestParam(value = "pageSize", defaultValue = "10") Integer pageSize) {
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,127 @@
|
||||||
|
package com.playlet.web.controller.system;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
import org.apache.shiro.authz.annotation.RequiresPermissions;
|
||||||
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
|
import org.springframework.stereotype.Controller;
|
||||||
|
import org.springframework.ui.ModelMap;
|
||||||
|
import org.springframework.web.bind.annotation.GetMapping;
|
||||||
|
import org.springframework.web.bind.annotation.PathVariable;
|
||||||
|
import org.springframework.web.bind.annotation.PostMapping;
|
||||||
|
import org.springframework.web.bind.annotation.RequestMapping;
|
||||||
|
import org.springframework.web.bind.annotation.ResponseBody;
|
||||||
|
import com.playlet.common.annotation.Log;
|
||||||
|
import com.playlet.common.enums.BusinessType;
|
||||||
|
import com.playlet.system.domain.PlayletPlatformFlow;
|
||||||
|
import com.playlet.system.service.IPlayletPlatformFlowService;
|
||||||
|
import com.playlet.common.core.controller.BaseController;
|
||||||
|
import com.playlet.common.core.domain.AjaxResult;
|
||||||
|
import com.playlet.common.utils.poi.ExcelUtil;
|
||||||
|
import com.playlet.common.core.page.TableDataInfo;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 挂载操作流程Controller
|
||||||
|
*
|
||||||
|
* @author ruoyi
|
||||||
|
* @date 2024-04-14
|
||||||
|
*/
|
||||||
|
@Controller
|
||||||
|
@RequestMapping("/system/playlet/flow")
|
||||||
|
public class PlayletPlatformFlowController extends BaseController
|
||||||
|
{
|
||||||
|
private String prefix = "system/playlet/flow";
|
||||||
|
|
||||||
|
@Autowired
|
||||||
|
private IPlayletPlatformFlowService playletPlatformFlowService;
|
||||||
|
|
||||||
|
@RequiresPermissions("playlet:flow:view")
|
||||||
|
@GetMapping()
|
||||||
|
public String flow()
|
||||||
|
{
|
||||||
|
return prefix + "/flow";
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查询挂载操作流程列表
|
||||||
|
*/
|
||||||
|
@RequiresPermissions("playlet:flow:list")
|
||||||
|
@PostMapping("/list")
|
||||||
|
@ResponseBody
|
||||||
|
public TableDataInfo list(PlayletPlatformFlow playletPlatformFlow)
|
||||||
|
{
|
||||||
|
startPage();
|
||||||
|
List<PlayletPlatformFlow> list = playletPlatformFlowService.selectPlayletPlatformFlowList(playletPlatformFlow);
|
||||||
|
return getDataTable(list);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 导出挂载操作流程列表
|
||||||
|
*/
|
||||||
|
@RequiresPermissions("playlet:flow:export")
|
||||||
|
@Log(title = "挂载操作流程", businessType = BusinessType.EXPORT)
|
||||||
|
@PostMapping("/export")
|
||||||
|
@ResponseBody
|
||||||
|
public AjaxResult export(PlayletPlatformFlow playletPlatformFlow)
|
||||||
|
{
|
||||||
|
List<PlayletPlatformFlow> list = playletPlatformFlowService.selectPlayletPlatformFlowList(playletPlatformFlow);
|
||||||
|
ExcelUtil<PlayletPlatformFlow> util = new ExcelUtil<PlayletPlatformFlow>(PlayletPlatformFlow.class);
|
||||||
|
return util.exportExcel(list, "挂载操作流程数据");
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 新增挂载操作流程
|
||||||
|
*/
|
||||||
|
@GetMapping("/add")
|
||||||
|
public String add()
|
||||||
|
{
|
||||||
|
return prefix + "/add";
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 新增保存挂载操作流程
|
||||||
|
*/
|
||||||
|
@RequiresPermissions("playlet:flow:add")
|
||||||
|
@Log(title = "挂载操作流程", businessType = BusinessType.INSERT)
|
||||||
|
@PostMapping("/add")
|
||||||
|
@ResponseBody
|
||||||
|
public AjaxResult addSave(PlayletPlatformFlow playletPlatformFlow)
|
||||||
|
{
|
||||||
|
return toAjax(playletPlatformFlowService.insertPlayletPlatformFlow(playletPlatformFlow));
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 修改挂载操作流程
|
||||||
|
*/
|
||||||
|
@RequiresPermissions("playlet:flow:edit")
|
||||||
|
@GetMapping("/edit/{id}")
|
||||||
|
public String edit(@PathVariable("id") Long id, ModelMap mmap)
|
||||||
|
{
|
||||||
|
PlayletPlatformFlow playletPlatformFlow = playletPlatformFlowService.selectPlayletPlatformFlowById(id);
|
||||||
|
mmap.put("playletPlatformFlow", playletPlatformFlow);
|
||||||
|
return prefix + "/edit";
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 修改保存挂载操作流程
|
||||||
|
*/
|
||||||
|
@RequiresPermissions("playlet:flow:edit")
|
||||||
|
@Log(title = "挂载操作流程", businessType = BusinessType.UPDATE)
|
||||||
|
@PostMapping("/edit")
|
||||||
|
@ResponseBody
|
||||||
|
public AjaxResult editSave(PlayletPlatformFlow playletPlatformFlow)
|
||||||
|
{
|
||||||
|
return toAjax(playletPlatformFlowService.updatePlayletPlatformFlow(playletPlatformFlow));
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除挂载操作流程
|
||||||
|
*/
|
||||||
|
@RequiresPermissions("playlet:flow:remove")
|
||||||
|
@Log(title = "挂载操作流程", businessType = BusinessType.DELETE)
|
||||||
|
@PostMapping( "/remove")
|
||||||
|
@ResponseBody
|
||||||
|
public AjaxResult remove(String ids)
|
||||||
|
{
|
||||||
|
return toAjax(playletPlatformFlowService.deletePlayletPlatformFlowByIds(ids));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,127 @@
|
||||||
|
package com.playlet.web.controller.system;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
import org.apache.shiro.authz.annotation.RequiresPermissions;
|
||||||
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
|
import org.springframework.stereotype.Controller;
|
||||||
|
import org.springframework.ui.ModelMap;
|
||||||
|
import org.springframework.web.bind.annotation.GetMapping;
|
||||||
|
import org.springframework.web.bind.annotation.PathVariable;
|
||||||
|
import org.springframework.web.bind.annotation.PostMapping;
|
||||||
|
import org.springframework.web.bind.annotation.RequestMapping;
|
||||||
|
import org.springframework.web.bind.annotation.ResponseBody;
|
||||||
|
import com.playlet.common.annotation.Log;
|
||||||
|
import com.playlet.common.enums.BusinessType;
|
||||||
|
import com.playlet.system.domain.PlayletUserExpandAccount;
|
||||||
|
import com.playlet.system.service.IPlayletUserExpandAccountService;
|
||||||
|
import com.playlet.common.core.controller.BaseController;
|
||||||
|
import com.playlet.common.core.domain.AjaxResult;
|
||||||
|
import com.playlet.common.utils.poi.ExcelUtil;
|
||||||
|
import com.playlet.common.core.page.TableDataInfo;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 用户外部账号Controller
|
||||||
|
*
|
||||||
|
* @author ruoyi
|
||||||
|
* @date 2024-04-14
|
||||||
|
*/
|
||||||
|
@Controller
|
||||||
|
@RequestMapping("/system/playlet/expand")
|
||||||
|
public class PlayletUserExpandAccountController extends BaseController
|
||||||
|
{
|
||||||
|
private String prefix = "system/playlet/expand";
|
||||||
|
|
||||||
|
@Autowired
|
||||||
|
private IPlayletUserExpandAccountService playletUserExpandAccountService;
|
||||||
|
|
||||||
|
@RequiresPermissions("playlet:account:view")
|
||||||
|
@GetMapping()
|
||||||
|
public String account()
|
||||||
|
{
|
||||||
|
return prefix + "/expand";
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查询用户外部账号列表
|
||||||
|
*/
|
||||||
|
@RequiresPermissions("playlet:account:list")
|
||||||
|
@PostMapping("/list")
|
||||||
|
@ResponseBody
|
||||||
|
public TableDataInfo list(PlayletUserExpandAccount playletUserExpandAccount)
|
||||||
|
{
|
||||||
|
startPage();
|
||||||
|
List<PlayletUserExpandAccount> list = playletUserExpandAccountService.selectPlayletUserExpandAccountList(playletUserExpandAccount);
|
||||||
|
return getDataTable(list);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 导出用户外部账号列表
|
||||||
|
*/
|
||||||
|
@RequiresPermissions("playlet:account:export")
|
||||||
|
@Log(title = "用户外部账号", businessType = BusinessType.EXPORT)
|
||||||
|
@PostMapping("/export")
|
||||||
|
@ResponseBody
|
||||||
|
public AjaxResult export(PlayletUserExpandAccount playletUserExpandAccount)
|
||||||
|
{
|
||||||
|
List<PlayletUserExpandAccount> list = playletUserExpandAccountService.selectPlayletUserExpandAccountList(playletUserExpandAccount);
|
||||||
|
ExcelUtil<PlayletUserExpandAccount> util = new ExcelUtil<PlayletUserExpandAccount>(PlayletUserExpandAccount.class);
|
||||||
|
return util.exportExcel(list, "用户外部账号数据");
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 新增用户外部账号
|
||||||
|
*/
|
||||||
|
@GetMapping("/add")
|
||||||
|
public String add()
|
||||||
|
{
|
||||||
|
return prefix + "/add";
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 新增保存用户外部账号
|
||||||
|
*/
|
||||||
|
@RequiresPermissions("playlet:account:add")
|
||||||
|
@Log(title = "用户外部账号", businessType = BusinessType.INSERT)
|
||||||
|
@PostMapping("/add")
|
||||||
|
@ResponseBody
|
||||||
|
public AjaxResult addSave(PlayletUserExpandAccount playletUserExpandAccount)
|
||||||
|
{
|
||||||
|
return toAjax(playletUserExpandAccountService.insertPlayletUserExpandAccount(playletUserExpandAccount));
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 修改用户外部账号
|
||||||
|
*/
|
||||||
|
@RequiresPermissions("playlet:account:edit")
|
||||||
|
@GetMapping("/edit/{id}")
|
||||||
|
public String edit(@PathVariable("id") Long id, ModelMap mmap)
|
||||||
|
{
|
||||||
|
PlayletUserExpandAccount playletUserExpandAccount = playletUserExpandAccountService.selectPlayletUserExpandAccountById(id);
|
||||||
|
mmap.put("playletUserExpandAccount", playletUserExpandAccount);
|
||||||
|
return prefix + "/edit";
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 修改保存用户外部账号
|
||||||
|
*/
|
||||||
|
@RequiresPermissions("playlet:account:edit")
|
||||||
|
@Log(title = "用户外部账号", businessType = BusinessType.UPDATE)
|
||||||
|
@PostMapping("/edit")
|
||||||
|
@ResponseBody
|
||||||
|
public AjaxResult editSave(PlayletUserExpandAccount playletUserExpandAccount)
|
||||||
|
{
|
||||||
|
return toAjax(playletUserExpandAccountService.updatePlayletUserExpandAccount(playletUserExpandAccount));
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除用户外部账号
|
||||||
|
*/
|
||||||
|
@RequiresPermissions("playlet:account:remove")
|
||||||
|
@Log(title = "用户外部账号", businessType = BusinessType.DELETE)
|
||||||
|
@PostMapping( "/remove")
|
||||||
|
@ResponseBody
|
||||||
|
public AjaxResult remove(String ids)
|
||||||
|
{
|
||||||
|
return toAjax(playletUserExpandAccountService.deletePlayletUserExpandAccountByIds(ids));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,33 @@
|
||||||
|
package com.playlet.web.service.app;
|
||||||
|
|
||||||
|
import com.github.pagehelper.PageInfo;
|
||||||
|
import com.playlet.system.domain.PlayletUserExpandAccount;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @author clunt
|
||||||
|
* <p>短剧*扩展账号管理service</p>
|
||||||
|
*/
|
||||||
|
public interface PlayletExpandService {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @param expandAccount 查询条件
|
||||||
|
* @param pageNum 页码
|
||||||
|
* @param pageSize 单页条数
|
||||||
|
* @return 分页结果
|
||||||
|
*/
|
||||||
|
PageInfo<PlayletUserExpandAccount> getPageList(PlayletUserExpandAccount expandAccount, Integer pageNum, Integer pageSize);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @param expandAccount 查询条件
|
||||||
|
* @return 返回list
|
||||||
|
*/
|
||||||
|
List<PlayletUserExpandAccount> getList(PlayletUserExpandAccount expandAccount);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @param expandAccount 新增外部账号
|
||||||
|
*/
|
||||||
|
void addAccount(PlayletUserExpandAccount expandAccount);
|
||||||
|
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,11 @@
|
||||||
|
package com.playlet.web.service.app;
|
||||||
|
|
||||||
|
import com.playlet.system.domain.PlayletPlatformFlow;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
public interface PlayletFlowAppService {
|
||||||
|
|
||||||
|
List<PlayletPlatformFlow> getFlowList(PlayletPlatformFlow platformFlow);
|
||||||
|
|
||||||
|
}
|
||||||
|
|
@ -2,6 +2,7 @@ package com.playlet.web.service.app;
|
||||||
|
|
||||||
import com.github.pagehelper.PageInfo;
|
import com.github.pagehelper.PageInfo;
|
||||||
import com.playlet.system.domain.PlayletTask;
|
import com.playlet.system.domain.PlayletTask;
|
||||||
|
import com.playlet.system.domain.PlayletUserTask;
|
||||||
|
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
|
|
@ -19,10 +20,10 @@ public interface PlayletTaskAppService {
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 用户选定任务
|
* 用户选定任务
|
||||||
* @param playletTask 任务实体数据
|
* @param playletUserTask 任务实体数据
|
||||||
* @return 是否添加成功
|
* @return 是否添加成功
|
||||||
*/
|
*/
|
||||||
Boolean userDesignateTask(PlayletTask playletTask);
|
Boolean userDesignateTask(PlayletUserTask playletUserTask);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 查询任务
|
* 查询任务
|
||||||
|
|
@ -71,4 +72,19 @@ public interface PlayletTaskAppService {
|
||||||
* @return 结果
|
* @return 结果
|
||||||
*/
|
*/
|
||||||
int deletePlayletTaskById(Long id);
|
int deletePlayletTaskById(Long id);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @param playletUserTask 推广任务
|
||||||
|
* @return 获取推广的链接
|
||||||
|
*/
|
||||||
|
String promotionTask(PlayletUserTask playletUserTask);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @param playletUserTask 入参
|
||||||
|
* @param pageNum 页数
|
||||||
|
* @param pageSize 单页条数
|
||||||
|
* @return 符合结果数据
|
||||||
|
*/
|
||||||
|
PageInfo<PlayletUserTask> getPromotionTaskPage(PlayletUserTask playletUserTask, Integer pageNum, Integer pageSize);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,40 @@
|
||||||
|
package com.playlet.web.service.app.impl;
|
||||||
|
|
||||||
|
import com.github.pagehelper.PageHelper;
|
||||||
|
import com.github.pagehelper.PageInfo;
|
||||||
|
import com.playlet.system.domain.PlayletUserExpandAccount;
|
||||||
|
import com.playlet.system.service.IPlayletUserExpandAccountService;
|
||||||
|
import com.playlet.web.service.app.PlayletExpandService;
|
||||||
|
import lombok.RequiredArgsConstructor;
|
||||||
|
import lombok.extern.slf4j.Slf4j;
|
||||||
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
|
import org.springframework.stereotype.Service;
|
||||||
|
|
||||||
|
import java.util.Date;
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
@Slf4j
|
||||||
|
@Service
|
||||||
|
@RequiredArgsConstructor(onConstructor = @__(@Autowired))
|
||||||
|
public class PlayletExpandServiceImpl implements PlayletExpandService {
|
||||||
|
|
||||||
|
private final IPlayletUserExpandAccountService iPlayletUserExpandAccountService;
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public PageInfo<PlayletUserExpandAccount> getPageList(PlayletUserExpandAccount expandAccount, Integer pageNum, Integer pageSize) {
|
||||||
|
PageHelper.startPage(pageNum, pageSize);
|
||||||
|
List<PlayletUserExpandAccount> list = iPlayletUserExpandAccountService.selectPlayletUserExpandAccountList(expandAccount);
|
||||||
|
return PageInfo.of(list);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public List<PlayletUserExpandAccount> getList(PlayletUserExpandAccount expandAccount) {
|
||||||
|
return iPlayletUserExpandAccountService.selectPlayletUserExpandAccountList(expandAccount);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void addAccount(PlayletUserExpandAccount expandAccount) {
|
||||||
|
expandAccount.setCreateTime(new Date());
|
||||||
|
iPlayletUserExpandAccountService.insertPlayletUserExpandAccount(expandAccount);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,25 @@
|
||||||
|
package com.playlet.web.service.app.impl;
|
||||||
|
|
||||||
|
import com.playlet.system.domain.PlayletPlatformFlow;
|
||||||
|
import com.playlet.system.service.IPlayletPlatformFlowService;
|
||||||
|
import com.playlet.web.service.app.PlayletFlowAppService;
|
||||||
|
import lombok.RequiredArgsConstructor;
|
||||||
|
import lombok.extern.slf4j.Slf4j;
|
||||||
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
|
import org.springframework.stereotype.Service;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
@Slf4j
|
||||||
|
@Service
|
||||||
|
@RequiredArgsConstructor(onConstructor = @__(@Autowired))
|
||||||
|
public class PlayletFlowAppServiceImpl implements PlayletFlowAppService {
|
||||||
|
|
||||||
|
private final IPlayletPlatformFlowService iPlayletPlatformFlowService;
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public List<PlayletPlatformFlow> getFlowList(PlayletPlatformFlow platformFlow) {
|
||||||
|
return iPlayletPlatformFlowService.selectPlayletPlatformFlowList(platformFlow);
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
@ -10,6 +10,7 @@ import com.playlet.common.utils.DateUtils;
|
||||||
import com.playlet.system.domain.*;
|
import com.playlet.system.domain.*;
|
||||||
import com.playlet.system.service.IPlayletRevenueRecordService;
|
import com.playlet.system.service.IPlayletRevenueRecordService;
|
||||||
import com.playlet.system.service.IPlayletTaskService;
|
import com.playlet.system.service.IPlayletTaskService;
|
||||||
|
import com.playlet.system.service.IPlayletUserTaskService;
|
||||||
import com.playlet.web.service.app.PlayletTaskAppService;
|
import com.playlet.web.service.app.PlayletTaskAppService;
|
||||||
import com.playlet.web.service.app.PlayletUserTaskAppService;
|
import com.playlet.web.service.app.PlayletUserTaskAppService;
|
||||||
import lombok.RequiredArgsConstructor;
|
import lombok.RequiredArgsConstructor;
|
||||||
|
|
@ -33,6 +34,7 @@ import java.util.List;
|
||||||
public class PlayletTaskAppServiceImpl implements PlayletTaskAppService {
|
public class PlayletTaskAppServiceImpl implements PlayletTaskAppService {
|
||||||
|
|
||||||
private final IPlayletTaskService playletTaskService;
|
private final IPlayletTaskService playletTaskService;
|
||||||
|
private final IPlayletUserTaskService iPlayletUserTaskService;
|
||||||
private final PlayletUserTaskAppService playletUserTaskAppService;
|
private final PlayletUserTaskAppService playletUserTaskAppService;
|
||||||
private final IPlayletRevenueRecordService revenueRecordService;
|
private final IPlayletRevenueRecordService revenueRecordService;
|
||||||
|
|
||||||
|
|
@ -51,9 +53,9 @@ public class PlayletTaskAppServiceImpl implements PlayletTaskAppService {
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public Boolean userDesignateTask(PlayletTask playletTask) {
|
public Boolean userDesignateTask(PlayletUserTask playletUserTask) {
|
||||||
// 检查任务数据。
|
// 检查任务数据。
|
||||||
PlayletTask task = playletTaskService.selectPlayletTaskById(playletTask.getId());
|
PlayletTask task = playletTaskService.selectPlayletTaskById(playletUserTask.getTaskId());
|
||||||
// 任务数据数据
|
// 任务数据数据
|
||||||
if (ObjectUtils.isNull(task)) {
|
if (ObjectUtils.isNull(task)) {
|
||||||
throw new ServiceException("参与任务失败,未找到匹配任务数据。");
|
throw new ServiceException("参与任务失败,未找到匹配任务数据。");
|
||||||
|
|
@ -63,9 +65,17 @@ public class PlayletTaskAppServiceImpl implements PlayletTaskAppService {
|
||||||
throw new ServiceException("参与任务失败,任务还未开始或者已结束。");
|
throw new ServiceException("参与任务失败,任务还未开始或者已结束。");
|
||||||
}
|
}
|
||||||
// 是否在任务时间线内
|
// 是否在任务时间线内
|
||||||
if (DateUtil.compare(task.getStartTime(), new Date()) >=0 && DateUtil.compare(task.getEndTime(), new Date())<=0) {
|
if (DateUtil.compare(new Date(), task.getStartTime()) >=0 && DateUtil.compare(new Date(), task.getEndTime())<=0) {
|
||||||
|
long count = iPlayletUserTaskService.lambdaQuery().eq(PlayletUserTask::getUserId, playletUserTask.getUserId())
|
||||||
|
.eq(PlayletUserTask::getTaskId, playletUserTask.getTaskId())
|
||||||
|
.count();
|
||||||
|
if(count > 0){
|
||||||
|
throw new ServiceException("请勿重复领取任务!");
|
||||||
|
}
|
||||||
|
PlayletUserTask model = PlayletUserTask.dataSupplement(task);
|
||||||
|
model.setUserId(playletUserTask.getUserId());
|
||||||
// 用户数据绑定。
|
// 用户数据绑定。
|
||||||
playletUserTaskAppService.insertPlayletUserTask(PlayletUserTask.dataSupplement(task));
|
playletUserTaskAppService.insertPlayletUserTask(model);
|
||||||
return Boolean.TRUE;
|
return Boolean.TRUE;
|
||||||
} else {
|
} else {
|
||||||
throw new ServiceException("参与任务失败,任务未开始或者已结束。");
|
throw new ServiceException("参与任务失败,任务未开始或者已结束。");
|
||||||
|
|
@ -152,4 +162,35 @@ public class PlayletTaskAppServiceImpl implements PlayletTaskAppService {
|
||||||
public int deletePlayletTaskById(Long id) {
|
public int deletePlayletTaskById(Long id) {
|
||||||
return playletTaskService.deletePlayletTaskById(id);
|
return playletTaskService.deletePlayletTaskById(id);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public String promotionTask(PlayletUserTask playletUserTask) {
|
||||||
|
PlayletUserTask model = iPlayletUserTaskService.getById(playletUserTask.getId());
|
||||||
|
if(model == null){
|
||||||
|
throw new ServiceException("改任务不存在!");
|
||||||
|
}
|
||||||
|
// 检查任务数据。
|
||||||
|
PlayletTask task = playletTaskService.selectPlayletTaskById(model.getTaskId());
|
||||||
|
// 任务数据数据
|
||||||
|
if (ObjectUtils.isNull(task)) {
|
||||||
|
throw new ServiceException("参与任务失败,未找到匹配任务数据。");
|
||||||
|
}
|
||||||
|
model.setUserTaskState(1);
|
||||||
|
// 将任务更新成推广中
|
||||||
|
iPlayletUserTaskService.updateById(model);
|
||||||
|
return "https://jumpv.qinronmedia.com/web/call?key=e9848b589167b459e98178e2e5ebfdbc";
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public PageInfo<PlayletUserTask> getPromotionTaskPage(PlayletUserTask playletUserTask, Integer pageNum, Integer pageSize) {
|
||||||
|
PageHelper.startPage(pageNum, pageSize);
|
||||||
|
List<PlayletUserTask> list = iPlayletUserTaskService.lambdaQuery()
|
||||||
|
.eq(PlayletUserTask::getUserId, playletUserTask.getUserId())
|
||||||
|
.ne(PlayletUserTask::getUserTaskState, 0)
|
||||||
|
.list();
|
||||||
|
list.forEach(model->{
|
||||||
|
model.setPlayletTask(playletTaskService.getById(model.getTaskId()));
|
||||||
|
});
|
||||||
|
return PageInfo.of(list);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,106 @@
|
||||||
|
<!DOCTYPE html>
|
||||||
|
<html lang="zh" xmlns:th="http://www.thymeleaf.org" xmlns:shiro="http://www.pollix.at/thymeleaf/shiro">
|
||||||
|
<head>
|
||||||
|
<th:block th:include="include :: header('用户外部账号列表')" />
|
||||||
|
</head>
|
||||||
|
<body class="gray-bg">
|
||||||
|
<div class="container-div">
|
||||||
|
<div class="row">
|
||||||
|
<div class="col-sm-12 search-collapse">
|
||||||
|
<form id="formId">
|
||||||
|
<div class="select-list">
|
||||||
|
<ul>
|
||||||
|
<li>
|
||||||
|
<label>昵称:</label>
|
||||||
|
<input type="text" name="name"/>
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
<label>账号:</label>
|
||||||
|
<input type="text" name="account"/>
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
<a class="btn btn-primary btn-rounded btn-sm" onclick="$.table.search()"><i class="fa fa-search"></i> 搜索</a>
|
||||||
|
<a class="btn btn-warning btn-rounded btn-sm" onclick="$.form.reset()"><i class="fa fa-refresh"></i> 重置</a>
|
||||||
|
</li>
|
||||||
|
</ul>
|
||||||
|
</div>
|
||||||
|
</form>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="btn-group-sm" id="toolbar" role="group">
|
||||||
|
<a class="btn btn-success" onclick="$.operate.add()" shiro:hasPermission="system:account:add">
|
||||||
|
<i class="fa fa-plus"></i> 添加
|
||||||
|
</a>
|
||||||
|
<a class="btn btn-primary single disabled" onclick="$.operate.edit()" shiro:hasPermission="system:account:edit">
|
||||||
|
<i class="fa fa-edit"></i> 修改
|
||||||
|
</a>
|
||||||
|
<a class="btn btn-danger multiple disabled" onclick="$.operate.removeAll()" shiro:hasPermission="system:account:remove">
|
||||||
|
<i class="fa fa-remove"></i> 删除
|
||||||
|
</a>
|
||||||
|
<a class="btn btn-warning" onclick="$.table.exportExcel()" shiro:hasPermission="system:account:export">
|
||||||
|
<i class="fa fa-download"></i> 导出
|
||||||
|
</a>
|
||||||
|
</div>
|
||||||
|
<div class="col-sm-12 select-table table-striped">
|
||||||
|
<table id="bootstrap-table"></table>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<th:block th:include="include :: footer" />
|
||||||
|
<script th:inline="javascript">
|
||||||
|
var editFlag = [[${@permission.hasPermi('playlet:expand:edit')}]];
|
||||||
|
var removeFlag = [[${@permission.hasPermi('playlet:expand:remove')}]];
|
||||||
|
var prefix = ctx + "system/playlet/expand";
|
||||||
|
|
||||||
|
$(function() {
|
||||||
|
var options = {
|
||||||
|
url: prefix + "/list",
|
||||||
|
createUrl: prefix + "/add",
|
||||||
|
updateUrl: prefix + "/edit/{id}",
|
||||||
|
removeUrl: prefix + "/remove",
|
||||||
|
exportUrl: prefix + "/export",
|
||||||
|
modalName: "用户外部账号",
|
||||||
|
columns: [{
|
||||||
|
checkbox: true
|
||||||
|
},
|
||||||
|
{
|
||||||
|
field: 'id',
|
||||||
|
title: '主键id',
|
||||||
|
visible: false
|
||||||
|
},
|
||||||
|
{
|
||||||
|
field: 'name',
|
||||||
|
title: '昵称'
|
||||||
|
},
|
||||||
|
{
|
||||||
|
field: 'account',
|
||||||
|
title: '账号'
|
||||||
|
},
|
||||||
|
{
|
||||||
|
field: 'type',
|
||||||
|
title: '平台 01.抖音 02.快手 03.视频号'
|
||||||
|
},
|
||||||
|
{
|
||||||
|
field: 'status',
|
||||||
|
title: '审核状态 01.待审核 02.审核通过 03.审核拒绝'
|
||||||
|
},
|
||||||
|
{
|
||||||
|
field: 'remark',
|
||||||
|
title: '备注'
|
||||||
|
},
|
||||||
|
{
|
||||||
|
title: '操作',
|
||||||
|
align: 'center',
|
||||||
|
formatter: function(value, row, index) {
|
||||||
|
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-danger btn-xs ' + removeFlag + '" href="javascript:void(0)" onclick="$.operate.remove(\'' + row.id + '\')"><i class="fa fa-remove"></i>删除</a>');
|
||||||
|
return actions.join('');
|
||||||
|
}
|
||||||
|
}]
|
||||||
|
};
|
||||||
|
$.table.init(options);
|
||||||
|
});
|
||||||
|
</script>
|
||||||
|
</body>
|
||||||
|
</html>
|
||||||
|
|
@ -0,0 +1,76 @@
|
||||||
|
<!DOCTYPE html>
|
||||||
|
<html lang="zh" xmlns:th="http://www.thymeleaf.org" >
|
||||||
|
<head>
|
||||||
|
<th:block th:include="include :: header('新增挂载操作流程')" />
|
||||||
|
<th:block th:include="include :: summernote-css" />
|
||||||
|
</head>
|
||||||
|
<body class="white-bg">
|
||||||
|
<div class="wrapper wrapper-content animated fadeInRight ibox-content">
|
||||||
|
<form class="form-horizontal m" id="form-flow-add">
|
||||||
|
<div class="form-group">
|
||||||
|
<label class="col-sm-3 control-label">挂载流程:</label>
|
||||||
|
<div class="col-sm-8">
|
||||||
|
<input type="hidden" class="form-control" name="content">
|
||||||
|
<div class="summernote" id="content"></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>
|
||||||
|
</div>
|
||||||
|
<th:block th:include="include :: footer" />
|
||||||
|
<th:block th:include="include :: summernote-js" />
|
||||||
|
<script th:inline="javascript">
|
||||||
|
var prefix = ctx + "system/playlet/flow"
|
||||||
|
$("#form-flow-add").validate({
|
||||||
|
focusCleanup: true
|
||||||
|
});
|
||||||
|
|
||||||
|
function submitHandler() {
|
||||||
|
if ($.validate.form()) {
|
||||||
|
$.operate.save(prefix + "/add", $('#form-flow-add').serialize());
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
$(function() {
|
||||||
|
$('.summernote').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("图片上传失败。");
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
}
|
||||||
|
});
|
||||||
|
});
|
||||||
|
</script>
|
||||||
|
</body>
|
||||||
|
</html>
|
||||||
|
|
@ -0,0 +1,81 @@
|
||||||
|
<!DOCTYPE html>
|
||||||
|
<html lang="zh" xmlns:th="http://www.thymeleaf.org" >
|
||||||
|
<head>
|
||||||
|
<th:block th:include="include :: header('修改挂载操作流程')" />
|
||||||
|
<th:block th:include="include :: summernote-css" />
|
||||||
|
</head>
|
||||||
|
<body class="white-bg">
|
||||||
|
<div class="wrapper wrapper-content animated fadeInRight ibox-content">
|
||||||
|
<form class="form-horizontal m" id="form-flow-edit" th:object="${playletPlatformFlow}">
|
||||||
|
<input name="id" th:field="*{id}" type="hidden">
|
||||||
|
<div class="form-group">
|
||||||
|
<label class="col-sm-3 control-label">挂载流程:</label>
|
||||||
|
<div class="col-sm-8">
|
||||||
|
<input type="hidden" class="form-control" th:field="*{content}">
|
||||||
|
<div class="summernote" id="content"></div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="form-group">
|
||||||
|
<label class="col-sm-3 control-label">备注:</label>
|
||||||
|
<div class="col-sm-8">
|
||||||
|
<input name="remark" th:field="*{remark}" class="form-control" type="text">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</form>
|
||||||
|
</div>
|
||||||
|
<th:block th:include="include :: footer" />
|
||||||
|
<th:block th:include="include :: summernote-js" />
|
||||||
|
<script th:inline="javascript">
|
||||||
|
var prefix = ctx + "system/playlet/flow";
|
||||||
|
$("#form-flow-edit").validate({
|
||||||
|
focusCleanup: true
|
||||||
|
});
|
||||||
|
|
||||||
|
function submitHandler() {
|
||||||
|
if ($.validate.form()) {
|
||||||
|
$.operate.save(prefix + "/edit", $('#form-flow-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>
|
||||||
|
</body>
|
||||||
|
</html>
|
||||||
|
|
@ -0,0 +1,90 @@
|
||||||
|
<!DOCTYPE html>
|
||||||
|
<html lang="zh" xmlns:th="http://www.thymeleaf.org" xmlns:shiro="http://www.pollix.at/thymeleaf/shiro">
|
||||||
|
<head>
|
||||||
|
<th:block th:include="include :: header('挂载操作流程列表')" />
|
||||||
|
</head>
|
||||||
|
<body class="gray-bg">
|
||||||
|
<div class="container-div">
|
||||||
|
<div class="row">
|
||||||
|
<div class="col-sm-12 search-collapse">
|
||||||
|
<form id="formId">
|
||||||
|
<div class="select-list">
|
||||||
|
<ul>
|
||||||
|
<li>
|
||||||
|
<a class="btn btn-primary btn-rounded btn-sm" onclick="$.table.search()"><i class="fa fa-search"></i> 搜索</a>
|
||||||
|
<a class="btn btn-warning btn-rounded btn-sm" onclick="$.form.reset()"><i class="fa fa-refresh"></i> 重置</a>
|
||||||
|
</li>
|
||||||
|
</ul>
|
||||||
|
</div>
|
||||||
|
</form>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div class="btn-group-sm" id="toolbar" role="group">
|
||||||
|
<a class="btn btn-success" onclick="$.operate.add()" shiro:hasPermission="system:flow:add">
|
||||||
|
<i class="fa fa-plus"></i> 添加
|
||||||
|
</a>
|
||||||
|
<a class="btn btn-primary single disabled" onclick="$.operate.edit()" shiro:hasPermission="system:flow:edit">
|
||||||
|
<i class="fa fa-edit"></i> 修改
|
||||||
|
</a>
|
||||||
|
<a class="btn btn-danger multiple disabled" onclick="$.operate.removeAll()" shiro:hasPermission="system:flow:remove">
|
||||||
|
<i class="fa fa-remove"></i> 删除
|
||||||
|
</a>
|
||||||
|
<a class="btn btn-warning" onclick="$.table.exportExcel()" shiro:hasPermission="system:flow:export">
|
||||||
|
<i class="fa fa-download"></i> 导出
|
||||||
|
</a>
|
||||||
|
</div>
|
||||||
|
<div class="col-sm-12 select-table table-striped">
|
||||||
|
<table id="bootstrap-table"></table>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<th:block th:include="include :: footer" />
|
||||||
|
<script th:inline="javascript">
|
||||||
|
var editFlag = [[${@permission.hasPermi('playlet:flow:edit')}]];
|
||||||
|
var removeFlag = [[${@permission.hasPermi('playlet:flow:remove')}]];
|
||||||
|
var prefix = ctx + "system/playlet/flow";
|
||||||
|
|
||||||
|
$(function() {
|
||||||
|
var options = {
|
||||||
|
url: prefix + "/list",
|
||||||
|
createUrl: prefix + "/add",
|
||||||
|
updateUrl: prefix + "/edit/{id}",
|
||||||
|
removeUrl: prefix + "/remove",
|
||||||
|
exportUrl: prefix + "/export",
|
||||||
|
modalName: "挂载操作流程",
|
||||||
|
columns: [{
|
||||||
|
checkbox: true
|
||||||
|
},
|
||||||
|
{
|
||||||
|
field: 'id',
|
||||||
|
title: '主键',
|
||||||
|
visible: false
|
||||||
|
},
|
||||||
|
{
|
||||||
|
field: 'type',
|
||||||
|
title: '平台类型 01.抖音 02.快手 03.视频号'
|
||||||
|
},
|
||||||
|
{
|
||||||
|
field: 'content',
|
||||||
|
title: '挂载流程'
|
||||||
|
},
|
||||||
|
{
|
||||||
|
field: 'remark',
|
||||||
|
title: '备注'
|
||||||
|
},
|
||||||
|
{
|
||||||
|
title: '操作',
|
||||||
|
align: 'center',
|
||||||
|
formatter: function(value, row, index) {
|
||||||
|
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-danger btn-xs ' + removeFlag + '" href="javascript:void(0)" onclick="$.operate.remove(\'' + row.id + '\')"><i class="fa fa-remove"></i>删除</a>');
|
||||||
|
return actions.join('');
|
||||||
|
}
|
||||||
|
}]
|
||||||
|
};
|
||||||
|
$.table.init(options);
|
||||||
|
});
|
||||||
|
</script>
|
||||||
|
</body>
|
||||||
|
</html>
|
||||||
|
|
@ -0,0 +1,33 @@
|
||||||
|
package com.playlet.system.domain;
|
||||||
|
|
||||||
|
import com.playlet.common.core.domain.BaseEntity;
|
||||||
|
import com.baomidou.mybatisplus.annotation.TableName;
|
||||||
|
import lombok.Data;
|
||||||
|
import lombok.EqualsAndHashCode;
|
||||||
|
import com.playlet.common.annotation.Excel;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 挂载操作流程对象 playlet_platform_flow
|
||||||
|
*
|
||||||
|
* @author ruoyi
|
||||||
|
* @date 2024-04-14
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
@EqualsAndHashCode(callSuper = false)
|
||||||
|
@TableName(value = "playlet_platform_flow")
|
||||||
|
public class PlayletPlatformFlow extends BaseEntity
|
||||||
|
{
|
||||||
|
private static final long serialVersionUID = 1L;
|
||||||
|
|
||||||
|
/** 主键 */
|
||||||
|
private Long id;
|
||||||
|
|
||||||
|
/** 平台类型 01.抖音 02.快手 03.视频号 */
|
||||||
|
@Excel(name = "平台类型 01.抖音 02.快手 03.视频号")
|
||||||
|
private String type;
|
||||||
|
|
||||||
|
/** 挂载流程 */
|
||||||
|
@Excel(name = "挂载流程")
|
||||||
|
private String content;
|
||||||
|
|
||||||
|
}
|
||||||
|
|
@ -61,4 +61,7 @@ public class PlayletUser extends BaseEntity
|
||||||
@ApiModelProperty(value = "父级分销ID")
|
@ApiModelProperty(value = "父级分销ID")
|
||||||
private String parentId;
|
private String parentId;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "用户状态 01.待审核, 02.审核通过 03.审核拒绝")
|
||||||
|
private String status;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,52 @@
|
||||||
|
package com.playlet.system.domain;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.annotation.IdType;
|
||||||
|
import com.baomidou.mybatisplus.annotation.TableId;
|
||||||
|
import com.playlet.common.core.domain.BaseEntity;
|
||||||
|
import com.baomidou.mybatisplus.annotation.TableName;
|
||||||
|
import io.swagger.annotations.ApiModel;
|
||||||
|
import io.swagger.annotations.ApiModelProperty;
|
||||||
|
import lombok.Data;
|
||||||
|
import lombok.EqualsAndHashCode;
|
||||||
|
import com.playlet.common.annotation.Excel;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 用户外部账号对象 playlet_user_expand_account
|
||||||
|
*
|
||||||
|
* @author ruoyi
|
||||||
|
* @date 2024-04-14
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
@EqualsAndHashCode(callSuper = false)
|
||||||
|
@TableName(value = "playlet_user_expand_account")
|
||||||
|
@ApiModel(value = "短剧*扩展账户管理")
|
||||||
|
public class PlayletUserExpandAccount extends BaseEntity
|
||||||
|
{
|
||||||
|
private static final long serialVersionUID = 1L;
|
||||||
|
|
||||||
|
/** 主键id */
|
||||||
|
@ApiModelProperty(value = "主键")
|
||||||
|
@TableId(value = "id", type = IdType.AUTO)
|
||||||
|
private Long id;
|
||||||
|
|
||||||
|
/** 昵称 */
|
||||||
|
@Excel(name = "昵称")
|
||||||
|
@ApiModelProperty(value = "昵称")
|
||||||
|
private String name;
|
||||||
|
|
||||||
|
/** 账号 */
|
||||||
|
@Excel(name = "账号")
|
||||||
|
@ApiModelProperty(value = "账号")
|
||||||
|
private String account;
|
||||||
|
|
||||||
|
/** 平台 01.抖音 02.快手 03.视频号 */
|
||||||
|
@Excel(name = "平台 01.抖音 02.快手 03.视频号")
|
||||||
|
@ApiModelProperty(value = "平台 01.抖音 02.快手 03.视频号")
|
||||||
|
private String type;
|
||||||
|
|
||||||
|
/** 审核状态 01.待审核 02.审核通过 03.审核拒绝 */
|
||||||
|
@Excel(name = "审核状态 01.待审核 02.审核通过 03.审核拒绝")
|
||||||
|
@ApiModelProperty(value = "审核状态 01.待审核 02.审核通过 03.审核拒绝")
|
||||||
|
private String status;
|
||||||
|
|
||||||
|
}
|
||||||
|
|
@ -1,6 +1,7 @@
|
||||||
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;
|
||||||
|
|
@ -38,6 +39,10 @@ public class PlayletUserTask extends BaseEntity {
|
||||||
@Excel(name = "任务id")
|
@Excel(name = "任务id")
|
||||||
private Long taskId;
|
private Long taskId;
|
||||||
|
|
||||||
|
@ApiModelProperty(value = "任务详情")
|
||||||
|
@TableField(exist = false)
|
||||||
|
private PlayletTask playletTask;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 用户Id
|
* 用户Id
|
||||||
*/
|
*/
|
||||||
|
|
@ -70,7 +75,7 @@ public class PlayletUserTask extends BaseEntity {
|
||||||
PlayletUserTask userTask = new PlayletUserTask();
|
PlayletUserTask userTask = new PlayletUserTask();
|
||||||
userTask.setTaskId(task.getId());
|
userTask.setTaskId(task.getId());
|
||||||
userTask.setUserId(task.getUserId());
|
userTask.setUserId(task.getUserId());
|
||||||
userTask.setUserTaskState(1);
|
userTask.setUserTaskState(0);
|
||||||
userTask.setCreateBy(task.getUserId());
|
userTask.setCreateBy(task.getUserId());
|
||||||
userTask.setUpdateBy(task.getUserId());
|
userTask.setUpdateBy(task.getUserId());
|
||||||
userTask.setTaskStartTime(task.getStartTime());
|
userTask.setTaskStartTime(task.getStartTime());
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,62 @@
|
||||||
|
package com.playlet.system.mapper;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
import com.playlet.system.domain.PlayletPlatformFlow;
|
||||||
|
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 挂载操作流程Mapper接口
|
||||||
|
*
|
||||||
|
* @author ruoyi
|
||||||
|
* @date 2024-04-14
|
||||||
|
*/
|
||||||
|
public interface PlayletPlatformFlowMapper extends BaseMapper<PlayletPlatformFlow>
|
||||||
|
{
|
||||||
|
/**
|
||||||
|
* 查询挂载操作流程
|
||||||
|
*
|
||||||
|
* @param id 挂载操作流程主键
|
||||||
|
* @return 挂载操作流程
|
||||||
|
*/
|
||||||
|
public PlayletPlatformFlow selectPlayletPlatformFlowById(Long id);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查询挂载操作流程列表
|
||||||
|
*
|
||||||
|
* @param playletPlatformFlow 挂载操作流程
|
||||||
|
* @return 挂载操作流程集合
|
||||||
|
*/
|
||||||
|
public List<PlayletPlatformFlow> selectPlayletPlatformFlowList(PlayletPlatformFlow playletPlatformFlow);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 新增挂载操作流程
|
||||||
|
*
|
||||||
|
* @param playletPlatformFlow 挂载操作流程
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int insertPlayletPlatformFlow(PlayletPlatformFlow playletPlatformFlow);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 修改挂载操作流程
|
||||||
|
*
|
||||||
|
* @param playletPlatformFlow 挂载操作流程
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int updatePlayletPlatformFlow(PlayletPlatformFlow playletPlatformFlow);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除挂载操作流程
|
||||||
|
*
|
||||||
|
* @param id 挂载操作流程主键
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int deletePlayletPlatformFlowById(Long id);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 批量删除挂载操作流程
|
||||||
|
*
|
||||||
|
* @param ids 需要删除的数据主键集合
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int deletePlayletPlatformFlowByIds(String[] ids);
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,62 @@
|
||||||
|
package com.playlet.system.mapper;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
import com.playlet.system.domain.PlayletUserExpandAccount;
|
||||||
|
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 用户外部账号Mapper接口
|
||||||
|
*
|
||||||
|
* @author ruoyi
|
||||||
|
* @date 2024-04-14
|
||||||
|
*/
|
||||||
|
public interface PlayletUserExpandAccountMapper extends BaseMapper<PlayletUserExpandAccount>
|
||||||
|
{
|
||||||
|
/**
|
||||||
|
* 查询用户外部账号
|
||||||
|
*
|
||||||
|
* @param id 用户外部账号主键
|
||||||
|
* @return 用户外部账号
|
||||||
|
*/
|
||||||
|
public PlayletUserExpandAccount selectPlayletUserExpandAccountById(Long id);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查询用户外部账号列表
|
||||||
|
*
|
||||||
|
* @param playletUserExpandAccount 用户外部账号
|
||||||
|
* @return 用户外部账号集合
|
||||||
|
*/
|
||||||
|
public List<PlayletUserExpandAccount> selectPlayletUserExpandAccountList(PlayletUserExpandAccount playletUserExpandAccount);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 新增用户外部账号
|
||||||
|
*
|
||||||
|
* @param playletUserExpandAccount 用户外部账号
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int insertPlayletUserExpandAccount(PlayletUserExpandAccount playletUserExpandAccount);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 修改用户外部账号
|
||||||
|
*
|
||||||
|
* @param playletUserExpandAccount 用户外部账号
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int updatePlayletUserExpandAccount(PlayletUserExpandAccount playletUserExpandAccount);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除用户外部账号
|
||||||
|
*
|
||||||
|
* @param id 用户外部账号主键
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int deletePlayletUserExpandAccountById(Long id);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 批量删除用户外部账号
|
||||||
|
*
|
||||||
|
* @param ids 需要删除的数据主键集合
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int deletePlayletUserExpandAccountByIds(String[] ids);
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,62 @@
|
||||||
|
package com.playlet.system.service;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
import com.playlet.system.domain.PlayletPlatformFlow;
|
||||||
|
import com.baomidou.mybatisplus.extension.service.IService;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 挂载操作流程Service接口
|
||||||
|
*
|
||||||
|
* @author ruoyi
|
||||||
|
* @date 2024-04-14
|
||||||
|
*/
|
||||||
|
public interface IPlayletPlatformFlowService extends IService<PlayletPlatformFlow>
|
||||||
|
{
|
||||||
|
/**
|
||||||
|
* 查询挂载操作流程
|
||||||
|
*
|
||||||
|
* @param id 挂载操作流程主键
|
||||||
|
* @return 挂载操作流程
|
||||||
|
*/
|
||||||
|
public PlayletPlatformFlow selectPlayletPlatformFlowById(Long id);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查询挂载操作流程列表
|
||||||
|
*
|
||||||
|
* @param playletPlatformFlow 挂载操作流程
|
||||||
|
* @return 挂载操作流程集合
|
||||||
|
*/
|
||||||
|
public List<PlayletPlatformFlow> selectPlayletPlatformFlowList(PlayletPlatformFlow playletPlatformFlow);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 新增挂载操作流程
|
||||||
|
*
|
||||||
|
* @param playletPlatformFlow 挂载操作流程
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int insertPlayletPlatformFlow(PlayletPlatformFlow playletPlatformFlow);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 修改挂载操作流程
|
||||||
|
*
|
||||||
|
* @param playletPlatformFlow 挂载操作流程
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int updatePlayletPlatformFlow(PlayletPlatformFlow playletPlatformFlow);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 批量删除挂载操作流程
|
||||||
|
*
|
||||||
|
* @param ids 需要删除的挂载操作流程主键集合
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int deletePlayletPlatformFlowByIds(String ids);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除挂载操作流程信息
|
||||||
|
*
|
||||||
|
* @param id 挂载操作流程主键
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int deletePlayletPlatformFlowById(Long id);
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,62 @@
|
||||||
|
package com.playlet.system.service;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
import com.playlet.system.domain.PlayletUserExpandAccount;
|
||||||
|
import com.baomidou.mybatisplus.extension.service.IService;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 用户外部账号Service接口
|
||||||
|
*
|
||||||
|
* @author ruoyi
|
||||||
|
* @date 2024-04-14
|
||||||
|
*/
|
||||||
|
public interface IPlayletUserExpandAccountService extends IService<PlayletUserExpandAccount>
|
||||||
|
{
|
||||||
|
/**
|
||||||
|
* 查询用户外部账号
|
||||||
|
*
|
||||||
|
* @param id 用户外部账号主键
|
||||||
|
* @return 用户外部账号
|
||||||
|
*/
|
||||||
|
public PlayletUserExpandAccount selectPlayletUserExpandAccountById(Long id);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查询用户外部账号列表
|
||||||
|
*
|
||||||
|
* @param playletUserExpandAccount 用户外部账号
|
||||||
|
* @return 用户外部账号集合
|
||||||
|
*/
|
||||||
|
public List<PlayletUserExpandAccount> selectPlayletUserExpandAccountList(PlayletUserExpandAccount playletUserExpandAccount);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 新增用户外部账号
|
||||||
|
*
|
||||||
|
* @param playletUserExpandAccount 用户外部账号
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int insertPlayletUserExpandAccount(PlayletUserExpandAccount playletUserExpandAccount);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 修改用户外部账号
|
||||||
|
*
|
||||||
|
* @param playletUserExpandAccount 用户外部账号
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int updatePlayletUserExpandAccount(PlayletUserExpandAccount playletUserExpandAccount);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 批量删除用户外部账号
|
||||||
|
*
|
||||||
|
* @param ids 需要删除的用户外部账号主键集合
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int deletePlayletUserExpandAccountByIds(String ids);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除用户外部账号信息
|
||||||
|
*
|
||||||
|
* @param id 用户外部账号主键
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int deletePlayletUserExpandAccountById(Long id);
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,98 @@
|
||||||
|
package com.playlet.system.service.impl;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
import com.playlet.common.utils.DateUtils;
|
||||||
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
|
import org.springframework.stereotype.Service;
|
||||||
|
import com.playlet.system.mapper.PlayletPlatformFlowMapper;
|
||||||
|
import com.playlet.system.domain.PlayletPlatformFlow;
|
||||||
|
import com.playlet.system.service.IPlayletPlatformFlowService;
|
||||||
|
import com.playlet.common.core.text.Convert;
|
||||||
|
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 挂载操作流程Service业务层处理
|
||||||
|
*
|
||||||
|
* @author ruoyi
|
||||||
|
* @date 2024-04-14
|
||||||
|
*/
|
||||||
|
@Service
|
||||||
|
public class PlayletPlatformFlowServiceImpl extends ServiceImpl<PlayletPlatformFlowMapper, PlayletPlatformFlow> implements IPlayletPlatformFlowService
|
||||||
|
{
|
||||||
|
@Autowired
|
||||||
|
private PlayletPlatformFlowMapper playletPlatformFlowMapper;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查询挂载操作流程
|
||||||
|
*
|
||||||
|
* @param id 挂载操作流程主键
|
||||||
|
* @return 挂载操作流程
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public PlayletPlatformFlow selectPlayletPlatformFlowById(Long id)
|
||||||
|
{
|
||||||
|
return playletPlatformFlowMapper.selectPlayletPlatformFlowById(id);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查询挂载操作流程列表
|
||||||
|
*
|
||||||
|
* @param playletPlatformFlow 挂载操作流程
|
||||||
|
* @return 挂载操作流程
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public List<PlayletPlatformFlow> selectPlayletPlatformFlowList(PlayletPlatformFlow playletPlatformFlow)
|
||||||
|
{
|
||||||
|
return playletPlatformFlowMapper.selectPlayletPlatformFlowList(playletPlatformFlow);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 新增挂载操作流程
|
||||||
|
*
|
||||||
|
* @param playletPlatformFlow 挂载操作流程
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public int insertPlayletPlatformFlow(PlayletPlatformFlow playletPlatformFlow)
|
||||||
|
{
|
||||||
|
playletPlatformFlow.setCreateTime(DateUtils.getNowDate());
|
||||||
|
return playletPlatformFlowMapper.insertPlayletPlatformFlow(playletPlatformFlow);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 修改挂载操作流程
|
||||||
|
*
|
||||||
|
* @param playletPlatformFlow 挂载操作流程
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public int updatePlayletPlatformFlow(PlayletPlatformFlow playletPlatformFlow)
|
||||||
|
{
|
||||||
|
playletPlatformFlow.setUpdateTime(DateUtils.getNowDate());
|
||||||
|
return playletPlatformFlowMapper.updatePlayletPlatformFlow(playletPlatformFlow);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 批量删除挂载操作流程
|
||||||
|
*
|
||||||
|
* @param ids 需要删除的挂载操作流程主键
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public int deletePlayletPlatformFlowByIds(String ids)
|
||||||
|
{
|
||||||
|
return playletPlatformFlowMapper.deletePlayletPlatformFlowByIds(Convert.toStrArray(ids));
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除挂载操作流程信息
|
||||||
|
*
|
||||||
|
* @param id 挂载操作流程主键
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public int deletePlayletPlatformFlowById(Long id)
|
||||||
|
{
|
||||||
|
return playletPlatformFlowMapper.deletePlayletPlatformFlowById(id);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,98 @@
|
||||||
|
package com.playlet.system.service.impl;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
import com.playlet.common.utils.DateUtils;
|
||||||
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
|
import org.springframework.stereotype.Service;
|
||||||
|
import com.playlet.system.mapper.PlayletUserExpandAccountMapper;
|
||||||
|
import com.playlet.system.domain.PlayletUserExpandAccount;
|
||||||
|
import com.playlet.system.service.IPlayletUserExpandAccountService;
|
||||||
|
import com.playlet.common.core.text.Convert;
|
||||||
|
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 用户外部账号Service业务层处理
|
||||||
|
*
|
||||||
|
* @author ruoyi
|
||||||
|
* @date 2024-04-14
|
||||||
|
*/
|
||||||
|
@Service
|
||||||
|
public class PlayletUserExpandAccountServiceImpl extends ServiceImpl<PlayletUserExpandAccountMapper, PlayletUserExpandAccount> implements IPlayletUserExpandAccountService
|
||||||
|
{
|
||||||
|
@Autowired
|
||||||
|
private PlayletUserExpandAccountMapper playletUserExpandAccountMapper;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查询用户外部账号
|
||||||
|
*
|
||||||
|
* @param id 用户外部账号主键
|
||||||
|
* @return 用户外部账号
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public PlayletUserExpandAccount selectPlayletUserExpandAccountById(Long id)
|
||||||
|
{
|
||||||
|
return playletUserExpandAccountMapper.selectPlayletUserExpandAccountById(id);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查询用户外部账号列表
|
||||||
|
*
|
||||||
|
* @param playletUserExpandAccount 用户外部账号
|
||||||
|
* @return 用户外部账号
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public List<PlayletUserExpandAccount> selectPlayletUserExpandAccountList(PlayletUserExpandAccount playletUserExpandAccount)
|
||||||
|
{
|
||||||
|
return playletUserExpandAccountMapper.selectPlayletUserExpandAccountList(playletUserExpandAccount);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 新增用户外部账号
|
||||||
|
*
|
||||||
|
* @param playletUserExpandAccount 用户外部账号
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public int insertPlayletUserExpandAccount(PlayletUserExpandAccount playletUserExpandAccount)
|
||||||
|
{
|
||||||
|
playletUserExpandAccount.setCreateTime(DateUtils.getNowDate());
|
||||||
|
return playletUserExpandAccountMapper.insertPlayletUserExpandAccount(playletUserExpandAccount);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 修改用户外部账号
|
||||||
|
*
|
||||||
|
* @param playletUserExpandAccount 用户外部账号
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public int updatePlayletUserExpandAccount(PlayletUserExpandAccount playletUserExpandAccount)
|
||||||
|
{
|
||||||
|
playletUserExpandAccount.setUpdateTime(DateUtils.getNowDate());
|
||||||
|
return playletUserExpandAccountMapper.updatePlayletUserExpandAccount(playletUserExpandAccount);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 批量删除用户外部账号
|
||||||
|
*
|
||||||
|
* @param ids 需要删除的用户外部账号主键
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public int deletePlayletUserExpandAccountByIds(String ids)
|
||||||
|
{
|
||||||
|
return playletUserExpandAccountMapper.deletePlayletUserExpandAccountByIds(Convert.toStrArray(ids));
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除用户外部账号信息
|
||||||
|
*
|
||||||
|
* @param id 用户外部账号主键
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public int deletePlayletUserExpandAccountById(Long id)
|
||||||
|
{
|
||||||
|
return playletUserExpandAccountMapper.deletePlayletUserExpandAccountById(id);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
@ -0,0 +1,82 @@
|
||||||
|
<?xml version="1.0" encoding="UTF-8" ?>
|
||||||
|
<!DOCTYPE mapper
|
||||||
|
PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
|
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||||
|
<mapper namespace="com.playlet.system.mapper.PlayletPlatformFlowMapper">
|
||||||
|
|
||||||
|
<resultMap type="PlayletPlatformFlow" id="PlayletPlatformFlowResult">
|
||||||
|
<result property="id" column="id" />
|
||||||
|
<result property="type" column="type" />
|
||||||
|
<result property="content" column="content" />
|
||||||
|
<result property="createBy" column="create_by" />
|
||||||
|
<result property="createTime" column="create_time" />
|
||||||
|
<result property="updateBy" column="update_by" />
|
||||||
|
<result property="updateTime" column="update_time" />
|
||||||
|
<result property="remark" column="remark" />
|
||||||
|
</resultMap>
|
||||||
|
|
||||||
|
<sql id="selectPlayletPlatformFlowVo">
|
||||||
|
select id, type, content, create_by, create_time, update_by, update_time, remark from playlet_platform_flow
|
||||||
|
</sql>
|
||||||
|
|
||||||
|
<select id="selectPlayletPlatformFlowList" parameterType="PlayletPlatformFlow" resultMap="PlayletPlatformFlowResult">
|
||||||
|
<include refid="selectPlayletPlatformFlowVo"/>
|
||||||
|
<where>
|
||||||
|
<if test="type != null and type != ''"> and type = #{type}</if>
|
||||||
|
<if test="content != null and content != ''"> and content = #{content}</if>
|
||||||
|
</where>
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<select id="selectPlayletPlatformFlowById" parameterType="Long" resultMap="PlayletPlatformFlowResult">
|
||||||
|
<include refid="selectPlayletPlatformFlowVo"/>
|
||||||
|
where id = #{id}
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<insert id="insertPlayletPlatformFlow" parameterType="PlayletPlatformFlow" useGeneratedKeys="true" keyProperty="id">
|
||||||
|
insert into playlet_platform_flow
|
||||||
|
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||||
|
<if test="type != null">type,</if>
|
||||||
|
<if test="content != null">content,</if>
|
||||||
|
<if test="createBy != null">create_by,</if>
|
||||||
|
<if test="createTime != null">create_time,</if>
|
||||||
|
<if test="updateBy != null">update_by,</if>
|
||||||
|
<if test="updateTime != null">update_time,</if>
|
||||||
|
<if test="remark != null">remark,</if>
|
||||||
|
</trim>
|
||||||
|
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||||
|
<if test="type != null">#{type},</if>
|
||||||
|
<if test="content != null">#{content},</if>
|
||||||
|
<if test="createBy != null">#{createBy},</if>
|
||||||
|
<if test="createTime != null">#{createTime},</if>
|
||||||
|
<if test="updateBy != null">#{updateBy},</if>
|
||||||
|
<if test="updateTime != null">#{updateTime},</if>
|
||||||
|
<if test="remark != null">#{remark},</if>
|
||||||
|
</trim>
|
||||||
|
</insert>
|
||||||
|
|
||||||
|
<update id="updatePlayletPlatformFlow" parameterType="PlayletPlatformFlow">
|
||||||
|
update playlet_platform_flow
|
||||||
|
<trim prefix="SET" suffixOverrides=",">
|
||||||
|
<if test="type != null">type = #{type},</if>
|
||||||
|
<if test="content != null">content = #{content},</if>
|
||||||
|
<if test="createBy != null">create_by = #{createBy},</if>
|
||||||
|
<if test="createTime != null">create_time = #{createTime},</if>
|
||||||
|
<if test="updateBy != null">update_by = #{updateBy},</if>
|
||||||
|
<if test="updateTime != null">update_time = #{updateTime},</if>
|
||||||
|
<if test="remark != null">remark = #{remark},</if>
|
||||||
|
</trim>
|
||||||
|
where id = #{id}
|
||||||
|
</update>
|
||||||
|
|
||||||
|
<delete id="deletePlayletPlatformFlowById" parameterType="Long">
|
||||||
|
delete from playlet_platform_flow where id = #{id}
|
||||||
|
</delete>
|
||||||
|
|
||||||
|
<delete id="deletePlayletPlatformFlowByIds" parameterType="String">
|
||||||
|
delete from playlet_platform_flow where id in
|
||||||
|
<foreach item="id" collection="array" open="(" separator="," close=")">
|
||||||
|
#{id}
|
||||||
|
</foreach>
|
||||||
|
</delete>
|
||||||
|
|
||||||
|
</mapper>
|
||||||
|
|
@ -83,6 +83,7 @@
|
||||||
select
|
select
|
||||||
playlet_task.`id`,
|
playlet_task.`id`,
|
||||||
playlet_task.`task_id`,
|
playlet_task.`task_id`,
|
||||||
|
playlet_task.`name`,
|
||||||
playlet_task.`start_time`,
|
playlet_task.`start_time`,
|
||||||
playlet_task.`end_time`,
|
playlet_task.`end_time`,
|
||||||
playlet_task.`platform_type`,
|
playlet_task.`platform_type`,
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,92 @@
|
||||||
|
<?xml version="1.0" encoding="UTF-8" ?>
|
||||||
|
<!DOCTYPE mapper
|
||||||
|
PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||||
|
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||||
|
<mapper namespace="com.playlet.system.mapper.PlayletUserExpandAccountMapper">
|
||||||
|
|
||||||
|
<resultMap type="PlayletUserExpandAccount" id="PlayletUserExpandAccountResult">
|
||||||
|
<result property="id" column="id" />
|
||||||
|
<result property="name" column="name" />
|
||||||
|
<result property="account" column="account" />
|
||||||
|
<result property="type" column="type" />
|
||||||
|
<result property="status" column="status" />
|
||||||
|
<result property="createBy" column="create_by" />
|
||||||
|
<result property="createTime" column="create_time" />
|
||||||
|
<result property="updateBy" column="update_by" />
|
||||||
|
<result property="updateTime" column="update_time" />
|
||||||
|
<result property="remark" column="remark" />
|
||||||
|
</resultMap>
|
||||||
|
|
||||||
|
<sql id="selectPlayletUserExpandAccountVo">
|
||||||
|
select id, name, account, type, status, create_by, create_time, update_by, update_time, remark from playlet_user_expand_account
|
||||||
|
</sql>
|
||||||
|
|
||||||
|
<select id="selectPlayletUserExpandAccountList" parameterType="PlayletUserExpandAccount" resultMap="PlayletUserExpandAccountResult">
|
||||||
|
<include refid="selectPlayletUserExpandAccountVo"/>
|
||||||
|
<where>
|
||||||
|
<if test="name != null and name != ''"> and name like concat('%', #{name}, '%')</if>
|
||||||
|
<if test="account != null and account != ''"> and account = #{account}</if>
|
||||||
|
<if test="type != null and type != ''"> and type = #{type}</if>
|
||||||
|
<if test="status != null and status != ''"> and status = #{status}</if>
|
||||||
|
</where>
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<select id="selectPlayletUserExpandAccountById" parameterType="Long" resultMap="PlayletUserExpandAccountResult">
|
||||||
|
<include refid="selectPlayletUserExpandAccountVo"/>
|
||||||
|
where id = #{id}
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<insert id="insertPlayletUserExpandAccount" parameterType="PlayletUserExpandAccount" useGeneratedKeys="true" keyProperty="id">
|
||||||
|
insert into playlet_user_expand_account
|
||||||
|
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||||
|
<if test="name != null">name,</if>
|
||||||
|
<if test="account != null">account,</if>
|
||||||
|
<if test="type != null">type,</if>
|
||||||
|
<if test="status != null">status,</if>
|
||||||
|
<if test="createBy != null">create_by,</if>
|
||||||
|
<if test="createTime != null">create_time,</if>
|
||||||
|
<if test="updateBy != null">update_by,</if>
|
||||||
|
<if test="updateTime != null">update_time,</if>
|
||||||
|
<if test="remark != null">remark,</if>
|
||||||
|
</trim>
|
||||||
|
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||||
|
<if test="name != null">#{name},</if>
|
||||||
|
<if test="account != null">#{account},</if>
|
||||||
|
<if test="type != null">#{type},</if>
|
||||||
|
<if test="status != null">#{status},</if>
|
||||||
|
<if test="createBy != null">#{createBy},</if>
|
||||||
|
<if test="createTime != null">#{createTime},</if>
|
||||||
|
<if test="updateBy != null">#{updateBy},</if>
|
||||||
|
<if test="updateTime != null">#{updateTime},</if>
|
||||||
|
<if test="remark != null">#{remark},</if>
|
||||||
|
</trim>
|
||||||
|
</insert>
|
||||||
|
|
||||||
|
<update id="updatePlayletUserExpandAccount" parameterType="PlayletUserExpandAccount">
|
||||||
|
update playlet_user_expand_account
|
||||||
|
<trim prefix="SET" suffixOverrides=",">
|
||||||
|
<if test="name != null">name = #{name},</if>
|
||||||
|
<if test="account != null">account = #{account},</if>
|
||||||
|
<if test="type != null">type = #{type},</if>
|
||||||
|
<if test="status != null">status = #{status},</if>
|
||||||
|
<if test="createBy != null">create_by = #{createBy},</if>
|
||||||
|
<if test="createTime != null">create_time = #{createTime},</if>
|
||||||
|
<if test="updateBy != null">update_by = #{updateBy},</if>
|
||||||
|
<if test="updateTime != null">update_time = #{updateTime},</if>
|
||||||
|
<if test="remark != null">remark = #{remark},</if>
|
||||||
|
</trim>
|
||||||
|
where id = #{id}
|
||||||
|
</update>
|
||||||
|
|
||||||
|
<delete id="deletePlayletUserExpandAccountById" parameterType="Long">
|
||||||
|
delete from playlet_user_expand_account where id = #{id}
|
||||||
|
</delete>
|
||||||
|
|
||||||
|
<delete id="deletePlayletUserExpandAccountByIds" parameterType="String">
|
||||||
|
delete from playlet_user_expand_account where id in
|
||||||
|
<foreach item="id" collection="array" open="(" separator="," close=")">
|
||||||
|
#{id}
|
||||||
|
</foreach>
|
||||||
|
</delete>
|
||||||
|
|
||||||
|
</mapper>
|
||||||
|
|
@ -12,6 +12,7 @@
|
||||||
<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="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" />
|
||||||
|
|
@ -20,7 +21,7 @@
|
||||||
</resultMap>
|
</resultMap>
|
||||||
|
|
||||||
<sql id="selectPlayletUserVo">
|
<sql id="selectPlayletUserVo">
|
||||||
select ID, PHONE, NICK_NAME, PASSWORD, ICON, AGENCY_ID, PARENT_ID, CREATE_BY, CREATE_TIME, UPDATE_BY, UPDATE_TIME, REMARK from playlet_user
|
select ID, 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">
|
||||||
|
|
@ -84,6 +85,7 @@
|
||||||
<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="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>
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue