Merge remote-tracking branch 'origin/dm'
This commit is contained in:
commit
eaeb9876ca
39 files changed
+3860
-11
No files matched your search
@@ -59,6 +59,12 @@
|
|||||||
<dependency>
|
<dependency>
|
||||||
<groupId>cn.smartjavaai</groupId>
|
<groupId>cn.smartjavaai</groupId>
|
||||||
<artifactId>ocr</artifactId>
|
<artifactId>ocr</artifactId>
|
||||||
|
<exclusions>
|
||||||
|
<exclusion>
|
||||||
|
<groupId>org.apache.poi</groupId>
|
||||||
|
<artifactId>poi</artifactId>
|
||||||
|
</exclusion>
|
||||||
|
</exclusions>
|
||||||
</dependency>
|
</dependency>
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -140,6 +140,11 @@
|
|||||||
<artifactId>luqj-thymeleaf</artifactId>
|
<artifactId>luqj-thymeleaf</artifactId>
|
||||||
<version>3.4.0</version>
|
<version>3.4.0</version>
|
||||||
</dependency>
|
</dependency>
|
||||||
|
<dependency>
|
||||||
|
<groupId>org.apache.poi</groupId>
|
||||||
|
<artifactId>poi-ooxml</artifactId>
|
||||||
|
<version>4.1.2</version>
|
||||||
|
</dependency>
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>com.ruoyi</groupId>
|
<groupId>com.ruoyi</groupId>
|
||||||
<artifactId>luqj-common</artifactId>
|
<artifactId>luqj-common</artifactId>
|
||||||
|
|||||||
@@ -27,7 +27,7 @@ public class DmPlayerentOnlineStatusTask {
|
|||||||
Date updateTime = playerent.getUpdateTime();
|
Date updateTime = playerent.getUpdateTime();
|
||||||
if (updateTime != null) {
|
if (updateTime != null) {
|
||||||
long diff = new Date().getTime() - updateTime.getTime();
|
long diff = new Date().getTime() - updateTime.getTime();
|
||||||
if (diff > 60000) {
|
if (diff > 600000) {
|
||||||
playerent.setOnlineStatus("0");
|
playerent.setOnlineStatus("0");
|
||||||
dmPlayerentService.updateById(playerent);
|
dmPlayerentService.updateById(playerent);
|
||||||
log.info("Update playerent online status to 0, id: {}", playerent.getId());
|
log.info("Update playerent online status to 0, id: {}", playerent.getId());
|
||||||
|
|||||||
@@ -21,6 +21,16 @@
|
|||||||
<groupId>cn.afterturn</groupId>
|
<groupId>cn.afterturn</groupId>
|
||||||
<artifactId>easypoi-base</artifactId>
|
<artifactId>easypoi-base</artifactId>
|
||||||
<version>4.1.3</version>
|
<version>4.1.3</version>
|
||||||
|
<exclusions>
|
||||||
|
<exclusion>
|
||||||
|
<groupId>org.apache.poi</groupId>
|
||||||
|
<artifactId>poi</artifactId>
|
||||||
|
</exclusion>
|
||||||
|
<exclusion>
|
||||||
|
<groupId>org.apache.poi</groupId>
|
||||||
|
<artifactId>poi-ooxml-schemas</artifactId>
|
||||||
|
</exclusion>
|
||||||
|
</exclusions>
|
||||||
</dependency>
|
</dependency>
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>cn.afterturn</groupId>
|
<groupId>cn.afterturn</groupId>
|
||||||
|
|||||||
@@ -0,0 +1,82 @@
|
|||||||
|
package com.ruoyi.common.utils;
|
||||||
|
import java.nio.charset.StandardCharsets;
|
||||||
|
import java.security.MessageDigest;
|
||||||
|
import java.util.Base64;
|
||||||
|
|
||||||
|
public class TokenUtil {
|
||||||
|
|
||||||
|
private static final String SECRET = "lu7213";
|
||||||
|
|
||||||
|
public static void main(String[] args) {
|
||||||
|
String token = TokenUtil.generateToken("admin", "123456");
|
||||||
|
System.out.println(token);
|
||||||
|
}
|
||||||
|
/**
|
||||||
|
* 生成24小时token
|
||||||
|
*/
|
||||||
|
public static String generateToken(String username, String password) {
|
||||||
|
long expireAt = System.currentTimeMillis() + 24 * 60 * 60 * 1000L;
|
||||||
|
|
||||||
|
String rawCredential = Base64.getEncoder().encodeToString(
|
||||||
|
(username + ":" + password).getBytes(StandardCharsets.UTF_8)
|
||||||
|
);
|
||||||
|
|
||||||
|
String sign = md5(rawCredential + ":" + expireAt + ":" + SECRET);
|
||||||
|
|
||||||
|
String payload = rawCredential + ":" + expireAt + ":" + sign;
|
||||||
|
|
||||||
|
return Base64.getUrlEncoder()
|
||||||
|
.withoutPadding()
|
||||||
|
.encodeToString(payload.getBytes(StandardCharsets.UTF_8));
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 校验token
|
||||||
|
*/
|
||||||
|
public static boolean validateToken(String username, String password,String token) {
|
||||||
|
try {
|
||||||
|
String rawCredential = Base64.getEncoder().encodeToString(
|
||||||
|
(username + ":" + password).getBytes(StandardCharsets.UTF_8)
|
||||||
|
);
|
||||||
|
String decoded = new String(
|
||||||
|
Base64.getUrlDecoder().decode(token),
|
||||||
|
StandardCharsets.UTF_8
|
||||||
|
);
|
||||||
|
String[] parts = decoded.split(":");
|
||||||
|
if (parts.length != 3) {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
if(!parts[0].equals(rawCredential)){
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
String expireStr = parts[1];
|
||||||
|
String sign = parts[2] ;
|
||||||
|
long expireAt = Long.parseLong(expireStr);
|
||||||
|
if (System.currentTimeMillis() > expireAt) {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
String expectedSign = md5(rawCredential + ":" + expireAt + ":" + SECRET);
|
||||||
|
|
||||||
|
return expectedSign.equals(sign);
|
||||||
|
|
||||||
|
} catch (Exception e) {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private static String md5(String str) {
|
||||||
|
try {
|
||||||
|
byte[] digest = MessageDigest.getInstance("MD5")
|
||||||
|
.digest(str.getBytes(StandardCharsets.UTF_8));
|
||||||
|
|
||||||
|
StringBuilder sb = new StringBuilder();
|
||||||
|
for (byte b : digest) {
|
||||||
|
sb.append(String.format("%02x", b));
|
||||||
|
}
|
||||||
|
return sb.toString();
|
||||||
|
|
||||||
|
} catch (Exception e) {
|
||||||
|
throw new RuntimeException(e);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
+118
@@ -0,0 +1,118 @@
|
|||||||
|
package com.ruoyi.system.controller;
|
||||||
|
import com.ruoyi.common.select.Ids;
|
||||||
|
import com.ruoyi.common.select.SelectItem;
|
||||||
|
import java.util.List;
|
||||||
|
import org.springframework.security.access.prepost.PreAuthorize;
|
||||||
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
|
import org.springframework.web.bind.annotation.GetMapping;
|
||||||
|
import org.springframework.web.bind.annotation.PostMapping;
|
||||||
|
import org.springframework.web.bind.annotation.PutMapping;
|
||||||
|
import org.springframework.web.bind.annotation.DeleteMapping;
|
||||||
|
import org.springframework.web.bind.annotation.PathVariable;
|
||||||
|
import org.springframework.web.bind.annotation.RequestBody;
|
||||||
|
import org.springframework.web.bind.annotation.RequestMapping;
|
||||||
|
import org.springframework.web.bind.annotation.RestController;
|
||||||
|
import com.ruoyi.common.annotation.Log;
|
||||||
|
import com.ruoyi.common.core.controller.BaseController;
|
||||||
|
import com.ruoyi.common.core.domain.AjaxResult;
|
||||||
|
import com.ruoyi.common.enums.BusinessType;
|
||||||
|
import com.ruoyi.system.domain.DmGroupTaskRelation;
|
||||||
|
import com.ruoyi.system.domain.DmGroupTaskRelationPlus;
|
||||||
|
import com.ruoyi.system.service.IDmGroupTaskRelationService;
|
||||||
|
import com.ruoyi.common.utils.poi.ExcelUtil;
|
||||||
|
import com.ruoyi.common.core.page.TableDataInfo;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 组任务关联Controller
|
||||||
|
*
|
||||||
|
* @author luqj
|
||||||
|
* @date 2026-05-14
|
||||||
|
*/
|
||||||
|
@RestController
|
||||||
|
@RequestMapping("/system/dmgrouptaskrelation")
|
||||||
|
public class DmGroupTaskRelationController extends BaseController
|
||||||
|
{
|
||||||
|
@Autowired
|
||||||
|
private IDmGroupTaskRelationService dmGroupTaskRelationService;
|
||||||
|
@PreAuthorize("@ss.hasPermi('system:dmgrouptaskrelation:getByIds')")
|
||||||
|
@PostMapping("/getByIds")
|
||||||
|
public AjaxResult getByIds(@RequestBody Ids ids)
|
||||||
|
{
|
||||||
|
List<DmGroupTaskRelationPlus> list = dmGroupTaskRelationService.getByIds(ids.getLongIds(),DmGroupTaskRelationPlus::getPlayerName,DmGroupTaskRelationPlus::getId);
|
||||||
|
return AjaxResult.success(list);
|
||||||
|
}
|
||||||
|
@PreAuthorize("@ss.hasPermi('system:dmgrouptaskrelation:select')")
|
||||||
|
@GetMapping("/select")
|
||||||
|
public AjaxResult select(String keyword)
|
||||||
|
{
|
||||||
|
List<SelectItem> list = dmGroupTaskRelationService.select(keyword);
|
||||||
|
return AjaxResult.success(list);
|
||||||
|
}
|
||||||
|
/**
|
||||||
|
* 查询组任务关联列表
|
||||||
|
*/
|
||||||
|
@PreAuthorize("@ss.hasPermi('system:dmgrouptaskrelation:list')")
|
||||||
|
@GetMapping("/list")
|
||||||
|
public TableDataInfo list(DmGroupTaskRelation dmGroupTaskRelation)
|
||||||
|
{
|
||||||
|
startPage();
|
||||||
|
List<DmGroupTaskRelation> list = dmGroupTaskRelationService.selectDmGroupTaskRelationList(dmGroupTaskRelation);
|
||||||
|
return getDataTable(list);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 导出组任务关联列表
|
||||||
|
*/
|
||||||
|
@PreAuthorize("@ss.hasPermi('system:dmgrouptaskrelation:export')")
|
||||||
|
@Log(title = "组任务关联", businessType = BusinessType.EXPORT)
|
||||||
|
@GetMapping("/export")
|
||||||
|
public AjaxResult export(DmGroupTaskRelation dmGroupTaskRelation)
|
||||||
|
{
|
||||||
|
List<DmGroupTaskRelation> list = dmGroupTaskRelationService.selectDmGroupTaskRelationList(dmGroupTaskRelation);
|
||||||
|
ExcelUtil<DmGroupTaskRelation> util = new ExcelUtil<DmGroupTaskRelation>(DmGroupTaskRelation.class);
|
||||||
|
return util.exportExcel(list, "dmgrouptaskrelation");
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 获取组任务关联详细信息
|
||||||
|
*/
|
||||||
|
@PreAuthorize("@ss.hasPermi('system:dmgrouptaskrelation:query')")
|
||||||
|
@GetMapping(value = "/{id}")
|
||||||
|
public AjaxResult getInfo(@PathVariable("id") Long id)
|
||||||
|
{
|
||||||
|
return AjaxResult.success(dmGroupTaskRelationService.selectDmGroupTaskRelationById(id));
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 新增组任务关联
|
||||||
|
*/
|
||||||
|
@PreAuthorize("@ss.hasPermi('system:dmgrouptaskrelation:add')")
|
||||||
|
@Log(title = "组任务关联", businessType = BusinessType.INSERT)
|
||||||
|
@PostMapping
|
||||||
|
public AjaxResult add(@RequestBody DmGroupTaskRelation dmGroupTaskRelation)
|
||||||
|
{
|
||||||
|
return toAjax(dmGroupTaskRelationService.insertDmGroupTaskRelation(dmGroupTaskRelation));
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 修改组任务关联
|
||||||
|
*/
|
||||||
|
@PreAuthorize("@ss.hasPermi('system:dmgrouptaskrelation:edit')")
|
||||||
|
@Log(title = "组任务关联", businessType = BusinessType.UPDATE)
|
||||||
|
@PutMapping
|
||||||
|
public AjaxResult edit(@RequestBody DmGroupTaskRelation dmGroupTaskRelation)
|
||||||
|
{
|
||||||
|
return toAjax(dmGroupTaskRelationService.updateDmGroupTaskRelation(dmGroupTaskRelation));
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除组任务关联
|
||||||
|
*/
|
||||||
|
@PreAuthorize("@ss.hasPermi('system:dmgrouptaskrelation:remove')")
|
||||||
|
@Log(title = "组任务关联", businessType = BusinessType.DELETE)
|
||||||
|
@DeleteMapping("/{ids}")
|
||||||
|
public AjaxResult remove(@PathVariable Long[] ids)
|
||||||
|
{
|
||||||
|
return toAjax(dmGroupTaskRelationService.deleteDmGroupTaskRelationByIds(ids));
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,119 @@
|
|||||||
|
package com.ruoyi.system.controller;
|
||||||
|
import com.ruoyi.common.select.Ids;
|
||||||
|
import com.ruoyi.common.select.SelectItem;
|
||||||
|
import java.util.List;
|
||||||
|
import org.springframework.security.access.prepost.PreAuthorize;
|
||||||
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
|
import org.springframework.web.bind.annotation.*;
|
||||||
|
import com.ruoyi.common.annotation.Log;
|
||||||
|
import com.ruoyi.common.core.controller.BaseController;
|
||||||
|
import com.ruoyi.common.core.domain.AjaxResult;
|
||||||
|
import com.ruoyi.common.enums.BusinessType;
|
||||||
|
import com.ruoyi.system.domain.DmPlayerConfig;
|
||||||
|
import com.ruoyi.system.domain.DmPlayerConfigPlus;
|
||||||
|
import com.ruoyi.system.service.IDmPlayerConfigService;
|
||||||
|
import com.ruoyi.common.utils.poi.ExcelUtil;
|
||||||
|
import com.ruoyi.common.core.page.TableDataInfo;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 玩家配置Controller
|
||||||
|
*
|
||||||
|
* @author luqj
|
||||||
|
* @date 2026-05-10
|
||||||
|
*/
|
||||||
|
@RestController
|
||||||
|
@RequestMapping("/system/dmplayerconfig")
|
||||||
|
public class DmPlayerConfigController extends BaseController
|
||||||
|
{
|
||||||
|
@Autowired
|
||||||
|
private IDmPlayerConfigService dmPlayerConfigService;
|
||||||
|
@PreAuthorize("@ss.hasPermi('system:dmplayerconfig:getByIds')")
|
||||||
|
@PostMapping("/getByIds")
|
||||||
|
public AjaxResult getByIds(@RequestBody Ids ids)
|
||||||
|
{
|
||||||
|
List<DmPlayerConfigPlus> list = dmPlayerConfigService.getByIds(ids.getLongIds(),DmPlayerConfigPlus::getPlayerId,DmPlayerConfigPlus::getId);
|
||||||
|
return AjaxResult.success(list);
|
||||||
|
}
|
||||||
|
@PreAuthorize("@ss.hasPermi('system:dmplayerconfig:select')")
|
||||||
|
@GetMapping("/select")
|
||||||
|
public AjaxResult select(String keyword)
|
||||||
|
{
|
||||||
|
List<SelectItem> list = dmPlayerConfigService.select(keyword);
|
||||||
|
return AjaxResult.success(list);
|
||||||
|
}
|
||||||
|
/**
|
||||||
|
* 查询玩家配置列表
|
||||||
|
*/
|
||||||
|
@PreAuthorize("@ss.hasPermi('system:dmplayerconfig:list')")
|
||||||
|
@GetMapping("/list")
|
||||||
|
public TableDataInfo list(DmPlayerConfig dmPlayerConfig)
|
||||||
|
{
|
||||||
|
startPage();
|
||||||
|
List<DmPlayerConfig> list = dmPlayerConfigService.selectDmPlayerConfigList(dmPlayerConfig);
|
||||||
|
return getDataTable(list);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 导出玩家配置列表
|
||||||
|
*/
|
||||||
|
@PreAuthorize("@ss.hasPermi('system:dmplayerconfig:export')")
|
||||||
|
@Log(title = "玩家配置", businessType = BusinessType.EXPORT)
|
||||||
|
@GetMapping("/export")
|
||||||
|
public AjaxResult export(DmPlayerConfig dmPlayerConfig)
|
||||||
|
{
|
||||||
|
List<DmPlayerConfig> list = dmPlayerConfigService.selectDmPlayerConfigList(dmPlayerConfig);
|
||||||
|
ExcelUtil<DmPlayerConfig> util = new ExcelUtil<DmPlayerConfig>(DmPlayerConfig.class);
|
||||||
|
return util.exportExcel(list, "dmplayerconfig");
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 获取玩家配置详细信息
|
||||||
|
*/
|
||||||
|
@PreAuthorize("@ss.hasPermi('system:dmplayerconfig:query')")
|
||||||
|
@GetMapping(value = "/{id}")
|
||||||
|
public AjaxResult getInfo(@PathVariable("id") Long id)
|
||||||
|
{
|
||||||
|
return AjaxResult.success(dmPlayerConfigService.selectDmPlayerConfigById(id));
|
||||||
|
}
|
||||||
|
/**
|
||||||
|
* 获取玩家配置详细信息
|
||||||
|
*/
|
||||||
|
@PreAuthorize("@ss.hasPermi('system:dmplayerconfig:query-by-player-id')")
|
||||||
|
@GetMapping(value = "/query-by-player-id")
|
||||||
|
public AjaxResult getInfoByPlayerId(@RequestParam("id") Long id)
|
||||||
|
{
|
||||||
|
return AjaxResult.success(dmPlayerConfigService.selectDmPlayerConfigByPlayerId(id));
|
||||||
|
}
|
||||||
|
/**
|
||||||
|
* 新增玩家配置
|
||||||
|
*/
|
||||||
|
@PreAuthorize("@ss.hasPermi('system:dmplayerconfig:add')")
|
||||||
|
@Log(title = "玩家配置", businessType = BusinessType.INSERT)
|
||||||
|
@PostMapping
|
||||||
|
public AjaxResult add(@RequestBody DmPlayerConfig dmPlayerConfig)
|
||||||
|
{
|
||||||
|
return toAjax(dmPlayerConfigService.insertDmPlayerConfig(dmPlayerConfig));
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 修改玩家配置
|
||||||
|
*/
|
||||||
|
@PreAuthorize("@ss.hasPermi('system:dmplayerconfig:edit')")
|
||||||
|
@Log(title = "玩家配置", businessType = BusinessType.UPDATE)
|
||||||
|
@PutMapping
|
||||||
|
public AjaxResult edit(@RequestBody DmPlayerConfig dmPlayerConfig)
|
||||||
|
{
|
||||||
|
return toAjax(dmPlayerConfigService.updateDmPlayerConfig(dmPlayerConfig));
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除玩家配置
|
||||||
|
*/
|
||||||
|
@PreAuthorize("@ss.hasPermi('system:dmplayerconfig:remove')")
|
||||||
|
@Log(title = "玩家配置", businessType = BusinessType.DELETE)
|
||||||
|
@DeleteMapping("/{ids}")
|
||||||
|
public AjaxResult remove(@PathVariable Long[] ids)
|
||||||
|
{
|
||||||
|
return toAjax(dmPlayerConfigService.deleteDmPlayerConfigByIds(ids));
|
||||||
|
}
|
||||||
|
}
|
||||||
+118
@@ -0,0 +1,118 @@
|
|||||||
|
package com.ruoyi.system.controller;
|
||||||
|
import com.ruoyi.common.select.Ids;
|
||||||
|
import com.ruoyi.common.select.SelectItem;
|
||||||
|
import java.util.List;
|
||||||
|
import org.springframework.security.access.prepost.PreAuthorize;
|
||||||
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
|
import org.springframework.web.bind.annotation.GetMapping;
|
||||||
|
import org.springframework.web.bind.annotation.PostMapping;
|
||||||
|
import org.springframework.web.bind.annotation.PutMapping;
|
||||||
|
import org.springframework.web.bind.annotation.DeleteMapping;
|
||||||
|
import org.springframework.web.bind.annotation.PathVariable;
|
||||||
|
import org.springframework.web.bind.annotation.RequestBody;
|
||||||
|
import org.springframework.web.bind.annotation.RequestMapping;
|
||||||
|
import org.springframework.web.bind.annotation.RestController;
|
||||||
|
import com.ruoyi.common.annotation.Log;
|
||||||
|
import com.ruoyi.common.core.controller.BaseController;
|
||||||
|
import com.ruoyi.common.core.domain.AjaxResult;
|
||||||
|
import com.ruoyi.common.enums.BusinessType;
|
||||||
|
import com.ruoyi.system.domain.DmPlayerTaskGroup;
|
||||||
|
import com.ruoyi.system.domain.DmPlayerTaskGroupPlus;
|
||||||
|
import com.ruoyi.system.service.IDmPlayerTaskGroupService;
|
||||||
|
import com.ruoyi.common.utils.poi.ExcelUtil;
|
||||||
|
import com.ruoyi.common.core.page.TableDataInfo;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 大漠任务组Controller
|
||||||
|
*
|
||||||
|
* @author luqj
|
||||||
|
* @date 2026-05-14
|
||||||
|
*/
|
||||||
|
@RestController
|
||||||
|
@RequestMapping("/system/dmtaskgroup")
|
||||||
|
public class DmPlayerTaskGroupController extends BaseController
|
||||||
|
{
|
||||||
|
@Autowired
|
||||||
|
private IDmPlayerTaskGroupService dmPlayerTaskGroupService;
|
||||||
|
@PreAuthorize("@ss.hasPermi('system:dmtaskgroup:getByIds')")
|
||||||
|
@PostMapping("/getByIds")
|
||||||
|
public AjaxResult getByIds(@RequestBody Ids ids)
|
||||||
|
{
|
||||||
|
List<DmPlayerTaskGroupPlus> list = dmPlayerTaskGroupService.getByIds(ids.getLongIds(),DmPlayerTaskGroupPlus::getGroupName,DmPlayerTaskGroupPlus::getId);
|
||||||
|
return AjaxResult.success(list);
|
||||||
|
}
|
||||||
|
@PreAuthorize("@ss.hasPermi('system:dmtaskgroup:select')")
|
||||||
|
@GetMapping("/select")
|
||||||
|
public AjaxResult select(String keyword)
|
||||||
|
{
|
||||||
|
List<SelectItem> list = dmPlayerTaskGroupService.select(keyword);
|
||||||
|
return AjaxResult.success(list);
|
||||||
|
}
|
||||||
|
/**
|
||||||
|
* 查询大漠任务组列表
|
||||||
|
*/
|
||||||
|
@PreAuthorize("@ss.hasPermi('system:dmtaskgroup:list')")
|
||||||
|
@GetMapping("/list")
|
||||||
|
public TableDataInfo list(DmPlayerTaskGroup dmPlayerTaskGroup)
|
||||||
|
{
|
||||||
|
startPage();
|
||||||
|
List<DmPlayerTaskGroup> list = dmPlayerTaskGroupService.selectDmPlayerTaskGroupList(dmPlayerTaskGroup);
|
||||||
|
return getDataTable(list);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 导出大漠任务组列表
|
||||||
|
*/
|
||||||
|
@PreAuthorize("@ss.hasPermi('system:dmtaskgroup:export')")
|
||||||
|
@Log(title = "大漠任务组", businessType = BusinessType.EXPORT)
|
||||||
|
@GetMapping("/export")
|
||||||
|
public AjaxResult export(DmPlayerTaskGroup dmPlayerTaskGroup)
|
||||||
|
{
|
||||||
|
List<DmPlayerTaskGroup> list = dmPlayerTaskGroupService.selectDmPlayerTaskGroupList(dmPlayerTaskGroup);
|
||||||
|
ExcelUtil<DmPlayerTaskGroup> util = new ExcelUtil<DmPlayerTaskGroup>(DmPlayerTaskGroup.class);
|
||||||
|
return util.exportExcel(list, "dmtaskgroup");
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 获取大漠任务组详细信息
|
||||||
|
*/
|
||||||
|
@PreAuthorize("@ss.hasPermi('system:dmtaskgroup:query')")
|
||||||
|
@GetMapping(value = "/{id}")
|
||||||
|
public AjaxResult getInfo(@PathVariable("id") Long id)
|
||||||
|
{
|
||||||
|
return AjaxResult.success(dmPlayerTaskGroupService.selectDmPlayerTaskGroupById(id));
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 新增大漠任务组
|
||||||
|
*/
|
||||||
|
@PreAuthorize("@ss.hasPermi('system:dmtaskgroup:add')")
|
||||||
|
@Log(title = "大漠任务组", businessType = BusinessType.INSERT)
|
||||||
|
@PostMapping
|
||||||
|
public AjaxResult add(@RequestBody DmPlayerTaskGroup dmPlayerTaskGroup)
|
||||||
|
{
|
||||||
|
return toAjax(dmPlayerTaskGroupService.insertDmPlayerTaskGroup(dmPlayerTaskGroup));
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 修改大漠任务组
|
||||||
|
*/
|
||||||
|
@PreAuthorize("@ss.hasPermi('system:dmtaskgroup:edit')")
|
||||||
|
@Log(title = "大漠任务组", businessType = BusinessType.UPDATE)
|
||||||
|
@PutMapping
|
||||||
|
public AjaxResult edit(@RequestBody DmPlayerTaskGroup dmPlayerTaskGroup)
|
||||||
|
{
|
||||||
|
return toAjax(dmPlayerTaskGroupService.updateDmPlayerTaskGroup(dmPlayerTaskGroup));
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除大漠任务组
|
||||||
|
*/
|
||||||
|
@PreAuthorize("@ss.hasPermi('system:dmtaskgroup:remove')")
|
||||||
|
@Log(title = "大漠任务组", businessType = BusinessType.DELETE)
|
||||||
|
@DeleteMapping("/{ids}")
|
||||||
|
public AjaxResult remove(@PathVariable Long[] ids)
|
||||||
|
{
|
||||||
|
return toAjax(dmPlayerTaskGroupService.deleteDmPlayerTaskGroupByIds(ids));
|
||||||
|
}
|
||||||
|
}
|
||||||
+129
@@ -0,0 +1,129 @@
|
|||||||
|
package com.ruoyi.system.controller;
|
||||||
|
import com.ruoyi.common.select.Ids;
|
||||||
|
import com.ruoyi.common.select.SelectItem;
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
import com.ruoyi.system.domain.DmVersionUpdateVo;
|
||||||
|
import org.springframework.security.access.prepost.PreAuthorize;
|
||||||
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
|
import org.springframework.web.bind.annotation.GetMapping;
|
||||||
|
import org.springframework.web.bind.annotation.PostMapping;
|
||||||
|
import org.springframework.web.bind.annotation.PutMapping;
|
||||||
|
import org.springframework.web.bind.annotation.DeleteMapping;
|
||||||
|
import org.springframework.web.bind.annotation.PathVariable;
|
||||||
|
import org.springframework.web.bind.annotation.RequestBody;
|
||||||
|
import org.springframework.web.bind.annotation.RequestMapping;
|
||||||
|
import org.springframework.web.bind.annotation.RestController;
|
||||||
|
import com.ruoyi.common.annotation.Log;
|
||||||
|
import com.ruoyi.common.core.controller.BaseController;
|
||||||
|
import com.ruoyi.common.core.domain.AjaxResult;
|
||||||
|
import com.ruoyi.common.enums.BusinessType;
|
||||||
|
import com.ruoyi.system.domain.DmPlayerVersion;
|
||||||
|
import com.ruoyi.system.domain.DmPlayerVersionPlus;
|
||||||
|
import com.ruoyi.system.service.IDmPlayerVersionService;
|
||||||
|
import com.ruoyi.common.utils.poi.ExcelUtil;
|
||||||
|
import com.ruoyi.common.core.page.TableDataInfo;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 版本信息Controller
|
||||||
|
*
|
||||||
|
* @author luqj
|
||||||
|
* @date 2026-05-14
|
||||||
|
*/
|
||||||
|
@RestController
|
||||||
|
@RequestMapping("/system/dmversion")
|
||||||
|
public class DmPlayerVersionController extends BaseController
|
||||||
|
{
|
||||||
|
@Autowired
|
||||||
|
private IDmPlayerVersionService dmPlayerVersionService;
|
||||||
|
@PreAuthorize("@ss.hasPermi('system:dmversion:getByIds')")
|
||||||
|
@PostMapping("/getByIds")
|
||||||
|
public AjaxResult getByIds(@RequestBody Ids ids)
|
||||||
|
{
|
||||||
|
List<DmPlayerVersionPlus> list = dmPlayerVersionService.getByIds(ids.getLongIds(),DmPlayerVersionPlus::getTitle,DmPlayerVersionPlus::getId);
|
||||||
|
return AjaxResult.success(list);
|
||||||
|
}
|
||||||
|
@PreAuthorize("@ss.hasPermi('system:dmversion:select')")
|
||||||
|
@GetMapping("/select")
|
||||||
|
public AjaxResult select(String keyword)
|
||||||
|
{
|
||||||
|
List<SelectItem> list = dmPlayerVersionService.select(keyword);
|
||||||
|
return AjaxResult.success(list);
|
||||||
|
}
|
||||||
|
/**
|
||||||
|
* 查询版本信息列表
|
||||||
|
*/
|
||||||
|
@PreAuthorize("@ss.hasPermi('system:dmversion:list')")
|
||||||
|
@GetMapping("/list")
|
||||||
|
public TableDataInfo list(DmPlayerVersion dmPlayerVersion)
|
||||||
|
{
|
||||||
|
startPage();
|
||||||
|
List<DmPlayerVersion> list = dmPlayerVersionService.selectDmPlayerVersionList(dmPlayerVersion);
|
||||||
|
return getDataTable(list);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 导出版本信息列表
|
||||||
|
*/
|
||||||
|
@PreAuthorize("@ss.hasPermi('system:dmversion:export')")
|
||||||
|
@Log(title = "版本信息", businessType = BusinessType.EXPORT)
|
||||||
|
@GetMapping("/export")
|
||||||
|
public AjaxResult export(DmPlayerVersion dmPlayerVersion)
|
||||||
|
{
|
||||||
|
List<DmPlayerVersion> list = dmPlayerVersionService.selectDmPlayerVersionList(dmPlayerVersion);
|
||||||
|
ExcelUtil<DmPlayerVersion> util = new ExcelUtil<DmPlayerVersion>(DmPlayerVersion.class);
|
||||||
|
return util.exportExcel(list, "dmversion");
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 获取版本信息详细信息
|
||||||
|
*/
|
||||||
|
@PreAuthorize("@ss.hasPermi('system:dmversion:query')")
|
||||||
|
@GetMapping(value = "/{id}")
|
||||||
|
public AjaxResult getInfo(@PathVariable("id") Long id)
|
||||||
|
{
|
||||||
|
return AjaxResult.success(dmPlayerVersionService.selectDmPlayerVersionById(id));
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 新增版本信息
|
||||||
|
*/
|
||||||
|
@PreAuthorize("@ss.hasPermi('system:dmversion:add')")
|
||||||
|
@Log(title = "版本信息", businessType = BusinessType.INSERT)
|
||||||
|
@PostMapping
|
||||||
|
public AjaxResult add(@RequestBody DmPlayerVersion dmPlayerVersion)
|
||||||
|
{
|
||||||
|
return toAjax(dmPlayerVersionService.insertDmPlayerVersion(dmPlayerVersion));
|
||||||
|
}
|
||||||
|
/**
|
||||||
|
* 新增版本信息
|
||||||
|
*/
|
||||||
|
@PreAuthorize("@ss.hasPermi('system:dmversion:playerent-update')")
|
||||||
|
@Log(title = "版本信息", businessType = BusinessType.INSERT)
|
||||||
|
@PostMapping("playerent-update")
|
||||||
|
public AjaxResult playerentUpdate(@RequestBody DmVersionUpdateVo vo)
|
||||||
|
{
|
||||||
|
return toAjax(dmPlayerVersionService.playerentUpdate(vo));
|
||||||
|
}
|
||||||
|
/**
|
||||||
|
* 修改版本信息
|
||||||
|
*/
|
||||||
|
@PreAuthorize("@ss.hasPermi('system:dmversion:edit')")
|
||||||
|
@Log(title = "版本信息", businessType = BusinessType.UPDATE)
|
||||||
|
@PutMapping
|
||||||
|
public AjaxResult edit(@RequestBody DmPlayerVersion dmPlayerVersion)
|
||||||
|
{
|
||||||
|
return toAjax(dmPlayerVersionService.updateDmPlayerVersion(dmPlayerVersion));
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除版本信息
|
||||||
|
*/
|
||||||
|
@PreAuthorize("@ss.hasPermi('system:dmversion:remove')")
|
||||||
|
@Log(title = "版本信息", businessType = BusinessType.DELETE)
|
||||||
|
@DeleteMapping("/{ids}")
|
||||||
|
public AjaxResult remove(@PathVariable Long[] ids)
|
||||||
|
{
|
||||||
|
return toAjax(dmPlayerVersionService.deleteDmPlayerVersionByIds(ids));
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,172 @@
|
|||||||
|
package com.ruoyi.system.domain;
|
||||||
|
|
||||||
|
import org.apache.commons.lang3.builder.ToStringBuilder;
|
||||||
|
import org.apache.commons.lang3.builder.ToStringStyle;
|
||||||
|
import com.ruoyi.common.annotation.Excel;
|
||||||
|
import com.ruoyi.common.core.domain.BaseEntity;
|
||||||
|
import java.io.Serializable;
|
||||||
|
/**
|
||||||
|
* 组任务关联对象 dm_group_task_relation
|
||||||
|
*
|
||||||
|
* @author luqj
|
||||||
|
* @date 2026-05-14
|
||||||
|
*/
|
||||||
|
public class DmGroupTaskRelation extends BaseEntity
|
||||||
|
{
|
||||||
|
private static final long serialVersionUID = 1L;
|
||||||
|
|
||||||
|
/** 主键 */
|
||||||
|
private Long id;
|
||||||
|
|
||||||
|
/** 组ID */
|
||||||
|
@Excel(name = "组ID")
|
||||||
|
private Long groupId;
|
||||||
|
|
||||||
|
/** 玩家ID */
|
||||||
|
@Excel(name = "玩家ID")
|
||||||
|
private Long playerId;
|
||||||
|
|
||||||
|
/** 名称 */
|
||||||
|
@Excel(name = "名称")
|
||||||
|
private String playerName;
|
||||||
|
|
||||||
|
/** 用户ID */
|
||||||
|
@Excel(name = "用户ID")
|
||||||
|
private Long accountId;
|
||||||
|
|
||||||
|
/** 第几个窗口 */
|
||||||
|
@Excel(name = "第几个窗口")
|
||||||
|
private Long windowIndex;
|
||||||
|
|
||||||
|
/** 窗口句柄 */
|
||||||
|
@Excel(name = "窗口句柄")
|
||||||
|
private Long windowHwnd;
|
||||||
|
|
||||||
|
/** 是否主控号 */
|
||||||
|
@Excel(name = "是否主控号")
|
||||||
|
private Integer isMaster;
|
||||||
|
|
||||||
|
/** 状态 */
|
||||||
|
@Excel(name = "状态")
|
||||||
|
private Integer status;
|
||||||
|
@Excel(name = "x")
|
||||||
|
private Integer x;
|
||||||
|
|
||||||
|
@Excel(name = "y")
|
||||||
|
private Integer y;
|
||||||
|
|
||||||
|
public Integer getX() {
|
||||||
|
return x;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setX(Integer x) {
|
||||||
|
this.x = x;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Integer getY() {
|
||||||
|
return y;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setY(Integer y) {
|
||||||
|
this.y = y;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setId(Long id)
|
||||||
|
{
|
||||||
|
this.id = id;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Long getId()
|
||||||
|
{
|
||||||
|
return id;
|
||||||
|
}
|
||||||
|
public void setGroupId(Long groupId)
|
||||||
|
{
|
||||||
|
this.groupId = groupId;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Long getGroupId()
|
||||||
|
{
|
||||||
|
return groupId;
|
||||||
|
}
|
||||||
|
public void setPlayerId(Long playerId)
|
||||||
|
{
|
||||||
|
this.playerId = playerId;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Long getPlayerId()
|
||||||
|
{
|
||||||
|
return playerId;
|
||||||
|
}
|
||||||
|
public void setPlayerName(String playerName)
|
||||||
|
{
|
||||||
|
this.playerName = playerName;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getPlayerName()
|
||||||
|
{
|
||||||
|
return playerName;
|
||||||
|
}
|
||||||
|
public void setAccountId(Long accountId)
|
||||||
|
{
|
||||||
|
this.accountId = accountId;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Long getAccountId()
|
||||||
|
{
|
||||||
|
return accountId;
|
||||||
|
}
|
||||||
|
public void setWindowIndex(Long windowIndex)
|
||||||
|
{
|
||||||
|
this.windowIndex = windowIndex;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Long getWindowIndex()
|
||||||
|
{
|
||||||
|
return windowIndex;
|
||||||
|
}
|
||||||
|
public void setWindowHwnd(Long windowHwnd)
|
||||||
|
{
|
||||||
|
this.windowHwnd = windowHwnd;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Long getWindowHwnd()
|
||||||
|
{
|
||||||
|
return windowHwnd;
|
||||||
|
}
|
||||||
|
public void setIsMaster(Integer isMaster)
|
||||||
|
{
|
||||||
|
this.isMaster = isMaster;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Integer getIsMaster()
|
||||||
|
{
|
||||||
|
return isMaster;
|
||||||
|
}
|
||||||
|
public void setStatus(Integer status)
|
||||||
|
{
|
||||||
|
this.status = status;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Integer getStatus()
|
||||||
|
{
|
||||||
|
return status;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public String toString() {
|
||||||
|
return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
|
||||||
|
.append("id", getId())
|
||||||
|
.append("groupId", getGroupId())
|
||||||
|
.append("playerId", getPlayerId())
|
||||||
|
.append("playerName", getPlayerName())
|
||||||
|
.append("accountId", getAccountId())
|
||||||
|
.append("windowIndex", getWindowIndex())
|
||||||
|
.append("windowHwnd", getWindowHwnd())
|
||||||
|
.append("isMaster", getIsMaster())
|
||||||
|
.append("status", getStatus())
|
||||||
|
.append("createTime", getCreateTime())
|
||||||
|
.append("updateTime", getUpdateTime())
|
||||||
|
.toString();
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,188 @@
|
|||||||
|
package com.ruoyi.system.domain;
|
||||||
|
|
||||||
|
import org.apache.commons.lang3.builder.ToStringBuilder;
|
||||||
|
import org.apache.commons.lang3.builder.ToStringStyle;
|
||||||
|
import com.ruoyi.common.annotation.Excel;
|
||||||
|
import com.ruoyi.common.core.domain.BaseEntity;
|
||||||
|
import java.io.Serializable;
|
||||||
|
import java.util.Date;
|
||||||
|
import com.baomidou.mybatisplus.annotation.TableName;
|
||||||
|
/**
|
||||||
|
* 组任务关联对象 dm_group_task_relation
|
||||||
|
*
|
||||||
|
* @author luqj
|
||||||
|
* @date 2026-05-14
|
||||||
|
*/
|
||||||
|
@TableName(value = "dm_group_task_relation")
|
||||||
|
public class DmGroupTaskRelationPlus implements Serializable
|
||||||
|
{
|
||||||
|
private static final long serialVersionUID = 1L;
|
||||||
|
|
||||||
|
/** 主键 */
|
||||||
|
private Long id;
|
||||||
|
/** 组ID */
|
||||||
|
@Excel(name = "组ID")
|
||||||
|
private Long groupId;
|
||||||
|
/** 玩家ID */
|
||||||
|
@Excel(name = "玩家ID")
|
||||||
|
private Long playerId;
|
||||||
|
/** 名称 */
|
||||||
|
@Excel(name = "名称")
|
||||||
|
private String playerName;
|
||||||
|
/** 用户ID */
|
||||||
|
@Excel(name = "用户ID")
|
||||||
|
private Long accountId;
|
||||||
|
/** 第几个窗口 */
|
||||||
|
@Excel(name = "第几个窗口")
|
||||||
|
private Long windowIndex;
|
||||||
|
/** 窗口句柄 */
|
||||||
|
@Excel(name = "窗口句柄")
|
||||||
|
private Long windowHwnd;
|
||||||
|
/** 是否主控号 */
|
||||||
|
@Excel(name = "是否主控号")
|
||||||
|
private Integer isMaster;
|
||||||
|
/** 状态 */
|
||||||
|
@Excel(name = "状态")
|
||||||
|
private Integer status;
|
||||||
|
@Excel(name = "x")
|
||||||
|
private Integer x;
|
||||||
|
|
||||||
|
@Excel(name = "y")
|
||||||
|
private Integer y;
|
||||||
|
/** 创建时间 */
|
||||||
|
private Date createTime;
|
||||||
|
/** 更新时间 */
|
||||||
|
private Date updateTime;
|
||||||
|
public void setId(Long id)
|
||||||
|
{
|
||||||
|
this.id = id;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Integer getX() {
|
||||||
|
return x;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setX(Integer x) {
|
||||||
|
this.x = x;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Integer getY() {
|
||||||
|
return y;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setY(Integer y) {
|
||||||
|
this.y = y;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Long getId()
|
||||||
|
{
|
||||||
|
return id;
|
||||||
|
}
|
||||||
|
public void setGroupId(Long groupId)
|
||||||
|
{
|
||||||
|
this.groupId = groupId;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Long getGroupId()
|
||||||
|
{
|
||||||
|
return groupId;
|
||||||
|
}
|
||||||
|
public void setPlayerId(Long playerId)
|
||||||
|
{
|
||||||
|
this.playerId = playerId;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Long getPlayerId()
|
||||||
|
{
|
||||||
|
return playerId;
|
||||||
|
}
|
||||||
|
public void setPlayerName(String playerName)
|
||||||
|
{
|
||||||
|
this.playerName = playerName;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getPlayerName()
|
||||||
|
{
|
||||||
|
return playerName;
|
||||||
|
}
|
||||||
|
public void setAccountId(Long accountId)
|
||||||
|
{
|
||||||
|
this.accountId = accountId;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Long getAccountId()
|
||||||
|
{
|
||||||
|
return accountId;
|
||||||
|
}
|
||||||
|
public void setWindowIndex(Long windowIndex)
|
||||||
|
{
|
||||||
|
this.windowIndex = windowIndex;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Long getWindowIndex()
|
||||||
|
{
|
||||||
|
return windowIndex;
|
||||||
|
}
|
||||||
|
public void setWindowHwnd(Long windowHwnd)
|
||||||
|
{
|
||||||
|
this.windowHwnd = windowHwnd;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Long getWindowHwnd()
|
||||||
|
{
|
||||||
|
return windowHwnd;
|
||||||
|
}
|
||||||
|
public void setIsMaster(Integer isMaster)
|
||||||
|
{
|
||||||
|
this.isMaster = isMaster;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Integer getIsMaster()
|
||||||
|
{
|
||||||
|
return isMaster;
|
||||||
|
}
|
||||||
|
public void setStatus(Integer status)
|
||||||
|
{
|
||||||
|
this.status = status;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Integer getStatus()
|
||||||
|
{
|
||||||
|
return status;
|
||||||
|
}
|
||||||
|
public void setCreateTime(Date createTime)
|
||||||
|
{
|
||||||
|
this.createTime = createTime;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Date getCreateTime()
|
||||||
|
{
|
||||||
|
return createTime;
|
||||||
|
}
|
||||||
|
public void setUpdateTime(Date updateTime)
|
||||||
|
{
|
||||||
|
this.updateTime = updateTime;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Date getUpdateTime()
|
||||||
|
{
|
||||||
|
return updateTime;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public String toString() {
|
||||||
|
return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
|
||||||
|
.append("id", getId())
|
||||||
|
.append("groupId", getGroupId())
|
||||||
|
.append("playerId", getPlayerId())
|
||||||
|
.append("playerName", getPlayerName())
|
||||||
|
.append("accountId", getAccountId())
|
||||||
|
.append("windowIndex", getWindowIndex())
|
||||||
|
.append("windowHwnd", getWindowHwnd())
|
||||||
|
.append("isMaster", getIsMaster())
|
||||||
|
.append("status", getStatus())
|
||||||
|
.append("createTime", getCreateTime())
|
||||||
|
.append("updateTime", getUpdateTime())
|
||||||
|
.toString();
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -12,4 +12,7 @@ public class DmOperateVo implements Serializable {
|
|||||||
private String winId;
|
private String winId;
|
||||||
private Integer operateType;
|
private Integer operateType;
|
||||||
private Integer type;
|
private Integer type;
|
||||||
|
private Integer x;
|
||||||
|
private Integer y;
|
||||||
|
private Long versionId;
|
||||||
}
|
}
|
||||||
@@ -0,0 +1,174 @@
|
|||||||
|
package com.ruoyi.system.domain;
|
||||||
|
|
||||||
|
import org.apache.commons.lang3.builder.ToStringBuilder;
|
||||||
|
import org.apache.commons.lang3.builder.ToStringStyle;
|
||||||
|
import com.ruoyi.common.annotation.Excel;
|
||||||
|
import com.ruoyi.common.core.domain.BaseEntity;
|
||||||
|
import java.io.Serializable;
|
||||||
|
/**
|
||||||
|
* 玩家配置对象 dm_player_config
|
||||||
|
*
|
||||||
|
* @author luqj
|
||||||
|
* @date 2026-05-10
|
||||||
|
*/
|
||||||
|
public class DmPlayerConfig extends BaseEntity
|
||||||
|
{
|
||||||
|
private static final long serialVersionUID = 1L;
|
||||||
|
|
||||||
|
/** 主键 */
|
||||||
|
private Long id;
|
||||||
|
|
||||||
|
/** 玩家ID */
|
||||||
|
@Excel(name = "玩家ID")
|
||||||
|
private Long playerId;
|
||||||
|
|
||||||
|
/** 喊话间隔 */
|
||||||
|
@Excel(name = "喊话间隔")
|
||||||
|
private Integer shoutInterval;
|
||||||
|
|
||||||
|
/** 喊话蓝量 */
|
||||||
|
@Excel(name = "喊话蓝量")
|
||||||
|
private Integer shoutMana;
|
||||||
|
@Excel(name = "喊话编码 对应按键值表")
|
||||||
|
private Integer shoutKey;
|
||||||
|
/** 是否自动加蓝 */
|
||||||
|
@Excel(name = "是否自动加蓝")
|
||||||
|
private Integer autoAddMana;
|
||||||
|
|
||||||
|
/** 加蓝阈值 */
|
||||||
|
@Excel(name = "加蓝阈值")
|
||||||
|
private Integer addManaThreshold;
|
||||||
|
|
||||||
|
/** 识别高度 */
|
||||||
|
@Excel(name = "识别高度")
|
||||||
|
private Integer yoloHeight;
|
||||||
|
|
||||||
|
/** 识别宽度 */
|
||||||
|
@Excel(name = "识别宽度")
|
||||||
|
private Integer yoloWidth;
|
||||||
|
|
||||||
|
/** 自定义参数 */
|
||||||
|
@Excel(name = "自定义参数")
|
||||||
|
private String customParams;
|
||||||
|
|
||||||
|
/** 固定方位 */
|
||||||
|
@Excel(name = "固定方位")
|
||||||
|
private Integer fixedDirection;
|
||||||
|
|
||||||
|
public void setId(Long id)
|
||||||
|
{
|
||||||
|
this.id = id;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Long getId()
|
||||||
|
{
|
||||||
|
return id;
|
||||||
|
}
|
||||||
|
public void setPlayerId(Long playerId)
|
||||||
|
{
|
||||||
|
this.playerId = playerId;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Long getPlayerId()
|
||||||
|
{
|
||||||
|
return playerId;
|
||||||
|
}
|
||||||
|
public void setShoutInterval(Integer shoutInterval)
|
||||||
|
{
|
||||||
|
this.shoutInterval = shoutInterval;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Integer getShoutInterval()
|
||||||
|
{
|
||||||
|
return shoutInterval;
|
||||||
|
}
|
||||||
|
public void setShoutMana(Integer shoutMana)
|
||||||
|
{
|
||||||
|
this.shoutMana = shoutMana;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Integer getShoutMana()
|
||||||
|
{
|
||||||
|
return shoutMana;
|
||||||
|
}
|
||||||
|
public void setAutoAddMana(Integer autoAddMana)
|
||||||
|
{
|
||||||
|
this.autoAddMana = autoAddMana;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Integer getAutoAddMana()
|
||||||
|
{
|
||||||
|
return autoAddMana;
|
||||||
|
}
|
||||||
|
public void setAddManaThreshold(Integer addManaThreshold)
|
||||||
|
{
|
||||||
|
this.addManaThreshold = addManaThreshold;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Integer getAddManaThreshold()
|
||||||
|
{
|
||||||
|
return addManaThreshold;
|
||||||
|
}
|
||||||
|
public void setYoloHeight(Integer yoloHeight)
|
||||||
|
{
|
||||||
|
this.yoloHeight = yoloHeight;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Integer getYoloHeight()
|
||||||
|
{
|
||||||
|
return yoloHeight;
|
||||||
|
}
|
||||||
|
public void setYoloWidth(Integer yoloWidth)
|
||||||
|
{
|
||||||
|
this.yoloWidth = yoloWidth;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Integer getYoloWidth()
|
||||||
|
{
|
||||||
|
return yoloWidth;
|
||||||
|
}
|
||||||
|
public void setCustomParams(String customParams)
|
||||||
|
{
|
||||||
|
this.customParams = customParams;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getCustomParams()
|
||||||
|
{
|
||||||
|
return customParams;
|
||||||
|
}
|
||||||
|
public void setFixedDirection(Integer fixedDirection)
|
||||||
|
{
|
||||||
|
this.fixedDirection = fixedDirection;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Integer getFixedDirection()
|
||||||
|
{
|
||||||
|
return fixedDirection;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Integer getShoutKey() {
|
||||||
|
return shoutKey;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setShoutKey(Integer shoutKey) {
|
||||||
|
this.shoutKey = shoutKey;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public String toString() {
|
||||||
|
return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
|
||||||
|
.append("id", getId())
|
||||||
|
.append("playerId", getPlayerId())
|
||||||
|
.append("createTime", getCreateTime())
|
||||||
|
.append("updateTime", getUpdateTime())
|
||||||
|
.append("shoutInterval", getShoutInterval())
|
||||||
|
.append("shoutMana", getShoutMana())
|
||||||
|
.append("autoAddMana", getAutoAddMana())
|
||||||
|
.append("addManaThreshold", getAddManaThreshold())
|
||||||
|
.append("yoloHeight", getYoloHeight())
|
||||||
|
.append("yoloWidth", getYoloWidth())
|
||||||
|
.append("customParams", getCustomParams())
|
||||||
|
.append("fixedDirection", getFixedDirection())
|
||||||
|
.toString();
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,203 @@
|
|||||||
|
package com.ruoyi.system.domain;
|
||||||
|
|
||||||
|
import org.apache.commons.lang3.builder.ToStringBuilder;
|
||||||
|
import org.apache.commons.lang3.builder.ToStringStyle;
|
||||||
|
import com.ruoyi.common.annotation.Excel;
|
||||||
|
import com.ruoyi.common.core.domain.BaseEntity;
|
||||||
|
import java.io.Serializable;
|
||||||
|
import java.util.Date;
|
||||||
|
import com.baomidou.mybatisplus.annotation.TableName;
|
||||||
|
/**
|
||||||
|
* 玩家配置对象 dm_player_config
|
||||||
|
*
|
||||||
|
* @author luqj
|
||||||
|
* @date 2026-05-10
|
||||||
|
*/
|
||||||
|
@TableName(value = "dm_player_config")
|
||||||
|
public class DmPlayerConfigPlus implements Serializable
|
||||||
|
{
|
||||||
|
private static final long serialVersionUID = 1L;
|
||||||
|
|
||||||
|
/** 主键 */
|
||||||
|
private Long id;
|
||||||
|
/** 玩家ID */
|
||||||
|
@Excel(name = "玩家ID")
|
||||||
|
private Long playerId;
|
||||||
|
/** 创建时间 */
|
||||||
|
private Date createTime;
|
||||||
|
/** 更新时间 */
|
||||||
|
private Date updateTime;
|
||||||
|
/** 喊话间隔 */
|
||||||
|
@Excel(name = "喊话间隔")
|
||||||
|
private Integer shoutInterval;
|
||||||
|
/** 喊话蓝量 */
|
||||||
|
@Excel(name = "喊话蓝量")
|
||||||
|
private Integer shoutMana;
|
||||||
|
/** 是否自动加蓝 */
|
||||||
|
@Excel(name = "是否自动加蓝")
|
||||||
|
private Integer autoAddMana;
|
||||||
|
/** 加蓝阈值 */
|
||||||
|
@Excel(name = "加蓝阈值")
|
||||||
|
private Integer addManaThreshold;
|
||||||
|
/** 识别高度 */
|
||||||
|
@Excel(name = "识别高度")
|
||||||
|
private Integer yoloHeight;
|
||||||
|
/** 识别宽度 */
|
||||||
|
@Excel(name = "识别宽度")
|
||||||
|
private Integer yoloWidth;
|
||||||
|
/** 自定义参数 */
|
||||||
|
@Excel(name = "自定义参数")
|
||||||
|
private String customParams;
|
||||||
|
/** 固定方位
|
||||||
|
* <el-option label="所有" :value="0" />
|
||||||
|
* <el-option label="斜四个方位" :value="9" />
|
||||||
|
* <el-option label="除了上" :value="10" />
|
||||||
|
* <el-option label="上" :value="1" />
|
||||||
|
* <el-option label="下" :value="2" />
|
||||||
|
* <el-option label="左" :value="3" />
|
||||||
|
* <el-option label="右" :value="4" />
|
||||||
|
* <el-option label="左上" :value="5" />
|
||||||
|
* <el-option label="右上" :value="6" />
|
||||||
|
* <el-option label="左下" :value="7" />
|
||||||
|
* <el-option label="右下" :value="8" />
|
||||||
|
* */
|
||||||
|
@Excel(name = "固定方位")
|
||||||
|
private Integer fixedDirection;
|
||||||
|
@Excel(name = "喊话编码 对应按键值表")
|
||||||
|
private Integer shoutKey;
|
||||||
|
|
||||||
|
public Integer getShoutKey() {
|
||||||
|
return shoutKey;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setShoutKey(Integer shoutKey) {
|
||||||
|
this.shoutKey = shoutKey;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setId(Long id)
|
||||||
|
{
|
||||||
|
this.id = id;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Long getId()
|
||||||
|
{
|
||||||
|
return id;
|
||||||
|
}
|
||||||
|
public void setPlayerId(Long playerId)
|
||||||
|
{
|
||||||
|
this.playerId = playerId;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Long getPlayerId()
|
||||||
|
{
|
||||||
|
return playerId;
|
||||||
|
}
|
||||||
|
public void setCreateTime(Date createTime)
|
||||||
|
{
|
||||||
|
this.createTime = createTime;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Date getCreateTime()
|
||||||
|
{
|
||||||
|
return createTime;
|
||||||
|
}
|
||||||
|
public void setUpdateTime(Date updateTime)
|
||||||
|
{
|
||||||
|
this.updateTime = updateTime;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Date getUpdateTime()
|
||||||
|
{
|
||||||
|
return updateTime;
|
||||||
|
}
|
||||||
|
public void setShoutInterval(Integer shoutInterval)
|
||||||
|
{
|
||||||
|
this.shoutInterval = shoutInterval;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Integer getShoutInterval()
|
||||||
|
{
|
||||||
|
return shoutInterval;
|
||||||
|
}
|
||||||
|
public void setShoutMana(Integer shoutMana)
|
||||||
|
{
|
||||||
|
this.shoutMana = shoutMana;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Integer getShoutMana()
|
||||||
|
{
|
||||||
|
return shoutMana;
|
||||||
|
}
|
||||||
|
public void setAutoAddMana(Integer autoAddMana)
|
||||||
|
{
|
||||||
|
this.autoAddMana = autoAddMana;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Integer getAutoAddMana()
|
||||||
|
{
|
||||||
|
return autoAddMana;
|
||||||
|
}
|
||||||
|
public void setAddManaThreshold(Integer addManaThreshold)
|
||||||
|
{
|
||||||
|
this.addManaThreshold = addManaThreshold;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Integer getAddManaThreshold()
|
||||||
|
{
|
||||||
|
return addManaThreshold;
|
||||||
|
}
|
||||||
|
public void setYoloHeight(Integer yoloHeight)
|
||||||
|
{
|
||||||
|
this.yoloHeight = yoloHeight;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Integer getYoloHeight()
|
||||||
|
{
|
||||||
|
return yoloHeight;
|
||||||
|
}
|
||||||
|
public void setYoloWidth(Integer yoloWidth)
|
||||||
|
{
|
||||||
|
this.yoloWidth = yoloWidth;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Integer getYoloWidth()
|
||||||
|
{
|
||||||
|
return yoloWidth;
|
||||||
|
}
|
||||||
|
public void setCustomParams(String customParams)
|
||||||
|
{
|
||||||
|
this.customParams = customParams;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getCustomParams()
|
||||||
|
{
|
||||||
|
return customParams;
|
||||||
|
}
|
||||||
|
public void setFixedDirection(Integer fixedDirection)
|
||||||
|
{
|
||||||
|
this.fixedDirection = fixedDirection;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Integer getFixedDirection()
|
||||||
|
{
|
||||||
|
return fixedDirection;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public String toString() {
|
||||||
|
return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
|
||||||
|
.append("id", getId())
|
||||||
|
.append("playerId", getPlayerId())
|
||||||
|
.append("createTime", getCreateTime())
|
||||||
|
.append("updateTime", getUpdateTime())
|
||||||
|
.append("shoutInterval", getShoutInterval())
|
||||||
|
.append("shoutMana", getShoutMana())
|
||||||
|
.append("autoAddMana", getAutoAddMana())
|
||||||
|
.append("addManaThreshold", getAddManaThreshold())
|
||||||
|
.append("yoloHeight", getYoloHeight())
|
||||||
|
.append("yoloWidth", getYoloWidth())
|
||||||
|
.append("customParams", getCustomParams())
|
||||||
|
.append("fixedDirection", getFixedDirection())
|
||||||
|
.toString();
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,96 @@
|
|||||||
|
package com.ruoyi.system.domain;
|
||||||
|
|
||||||
|
import org.apache.commons.lang3.builder.ToStringBuilder;
|
||||||
|
import org.apache.commons.lang3.builder.ToStringStyle;
|
||||||
|
import com.ruoyi.common.annotation.Excel;
|
||||||
|
import com.ruoyi.common.core.domain.BaseEntity;
|
||||||
|
import java.io.Serializable;
|
||||||
|
/**
|
||||||
|
* 大漠任务组对象 dm_player_task_group
|
||||||
|
*
|
||||||
|
* @author luqj
|
||||||
|
* @date 2026-05-14
|
||||||
|
*/
|
||||||
|
public class DmPlayerTaskGroup extends BaseEntity
|
||||||
|
{
|
||||||
|
private static final long serialVersionUID = 1L;
|
||||||
|
|
||||||
|
/** 主键 */
|
||||||
|
private Long id;
|
||||||
|
|
||||||
|
/** 组编号 */
|
||||||
|
@Excel(name = "组编号")
|
||||||
|
private String groupCode;
|
||||||
|
|
||||||
|
/** 组名称 */
|
||||||
|
@Excel(name = "组名称")
|
||||||
|
private String groupName;
|
||||||
|
|
||||||
|
/** 类型 0 加速 */
|
||||||
|
@Excel(name = "类型 0 加速")
|
||||||
|
private Integer type;
|
||||||
|
|
||||||
|
/** 状态 */
|
||||||
|
@Excel(name = "状态")
|
||||||
|
private Integer status;
|
||||||
|
|
||||||
|
public void setId(Long id)
|
||||||
|
{
|
||||||
|
this.id = id;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Long getId()
|
||||||
|
{
|
||||||
|
return id;
|
||||||
|
}
|
||||||
|
public void setGroupCode(String groupCode)
|
||||||
|
{
|
||||||
|
this.groupCode = groupCode;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getGroupCode()
|
||||||
|
{
|
||||||
|
return groupCode;
|
||||||
|
}
|
||||||
|
public void setGroupName(String groupName)
|
||||||
|
{
|
||||||
|
this.groupName = groupName;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getGroupName()
|
||||||
|
{
|
||||||
|
return groupName;
|
||||||
|
}
|
||||||
|
public void setType(Integer type)
|
||||||
|
{
|
||||||
|
this.type = type;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Integer getType()
|
||||||
|
{
|
||||||
|
return type;
|
||||||
|
}
|
||||||
|
public void setStatus(Integer status)
|
||||||
|
{
|
||||||
|
this.status = status;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Integer getStatus()
|
||||||
|
{
|
||||||
|
return status;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public String toString() {
|
||||||
|
return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
|
||||||
|
.append("id", getId())
|
||||||
|
.append("groupCode", getGroupCode())
|
||||||
|
.append("groupName", getGroupName())
|
||||||
|
.append("type", getType())
|
||||||
|
.append("status", getStatus())
|
||||||
|
.append("remark", getRemark())
|
||||||
|
.append("createTime", getCreateTime())
|
||||||
|
.append("updateTime", getUpdateTime())
|
||||||
|
.toString();
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,128 @@
|
|||||||
|
package com.ruoyi.system.domain;
|
||||||
|
|
||||||
|
import org.apache.commons.lang3.builder.ToStringBuilder;
|
||||||
|
import org.apache.commons.lang3.builder.ToStringStyle;
|
||||||
|
import com.ruoyi.common.annotation.Excel;
|
||||||
|
import com.ruoyi.common.core.domain.BaseEntity;
|
||||||
|
import java.io.Serializable;
|
||||||
|
import java.util.Date;
|
||||||
|
import com.baomidou.mybatisplus.annotation.TableName;
|
||||||
|
/**
|
||||||
|
* 大漠任务组对象 dm_player_task_group
|
||||||
|
*
|
||||||
|
* @author luqj
|
||||||
|
* @date 2026-05-14
|
||||||
|
*/
|
||||||
|
@TableName(value = "dm_player_task_group")
|
||||||
|
public class DmPlayerTaskGroupPlus implements Serializable
|
||||||
|
{
|
||||||
|
private static final long serialVersionUID = 1L;
|
||||||
|
|
||||||
|
/** 主键 */
|
||||||
|
private Long id;
|
||||||
|
/** 组编号 */
|
||||||
|
@Excel(name = "组编号")
|
||||||
|
private String groupCode;
|
||||||
|
/** 组名称 */
|
||||||
|
@Excel(name = "组名称")
|
||||||
|
private String groupName;
|
||||||
|
/** 类型 0 加速 */
|
||||||
|
@Excel(name = "类型 0 加速")
|
||||||
|
private Integer type;
|
||||||
|
/** 状态 */
|
||||||
|
@Excel(name = "状态")
|
||||||
|
private Integer status;
|
||||||
|
/** 备注 */
|
||||||
|
@Excel(name = "备注")
|
||||||
|
private String remark;
|
||||||
|
/** 创建时间 */
|
||||||
|
private Date createTime;
|
||||||
|
/** 更新时间 */
|
||||||
|
private Date updateTime;
|
||||||
|
public void setId(Long id)
|
||||||
|
{
|
||||||
|
this.id = id;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Long getId()
|
||||||
|
{
|
||||||
|
return id;
|
||||||
|
}
|
||||||
|
public void setGroupCode(String groupCode)
|
||||||
|
{
|
||||||
|
this.groupCode = groupCode;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getGroupCode()
|
||||||
|
{
|
||||||
|
return groupCode;
|
||||||
|
}
|
||||||
|
public void setGroupName(String groupName)
|
||||||
|
{
|
||||||
|
this.groupName = groupName;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getGroupName()
|
||||||
|
{
|
||||||
|
return groupName;
|
||||||
|
}
|
||||||
|
public void setType(Integer type)
|
||||||
|
{
|
||||||
|
this.type = type;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Integer getType()
|
||||||
|
{
|
||||||
|
return type;
|
||||||
|
}
|
||||||
|
public void setStatus(Integer status)
|
||||||
|
{
|
||||||
|
this.status = status;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Integer getStatus()
|
||||||
|
{
|
||||||
|
return status;
|
||||||
|
}
|
||||||
|
public void setRemark(String remark)
|
||||||
|
{
|
||||||
|
this.remark = remark;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getRemark()
|
||||||
|
{
|
||||||
|
return remark;
|
||||||
|
}
|
||||||
|
public void setCreateTime(Date createTime)
|
||||||
|
{
|
||||||
|
this.createTime = createTime;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Date getCreateTime()
|
||||||
|
{
|
||||||
|
return createTime;
|
||||||
|
}
|
||||||
|
public void setUpdateTime(Date updateTime)
|
||||||
|
{
|
||||||
|
this.updateTime = updateTime;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Date getUpdateTime()
|
||||||
|
{
|
||||||
|
return updateTime;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public String toString() {
|
||||||
|
return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
|
||||||
|
.append("id", getId())
|
||||||
|
.append("groupCode", getGroupCode())
|
||||||
|
.append("groupName", getGroupName())
|
||||||
|
.append("type", getType())
|
||||||
|
.append("status", getStatus())
|
||||||
|
.append("remark", getRemark())
|
||||||
|
.append("createTime", getCreateTime())
|
||||||
|
.append("updateTime", getUpdateTime())
|
||||||
|
.toString();
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,95 @@
|
|||||||
|
package com.ruoyi.system.domain;
|
||||||
|
|
||||||
|
import org.apache.commons.lang3.builder.ToStringBuilder;
|
||||||
|
import org.apache.commons.lang3.builder.ToStringStyle;
|
||||||
|
import com.ruoyi.common.annotation.Excel;
|
||||||
|
import com.ruoyi.common.core.domain.BaseEntity;
|
||||||
|
import java.io.Serializable;
|
||||||
|
/**
|
||||||
|
* 版本信息对象 dm_player_version
|
||||||
|
*
|
||||||
|
* @author luqj
|
||||||
|
* @date 2026-05-14
|
||||||
|
*/
|
||||||
|
public class DmPlayerVersion extends BaseEntity
|
||||||
|
{
|
||||||
|
private static final long serialVersionUID = 1L;
|
||||||
|
|
||||||
|
/** 主键 */
|
||||||
|
private Long id;
|
||||||
|
|
||||||
|
/** 名称 */
|
||||||
|
@Excel(name = "名称")
|
||||||
|
private String title;
|
||||||
|
|
||||||
|
/** 版本号 */
|
||||||
|
@Excel(name = "版本号")
|
||||||
|
private String versionNum;
|
||||||
|
|
||||||
|
/** 配置下载地址 */
|
||||||
|
@Excel(name = "配置下载地址")
|
||||||
|
private String configUrl;
|
||||||
|
|
||||||
|
/** 代理下载地址 */
|
||||||
|
@Excel(name = "代理下载地址")
|
||||||
|
private String proxyUrl;
|
||||||
|
|
||||||
|
public void setId(Long id)
|
||||||
|
{
|
||||||
|
this.id = id;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Long getId()
|
||||||
|
{
|
||||||
|
return id;
|
||||||
|
}
|
||||||
|
public void setTitle(String title)
|
||||||
|
{
|
||||||
|
this.title = title;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getTitle()
|
||||||
|
{
|
||||||
|
return title;
|
||||||
|
}
|
||||||
|
public void setVersionNum(String versionNum)
|
||||||
|
{
|
||||||
|
this.versionNum = versionNum;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getVersionNum()
|
||||||
|
{
|
||||||
|
return versionNum;
|
||||||
|
}
|
||||||
|
public void setConfigUrl(String configUrl)
|
||||||
|
{
|
||||||
|
this.configUrl = configUrl;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getConfigUrl()
|
||||||
|
{
|
||||||
|
return configUrl;
|
||||||
|
}
|
||||||
|
public void setProxyUrl(String proxyUrl)
|
||||||
|
{
|
||||||
|
this.proxyUrl = proxyUrl;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getProxyUrl()
|
||||||
|
{
|
||||||
|
return proxyUrl;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public String toString() {
|
||||||
|
return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
|
||||||
|
.append("id", getId())
|
||||||
|
.append("title", getTitle())
|
||||||
|
.append("versionNum", getVersionNum())
|
||||||
|
.append("configUrl", getConfigUrl())
|
||||||
|
.append("proxyUrl", getProxyUrl())
|
||||||
|
.append("createTime", getCreateTime())
|
||||||
|
.append("updateTime", getUpdateTime())
|
||||||
|
.toString();
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,115 @@
|
|||||||
|
package com.ruoyi.system.domain;
|
||||||
|
|
||||||
|
import org.apache.commons.lang3.builder.ToStringBuilder;
|
||||||
|
import org.apache.commons.lang3.builder.ToStringStyle;
|
||||||
|
import com.ruoyi.common.annotation.Excel;
|
||||||
|
import com.ruoyi.common.core.domain.BaseEntity;
|
||||||
|
import java.io.Serializable;
|
||||||
|
import java.util.Date;
|
||||||
|
import com.baomidou.mybatisplus.annotation.TableName;
|
||||||
|
/**
|
||||||
|
* 版本信息对象 dm_player_version
|
||||||
|
*
|
||||||
|
* @author luqj
|
||||||
|
* @date 2026-05-14
|
||||||
|
*/
|
||||||
|
@TableName(value = "dm_player_version")
|
||||||
|
public class DmPlayerVersionPlus implements Serializable
|
||||||
|
{
|
||||||
|
private static final long serialVersionUID = 1L;
|
||||||
|
|
||||||
|
/** 主键 */
|
||||||
|
private Long id;
|
||||||
|
/** 名称 */
|
||||||
|
@Excel(name = "名称")
|
||||||
|
private String title;
|
||||||
|
/** 版本号 */
|
||||||
|
@Excel(name = "版本号")
|
||||||
|
private String versionNum;
|
||||||
|
/** 配置下载地址 */
|
||||||
|
@Excel(name = "配置下载地址")
|
||||||
|
private String configUrl;
|
||||||
|
/** 代理下载地址 */
|
||||||
|
@Excel(name = "代理下载地址")
|
||||||
|
private String proxyUrl;
|
||||||
|
/** 创建时间 */
|
||||||
|
private Date createTime;
|
||||||
|
/** 更新时间 */
|
||||||
|
private Date updateTime;
|
||||||
|
public void setId(Long id)
|
||||||
|
{
|
||||||
|
this.id = id;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Long getId()
|
||||||
|
{
|
||||||
|
return id;
|
||||||
|
}
|
||||||
|
public void setTitle(String title)
|
||||||
|
{
|
||||||
|
this.title = title;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getTitle()
|
||||||
|
{
|
||||||
|
return title;
|
||||||
|
}
|
||||||
|
public void setVersionNum(String versionNum)
|
||||||
|
{
|
||||||
|
this.versionNum = versionNum;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getVersionNum()
|
||||||
|
{
|
||||||
|
return versionNum;
|
||||||
|
}
|
||||||
|
public void setConfigUrl(String configUrl)
|
||||||
|
{
|
||||||
|
this.configUrl = configUrl;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getConfigUrl()
|
||||||
|
{
|
||||||
|
return configUrl;
|
||||||
|
}
|
||||||
|
public void setProxyUrl(String proxyUrl)
|
||||||
|
{
|
||||||
|
this.proxyUrl = proxyUrl;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getProxyUrl()
|
||||||
|
{
|
||||||
|
return proxyUrl;
|
||||||
|
}
|
||||||
|
public void setCreateTime(Date createTime)
|
||||||
|
{
|
||||||
|
this.createTime = createTime;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Date getCreateTime()
|
||||||
|
{
|
||||||
|
return createTime;
|
||||||
|
}
|
||||||
|
public void setUpdateTime(Date updateTime)
|
||||||
|
{
|
||||||
|
this.updateTime = updateTime;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Date getUpdateTime()
|
||||||
|
{
|
||||||
|
return updateTime;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public String toString() {
|
||||||
|
return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
|
||||||
|
.append("id", getId())
|
||||||
|
.append("title", getTitle())
|
||||||
|
.append("versionNum", getVersionNum())
|
||||||
|
.append("configUrl", getConfigUrl())
|
||||||
|
.append("proxyUrl", getProxyUrl())
|
||||||
|
.append("createTime", getCreateTime())
|
||||||
|
.append("updateTime", getUpdateTime())
|
||||||
|
.toString();
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -4,6 +4,8 @@ import org.apache.commons.lang3.builder.ToStringBuilder;
|
|||||||
import org.apache.commons.lang3.builder.ToStringStyle;
|
import org.apache.commons.lang3.builder.ToStringStyle;
|
||||||
import com.ruoyi.common.annotation.Excel;
|
import com.ruoyi.common.annotation.Excel;
|
||||||
import com.ruoyi.common.core.domain.BaseEntity;
|
import com.ruoyi.common.core.domain.BaseEntity;
|
||||||
|
import org.springframework.data.annotation.Transient;
|
||||||
|
|
||||||
import java.io.Serializable;
|
import java.io.Serializable;
|
||||||
/**
|
/**
|
||||||
* 大漠代理对象 dm_playerent
|
* 大漠代理对象 dm_playerent
|
||||||
@@ -69,10 +71,31 @@ public class DmPlayerent extends BaseEntity
|
|||||||
/** 当前任务 */
|
/** 当前任务 */
|
||||||
@Excel(name = "当前任务")
|
@Excel(name = "当前任务")
|
||||||
private String winOneCurTask;
|
private String winOneCurTask;
|
||||||
|
/** 当前任务 */
|
||||||
|
@Excel(name = "secret")
|
||||||
|
private String secret;
|
||||||
/** 当前任务 */
|
/** 当前任务 */
|
||||||
@Excel(name = "当前任务")
|
@Excel(name = "当前任务")
|
||||||
private String winTwoCurTask;
|
private String winTwoCurTask;
|
||||||
|
@Excel(name = "mjpeg播放地址")
|
||||||
|
@Transient
|
||||||
|
private transient String mjpegUrl;
|
||||||
|
|
||||||
|
public String getSecret() {
|
||||||
|
return secret;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setSecret(String secret) {
|
||||||
|
this.secret = secret;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getMjpegUrl() {
|
||||||
|
return mjpegUrl;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setMjpegUrl(String mjpegUrl) {
|
||||||
|
this.mjpegUrl = mjpegUrl;
|
||||||
|
}
|
||||||
|
|
||||||
public void setId(Long id)
|
public void setId(Long id)
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -66,6 +66,18 @@ public class DmPlayerentPlus implements Serializable
|
|||||||
/** 当前任务 */
|
/** 当前任务 */
|
||||||
@Excel(name = "当前任务")
|
@Excel(name = "当前任务")
|
||||||
private String winTwoCurTask;
|
private String winTwoCurTask;
|
||||||
|
|
||||||
|
@Excel(name = "版本信息")
|
||||||
|
private String dmVersion;
|
||||||
|
|
||||||
|
public String getDmVersion() {
|
||||||
|
return dmVersion;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setDmVersion(String dmVersion) {
|
||||||
|
this.dmVersion = dmVersion;
|
||||||
|
}
|
||||||
|
|
||||||
public void setId(Long id)
|
public void setId(Long id)
|
||||||
{
|
{
|
||||||
this.id = id;
|
this.id = id;
|
||||||
|
|||||||
@@ -0,0 +1,14 @@
|
|||||||
|
package com.ruoyi.system.domain;
|
||||||
|
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
import java.io.Serializable;
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
@Data
|
||||||
|
public class DmVersionUpdateVo implements Serializable {
|
||||||
|
private static final long serialVersionUID = 1L;
|
||||||
|
private Long id;
|
||||||
|
|
||||||
|
private List<Long> playerIds;
|
||||||
|
}
|
||||||
@@ -0,0 +1,65 @@
|
|||||||
|
package com.ruoyi.system.mapper;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||||
|
import org.apache.ibatis.annotations.Param;
|
||||||
|
import com.ruoyi.system.domain.DmGroupTaskRelation;
|
||||||
|
import com.ruoyi.system.domain.DmGroupTaskRelationPlus;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 组任务关联Mapper接口
|
||||||
|
*
|
||||||
|
* @author luqj
|
||||||
|
* @date 2026-05-14
|
||||||
|
*/
|
||||||
|
public interface DmGroupTaskRelationMapper extends BaseMapper<DmGroupTaskRelationPlus>
|
||||||
|
{
|
||||||
|
/**
|
||||||
|
* 查询组任务关联
|
||||||
|
*
|
||||||
|
* @param id 组任务关联ID
|
||||||
|
* @return 组任务关联
|
||||||
|
*/
|
||||||
|
public DmGroupTaskRelation selectDmGroupTaskRelationById(Long id);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查询组任务关联列表
|
||||||
|
*
|
||||||
|
* @param dmGroupTaskRelation 组任务关联
|
||||||
|
* @return 组任务关联集合
|
||||||
|
*/
|
||||||
|
public List<DmGroupTaskRelation> selectDmGroupTaskRelationList(DmGroupTaskRelation dmGroupTaskRelation);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 新增组任务关联
|
||||||
|
*
|
||||||
|
* @param dmGroupTaskRelation 组任务关联
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int insertDmGroupTaskRelation(DmGroupTaskRelation dmGroupTaskRelation);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 修改组任务关联
|
||||||
|
*
|
||||||
|
* @param dmGroupTaskRelation 组任务关联
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int updateDmGroupTaskRelation(DmGroupTaskRelation dmGroupTaskRelation);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除组任务关联
|
||||||
|
*
|
||||||
|
* @param id 组任务关联ID
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int deleteDmGroupTaskRelationById(Long id);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 批量删除组任务关联
|
||||||
|
*
|
||||||
|
* @param ids 需要删除的数据ID
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int deleteDmGroupTaskRelationByIds(Long[] ids);
|
||||||
|
}
|
||||||
@@ -0,0 +1,67 @@
|
|||||||
|
package com.ruoyi.system.mapper;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||||
|
import org.apache.ibatis.annotations.Param;
|
||||||
|
import com.ruoyi.system.domain.DmPlayerConfig;
|
||||||
|
import com.ruoyi.system.domain.DmPlayerConfigPlus;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 玩家配置Mapper接口
|
||||||
|
*
|
||||||
|
* @author luqj
|
||||||
|
* @date 2026-05-10
|
||||||
|
*/
|
||||||
|
public interface DmPlayerConfigMapper extends BaseMapper<DmPlayerConfigPlus>
|
||||||
|
{
|
||||||
|
/**
|
||||||
|
* 查询玩家配置
|
||||||
|
*
|
||||||
|
* @param id 玩家配置ID
|
||||||
|
* @return 玩家配置
|
||||||
|
*/
|
||||||
|
public DmPlayerConfig selectDmPlayerConfigById(Long id);
|
||||||
|
|
||||||
|
|
||||||
|
public DmPlayerConfig selectDmPlayerConfigByPlayerId(Long playerId);
|
||||||
|
/**
|
||||||
|
* 查询玩家配置列表
|
||||||
|
*
|
||||||
|
* @param dmPlayerConfig 玩家配置
|
||||||
|
* @return 玩家配置集合
|
||||||
|
*/
|
||||||
|
public List<DmPlayerConfig> selectDmPlayerConfigList(DmPlayerConfig dmPlayerConfig);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 新增玩家配置
|
||||||
|
*
|
||||||
|
* @param dmPlayerConfig 玩家配置
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int insertDmPlayerConfig(DmPlayerConfig dmPlayerConfig);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 修改玩家配置
|
||||||
|
*
|
||||||
|
* @param dmPlayerConfig 玩家配置
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int updateDmPlayerConfig(DmPlayerConfig dmPlayerConfig);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除玩家配置
|
||||||
|
*
|
||||||
|
* @param id 玩家配置ID
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int deleteDmPlayerConfigById(Long id);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 批量删除玩家配置
|
||||||
|
*
|
||||||
|
* @param ids 需要删除的数据ID
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int deleteDmPlayerConfigByIds(Long[] ids);
|
||||||
|
}
|
||||||
@@ -0,0 +1,65 @@
|
|||||||
|
package com.ruoyi.system.mapper;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||||
|
import org.apache.ibatis.annotations.Param;
|
||||||
|
import com.ruoyi.system.domain.DmPlayerTaskGroup;
|
||||||
|
import com.ruoyi.system.domain.DmPlayerTaskGroupPlus;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 大漠任务组Mapper接口
|
||||||
|
*
|
||||||
|
* @author luqj
|
||||||
|
* @date 2026-05-14
|
||||||
|
*/
|
||||||
|
public interface DmPlayerTaskGroupMapper extends BaseMapper<DmPlayerTaskGroupPlus>
|
||||||
|
{
|
||||||
|
/**
|
||||||
|
* 查询大漠任务组
|
||||||
|
*
|
||||||
|
* @param id 大漠任务组ID
|
||||||
|
* @return 大漠任务组
|
||||||
|
*/
|
||||||
|
public DmPlayerTaskGroup selectDmPlayerTaskGroupById(Long id);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查询大漠任务组列表
|
||||||
|
*
|
||||||
|
* @param dmPlayerTaskGroup 大漠任务组
|
||||||
|
* @return 大漠任务组集合
|
||||||
|
*/
|
||||||
|
public List<DmPlayerTaskGroup> selectDmPlayerTaskGroupList(DmPlayerTaskGroup dmPlayerTaskGroup);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 新增大漠任务组
|
||||||
|
*
|
||||||
|
* @param dmPlayerTaskGroup 大漠任务组
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int insertDmPlayerTaskGroup(DmPlayerTaskGroup dmPlayerTaskGroup);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 修改大漠任务组
|
||||||
|
*
|
||||||
|
* @param dmPlayerTaskGroup 大漠任务组
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int updateDmPlayerTaskGroup(DmPlayerTaskGroup dmPlayerTaskGroup);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除大漠任务组
|
||||||
|
*
|
||||||
|
* @param id 大漠任务组ID
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int deleteDmPlayerTaskGroupById(Long id);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 批量删除大漠任务组
|
||||||
|
*
|
||||||
|
* @param ids 需要删除的数据ID
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int deleteDmPlayerTaskGroupByIds(Long[] ids);
|
||||||
|
}
|
||||||
@@ -0,0 +1,65 @@
|
|||||||
|
package com.ruoyi.system.mapper;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||||
|
import org.apache.ibatis.annotations.Param;
|
||||||
|
import com.ruoyi.system.domain.DmPlayerVersion;
|
||||||
|
import com.ruoyi.system.domain.DmPlayerVersionPlus;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 版本信息Mapper接口
|
||||||
|
*
|
||||||
|
* @author luqj
|
||||||
|
* @date 2026-05-14
|
||||||
|
*/
|
||||||
|
public interface DmPlayerVersionMapper extends BaseMapper<DmPlayerVersionPlus>
|
||||||
|
{
|
||||||
|
/**
|
||||||
|
* 查询版本信息
|
||||||
|
*
|
||||||
|
* @param id 版本信息ID
|
||||||
|
* @return 版本信息
|
||||||
|
*/
|
||||||
|
public DmPlayerVersion selectDmPlayerVersionById(Long id);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查询版本信息列表
|
||||||
|
*
|
||||||
|
* @param dmPlayerVersion 版本信息
|
||||||
|
* @return 版本信息集合
|
||||||
|
*/
|
||||||
|
public List<DmPlayerVersion> selectDmPlayerVersionList(DmPlayerVersion dmPlayerVersion);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 新增版本信息
|
||||||
|
*
|
||||||
|
* @param dmPlayerVersion 版本信息
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int insertDmPlayerVersion(DmPlayerVersion dmPlayerVersion);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 修改版本信息
|
||||||
|
*
|
||||||
|
* @param dmPlayerVersion 版本信息
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int updateDmPlayerVersion(DmPlayerVersion dmPlayerVersion);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除版本信息
|
||||||
|
*
|
||||||
|
* @param id 版本信息ID
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int deleteDmPlayerVersionById(Long id);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 批量删除版本信息
|
||||||
|
*
|
||||||
|
* @param ids 需要删除的数据ID
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int deleteDmPlayerVersionByIds(Long[] ids);
|
||||||
|
}
|
||||||
@@ -0,0 +1,89 @@
|
|||||||
|
package com.ruoyi.system.service;
|
||||||
|
import java.util.Map;
|
||||||
|
import java.util.List;
|
||||||
|
import com.ruoyi.system.domain.DmGroupTaskRelation;
|
||||||
|
import com.ruoyi.system.domain.DmGroupTaskRelationPlus;
|
||||||
|
import com.baomidou.mybatisplus.extension.service.IService;
|
||||||
|
import com.baomidou.mybatisplus.core.toolkit.support.SFunction;
|
||||||
|
import com.ruoyi.common.select.SelectItem;
|
||||||
|
/**
|
||||||
|
* 组任务关联Service接口
|
||||||
|
*
|
||||||
|
* @author luqj
|
||||||
|
* @date 2026-05-14
|
||||||
|
*/
|
||||||
|
public interface IDmGroupTaskRelationService extends IService<DmGroupTaskRelationPlus>
|
||||||
|
{
|
||||||
|
|
||||||
|
List<SelectItem> select(String keyword);
|
||||||
|
/**
|
||||||
|
* 查询组任务关联
|
||||||
|
*
|
||||||
|
* @param id 组任务关联ID
|
||||||
|
* @return 组任务关联
|
||||||
|
*/
|
||||||
|
public DmGroupTaskRelation selectDmGroupTaskRelationById(Long id);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查询组任务关联列表
|
||||||
|
*
|
||||||
|
* @param dmGroupTaskRelation 组任务关联
|
||||||
|
* @return 组任务关联集合
|
||||||
|
*/
|
||||||
|
public List<DmGroupTaskRelation> selectDmGroupTaskRelationList(DmGroupTaskRelation dmGroupTaskRelation);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 新增组任务关联
|
||||||
|
*
|
||||||
|
* @param dmGroupTaskRelation 组任务关联
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int insertDmGroupTaskRelation(DmGroupTaskRelation dmGroupTaskRelation);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 修改组任务关联
|
||||||
|
*
|
||||||
|
* @param dmGroupTaskRelation 组任务关联
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int updateDmGroupTaskRelation(DmGroupTaskRelation dmGroupTaskRelation);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 批量删除组任务关联
|
||||||
|
*
|
||||||
|
* @param ids 需要删除的组任务关联ID
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int deleteDmGroupTaskRelationByIds(Long[] ids);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除组任务关联信息
|
||||||
|
*
|
||||||
|
* @param id 组任务关联ID
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int deleteDmGroupTaskRelationById(Long id);
|
||||||
|
|
||||||
|
List<DmGroupTaskRelationPlus> getByIds(List<Long> ids, SFunction<DmGroupTaskRelationPlus, ?>... columns);
|
||||||
|
|
||||||
|
DmGroupTaskRelationPlus getById(Long id, SFunction<DmGroupTaskRelationPlus, ?>... columns);
|
||||||
|
|
||||||
|
Map<Long, DmGroupTaskRelationPlus> getMapByIds(List<Long> ids, SFunction<DmGroupTaskRelationPlus, ?>... columns);
|
||||||
|
|
||||||
|
List<DmGroupTaskRelationPlus> getByIds(List<Long> ids);
|
||||||
|
|
||||||
|
Map<Long, DmGroupTaskRelationPlus> getMapByIds(List<Long> ids);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @param field sum 字段
|
||||||
|
* @param where 条件
|
||||||
|
* @param tClass 返回类型
|
||||||
|
* @param <T>
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
<T> T sum(String field, String where, Class<T> tClass);
|
||||||
|
|
||||||
|
Long count(String where);
|
||||||
|
|
||||||
|
<T> List<T> countByGroupBy(String select, String where, String groupby, Class<T> tClass);
|
||||||
|
}
|
||||||
@@ -0,0 +1,93 @@
|
|||||||
|
package com.ruoyi.system.service;
|
||||||
|
import java.util.Map;
|
||||||
|
import java.util.List;
|
||||||
|
import com.ruoyi.system.domain.DmPlayerConfig;
|
||||||
|
import com.ruoyi.system.domain.DmPlayerConfigPlus;
|
||||||
|
import com.baomidou.mybatisplus.extension.service.IService;
|
||||||
|
import com.baomidou.mybatisplus.core.toolkit.support.SFunction;
|
||||||
|
import com.ruoyi.common.select.SelectItem;
|
||||||
|
/**
|
||||||
|
* 玩家配置Service接口
|
||||||
|
*
|
||||||
|
* @author luqj
|
||||||
|
* @date 2026-05-10
|
||||||
|
*/
|
||||||
|
public interface IDmPlayerConfigService extends IService<DmPlayerConfigPlus>
|
||||||
|
{
|
||||||
|
|
||||||
|
List<SelectItem> select(String keyword);
|
||||||
|
/**
|
||||||
|
* 查询玩家配置
|
||||||
|
*
|
||||||
|
* @param id 玩家配置ID
|
||||||
|
* @return 玩家配置
|
||||||
|
*/
|
||||||
|
public DmPlayerConfig selectDmPlayerConfigById(Long id);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查询玩家配置列表
|
||||||
|
*
|
||||||
|
* @param dmPlayerConfig 玩家配置
|
||||||
|
* @return 玩家配置集合
|
||||||
|
*/
|
||||||
|
public List<DmPlayerConfig> selectDmPlayerConfigList(DmPlayerConfig dmPlayerConfig);
|
||||||
|
|
||||||
|
|
||||||
|
public DmPlayerConfig selectDmPlayerConfigByPlayerId(Long playerId);
|
||||||
|
/**
|
||||||
|
* 新增玩家配置
|
||||||
|
*
|
||||||
|
* @param dmPlayerConfig 玩家配置
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int insertDmPlayerConfig(DmPlayerConfig dmPlayerConfig);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 修改玩家配置
|
||||||
|
*
|
||||||
|
* @param dmPlayerConfig 玩家配置
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int updateDmPlayerConfig(DmPlayerConfig dmPlayerConfig);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 批量删除玩家配置
|
||||||
|
*
|
||||||
|
* @param ids 需要删除的玩家配置ID
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int deleteDmPlayerConfigByIds(Long[] ids);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除玩家配置信息
|
||||||
|
*
|
||||||
|
* @param id 玩家配置ID
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int deleteDmPlayerConfigById(Long id);
|
||||||
|
|
||||||
|
List<DmPlayerConfigPlus> getByIds(List<Long> ids, SFunction<DmPlayerConfigPlus, ?>... columns);
|
||||||
|
|
||||||
|
DmPlayerConfigPlus getById(Long id, SFunction<DmPlayerConfigPlus, ?>... columns);
|
||||||
|
|
||||||
|
Map<Long, DmPlayerConfigPlus> getMapByIds(List<Long> ids, SFunction<DmPlayerConfigPlus, ?>... columns);
|
||||||
|
|
||||||
|
List<DmPlayerConfigPlus> getByIds(List<Long> ids);
|
||||||
|
|
||||||
|
Map<Long, DmPlayerConfigPlus> getMapByIds(List<Long> ids);
|
||||||
|
|
||||||
|
|
||||||
|
Map<Long, DmPlayerConfigPlus> getMapByPlayerIds(List<Long> ids);
|
||||||
|
/**
|
||||||
|
* @param field sum 字段
|
||||||
|
* @param where 条件
|
||||||
|
* @param tClass 返回类型
|
||||||
|
* @param <T>
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
<T> T sum(String field, String where, Class<T> tClass);
|
||||||
|
|
||||||
|
Long count(String where);
|
||||||
|
|
||||||
|
<T> List<T> countByGroupBy(String select, String where, String groupby, Class<T> tClass);
|
||||||
|
}
|
||||||
@@ -0,0 +1,89 @@
|
|||||||
|
package com.ruoyi.system.service;
|
||||||
|
import java.util.Map;
|
||||||
|
import java.util.List;
|
||||||
|
import com.ruoyi.system.domain.DmPlayerTaskGroup;
|
||||||
|
import com.ruoyi.system.domain.DmPlayerTaskGroupPlus;
|
||||||
|
import com.baomidou.mybatisplus.extension.service.IService;
|
||||||
|
import com.baomidou.mybatisplus.core.toolkit.support.SFunction;
|
||||||
|
import com.ruoyi.common.select.SelectItem;
|
||||||
|
/**
|
||||||
|
* 大漠任务组Service接口
|
||||||
|
*
|
||||||
|
* @author luqj
|
||||||
|
* @date 2026-05-14
|
||||||
|
*/
|
||||||
|
public interface IDmPlayerTaskGroupService extends IService<DmPlayerTaskGroupPlus>
|
||||||
|
{
|
||||||
|
|
||||||
|
List<SelectItem> select(String keyword);
|
||||||
|
/**
|
||||||
|
* 查询大漠任务组
|
||||||
|
*
|
||||||
|
* @param id 大漠任务组ID
|
||||||
|
* @return 大漠任务组
|
||||||
|
*/
|
||||||
|
public DmPlayerTaskGroup selectDmPlayerTaskGroupById(Long id);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查询大漠任务组列表
|
||||||
|
*
|
||||||
|
* @param dmPlayerTaskGroup 大漠任务组
|
||||||
|
* @return 大漠任务组集合
|
||||||
|
*/
|
||||||
|
public List<DmPlayerTaskGroup> selectDmPlayerTaskGroupList(DmPlayerTaskGroup dmPlayerTaskGroup);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 新增大漠任务组
|
||||||
|
*
|
||||||
|
* @param dmPlayerTaskGroup 大漠任务组
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int insertDmPlayerTaskGroup(DmPlayerTaskGroup dmPlayerTaskGroup);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 修改大漠任务组
|
||||||
|
*
|
||||||
|
* @param dmPlayerTaskGroup 大漠任务组
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int updateDmPlayerTaskGroup(DmPlayerTaskGroup dmPlayerTaskGroup);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 批量删除大漠任务组
|
||||||
|
*
|
||||||
|
* @param ids 需要删除的大漠任务组ID
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int deleteDmPlayerTaskGroupByIds(Long[] ids);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除大漠任务组信息
|
||||||
|
*
|
||||||
|
* @param id 大漠任务组ID
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int deleteDmPlayerTaskGroupById(Long id);
|
||||||
|
|
||||||
|
List<DmPlayerTaskGroupPlus> getByIds(List<Long> ids, SFunction<DmPlayerTaskGroupPlus, ?>... columns);
|
||||||
|
|
||||||
|
DmPlayerTaskGroupPlus getById(Long id, SFunction<DmPlayerTaskGroupPlus, ?>... columns);
|
||||||
|
|
||||||
|
Map<Long, DmPlayerTaskGroupPlus> getMapByIds(List<Long> ids, SFunction<DmPlayerTaskGroupPlus, ?>... columns);
|
||||||
|
|
||||||
|
List<DmPlayerTaskGroupPlus> getByIds(List<Long> ids);
|
||||||
|
|
||||||
|
Map<Long, DmPlayerTaskGroupPlus> getMapByIds(List<Long> ids);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @param field sum 字段
|
||||||
|
* @param where 条件
|
||||||
|
* @param tClass 返回类型
|
||||||
|
* @param <T>
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
<T> T sum(String field, String where, Class<T> tClass);
|
||||||
|
|
||||||
|
Long count(String where);
|
||||||
|
|
||||||
|
<T> List<T> countByGroupBy(String select, String where, String groupby, Class<T> tClass);
|
||||||
|
}
|
||||||
@@ -0,0 +1,93 @@
|
|||||||
|
package com.ruoyi.system.service;
|
||||||
|
import java.util.Map;
|
||||||
|
import java.util.List;
|
||||||
|
import com.ruoyi.system.domain.DmPlayerVersion;
|
||||||
|
import com.ruoyi.system.domain.DmPlayerVersionPlus;
|
||||||
|
import com.baomidou.mybatisplus.extension.service.IService;
|
||||||
|
import com.baomidou.mybatisplus.core.toolkit.support.SFunction;
|
||||||
|
import com.ruoyi.common.select.SelectItem;
|
||||||
|
import com.ruoyi.system.domain.DmVersionUpdateVo;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 版本信息Service接口
|
||||||
|
*
|
||||||
|
* @author luqj
|
||||||
|
* @date 2026-05-14
|
||||||
|
*/
|
||||||
|
public interface IDmPlayerVersionService extends IService<DmPlayerVersionPlus>
|
||||||
|
{
|
||||||
|
|
||||||
|
List<SelectItem> select(String keyword);
|
||||||
|
/**
|
||||||
|
* 查询版本信息
|
||||||
|
*
|
||||||
|
* @param id 版本信息ID
|
||||||
|
* @return 版本信息
|
||||||
|
*/
|
||||||
|
public DmPlayerVersion selectDmPlayerVersionById(Long id);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查询版本信息列表
|
||||||
|
*
|
||||||
|
* @param dmPlayerVersion 版本信息
|
||||||
|
* @return 版本信息集合
|
||||||
|
*/
|
||||||
|
public List<DmPlayerVersion> selectDmPlayerVersionList(DmPlayerVersion dmPlayerVersion);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 新增版本信息
|
||||||
|
*
|
||||||
|
* @param dmPlayerVersion 版本信息
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int insertDmPlayerVersion(DmPlayerVersion dmPlayerVersion);
|
||||||
|
|
||||||
|
|
||||||
|
public boolean playerentUpdate(DmVersionUpdateVo vo);
|
||||||
|
/**
|
||||||
|
* 修改版本信息
|
||||||
|
*
|
||||||
|
* @param dmPlayerVersion 版本信息
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int updateDmPlayerVersion(DmPlayerVersion dmPlayerVersion);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 批量删除版本信息
|
||||||
|
*
|
||||||
|
* @param ids 需要删除的版本信息ID
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int deleteDmPlayerVersionByIds(Long[] ids);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除版本信息信息
|
||||||
|
*
|
||||||
|
* @param id 版本信息ID
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
public int deleteDmPlayerVersionById(Long id);
|
||||||
|
|
||||||
|
List<DmPlayerVersionPlus> getByIds(List<Long> ids, SFunction<DmPlayerVersionPlus, ?>... columns);
|
||||||
|
|
||||||
|
DmPlayerVersionPlus getById(Long id, SFunction<DmPlayerVersionPlus, ?>... columns);
|
||||||
|
|
||||||
|
Map<Long, DmPlayerVersionPlus> getMapByIds(List<Long> ids, SFunction<DmPlayerVersionPlus, ?>... columns);
|
||||||
|
|
||||||
|
List<DmPlayerVersionPlus> getByIds(List<Long> ids);
|
||||||
|
|
||||||
|
Map<Long, DmPlayerVersionPlus> getMapByIds(List<Long> ids);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @param field sum 字段
|
||||||
|
* @param where 条件
|
||||||
|
* @param tClass 返回类型
|
||||||
|
* @param <T>
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
<T> T sum(String field, String where, Class<T> tClass);
|
||||||
|
|
||||||
|
Long count(String where);
|
||||||
|
|
||||||
|
<T> List<T> countByGroupBy(String select, String where, String groupby, Class<T> tClass);
|
||||||
|
}
|
||||||
+208
@@ -0,0 +1,208 @@
|
|||||||
|
package com.ruoyi.system.service.impl;
|
||||||
|
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
|
||||||
|
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
||||||
|
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||||
|
import com.github.pagehelper.PageHelper;
|
||||||
|
import com.baomidou.mybatisplus.core.toolkit.support.SFunction;
|
||||||
|
|
||||||
|
import java.util.ArrayList;
|
||||||
|
import java.util.HashMap;
|
||||||
|
import com.ruoyi.common.utils.StringUtils;
|
||||||
|
import com.alibaba.fastjson.JSONArray;
|
||||||
|
import java.util.List;
|
||||||
|
import java.util.Map;
|
||||||
|
import com.ruoyi.common.utils.DateUtils;
|
||||||
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
|
import org.springframework.stereotype.Service;
|
||||||
|
import com.ruoyi.system.mapper.DmGroupTaskRelationMapper;
|
||||||
|
import com.ruoyi.system.domain.DmGroupTaskRelation;
|
||||||
|
import com.ruoyi.system.domain.DmGroupTaskRelationPlus;
|
||||||
|
import com.ruoyi.system.service.IDmGroupTaskRelationService;
|
||||||
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
|
import org.springframework.jdbc.core.JdbcTemplate;
|
||||||
|
import com.ruoyi.common.select.SelectItem;
|
||||||
|
/**
|
||||||
|
* 组任务关联Service业务层处理
|
||||||
|
*
|
||||||
|
* @author luqj
|
||||||
|
* @date 2026-05-14
|
||||||
|
*/
|
||||||
|
@Service
|
||||||
|
public class DmGroupTaskRelationServiceImpl extends ServiceImpl<DmGroupTaskRelationMapper, DmGroupTaskRelationPlus> implements IDmGroupTaskRelationService
|
||||||
|
{
|
||||||
|
@Autowired
|
||||||
|
private DmGroupTaskRelationMapper dmGroupTaskRelationMapper;
|
||||||
|
@Autowired
|
||||||
|
private JdbcTemplate jdbcTemplate;
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public List<DmGroupTaskRelationPlus> getByIds(List<Long> ids, SFunction<DmGroupTaskRelationPlus, ?>... columns) {
|
||||||
|
LambdaQueryWrapper<DmGroupTaskRelationPlus> lambdaQueryWrapper = new LambdaQueryWrapper<DmGroupTaskRelationPlus>()
|
||||||
|
.select(columns).in(DmGroupTaskRelationPlus::getId, ids);
|
||||||
|
return this.list(lambdaQueryWrapper);
|
||||||
|
}
|
||||||
|
@Override
|
||||||
|
public List<SelectItem> select(String keyword) {
|
||||||
|
LambdaQueryWrapper<DmGroupTaskRelationPlus> lambdaQueryWrapper = new LambdaQueryWrapper<DmGroupTaskRelationPlus>()
|
||||||
|
.select(DmGroupTaskRelationPlus::getId, DmGroupTaskRelationPlus::getPlayerName)
|
||||||
|
.like(DmGroupTaskRelationPlus::getPlayerName, keyword);
|
||||||
|
List<DmGroupTaskRelationPlus> list = this.list(lambdaQueryWrapper);
|
||||||
|
List<SelectItem> result =new ArrayList<>();
|
||||||
|
for (DmGroupTaskRelationPlus item : list){
|
||||||
|
SelectItem selectItem = new SelectItem();
|
||||||
|
selectItem.setName(item.getPlayerName());
|
||||||
|
selectItem.setId(item.getId());
|
||||||
|
result.add(selectItem);
|
||||||
|
}
|
||||||
|
return result;
|
||||||
|
}
|
||||||
|
@Override
|
||||||
|
public DmGroupTaskRelationPlus getById(Long id, SFunction<DmGroupTaskRelationPlus, ?>... columns) {
|
||||||
|
LambdaQueryWrapper<DmGroupTaskRelationPlus> lambdaQueryWrapper = new LambdaQueryWrapper<DmGroupTaskRelationPlus>()
|
||||||
|
.select(columns).eq(DmGroupTaskRelationPlus::getId, id);
|
||||||
|
return baseMapper.selectOne(lambdaQueryWrapper);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public Map<Long, DmGroupTaskRelationPlus> getMapByIds(List<Long> ids, SFunction<DmGroupTaskRelationPlus, ?>... columns) {
|
||||||
|
List<DmGroupTaskRelationPlus> list = this.getByIds(ids, columns);
|
||||||
|
Map<Long, DmGroupTaskRelationPlus> map = new HashMap<>();
|
||||||
|
for (DmGroupTaskRelationPlus item : list) {
|
||||||
|
map.put(item.getId(), item);
|
||||||
|
}
|
||||||
|
return map;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public Map<Long, DmGroupTaskRelationPlus> getMapByIds(List<Long> ids) {
|
||||||
|
List<DmGroupTaskRelationPlus> list = this.getByIds(ids);
|
||||||
|
Map<Long, DmGroupTaskRelationPlus> map = new HashMap<>();
|
||||||
|
for (DmGroupTaskRelationPlus item : list) {
|
||||||
|
map.put(item.getId(), item);
|
||||||
|
}
|
||||||
|
return map;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public List<DmGroupTaskRelationPlus> getByIds(List<Long> ids) {
|
||||||
|
LambdaQueryWrapper<DmGroupTaskRelationPlus> lambdaQueryWrapper = new LambdaQueryWrapper<DmGroupTaskRelationPlus>().in(DmGroupTaskRelationPlus::getId, ids);
|
||||||
|
return this.list(lambdaQueryWrapper);
|
||||||
|
}
|
||||||
|
|
||||||
|
public <T> T sum(String field, String where, Class<T> tClass) {
|
||||||
|
StringBuffer stringBuffer = new StringBuffer();
|
||||||
|
stringBuffer.append("select ");
|
||||||
|
stringBuffer.append(" sum(" + field + ") as total ");
|
||||||
|
stringBuffer.append(" from dm_group_task_relation ");
|
||||||
|
if (StringUtils.isNotBlank(where)) {
|
||||||
|
stringBuffer.append(" where ");
|
||||||
|
stringBuffer.append(where);
|
||||||
|
}
|
||||||
|
T result = jdbcTemplate.queryForObject(stringBuffer.toString(), tClass);
|
||||||
|
return result;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Long count(String where) {
|
||||||
|
StringBuffer stringBuffer = new StringBuffer();
|
||||||
|
stringBuffer.append("select ");
|
||||||
|
stringBuffer.append(" count(1)");
|
||||||
|
stringBuffer.append(" from ");
|
||||||
|
stringBuffer.append(" dm_group_task_relation ");
|
||||||
|
if (StringUtils.isNotBlank(where)) {
|
||||||
|
stringBuffer.append(" where ");
|
||||||
|
stringBuffer.append(where);
|
||||||
|
}
|
||||||
|
Long result = jdbcTemplate.queryForObject(stringBuffer.toString(), Long.class);
|
||||||
|
return result;
|
||||||
|
}
|
||||||
|
|
||||||
|
public <T> List<T> countByGroupBy(String select, String where, String groupby, Class<T> tClass) {
|
||||||
|
StringBuffer stringBuffer = new StringBuffer();
|
||||||
|
stringBuffer.append("select ");
|
||||||
|
stringBuffer.append(select);
|
||||||
|
stringBuffer.append(" from ");
|
||||||
|
stringBuffer.append(" dm_group_task_relation ");
|
||||||
|
if (StringUtils.isNotBlank(where)) {
|
||||||
|
stringBuffer.append(" where ");
|
||||||
|
stringBuffer.append(where);
|
||||||
|
}
|
||||||
|
stringBuffer.append(" group by ");
|
||||||
|
stringBuffer.append(groupby);
|
||||||
|
List result = jdbcTemplate.queryForList(stringBuffer.toString());
|
||||||
|
List<T> tList = JSONArray.parseArray(JSONArray.toJSONString(result), tClass);
|
||||||
|
return tList;
|
||||||
|
}
|
||||||
|
/**
|
||||||
|
* 查询组任务关联
|
||||||
|
*
|
||||||
|
* @param id 组任务关联ID
|
||||||
|
* @return 组任务关联
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public DmGroupTaskRelation selectDmGroupTaskRelationById(Long id)
|
||||||
|
{
|
||||||
|
return dmGroupTaskRelationMapper.selectDmGroupTaskRelationById(id);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查询组任务关联列表
|
||||||
|
*
|
||||||
|
* @param dmGroupTaskRelation 组任务关联
|
||||||
|
* @return 组任务关联
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public List<DmGroupTaskRelation> selectDmGroupTaskRelationList(DmGroupTaskRelation dmGroupTaskRelation)
|
||||||
|
{
|
||||||
|
return dmGroupTaskRelationMapper.selectDmGroupTaskRelationList(dmGroupTaskRelation);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 新增组任务关联
|
||||||
|
*
|
||||||
|
* @param dmGroupTaskRelation 组任务关联
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public int insertDmGroupTaskRelation(DmGroupTaskRelation dmGroupTaskRelation)
|
||||||
|
{
|
||||||
|
dmGroupTaskRelation.setCreateTime(DateUtils.getNowDate());
|
||||||
|
return dmGroupTaskRelationMapper.insertDmGroupTaskRelation(dmGroupTaskRelation);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 修改组任务关联
|
||||||
|
*
|
||||||
|
* @param dmGroupTaskRelation 组任务关联
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public int updateDmGroupTaskRelation(DmGroupTaskRelation dmGroupTaskRelation)
|
||||||
|
{
|
||||||
|
dmGroupTaskRelation.setUpdateTime(DateUtils.getNowDate());
|
||||||
|
return dmGroupTaskRelationMapper.updateDmGroupTaskRelation(dmGroupTaskRelation);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 批量删除组任务关联
|
||||||
|
*
|
||||||
|
* @param ids 需要删除的组任务关联ID
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public int deleteDmGroupTaskRelationByIds(Long[] ids)
|
||||||
|
{
|
||||||
|
return dmGroupTaskRelationMapper.deleteDmGroupTaskRelationByIds(ids);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除组任务关联信息
|
||||||
|
*
|
||||||
|
* @param id 组任务关联ID
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public int deleteDmGroupTaskRelationById(Long id)
|
||||||
|
{
|
||||||
|
return dmGroupTaskRelationMapper.deleteDmGroupTaskRelationById(id);
|
||||||
|
}
|
||||||
|
}
|
||||||
+265
@@ -0,0 +1,265 @@
|
|||||||
|
package com.ruoyi.system.service.impl;
|
||||||
|
|
||||||
|
import com.alibaba.fastjson.JSONArray;
|
||||||
|
import com.alibaba.fastjson.JSONObject;
|
||||||
|
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
|
||||||
|
import com.baomidou.mybatisplus.core.toolkit.support.SFunction;
|
||||||
|
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||||
|
import com.luqj.util.HttpHelper;
|
||||||
|
import com.ruoyi.common.select.SelectItem;
|
||||||
|
import com.ruoyi.common.utils.DateUtils;
|
||||||
|
import com.ruoyi.common.utils.SecurityUtils;
|
||||||
|
import com.ruoyi.common.utils.StringUtils;
|
||||||
|
import com.ruoyi.system.domain.DmPlayerConfig;
|
||||||
|
import com.ruoyi.system.domain.DmPlayerConfigPlus;
|
||||||
|
import com.ruoyi.system.mapper.DmPlayerConfigMapper;
|
||||||
|
import com.ruoyi.system.service.IDmPlayerConfigService;
|
||||||
|
import lombok.extern.slf4j.Slf4j;
|
||||||
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
|
import org.springframework.beans.factory.annotation.Value;
|
||||||
|
import org.springframework.jdbc.core.JdbcTemplate;
|
||||||
|
import org.springframework.stereotype.Service;
|
||||||
|
|
||||||
|
import java.net.URLEncoder;
|
||||||
|
import java.util.*;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 玩家配置Service业务层处理
|
||||||
|
*
|
||||||
|
* @author luqj
|
||||||
|
* @date 2026-05-10
|
||||||
|
*/
|
||||||
|
@Slf4j
|
||||||
|
@Service
|
||||||
|
public class DmPlayerConfigServiceImpl extends ServiceImpl<DmPlayerConfigMapper, DmPlayerConfigPlus> implements IDmPlayerConfigService {
|
||||||
|
@Autowired
|
||||||
|
private DmPlayerConfigMapper dmPlayerConfigMapper;
|
||||||
|
@Autowired
|
||||||
|
private JdbcTemplate jdbcTemplate;
|
||||||
|
private HttpHelper httpHelper = new HttpHelper();
|
||||||
|
@Value("${dm.server.ip:192.168.3.103}")
|
||||||
|
private String serverIp;
|
||||||
|
@Value("${dm.server.port:8080}")
|
||||||
|
private Integer serverPort;
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public List<DmPlayerConfigPlus> getByIds(List<Long> ids, SFunction<DmPlayerConfigPlus, ?>... columns) {
|
||||||
|
LambdaQueryWrapper<DmPlayerConfigPlus> lambdaQueryWrapper = new LambdaQueryWrapper<DmPlayerConfigPlus>()
|
||||||
|
.select(columns).in(DmPlayerConfigPlus::getId, ids);
|
||||||
|
return this.list(lambdaQueryWrapper);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public List<SelectItem> select(String keyword) {
|
||||||
|
LambdaQueryWrapper<DmPlayerConfigPlus> lambdaQueryWrapper = new LambdaQueryWrapper<DmPlayerConfigPlus>()
|
||||||
|
.select(DmPlayerConfigPlus::getId, DmPlayerConfigPlus::getPlayerId)
|
||||||
|
.like(DmPlayerConfigPlus::getPlayerId, keyword);
|
||||||
|
List<DmPlayerConfigPlus> list = this.list(lambdaQueryWrapper);
|
||||||
|
List<SelectItem> result = new ArrayList<>();
|
||||||
|
for (DmPlayerConfigPlus item : list) {
|
||||||
|
SelectItem selectItem = new SelectItem();
|
||||||
|
selectItem.setName(item.getPlayerId() + "");
|
||||||
|
selectItem.setId(item.getId());
|
||||||
|
result.add(selectItem);
|
||||||
|
}
|
||||||
|
return result;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public DmPlayerConfigPlus getById(Long id, SFunction<DmPlayerConfigPlus, ?>... columns) {
|
||||||
|
LambdaQueryWrapper<DmPlayerConfigPlus> lambdaQueryWrapper = new LambdaQueryWrapper<DmPlayerConfigPlus>()
|
||||||
|
.select(columns).eq(DmPlayerConfigPlus::getId, id);
|
||||||
|
return baseMapper.selectOne(lambdaQueryWrapper);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public Map<Long, DmPlayerConfigPlus> getMapByIds(List<Long> ids, SFunction<DmPlayerConfigPlus, ?>... columns) {
|
||||||
|
List<DmPlayerConfigPlus> list = this.getByIds(ids, columns);
|
||||||
|
Map<Long, DmPlayerConfigPlus> map = new HashMap<>();
|
||||||
|
for (DmPlayerConfigPlus item : list) {
|
||||||
|
map.put(item.getId(), item);
|
||||||
|
}
|
||||||
|
return map;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public Map<Long, DmPlayerConfigPlus> getMapByIds(List<Long> ids) {
|
||||||
|
List<DmPlayerConfigPlus> list = this.getByIds(ids);
|
||||||
|
Map<Long, DmPlayerConfigPlus> map = new HashMap<>();
|
||||||
|
for (DmPlayerConfigPlus item : list) {
|
||||||
|
map.put(item.getId(), item);
|
||||||
|
}
|
||||||
|
return map;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public Map<Long, DmPlayerConfigPlus> getMapByPlayerIds(List<Long> ids) {
|
||||||
|
LambdaQueryWrapper<DmPlayerConfigPlus> lambdaQueryWrapper = new LambdaQueryWrapper<DmPlayerConfigPlus>()
|
||||||
|
.in(DmPlayerConfigPlus::getPlayerId, ids);
|
||||||
|
List<DmPlayerConfigPlus> list = this.list(lambdaQueryWrapper);
|
||||||
|
Map<Long, DmPlayerConfigPlus> map = new HashMap<>();
|
||||||
|
for (DmPlayerConfigPlus item : list) {
|
||||||
|
map.put(item.getId(), item);
|
||||||
|
}
|
||||||
|
return map;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public List<DmPlayerConfigPlus> getByIds(List<Long> ids) {
|
||||||
|
LambdaQueryWrapper<DmPlayerConfigPlus> lambdaQueryWrapper = new LambdaQueryWrapper<DmPlayerConfigPlus>().in(DmPlayerConfigPlus::getId, ids);
|
||||||
|
return this.list(lambdaQueryWrapper);
|
||||||
|
}
|
||||||
|
|
||||||
|
public <T> T sum(String field, String where, Class<T> tClass) {
|
||||||
|
StringBuffer stringBuffer = new StringBuffer();
|
||||||
|
stringBuffer.append("select ");
|
||||||
|
stringBuffer.append(" sum(" + field + ") as total ");
|
||||||
|
stringBuffer.append(" from dm_player_config ");
|
||||||
|
if (StringUtils.isNotBlank(where)) {
|
||||||
|
stringBuffer.append(" where ");
|
||||||
|
stringBuffer.append(where);
|
||||||
|
}
|
||||||
|
T result = jdbcTemplate.queryForObject(stringBuffer.toString(), tClass);
|
||||||
|
return result;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Long count(String where) {
|
||||||
|
StringBuffer stringBuffer = new StringBuffer();
|
||||||
|
stringBuffer.append("select ");
|
||||||
|
stringBuffer.append(" count(1)");
|
||||||
|
stringBuffer.append(" from ");
|
||||||
|
stringBuffer.append(" dm_player_config ");
|
||||||
|
if (StringUtils.isNotBlank(where)) {
|
||||||
|
stringBuffer.append(" where ");
|
||||||
|
stringBuffer.append(where);
|
||||||
|
}
|
||||||
|
Long result = jdbcTemplate.queryForObject(stringBuffer.toString(), Long.class);
|
||||||
|
return result;
|
||||||
|
}
|
||||||
|
|
||||||
|
public <T> List<T> countByGroupBy(String select, String where, String groupby, Class<T> tClass) {
|
||||||
|
StringBuffer stringBuffer = new StringBuffer();
|
||||||
|
stringBuffer.append("select ");
|
||||||
|
stringBuffer.append(select);
|
||||||
|
stringBuffer.append(" from ");
|
||||||
|
stringBuffer.append(" dm_player_config ");
|
||||||
|
if (StringUtils.isNotBlank(where)) {
|
||||||
|
stringBuffer.append(" where ");
|
||||||
|
stringBuffer.append(where);
|
||||||
|
}
|
||||||
|
stringBuffer.append(" group by ");
|
||||||
|
stringBuffer.append(groupby);
|
||||||
|
List result = jdbcTemplate.queryForList(stringBuffer.toString());
|
||||||
|
List<T> tList = JSONArray.parseArray(JSONArray.toJSONString(result), tClass);
|
||||||
|
return tList;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查询玩家配置
|
||||||
|
*
|
||||||
|
* @param id 玩家配置ID
|
||||||
|
* @return 玩家配置
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public DmPlayerConfig selectDmPlayerConfigById(Long id) {
|
||||||
|
return dmPlayerConfigMapper.selectDmPlayerConfigById(id);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public DmPlayerConfig selectDmPlayerConfigByPlayerId(Long playerId) {
|
||||||
|
DmPlayerConfig dmPlayerConfig = dmPlayerConfigMapper.selectDmPlayerConfigByPlayerId(playerId);
|
||||||
|
if (dmPlayerConfig == null) {
|
||||||
|
DmPlayerConfig playerConfigPlus = new DmPlayerConfig();
|
||||||
|
playerConfigPlus.setPlayerId(playerId);
|
||||||
|
playerConfigPlus.setAutoAddMana(0);
|
||||||
|
playerConfigPlus.setAddManaThreshold(10);
|
||||||
|
playerConfigPlus.setCreateTime(new Date());
|
||||||
|
playerConfigPlus.setYoloHeight(100);
|
||||||
|
playerConfigPlus.setYoloWidth(100);
|
||||||
|
playerConfigPlus.setCustomParams("");
|
||||||
|
playerConfigPlus.setUpdateTime(new Date());
|
||||||
|
playerConfigPlus.setFixedDirection(0);
|
||||||
|
playerConfigPlus.setShoutInterval(12000);
|
||||||
|
playerConfigPlus.setShoutMana(55);
|
||||||
|
playerConfigPlus.setShoutKey(69);
|
||||||
|
this.dmPlayerConfigMapper.insertDmPlayerConfig(playerConfigPlus);
|
||||||
|
return playerConfigPlus;
|
||||||
|
}
|
||||||
|
return dmPlayerConfig;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查询玩家配置列表
|
||||||
|
*
|
||||||
|
* @param dmPlayerConfig 玩家配置
|
||||||
|
* @return 玩家配置
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public List<DmPlayerConfig> selectDmPlayerConfigList(DmPlayerConfig dmPlayerConfig) {
|
||||||
|
return dmPlayerConfigMapper.selectDmPlayerConfigList(dmPlayerConfig);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 新增玩家配置
|
||||||
|
*
|
||||||
|
* @param dmPlayerConfig 玩家配置
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public int insertDmPlayerConfig(DmPlayerConfig dmPlayerConfig) {
|
||||||
|
dmPlayerConfig.setCreateTime(DateUtils.getNowDate());
|
||||||
|
return dmPlayerConfigMapper.insertDmPlayerConfig(dmPlayerConfig);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 修改玩家配置
|
||||||
|
*
|
||||||
|
* @param dmPlayerConfig 玩家配置
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public int updateDmPlayerConfig(DmPlayerConfig dmPlayerConfig) {
|
||||||
|
dmPlayerConfig.setUpdateTime(DateUtils.getNowDate());
|
||||||
|
int resutl = dmPlayerConfigMapper.updateDmPlayerConfig(dmPlayerConfig);
|
||||||
|
if (resutl > 0) {
|
||||||
|
try {
|
||||||
|
JSONObject params = new JSONObject();
|
||||||
|
params.put("playerId", dmPlayerConfig.getPlayerId());
|
||||||
|
params.put("dates", Base64.getEncoder().encodeToString(JSONObject.toJSONString(dmPlayerConfig).getBytes()));
|
||||||
|
String result = httpHelper.getlHttpResult("http://" + this.serverIp + ":" + serverPort + "?cmd=8¶ms=" + URLEncoder.encode(JSONObject.toJSONString(params), "utf-8")
|
||||||
|
, "get", new HashMap<>(), new HashMap<>());
|
||||||
|
JSONObject jsonObject = JSONObject.parseObject(result);
|
||||||
|
if (jsonObject.getString("code").equals("1")) {
|
||||||
|
log.info("配置同步成功");
|
||||||
|
} else {
|
||||||
|
log.error("配置同步失败");
|
||||||
|
}
|
||||||
|
} catch (Exception e) {
|
||||||
|
throw new RuntimeException(e);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return resutl;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 批量删除玩家配置
|
||||||
|
*
|
||||||
|
* @param ids 需要删除的玩家配置ID
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public int deleteDmPlayerConfigByIds(Long[] ids) {
|
||||||
|
return dmPlayerConfigMapper.deleteDmPlayerConfigByIds(ids);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除玩家配置信息
|
||||||
|
*
|
||||||
|
* @param id 玩家配置ID
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public int deleteDmPlayerConfigById(Long id) {
|
||||||
|
return dmPlayerConfigMapper.deleteDmPlayerConfigById(id);
|
||||||
|
}
|
||||||
|
}
|
||||||
+208
@@ -0,0 +1,208 @@
|
|||||||
|
package com.ruoyi.system.service.impl;
|
||||||
|
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
|
||||||
|
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
||||||
|
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||||
|
import com.github.pagehelper.PageHelper;
|
||||||
|
import com.baomidou.mybatisplus.core.toolkit.support.SFunction;
|
||||||
|
|
||||||
|
import java.util.ArrayList;
|
||||||
|
import java.util.HashMap;
|
||||||
|
import com.ruoyi.common.utils.StringUtils;
|
||||||
|
import com.alibaba.fastjson.JSONArray;
|
||||||
|
import java.util.List;
|
||||||
|
import java.util.Map;
|
||||||
|
import com.ruoyi.common.utils.DateUtils;
|
||||||
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
|
import org.springframework.stereotype.Service;
|
||||||
|
import com.ruoyi.system.mapper.DmPlayerTaskGroupMapper;
|
||||||
|
import com.ruoyi.system.domain.DmPlayerTaskGroup;
|
||||||
|
import com.ruoyi.system.domain.DmPlayerTaskGroupPlus;
|
||||||
|
import com.ruoyi.system.service.IDmPlayerTaskGroupService;
|
||||||
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
|
import org.springframework.jdbc.core.JdbcTemplate;
|
||||||
|
import com.ruoyi.common.select.SelectItem;
|
||||||
|
/**
|
||||||
|
* 大漠任务组Service业务层处理
|
||||||
|
*
|
||||||
|
* @author luqj
|
||||||
|
* @date 2026-05-14
|
||||||
|
*/
|
||||||
|
@Service
|
||||||
|
public class DmPlayerTaskGroupServiceImpl extends ServiceImpl<DmPlayerTaskGroupMapper, DmPlayerTaskGroupPlus> implements IDmPlayerTaskGroupService
|
||||||
|
{
|
||||||
|
@Autowired
|
||||||
|
private DmPlayerTaskGroupMapper dmPlayerTaskGroupMapper;
|
||||||
|
@Autowired
|
||||||
|
private JdbcTemplate jdbcTemplate;
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public List<DmPlayerTaskGroupPlus> getByIds(List<Long> ids, SFunction<DmPlayerTaskGroupPlus, ?>... columns) {
|
||||||
|
LambdaQueryWrapper<DmPlayerTaskGroupPlus> lambdaQueryWrapper = new LambdaQueryWrapper<DmPlayerTaskGroupPlus>()
|
||||||
|
.select(columns).in(DmPlayerTaskGroupPlus::getId, ids);
|
||||||
|
return this.list(lambdaQueryWrapper);
|
||||||
|
}
|
||||||
|
@Override
|
||||||
|
public List<SelectItem> select(String keyword) {
|
||||||
|
LambdaQueryWrapper<DmPlayerTaskGroupPlus> lambdaQueryWrapper = new LambdaQueryWrapper<DmPlayerTaskGroupPlus>()
|
||||||
|
.select(DmPlayerTaskGroupPlus::getId, DmPlayerTaskGroupPlus::getGroupName)
|
||||||
|
.like(DmPlayerTaskGroupPlus::getGroupName, keyword);
|
||||||
|
List<DmPlayerTaskGroupPlus> list = this.list(lambdaQueryWrapper);
|
||||||
|
List<SelectItem> result =new ArrayList<>();
|
||||||
|
for (DmPlayerTaskGroupPlus item : list){
|
||||||
|
SelectItem selectItem = new SelectItem();
|
||||||
|
selectItem.setName(item.getGroupName());
|
||||||
|
selectItem.setId(item.getId());
|
||||||
|
result.add(selectItem);
|
||||||
|
}
|
||||||
|
return result;
|
||||||
|
}
|
||||||
|
@Override
|
||||||
|
public DmPlayerTaskGroupPlus getById(Long id, SFunction<DmPlayerTaskGroupPlus, ?>... columns) {
|
||||||
|
LambdaQueryWrapper<DmPlayerTaskGroupPlus> lambdaQueryWrapper = new LambdaQueryWrapper<DmPlayerTaskGroupPlus>()
|
||||||
|
.select(columns).eq(DmPlayerTaskGroupPlus::getId, id);
|
||||||
|
return baseMapper.selectOne(lambdaQueryWrapper);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public Map<Long, DmPlayerTaskGroupPlus> getMapByIds(List<Long> ids, SFunction<DmPlayerTaskGroupPlus, ?>... columns) {
|
||||||
|
List<DmPlayerTaskGroupPlus> list = this.getByIds(ids, columns);
|
||||||
|
Map<Long, DmPlayerTaskGroupPlus> map = new HashMap<>();
|
||||||
|
for (DmPlayerTaskGroupPlus item : list) {
|
||||||
|
map.put(item.getId(), item);
|
||||||
|
}
|
||||||
|
return map;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public Map<Long, DmPlayerTaskGroupPlus> getMapByIds(List<Long> ids) {
|
||||||
|
List<DmPlayerTaskGroupPlus> list = this.getByIds(ids);
|
||||||
|
Map<Long, DmPlayerTaskGroupPlus> map = new HashMap<>();
|
||||||
|
for (DmPlayerTaskGroupPlus item : list) {
|
||||||
|
map.put(item.getId(), item);
|
||||||
|
}
|
||||||
|
return map;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public List<DmPlayerTaskGroupPlus> getByIds(List<Long> ids) {
|
||||||
|
LambdaQueryWrapper<DmPlayerTaskGroupPlus> lambdaQueryWrapper = new LambdaQueryWrapper<DmPlayerTaskGroupPlus>().in(DmPlayerTaskGroupPlus::getId, ids);
|
||||||
|
return this.list(lambdaQueryWrapper);
|
||||||
|
}
|
||||||
|
|
||||||
|
public <T> T sum(String field, String where, Class<T> tClass) {
|
||||||
|
StringBuffer stringBuffer = new StringBuffer();
|
||||||
|
stringBuffer.append("select ");
|
||||||
|
stringBuffer.append(" sum(" + field + ") as total ");
|
||||||
|
stringBuffer.append(" from dm_player_task_group ");
|
||||||
|
if (StringUtils.isNotBlank(where)) {
|
||||||
|
stringBuffer.append(" where ");
|
||||||
|
stringBuffer.append(where);
|
||||||
|
}
|
||||||
|
T result = jdbcTemplate.queryForObject(stringBuffer.toString(), tClass);
|
||||||
|
return result;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Long count(String where) {
|
||||||
|
StringBuffer stringBuffer = new StringBuffer();
|
||||||
|
stringBuffer.append("select ");
|
||||||
|
stringBuffer.append(" count(1)");
|
||||||
|
stringBuffer.append(" from ");
|
||||||
|
stringBuffer.append(" dm_player_task_group ");
|
||||||
|
if (StringUtils.isNotBlank(where)) {
|
||||||
|
stringBuffer.append(" where ");
|
||||||
|
stringBuffer.append(where);
|
||||||
|
}
|
||||||
|
Long result = jdbcTemplate.queryForObject(stringBuffer.toString(), Long.class);
|
||||||
|
return result;
|
||||||
|
}
|
||||||
|
|
||||||
|
public <T> List<T> countByGroupBy(String select, String where, String groupby, Class<T> tClass) {
|
||||||
|
StringBuffer stringBuffer = new StringBuffer();
|
||||||
|
stringBuffer.append("select ");
|
||||||
|
stringBuffer.append(select);
|
||||||
|
stringBuffer.append(" from ");
|
||||||
|
stringBuffer.append(" dm_player_task_group ");
|
||||||
|
if (StringUtils.isNotBlank(where)) {
|
||||||
|
stringBuffer.append(" where ");
|
||||||
|
stringBuffer.append(where);
|
||||||
|
}
|
||||||
|
stringBuffer.append(" group by ");
|
||||||
|
stringBuffer.append(groupby);
|
||||||
|
List result = jdbcTemplate.queryForList(stringBuffer.toString());
|
||||||
|
List<T> tList = JSONArray.parseArray(JSONArray.toJSONString(result), tClass);
|
||||||
|
return tList;
|
||||||
|
}
|
||||||
|
/**
|
||||||
|
* 查询大漠任务组
|
||||||
|
*
|
||||||
|
* @param id 大漠任务组ID
|
||||||
|
* @return 大漠任务组
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public DmPlayerTaskGroup selectDmPlayerTaskGroupById(Long id)
|
||||||
|
{
|
||||||
|
return dmPlayerTaskGroupMapper.selectDmPlayerTaskGroupById(id);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查询大漠任务组列表
|
||||||
|
*
|
||||||
|
* @param dmPlayerTaskGroup 大漠任务组
|
||||||
|
* @return 大漠任务组
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public List<DmPlayerTaskGroup> selectDmPlayerTaskGroupList(DmPlayerTaskGroup dmPlayerTaskGroup)
|
||||||
|
{
|
||||||
|
return dmPlayerTaskGroupMapper.selectDmPlayerTaskGroupList(dmPlayerTaskGroup);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 新增大漠任务组
|
||||||
|
*
|
||||||
|
* @param dmPlayerTaskGroup 大漠任务组
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public int insertDmPlayerTaskGroup(DmPlayerTaskGroup dmPlayerTaskGroup)
|
||||||
|
{
|
||||||
|
dmPlayerTaskGroup.setCreateTime(DateUtils.getNowDate());
|
||||||
|
return dmPlayerTaskGroupMapper.insertDmPlayerTaskGroup(dmPlayerTaskGroup);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 修改大漠任务组
|
||||||
|
*
|
||||||
|
* @param dmPlayerTaskGroup 大漠任务组
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public int updateDmPlayerTaskGroup(DmPlayerTaskGroup dmPlayerTaskGroup)
|
||||||
|
{
|
||||||
|
dmPlayerTaskGroup.setUpdateTime(DateUtils.getNowDate());
|
||||||
|
return dmPlayerTaskGroupMapper.updateDmPlayerTaskGroup(dmPlayerTaskGroup);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 批量删除大漠任务组
|
||||||
|
*
|
||||||
|
* @param ids 需要删除的大漠任务组ID
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public int deleteDmPlayerTaskGroupByIds(Long[] ids)
|
||||||
|
{
|
||||||
|
return dmPlayerTaskGroupMapper.deleteDmPlayerTaskGroupByIds(ids);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除大漠任务组信息
|
||||||
|
*
|
||||||
|
* @param id 大漠任务组ID
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public int deleteDmPlayerTaskGroupById(Long id)
|
||||||
|
{
|
||||||
|
return dmPlayerTaskGroupMapper.deleteDmPlayerTaskGroupById(id);
|
||||||
|
}
|
||||||
|
}
|
||||||
+243
@@ -0,0 +1,243 @@
|
|||||||
|
package com.ruoyi.system.service.impl;
|
||||||
|
import com.alibaba.fastjson.JSONObject;
|
||||||
|
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
|
||||||
|
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
||||||
|
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||||
|
import com.github.pagehelper.PageHelper;
|
||||||
|
import com.baomidou.mybatisplus.core.toolkit.support.SFunction;
|
||||||
|
|
||||||
|
import java.net.URLEncoder;
|
||||||
|
import java.util.*;
|
||||||
|
|
||||||
|
import com.luqj.util.HttpHelper;
|
||||||
|
import com.ruoyi.common.utils.StringUtils;
|
||||||
|
import com.alibaba.fastjson.JSONArray;
|
||||||
|
import com.ruoyi.common.utils.DateUtils;
|
||||||
|
import com.ruoyi.system.domain.DmVersionUpdateVo;
|
||||||
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
|
import org.springframework.beans.factory.annotation.Value;
|
||||||
|
import org.springframework.stereotype.Service;
|
||||||
|
import com.ruoyi.system.mapper.DmPlayerVersionMapper;
|
||||||
|
import com.ruoyi.system.domain.DmPlayerVersion;
|
||||||
|
import com.ruoyi.system.domain.DmPlayerVersionPlus;
|
||||||
|
import com.ruoyi.system.service.IDmPlayerVersionService;
|
||||||
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
|
import org.springframework.jdbc.core.JdbcTemplate;
|
||||||
|
import com.ruoyi.common.select.SelectItem;
|
||||||
|
/**
|
||||||
|
* 版本信息Service业务层处理
|
||||||
|
*
|
||||||
|
* @author luqj
|
||||||
|
* @date 2026-05-14
|
||||||
|
*/
|
||||||
|
@Service
|
||||||
|
public class DmPlayerVersionServiceImpl extends ServiceImpl<DmPlayerVersionMapper, DmPlayerVersionPlus> implements IDmPlayerVersionService
|
||||||
|
{
|
||||||
|
@Value("${dm.server.ip:192.168.3.103}")
|
||||||
|
private String serverIp;
|
||||||
|
@Value("${dm.server.port:8080}")
|
||||||
|
private Integer serverPort;
|
||||||
|
private HttpHelper httpHelper = new HttpHelper();
|
||||||
|
@Autowired
|
||||||
|
private DmPlayerVersionMapper dmPlayerVersionMapper;
|
||||||
|
@Autowired
|
||||||
|
private JdbcTemplate jdbcTemplate;
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public List<DmPlayerVersionPlus> getByIds(List<Long> ids, SFunction<DmPlayerVersionPlus, ?>... columns) {
|
||||||
|
LambdaQueryWrapper<DmPlayerVersionPlus> lambdaQueryWrapper = new LambdaQueryWrapper<DmPlayerVersionPlus>()
|
||||||
|
.select(columns).in(DmPlayerVersionPlus::getId, ids);
|
||||||
|
return this.list(lambdaQueryWrapper);
|
||||||
|
}
|
||||||
|
@Override
|
||||||
|
public List<SelectItem> select(String keyword) {
|
||||||
|
LambdaQueryWrapper<DmPlayerVersionPlus> lambdaQueryWrapper = new LambdaQueryWrapper<DmPlayerVersionPlus>()
|
||||||
|
.select(DmPlayerVersionPlus::getId, DmPlayerVersionPlus::getTitle)
|
||||||
|
.like(DmPlayerVersionPlus::getTitle, keyword);
|
||||||
|
List<DmPlayerVersionPlus> list = this.list(lambdaQueryWrapper);
|
||||||
|
List<SelectItem> result =new ArrayList<>();
|
||||||
|
for (DmPlayerVersionPlus item : list){
|
||||||
|
SelectItem selectItem = new SelectItem();
|
||||||
|
selectItem.setName(item.getTitle());
|
||||||
|
selectItem.setId(item.getId());
|
||||||
|
result.add(selectItem);
|
||||||
|
}
|
||||||
|
return result;
|
||||||
|
}
|
||||||
|
@Override
|
||||||
|
public DmPlayerVersionPlus getById(Long id, SFunction<DmPlayerVersionPlus, ?>... columns) {
|
||||||
|
LambdaQueryWrapper<DmPlayerVersionPlus> lambdaQueryWrapper = new LambdaQueryWrapper<DmPlayerVersionPlus>()
|
||||||
|
.select(columns).eq(DmPlayerVersionPlus::getId, id);
|
||||||
|
return baseMapper.selectOne(lambdaQueryWrapper);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public Map<Long, DmPlayerVersionPlus> getMapByIds(List<Long> ids, SFunction<DmPlayerVersionPlus, ?>... columns) {
|
||||||
|
List<DmPlayerVersionPlus> list = this.getByIds(ids, columns);
|
||||||
|
Map<Long, DmPlayerVersionPlus> map = new HashMap<>();
|
||||||
|
for (DmPlayerVersionPlus item : list) {
|
||||||
|
map.put(item.getId(), item);
|
||||||
|
}
|
||||||
|
return map;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public Map<Long, DmPlayerVersionPlus> getMapByIds(List<Long> ids) {
|
||||||
|
List<DmPlayerVersionPlus> list = this.getByIds(ids);
|
||||||
|
Map<Long, DmPlayerVersionPlus> map = new HashMap<>();
|
||||||
|
for (DmPlayerVersionPlus item : list) {
|
||||||
|
map.put(item.getId(), item);
|
||||||
|
}
|
||||||
|
return map;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public List<DmPlayerVersionPlus> getByIds(List<Long> ids) {
|
||||||
|
LambdaQueryWrapper<DmPlayerVersionPlus> lambdaQueryWrapper = new LambdaQueryWrapper<DmPlayerVersionPlus>().in(DmPlayerVersionPlus::getId, ids);
|
||||||
|
return this.list(lambdaQueryWrapper);
|
||||||
|
}
|
||||||
|
|
||||||
|
public <T> T sum(String field, String where, Class<T> tClass) {
|
||||||
|
StringBuffer stringBuffer = new StringBuffer();
|
||||||
|
stringBuffer.append("select ");
|
||||||
|
stringBuffer.append(" sum(" + field + ") as total ");
|
||||||
|
stringBuffer.append(" from dm_player_version ");
|
||||||
|
if (StringUtils.isNotBlank(where)) {
|
||||||
|
stringBuffer.append(" where ");
|
||||||
|
stringBuffer.append(where);
|
||||||
|
}
|
||||||
|
T result = jdbcTemplate.queryForObject(stringBuffer.toString(), tClass);
|
||||||
|
return result;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Long count(String where) {
|
||||||
|
StringBuffer stringBuffer = new StringBuffer();
|
||||||
|
stringBuffer.append("select ");
|
||||||
|
stringBuffer.append(" count(1)");
|
||||||
|
stringBuffer.append(" from ");
|
||||||
|
stringBuffer.append(" dm_player_version ");
|
||||||
|
if (StringUtils.isNotBlank(where)) {
|
||||||
|
stringBuffer.append(" where ");
|
||||||
|
stringBuffer.append(where);
|
||||||
|
}
|
||||||
|
Long result = jdbcTemplate.queryForObject(stringBuffer.toString(), Long.class);
|
||||||
|
return result;
|
||||||
|
}
|
||||||
|
|
||||||
|
public <T> List<T> countByGroupBy(String select, String where, String groupby, Class<T> tClass) {
|
||||||
|
StringBuffer stringBuffer = new StringBuffer();
|
||||||
|
stringBuffer.append("select ");
|
||||||
|
stringBuffer.append(select);
|
||||||
|
stringBuffer.append(" from ");
|
||||||
|
stringBuffer.append(" dm_player_version ");
|
||||||
|
if (StringUtils.isNotBlank(where)) {
|
||||||
|
stringBuffer.append(" where ");
|
||||||
|
stringBuffer.append(where);
|
||||||
|
}
|
||||||
|
stringBuffer.append(" group by ");
|
||||||
|
stringBuffer.append(groupby);
|
||||||
|
List result = jdbcTemplate.queryForList(stringBuffer.toString());
|
||||||
|
List<T> tList = JSONArray.parseArray(JSONArray.toJSONString(result), tClass);
|
||||||
|
return tList;
|
||||||
|
}
|
||||||
|
/**
|
||||||
|
* 查询版本信息
|
||||||
|
*
|
||||||
|
* @param id 版本信息ID
|
||||||
|
* @return 版本信息
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public DmPlayerVersion selectDmPlayerVersionById(Long id)
|
||||||
|
{
|
||||||
|
return dmPlayerVersionMapper.selectDmPlayerVersionById(id);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 查询版本信息列表
|
||||||
|
*
|
||||||
|
* @param dmPlayerVersion 版本信息
|
||||||
|
* @return 版本信息
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public List<DmPlayerVersion> selectDmPlayerVersionList(DmPlayerVersion dmPlayerVersion)
|
||||||
|
{
|
||||||
|
return dmPlayerVersionMapper.selectDmPlayerVersionList(dmPlayerVersion);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 新增版本信息
|
||||||
|
*
|
||||||
|
* @param dmPlayerVersion 版本信息
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public int insertDmPlayerVersion(DmPlayerVersion dmPlayerVersion)
|
||||||
|
{
|
||||||
|
dmPlayerVersion.setCreateTime(DateUtils.getNowDate());
|
||||||
|
return dmPlayerVersionMapper.insertDmPlayerVersion(dmPlayerVersion);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public boolean playerentUpdate(DmVersionUpdateVo vo) {
|
||||||
|
DmPlayerVersion dmPlayerVersion = this.selectDmPlayerVersionById(vo.getId());
|
||||||
|
for(Long playerId : vo.getPlayerIds()){
|
||||||
|
try {
|
||||||
|
JSONObject params = new JSONObject();
|
||||||
|
params.put("playerId", playerId);
|
||||||
|
JSONObject version = new JSONObject();
|
||||||
|
version.put("version",dmPlayerVersion.getVersionNum());
|
||||||
|
version.put("url",dmPlayerVersion.getProxyUrl());
|
||||||
|
version.put("configVersion",dmPlayerVersion.getVersionNum());
|
||||||
|
version.put("configUrl",dmPlayerVersion.getConfigUrl());
|
||||||
|
params.put("versionInfo", Base64.getEncoder().encodeToString(JSONObject.toJSONString(version).getBytes()));
|
||||||
|
String result = httpHelper.getlHttpResult("http://" + this.serverIp + ":" + serverPort + "?cmd=9¶ms=" + URLEncoder.encode(JSONObject.toJSONString(params), "utf-8")
|
||||||
|
, "get", new HashMap<>(), new HashMap<>());
|
||||||
|
JSONObject jsonObject = JSONObject.parseObject(result);
|
||||||
|
if (jsonObject.getString("code").equals("1")) {
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
System.out.println(result);
|
||||||
|
} catch (Exception e) {
|
||||||
|
throw new RuntimeException(e);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 修改版本信息
|
||||||
|
*
|
||||||
|
* @param dmPlayerVersion 版本信息
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public int updateDmPlayerVersion(DmPlayerVersion dmPlayerVersion)
|
||||||
|
{
|
||||||
|
dmPlayerVersion.setUpdateTime(DateUtils.getNowDate());
|
||||||
|
return dmPlayerVersionMapper.updateDmPlayerVersion(dmPlayerVersion);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 批量删除版本信息
|
||||||
|
*
|
||||||
|
* @param ids 需要删除的版本信息ID
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public int deleteDmPlayerVersionByIds(Long[] ids)
|
||||||
|
{
|
||||||
|
return dmPlayerVersionMapper.deleteDmPlayerVersionByIds(ids);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除版本信息信息
|
||||||
|
*
|
||||||
|
* @param id 版本信息ID
|
||||||
|
* @return 结果
|
||||||
|
*/
|
||||||
|
@Override
|
||||||
|
public int deleteDmPlayerVersionById(Long id)
|
||||||
|
{
|
||||||
|
return dmPlayerVersionMapper.deleteDmPlayerVersionById(id);
|
||||||
|
}
|
||||||
|
}
|
||||||
+127
-8
@@ -8,22 +8,24 @@ import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
|||||||
import com.luqj.util.HttpHelper;
|
import com.luqj.util.HttpHelper;
|
||||||
import com.ruoyi.common.select.SelectItem;
|
import com.ruoyi.common.select.SelectItem;
|
||||||
import com.ruoyi.common.utils.DateUtils;
|
import com.ruoyi.common.utils.DateUtils;
|
||||||
|
import com.ruoyi.common.utils.SecurityUtils;
|
||||||
import com.ruoyi.common.utils.StringUtils;
|
import com.ruoyi.common.utils.StringUtils;
|
||||||
|
import com.ruoyi.common.utils.TokenUtil;
|
||||||
import com.ruoyi.system.domain.DmOperateVo;
|
import com.ruoyi.system.domain.DmOperateVo;
|
||||||
|
import com.ruoyi.system.domain.DmPlayerConfigPlus;
|
||||||
import com.ruoyi.system.domain.DmPlayerent;
|
import com.ruoyi.system.domain.DmPlayerent;
|
||||||
import com.ruoyi.system.domain.DmPlayerentPlus;
|
import com.ruoyi.system.domain.DmPlayerentPlus;
|
||||||
import com.ruoyi.system.mapper.DmPlayerentMapper;
|
import com.ruoyi.system.mapper.DmPlayerentMapper;
|
||||||
|
import com.ruoyi.system.service.IDmPlayerConfigService;
|
||||||
import com.ruoyi.system.service.IDmPlayerentService;
|
import com.ruoyi.system.service.IDmPlayerentService;
|
||||||
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
import org.springframework.beans.factory.annotation.Value;
|
import org.springframework.beans.factory.annotation.Value;
|
||||||
|
import org.springframework.context.annotation.Lazy;
|
||||||
import org.springframework.jdbc.core.JdbcTemplate;
|
import org.springframework.jdbc.core.JdbcTemplate;
|
||||||
import org.springframework.stereotype.Service;
|
import org.springframework.stereotype.Service;
|
||||||
|
|
||||||
import java.net.URLEncoder;
|
import java.net.URLEncoder;
|
||||||
import java.util.ArrayList;
|
import java.util.*;
|
||||||
import java.util.HashMap;
|
|
||||||
import java.util.List;
|
|
||||||
import java.util.Map;
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 大漠代理Service业务层处理
|
* 大漠代理Service业务层处理
|
||||||
@@ -36,6 +38,9 @@ public class DmPlayerentServiceImpl extends ServiceImpl<DmPlayerentMapper, DmPla
|
|||||||
private HttpHelper httpHelper = new HttpHelper();
|
private HttpHelper httpHelper = new HttpHelper();
|
||||||
@Autowired
|
@Autowired
|
||||||
private DmPlayerentMapper dmPlayerentMapper;
|
private DmPlayerentMapper dmPlayerentMapper;
|
||||||
|
@Lazy
|
||||||
|
@Autowired
|
||||||
|
private IDmPlayerConfigService playerConfigService;
|
||||||
@Autowired
|
@Autowired
|
||||||
private JdbcTemplate jdbcTemplate;
|
private JdbcTemplate jdbcTemplate;
|
||||||
@Value("${dm.server.ip:192.168.3.103}")
|
@Value("${dm.server.ip:192.168.3.103}")
|
||||||
@@ -151,7 +156,22 @@ public class DmPlayerentServiceImpl extends ServiceImpl<DmPlayerentMapper, DmPla
|
|||||||
*/
|
*/
|
||||||
@Override
|
@Override
|
||||||
public DmPlayerent selectDmPlayerentById(Long id) {
|
public DmPlayerent selectDmPlayerentById(Long id) {
|
||||||
return dmPlayerentMapper.selectDmPlayerentById(id);
|
DmPlayerent dmPlayerent = dmPlayerentMapper.selectDmPlayerentById(id);
|
||||||
|
// dmPlayerent.setMjpegUrl("http://gitlab.chatshop.com.cn:880/"+
|
||||||
|
// dmPlayerent.getIp()+"/mjpeg/stream?token="
|
||||||
|
// + TokenUtil.generateToken(dmPlayerent.getId() + "", dmPlayerent.getSecret()));
|
||||||
|
dmPlayerent.setMjpegUrl("http://" + dmPlayerent.getIp() + ":8888/stream?token="
|
||||||
|
+ TokenUtil.generateToken(dmPlayerent.getId() + "", dmPlayerent.getSecret()));
|
||||||
|
dmPlayerent.setSecret(null);
|
||||||
|
if (null != SecurityUtils.getUserId() && SecurityUtils.getUserId() == 1L) {
|
||||||
|
return dmPlayerent;
|
||||||
|
} else {
|
||||||
|
if (dmPlayerent.getAccountid().longValue() == SecurityUtils.getUserId()) {
|
||||||
|
return dmPlayerent;
|
||||||
|
} else {
|
||||||
|
throw new RuntimeException("没有权限");
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -162,7 +182,41 @@ public class DmPlayerentServiceImpl extends ServiceImpl<DmPlayerentMapper, DmPla
|
|||||||
*/
|
*/
|
||||||
@Override
|
@Override
|
||||||
public List<DmPlayerent> selectDmPlayerentList(DmPlayerent dmPlayerent) {
|
public List<DmPlayerent> selectDmPlayerentList(DmPlayerent dmPlayerent) {
|
||||||
return dmPlayerentMapper.selectDmPlayerentList(dmPlayerent);
|
if (null != SecurityUtils.getUserId() && SecurityUtils.getUserId() != 1L) {
|
||||||
|
dmPlayerent.setAccountid(SecurityUtils.getUserId());
|
||||||
|
}
|
||||||
|
List<DmPlayerent> list = dmPlayerentMapper.selectDmPlayerentList(dmPlayerent);
|
||||||
|
List<Long> ids = new ArrayList<>();
|
||||||
|
for (DmPlayerent playerent : list) {
|
||||||
|
playerent.setSecret(null);
|
||||||
|
ids.add(playerent.getId());
|
||||||
|
}
|
||||||
|
if (!ids.isEmpty()) {
|
||||||
|
Map<Long, DmPlayerConfigPlus> map = playerConfigService.getMapByPlayerIds(ids);
|
||||||
|
List<DmPlayerConfigPlus> saveList = new ArrayList<>();
|
||||||
|
for (DmPlayerent playerent : list) {
|
||||||
|
if (!map.containsKey(playerent.getId())) {
|
||||||
|
DmPlayerConfigPlus playerConfigPlus = new DmPlayerConfigPlus();
|
||||||
|
playerConfigPlus.setPlayerId(playerent.getId());
|
||||||
|
playerConfigPlus.setAutoAddMana(0);
|
||||||
|
playerConfigPlus.setAddManaThreshold(10);
|
||||||
|
playerConfigPlus.setCreateTime(new Date());
|
||||||
|
playerConfigPlus.setYoloHeight(100);
|
||||||
|
playerConfigPlus.setYoloWidth(100);
|
||||||
|
playerConfigPlus.setCustomParams("");
|
||||||
|
playerConfigPlus.setUpdateTime(new Date());
|
||||||
|
playerConfigPlus.setFixedDirection(0);
|
||||||
|
playerConfigPlus.setShoutInterval(12000);
|
||||||
|
playerConfigPlus.setShoutMana(55);
|
||||||
|
playerConfigPlus.setShoutKey(69);
|
||||||
|
saveList.add(playerConfigPlus);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if (!saveList.isEmpty()) {
|
||||||
|
this.playerConfigService.saveBatch(saveList);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return list;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -173,16 +227,36 @@ public class DmPlayerentServiceImpl extends ServiceImpl<DmPlayerentMapper, DmPla
|
|||||||
*/
|
*/
|
||||||
@Override
|
@Override
|
||||||
public int insertDmPlayerent(DmPlayerent dmPlayerent) {
|
public int insertDmPlayerent(DmPlayerent dmPlayerent) {
|
||||||
|
dmPlayerent.setAccountid(SecurityUtils.getUserId());
|
||||||
dmPlayerent.setCreateTime(DateUtils.getNowDate());
|
dmPlayerent.setCreateTime(DateUtils.getNowDate());
|
||||||
return dmPlayerentMapper.insertDmPlayerent(dmPlayerent);
|
return dmPlayerentMapper.insertDmPlayerent(dmPlayerent);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean operate(DmOperateVo vo) {
|
public boolean operate(DmOperateVo vo) {
|
||||||
|
DmPlayerent dmPlayerent = this.dmPlayerentMapper.selectDmPlayerentById(Long.parseLong(vo.getPlayerId()));
|
||||||
|
if (null != SecurityUtils.getUserId() && SecurityUtils.getUserId() == 1L) {
|
||||||
|
|
||||||
|
} else {
|
||||||
|
if (dmPlayerent.getAccountid().longValue() == SecurityUtils.getUserId()) {
|
||||||
|
} else {
|
||||||
|
throw new RuntimeException("没有权限");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if (dmPlayerent == null) {
|
||||||
|
throw new RuntimeException("找不到对象");
|
||||||
|
}
|
||||||
|
// if (dmPlayerent.getOnlineStatus().equals("0")) {
|
||||||
|
// throw new RuntimeException("设备离线");
|
||||||
|
// }
|
||||||
|
JSONObject params = new JSONObject();
|
||||||
|
params.put("params", "");
|
||||||
if (vo.getType() == null) {
|
if (vo.getType() == null) {
|
||||||
vo.setType(-1);
|
vo.setType(-1);
|
||||||
}
|
}
|
||||||
JSONObject params = new JSONObject();
|
if (vo.getX() != null && vo.getY() != null) {
|
||||||
|
params.put("params", vo.getX() + "|" + vo.getY());
|
||||||
|
}
|
||||||
if (vo.getAction() == 5) { //截图
|
if (vo.getAction() == 5) { //截图
|
||||||
try {
|
try {
|
||||||
params.put("winId", vo.getWinId());
|
params.put("winId", vo.getWinId());
|
||||||
@@ -213,8 +287,34 @@ public class DmPlayerentServiceImpl extends ServiceImpl<DmPlayerentMapper, DmPla
|
|||||||
} catch (Exception e) {
|
} catch (Exception e) {
|
||||||
throw new RuntimeException(e);
|
throw new RuntimeException(e);
|
||||||
}
|
}
|
||||||
|
} else if (vo.getAction() == 9) { //更新版本
|
||||||
|
try {
|
||||||
|
params.put("playerId", vo.getPlayerId());
|
||||||
|
String result = httpHelper.getlHttpResult("http://" + this.serverIp + ":" + serverPort + "?cmd=9¶ms=" + URLEncoder.encode(JSONObject.toJSONString(params), "utf-8")
|
||||||
|
, "get", new HashMap<>(), new HashMap<>());
|
||||||
|
JSONObject jsonObject = JSONObject.parseObject(result);
|
||||||
|
if (jsonObject.getString("code").equals("1")) {
|
||||||
|
return true;
|
||||||
}
|
}
|
||||||
return false;
|
System.out.println(result);
|
||||||
|
} catch (Exception e) {
|
||||||
|
throw new RuntimeException(e);
|
||||||
|
}
|
||||||
|
} else if (vo.getAction() == 10) { //更新版本
|
||||||
|
try {
|
||||||
|
params.put("playerId", vo.getPlayerId());
|
||||||
|
String result = httpHelper.getlHttpResult("http://" + this.serverIp + ":" + serverPort + "?cmd=10¶ms=" + URLEncoder.encode(JSONObject.toJSONString(params), "utf-8")
|
||||||
|
, "get", new HashMap<>(), new HashMap<>());
|
||||||
|
JSONObject jsonObject = JSONObject.parseObject(result);
|
||||||
|
if (jsonObject.getString("code").equals("1")) {
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
System.out.println(result);
|
||||||
|
} catch (Exception e) {
|
||||||
|
throw new RuntimeException(e);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -226,7 +326,15 @@ public class DmPlayerentServiceImpl extends ServiceImpl<DmPlayerentMapper, DmPla
|
|||||||
@Override
|
@Override
|
||||||
public int updateDmPlayerent(DmPlayerent dmPlayerent) {
|
public int updateDmPlayerent(DmPlayerent dmPlayerent) {
|
||||||
dmPlayerent.setUpdateTime(DateUtils.getNowDate());
|
dmPlayerent.setUpdateTime(DateUtils.getNowDate());
|
||||||
|
if (null != SecurityUtils.getUserId() && SecurityUtils.getUserId() == 1L) {
|
||||||
return dmPlayerentMapper.updateDmPlayerent(dmPlayerent);
|
return dmPlayerentMapper.updateDmPlayerent(dmPlayerent);
|
||||||
|
} else {
|
||||||
|
if (dmPlayerent.getAccountid().longValue() == SecurityUtils.getUserId()) {
|
||||||
|
return dmPlayerentMapper.updateDmPlayerent(dmPlayerent);
|
||||||
|
} else {
|
||||||
|
throw new RuntimeException("没有权限");
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -237,7 +345,18 @@ public class DmPlayerentServiceImpl extends ServiceImpl<DmPlayerentMapper, DmPla
|
|||||||
*/
|
*/
|
||||||
@Override
|
@Override
|
||||||
public int deleteDmPlayerentByIds(Long[] ids) {
|
public int deleteDmPlayerentByIds(Long[] ids) {
|
||||||
|
if (null != SecurityUtils.getUserId() && SecurityUtils.getUserId() == 1L) {
|
||||||
return dmPlayerentMapper.deleteDmPlayerentByIds(ids);
|
return dmPlayerentMapper.deleteDmPlayerentByIds(ids);
|
||||||
|
} else {
|
||||||
|
List<DmPlayerentPlus> list = dmPlayerentMapper.selectBatchIds(Arrays.asList(ids));
|
||||||
|
for (int i = 0; i < list.size(); i++) {
|
||||||
|
if (list.get(i).getAccountid().longValue() == SecurityUtils.getUserId()) {
|
||||||
|
} else {
|
||||||
|
throw new RuntimeException("没有权限");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return dmPlayerentMapper.deleteDmPlayerentByIds(ids);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|||||||
@@ -0,0 +1,102 @@
|
|||||||
|
<?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.ruoyi.system.mapper.DmGroupTaskRelationMapper">
|
||||||
|
|
||||||
|
<resultMap type="DmGroupTaskRelation" id="DmGroupTaskRelationResult">
|
||||||
|
<result property="id" column="id" />
|
||||||
|
<result property="groupId" column="group_id" />
|
||||||
|
<result property="playerId" column="player_id" />
|
||||||
|
<result property="playerName" column="player_name" />
|
||||||
|
<result property="accountId" column="account_id" />
|
||||||
|
<result property="windowIndex" column="window_index" />
|
||||||
|
<result property="windowHwnd" column="window_hwnd" />
|
||||||
|
<result property="isMaster" column="is_master" />
|
||||||
|
<result property="status" column="status" />
|
||||||
|
<result property="x" column="x" />
|
||||||
|
<result property="y" column="y" />
|
||||||
|
<result property="createTime" column="create_time" />
|
||||||
|
<result property="updateTime" column="update_time" />
|
||||||
|
</resultMap>
|
||||||
|
|
||||||
|
<sql id="selectDmGroupTaskRelationVo">
|
||||||
|
select id, group_id,`x`,`y`, player_id, player_name, account_id, window_index, window_hwnd, is_master, status, create_time, update_time from dm_group_task_relation
|
||||||
|
</sql>
|
||||||
|
|
||||||
|
<select id="selectDmGroupTaskRelationList" parameterType="DmGroupTaskRelation" resultMap="DmGroupTaskRelationResult">
|
||||||
|
<include refid="selectDmGroupTaskRelationVo"/>
|
||||||
|
<where>
|
||||||
|
<if test="groupId != null "> and group_id = #{groupId}</if>
|
||||||
|
<if test="playerName != null and playerName != ''"> and player_name like concat('%', #{playerName}, '%')</if>
|
||||||
|
<if test="status != null "> and status = #{status}</if>
|
||||||
|
</where>
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<select id="selectDmGroupTaskRelationById" parameterType="Long" resultMap="DmGroupTaskRelationResult">
|
||||||
|
<include refid="selectDmGroupTaskRelationVo"/>
|
||||||
|
where id = #{id}
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<insert id="insertDmGroupTaskRelation" parameterType="DmGroupTaskRelation" useGeneratedKeys="true" keyProperty="id">
|
||||||
|
insert into dm_group_task_relation
|
||||||
|
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||||
|
<if test="groupId != null">group_id,</if>
|
||||||
|
<if test="playerId != null">player_id,</if>
|
||||||
|
<if test="playerName != null">player_name,</if>
|
||||||
|
<if test="accountId != null">account_id,</if>
|
||||||
|
<if test="windowIndex != null">window_index,</if>
|
||||||
|
<if test="windowHwnd != null">window_hwnd,</if>
|
||||||
|
<if test="isMaster != null">is_master,</if>
|
||||||
|
<if test="status != null">status,</if>
|
||||||
|
<if test="createTime != null">create_time,</if>
|
||||||
|
<if test="updateTime != null">update_time,</if>
|
||||||
|
<if test="x != null">`x`,</if>
|
||||||
|
<if test="y != null">`y`,</if>
|
||||||
|
</trim>
|
||||||
|
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||||
|
<if test="groupId != null">#{groupId},</if>
|
||||||
|
<if test="playerId != null">#{playerId},</if>
|
||||||
|
<if test="playerName != null">#{playerName},</if>
|
||||||
|
<if test="accountId != null">#{accountId},</if>
|
||||||
|
<if test="windowIndex != null">#{windowIndex},</if>
|
||||||
|
<if test="windowHwnd != null">#{windowHwnd},</if>
|
||||||
|
<if test="isMaster != null">#{isMaster},</if>
|
||||||
|
<if test="status != null">#{status},</if>
|
||||||
|
<if test="createTime != null">#{createTime},</if>
|
||||||
|
<if test="updateTime != null">#{updateTime},</if>
|
||||||
|
<if test="x != null">#{x},</if>
|
||||||
|
<if test="y != null">#{y},</if>
|
||||||
|
</trim>
|
||||||
|
</insert>
|
||||||
|
|
||||||
|
<update id="updateDmGroupTaskRelation" parameterType="DmGroupTaskRelation">
|
||||||
|
update dm_group_task_relation
|
||||||
|
<trim prefix="SET" suffixOverrides=",">
|
||||||
|
<if test="groupId != null">group_id = #{groupId},</if>
|
||||||
|
<if test="playerId != null">player_id = #{playerId},</if>
|
||||||
|
<if test="playerName != null">player_name = #{playerName},</if>
|
||||||
|
<if test="accountId != null">account_id = #{accountId},</if>
|
||||||
|
<if test="windowIndex != null">window_index = #{windowIndex},</if>
|
||||||
|
<if test="windowHwnd != null">window_hwnd = #{windowHwnd},</if>
|
||||||
|
<if test="isMaster != null">is_master = #{isMaster},</if>
|
||||||
|
<if test="status != null">status = #{status},</if>
|
||||||
|
<if test="createTime != null">create_time = #{createTime},</if>
|
||||||
|
<if test="updateTime != null">update_time = #{updateTime},</if>
|
||||||
|
<if test="x != null">`x` = #{x},</if>
|
||||||
|
<if test="y != null">`y` = #{y},</if>
|
||||||
|
</trim>
|
||||||
|
where id = #{id}
|
||||||
|
</update>
|
||||||
|
|
||||||
|
<delete id="deleteDmGroupTaskRelationById" parameterType="Long">
|
||||||
|
delete from dm_group_task_relation where id = #{id}
|
||||||
|
</delete>
|
||||||
|
|
||||||
|
<delete id="deleteDmGroupTaskRelationByIds" parameterType="String">
|
||||||
|
delete from dm_group_task_relation where id in
|
||||||
|
<foreach item="id" collection="array" open="(" separator="," close=")">
|
||||||
|
#{id}
|
||||||
|
</foreach>
|
||||||
|
</delete>
|
||||||
|
</mapper>
|
||||||
@@ -0,0 +1,104 @@
|
|||||||
|
<?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.ruoyi.system.mapper.DmPlayerConfigMapper">
|
||||||
|
|
||||||
|
<resultMap type="DmPlayerConfig" id="DmPlayerConfigResult">
|
||||||
|
<result property="id" column="id" />
|
||||||
|
<result property="playerId" column="player_id" />
|
||||||
|
<result property="createTime" column="create_time" />
|
||||||
|
<result property="updateTime" column="update_time" />
|
||||||
|
<result property="shoutInterval" column="shout_interval" />
|
||||||
|
<result property="shoutMana" column="shout_mana" />
|
||||||
|
<result property="autoAddMana" column="auto_add_mana" />
|
||||||
|
<result property="addManaThreshold" column="add_mana_threshold" />
|
||||||
|
<result property="yoloHeight" column="yolo_height" />
|
||||||
|
<result property="yoloWidth" column="yolo_width" />
|
||||||
|
<result property="customParams" column="custom_params" />
|
||||||
|
<result property="fixedDirection" column="fixed_direction" />
|
||||||
|
<result property="shoutKey" column="shout_key" />
|
||||||
|
</resultMap>
|
||||||
|
|
||||||
|
<sql id="selectDmPlayerConfigVo">
|
||||||
|
select id, player_id, create_time,shout_key, update_time, shout_interval, shout_mana, auto_add_mana, add_mana_threshold, yolo_height, yolo_width, custom_params, fixed_direction from dm_player_config
|
||||||
|
</sql>
|
||||||
|
|
||||||
|
<select id="selectDmPlayerConfigList" parameterType="DmPlayerConfig" resultMap="DmPlayerConfigResult">
|
||||||
|
<include refid="selectDmPlayerConfigVo"/>
|
||||||
|
<where>
|
||||||
|
<if test="playerId != null "> and player_id = #{playerId}</if>
|
||||||
|
<if test="fixedDirection != null "> and fixed_direction = #{fixedDirection}</if>
|
||||||
|
</where>
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<select id="selectDmPlayerConfigById" parameterType="Long" resultMap="DmPlayerConfigResult">
|
||||||
|
<include refid="selectDmPlayerConfigVo"/>
|
||||||
|
where id = #{id}
|
||||||
|
</select>
|
||||||
|
<select id="selectDmPlayerConfigByPlayerId" parameterType="Long" resultMap="DmPlayerConfigResult">
|
||||||
|
<include refid="selectDmPlayerConfigVo"/>
|
||||||
|
where player_id = #{playerId}
|
||||||
|
</select>
|
||||||
|
<insert id="insertDmPlayerConfig" parameterType="DmPlayerConfig" useGeneratedKeys="true" keyProperty="id">
|
||||||
|
insert into dm_player_config
|
||||||
|
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||||
|
<if test="playerId != null">player_id,</if>
|
||||||
|
<if test="createTime != null">create_time,</if>
|
||||||
|
<if test="updateTime != null">update_time,</if>
|
||||||
|
<if test="shoutInterval != null">shout_interval,</if>
|
||||||
|
<if test="shoutMana != null">shout_mana,</if>
|
||||||
|
<if test="autoAddMana != null">auto_add_mana,</if>
|
||||||
|
<if test="addManaThreshold != null">add_mana_threshold,</if>
|
||||||
|
<if test="yoloHeight != null">yolo_height,</if>
|
||||||
|
<if test="yoloWidth != null">yolo_width,</if>
|
||||||
|
<if test="customParams != null">custom_params,</if>
|
||||||
|
<if test="fixedDirection != null">fixed_direction,</if>
|
||||||
|
<if test="shoutKey != null">shoutKey,</if>
|
||||||
|
</trim>
|
||||||
|
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||||
|
<if test="playerId != null">#{playerId},</if>
|
||||||
|
<if test="createTime != null">#{createTime},</if>
|
||||||
|
<if test="updateTime != null">#{updateTime},</if>
|
||||||
|
<if test="shoutInterval != null">#{shoutInterval},</if>
|
||||||
|
<if test="shoutMana != null">#{shoutMana},</if>
|
||||||
|
<if test="autoAddMana != null">#{autoAddMana},</if>
|
||||||
|
<if test="addManaThreshold != null">#{addManaThreshold},</if>
|
||||||
|
<if test="yoloHeight != null">#{yoloHeight},</if>
|
||||||
|
<if test="yoloWidth != null">#{yoloWidth},</if>
|
||||||
|
<if test="customParams != null">#{customParams},</if>
|
||||||
|
<if test="fixedDirection != null">#{fixedDirection},</if>
|
||||||
|
<if test="shoutKey != null">#{shoutKey},</if>
|
||||||
|
</trim>
|
||||||
|
</insert>
|
||||||
|
|
||||||
|
<update id="updateDmPlayerConfig" parameterType="DmPlayerConfig">
|
||||||
|
update dm_player_config
|
||||||
|
<trim prefix="SET" suffixOverrides=",">
|
||||||
|
<if test="playerId != null">player_id = #{playerId},</if>
|
||||||
|
<if test="createTime != null">create_time = #{createTime},</if>
|
||||||
|
<if test="updateTime != null">update_time = #{updateTime},</if>
|
||||||
|
<if test="shoutInterval != null">shout_interval = #{shoutInterval},</if>
|
||||||
|
<if test="shoutMana != null">shout_mana = #{shoutMana},</if>
|
||||||
|
<if test="autoAddMana != null">auto_add_mana = #{autoAddMana},</if>
|
||||||
|
<if test="addManaThreshold != null">add_mana_threshold = #{addManaThreshold},</if>
|
||||||
|
<if test="yoloHeight != null">yolo_height = #{yoloHeight},</if>
|
||||||
|
<if test="yoloWidth != null">yolo_width = #{yoloWidth},</if>
|
||||||
|
<if test="customParams != null">custom_params = #{customParams},</if>
|
||||||
|
<if test="fixedDirection != null">fixed_direction = #{fixedDirection},</if>
|
||||||
|
<if test="shoutKey != null">shout_key = #{shoutKey},</if>
|
||||||
|
</trim>
|
||||||
|
where id = #{id}
|
||||||
|
</update>
|
||||||
|
|
||||||
|
<delete id="deleteDmPlayerConfigById" parameterType="Long">
|
||||||
|
delete from dm_player_config where id = #{id}
|
||||||
|
</delete>
|
||||||
|
|
||||||
|
<delete id="deleteDmPlayerConfigByIds" parameterType="String">
|
||||||
|
delete from dm_player_config where id in
|
||||||
|
<foreach item="id" collection="array" open="(" separator="," close=")">
|
||||||
|
#{id}
|
||||||
|
</foreach>
|
||||||
|
</delete>
|
||||||
|
</mapper>
|
||||||
@@ -0,0 +1,83 @@
|
|||||||
|
<?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.ruoyi.system.mapper.DmPlayerTaskGroupMapper">
|
||||||
|
|
||||||
|
<resultMap type="DmPlayerTaskGroup" id="DmPlayerTaskGroupResult">
|
||||||
|
<result property="id" column="id" />
|
||||||
|
<result property="groupCode" column="group_code" />
|
||||||
|
<result property="groupName" column="group_name" />
|
||||||
|
<result property="type" column="type" />
|
||||||
|
<result property="status" column="status" />
|
||||||
|
<result property="remark" column="remark" />
|
||||||
|
<result property="createTime" column="create_time" />
|
||||||
|
<result property="updateTime" column="update_time" />
|
||||||
|
</resultMap>
|
||||||
|
|
||||||
|
<sql id="selectDmPlayerTaskGroupVo">
|
||||||
|
select id, group_code, group_name, type, status, remark, create_time, update_time from dm_player_task_group
|
||||||
|
</sql>
|
||||||
|
|
||||||
|
<select id="selectDmPlayerTaskGroupList" parameterType="DmPlayerTaskGroup" resultMap="DmPlayerTaskGroupResult">
|
||||||
|
<include refid="selectDmPlayerTaskGroupVo"/>
|
||||||
|
<where>
|
||||||
|
<if test="groupCode != null and groupCode != ''"> and group_code = #{groupCode}</if>
|
||||||
|
<if test="groupName != null and groupName != ''"> and group_name like concat('%', #{groupName}, '%')</if>
|
||||||
|
<if test="type != null "> and type = #{type}</if>
|
||||||
|
<if test="status != null "> and status = #{status}</if>
|
||||||
|
</where>
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<select id="selectDmPlayerTaskGroupById" parameterType="Long" resultMap="DmPlayerTaskGroupResult">
|
||||||
|
<include refid="selectDmPlayerTaskGroupVo"/>
|
||||||
|
where id = #{id}
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<insert id="insertDmPlayerTaskGroup" parameterType="DmPlayerTaskGroup" useGeneratedKeys="true" keyProperty="id">
|
||||||
|
insert into dm_player_task_group
|
||||||
|
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||||
|
<if test="groupCode != null and groupCode != ''">group_code,</if>
|
||||||
|
<if test="groupName != null and groupName != ''">group_name,</if>
|
||||||
|
<if test="type != null">type,</if>
|
||||||
|
<if test="status != null">status,</if>
|
||||||
|
<if test="remark != null">remark,</if>
|
||||||
|
<if test="createTime != null">create_time,</if>
|
||||||
|
<if test="updateTime != null">update_time,</if>
|
||||||
|
</trim>
|
||||||
|
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||||
|
<if test="groupCode != null and groupCode != ''">#{groupCode},</if>
|
||||||
|
<if test="groupName != null and groupName != ''">#{groupName},</if>
|
||||||
|
<if test="type != null">#{type},</if>
|
||||||
|
<if test="status != null">#{status},</if>
|
||||||
|
<if test="remark != null">#{remark},</if>
|
||||||
|
<if test="createTime != null">#{createTime},</if>
|
||||||
|
<if test="updateTime != null">#{updateTime},</if>
|
||||||
|
</trim>
|
||||||
|
</insert>
|
||||||
|
|
||||||
|
<update id="updateDmPlayerTaskGroup" parameterType="DmPlayerTaskGroup">
|
||||||
|
update dm_player_task_group
|
||||||
|
<trim prefix="SET" suffixOverrides=",">
|
||||||
|
<if test="groupCode != null and groupCode != ''">group_code = #{groupCode},</if>
|
||||||
|
<if test="groupName != null and groupName != ''">group_name = #{groupName},</if>
|
||||||
|
<if test="type != null">type = #{type},</if>
|
||||||
|
<if test="status != null">status = #{status},</if>
|
||||||
|
<if test="remark != null">remark = #{remark},</if>
|
||||||
|
<if test="createTime != null">create_time = #{createTime},</if>
|
||||||
|
<if test="updateTime != null">update_time = #{updateTime},</if>
|
||||||
|
</trim>
|
||||||
|
where id = #{id}
|
||||||
|
</update>
|
||||||
|
|
||||||
|
<delete id="deleteDmPlayerTaskGroupById" parameterType="Long">
|
||||||
|
delete from dm_player_task_group where id = #{id}
|
||||||
|
</delete>
|
||||||
|
|
||||||
|
<delete id="deleteDmPlayerTaskGroupByIds" parameterType="String">
|
||||||
|
delete from dm_player_task_group where id in
|
||||||
|
<foreach item="id" collection="array" open="(" separator="," close=")">
|
||||||
|
#{id}
|
||||||
|
</foreach>
|
||||||
|
</delete>
|
||||||
|
</mapper>
|
||||||
@@ -0,0 +1,79 @@
|
|||||||
|
<?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.ruoyi.system.mapper.DmPlayerVersionMapper">
|
||||||
|
|
||||||
|
<resultMap type="DmPlayerVersion" id="DmPlayerVersionResult">
|
||||||
|
<result property="id" column="id" />
|
||||||
|
<result property="title" column="title" />
|
||||||
|
<result property="versionNum" column="version_num" />
|
||||||
|
<result property="configUrl" column="config_url" />
|
||||||
|
<result property="proxyUrl" column="proxy_url" />
|
||||||
|
<result property="createTime" column="create_time" />
|
||||||
|
<result property="updateTime" column="update_time" />
|
||||||
|
</resultMap>
|
||||||
|
|
||||||
|
<sql id="selectDmPlayerVersionVo">
|
||||||
|
select id, title, version_num, config_url, proxy_url, create_time, update_time from dm_player_version
|
||||||
|
</sql>
|
||||||
|
|
||||||
|
<select id="selectDmPlayerVersionList" parameterType="DmPlayerVersion" resultMap="DmPlayerVersionResult">
|
||||||
|
<include refid="selectDmPlayerVersionVo"/>
|
||||||
|
<where>
|
||||||
|
<if test="title != null and title != ''"> and title like concat('%', #{title}, '%')</if>
|
||||||
|
<if test="versionNum != null and versionNum != ''"> and version_num like concat('%', #{versionNum}, '%')</if>
|
||||||
|
</where>
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<select id="selectDmPlayerVersionById" parameterType="Long" resultMap="DmPlayerVersionResult">
|
||||||
|
<include refid="selectDmPlayerVersionVo"/>
|
||||||
|
where id = #{id}
|
||||||
|
</select>
|
||||||
|
|
||||||
|
<insert id="insertDmPlayerVersion" parameterType="DmPlayerVersion">
|
||||||
|
insert into dm_player_version
|
||||||
|
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||||
|
<if test="id != null">id,</if>
|
||||||
|
<if test="title != null">title,</if>
|
||||||
|
<if test="versionNum != null">version_num,</if>
|
||||||
|
<if test="configUrl != null">config_url,</if>
|
||||||
|
<if test="proxyUrl != null">proxy_url,</if>
|
||||||
|
<if test="createTime != null">create_time,</if>
|
||||||
|
<if test="updateTime != null">update_time,</if>
|
||||||
|
</trim>
|
||||||
|
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||||
|
<if test="id != null">#{id},</if>
|
||||||
|
<if test="title != null">#{title},</if>
|
||||||
|
<if test="versionNum != null">#{versionNum},</if>
|
||||||
|
<if test="configUrl != null">#{configUrl},</if>
|
||||||
|
<if test="proxyUrl != null">#{proxyUrl},</if>
|
||||||
|
<if test="createTime != null">#{createTime},</if>
|
||||||
|
<if test="updateTime != null">#{updateTime},</if>
|
||||||
|
</trim>
|
||||||
|
</insert>
|
||||||
|
|
||||||
|
<update id="updateDmPlayerVersion" parameterType="DmPlayerVersion">
|
||||||
|
update dm_player_version
|
||||||
|
<trim prefix="SET" suffixOverrides=",">
|
||||||
|
<if test="title != null">title = #{title},</if>
|
||||||
|
<if test="versionNum != null">version_num = #{versionNum},</if>
|
||||||
|
<if test="configUrl != null">config_url = #{configUrl},</if>
|
||||||
|
<if test="proxyUrl != null">proxy_url = #{proxyUrl},</if>
|
||||||
|
<if test="createTime != null">create_time = #{createTime},</if>
|
||||||
|
<if test="updateTime != null">update_time = #{updateTime},</if>
|
||||||
|
</trim>
|
||||||
|
where id = #{id}
|
||||||
|
</update>
|
||||||
|
|
||||||
|
<delete id="deleteDmPlayerVersionById" parameterType="Long">
|
||||||
|
delete from dm_player_version where id = #{id}
|
||||||
|
</delete>
|
||||||
|
|
||||||
|
<delete id="deleteDmPlayerVersionByIds" parameterType="String">
|
||||||
|
delete from dm_player_version where id in
|
||||||
|
<foreach item="id" collection="array" open="(" separator="," close=")">
|
||||||
|
#{id}
|
||||||
|
</foreach>
|
||||||
|
</delete>
|
||||||
|
</mapper>
|
||||||
@@ -22,10 +22,11 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||||||
<result property="winOneImgPath" column="win_one_img_path" />
|
<result property="winOneImgPath" column="win_one_img_path" />
|
||||||
<result property="winOneCurTask" column="win_one_cur_task" />
|
<result property="winOneCurTask" column="win_one_cur_task" />
|
||||||
<result property="winTwoCurTask" column="win_two_cur_task" />
|
<result property="winTwoCurTask" column="win_two_cur_task" />
|
||||||
|
<result property="secret" column="secret" />
|
||||||
</resultMap>
|
</resultMap>
|
||||||
|
|
||||||
<sql id="selectDmPlayerentVo">
|
<sql id="selectDmPlayerentVo">
|
||||||
select id, accountId, name, create_time, update_time, online_status, player_status, ip, http_port, win_one_hwnd, win_one_info, win_two_hwnd, win_two_info, win_two_img_path, win_one_img_path, win_one_cur_task, win_two_cur_task from dm_playerent
|
select id, accountId, name, secret,create_time, update_time, online_status, player_status, ip, http_port, win_one_hwnd, win_one_info, win_two_hwnd, win_two_info, win_two_img_path, win_one_img_path, win_one_cur_task, win_two_cur_task from dm_playerent
|
||||||
</sql>
|
</sql>
|
||||||
|
|
||||||
<select id="selectDmPlayerentList" parameterType="DmPlayerent" resultMap="DmPlayerentResult">
|
<select id="selectDmPlayerentList" parameterType="DmPlayerent" resultMap="DmPlayerentResult">
|
||||||
@@ -34,6 +35,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||||||
<if test="name != null and name != ''"> and name like concat('%', #{name}, '%')</if>
|
<if test="name != null and name != ''"> and name like concat('%', #{name}, '%')</if>
|
||||||
<if test="onlineStatus != null and onlineStatus != ''"> and online_status = #{onlineStatus}</if>
|
<if test="onlineStatus != null and onlineStatus != ''"> and online_status = #{onlineStatus}</if>
|
||||||
<if test="playerStatus != null and playerStatus != ''"> and player_status = #{playerStatus}</if>
|
<if test="playerStatus != null and playerStatus != ''"> and player_status = #{playerStatus}</if>
|
||||||
|
<if test="accountid != null and accountid != ''"> and accountId = #{accountid}</if>
|
||||||
<if test="ip != null and ip != ''"> and ip like concat('%', #{ip}, '%')</if>
|
<if test="ip != null and ip != ''"> and ip like concat('%', #{ip}, '%')</if>
|
||||||
</where>
|
</where>
|
||||||
</select>
|
</select>
|
||||||
|
|||||||
Reference in new issue
Block a user