feat: collaboration and statistics
This commit is contained in:
-36
@@ -1,36 +0,0 @@
|
||||
---
|
||||
name: Bug 报告
|
||||
about: 创建BUG报告以改进项目
|
||||
title: ''
|
||||
labels: ''
|
||||
assignees: ''
|
||||
|
||||
---
|
||||
|
||||
**BUG描述**
|
||||
关于BUG清晰简洁的描述。
|
||||
|
||||
**复现步骤**
|
||||
详细的复现步骤。
|
||||
|
||||
|
||||
**正确的行为**
|
||||
你认为这个修复这个BUG后,正确的行为应该是什么。
|
||||
|
||||
|
||||
**详细截图**
|
||||
如果可以的话,请添加截图以帮助调查BUG.
|
||||
|
||||
**桌面端:**
|
||||
- 操作系统: [例如. iOS]
|
||||
- 浏览器及版本 [例如. chrome 11]
|
||||
- 项目版本 [例如. 1.6.0]
|
||||
|
||||
**手机端:**
|
||||
- 设备: [例如. iPhone6]
|
||||
- 操作系统: [例如. iOS8.1]
|
||||
- 浏览器及版本 [例如.safari 8]
|
||||
- 项目版本 [例如. 1.6.0]
|
||||
|
||||
**Additional context**
|
||||
任何其他你认为有助于排查错误的信息,或者你的猜测。
|
||||
@@ -1,20 +0,0 @@
|
||||
---
|
||||
name: 功能建议
|
||||
about: 关于该项目的建议
|
||||
title: ''
|
||||
labels: ''
|
||||
assignees: ''
|
||||
|
||||
---
|
||||
|
||||
**您的功能请求是否与问题相关? 请描述。**
|
||||
清楚简明地描述问题所在。
|
||||
|
||||
**描述您想要的解决方案**
|
||||
对您所设想的问题的清晰简洁的描述。
|
||||
|
||||
**描述您考虑过的替代方案**
|
||||
对您考虑过的任何替代解决方案或功能的清晰简洁的描述。
|
||||
|
||||
**附加上下文**
|
||||
在此处添加有关功能请求的任何其他上下文或屏幕截图。
|
||||
Vendored
-116
@@ -1,116 +0,0 @@
|
||||
# This workflow will build a Java project with Maven, and cache/restore any dependencies to improve the workflow execution time
|
||||
# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-java-with-maven
|
||||
|
||||
# 权限声明,确保 workflow 有权限写 checks 和 security-events
|
||||
permissions:
|
||||
contents: read
|
||||
checks: write
|
||||
security-events: write
|
||||
|
||||
name: Java CI with Maven
|
||||
|
||||
on:
|
||||
push:
|
||||
branches: [ "main" ]
|
||||
paths-ignore:
|
||||
- 'README.md'
|
||||
- 'LICENSE'
|
||||
- '.gitignore'
|
||||
- '.gitattributes'
|
||||
- 'picture'
|
||||
pull_request:
|
||||
branches: [ "main" ]
|
||||
workflow_dispatch:
|
||||
|
||||
jobs:
|
||||
build:
|
||||
runs-on: ubuntu-latest
|
||||
timeout-minutes: 30
|
||||
strategy:
|
||||
matrix:
|
||||
java-version: ['8', '17', '21']
|
||||
fail-fast: false
|
||||
|
||||
name: Build with Java ${{ matrix.java-version }}
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v3
|
||||
with:
|
||||
fetch-depth: 0
|
||||
|
||||
- name: Set up JDK ${{ matrix.java-version }}
|
||||
uses: actions/setup-java@v3
|
||||
with:
|
||||
java-version: ${{ matrix.java-version }}
|
||||
distribution: 'temurin'
|
||||
cache: 'maven'
|
||||
|
||||
# 优化Maven本地仓库缓存策略
|
||||
- name: Cache Maven packages
|
||||
uses: actions/cache@v3
|
||||
with:
|
||||
path: ~/.m2
|
||||
key: ${{ runner.os }}-m2-${{ hashFiles('**/pom.xml') }}-${{ matrix.java-version }}
|
||||
restore-keys: |
|
||||
${{ runner.os }}-m2-
|
||||
|
||||
# 编译和测试:去掉failOnWarning,避免因为警告导致失败
|
||||
- name: Build and Test with Maven
|
||||
run: |
|
||||
mvn -B verify --file pom.xml -Dmaven.test.failure.ignore=false -Dgpg.skip -Dmaven.javadoc.skip=false
|
||||
env:
|
||||
MAVEN_OPTS: -Xmx4g -XX:MaxMetaspaceSize=1g
|
||||
MAVEN_CLI_OPTS: "--batch-mode --errors --fail-at-end --show-version"
|
||||
|
||||
- name: Publish Test Report
|
||||
uses: mikepenz/action-junit-report@v4
|
||||
if: success() || failure()
|
||||
with:
|
||||
report_paths: '**/target/surefire-reports/TEST-*.xml'
|
||||
detailed_summary: true
|
||||
include_passed: true
|
||||
fail_on_failure: true
|
||||
|
||||
- name: Run SonarQube Analysis
|
||||
if: matrix.java-version == '17' && github.event_name != 'pull_request' && github.ref == 'refs/heads/main'
|
||||
continue-on-error: true
|
||||
run: |
|
||||
if [[ ! -z "${{ secrets.SONAR_TOKEN }}" ]]; then
|
||||
mvn sonar:sonar \
|
||||
-Dsonar.projectKey=agileboot \
|
||||
-Dsonar.organization=${{ secrets.SONAR_ORGANIZATION || 'default' }} \
|
||||
-Dsonar.host.url=${{ secrets.SONAR_HOST_URL || 'https://sonarcloud.io' }} \
|
||||
-Dsonar.login=${{ secrets.SONAR_TOKEN }} \
|
||||
-Dsonar.java.source=${{ matrix.java-version }}
|
||||
else
|
||||
echo "Skipping SonarQube analysis - SONAR_TOKEN not configured"
|
||||
fi
|
||||
|
||||
# 上传构建产物,if-no-files-found 改为 warn
|
||||
- name: Upload Build Artifacts
|
||||
uses: actions/upload-artifact@v4
|
||||
with:
|
||||
name: agileboot-artifacts-java-${{ matrix.java-version }}
|
||||
path: |
|
||||
**/target/*.jar
|
||||
!**/target/original-*.jar
|
||||
retention-days: 5
|
||||
if-no-files-found: warn
|
||||
|
||||
# # 只在 Java 17 版本上更新依赖图(权限和token已修复)
|
||||
# - name: Update dependency graph
|
||||
# uses: advanced-security/maven-dependency-submission-action@v4
|
||||
# if: matrix.java-version == '17' && success()
|
||||
# with:
|
||||
# token: ${{ secrets.GITHUB_TOKEN }}
|
||||
|
||||
# # 发送构建状态通知
|
||||
# - name: Notify Build Status
|
||||
# if: always()
|
||||
# uses: rtCamp/action-slack-notify@v2.2.1
|
||||
# env:
|
||||
# SLACK_WEBHOOK: ${{ secrets.SLACK_WEBHOOK || '' }}
|
||||
# SLACK_CHANNEL: build-notifications
|
||||
# SLACK_COLOR: ${{ job.status }}
|
||||
# SLACK_TITLE: Build Status for Java ${{ matrix.java-version }}
|
||||
# SLACK_MESSAGE: 'Build ${{ job.status }} on Java ${{ matrix.java-version }}'
|
||||
@@ -1,50 +0,0 @@
|
||||
######################################################################
|
||||
# Build Tools
|
||||
|
||||
.gradle
|
||||
/build/
|
||||
!gradle/wrapper/gradle-wrapper.jar
|
||||
|
||||
target/
|
||||
!.mvn/wrapper/maven-wrapper.jar
|
||||
|
||||
######################################################################
|
||||
# IDE
|
||||
|
||||
### STS ###
|
||||
.apt_generated
|
||||
.classpath
|
||||
.factorypath
|
||||
.project
|
||||
.settings
|
||||
.springBeans
|
||||
|
||||
### IntelliJ IDEA ###
|
||||
.idea
|
||||
*.iws
|
||||
*.iml
|
||||
*.ipr
|
||||
|
||||
### JRebel ###
|
||||
rebel.xml
|
||||
|
||||
### NetBeans ###
|
||||
nbproject/private/
|
||||
build/*
|
||||
nbbuild/
|
||||
dist/
|
||||
nbdist/
|
||||
.nb-gradle/
|
||||
|
||||
######################################################################
|
||||
# Others
|
||||
*.log
|
||||
*.xml.versionsBackup
|
||||
*.swp
|
||||
|
||||
!*/build/*.java
|
||||
!*/build/*.html
|
||||
!*/build/*.xml
|
||||
|
||||
/agileboot-admin/src/main/resources/application-prod.yml
|
||||
|
||||
@@ -148,7 +148,9 @@
|
||||
<option name="FOR_BRACE_FORCE" value="3" />
|
||||
<option name="WRAP_ON_TYPING" value="0" />
|
||||
<indentOptions>
|
||||
<option name="INDENT_SIZE" value="2" />
|
||||
<option name="CONTINUATION_INDENT_SIZE" value="4" />
|
||||
<option name="TAB_SIZE" value="2" />
|
||||
</indentOptions>
|
||||
</codeStyleSettings>
|
||||
<codeStyleSettings language="JSON">
|
||||
@@ -564,4 +566,4 @@
|
||||
<option name="TAB_SIZE" value="2" />
|
||||
</indentOptions>
|
||||
</codeStyleSettings>
|
||||
</code_scheme>
|
||||
</code_scheme>
|
||||
|
||||
+104
@@ -0,0 +1,104 @@
|
||||
package com.agileboot.admin.controller.collaboration;
|
||||
|
||||
import com.agileboot.admin.customize.aop.accessLog.AccessLog;
|
||||
import com.agileboot.common.core.base.BaseController;
|
||||
import com.agileboot.common.core.dto.ResponseDTO;
|
||||
import com.agileboot.common.core.page.PageDTO;
|
||||
import com.agileboot.common.enums.common.BusinessTypeEnum;
|
||||
import com.agileboot.domain.collaboration.record.CollaborationRecordApplicationService;
|
||||
import com.agileboot.domain.collaboration.record.command.AddCollaborationRecordCommand;
|
||||
import com.agileboot.domain.collaboration.record.command.UpdateCollaborationRecordCommand;
|
||||
import com.agileboot.domain.collaboration.record.dto.CollaborationMonthlyStatisticsDTO;
|
||||
import com.agileboot.domain.collaboration.record.dto.CollaborationOptionDTO;
|
||||
import com.agileboot.domain.collaboration.record.dto.CollaborationRecordDTO;
|
||||
import com.agileboot.domain.collaboration.record.dto.CollaborationRecordDetailDTO;
|
||||
import com.agileboot.domain.collaboration.record.query.CollaborationRecordQuery;
|
||||
import com.agileboot.domain.common.command.BulkOperationCommand;
|
||||
import io.swagger.v3.oas.annotations.Operation;
|
||||
import io.swagger.v3.oas.annotations.tags.Tag;
|
||||
import java.util.List;
|
||||
import javax.validation.Valid;
|
||||
import javax.validation.constraints.NotEmpty;
|
||||
import javax.validation.constraints.NotNull;
|
||||
import javax.validation.constraints.Positive;
|
||||
import lombok.RequiredArgsConstructor;
|
||||
import org.springframework.security.access.prepost.PreAuthorize;
|
||||
import org.springframework.validation.annotation.Validated;
|
||||
import org.springframework.web.bind.annotation.DeleteMapping;
|
||||
import org.springframework.web.bind.annotation.GetMapping;
|
||||
import org.springframework.web.bind.annotation.PathVariable;
|
||||
import org.springframework.web.bind.annotation.PostMapping;
|
||||
import org.springframework.web.bind.annotation.PutMapping;
|
||||
import org.springframework.web.bind.annotation.RequestBody;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.RequestParam;
|
||||
import org.springframework.web.bind.annotation.RestController;
|
||||
|
||||
/**
|
||||
* @author codex
|
||||
*/
|
||||
@Tag(name = "合作记录API", description = "合作记录相关的增删查改和统计")
|
||||
@RestController
|
||||
@RequestMapping("/collaboration/record")
|
||||
@Validated
|
||||
@RequiredArgsConstructor
|
||||
public class CollaborationRecordController extends BaseController {
|
||||
|
||||
private final CollaborationRecordApplicationService recordApplicationService;
|
||||
|
||||
@Operation(summary = "合作记录列表")
|
||||
@PreAuthorize("@permission.has('collaboration:record:list')")
|
||||
@GetMapping("/list")
|
||||
public ResponseDTO<PageDTO<CollaborationRecordDTO>> list(CollaborationRecordQuery query) {
|
||||
return ResponseDTO.ok(recordApplicationService.getRecordList(query));
|
||||
}
|
||||
|
||||
@Operation(summary = "合作记录详情")
|
||||
@PreAuthorize("@permission.has('collaboration:record:query')")
|
||||
@GetMapping("/{recordId}")
|
||||
public ResponseDTO<CollaborationRecordDetailDTO> getInfo(@PathVariable @Positive Long recordId) {
|
||||
return ResponseDTO.ok(recordApplicationService.getRecordInfo(recordId));
|
||||
}
|
||||
|
||||
@Operation(summary = "合作记录选项")
|
||||
@PreAuthorize("@permission.has('collaboration:record:list')")
|
||||
@GetMapping("/options")
|
||||
public ResponseDTO<List<CollaborationOptionDTO>> options() {
|
||||
return ResponseDTO.ok(recordApplicationService.getOptions());
|
||||
}
|
||||
|
||||
@Operation(summary = "合作记录月度统计")
|
||||
@PreAuthorize("@permission.has('collaboration:record:statistics')")
|
||||
@GetMapping("/monthly-statistics")
|
||||
public ResponseDTO<List<CollaborationMonthlyStatisticsDTO>> monthlyStatistics(@RequestParam Integer year) {
|
||||
return ResponseDTO.ok(recordApplicationService.getMonthlyStatistics(year));
|
||||
}
|
||||
|
||||
@Operation(summary = "新增合作记录")
|
||||
@PreAuthorize("@permission.has('collaboration:record:add')")
|
||||
@AccessLog(title = "合作记录", businessType = BusinessTypeEnum.ADD)
|
||||
@PostMapping
|
||||
public ResponseDTO<Void> add(@Valid @RequestBody AddCollaborationRecordCommand command) {
|
||||
recordApplicationService.addRecord(command);
|
||||
return ResponseDTO.ok();
|
||||
}
|
||||
|
||||
@Operation(summary = "修改合作记录")
|
||||
@PreAuthorize("@permission.has('collaboration:record:edit')")
|
||||
@AccessLog(title = "合作记录", businessType = BusinessTypeEnum.MODIFY)
|
||||
@PutMapping
|
||||
public ResponseDTO<Void> edit(@Valid @RequestBody UpdateCollaborationRecordCommand command) {
|
||||
recordApplicationService.updateRecord(command);
|
||||
return ResponseDTO.ok();
|
||||
}
|
||||
|
||||
@Operation(summary = "删除合作记录")
|
||||
@PreAuthorize("@permission.has('collaboration:record:remove')")
|
||||
@AccessLog(title = "合作记录", businessType = BusinessTypeEnum.DELETE)
|
||||
@DeleteMapping
|
||||
public ResponseDTO<Void> remove(@RequestParam @NotNull @NotEmpty List<Long> ids) {
|
||||
recordApplicationService.deleteRecord(new BulkOperationCommand<>(ids));
|
||||
return ResponseDTO.ok();
|
||||
}
|
||||
|
||||
}
|
||||
@@ -50,7 +50,7 @@ spring:
|
||||
datasource:
|
||||
# 主库数据源
|
||||
master:
|
||||
url: jdbc:mysql://localhost:3306/agileboot_pure?useUnicode=true&characterEncoding=utf8&zeroDateTimeBehavior=convertToNull&useSSL=true&serverTimezone=GMT%2B8
|
||||
url: jdbc:mysql://localhost:33061/todo_agileboot_pure?useUnicode=true&characterEncoding=utf8&zeroDateTimeBehavior=convertToNull&useSSL=true&serverTimezone=GMT%2B8
|
||||
username: root
|
||||
password: root123
|
||||
# 从库数据源
|
||||
@@ -64,7 +64,7 @@ spring:
|
||||
# 地址
|
||||
host: localhost
|
||||
# 端口,默认为6379
|
||||
port: 6379
|
||||
port: 63791
|
||||
# 数据库索引
|
||||
database: 0
|
||||
# 密码
|
||||
@@ -84,7 +84,7 @@ spring:
|
||||
|
||||
logging:
|
||||
file:
|
||||
path: D:/logs/agileboot-dev
|
||||
path: /home/agileboot/logs/agileboot-dev
|
||||
|
||||
|
||||
springdoc:
|
||||
@@ -98,8 +98,8 @@ springdoc:
|
||||
|
||||
# 项目相关配置
|
||||
agileboot:
|
||||
# 文件基路径 示例( Windows配置D:\agileboot,Linux配置 /home/agileboot)
|
||||
file-base-dir: D:\agileboot
|
||||
# 文件基路径 示例(Linux配置 /home/agileboot)
|
||||
file-base-dir: /home/agileboot
|
||||
# 前端url请求转发前缀
|
||||
api-prefix: /dev-api
|
||||
demo-enabled: false
|
||||
|
||||
+6
-9
@@ -6,14 +6,11 @@ import com.agileboot.common.config.AgileBootConfig;
|
||||
import com.agileboot.common.constant.Constants.UploadSubDir;
|
||||
import java.io.File;
|
||||
import javax.annotation.Resource;
|
||||
import org.junit.Test;
|
||||
import org.junit.jupiter.api.Assertions;
|
||||
import org.junit.runner.RunWith;
|
||||
import org.junit.jupiter.api.Test;
|
||||
import org.springframework.boot.test.context.SpringBootTest;
|
||||
import org.springframework.test.context.junit4.SpringRunner;
|
||||
|
||||
@SpringBootTest(classes = AgileBootAdminApplication.class)
|
||||
@RunWith(SpringRunner.class)
|
||||
public class AgileBootConfigTest {
|
||||
|
||||
@Resource
|
||||
@@ -21,7 +18,7 @@ public class AgileBootConfigTest {
|
||||
|
||||
@Test
|
||||
public void testConfig() {
|
||||
String fileBaseDir = "D:\\agileboot\\profile";
|
||||
String fileBaseDir = "/home/agileboot/profile";
|
||||
|
||||
Assertions.assertEquals("AgileBoot", config.getName());
|
||||
Assertions.assertEquals("1.8.0", config.getVersion());
|
||||
@@ -31,13 +28,13 @@ public class AgileBootConfigTest {
|
||||
Assertions.assertFalse(AgileBootConfig.isAddressEnabled());
|
||||
Assertions.assertEquals("math", AgileBootConfig.getCaptchaType());
|
||||
Assertions.assertEquals("math", AgileBootConfig.getCaptchaType());
|
||||
Assertions.assertEquals(fileBaseDir + "\\import",
|
||||
Assertions.assertEquals(fileBaseDir + "/import",
|
||||
AgileBootConfig.getFileBaseDir() + File.separator + UploadSubDir.IMPORT_PATH);
|
||||
Assertions.assertEquals(fileBaseDir + "\\avatar",
|
||||
Assertions.assertEquals(fileBaseDir + "/avatar",
|
||||
AgileBootConfig.getFileBaseDir() + File.separator + UploadSubDir.AVATAR_PATH);
|
||||
Assertions.assertEquals(fileBaseDir + "\\download",
|
||||
Assertions.assertEquals(fileBaseDir + "/download",
|
||||
AgileBootConfig.getFileBaseDir() + File.separator + UploadSubDir.DOWNLOAD_PATH);
|
||||
Assertions.assertEquals(fileBaseDir + "\\upload",
|
||||
Assertions.assertEquals(fileBaseDir + "/upload",
|
||||
AgileBootConfig.getFileBaseDir() + File.separator + UploadSubDir.UPLOAD_PATH);
|
||||
}
|
||||
|
||||
|
||||
+2
-2
@@ -110,10 +110,10 @@ class FileUploadUtilsTest {
|
||||
@Test
|
||||
void getFileAbsolutePath() {
|
||||
AgileBootConfig agileBootConfig = new AgileBootConfig();
|
||||
agileBootConfig.setFileBaseDir("D:\\agileboot");
|
||||
agileBootConfig.setFileBaseDir("/home/agileboot");
|
||||
|
||||
String fileAbsolutePath = FileUploadUtils.getFileAbsolutePath(UploadSubDir.AVATAR_PATH, "test.jpg");
|
||||
|
||||
Assertions.assertEquals("D:\\agileboot\\profile\\avatar\\test.jpg", fileAbsolutePath);
|
||||
Assertions.assertEquals("/home/agileboot/profile/avatar/test.jpg", fileAbsolutePath);
|
||||
}
|
||||
}
|
||||
|
||||
+402
@@ -0,0 +1,402 @@
|
||||
package com.agileboot.domain.collaboration.record;
|
||||
|
||||
import com.agileboot.common.core.page.PageDTO;
|
||||
import com.agileboot.domain.collaboration.record.command.AddCollaborationRecordCommand;
|
||||
import com.agileboot.domain.collaboration.record.command.CollaborationExpenditureCommand;
|
||||
import com.agileboot.domain.collaboration.record.command.CollaborationFileCommand;
|
||||
import com.agileboot.domain.collaboration.record.command.CollaborationSettlementCommand;
|
||||
import com.agileboot.domain.collaboration.record.command.CollaborationTaskCommand;
|
||||
import com.agileboot.domain.collaboration.record.command.UpdateCollaborationRecordCommand;
|
||||
import com.agileboot.domain.collaboration.record.db.CollaborationExpenditureEntity;
|
||||
import com.agileboot.domain.collaboration.record.db.CollaborationExpenditureService;
|
||||
import com.agileboot.domain.collaboration.record.db.CollaborationFileEntity;
|
||||
import com.agileboot.domain.collaboration.record.db.CollaborationFileService;
|
||||
import com.agileboot.domain.collaboration.record.db.CollaborationRecordEntity;
|
||||
import com.agileboot.domain.collaboration.record.db.CollaborationRecordService;
|
||||
import com.agileboot.domain.collaboration.record.db.CollaborationSettlementEntity;
|
||||
import com.agileboot.domain.collaboration.record.db.CollaborationSettlementService;
|
||||
import com.agileboot.domain.collaboration.record.db.CollaborationTaskEntity;
|
||||
import com.agileboot.domain.collaboration.record.db.CollaborationTaskService;
|
||||
import com.agileboot.domain.collaboration.record.dto.CollaborationExpenditureDTO;
|
||||
import com.agileboot.domain.collaboration.record.dto.CollaborationFileDTO;
|
||||
import com.agileboot.domain.collaboration.record.dto.CollaborationMonthlyStatisticsDTO;
|
||||
import com.agileboot.domain.collaboration.record.dto.CollaborationOptionDTO;
|
||||
import com.agileboot.domain.collaboration.record.dto.CollaborationRecordDTO;
|
||||
import com.agileboot.domain.collaboration.record.dto.CollaborationRecordDetailDTO;
|
||||
import com.agileboot.domain.collaboration.record.dto.CollaborationSettlementDTO;
|
||||
import com.agileboot.domain.collaboration.record.dto.CollaborationTaskDTO;
|
||||
import com.agileboot.domain.collaboration.record.dto.SettlementStatusDTO;
|
||||
import com.agileboot.domain.collaboration.record.enumtype.CollaborationOptionEnum;
|
||||
import com.agileboot.domain.collaboration.record.enumtype.SettlementStatusEnum;
|
||||
import com.agileboot.domain.collaboration.record.model.CollaborationRecordModel;
|
||||
import com.agileboot.domain.collaboration.record.model.CollaborationRecordModelFactory;
|
||||
import com.agileboot.domain.collaboration.record.query.CollaborationRecordQuery;
|
||||
import com.agileboot.domain.common.command.BulkOperationCommand;
|
||||
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
||||
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
||||
import java.math.BigDecimal;
|
||||
import java.util.ArrayList;
|
||||
import java.util.Arrays;
|
||||
import java.util.Calendar;
|
||||
import java.util.Collections;
|
||||
import java.util.Date;
|
||||
import java.util.List;
|
||||
import java.util.Set;
|
||||
import java.util.stream.Collectors;
|
||||
import lombok.RequiredArgsConstructor;
|
||||
import org.springframework.stereotype.Service;
|
||||
import org.springframework.transaction.annotation.Transactional;
|
||||
|
||||
/**
|
||||
* @author codex
|
||||
*/
|
||||
@Service
|
||||
@RequiredArgsConstructor
|
||||
public class CollaborationRecordApplicationService {
|
||||
|
||||
private static final String PURCHASE_FEE = "拍单费用";
|
||||
private static final String DELIVERY_FEE = "快递费用";
|
||||
private static final String REMUNERATION_FEE = "稿费";
|
||||
|
||||
private final CollaborationRecordModelFactory recordModelFactory;
|
||||
private final CollaborationRecordService recordService;
|
||||
private final CollaborationTaskService taskService;
|
||||
private final CollaborationExpenditureService expenditureService;
|
||||
private final CollaborationSettlementService settlementService;
|
||||
private final CollaborationFileService fileService;
|
||||
|
||||
public PageDTO<CollaborationRecordDTO> getRecordList(CollaborationRecordQuery query) {
|
||||
Page<CollaborationRecordEntity> page = recordService.page(query.toPage(), query.toQueryWrapper());
|
||||
List<CollaborationRecordDTO> records = page.getRecords().stream()
|
||||
.map(this::buildRecordDTO)
|
||||
.collect(Collectors.toList());
|
||||
return new PageDTO<>(records, page.getTotal());
|
||||
}
|
||||
|
||||
public CollaborationRecordDetailDTO getRecordInfo(Long recordId) {
|
||||
CollaborationRecordModel model = recordModelFactory.loadById(recordId);
|
||||
CollaborationRecordDetailDTO dto = new CollaborationRecordDetailDTO(model);
|
||||
fillDetailChildren(dto, recordId);
|
||||
fillRecordStats(dto, recordId);
|
||||
return dto;
|
||||
}
|
||||
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
public void addRecord(AddCollaborationRecordCommand command) {
|
||||
CollaborationRecordModel model = recordModelFactory.create();
|
||||
model.loadFromAddCommand(command);
|
||||
model.saveRecord();
|
||||
saveChildren(model.getRecordId(), command);
|
||||
}
|
||||
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
public void updateRecord(UpdateCollaborationRecordCommand command) {
|
||||
CollaborationRecordModel model = recordModelFactory.loadById(command.getRecordId());
|
||||
model.loadFromUpdateCommand(command);
|
||||
model.updateRecord();
|
||||
replaceChildren(command.getRecordId(), command);
|
||||
}
|
||||
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
public void deleteRecord(BulkOperationCommand<Long> command) {
|
||||
Set<Long> ids = command.getIds();
|
||||
if (ids == null || ids.isEmpty()) {
|
||||
return;
|
||||
}
|
||||
taskService.removeByRecordIds(ids);
|
||||
expenditureService.removeByRecordIds(ids);
|
||||
settlementService.removeByRecordIds(ids);
|
||||
fileService.removeByRecordIds(ids);
|
||||
recordService.removeBatchByIds(ids);
|
||||
}
|
||||
|
||||
public List<CollaborationOptionDTO> getOptions() {
|
||||
return Arrays.stream(CollaborationOptionEnum.values())
|
||||
.map(item -> new CollaborationOptionDTO(item.getType(), item.getLabel(), Arrays.asList(item.getValues())))
|
||||
.collect(Collectors.toList());
|
||||
}
|
||||
|
||||
public List<CollaborationMonthlyStatisticsDTO> getMonthlyStatistics(Integer year) {
|
||||
List<CollaborationMonthlyStatisticsDTO> statistics = new ArrayList<>();
|
||||
for (int month = 1; month <= 12; month++) {
|
||||
statistics.add(buildMonthlyStatistics(year, month));
|
||||
}
|
||||
return statistics;
|
||||
}
|
||||
|
||||
private CollaborationRecordDTO buildRecordDTO(CollaborationRecordEntity entity) {
|
||||
CollaborationRecordDTO dto = new CollaborationRecordDTO(entity);
|
||||
fillRecordStats(dto, entity.getRecordId());
|
||||
return dto;
|
||||
}
|
||||
|
||||
private void fillDetailChildren(CollaborationRecordDetailDTO dto, Long recordId) {
|
||||
dto.setTasks(taskService.listByRecordId(recordId).stream()
|
||||
.map(CollaborationTaskDTO::new)
|
||||
.collect(Collectors.toList()));
|
||||
dto.setExpenditures(expenditureService.listByRecordId(recordId).stream()
|
||||
.map(CollaborationExpenditureDTO::new)
|
||||
.collect(Collectors.toList()));
|
||||
dto.setSettlements(settlementService.listByRecordId(recordId).stream()
|
||||
.map(CollaborationSettlementDTO::new)
|
||||
.collect(Collectors.toList()));
|
||||
dto.setFiles(fileService.listByRecordId(recordId).stream()
|
||||
.map(CollaborationFileDTO::new)
|
||||
.collect(Collectors.toList()));
|
||||
}
|
||||
|
||||
private void fillRecordStats(CollaborationRecordDTO dto, Long recordId) {
|
||||
List<CollaborationTaskEntity> tasks = taskService.listByRecordId(recordId);
|
||||
List<CollaborationExpenditureEntity> expenditures = expenditureService.listByRecordId(recordId);
|
||||
List<CollaborationSettlementEntity> settlements = settlementService.listByRecordId(recordId);
|
||||
dto.setTasksNum(tasks.size());
|
||||
dto.setCompletedTasksNum((int) tasks.stream().filter(item -> item.getReleaseDate() != null).count());
|
||||
dto.setPurchaseSettlementStatus(getStatus(dto.getPurchasePrice(), settlements, PURCHASE_FEE));
|
||||
dto.setDeliverySettlementStatus(getStatus(sumExpenditure(expenditures, DELIVERY_FEE), settlements, DELIVERY_FEE));
|
||||
dto.setRemunerationSettlementStatus(getStatus(dto.getRemuneration(), settlements, REMUNERATION_FEE));
|
||||
}
|
||||
|
||||
private SettlementStatusDTO getStatus(
|
||||
BigDecimal expectedAmount, List<CollaborationSettlementEntity> settlements, String purpose) {
|
||||
List<CollaborationSettlementEntity> matched = filterSettlements(settlements, purpose);
|
||||
if (matched.isEmpty()) {
|
||||
return toStatusDTO(SettlementStatusEnum.NONE);
|
||||
}
|
||||
BigDecimal settledAmount = sumSettlement(matched);
|
||||
BigDecimal expected = defaultAmount(expectedAmount);
|
||||
if (isAllSettlementPending(matched)) {
|
||||
return toStatusDTO(SettlementStatusEnum.UNSETTLED);
|
||||
}
|
||||
if (isAllSettlementDue(matched) && settledAmount.compareTo(expected) >= 0) {
|
||||
return toStatusDTO(SettlementStatusEnum.SETTLED);
|
||||
}
|
||||
return toStatusDTO(SettlementStatusEnum.PARTIAL);
|
||||
}
|
||||
|
||||
private List<CollaborationSettlementEntity> filterSettlements(
|
||||
List<CollaborationSettlementEntity> settlements, String purpose) {
|
||||
if (settlements == null) {
|
||||
return Collections.emptyList();
|
||||
}
|
||||
return settlements.stream()
|
||||
.filter(item -> purpose.equals(item.getPurpose()))
|
||||
.collect(Collectors.toList());
|
||||
}
|
||||
|
||||
private SettlementStatusDTO toStatusDTO(SettlementStatusEnum status) {
|
||||
return new SettlementStatusDTO(status.getValue(), status.getLabel());
|
||||
}
|
||||
|
||||
private boolean isAllSettlementDue(List<CollaborationSettlementEntity> settlements) {
|
||||
Date today = getTodayStart();
|
||||
return settlements.stream()
|
||||
.allMatch(item -> item.getSettleDate() != null && !item.getSettleDate().after(today));
|
||||
}
|
||||
|
||||
private boolean isAllSettlementPending(List<CollaborationSettlementEntity> settlements) {
|
||||
Date today = getTodayStart();
|
||||
return settlements.stream()
|
||||
.allMatch(item -> item.getSettleDate() == null || item.getSettleDate().after(today));
|
||||
}
|
||||
|
||||
private void replaceChildren(Long recordId, AddCollaborationRecordCommand command) {
|
||||
List<Long> ids = Collections.singletonList(recordId);
|
||||
taskService.removeByRecordIds(ids);
|
||||
expenditureService.removeByRecordIds(ids);
|
||||
settlementService.removeByRecordIds(ids);
|
||||
fileService.removeByRecordIds(ids);
|
||||
saveChildren(recordId, command);
|
||||
}
|
||||
|
||||
private void saveChildren(Long recordId, AddCollaborationRecordCommand command) {
|
||||
saveTasks(recordId, command.getTasks());
|
||||
saveExpenditures(recordId, command.getExpenditures());
|
||||
saveSettlements(recordId, command.getSettlements());
|
||||
saveFiles(recordId, command.getFiles());
|
||||
}
|
||||
|
||||
private void saveTasks(Long recordId, List<CollaborationTaskCommand> tasks) {
|
||||
List<CollaborationTaskEntity> entities = toTaskEntities(recordId, tasks);
|
||||
if (!entities.isEmpty()) {
|
||||
taskService.saveBatch(entities);
|
||||
}
|
||||
}
|
||||
|
||||
private void saveExpenditures(Long recordId, List<CollaborationExpenditureCommand> expenditures) {
|
||||
List<CollaborationExpenditureEntity> entities = toExpenditureEntities(recordId, expenditures);
|
||||
if (!entities.isEmpty()) {
|
||||
expenditureService.saveBatch(entities);
|
||||
}
|
||||
}
|
||||
|
||||
private void saveSettlements(Long recordId, List<CollaborationSettlementCommand> settlements) {
|
||||
List<CollaborationSettlementEntity> entities = toSettlementEntities(recordId, settlements);
|
||||
if (!entities.isEmpty()) {
|
||||
settlementService.saveBatch(entities);
|
||||
}
|
||||
}
|
||||
|
||||
private void saveFiles(Long recordId, List<CollaborationFileCommand> files) {
|
||||
List<CollaborationFileEntity> entities = toFileEntities(recordId, files);
|
||||
if (!entities.isEmpty()) {
|
||||
fileService.saveBatch(entities);
|
||||
}
|
||||
}
|
||||
|
||||
private List<CollaborationTaskEntity> toTaskEntities(Long recordId, List<CollaborationTaskCommand> tasks) {
|
||||
List<CollaborationTaskEntity> entities = new ArrayList<>();
|
||||
if (tasks == null) {
|
||||
return entities;
|
||||
}
|
||||
for (int i = 0; i < tasks.size(); i++) {
|
||||
entities.add(toTaskEntity(recordId, tasks.get(i), i));
|
||||
}
|
||||
return entities;
|
||||
}
|
||||
|
||||
private CollaborationTaskEntity toTaskEntity(Long recordId, CollaborationTaskCommand command, int index) {
|
||||
CollaborationTaskEntity entity = new CollaborationTaskEntity();
|
||||
entity.setRecordId(recordId);
|
||||
entity.setReleaseDate(command.getReleaseDate());
|
||||
entity.setSortOrder(index);
|
||||
return entity;
|
||||
}
|
||||
|
||||
private List<CollaborationExpenditureEntity> toExpenditureEntities(
|
||||
Long recordId, List<CollaborationExpenditureCommand> expenditures) {
|
||||
if (expenditures == null) {
|
||||
return Collections.emptyList();
|
||||
}
|
||||
return expenditures.stream()
|
||||
.map(item -> toExpenditureEntity(recordId, item))
|
||||
.collect(Collectors.toList());
|
||||
}
|
||||
|
||||
private CollaborationExpenditureEntity toExpenditureEntity(Long recordId, CollaborationExpenditureCommand command) {
|
||||
CollaborationExpenditureEntity entity = new CollaborationExpenditureEntity();
|
||||
entity.setRecordId(recordId);
|
||||
entity.setSpendDate(command.getSpendDate());
|
||||
entity.setAmount(command.getAmount());
|
||||
entity.setPurpose(command.getPurpose());
|
||||
return entity;
|
||||
}
|
||||
|
||||
private List<CollaborationSettlementEntity> toSettlementEntities(
|
||||
Long recordId, List<CollaborationSettlementCommand> settlements) {
|
||||
if (settlements == null) {
|
||||
return Collections.emptyList();
|
||||
}
|
||||
return settlements.stream()
|
||||
.map(item -> toSettlementEntity(recordId, item))
|
||||
.collect(Collectors.toList());
|
||||
}
|
||||
|
||||
private CollaborationSettlementEntity toSettlementEntity(Long recordId, CollaborationSettlementCommand command) {
|
||||
CollaborationSettlementEntity entity = new CollaborationSettlementEntity();
|
||||
entity.setRecordId(recordId);
|
||||
entity.setSettleDate(command.getSettleDate());
|
||||
entity.setMethod(command.getMethod());
|
||||
entity.setIncome(command.getIncome());
|
||||
entity.setPurpose(command.getPurpose());
|
||||
return entity;
|
||||
}
|
||||
|
||||
private List<CollaborationFileEntity> toFileEntities(Long recordId, List<CollaborationFileCommand> files) {
|
||||
List<CollaborationFileEntity> entities = new ArrayList<>();
|
||||
if (files == null) {
|
||||
return entities;
|
||||
}
|
||||
for (int i = 0; i < files.size(); i++) {
|
||||
entities.add(toFileEntity(recordId, files.get(i), i));
|
||||
}
|
||||
return entities;
|
||||
}
|
||||
|
||||
private CollaborationFileEntity toFileEntity(Long recordId, CollaborationFileCommand command, int index) {
|
||||
CollaborationFileEntity entity = new CollaborationFileEntity();
|
||||
entity.setRecordId(recordId);
|
||||
entity.setFileType(command.getFileType());
|
||||
entity.setUrl(command.getUrl());
|
||||
entity.setFileName(command.getFileName());
|
||||
entity.setNewFileName(command.getNewFileName());
|
||||
entity.setOriginalFilename(command.getOriginalFilename());
|
||||
entity.setSortOrder(index);
|
||||
return entity;
|
||||
}
|
||||
|
||||
private CollaborationMonthlyStatisticsDTO buildMonthlyStatistics(Integer year, Integer month) {
|
||||
Date[] range = getMonthRange(year, month);
|
||||
BigDecimal purchasePrice = sumPurchasePrice(range);
|
||||
BigDecimal expenditureAmount = sumExpenditure(range);
|
||||
BigDecimal settledRemuneration = sumSettlement(range, REMUNERATION_FEE);
|
||||
BigDecimal settledTotal = sumSettlement(range, null);
|
||||
return new CollaborationMonthlyStatisticsDTO(month, purchasePrice, expenditureAmount,
|
||||
settledRemuneration, settledTotal);
|
||||
}
|
||||
|
||||
private BigDecimal sumPurchasePrice(Date[] range) {
|
||||
List<CollaborationRecordEntity> records = recordService.list(new QueryWrapper<CollaborationRecordEntity>()
|
||||
.ge("purchase_date", range[0])
|
||||
.le("purchase_date", range[1]));
|
||||
return records.stream()
|
||||
.map(CollaborationRecordEntity::getPurchasePrice)
|
||||
.map(this::defaultAmount)
|
||||
.reduce(BigDecimal.ZERO, BigDecimal::add);
|
||||
}
|
||||
|
||||
private BigDecimal sumExpenditure(Date[] range) {
|
||||
List<CollaborationExpenditureEntity> expenditures = expenditureService.list(
|
||||
new QueryWrapper<CollaborationExpenditureEntity>().ge("spend_date", range[0]).le("spend_date", range[1]));
|
||||
return expenditures.stream()
|
||||
.map(CollaborationExpenditureEntity::getAmount)
|
||||
.map(this::defaultAmount)
|
||||
.reduce(BigDecimal.ZERO, BigDecimal::add);
|
||||
}
|
||||
|
||||
private BigDecimal sumSettlement(Date[] range, String purpose) {
|
||||
QueryWrapper<CollaborationSettlementEntity> wrapper = new QueryWrapper<CollaborationSettlementEntity>()
|
||||
.ge("settle_date", range[0])
|
||||
.le("settle_date", range[1])
|
||||
.eq(purpose != null, "purpose", purpose);
|
||||
return sumSettlement(settlementService.list(wrapper));
|
||||
}
|
||||
|
||||
private BigDecimal sumExpenditure(List<CollaborationExpenditureEntity> expenditures, String purpose) {
|
||||
return expenditures.stream()
|
||||
.filter(item -> purpose.equals(item.getPurpose()))
|
||||
.map(CollaborationExpenditureEntity::getAmount)
|
||||
.map(this::defaultAmount)
|
||||
.reduce(BigDecimal.ZERO, BigDecimal::add);
|
||||
}
|
||||
|
||||
private BigDecimal sumSettlement(List<CollaborationSettlementEntity> settlements) {
|
||||
return settlements.stream()
|
||||
.map(CollaborationSettlementEntity::getIncome)
|
||||
.map(this::defaultAmount)
|
||||
.reduce(BigDecimal.ZERO, BigDecimal::add);
|
||||
}
|
||||
|
||||
private BigDecimal defaultAmount(BigDecimal amount) {
|
||||
return amount == null ? BigDecimal.ZERO : amount;
|
||||
}
|
||||
|
||||
private Date[] getMonthRange(Integer year, Integer month) {
|
||||
Calendar start = Calendar.getInstance();
|
||||
start.set(year, month - 1, 1, 0, 0, 0);
|
||||
start.set(Calendar.MILLISECOND, 0);
|
||||
Calendar end = (Calendar) start.clone();
|
||||
end.add(Calendar.MONTH, 1);
|
||||
end.add(Calendar.MILLISECOND, -1);
|
||||
return new Date[]{start.getTime(), end.getTime()};
|
||||
}
|
||||
|
||||
private Date getTodayStart() {
|
||||
Calendar today = Calendar.getInstance();
|
||||
today.set(Calendar.HOUR_OF_DAY, 0);
|
||||
today.set(Calendar.MINUTE, 0);
|
||||
today.set(Calendar.SECOND, 0);
|
||||
today.set(Calendar.MILLISECOND, 0);
|
||||
return today.getTime();
|
||||
}
|
||||
|
||||
}
|
||||
+83
@@ -0,0 +1,83 @@
|
||||
package com.agileboot.domain.collaboration.record.command;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import java.math.BigDecimal;
|
||||
import java.util.ArrayList;
|
||||
import java.util.Date;
|
||||
import java.util.List;
|
||||
import javax.validation.Valid;
|
||||
import javax.validation.constraints.Min;
|
||||
import javax.validation.constraints.NotBlank;
|
||||
import javax.validation.constraints.NotNull;
|
||||
import javax.validation.constraints.PositiveOrZero;
|
||||
import javax.validation.constraints.Size;
|
||||
import lombok.Data;
|
||||
|
||||
/**
|
||||
* @author codex
|
||||
*/
|
||||
@Data
|
||||
public class AddCollaborationRecordCommand {
|
||||
|
||||
@NotBlank(message = "品牌不能为空")
|
||||
@Size(max = 100, message = "品牌长度不能超过100个字符")
|
||||
protected String brand;
|
||||
|
||||
@NotBlank(message = "物品不能为空")
|
||||
@Size(max = 100, message = "物品长度不能超过100个字符")
|
||||
protected String goods;
|
||||
|
||||
@Size(max = 50, message = "合作平台长度不能超过50个字符")
|
||||
protected String cooperationPlatform;
|
||||
|
||||
@NotNull(message = "返图数量不能为空")
|
||||
@Min(value = 1, message = "返图数量至少为1")
|
||||
protected Integer imageReturnNum;
|
||||
|
||||
@Size(max = 30, message = "留存方式长度不能超过30个字符")
|
||||
protected String retainedMethod;
|
||||
|
||||
@Size(max = 30, message = "合作方式长度不能超过30个字符")
|
||||
protected String cooperatedMethod;
|
||||
|
||||
@Size(max = 30, message = "购入方式长度不能超过30个字符")
|
||||
protected String purchaseMethod;
|
||||
|
||||
@PositiveOrZero(message = "购入金额不能小于0")
|
||||
protected BigDecimal purchasePrice;
|
||||
|
||||
@JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8")
|
||||
protected Date purchaseDate;
|
||||
|
||||
@Size(max = 30, message = "购入平台长度不能超过30个字符")
|
||||
protected String purchasePlatform;
|
||||
|
||||
@NotNull(message = "预完成日期不能为空")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8")
|
||||
protected Date deadline;
|
||||
|
||||
@PositiveOrZero(message = "稿费不能小于0")
|
||||
protected BigDecimal remuneration;
|
||||
|
||||
@JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8")
|
||||
protected Date completeDate;
|
||||
|
||||
@Size(max = 1000, message = "拍摄要求长度不能超过1000个字符")
|
||||
protected String requirements;
|
||||
|
||||
@Size(max = 1000, message = "备注长度不能超过1000个字符")
|
||||
protected String remark;
|
||||
|
||||
@Valid
|
||||
protected List<CollaborationTaskCommand> tasks = new ArrayList<>();
|
||||
|
||||
@Valid
|
||||
protected List<CollaborationExpenditureCommand> expenditures = new ArrayList<>();
|
||||
|
||||
@Valid
|
||||
protected List<CollaborationSettlementCommand> settlements = new ArrayList<>();
|
||||
|
||||
@Valid
|
||||
protected List<CollaborationFileCommand> files = new ArrayList<>();
|
||||
|
||||
}
|
||||
+25
@@ -0,0 +1,25 @@
|
||||
package com.agileboot.domain.collaboration.record.command;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import java.math.BigDecimal;
|
||||
import java.util.Date;
|
||||
import javax.validation.constraints.PositiveOrZero;
|
||||
import javax.validation.constraints.Size;
|
||||
import lombok.Data;
|
||||
|
||||
/**
|
||||
* @author codex
|
||||
*/
|
||||
@Data
|
||||
public class CollaborationExpenditureCommand {
|
||||
|
||||
@JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8")
|
||||
private Date spendDate;
|
||||
|
||||
@PositiveOrZero(message = "支出金额不能小于0")
|
||||
private BigDecimal amount;
|
||||
|
||||
@Size(max = 30, message = "支出用途长度不能超过30个字符")
|
||||
private String purpose;
|
||||
|
||||
}
|
||||
+30
@@ -0,0 +1,30 @@
|
||||
package com.agileboot.domain.collaboration.record.command;
|
||||
|
||||
import javax.validation.constraints.NotBlank;
|
||||
import javax.validation.constraints.Size;
|
||||
import lombok.Data;
|
||||
|
||||
/**
|
||||
* @author codex
|
||||
*/
|
||||
@Data
|
||||
public class CollaborationFileCommand {
|
||||
|
||||
@NotBlank(message = "文件类型不能为空")
|
||||
@Size(max = 30, message = "文件类型长度不能超过30个字符")
|
||||
private String fileType;
|
||||
|
||||
@NotBlank(message = "文件地址不能为空")
|
||||
@Size(max = 500, message = "文件地址长度不能超过500个字符")
|
||||
private String url;
|
||||
|
||||
@Size(max = 300, message = "文件路径长度不能超过300个字符")
|
||||
private String fileName;
|
||||
|
||||
@Size(max = 200, message = "服务端文件名长度不能超过200个字符")
|
||||
private String newFileName;
|
||||
|
||||
@Size(max = 300, message = "原始文件名长度不能超过300个字符")
|
||||
private String originalFilename;
|
||||
|
||||
}
|
||||
+28
@@ -0,0 +1,28 @@
|
||||
package com.agileboot.domain.collaboration.record.command;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import java.math.BigDecimal;
|
||||
import java.util.Date;
|
||||
import javax.validation.constraints.PositiveOrZero;
|
||||
import javax.validation.constraints.Size;
|
||||
import lombok.Data;
|
||||
|
||||
/**
|
||||
* @author codex
|
||||
*/
|
||||
@Data
|
||||
public class CollaborationSettlementCommand {
|
||||
|
||||
@JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8")
|
||||
private Date settleDate;
|
||||
|
||||
@Size(max = 30, message = "结款方式长度不能超过30个字符")
|
||||
private String method;
|
||||
|
||||
@PositiveOrZero(message = "结款金额不能小于0")
|
||||
private BigDecimal income;
|
||||
|
||||
@Size(max = 30, message = "结款用途长度不能超过30个字符")
|
||||
private String purpose;
|
||||
|
||||
}
|
||||
+16
@@ -0,0 +1,16 @@
|
||||
package com.agileboot.domain.collaboration.record.command;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import java.util.Date;
|
||||
import lombok.Data;
|
||||
|
||||
/**
|
||||
* @author codex
|
||||
*/
|
||||
@Data
|
||||
public class CollaborationTaskCommand {
|
||||
|
||||
@JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8")
|
||||
private Date releaseDate;
|
||||
|
||||
}
|
||||
+19
@@ -0,0 +1,19 @@
|
||||
package com.agileboot.domain.collaboration.record.command;
|
||||
|
||||
import javax.validation.constraints.NotNull;
|
||||
import javax.validation.constraints.Positive;
|
||||
import lombok.Data;
|
||||
import lombok.EqualsAndHashCode;
|
||||
|
||||
/**
|
||||
* @author codex
|
||||
*/
|
||||
@EqualsAndHashCode(callSuper = true)
|
||||
@Data
|
||||
public class UpdateCollaborationRecordCommand extends AddCollaborationRecordCommand {
|
||||
|
||||
@NotNull(message = "合作记录ID不能为空")
|
||||
@Positive
|
||||
private Long recordId;
|
||||
|
||||
}
|
||||
+46
@@ -0,0 +1,46 @@
|
||||
package com.agileboot.domain.collaboration.record.db;
|
||||
|
||||
import com.agileboot.common.core.base.BaseEntity;
|
||||
import com.baomidou.mybatisplus.annotation.IdType;
|
||||
import com.baomidou.mybatisplus.annotation.TableField;
|
||||
import com.baomidou.mybatisplus.annotation.TableId;
|
||||
import com.baomidou.mybatisplus.annotation.TableName;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import java.io.Serializable;
|
||||
import java.math.BigDecimal;
|
||||
import java.util.Date;
|
||||
import lombok.Getter;
|
||||
import lombok.Setter;
|
||||
|
||||
/**
|
||||
* @author codex
|
||||
*/
|
||||
@Getter
|
||||
@Setter
|
||||
@TableName("collaboration_expenditure")
|
||||
@ApiModel(value = "CollaborationExpenditureEntity对象", description = "合作支出表")
|
||||
public class CollaborationExpenditureEntity extends BaseEntity<CollaborationExpenditureEntity> {
|
||||
|
||||
@TableId(value = "expenditure_id", type = IdType.AUTO)
|
||||
private Long expenditureId;
|
||||
|
||||
@TableField("record_id")
|
||||
private Long recordId;
|
||||
|
||||
@JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8")
|
||||
@TableField("spend_date")
|
||||
private Date spendDate;
|
||||
|
||||
@TableField("amount")
|
||||
private BigDecimal amount;
|
||||
|
||||
@TableField("purpose")
|
||||
private String purpose;
|
||||
|
||||
@Override
|
||||
public Serializable pkVal() {
|
||||
return this.expenditureId;
|
||||
}
|
||||
|
||||
}
|
||||
+10
@@ -0,0 +1,10 @@
|
||||
package com.agileboot.domain.collaboration.record.db;
|
||||
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
|
||||
/**
|
||||
* @author codex
|
||||
*/
|
||||
public interface CollaborationExpenditureMapper extends BaseMapper<CollaborationExpenditureEntity> {
|
||||
|
||||
}
|
||||
+16
@@ -0,0 +1,16 @@
|
||||
package com.agileboot.domain.collaboration.record.db;
|
||||
|
||||
import com.baomidou.mybatisplus.extension.service.IService;
|
||||
import java.util.Collection;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @author codex
|
||||
*/
|
||||
public interface CollaborationExpenditureService extends IService<CollaborationExpenditureEntity> {
|
||||
|
||||
List<CollaborationExpenditureEntity> listByRecordId(Long recordId);
|
||||
|
||||
void removeByRecordIds(Collection<Long> recordIds);
|
||||
|
||||
}
|
||||
+36
@@ -0,0 +1,36 @@
|
||||
package com.agileboot.domain.collaboration.record.db;
|
||||
|
||||
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
||||
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||
import java.util.Collection;
|
||||
import java.util.Collections;
|
||||
import java.util.List;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
/**
|
||||
* @author codex
|
||||
*/
|
||||
@Service
|
||||
public class CollaborationExpenditureServiceImpl
|
||||
extends ServiceImpl<CollaborationExpenditureMapper, CollaborationExpenditureEntity>
|
||||
implements CollaborationExpenditureService {
|
||||
|
||||
@Override
|
||||
public List<CollaborationExpenditureEntity> listByRecordId(Long recordId) {
|
||||
if (recordId == null) {
|
||||
return Collections.emptyList();
|
||||
}
|
||||
return list(new QueryWrapper<CollaborationExpenditureEntity>()
|
||||
.eq("record_id", recordId)
|
||||
.orderByAsc("spend_date"));
|
||||
}
|
||||
|
||||
@Override
|
||||
public void removeByRecordIds(Collection<Long> recordIds) {
|
||||
if (recordIds == null || recordIds.isEmpty()) {
|
||||
return;
|
||||
}
|
||||
remove(new QueryWrapper<CollaborationExpenditureEntity>().in("record_id", recordIds));
|
||||
}
|
||||
|
||||
}
|
||||
+51
@@ -0,0 +1,51 @@
|
||||
package com.agileboot.domain.collaboration.record.db;
|
||||
|
||||
import com.agileboot.common.core.base.BaseEntity;
|
||||
import com.baomidou.mybatisplus.annotation.IdType;
|
||||
import com.baomidou.mybatisplus.annotation.TableField;
|
||||
import com.baomidou.mybatisplus.annotation.TableId;
|
||||
import com.baomidou.mybatisplus.annotation.TableName;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import java.io.Serializable;
|
||||
import lombok.Getter;
|
||||
import lombok.Setter;
|
||||
|
||||
/**
|
||||
* @author codex
|
||||
*/
|
||||
@Getter
|
||||
@Setter
|
||||
@TableName("collaboration_file")
|
||||
@ApiModel(value = "CollaborationFileEntity对象", description = "合作文件表")
|
||||
public class CollaborationFileEntity extends BaseEntity<CollaborationFileEntity> {
|
||||
|
||||
@TableId(value = "file_id", type = IdType.AUTO)
|
||||
private Long fileId;
|
||||
|
||||
@TableField("record_id")
|
||||
private Long recordId;
|
||||
|
||||
@TableField("file_type")
|
||||
private String fileType;
|
||||
|
||||
@TableField("url")
|
||||
private String url;
|
||||
|
||||
@TableField("file_name")
|
||||
private String fileName;
|
||||
|
||||
@TableField("new_file_name")
|
||||
private String newFileName;
|
||||
|
||||
@TableField("original_filename")
|
||||
private String originalFilename;
|
||||
|
||||
@TableField("sort_order")
|
||||
private Integer sortOrder;
|
||||
|
||||
@Override
|
||||
public Serializable pkVal() {
|
||||
return this.fileId;
|
||||
}
|
||||
|
||||
}
|
||||
+10
@@ -0,0 +1,10 @@
|
||||
package com.agileboot.domain.collaboration.record.db;
|
||||
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
|
||||
/**
|
||||
* @author codex
|
||||
*/
|
||||
public interface CollaborationFileMapper extends BaseMapper<CollaborationFileEntity> {
|
||||
|
||||
}
|
||||
+16
@@ -0,0 +1,16 @@
|
||||
package com.agileboot.domain.collaboration.record.db;
|
||||
|
||||
import com.baomidou.mybatisplus.extension.service.IService;
|
||||
import java.util.Collection;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @author codex
|
||||
*/
|
||||
public interface CollaborationFileService extends IService<CollaborationFileEntity> {
|
||||
|
||||
List<CollaborationFileEntity> listByRecordId(Long recordId);
|
||||
|
||||
void removeByRecordIds(Collection<Long> recordIds);
|
||||
|
||||
}
|
||||
+36
@@ -0,0 +1,36 @@
|
||||
package com.agileboot.domain.collaboration.record.db;
|
||||
|
||||
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
||||
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||
import java.util.Collection;
|
||||
import java.util.Collections;
|
||||
import java.util.List;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
/**
|
||||
* @author codex
|
||||
*/
|
||||
@Service
|
||||
public class CollaborationFileServiceImpl
|
||||
extends ServiceImpl<CollaborationFileMapper, CollaborationFileEntity>
|
||||
implements CollaborationFileService {
|
||||
|
||||
@Override
|
||||
public List<CollaborationFileEntity> listByRecordId(Long recordId) {
|
||||
if (recordId == null) {
|
||||
return Collections.emptyList();
|
||||
}
|
||||
return list(new QueryWrapper<CollaborationFileEntity>()
|
||||
.eq("record_id", recordId)
|
||||
.orderByAsc("file_type", "sort_order"));
|
||||
}
|
||||
|
||||
@Override
|
||||
public void removeByRecordIds(Collection<Long> recordIds) {
|
||||
if (recordIds == null || recordIds.isEmpty()) {
|
||||
return;
|
||||
}
|
||||
remove(new QueryWrapper<CollaborationFileEntity>().in("record_id", recordIds));
|
||||
}
|
||||
|
||||
}
|
||||
+100
@@ -0,0 +1,100 @@
|
||||
package com.agileboot.domain.collaboration.record.db;
|
||||
|
||||
import com.agileboot.common.core.base.BaseEntity;
|
||||
import com.baomidou.mybatisplus.annotation.IdType;
|
||||
import com.baomidou.mybatisplus.annotation.TableField;
|
||||
import com.baomidou.mybatisplus.annotation.TableId;
|
||||
import com.baomidou.mybatisplus.annotation.TableName;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import java.io.Serializable;
|
||||
import java.math.BigDecimal;
|
||||
import java.util.Date;
|
||||
import lombok.Getter;
|
||||
import lombok.Setter;
|
||||
|
||||
/**
|
||||
* @author codex
|
||||
*/
|
||||
@Getter
|
||||
@Setter
|
||||
@TableName("collaboration_record")
|
||||
@ApiModel(value = "CollaborationRecordEntity对象", description = "合作记录表")
|
||||
public class CollaborationRecordEntity extends BaseEntity<CollaborationRecordEntity> {
|
||||
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
@ApiModelProperty("合作记录ID")
|
||||
@TableId(value = "record_id", type = IdType.AUTO)
|
||||
private Long recordId;
|
||||
|
||||
@ApiModelProperty("品牌")
|
||||
@TableField("brand")
|
||||
private String brand;
|
||||
|
||||
@ApiModelProperty("物品")
|
||||
@TableField("goods")
|
||||
private String goods;
|
||||
|
||||
@ApiModelProperty("合作平台")
|
||||
@TableField("cooperation_platform")
|
||||
private String cooperationPlatform;
|
||||
|
||||
@ApiModelProperty("返图数量")
|
||||
@TableField("image_return_num")
|
||||
private Integer imageReturnNum;
|
||||
|
||||
@ApiModelProperty("留存方式")
|
||||
@TableField("retained_method")
|
||||
private String retainedMethod;
|
||||
|
||||
@ApiModelProperty("合作方式")
|
||||
@TableField("cooperated_method")
|
||||
private String cooperatedMethod;
|
||||
|
||||
@ApiModelProperty("购入方式")
|
||||
@TableField("purchase_method")
|
||||
private String purchaseMethod;
|
||||
|
||||
@ApiModelProperty("购入金额")
|
||||
@TableField("purchase_price")
|
||||
private BigDecimal purchasePrice;
|
||||
|
||||
@JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8")
|
||||
@ApiModelProperty("购入日期")
|
||||
@TableField("purchase_date")
|
||||
private Date purchaseDate;
|
||||
|
||||
@ApiModelProperty("购入平台")
|
||||
@TableField("purchase_platform")
|
||||
private String purchasePlatform;
|
||||
|
||||
@JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8")
|
||||
@ApiModelProperty("预完成日期")
|
||||
@TableField("deadline")
|
||||
private Date deadline;
|
||||
|
||||
@ApiModelProperty("稿费")
|
||||
@TableField("remuneration")
|
||||
private BigDecimal remuneration;
|
||||
|
||||
@JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8")
|
||||
@ApiModelProperty("完成日期")
|
||||
@TableField("complete_date")
|
||||
private Date completeDate;
|
||||
|
||||
@ApiModelProperty("拍摄要求")
|
||||
@TableField("requirements")
|
||||
private String requirements;
|
||||
|
||||
@ApiModelProperty("备注")
|
||||
@TableField("remark")
|
||||
private String remark;
|
||||
|
||||
@Override
|
||||
public Serializable pkVal() {
|
||||
return this.recordId;
|
||||
}
|
||||
|
||||
}
|
||||
+10
@@ -0,0 +1,10 @@
|
||||
package com.agileboot.domain.collaboration.record.db;
|
||||
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
|
||||
/**
|
||||
* @author codex
|
||||
*/
|
||||
public interface CollaborationRecordMapper extends BaseMapper<CollaborationRecordEntity> {
|
||||
|
||||
}
|
||||
+10
@@ -0,0 +1,10 @@
|
||||
package com.agileboot.domain.collaboration.record.db;
|
||||
|
||||
import com.baomidou.mybatisplus.extension.service.IService;
|
||||
|
||||
/**
|
||||
* @author codex
|
||||
*/
|
||||
public interface CollaborationRecordService extends IService<CollaborationRecordEntity> {
|
||||
|
||||
}
|
||||
+14
@@ -0,0 +1,14 @@
|
||||
package com.agileboot.domain.collaboration.record.db;
|
||||
|
||||
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
/**
|
||||
* @author codex
|
||||
*/
|
||||
@Service
|
||||
public class CollaborationRecordServiceImpl
|
||||
extends ServiceImpl<CollaborationRecordMapper, CollaborationRecordEntity>
|
||||
implements CollaborationRecordService {
|
||||
|
||||
}
|
||||
+49
@@ -0,0 +1,49 @@
|
||||
package com.agileboot.domain.collaboration.record.db;
|
||||
|
||||
import com.agileboot.common.core.base.BaseEntity;
|
||||
import com.baomidou.mybatisplus.annotation.IdType;
|
||||
import com.baomidou.mybatisplus.annotation.TableField;
|
||||
import com.baomidou.mybatisplus.annotation.TableId;
|
||||
import com.baomidou.mybatisplus.annotation.TableName;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import java.io.Serializable;
|
||||
import java.math.BigDecimal;
|
||||
import java.util.Date;
|
||||
import lombok.Getter;
|
||||
import lombok.Setter;
|
||||
|
||||
/**
|
||||
* @author codex
|
||||
*/
|
||||
@Getter
|
||||
@Setter
|
||||
@TableName("collaboration_settlement")
|
||||
@ApiModel(value = "CollaborationSettlementEntity对象", description = "合作结款表")
|
||||
public class CollaborationSettlementEntity extends BaseEntity<CollaborationSettlementEntity> {
|
||||
|
||||
@TableId(value = "settlement_id", type = IdType.AUTO)
|
||||
private Long settlementId;
|
||||
|
||||
@TableField("record_id")
|
||||
private Long recordId;
|
||||
|
||||
@JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8")
|
||||
@TableField("settle_date")
|
||||
private Date settleDate;
|
||||
|
||||
@TableField("method")
|
||||
private String method;
|
||||
|
||||
@TableField("income")
|
||||
private BigDecimal income;
|
||||
|
||||
@TableField("purpose")
|
||||
private String purpose;
|
||||
|
||||
@Override
|
||||
public Serializable pkVal() {
|
||||
return this.settlementId;
|
||||
}
|
||||
|
||||
}
|
||||
+10
@@ -0,0 +1,10 @@
|
||||
package com.agileboot.domain.collaboration.record.db;
|
||||
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
|
||||
/**
|
||||
* @author codex
|
||||
*/
|
||||
public interface CollaborationSettlementMapper extends BaseMapper<CollaborationSettlementEntity> {
|
||||
|
||||
}
|
||||
+16
@@ -0,0 +1,16 @@
|
||||
package com.agileboot.domain.collaboration.record.db;
|
||||
|
||||
import com.baomidou.mybatisplus.extension.service.IService;
|
||||
import java.util.Collection;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @author codex
|
||||
*/
|
||||
public interface CollaborationSettlementService extends IService<CollaborationSettlementEntity> {
|
||||
|
||||
List<CollaborationSettlementEntity> listByRecordId(Long recordId);
|
||||
|
||||
void removeByRecordIds(Collection<Long> recordIds);
|
||||
|
||||
}
|
||||
+36
@@ -0,0 +1,36 @@
|
||||
package com.agileboot.domain.collaboration.record.db;
|
||||
|
||||
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
||||
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||
import java.util.Collection;
|
||||
import java.util.Collections;
|
||||
import java.util.List;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
/**
|
||||
* @author codex
|
||||
*/
|
||||
@Service
|
||||
public class CollaborationSettlementServiceImpl
|
||||
extends ServiceImpl<CollaborationSettlementMapper, CollaborationSettlementEntity>
|
||||
implements CollaborationSettlementService {
|
||||
|
||||
@Override
|
||||
public List<CollaborationSettlementEntity> listByRecordId(Long recordId) {
|
||||
if (recordId == null) {
|
||||
return Collections.emptyList();
|
||||
}
|
||||
return list(new QueryWrapper<CollaborationSettlementEntity>()
|
||||
.eq("record_id", recordId)
|
||||
.orderByAsc("settle_date"));
|
||||
}
|
||||
|
||||
@Override
|
||||
public void removeByRecordIds(Collection<Long> recordIds) {
|
||||
if (recordIds == null || recordIds.isEmpty()) {
|
||||
return;
|
||||
}
|
||||
remove(new QueryWrapper<CollaborationSettlementEntity>().in("record_id", recordIds));
|
||||
}
|
||||
|
||||
}
|
||||
+42
@@ -0,0 +1,42 @@
|
||||
package com.agileboot.domain.collaboration.record.db;
|
||||
|
||||
import com.agileboot.common.core.base.BaseEntity;
|
||||
import com.baomidou.mybatisplus.annotation.IdType;
|
||||
import com.baomidou.mybatisplus.annotation.TableField;
|
||||
import com.baomidou.mybatisplus.annotation.TableId;
|
||||
import com.baomidou.mybatisplus.annotation.TableName;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import java.io.Serializable;
|
||||
import java.util.Date;
|
||||
import lombok.Getter;
|
||||
import lombok.Setter;
|
||||
|
||||
/**
|
||||
* @author codex
|
||||
*/
|
||||
@Getter
|
||||
@Setter
|
||||
@TableName("collaboration_task")
|
||||
@ApiModel(value = "CollaborationTaskEntity对象", description = "合作笔记任务表")
|
||||
public class CollaborationTaskEntity extends BaseEntity<CollaborationTaskEntity> {
|
||||
|
||||
@TableId(value = "task_id", type = IdType.AUTO)
|
||||
private Long taskId;
|
||||
|
||||
@TableField("record_id")
|
||||
private Long recordId;
|
||||
|
||||
@JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8")
|
||||
@TableField("release_date")
|
||||
private Date releaseDate;
|
||||
|
||||
@TableField("sort_order")
|
||||
private Integer sortOrder;
|
||||
|
||||
@Override
|
||||
public Serializable pkVal() {
|
||||
return this.taskId;
|
||||
}
|
||||
|
||||
}
|
||||
+10
@@ -0,0 +1,10 @@
|
||||
package com.agileboot.domain.collaboration.record.db;
|
||||
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
|
||||
/**
|
||||
* @author codex
|
||||
*/
|
||||
public interface CollaborationTaskMapper extends BaseMapper<CollaborationTaskEntity> {
|
||||
|
||||
}
|
||||
+16
@@ -0,0 +1,16 @@
|
||||
package com.agileboot.domain.collaboration.record.db;
|
||||
|
||||
import com.baomidou.mybatisplus.extension.service.IService;
|
||||
import java.util.Collection;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @author codex
|
||||
*/
|
||||
public interface CollaborationTaskService extends IService<CollaborationTaskEntity> {
|
||||
|
||||
List<CollaborationTaskEntity> listByRecordId(Long recordId);
|
||||
|
||||
void removeByRecordIds(Collection<Long> recordIds);
|
||||
|
||||
}
|
||||
+36
@@ -0,0 +1,36 @@
|
||||
package com.agileboot.domain.collaboration.record.db;
|
||||
|
||||
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
||||
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||
import java.util.Collection;
|
||||
import java.util.Collections;
|
||||
import java.util.List;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
/**
|
||||
* @author codex
|
||||
*/
|
||||
@Service
|
||||
public class CollaborationTaskServiceImpl
|
||||
extends ServiceImpl<CollaborationTaskMapper, CollaborationTaskEntity>
|
||||
implements CollaborationTaskService {
|
||||
|
||||
@Override
|
||||
public List<CollaborationTaskEntity> listByRecordId(Long recordId) {
|
||||
if (recordId == null) {
|
||||
return Collections.emptyList();
|
||||
}
|
||||
return list(new QueryWrapper<CollaborationTaskEntity>()
|
||||
.eq("record_id", recordId)
|
||||
.orderByAsc("sort_order"));
|
||||
}
|
||||
|
||||
@Override
|
||||
public void removeByRecordIds(Collection<Long> recordIds) {
|
||||
if (recordIds == null || recordIds.isEmpty()) {
|
||||
return;
|
||||
}
|
||||
remove(new QueryWrapper<CollaborationTaskEntity>().in("record_id", recordIds));
|
||||
}
|
||||
|
||||
}
|
||||
+33
@@ -0,0 +1,33 @@
|
||||
package com.agileboot.domain.collaboration.record.dto;
|
||||
|
||||
import cn.hutool.core.bean.BeanUtil;
|
||||
import com.agileboot.domain.collaboration.record.db.CollaborationExpenditureEntity;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import java.math.BigDecimal;
|
||||
import java.util.Date;
|
||||
import lombok.Data;
|
||||
import lombok.NoArgsConstructor;
|
||||
|
||||
/**
|
||||
* @author codex
|
||||
*/
|
||||
@NoArgsConstructor
|
||||
@Data
|
||||
public class CollaborationExpenditureDTO {
|
||||
|
||||
public CollaborationExpenditureDTO(CollaborationExpenditureEntity entity) {
|
||||
if (entity != null) {
|
||||
BeanUtil.copyProperties(entity, this);
|
||||
}
|
||||
}
|
||||
|
||||
private Long expenditureId;
|
||||
|
||||
@JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8")
|
||||
private Date spendDate;
|
||||
|
||||
private BigDecimal amount;
|
||||
|
||||
private String purpose;
|
||||
|
||||
}
|
||||
+35
@@ -0,0 +1,35 @@
|
||||
package com.agileboot.domain.collaboration.record.dto;
|
||||
|
||||
import cn.hutool.core.bean.BeanUtil;
|
||||
import com.agileboot.domain.collaboration.record.db.CollaborationFileEntity;
|
||||
import lombok.Data;
|
||||
import lombok.NoArgsConstructor;
|
||||
|
||||
/**
|
||||
* @author codex
|
||||
*/
|
||||
@NoArgsConstructor
|
||||
@Data
|
||||
public class CollaborationFileDTO {
|
||||
|
||||
public CollaborationFileDTO(CollaborationFileEntity entity) {
|
||||
if (entity != null) {
|
||||
BeanUtil.copyProperties(entity, this);
|
||||
}
|
||||
}
|
||||
|
||||
private Long fileId;
|
||||
|
||||
private String fileType;
|
||||
|
||||
private String url;
|
||||
|
||||
private String fileName;
|
||||
|
||||
private String newFileName;
|
||||
|
||||
private String originalFilename;
|
||||
|
||||
private Integer sortOrder;
|
||||
|
||||
}
|
||||
+26
@@ -0,0 +1,26 @@
|
||||
package com.agileboot.domain.collaboration.record.dto;
|
||||
|
||||
import java.math.BigDecimal;
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.Data;
|
||||
import lombok.NoArgsConstructor;
|
||||
|
||||
/**
|
||||
* @author codex
|
||||
*/
|
||||
@AllArgsConstructor
|
||||
@NoArgsConstructor
|
||||
@Data
|
||||
public class CollaborationMonthlyStatisticsDTO {
|
||||
|
||||
private Integer month;
|
||||
|
||||
private BigDecimal purchasePrice;
|
||||
|
||||
private BigDecimal expenditureAmount;
|
||||
|
||||
private BigDecimal settledRemuneration;
|
||||
|
||||
private BigDecimal settledTotal;
|
||||
|
||||
}
|
||||
+22
@@ -0,0 +1,22 @@
|
||||
package com.agileboot.domain.collaboration.record.dto;
|
||||
|
||||
import java.util.List;
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.Data;
|
||||
import lombok.NoArgsConstructor;
|
||||
|
||||
/**
|
||||
* @author codex
|
||||
*/
|
||||
@AllArgsConstructor
|
||||
@NoArgsConstructor
|
||||
@Data
|
||||
public class CollaborationOptionDTO {
|
||||
|
||||
private String type;
|
||||
|
||||
private String label;
|
||||
|
||||
private List<String> values;
|
||||
|
||||
}
|
||||
+71
@@ -0,0 +1,71 @@
|
||||
package com.agileboot.domain.collaboration.record.dto;
|
||||
|
||||
import cn.hutool.core.bean.BeanUtil;
|
||||
import com.agileboot.domain.collaboration.record.db.CollaborationRecordEntity;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import java.math.BigDecimal;
|
||||
import java.util.Date;
|
||||
import lombok.Data;
|
||||
import lombok.NoArgsConstructor;
|
||||
|
||||
/**
|
||||
* @author codex
|
||||
*/
|
||||
@NoArgsConstructor
|
||||
@Data
|
||||
public class CollaborationRecordDTO {
|
||||
|
||||
public CollaborationRecordDTO(CollaborationRecordEntity entity) {
|
||||
if (entity != null) {
|
||||
BeanUtil.copyProperties(entity, this);
|
||||
}
|
||||
}
|
||||
|
||||
private Long recordId;
|
||||
|
||||
private String brand;
|
||||
|
||||
private String goods;
|
||||
|
||||
private String cooperationPlatform;
|
||||
|
||||
private Integer imageReturnNum;
|
||||
|
||||
private String retainedMethod;
|
||||
|
||||
private String cooperatedMethod;
|
||||
|
||||
private String purchaseMethod;
|
||||
|
||||
private BigDecimal purchasePrice;
|
||||
|
||||
@JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8")
|
||||
private Date purchaseDate;
|
||||
|
||||
private String purchasePlatform;
|
||||
|
||||
@JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8")
|
||||
private Date deadline;
|
||||
|
||||
private BigDecimal remuneration;
|
||||
|
||||
@JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8")
|
||||
private Date completeDate;
|
||||
|
||||
private String requirements;
|
||||
|
||||
private String remark;
|
||||
|
||||
private Integer tasksNum;
|
||||
|
||||
private Integer completedTasksNum;
|
||||
|
||||
private SettlementStatusDTO purchaseSettlementStatus;
|
||||
|
||||
private SettlementStatusDTO deliverySettlementStatus;
|
||||
|
||||
private SettlementStatusDTO remunerationSettlementStatus;
|
||||
|
||||
private Date createTime;
|
||||
|
||||
}
|
||||
+30
@@ -0,0 +1,30 @@
|
||||
package com.agileboot.domain.collaboration.record.dto;
|
||||
|
||||
import com.agileboot.domain.collaboration.record.db.CollaborationRecordEntity;
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
import lombok.Data;
|
||||
import lombok.EqualsAndHashCode;
|
||||
import lombok.NoArgsConstructor;
|
||||
|
||||
/**
|
||||
* @author codex
|
||||
*/
|
||||
@EqualsAndHashCode(callSuper = true)
|
||||
@NoArgsConstructor
|
||||
@Data
|
||||
public class CollaborationRecordDetailDTO extends CollaborationRecordDTO {
|
||||
|
||||
public CollaborationRecordDetailDTO(CollaborationRecordEntity entity) {
|
||||
super(entity);
|
||||
}
|
||||
|
||||
private List<CollaborationTaskDTO> tasks = new ArrayList<>();
|
||||
|
||||
private List<CollaborationExpenditureDTO> expenditures = new ArrayList<>();
|
||||
|
||||
private List<CollaborationSettlementDTO> settlements = new ArrayList<>();
|
||||
|
||||
private List<CollaborationFileDTO> files = new ArrayList<>();
|
||||
|
||||
}
|
||||
+35
@@ -0,0 +1,35 @@
|
||||
package com.agileboot.domain.collaboration.record.dto;
|
||||
|
||||
import cn.hutool.core.bean.BeanUtil;
|
||||
import com.agileboot.domain.collaboration.record.db.CollaborationSettlementEntity;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import java.math.BigDecimal;
|
||||
import java.util.Date;
|
||||
import lombok.Data;
|
||||
import lombok.NoArgsConstructor;
|
||||
|
||||
/**
|
||||
* @author codex
|
||||
*/
|
||||
@NoArgsConstructor
|
||||
@Data
|
||||
public class CollaborationSettlementDTO {
|
||||
|
||||
public CollaborationSettlementDTO(CollaborationSettlementEntity entity) {
|
||||
if (entity != null) {
|
||||
BeanUtil.copyProperties(entity, this);
|
||||
}
|
||||
}
|
||||
|
||||
private Long settlementId;
|
||||
|
||||
@JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8")
|
||||
private Date settleDate;
|
||||
|
||||
private String method;
|
||||
|
||||
private BigDecimal income;
|
||||
|
||||
private String purpose;
|
||||
|
||||
}
|
||||
+30
@@ -0,0 +1,30 @@
|
||||
package com.agileboot.domain.collaboration.record.dto;
|
||||
|
||||
import cn.hutool.core.bean.BeanUtil;
|
||||
import com.agileboot.domain.collaboration.record.db.CollaborationTaskEntity;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import java.util.Date;
|
||||
import lombok.Data;
|
||||
import lombok.NoArgsConstructor;
|
||||
|
||||
/**
|
||||
* @author codex
|
||||
*/
|
||||
@NoArgsConstructor
|
||||
@Data
|
||||
public class CollaborationTaskDTO {
|
||||
|
||||
public CollaborationTaskDTO(CollaborationTaskEntity entity) {
|
||||
if (entity != null) {
|
||||
BeanUtil.copyProperties(entity, this);
|
||||
}
|
||||
}
|
||||
|
||||
private Long taskId;
|
||||
|
||||
@JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8")
|
||||
private Date releaseDate;
|
||||
|
||||
private Integer sortOrder;
|
||||
|
||||
}
|
||||
+19
@@ -0,0 +1,19 @@
|
||||
package com.agileboot.domain.collaboration.record.dto;
|
||||
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.Data;
|
||||
import lombok.NoArgsConstructor;
|
||||
|
||||
/**
|
||||
* @author codex
|
||||
*/
|
||||
@AllArgsConstructor
|
||||
@NoArgsConstructor
|
||||
@Data
|
||||
public class SettlementStatusDTO {
|
||||
|
||||
private String status;
|
||||
|
||||
private String label;
|
||||
|
||||
}
|
||||
+12
@@ -0,0 +1,12 @@
|
||||
package com.agileboot.domain.collaboration.record.enumtype;
|
||||
|
||||
/**
|
||||
* @author codex
|
||||
*/
|
||||
public enum CollaborationFileTypeEnum {
|
||||
|
||||
GOODS_IMAGE,
|
||||
|
||||
ATTACHMENT
|
||||
|
||||
}
|
||||
+45
@@ -0,0 +1,45 @@
|
||||
package com.agileboot.domain.collaboration.record.enumtype;
|
||||
|
||||
import lombok.Getter;
|
||||
|
||||
/**
|
||||
* @author codex
|
||||
*/
|
||||
@Getter
|
||||
public enum CollaborationOptionEnum {
|
||||
|
||||
COOPERATION_PLATFORM("cooperationPlatform", "合作平台",
|
||||
new String[]{"小红书", "得物", "抖音", "淘宝", "京东", "微博", "B站", "其他"}),
|
||||
|
||||
RETAINED_METHOD("retainedMethod", "留存方式",
|
||||
new String[]{"寄拍", "送拍", "置换", "无需寄样"}),
|
||||
|
||||
COOPERATED_METHOD("cooperatedMethod", "合作方式",
|
||||
new String[]{"水下", "蒲公英"}),
|
||||
|
||||
PURCHASE_METHOD("purchaseMethod", "购入方式",
|
||||
new String[]{"拍单", "商家寄出"}),
|
||||
|
||||
PURCHASE_PLATFORM("purchasePlatform", "购入平台",
|
||||
new String[]{"淘宝", "小红书", "京东", "抖音"}),
|
||||
|
||||
EXPENDITURE_PURPOSE("expenditurePurpose", "支出用途",
|
||||
new String[]{"快递费用", "返点", "蒲公英扣税费用"}),
|
||||
|
||||
SETTLEMENT_METHOD("settlementMethod", "结款方式",
|
||||
new String[]{"微信", "支付宝", "蒲公英", "京灵平台"}),
|
||||
|
||||
SETTLEMENT_PURPOSE("settlementPurpose", "结款用途",
|
||||
new String[]{"稿费", "快递费用", "拍单费用", "蒲公英扣税费用"});
|
||||
|
||||
private final String type;
|
||||
private final String label;
|
||||
private final String[] values;
|
||||
|
||||
CollaborationOptionEnum(String type, String label, String[] values) {
|
||||
this.type = type;
|
||||
this.label = label;
|
||||
this.values = values;
|
||||
}
|
||||
|
||||
}
|
||||
+27
@@ -0,0 +1,27 @@
|
||||
package com.agileboot.domain.collaboration.record.enumtype;
|
||||
|
||||
import lombok.Getter;
|
||||
|
||||
/**
|
||||
* @author codex
|
||||
*/
|
||||
@Getter
|
||||
public enum SettlementStatusEnum {
|
||||
|
||||
NONE("NONE", "无结款项"),
|
||||
|
||||
SETTLED("SETTLED", "已结"),
|
||||
|
||||
UNSETTLED("UNSETTLED", "未结"),
|
||||
|
||||
PARTIAL("PARTIAL", "未结清");
|
||||
|
||||
private final String value;
|
||||
private final String label;
|
||||
|
||||
SettlementStatusEnum(String value, String label) {
|
||||
this.value = value;
|
||||
this.label = label;
|
||||
}
|
||||
|
||||
}
|
||||
+79
@@ -0,0 +1,79 @@
|
||||
package com.agileboot.domain.collaboration.record.model;
|
||||
|
||||
import cn.hutool.core.bean.BeanUtil;
|
||||
import cn.hutool.core.util.StrUtil;
|
||||
import com.agileboot.common.exception.ApiException;
|
||||
import com.agileboot.common.exception.error.ErrorCode;
|
||||
import com.agileboot.domain.collaboration.record.command.AddCollaborationRecordCommand;
|
||||
import com.agileboot.domain.collaboration.record.command.UpdateCollaborationRecordCommand;
|
||||
import com.agileboot.domain.collaboration.record.db.CollaborationRecordEntity;
|
||||
import com.agileboot.domain.collaboration.record.db.CollaborationRecordService;
|
||||
import lombok.NoArgsConstructor;
|
||||
|
||||
/**
|
||||
* @author codex
|
||||
*/
|
||||
@NoArgsConstructor
|
||||
public class CollaborationRecordModel extends CollaborationRecordEntity {
|
||||
|
||||
private CollaborationRecordService recordService;
|
||||
|
||||
public CollaborationRecordModel(CollaborationRecordService recordService) {
|
||||
this.recordService = recordService;
|
||||
}
|
||||
|
||||
public CollaborationRecordModel(CollaborationRecordEntity entity, CollaborationRecordService recordService) {
|
||||
if (entity != null) {
|
||||
BeanUtil.copyProperties(entity, this);
|
||||
}
|
||||
this.recordService = recordService;
|
||||
}
|
||||
|
||||
public void loadFromAddCommand(AddCollaborationRecordCommand command) {
|
||||
if (command == null) {
|
||||
return;
|
||||
}
|
||||
BeanUtil.copyProperties(command, this, "recordId");
|
||||
loadDefaultValues();
|
||||
}
|
||||
|
||||
public void loadFromUpdateCommand(UpdateCollaborationRecordCommand command) {
|
||||
if (command == null) {
|
||||
return;
|
||||
}
|
||||
loadFromAddCommand(command);
|
||||
}
|
||||
|
||||
public void checkRequiredFields() {
|
||||
if (StrUtil.isBlank(getBrand())) {
|
||||
throw new ApiException(ErrorCode.FAILED);
|
||||
}
|
||||
if (StrUtil.isBlank(getGoods())) {
|
||||
throw new ApiException(ErrorCode.FAILED);
|
||||
}
|
||||
}
|
||||
|
||||
public void saveRecord() {
|
||||
recordService.save(this);
|
||||
}
|
||||
|
||||
public void updateRecord() {
|
||||
recordService.updateById(this);
|
||||
}
|
||||
|
||||
private void loadDefaultValues() {
|
||||
if (getImageReturnNum() == null) {
|
||||
setImageReturnNum(1);
|
||||
}
|
||||
if (StrUtil.isBlank(getRetainedMethod())) {
|
||||
setRetainedMethod("寄拍");
|
||||
}
|
||||
if (StrUtil.isBlank(getCooperatedMethod())) {
|
||||
setCooperatedMethod("水下");
|
||||
}
|
||||
if (StrUtil.isBlank(getPurchaseMethod())) {
|
||||
setPurchaseMethod("拍单");
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
+31
@@ -0,0 +1,31 @@
|
||||
package com.agileboot.domain.collaboration.record.model;
|
||||
|
||||
import com.agileboot.common.exception.ApiException;
|
||||
import com.agileboot.common.exception.error.ErrorCode.Business;
|
||||
import com.agileboot.domain.collaboration.record.db.CollaborationRecordEntity;
|
||||
import com.agileboot.domain.collaboration.record.db.CollaborationRecordService;
|
||||
import lombok.RequiredArgsConstructor;
|
||||
import org.springframework.stereotype.Component;
|
||||
|
||||
/**
|
||||
* @author codex
|
||||
*/
|
||||
@Component
|
||||
@RequiredArgsConstructor
|
||||
public class CollaborationRecordModelFactory {
|
||||
|
||||
private final CollaborationRecordService recordService;
|
||||
|
||||
public CollaborationRecordModel loadById(Long recordId) {
|
||||
CollaborationRecordEntity entity = recordService.getById(recordId);
|
||||
if (entity == null) {
|
||||
throw new ApiException(Business.COMMON_OBJECT_NOT_FOUND, recordId, "合作记录");
|
||||
}
|
||||
return new CollaborationRecordModel(entity, recordService);
|
||||
}
|
||||
|
||||
public CollaborationRecordModel create() {
|
||||
return new CollaborationRecordModel(recordService);
|
||||
}
|
||||
|
||||
}
|
||||
+49
@@ -0,0 +1,49 @@
|
||||
package com.agileboot.domain.collaboration.record.query;
|
||||
|
||||
import cn.hutool.core.util.StrUtil;
|
||||
import com.agileboot.common.core.page.AbstractPageQuery;
|
||||
import com.agileboot.common.utils.time.DatePickUtil;
|
||||
import com.agileboot.domain.collaboration.record.db.CollaborationRecordEntity;
|
||||
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import java.util.Date;
|
||||
import lombok.Data;
|
||||
import lombok.EqualsAndHashCode;
|
||||
|
||||
/**
|
||||
* @author codex
|
||||
*/
|
||||
@EqualsAndHashCode(callSuper = true)
|
||||
@Data
|
||||
public class CollaborationRecordQuery extends AbstractPageQuery<CollaborationRecordEntity> {
|
||||
|
||||
private String brand;
|
||||
|
||||
private String goods;
|
||||
|
||||
private String cooperationPlatform;
|
||||
|
||||
@JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8")
|
||||
private Date purchaseBeginTime;
|
||||
|
||||
@JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8")
|
||||
private Date purchaseEndTime;
|
||||
|
||||
@Override
|
||||
public QueryWrapper<CollaborationRecordEntity> addQueryCondition() {
|
||||
QueryWrapper<CollaborationRecordEntity> queryWrapper = new QueryWrapper<CollaborationRecordEntity>()
|
||||
.like(StrUtil.isNotEmpty(brand), "brand", brand)
|
||||
.like(StrUtil.isNotEmpty(goods), "goods", goods)
|
||||
.eq(StrUtil.isNotEmpty(cooperationPlatform), "cooperation_platform", cooperationPlatform)
|
||||
.ge(purchaseBeginTime != null, "purchase_date", DatePickUtil.getBeginOfTheDay(purchaseBeginTime))
|
||||
.le(purchaseEndTime != null, "purchase_date", DatePickUtil.getEndOfTheDay(purchaseEndTime));
|
||||
|
||||
if (StrUtil.isEmpty(this.getOrderColumn())) {
|
||||
this.setOrderColumn("deadline");
|
||||
this.setOrderDirection("descending");
|
||||
}
|
||||
this.setTimeRangeColumn("deadline");
|
||||
return queryWrapper;
|
||||
}
|
||||
|
||||
}
|
||||
@@ -1,67 +0,0 @@
|
||||
@echo off
|
||||
|
||||
rem jar平级目录
|
||||
set AppName=agileboot-admin.jar
|
||||
|
||||
rem JVM参数
|
||||
set JVM_OPTS="-Dname=%AppName% -Duser.timezone=Asia/Shanghai -Xms512m -Xmx1024m -XX:MetaspaceSize=128m -XX:MaxMetaspaceSize=512m -XX:+HeapDumpOnOutOfMemoryError -XX:+PrintGCDateStamps -XX:+PrintGCDetails -XX:NewRatio=1 -XX:SurvivorRatio=30 -XX:+UseParallelGC -XX:+UseParallelOldGC"
|
||||
|
||||
|
||||
ECHO.
|
||||
ECHO. [1] 启动%AppName%
|
||||
ECHO. [2] 关闭%AppName%
|
||||
ECHO. [3] 重启%AppName%
|
||||
ECHO. [4] 启动状态 %AppName%
|
||||
ECHO. [5] 退 出
|
||||
ECHO.
|
||||
|
||||
ECHO.请输入选择项目的序号:
|
||||
set /p ID=
|
||||
IF "%id%"=="1" GOTO start
|
||||
IF "%id%"=="2" GOTO stop
|
||||
IF "%id%"=="3" GOTO restart
|
||||
IF "%id%"=="4" GOTO status
|
||||
IF "%id%"=="5" EXIT
|
||||
PAUSE
|
||||
:start
|
||||
for /f "usebackq tokens=1-2" %%a in (`jps -l ^| findstr %AppName%`) do (
|
||||
set pid=%%a
|
||||
set image_name=%%b
|
||||
)
|
||||
if defined pid (
|
||||
echo %%is running
|
||||
PAUSE
|
||||
)
|
||||
|
||||
start javaw %JVM_OPTS% -jar %AppName%
|
||||
|
||||
echo starting……
|
||||
echo Start %AppName% success...
|
||||
goto:eof
|
||||
|
||||
rem 函数stop通过jps命令查找pid并结束进程
|
||||
:stop
|
||||
for /f "usebackq tokens=1-2" %%a in (`jps -l ^| findstr %AppName%`) do (
|
||||
set pid=%%a
|
||||
set image_name=%%b
|
||||
)
|
||||
if not defined pid (echo process %AppName% does not exists) else (
|
||||
echo prepare to kill %image_name%
|
||||
echo start kill %pid% ...
|
||||
rem 根据进程ID,kill进程
|
||||
taskkill /f /pid %pid%
|
||||
)
|
||||
goto:eof
|
||||
:restart
|
||||
call :stop
|
||||
call :start
|
||||
goto:eof
|
||||
:status
|
||||
for /f "usebackq tokens=1-2" %%a in (`jps -l ^| findstr %AppName%`) do (
|
||||
set pid=%%a
|
||||
set image_name=%%b
|
||||
)
|
||||
if not defined pid (echo process %AppName% is dead ) else (
|
||||
echo %image_name% is running
|
||||
)
|
||||
goto:eof
|
||||
@@ -1,86 +0,0 @@
|
||||
#!/bin/sh
|
||||
# ./ag-admin.sh start 启动 stop 停止 restart 重启 status 状态
|
||||
AppName=agileboot-admin.jar
|
||||
|
||||
# JVM参数
|
||||
JVM_OPTS="-Dname=$AppName -Duser.timezone=Asia/Shanghai -Xms512m -Xmx1024m -XX:MetaspaceSize=128m -XX:MaxMetaspaceSize=512m -XX:+HeapDumpOnOutOfMemoryError -XX:+PrintGCDateStamps -XX:+PrintGCDetails -XX:NewRatio=1 -XX:SurvivorRatio=30 -XX:+UseParallelGC -XX:+UseParallelOldGC"
|
||||
APP_HOME=`pwd`
|
||||
LOG_PATH=$APP_HOME/logs/$AppName.log
|
||||
|
||||
if [ "$1" = "" ];
|
||||
then
|
||||
echo -e "\033[0;31m 未输入操作名 \033[0m \033[0;34m {start|stop|restart|status} \033[0m"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
if [ "$AppName" = "" ];
|
||||
then
|
||||
echo -e "\033[0;31m 未输入应用名 \033[0m"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
function start()
|
||||
{
|
||||
PID=`ps -ef |grep java|grep $AppName|grep -v grep|awk '{print $2}'`
|
||||
|
||||
if [ x"$PID" != x"" ]; then
|
||||
echo "$AppName is running..."
|
||||
else
|
||||
nohup java $JVM_OPTS -jar $AppName > /dev/null 2>&1 &
|
||||
echo "Start $AppName success..."
|
||||
fi
|
||||
}
|
||||
|
||||
function stop()
|
||||
{
|
||||
echo "Stop $AppName"
|
||||
|
||||
PID=""
|
||||
query(){
|
||||
PID=`ps -ef |grep java|grep $AppName|grep -v grep|awk '{print $2}'`
|
||||
}
|
||||
|
||||
query
|
||||
if [ x"$PID" != x"" ]; then
|
||||
kill -TERM $PID
|
||||
echo "$AppName (pid:$PID) exiting..."
|
||||
while [ x"$PID" != x"" ]
|
||||
do
|
||||
sleep 1
|
||||
query
|
||||
done
|
||||
echo "$AppName exited."
|
||||
else
|
||||
echo "$AppName already stopped."
|
||||
fi
|
||||
}
|
||||
|
||||
function restart()
|
||||
{
|
||||
stop
|
||||
sleep 2
|
||||
start
|
||||
}
|
||||
|
||||
function status()
|
||||
{
|
||||
PID=`ps -ef |grep java|grep $AppName|grep -v grep|wc -l`
|
||||
if [ $PID != 0 ];then
|
||||
echo "$AppName is running..."
|
||||
else
|
||||
echo "$AppName is not running..."
|
||||
fi
|
||||
}
|
||||
|
||||
case $1 in
|
||||
start)
|
||||
start;;
|
||||
stop)
|
||||
stop;;
|
||||
restart)
|
||||
restart;;
|
||||
status)
|
||||
status;;
|
||||
*)
|
||||
|
||||
esac
|
||||
@@ -1,14 +0,0 @@
|
||||
@echo off
|
||||
echo.
|
||||
echo [信息] 使用Jar命令运行Web工程。
|
||||
echo.
|
||||
|
||||
cd %~dp0
|
||||
cd ../agileboot-admin/target
|
||||
|
||||
set JAVA_OPTS=-Xms256m -Xmx1024m -XX:MetaspaceSize=128m -XX:MaxMetaspaceSize=512m
|
||||
|
||||
java -jar %JAVA_OPTS% agileboot-admin.jar
|
||||
|
||||
cd bin
|
||||
pause
|
||||
+16
-12
@@ -1,34 +1,38 @@
|
||||
services:
|
||||
mysql:
|
||||
image: mysql:8.0
|
||||
container_name: mysql-server
|
||||
container_name: todo-mysql-server
|
||||
restart: always
|
||||
command:
|
||||
- --character-set-server=utf8mb4
|
||||
- --collation-server=utf8mb4_unicode_ci
|
||||
environment:
|
||||
MYSQL_ROOT_PASSWORD: root123
|
||||
MYSQL_DATABASE: agileboot_pure
|
||||
MYSQL_DATABASE: todo_agileboot_pure
|
||||
ports:
|
||||
- "3306:3306"
|
||||
- "33061:3306"
|
||||
volumes:
|
||||
- mysql_data:/var/lib/mysql
|
||||
- todo_mysql_data:/var/lib/mysql
|
||||
- ./sql/agileboot.sql:/docker-entrypoint-initdb.d/01-agileboot.sql:ro
|
||||
networks:
|
||||
- db-network
|
||||
- todo-db-network
|
||||
|
||||
redis:
|
||||
image: redis:7.2-alpine
|
||||
container_name: redis-server
|
||||
container_name: todo-redis-server
|
||||
restart: always
|
||||
command: redis-server --requirepass redis123
|
||||
ports:
|
||||
- "6379:6379"
|
||||
- "63791:6379"
|
||||
volumes:
|
||||
- redis_data:/data
|
||||
- todo_redis_data:/data
|
||||
networks:
|
||||
- db-network
|
||||
- todo-db-network
|
||||
|
||||
volumes:
|
||||
mysql_data:
|
||||
redis_data:
|
||||
todo_mysql_data:
|
||||
todo_redis_data:
|
||||
|
||||
networks:
|
||||
db-network:
|
||||
todo-db-network:
|
||||
driver: bridge
|
||||
|
||||
@@ -1,3 +1,8 @@
|
||||
SET NAMES utf8mb4;
|
||||
SET character_set_client = utf8mb4;
|
||||
SET character_set_connection = utf8mb4;
|
||||
SET character_set_results = utf8mb4;
|
||||
|
||||
create table sys_config
|
||||
(
|
||||
config_id int auto_increment comment '参数主键'
|
||||
@@ -101,68 +106,66 @@ create table sys_menu
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (1, '系统管理', 2, '', 0, '/system', 0, '', '{"title":"系统管理","icon":"ep:management","showParent":true,"rank":1}', 1, '系统管理目录', 0, '2022-05-21 08:30:54', 1, '2023-08-14 23:08:50', 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (2, '系统监控', 2, '', 0, '/monitor', 0, '', '{"title":"系统监控","icon":"ep:monitor","showParent":true,"rank":3}', 1, '系统监控目录', 0, '2022-05-21 08:30:54', 1, '2023-08-14 23:09:15', 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (3, '系统工具', 2, '', 0, '/tool', 0, '', '{"title":"系统工具","icon":"ep:tools","showParent":true,"rank":2}', 1, '系统工具目录', 0, '2022-05-21 08:30:54', 1, '2023-08-14 23:09:03', 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (4, 'AgileBoot官网', 3, 'AgileBootguanwangIframeRouter', 0, '/AgileBootguanwangIframeLink', 0, '', '{"title":"AgileBoot官网","icon":"ep:link","showParent":true,"frameSrc":"https://element-plus.org/zh-CN/","rank":8}', 1, 'Agileboot官网地址', 0, '2022-05-21 08:30:54', 1, '2023-08-14 23:09:40', 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (5, '用户管理', 1, 'SystemUser', 1, '/system/user/index', 0, 'system:user:list', '{"title":"用户管理","icon":"ep:user-filled","showParent":true}', 1, '用户管理菜单', 0, '2022-05-21 08:30:54', 1, '2023-08-14 23:16:13', 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (6, '角色管理', 1, 'SystemRole', 1, '/system/role/index', 0, 'system:role:list', '{"title":"角色管理","icon":"ep:user","showParent":true}', 1, '角色管理菜单', 0, '2022-05-21 08:30:54', 1, '2023-08-14 23:16:23', 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (7, '菜单管理', 1, 'MenuManagement', 1, '/system/menu/index', 0, 'system:menu:list', '{"title":"菜单管理","icon":"ep:menu","showParent":true}', 1, '菜单管理菜单', 0, '2022-05-21 08:30:54', 1, '2023-08-14 23:15:41', 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (8, '部门管理', 1, 'Department', 1, '/system/dept/index', 0, 'system:dept:list', '{"title":"部门管理","icon":"fa-solid:code-branch","showParent":true}', 1, '部门管理菜单', 0, '2022-05-21 08:30:54', 1, '2023-08-14 23:15:35', 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (9, '岗位管理', 1, 'Post', 1, '/system/post/index', 0, 'system:post:list', '{"title":"岗位管理","icon":"ep:postcard","showParent":true}', 1, '岗位管理菜单', 0, '2022-05-21 08:30:54', 1, '2023-08-14 23:15:11', 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (10, '参数设置', 1, 'Config', 1, '/system/config/index', 0, 'system:config:list', '{"title":"参数设置","icon":"ep:setting","showParent":true}', 1, '参数设置菜单', 0, '2022-05-21 08:30:54', 1, '2023-08-14 23:15:03', 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (11, '通知公告', 1, 'SystemNotice', 1, '/system/notice/index', 0, 'system:notice:list', '{"title":"通知公告","icon":"ep:notification","showParent":true}', 1, '通知公告菜单', 0, '2022-05-21 08:30:54', 1, '2023-08-14 23:14:56', 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (12, '日志管理', 1, 'LogManagement', 1, '/system/logd', 0, '', '{"title":"日志管理","icon":"ep:document","showParent":true}', 1, '日志管理菜单', 0, '2022-05-21 08:30:54', 1, '2023-08-14 23:14:47', 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (13, '在线用户', 1, 'OnlineUser', 2, '/system/monitor/onlineUser/index', 0, 'monitor:online:list', '{"title":"在线用户","icon":"fa-solid:users","showParent":true}', 1, '在线用户菜单', 0, '2022-05-21 08:30:54', 1, '2023-08-14 23:13:13', 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (14, '数据监控', 1, 'DataMonitor', 2, '/system/monitor/druid/index', 0, 'monitor:druid:list', '{"title":"数据监控","icon":"fa:database","showParent":true,"frameSrc":"/druid/login.html","isFrameSrcInternal":true}', 1, '数据监控菜单', 0, '2022-05-21 08:30:54', 1, '2023-08-14 23:13:25', 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (15, '服务监控', 1, 'ServerInfo', 2, '/system/monitor/server/index', 0, 'monitor:server:list', '{"title":"服务监控","icon":"fa:server","showParent":true}', 1, '服务监控菜单', 0, '2022-05-21 08:30:54', 1, '2023-08-14 23:13:34', 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (16, '缓存监控', 1, 'CacheInfo', 2, '/system/monitor/cache/index', 0, 'monitor:cache:list', '{"title":"缓存监控","icon":"ep:reading","showParent":true}', 1, '缓存监控菜单', 0, '2022-05-21 08:30:54', 1, '2023-08-14 23:12:59', 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (17, '系统接口', 1, 'SystemAPI', 3, '/tool/swagger/index', 0, 'tool:swagger:list', '{"title":"系统接口","icon":"ep:document-remove","showParent":true,"frameSrc":"/swagger-ui/index.html","isFrameSrcInternal":true}', 1, '系统接口菜单', 0, '2022-05-21 08:30:54', 1, '2023-08-14 23:14:01', 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (18, '操作日志', 1, 'OperationLog', 12, '/system/log/operationLog/index', 0, 'monitor:operlog:list', '{"title":"操作日志"}', 1, '操作日志菜单', 0, '2022-05-21 08:30:54', null, null, 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (19, '登录日志', 1, 'LoginLog', 12, '/system/log/loginLog/index', 0, 'monitor:logininfor:list', '{"title":"登录日志"}', 1, '登录日志菜单', 0, '2022-05-21 08:30:54', null, null, 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (20, '用户查询', 0, ' ', 5, '', 1, 'system:user:query', '{"title":"用户查询"}', 1, '', 0, '2022-05-21 08:30:54', null, null, 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (21, '用户新增', 0, ' ', 5, '', 1, 'system:user:add', '{"title":"用户新增"}', 1, '', 0, '2022-05-21 08:30:54', null, null, 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (22, '用户修改', 0, ' ', 5, '', 1, 'system:user:edit', '{"title":"用户修改"}', 1, '', 0, '2022-05-21 08:30:54', null, null, 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (23, '用户删除', 0, ' ', 5, '', 1, 'system:user:remove', '{"title":"用户删除"}', 1, '', 0, '2022-05-21 08:30:54', null, null, 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (24, '用户导出', 0, ' ', 5, '', 1, 'system:user:export', '{"title":"用户导出"}', 1, '', 0, '2022-05-21 08:30:54', null, null, 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (25, '用户导入', 0, ' ', 5, '', 1, 'system:user:import', '{"title":"用户导入"}', 1, '', 0, '2022-05-21 08:30:54', null, null, 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (26, '重置密码', 0, ' ', 5, '', 1, 'system:user:resetPwd', '{"title":"重置密码"}', 1, '', 0, '2022-05-21 08:30:54', null, null, 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (27, '角色查询', 0, ' ', 6, '', 1, 'system:role:query', '{"title":"角色查询"}', 1, '', 0, '2022-05-21 08:30:54', null, null, 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (28, '角色新增', 0, ' ', 6, '', 1, 'system:role:add', '{"title":"角色新增"}', 1, '', 0, '2022-05-21 08:30:54', null, null, 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (29, '角色修改', 0, ' ', 6, '', 1, 'system:role:edit', '{"title":"角色修改"}', 1, '', 0, '2022-05-21 08:30:54', null, null, 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (30, '角色删除', 0, ' ', 6, '', 1, 'system:role:remove', '{"title":"角色删除"}', 1, '', 0, '2022-05-21 08:30:54', null, null, 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (31, '角色导出', 0, ' ', 6, '', 1, 'system:role:export', '{"title":"角色导出"}', 1, '', 0, '2022-05-21 08:30:54', null, null, 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (32, '菜单查询', 0, ' ', 7, '', 1, 'system:menu:query', '{"title":"菜单查询"}', 1, '', 0, '2022-05-21 08:30:54', null, null, 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (33, '菜单新增', 0, ' ', 7, '', 1, 'system:menu:add', '{"title":"菜单新增"}', 1, '', 0, '2022-05-21 08:30:54', null, null, 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (34, '菜单修改', 0, ' ', 7, '', 1, 'system:menu:edit', '{"title":"菜单修改"}', 1, '', 0, '2022-05-21 08:30:54', null, null, 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (35, '菜单删除', 0, ' ', 7, '', 1, 'system:menu:remove', '{"title":"菜单删除"}', 1, '', 0, '2022-05-21 08:30:54', null, null, 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (36, '部门查询', 0, ' ', 8, '', 1, 'system:dept:query', '{"title":"部门查询"}', 1, '', 0, '2022-05-21 08:30:54', null, null, 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (37, '部门新增', 0, ' ', 8, '', 1, 'system:dept:add', '{"title":"部门新增"}', 1, '', 0, '2022-05-21 08:30:54', null, null, 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (38, '部门修改', 0, ' ', 8, '', 1, 'system:dept:edit', '{"title":"部门修改"}', 1, '', 0, '2022-05-21 08:30:54', null, null, 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (39, '部门删除', 0, ' ', 8, '', 1, 'system:dept:remove', '{"title":"部门删除"}', 1, '', 0, '2022-05-21 08:30:54', null, null, 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (40, '岗位查询', 0, ' ', 9, '', 1, 'system:post:query', '{"title":"岗位查询"}', 1, '', 0, '2022-05-21 08:30:54', null, null, 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (41, '岗位新增', 0, ' ', 9, '', 1, 'system:post:add', '{"title":"岗位新增"}', 1, '', 0, '2022-05-21 08:30:54', null, null, 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (42, '岗位修改', 0, ' ', 9, '', 1, 'system:post:edit', '{"title":"岗位修改"}', 1, '', 0, '2022-05-21 08:30:54', null, null, 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (43, '岗位删除', 0, ' ', 9, '', 1, 'system:post:remove', '{"title":"岗位删除"}', 1, '', 0, '2022-05-21 08:30:54', null, null, 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (44, '岗位导出', 0, ' ', 9, '', 1, 'system:post:export', '{"title":"岗位导出"}', 1, '', 0, '2022-05-21 08:30:54', null, null, 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (45, '参数查询', 0, ' ', 10, '', 1, 'system:config:query', '{"title":"参数查询"}', 1, '', 0, '2022-05-21 08:30:54', null, null, 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (46, '参数新增', 0, ' ', 10, '', 1, 'system:config:add', '{"title":"参数新增"}', 1, '', 0, '2022-05-21 08:30:54', null, null, 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (47, '参数修改', 0, ' ', 10, '', 1, 'system:config:edit', '{"title":"参数修改"}', 1, '', 0, '2022-05-21 08:30:54', null, null, 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (48, '参数删除', 0, ' ', 10, '', 1, 'system:config:remove', '{"title":"参数删除"}', 1, '', 0, '2022-05-21 08:30:54', null, null, 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (49, '参数导出', 0, ' ', 10, '', 1, 'system:config:export', '{"title":"参数导出"}', 1, '', 0, '2022-05-21 08:30:54', null, null, 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (50, '公告查询', 0, ' ', 11, '', 1, 'system:notice:query', '{"title":"公告查询"}', 1, '', 0, '2022-05-21 08:30:54', null, null, 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (51, '公告新增', 0, ' ', 11, '', 1, 'system:notice:add', '{"title":"公告新增"}', 1, '', 0, '2022-05-21 08:30:54', null, null, 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (52, '公告修改', 0, ' ', 11, '', 1, 'system:notice:edit', '{"title":"公告修改"}', 1, '', 0, '2022-05-21 08:30:54', null, null, 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (53, '公告删除', 0, ' ', 11, '', 1, 'system:notice:remove', '{"title":"公告删除"}', 1, '', 0, '2022-05-21 08:30:54', null, null, 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (54, '操作查询', 0, ' ', 18, '', 1, 'monitor:operlog:query', '{"title":"操作查询"}', 1, '', 0, '2022-05-21 08:30:54', null, null, 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (55, '操作删除', 0, ' ', 18, '', 1, 'monitor:operlog:remove', '{"title":"操作删除"}', 1, '', 0, '2022-05-21 08:30:54', null, null, 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (56, '日志导出', 0, ' ', 18, '', 1, 'monitor:operlog:export', '{"title":"日志导出"}', 1, '', 0, '2022-05-21 08:30:54', null, null, 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (57, '登录查询', 0, ' ', 19, '', 1, 'monitor:logininfor:query', '{"title":"登录查询"}', 1, '', 0, '2022-05-21 08:30:54', null, null, 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (58, '登录删除', 0, ' ', 19, '', 1, 'monitor:logininfor:remove', '{"title":"登录删除"}', 1, '', 0, '2022-05-21 08:30:54', null, null, 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (59, '日志导出', 0, ' ', 19, '', 1, 'monitor:logininfor:export', '{"title":"日志导出","rank":22}', 1, '', 0, '2022-05-21 08:30:54', 1, '2023-07-22 17:02:28', 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (60, '在线查询', 0, ' ', 13, '', 1, 'monitor:online:query', '{"title":"在线查询"}', 1, '', 0, '2022-05-21 08:30:54', null, null, 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (61, '批量强退', 0, ' ', 13, '', 1, 'monitor:online:batchLogout', '{"title":"批量强退"}', 1, '', 0, '2022-05-21 08:30:54', null, null, 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (62, '单条强退', 0, ' ', 13, '', 1, 'monitor:online:forceLogout', '{"title":"单条强退"}', 1, '', 0, '2022-05-21 08:30:54', null, null, 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (63, 'AgileBoot Github地址', 4, 'https://github.com/valarchie/AgileBoot-Back-End', 0, '/external', 0, '', '{"title":"AgileBoot Github地址","icon":"fa-solid:external-link-alt","showParent":true,"rank":9}', 1, 'Agileboot github地址', 0, '2022-05-21 08:30:54', 1, '2023-08-14 23:12:13', 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (64, '首页', 2, '', 0, '/global', 0, '121212', '{"title":"首页","showParent":true,"rank":3}', 1, '', 1, '2023-07-24 22:36:03', 1, '2023-07-24 22:38:37', 1);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (65, '个人中心', 1, 'PersonalCenter', 2053, '/system/user/profile', 0, '434sdf', '{"title":"个人中心","showParent":true,"rank":3}', 1, '', 1, '2023-07-24 22:36:55', null, null, 1);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (4, '用户管理', 1, 'SystemUser', 1, '/system/user/index', 0, 'system:user:list', '{"title":"用户管理","icon":"ep:user-filled","showParent":true}', 1, '用户管理菜单', 0, '2022-05-21 08:30:54', 1, '2023-08-14 23:16:13', 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (5, '角色管理', 1, 'SystemRole', 1, '/system/role/index', 0, 'system:role:list', '{"title":"角色管理","icon":"ep:user","showParent":true}', 1, '角色管理菜单', 0, '2022-05-21 08:30:54', 1, '2023-08-14 23:16:23', 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (6, '菜单管理', 1, 'MenuManagement', 1, '/system/menu/index', 0, 'system:menu:list', '{"title":"菜单管理","icon":"ep:menu","showParent":true}', 1, '菜单管理菜单', 0, '2022-05-21 08:30:54', 1, '2023-08-14 23:15:41', 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (7, '部门管理', 1, 'Department', 1, '/system/dept/index', 0, 'system:dept:list', '{"title":"部门管理","icon":"fa-solid:code-branch","showParent":true}', 1, '部门管理菜单', 0, '2022-05-21 08:30:54', 1, '2023-08-14 23:15:35', 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (8, '岗位管理', 1, 'Post', 1, '/system/post/index', 0, 'system:post:list', '{"title":"岗位管理","icon":"ep:postcard","showParent":true}', 1, '岗位管理菜单', 0, '2022-05-21 08:30:54', 1, '2023-08-14 23:15:11', 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (9, '参数设置', 1, 'Config', 1, '/system/config/index', 0, 'system:config:list', '{"title":"参数设置","icon":"ep:setting","showParent":true}', 1, '参数设置菜单', 0, '2022-05-21 08:30:54', 1, '2023-08-14 23:15:03', 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (10, '通知公告', 1, 'SystemNotice', 1, '/system/notice/index', 0, 'system:notice:list', '{"title":"通知公告","icon":"ep:notification","showParent":true}', 1, '通知公告菜单', 0, '2022-05-21 08:30:54', 1, '2023-08-14 23:14:56', 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (11, '日志管理', 1, 'LogManagement', 1, '/system/logd', 0, '', '{"title":"日志管理","icon":"ep:document","showParent":true}', 1, '日志管理菜单', 0, '2022-05-21 08:30:54', 1, '2023-08-14 23:14:47', 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (12, '在线用户', 1, 'OnlineUser', 2, '/system/monitor/onlineUser/index', 0, 'monitor:online:list', '{"title":"在线用户","icon":"fa-solid:users","showParent":true}', 1, '在线用户菜单', 0, '2022-05-21 08:30:54', 1, '2023-08-14 23:13:13', 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (13, '数据监控', 1, 'DataMonitor', 2, '/system/monitor/druid/index', 0, 'monitor:druid:list', '{"title":"数据监控","icon":"fa:database","showParent":true,"frameSrc":"/druid/login.html","isFrameSrcInternal":true}', 1, '数据监控菜单', 0, '2022-05-21 08:30:54', 1, '2023-08-14 23:13:25', 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (14, '服务监控', 1, 'ServerInfo', 2, '/system/monitor/server/index', 0, 'monitor:server:list', '{"title":"服务监控","icon":"fa:server","showParent":true}', 1, '服务监控菜单', 0, '2022-05-21 08:30:54', 1, '2023-08-14 23:13:34', 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (15, '缓存监控', 1, 'CacheInfo', 2, '/system/monitor/cache/index', 0, 'monitor:cache:list', '{"title":"缓存监控","icon":"ep:reading","showParent":true}', 1, '缓存监控菜单', 0, '2022-05-21 08:30:54', 1, '2023-08-14 23:12:59', 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (16, '系统接口', 1, 'SystemAPI', 3, '/tool/swagger/index', 0, 'tool:swagger:list', '{"title":"系统接口","icon":"ep:document-remove","showParent":true,"frameSrc":"/swagger-ui/index.html","isFrameSrcInternal":true}', 1, '系统接口菜单', 0, '2022-05-21 08:30:54', 1, '2023-08-14 23:14:01', 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (17, '操作日志', 1, 'OperationLog', 12, '/system/log/operationLog/index', 0, 'monitor:operlog:list', '{"title":"操作日志"}', 1, '操作日志菜单', 0, '2022-05-21 08:30:54', null, null, 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (18, '登录日志', 1, 'LoginLog', 12, '/system/log/loginLog/index', 0, 'monitor:logininfor:list', '{"title":"登录日志"}', 1, '登录日志菜单', 0, '2022-05-21 08:30:54', null, null, 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (19, '用户查询', 0, ' ', 5, '', 1, 'system:user:query', '{"title":"用户查询"}', 1, '', 0, '2022-05-21 08:30:54', null, null, 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (20, '用户新增', 0, ' ', 5, '', 1, 'system:user:add', '{"title":"用户新增"}', 1, '', 0, '2022-05-21 08:30:54', null, null, 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (21, '用户修改', 0, ' ', 5, '', 1, 'system:user:edit', '{"title":"用户修改"}', 1, '', 0, '2022-05-21 08:30:54', null, null, 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (22, '用户删除', 0, ' ', 5, '', 1, 'system:user:remove', '{"title":"用户删除"}', 1, '', 0, '2022-05-21 08:30:54', null, null, 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (23, '用户导出', 0, ' ', 5, '', 1, 'system:user:export', '{"title":"用户导出"}', 1, '', 0, '2022-05-21 08:30:54', null, null, 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (24, '用户导入', 0, ' ', 5, '', 1, 'system:user:import', '{"title":"用户导入"}', 1, '', 0, '2022-05-21 08:30:54', null, null, 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (25, '重置密码', 0, ' ', 5, '', 1, 'system:user:resetPwd', '{"title":"重置密码"}', 1, '', 0, '2022-05-21 08:30:54', null, null, 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (26, '角色查询', 0, ' ', 6, '', 1, 'system:role:query', '{"title":"角色查询"}', 1, '', 0, '2022-05-21 08:30:54', null, null, 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (27, '角色新增', 0, ' ', 6, '', 1, 'system:role:add', '{"title":"角色新增"}', 1, '', 0, '2022-05-21 08:30:54', null, null, 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (28, '角色修改', 0, ' ', 6, '', 1, 'system:role:edit', '{"title":"角色修改"}', 1, '', 0, '2022-05-21 08:30:54', null, null, 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (29, '角色删除', 0, ' ', 6, '', 1, 'system:role:remove', '{"title":"角色删除"}', 1, '', 0, '2022-05-21 08:30:54', null, null, 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (30, '角色导出', 0, ' ', 6, '', 1, 'system:role:export', '{"title":"角色导出"}', 1, '', 0, '2022-05-21 08:30:54', null, null, 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (31, '菜单查询', 0, ' ', 7, '', 1, 'system:menu:query', '{"title":"菜单查询"}', 1, '', 0, '2022-05-21 08:30:54', null, null, 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (32, '菜单新增', 0, ' ', 7, '', 1, 'system:menu:add', '{"title":"菜单新增"}', 1, '', 0, '2022-05-21 08:30:54', null, null, 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (33, '菜单修改', 0, ' ', 7, '', 1, 'system:menu:edit', '{"title":"菜单修改"}', 1, '', 0, '2022-05-21 08:30:54', null, null, 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (34, '菜单删除', 0, ' ', 7, '', 1, 'system:menu:remove', '{"title":"菜单删除"}', 1, '', 0, '2022-05-21 08:30:54', null, null, 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (35, '部门查询', 0, ' ', 8, '', 1, 'system:dept:query', '{"title":"部门查询"}', 1, '', 0, '2022-05-21 08:30:54', null, null, 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (36, '部门新增', 0, ' ', 8, '', 1, 'system:dept:add', '{"title":"部门新增"}', 1, '', 0, '2022-05-21 08:30:54', null, null, 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (37, '部门修改', 0, ' ', 8, '', 1, 'system:dept:edit', '{"title":"部门修改"}', 1, '', 0, '2022-05-21 08:30:54', null, null, 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (38, '部门删除', 0, ' ', 8, '', 1, 'system:dept:remove', '{"title":"部门删除"}', 1, '', 0, '2022-05-21 08:30:54', null, null, 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (39, '岗位查询', 0, ' ', 9, '', 1, 'system:post:query', '{"title":"岗位查询"}', 1, '', 0, '2022-05-21 08:30:54', null, null, 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (40, '岗位新增', 0, ' ', 9, '', 1, 'system:post:add', '{"title":"岗位新增"}', 1, '', 0, '2022-05-21 08:30:54', null, null, 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (41, '岗位修改', 0, ' ', 9, '', 1, 'system:post:edit', '{"title":"岗位修改"}', 1, '', 0, '2022-05-21 08:30:54', null, null, 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (42, '岗位删除', 0, ' ', 9, '', 1, 'system:post:remove', '{"title":"岗位删除"}', 1, '', 0, '2022-05-21 08:30:54', null, null, 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (43, '岗位导出', 0, ' ', 9, '', 1, 'system:post:export', '{"title":"岗位导出"}', 1, '', 0, '2022-05-21 08:30:54', null, null, 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (44, '参数查询', 0, ' ', 10, '', 1, 'system:config:query', '{"title":"参数查询"}', 1, '', 0, '2022-05-21 08:30:54', null, null, 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (45, '参数新增', 0, ' ', 10, '', 1, 'system:config:add', '{"title":"参数新增"}', 1, '', 0, '2022-05-21 08:30:54', null, null, 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (46, '参数修改', 0, ' ', 10, '', 1, 'system:config:edit', '{"title":"参数修改"}', 1, '', 0, '2022-05-21 08:30:54', null, null, 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (47, '参数删除', 0, ' ', 10, '', 1, 'system:config:remove', '{"title":"参数删除"}', 1, '', 0, '2022-05-21 08:30:54', null, null, 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (48, '参数导出', 0, ' ', 10, '', 1, 'system:config:export', '{"title":"参数导出"}', 1, '', 0, '2022-05-21 08:30:54', null, null, 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (49, '公告查询', 0, ' ', 11, '', 1, 'system:notice:query', '{"title":"公告查询"}', 1, '', 0, '2022-05-21 08:30:54', null, null, 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (50, '公告新增', 0, ' ', 11, '', 1, 'system:notice:add', '{"title":"公告新增"}', 1, '', 0, '2022-05-21 08:30:54', null, null, 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (51, '公告修改', 0, ' ', 11, '', 1, 'system:notice:edit', '{"title":"公告修改"}', 1, '', 0, '2022-05-21 08:30:54', null, null, 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (52, '公告删除', 0, ' ', 11, '', 1, 'system:notice:remove', '{"title":"公告删除"}', 1, '', 0, '2022-05-21 08:30:54', null, null, 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (53, '操作查询', 0, ' ', 18, '', 1, 'monitor:operlog:query', '{"title":"操作查询"}', 1, '', 0, '2022-05-21 08:30:54', null, null, 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (54, '操作删除', 0, ' ', 18, '', 1, 'monitor:operlog:remove', '{"title":"操作删除"}', 1, '', 0, '2022-05-21 08:30:54', null, null, 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (55, '日志导出', 0, ' ', 18, '', 1, 'monitor:operlog:export', '{"title":"日志导出"}', 1, '', 0, '2022-05-21 08:30:54', null, null, 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (56, '登录查询', 0, ' ', 19, '', 1, 'monitor:logininfor:query', '{"title":"登录查询"}', 1, '', 0, '2022-05-21 08:30:54', null, null, 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (57, '登录删除', 0, ' ', 19, '', 1, 'monitor:logininfor:remove', '{"title":"登录删除"}', 1, '', 0, '2022-05-21 08:30:54', null, null, 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (58, '日志导出', 0, ' ', 19, '', 1, 'monitor:logininfor:export', '{"title":"日志导出","rank":22}', 1, '', 0, '2022-05-21 08:30:54', 1, '2023-07-22 17:02:28', 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (59, '在线查询', 0, ' ', 13, '', 1, 'monitor:online:query', '{"title":"在线查询"}', 1, '', 0, '2022-05-21 08:30:54', null, null, 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (60, '批量强退', 0, ' ', 13, '', 1, 'monitor:online:batchLogout', '{"title":"批量强退"}', 1, '', 0, '2022-05-21 08:30:54', null, null, 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (61, '单条强退', 0, ' ', 13, '', 1, 'monitor:online:forceLogout', '{"title":"单条强退"}', 1, '', 0, '2022-05-21 08:30:54', null, null, 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (62, '首页', 2, '', 0, '/global', 0, '121212', '{"title":"首页","showParent":true,"rank":3}', 1, '', 1, '2023-07-24 22:36:03', 1, '2023-07-24 22:38:37', 1);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (63, '个人中心', 1, 'PersonalCenter', 2053, '/system/user/profile', 0, '434sdf', '{"title":"个人中心","showParent":true,"rank":3}', 1, '', 1, '2023-07-24 22:36:55', null, null, 1);
|
||||
|
||||
create table sys_notice
|
||||
(
|
||||
@@ -357,6 +360,123 @@ create table sys_user
|
||||
comment '用户信息表';
|
||||
|
||||
INSERT INTO sys_user (user_id, post_id, role_id, dept_id, username, nickname, user_type, email, phone_number, sex, avatar, password, status, login_ip, login_date, is_admin, creator_id, create_time, updater_id, update_time, remark, deleted) VALUES (1, 1, 1, 4, 'admin', 'valarchie1', 0, 'agileboot@163.com', '15888888883', 0, '/profile/avatar/20230725164110_blob_6b7a989b1cdd4dd396665d2cfd2addc5.png', '$2a$10$o55UFZAtyWnDpRV6dvQe8.c/MjlFacC49ASj2usNXm9BY74SYI/uG', 1, '127.0.0.1', '2023-08-14 23:07:03', 1, null, '2022-05-21 08:30:54', 1, '2023-08-14 23:07:03', '管理员', 0);
|
||||
INSERT INTO sys_user (user_id, post_id, role_id, dept_id, username, nickname, user_type, email, phone_number, sex, avatar, password, status, login_ip, login_date, is_admin, creator_id, create_time, updater_id, update_time, remark, deleted) VALUES (2, 2, 2, 5, 'ag1', 'valarchie2', 0, 'agileboot1@qq.com', '15666666666', 1, '/profile/avatar/20230725114818_avatar_b5bf400732bb43369b4df58802049b22.png', '$2a$10$7JB720yubVSZvUI0rEqK/.VqGOZTH.ulu33dHOiBE8ByOhJIrdAu2', 1, '127.0.0.1', '2022-05-21 08:30:54', 0, null, '2022-05-21 08:30:54', null, null, '测试员1', 0);
|
||||
INSERT INTO sys_user (user_id, post_id, role_id, dept_id, username, nickname, user_type, email, phone_number, sex, avatar, password, status, login_ip, login_date, is_admin, creator_id, create_time, updater_id, update_time, remark, deleted) VALUES (3, 2, 0, 5, 'ag2', 'valarchie3', 0, 'agileboot2@qq.com', '15666666667', 1, '/profile/avatar/20230725114818_avatar_b5bf400732bb43369b4df58802049b22.png', '$2a$10$7JB720yubVSZvUI0rEqK/.VqGOZTH.ulu33dHOiBE8ByOhJIrdAu2', 1, '127.0.0.1', '2022-05-21 08:30:54', 0, null, '2022-05-21 08:30:54', null, null, '测试员2', 0);
|
||||
|
||||
create table collaboration_record
|
||||
(
|
||||
record_id bigint auto_increment comment '合作记录ID'
|
||||
primary key,
|
||||
brand varchar(100) not null comment '品牌',
|
||||
goods varchar(100) not null comment '物品',
|
||||
cooperation_platform varchar(50) null comment '合作平台',
|
||||
image_return_num int default 1 not null comment '返图数量',
|
||||
retained_method varchar(30) default '寄拍' not null comment '留存方式',
|
||||
cooperated_method varchar(30) default '水下' not null comment '合作方式',
|
||||
purchase_method varchar(30) default '拍单' not null comment '购入方式',
|
||||
purchase_price decimal(10, 2) null comment '购入金额',
|
||||
purchase_date date null comment '购入日期',
|
||||
purchase_platform varchar(30) null comment '购入平台',
|
||||
deadline date not null comment '预完成日期',
|
||||
remuneration decimal(10, 2) null comment '稿费',
|
||||
complete_date date null comment '完成日期',
|
||||
requirements varchar(1000) null comment '拍摄要求',
|
||||
remark varchar(1000) null comment '备注',
|
||||
creator_id bigint null comment '创建者ID',
|
||||
create_time datetime null comment '创建时间',
|
||||
updater_id bigint null comment '更新者ID',
|
||||
update_time datetime null comment '更新时间',
|
||||
deleted tinyint(1) default 0 not null comment '逻辑删除',
|
||||
index idx_collaboration_record_platform (cooperation_platform),
|
||||
index idx_collaboration_record_deadline (deadline),
|
||||
index idx_collaboration_record_purchase_date (purchase_date)
|
||||
)
|
||||
comment '合作记录表';
|
||||
|
||||
create table collaboration_task
|
||||
(
|
||||
task_id bigint auto_increment comment '笔记任务ID'
|
||||
primary key,
|
||||
record_id bigint not null comment '合作记录ID',
|
||||
release_date date null comment '发布日期',
|
||||
sort_order int default 0 not null comment '排序',
|
||||
creator_id bigint null comment '创建者ID',
|
||||
create_time datetime null comment '创建时间',
|
||||
updater_id bigint null comment '更新者ID',
|
||||
update_time datetime null comment '更新时间',
|
||||
deleted tinyint(1) default 0 not null comment '逻辑删除',
|
||||
index idx_collaboration_task_record_id (record_id)
|
||||
)
|
||||
comment '合作笔记任务表';
|
||||
|
||||
create table collaboration_expenditure
|
||||
(
|
||||
expenditure_id bigint auto_increment comment '支出ID'
|
||||
primary key,
|
||||
record_id bigint not null comment '合作记录ID',
|
||||
spend_date date null comment '支出日期',
|
||||
amount decimal(10, 2) null comment '支出金额',
|
||||
purpose varchar(30) null comment '支出用途',
|
||||
creator_id bigint null comment '创建者ID',
|
||||
create_time datetime null comment '创建时间',
|
||||
updater_id bigint null comment '更新者ID',
|
||||
update_time datetime null comment '更新时间',
|
||||
deleted tinyint(1) default 0 not null comment '逻辑删除',
|
||||
index idx_collaboration_expenditure_record_id (record_id),
|
||||
index idx_collaboration_expenditure_spend_date (spend_date)
|
||||
)
|
||||
comment '合作支出表';
|
||||
|
||||
create table collaboration_settlement
|
||||
(
|
||||
settlement_id bigint auto_increment comment '结款ID'
|
||||
primary key,
|
||||
record_id bigint not null comment '合作记录ID',
|
||||
settle_date date null comment '结款日期',
|
||||
method varchar(30) null comment '结款方式',
|
||||
income decimal(10, 2) null comment '结款金额',
|
||||
purpose varchar(30) null comment '结款用途',
|
||||
creator_id bigint null comment '创建者ID',
|
||||
create_time datetime null comment '创建时间',
|
||||
updater_id bigint null comment '更新者ID',
|
||||
update_time datetime null comment '更新时间',
|
||||
deleted tinyint(1) default 0 not null comment '逻辑删除',
|
||||
index idx_collaboration_settlement_record_id (record_id),
|
||||
index idx_collaboration_settlement_date (settle_date),
|
||||
index idx_collaboration_settlement_purpose (purpose)
|
||||
)
|
||||
comment '合作结款表';
|
||||
|
||||
create table collaboration_file
|
||||
(
|
||||
file_id bigint auto_increment comment '文件ID'
|
||||
primary key,
|
||||
record_id bigint not null comment '合作记录ID',
|
||||
file_type varchar(30) not null comment '文件类型:GOODS_IMAGE/ATTACHMENT',
|
||||
url varchar(500) not null comment '访问地址',
|
||||
file_name varchar(300) null comment '服务端相对路径',
|
||||
new_file_name varchar(200) null comment '服务端新文件名',
|
||||
original_filename varchar(300) null comment '原始文件名',
|
||||
sort_order int default 0 not null comment '排序',
|
||||
creator_id bigint null comment '创建者ID',
|
||||
create_time datetime null comment '创建时间',
|
||||
updater_id bigint null comment '更新者ID',
|
||||
update_time datetime null comment '更新时间',
|
||||
deleted tinyint(1) default 0 not null comment '逻辑删除',
|
||||
index idx_collaboration_file_record_id (record_id),
|
||||
index idx_collaboration_file_type (file_type)
|
||||
)
|
||||
comment '合作文件表';
|
||||
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (3000, '合作管理', 2, '', 0, '/collaboration', 0, '', '{"title":"合作管理","icon":"ep:connection","showParent":true,"rank":4}', 1, '合作管理目录', 0, now(), null, null, 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (3001, '合作记录', 1, 'CollaborationRecord', 3000, '/collaboration/record/index', 0, 'collaboration:record:list', '{"title":"合作记录","icon":"ep:notebook","showParent":true}', 1, '合作记录菜单', 0, now(), null, null, 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (3002, '月度统计', 1, 'CollaborationStatistics', 3000, '/collaboration/statistics/index', 0, 'collaboration:record:statistics', '{"title":"月度统计","icon":"ep:data-analysis","showParent":true}', 1, '月度统计菜单', 0, now(), null, null, 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (3003, '合作查询', 0, ' ', 3001, '', 1, 'collaboration:record:query', '{"title":"合作查询"}', 1, '', 0, now(), null, null, 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (3004, '合作新增', 0, ' ', 3001, '', 1, 'collaboration:record:add', '{"title":"合作新增"}', 1, '', 0, now(), null, null, 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (3005, '合作修改', 0, ' ', 3001, '', 1, 'collaboration:record:edit', '{"title":"合作修改"}', 1, '', 0, now(), null, null, 0);
|
||||
INSERT INTO sys_menu (menu_id, menu_name, menu_type, router_name, parent_id, path, is_button, permission, meta_info, status, remark, creator_id, create_time, updater_id, update_time, deleted) VALUES (3006, '合作删除', 0, ' ', 3001, '', 1, 'collaboration:record:remove', '{"title":"合作删除"}', 1, '', 0, now(), null, null, 0);
|
||||
INSERT INTO sys_role_menu (role_id, menu_id) VALUES (2, 3000);
|
||||
INSERT INTO sys_role_menu (role_id, menu_id) VALUES (2, 3001);
|
||||
INSERT INTO sys_role_menu (role_id, menu_id) VALUES (2, 3002);
|
||||
INSERT INTO sys_role_menu (role_id, menu_id) VALUES (2, 3003);
|
||||
INSERT INTO sys_role_menu (role_id, menu_id) VALUES (2, 3004);
|
||||
INSERT INTO sys_role_menu (role_id, menu_id) VALUES (2, 3005);
|
||||
INSERT INTO sys_role_menu (role_id, menu_id) VALUES (2, 3006);
|
||||
@@ -1,428 +0,0 @@
|
||||
/*
|
||||
Navicat MySQL Data Transfer
|
||||
|
||||
Source Server : Local-Mysql
|
||||
Source Server Version : 80029
|
||||
Source Host : localhost:33066
|
||||
Source Database : agileboot
|
||||
|
||||
Target Server Type : MYSQL
|
||||
Target Server Version : 80029
|
||||
File Encoding : 65001
|
||||
|
||||
Date: 2022-10-07 16:05:40
|
||||
*/
|
||||
|
||||
SET FOREIGN_KEY_CHECKS=0;
|
||||
|
||||
-- ----------------------------
|
||||
-- Table structure for sys_config
|
||||
-- ----------------------------
|
||||
DROP TABLE IF EXISTS `sys_config`;
|
||||
CREATE TABLE `sys_config` (
|
||||
`config_id` int NOT NULL AUTO_INCREMENT COMMENT '参数主键',
|
||||
`config_name` varchar(128) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' COMMENT '配置名称',
|
||||
`config_key` varchar(128) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' COMMENT '配置键名',
|
||||
`config_options` varchar(1024) NOT NULL DEFAULT '' COMMENT '可选的选项',
|
||||
`config_value` varchar(256) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' COMMENT '配置值',
|
||||
`is_allow_change` tinyint(1) NOT NULL COMMENT '是否允许修改',
|
||||
`creator_id` bigint DEFAULT NULL COMMENT '创建者ID',
|
||||
`updater_id` bigint DEFAULT NULL COMMENT '更新者ID',
|
||||
`update_time` datetime DEFAULT NULL COMMENT '更新时间',
|
||||
`create_time` datetime DEFAULT NULL COMMENT '创建时间',
|
||||
`remark` varchar(128) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL COMMENT '备注',
|
||||
`deleted` tinyint(1) NOT NULL DEFAULT '0' COMMENT '逻辑删除',
|
||||
PRIMARY KEY (`config_id`),
|
||||
UNIQUE KEY `config_key_uniq_idx` (`config_key`) USING BTREE
|
||||
) ENGINE=InnoDB AUTO_INCREMENT=100 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci COMMENT='参数配置表';
|
||||
|
||||
-- ----------------------------
|
||||
-- Records of sys_config
|
||||
-- ----------------------------
|
||||
INSERT INTO `sys_config` VALUES ('1', '主框架页-默认皮肤样式名称', 'sys.index.skinName', '["skin-blue","skin-green","skin-purple","skin-red","skin-yellow"]', 'skin-blue', '1', null, null, '2022-08-28 22:12:19', '2022-05-21 08:30:55', '蓝色 skin-blue、绿色 skin-green、紫色 skin-purple、红色 skin-red、黄色 skin-yellow', '0');
|
||||
INSERT INTO `sys_config` VALUES ('2', '用户管理-账号初始密码', 'sys.user.initPassword', '', '1234567', '1', null, null, '2022-08-28 21:54:19', '2022-05-21 08:30:55', '初始化密码 123456', '0');
|
||||
INSERT INTO `sys_config` VALUES ('3', '主框架页-侧边栏主题', 'sys.index.sideTheme', '["theme-dark","theme-light"]', 'theme-dark', '1', null, null, '2022-08-28 22:12:15', '2022-08-20 08:30:55', '深色主题theme-dark,浅色主题theme-light', '0');
|
||||
INSERT INTO `sys_config` VALUES ('4', '账号自助-验证码开关', 'sys.account.captchaOnOff', '["true","false"]', 'false', '0', null, null, '2022-08-28 22:03:37', '2022-05-21 08:30:55', '是否开启验证码功能(true开启,false关闭)', '0');
|
||||
INSERT INTO `sys_config` VALUES ('5', '账号自助-是否开启用户注册功能', 'sys.account.registerUser', '["true","false"]', 'true', '0', null, '1', '2022-10-05 22:18:57', '2022-05-21 08:30:55', '是否开启注册用户功能(true开启,false关闭)', '0');
|
||||
|
||||
|
||||
-- ----------------------------
|
||||
-- Table structure for sys_dept
|
||||
-- ----------------------------
|
||||
DROP TABLE IF EXISTS `sys_dept`;
|
||||
CREATE TABLE `sys_dept` (
|
||||
`dept_id` bigint NOT NULL AUTO_INCREMENT COMMENT '部门id',
|
||||
`parent_id` bigint NOT NULL DEFAULT '0' COMMENT '父部门id',
|
||||
`ancestors` text CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL COMMENT '祖级列表',
|
||||
`dept_name` varchar(64) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' COMMENT '部门名称',
|
||||
`order_num` int NOT NULL DEFAULT '0' COMMENT '显示顺序',
|
||||
`leader_id` bigint DEFAULT NULL,
|
||||
`leader_name` varchar(64) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL COMMENT '负责人',
|
||||
`phone` varchar(16) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL COMMENT '联系电话',
|
||||
`email` varchar(128) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL COMMENT '邮箱',
|
||||
`status` smallint NOT NULL DEFAULT '0' COMMENT '部门状态(0停用 1启用)',
|
||||
`creator_id` bigint DEFAULT NULL COMMENT '创建者ID',
|
||||
`create_time` datetime DEFAULT NULL COMMENT '创建时间',
|
||||
`updater_id` bigint DEFAULT NULL COMMENT '更新者ID',
|
||||
`update_time` datetime DEFAULT NULL COMMENT '更新时间',
|
||||
`deleted` tinyint(1) NOT NULL DEFAULT '0' COMMENT '逻辑删除',
|
||||
PRIMARY KEY (`dept_id`)
|
||||
) ENGINE=InnoDB AUTO_INCREMENT=203 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci COMMENT='部门表';
|
||||
|
||||
-- ----------------------------
|
||||
-- Records of sys_dept
|
||||
-- ----------------------------
|
||||
INSERT INTO `sys_dept` VALUES ('1', '0', '0', 'AgileBoot科技', '0', null, 'valarchie', '15888888888', 'valarchie@163.com', '1', null, '2022-05-21 08:30:54', null, null, '0');
|
||||
INSERT INTO `sys_dept` VALUES ('2', '1', '0,1', '深圳总公司', '1', null, 'valarchie', '15888888888', 'valarchie@163.com', '1', null, '2022-05-21 08:30:54', null, null, '0');
|
||||
INSERT INTO `sys_dept` VALUES ('3', '1', '0,1', '长沙分公司', '2', null, 'valarchie', '15888888888', 'valarchie@163.com', '1', null, '2022-05-21 08:30:54', null, null, '0');
|
||||
INSERT INTO `sys_dept` VALUES ('4', '2', '0,1,2', '研发部门', '1', null, 'valarchie', '15888888888', 'valarchie@163.com', '1', null, '2022-05-21 08:30:54', null, null, '0');
|
||||
INSERT INTO `sys_dept` VALUES ('5', '2', '0,1,2', '市场部门', '2', null, 'valarchie', '15888888888', 'valarchie@163.com', '1', null, '2022-05-21 08:30:54', null, null, '0');
|
||||
INSERT INTO `sys_dept` VALUES ('6', '2', '0,1,2', '测试部门', '3', null, 'valarchie', '15888888888', 'valarchie@163.com', '1', null, '2022-05-21 08:30:54', null, null, '0');
|
||||
INSERT INTO `sys_dept` VALUES ('7', '2', '0,1,2', '财务部门', '4', null, 'valarchie', '15888888888', 'valarchie@163.com', '1', null, '2022-05-21 08:30:54', null, null, '0');
|
||||
INSERT INTO `sys_dept` VALUES ('8', '2', '0,1,2', '运维部门', '5', null, 'valarchie', '15888888888', 'valarchie@163.com', '1', null, '2022-05-21 08:30:54', null, null, '0');
|
||||
INSERT INTO `sys_dept` VALUES ('9', '3', '0,1,3', '市场部门', '1', null, 'valarchie', '15888888888', 'valarchie@163.com', '1', null, '2022-05-21 08:30:54', null, null, '0');
|
||||
INSERT INTO `sys_dept` VALUES ('10', '3', '0,1,3', '财务部门', '2', null, 'valarchie', '15888888888', 'valarchie@163.com', '0', null, '2022-05-21 08:30:54', null, null, '0');
|
||||
|
||||
-- ----------------------------
|
||||
-- Table structure for sys_login_info
|
||||
-- ----------------------------
|
||||
DROP TABLE IF EXISTS `sys_login_info`;
|
||||
CREATE TABLE `sys_login_info` (
|
||||
`info_id` bigint NOT NULL AUTO_INCREMENT COMMENT '访问ID',
|
||||
`username` varchar(50) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' COMMENT '用户账号',
|
||||
`ip_address` varchar(128) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' COMMENT '登录IP地址',
|
||||
`login_location` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' COMMENT '登录地点',
|
||||
`browser` varchar(50) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' COMMENT '浏览器类型',
|
||||
`operation_system` varchar(50) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' COMMENT '操作系统',
|
||||
`status` smallint NOT NULL DEFAULT '0' COMMENT '登录状态(1成功 0失败)',
|
||||
`msg` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' COMMENT '提示消息',
|
||||
`login_time` datetime DEFAULT NULL COMMENT '访问时间',
|
||||
`deleted` tinyint(1) NOT NULL DEFAULT '0' COMMENT '逻辑删除',
|
||||
PRIMARY KEY (`info_id`)
|
||||
) ENGINE=InnoDB AUTO_INCREMENT=415 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci COMMENT='系统访问记录';
|
||||
|
||||
-- ----------------------------
|
||||
-- Records of sys_login_info
|
||||
-- ----------------------------
|
||||
|
||||
-- ----------------------------
|
||||
-- Table structure for sys_menu
|
||||
-- ----------------------------
|
||||
DROP TABLE IF EXISTS `sys_menu`;
|
||||
CREATE TABLE `sys_menu` (
|
||||
`menu_id` bigint NOT NULL AUTO_INCREMENT COMMENT '菜单ID',
|
||||
`menu_name` varchar(64) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL COMMENT '菜单名称',
|
||||
`parent_id` bigint NOT NULL DEFAULT '0' COMMENT '父菜单ID',
|
||||
`order_num` int NOT NULL DEFAULT '0' COMMENT '显示顺序',
|
||||
`path` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT '' COMMENT '路由地址',
|
||||
`component` varchar(255) DEFAULT NULL COMMENT '组件路径',
|
||||
`query` varchar(255) DEFAULT NULL COMMENT '路由参数',
|
||||
`is_external` tinyint(1) NOT NULL DEFAULT '1' COMMENT '是否为外链(1是 0否)',
|
||||
`is_cache` tinyint(1) NOT NULL DEFAULT '0' COMMENT '是否缓存(1缓存 0不缓存)',
|
||||
`menu_type` smallint NOT NULL DEFAULT '0' COMMENT '菜单类型(M=1目录 C=2菜单 F=3按钮)',
|
||||
`is_visible` tinyint(1) NOT NULL DEFAULT '0' COMMENT '菜单状态(1显示 0隐藏)',
|
||||
`status` smallint NOT NULL DEFAULT '0' COMMENT '菜单状态(1启用 0停用)',
|
||||
`perms` varchar(128) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL COMMENT '权限标识',
|
||||
`icon` varchar(128) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT '#' COMMENT '菜单图标',
|
||||
`creator_id` bigint DEFAULT NULL COMMENT '创建者ID',
|
||||
`create_time` datetime DEFAULT NULL COMMENT '创建时间',
|
||||
`updater_id` bigint DEFAULT NULL COMMENT '更新者ID',
|
||||
`update_time` datetime DEFAULT NULL COMMENT '更新时间',
|
||||
`remark` varchar(512) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT '' COMMENT '备注',
|
||||
`deleted` tinyint(1) NOT NULL DEFAULT '0' COMMENT '逻辑删除',
|
||||
PRIMARY KEY (`menu_id`)
|
||||
) ENGINE=InnoDB AUTO_INCREMENT=2007 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci COMMENT='菜单权限表';
|
||||
|
||||
-- ----------------------------
|
||||
-- Records of sys_menu
|
||||
-- ----------------------------
|
||||
INSERT INTO `sys_menu` VALUES ('1', '系统管理', '0', '1', 'system', null, '', '0', '1', '1', '1', '1', '', 'system', '0', '2022-05-21 08:30:54', null, null, '系统管理目录', '0');
|
||||
INSERT INTO `sys_menu` VALUES ('2', '系统监控', '0', '2', 'monitor', null, '', '0', '1', '1', '1', '1', '', 'monitor', '0', '2022-05-21 08:30:54', null, null, '系统监控目录', '0');
|
||||
INSERT INTO `sys_menu` VALUES ('3', '系统工具', '0', '3', 'tool', null, '', '0', '1', '1', '1', '1', '', 'tool', '0', '2022-05-21 08:30:54', null, null, '系统工具目录', '0');
|
||||
INSERT INTO `sys_menu` VALUES ('4', 'AgileBoot官网', '0', '4', 'https://juejin.cn/column/7159946528827080734', null, '', '1', '1', '1', '1', '1', '', 'guide', '0', '2022-05-21 08:30:54', null, null, 'Agileboot官网地址', '0');
|
||||
INSERT INTO `sys_menu` VALUES ('5', '用户管理', '1', '1', 'user', 'system/user/index', '', '0', '1', '2', '1', '1', 'system:user:list', 'user', '0', '2022-05-21 08:30:54', null, null, '用户管理菜单', '0');
|
||||
INSERT INTO `sys_menu` VALUES ('6', '角色管理', '1', '2', 'role', 'system/role/index', '', '0', '1', '2', '1', '1', 'system:role:list', 'peoples', '0', '2022-05-21 08:30:54', null, null, '角色管理菜单', '0');
|
||||
INSERT INTO `sys_menu` VALUES ('7', '菜单管理', '1', '3', 'menu', 'system/menu/index', '', '0', '1', '2', '1', '1', 'system:menu:list', 'tree-table', '0', '2022-05-21 08:30:54', null, null, '菜单管理菜单', '0');
|
||||
INSERT INTO `sys_menu` VALUES ('8', '部门管理', '1', '4', 'dept', 'system/dept/index', '', '0', '1', '2', '1', '1', 'system:dept:list', 'tree', '0', '2022-05-21 08:30:54', null, null, '部门管理菜单', '0');
|
||||
INSERT INTO `sys_menu` VALUES ('9', '岗位管理', '1', '5', 'post', 'system/post/index', '', '0', '1', '2', '1', '1', 'system:post:list', 'post', '0', '2022-05-21 08:30:54', null, null, '岗位管理菜单', '0');
|
||||
INSERT INTO `sys_menu` VALUES ('10', '参数设置', '1', '7', 'config', 'system/config/index', '', '0', '1', '2', '1', '1', 'system:config:list', 'edit', '0', '2022-05-21 08:30:54', null, null, '参数设置菜单', '0');
|
||||
INSERT INTO `sys_menu` VALUES ('11', '通知公告', '1', '8', 'notice', 'system/notice/index', '', '0', '1', '2', '1', '1', 'system:notice:list', 'message', '0', '2022-05-21 08:30:54', null, null, '通知公告菜单', '0');
|
||||
INSERT INTO `sys_menu` VALUES ('12', '日志管理', '1', '9', 'log', '', '', '0', '1', '1', '1', '1', '', 'log', '0', '2022-05-21 08:30:54', null, null, '日志管理菜单', '0');
|
||||
INSERT INTO `sys_menu` VALUES ('13', '在线用户', '2', '1', 'online', 'monitor/online/index', '', '0', '1', '2', '1', '1', 'monitor:online:list', 'online', '0', '2022-05-21 08:30:54', null, null, '在线用户菜单', '0');
|
||||
INSERT INTO `sys_menu` VALUES ('14', '数据监控', '2', '3', 'druid', 'monitor/druid/index', '', '0', '1', '2', '1', '1', 'monitor:druid:list', 'druid', '0', '2022-05-21 08:30:54', null, null, '数据监控菜单', '0');
|
||||
INSERT INTO `sys_menu` VALUES ('15', '服务监控', '2', '4', 'server', 'monitor/server/index', '', '0', '1', '2', '1', '1', 'monitor:server:list', 'server', '0', '2022-05-21 08:30:54', null, null, '服务监控菜单', '0');
|
||||
INSERT INTO `sys_menu` VALUES ('16', '缓存监控', '2', '5', 'cache', 'monitor/cache/index', '', '0', '1', '2', '1', '1', 'monitor:cache:list', 'redis', '0', '2022-05-21 08:30:54', null, null, '缓存监控菜单', '0');
|
||||
INSERT INTO `sys_menu` VALUES ('17', '系统接口', '3', '3', 'swagger', 'tool/swagger/index', '', '0', '1', '2', '1', '1', 'tool:swagger:list', 'swagger', '0', '2022-05-21 08:30:54', null, null, '系统接口菜单', '0');
|
||||
INSERT INTO `sys_menu` VALUES ('18', '操作日志', '12', '1', 'operlog', 'monitor/operlog/index', '', '0', '1', '2', '1', '1', 'monitor:operlog:list', 'form', '0', '2022-05-21 08:30:54', null, null, '操作日志菜单', '0');
|
||||
INSERT INTO `sys_menu` VALUES ('19', '登录日志', '12', '2', 'logininfor', 'monitor/logininfor/index', '', '0', '1', '2', '1', '1', 'monitor:logininfor:list', 'logininfor', '0', '2022-05-21 08:30:54', null, null, '登录日志菜单', '0');
|
||||
INSERT INTO `sys_menu` VALUES ('20', '用户查询', '5', '1', '', '', '', '0', '1', '3', '1', '1', 'system:user:query', '#', '0', '2022-05-21 08:30:54', null, null, '', '0');
|
||||
INSERT INTO `sys_menu` VALUES ('21', '用户新增', '5', '2', '', '', '', '0', '1', '3', '1', '1', 'system:user:add', '#', '0', '2022-05-21 08:30:54', null, null, '', '0');
|
||||
INSERT INTO `sys_menu` VALUES ('22', '用户修改', '5', '3', '', '', '', '0', '1', '3', '1', '1', 'system:user:edit', '#', '0', '2022-05-21 08:30:54', null, null, '', '0');
|
||||
INSERT INTO `sys_menu` VALUES ('23', '用户删除', '5', '4', '', '', '', '0', '1', '3', '1', '1', 'system:user:remove', '#', '0', '2022-05-21 08:30:54', null, null, '', '0');
|
||||
INSERT INTO `sys_menu` VALUES ('24', '用户导出', '5', '5', '', '', '', '0', '1', '3', '1', '1', 'system:user:export', '#', '0', '2022-05-21 08:30:54', null, null, '', '0');
|
||||
INSERT INTO `sys_menu` VALUES ('25', '用户导入', '5', '6', '', '', '', '0', '1', '3', '1', '1', 'system:user:import', '#', '0', '2022-05-21 08:30:54', null, null, '', '0');
|
||||
INSERT INTO `sys_menu` VALUES ('26', '重置密码', '5', '7', '', '', '', '0', '1', '3', '1', '1', 'system:user:resetPwd', '#', '0', '2022-05-21 08:30:54', null, null, '', '0');
|
||||
INSERT INTO `sys_menu` VALUES ('27', '角色查询', '6', '1', '', '', '', '0', '1', '3', '1', '1', 'system:role:query', '#', '0', '2022-05-21 08:30:54', null, null, '', '0');
|
||||
INSERT INTO `sys_menu` VALUES ('28', '角色新增', '6', '2', '', '', '', '0', '1', '3', '1', '1', 'system:role:add', '#', '0', '2022-05-21 08:30:54', null, null, '', '0');
|
||||
INSERT INTO `sys_menu` VALUES ('29', '角色修改', '6', '3', '', '', '', '0', '1', '3', '1', '1', 'system:role:edit', '#', '0', '2022-05-21 08:30:54', null, null, '', '0');
|
||||
INSERT INTO `sys_menu` VALUES ('30', '角色删除', '6', '4', '', '', '', '0', '1', '3', '1', '1', 'system:role:remove', '#', '0', '2022-05-21 08:30:54', null, null, '', '0');
|
||||
INSERT INTO `sys_menu` VALUES ('31', '角色导出', '6', '5', '', '', '', '0', '1', '3', '1', '1', 'system:role:export', '#', '0', '2022-05-21 08:30:54', null, null, '', '0');
|
||||
INSERT INTO `sys_menu` VALUES ('32', '菜单查询', '7', '1', '', '', '', '0', '1', '3', '1', '1', 'system:menu:query', '#', '0', '2022-05-21 08:30:54', null, null, '', '0');
|
||||
INSERT INTO `sys_menu` VALUES ('33', '菜单新增', '7', '2', '', '', '', '0', '1', '3', '1', '1', 'system:menu:add', '#', '0', '2022-05-21 08:30:54', null, null, '', '0');
|
||||
INSERT INTO `sys_menu` VALUES ('34', '菜单修改', '7', '3', '', '', '', '0', '1', '3', '1', '1', 'system:menu:edit', '#', '0', '2022-05-21 08:30:54', null, null, '', '0');
|
||||
INSERT INTO `sys_menu` VALUES ('35', '菜单删除', '7', '4', '', '', '', '0', '1', '3', '1', '1', 'system:menu:remove', '#', '0', '2022-05-21 08:30:54', null, null, '', '0');
|
||||
INSERT INTO `sys_menu` VALUES ('36', '部门查询', '8', '1', '', '', '', '0', '1', '3', '1', '1', 'system:dept:query', '#', '0', '2022-05-21 08:30:54', null, null, '', '0');
|
||||
INSERT INTO `sys_menu` VALUES ('37', '部门新增', '8', '2', '', '', '', '0', '1', '3', '1', '1', 'system:dept:add', '#', '0', '2022-05-21 08:30:54', null, null, '', '0');
|
||||
INSERT INTO `sys_menu` VALUES ('38', '部门修改', '8', '3', '', '', '', '0', '1', '3', '1', '1', 'system:dept:edit', '#', '0', '2022-05-21 08:30:54', null, null, '', '0');
|
||||
INSERT INTO `sys_menu` VALUES ('39', '部门删除', '8', '4', '', '', '', '0', '1', '3', '1', '1', 'system:dept:remove', '#', '0', '2022-05-21 08:30:54', null, null, '', '0');
|
||||
INSERT INTO `sys_menu` VALUES ('40', '岗位查询', '9', '1', '', '', '', '0', '1', '3', '1', '1', 'system:post:query', '#', '0', '2022-05-21 08:30:54', null, null, '', '0');
|
||||
INSERT INTO `sys_menu` VALUES ('41', '岗位新增', '9', '2', '', '', '', '0', '1', '3', '1', '1', 'system:post:add', '#', '0', '2022-05-21 08:30:54', null, null, '', '0');
|
||||
INSERT INTO `sys_menu` VALUES ('42', '岗位修改', '9', '3', '', '', '', '0', '1', '3', '1', '1', 'system:post:edit', '#', '0', '2022-05-21 08:30:54', null, null, '', '0');
|
||||
INSERT INTO `sys_menu` VALUES ('43', '岗位删除', '9', '4', '', '', '', '0', '1', '3', '1', '1', 'system:post:remove', '#', '0', '2022-05-21 08:30:54', null, null, '', '0');
|
||||
INSERT INTO `sys_menu` VALUES ('44', '岗位导出', '9', '5', '', '', '', '0', '1', '3', '1', '1', 'system:post:export', '#', '0', '2022-05-21 08:30:54', null, null, '', '0');
|
||||
INSERT INTO `sys_menu` VALUES ('45', '参数查询', '10', '1', '#', '', '', '0', '1', '3', '1', '1', 'system:config:query', '#', '0', '2022-05-21 08:30:54', null, null, '', '0');
|
||||
INSERT INTO `sys_menu` VALUES ('46', '参数新增', '10', '2', '#', '', '', '0', '1', '3', '1', '1', 'system:config:add', '#', '0', '2022-05-21 08:30:54', null, null, '', '0');
|
||||
INSERT INTO `sys_menu` VALUES ('47', '参数修改', '10', '3', '#', '', '', '0', '1', '3', '1', '1', 'system:config:edit', '#', '0', '2022-05-21 08:30:54', null, null, '', '0');
|
||||
INSERT INTO `sys_menu` VALUES ('48', '参数删除', '10', '4', '#', '', '', '0', '1', '3', '1', '1', 'system:config:remove', '#', '0', '2022-05-21 08:30:54', null, null, '', '0');
|
||||
INSERT INTO `sys_menu` VALUES ('49', '参数导出', '10', '5', '#', '', '', '0', '1', '3', '1', '1', 'system:config:export', '#', '0', '2022-05-21 08:30:54', null, null, '', '0');
|
||||
INSERT INTO `sys_menu` VALUES ('50', '公告查询', '11', '1', '#', '', '', '0', '1', '3', '1', '1', 'system:notice:query', '#', '0', '2022-05-21 08:30:54', null, null, '', '0');
|
||||
INSERT INTO `sys_menu` VALUES ('51', '公告新增', '11', '2', '#', '', '', '0', '1', '3', '1', '1', 'system:notice:add', '#', '0', '2022-05-21 08:30:54', null, null, '', '0');
|
||||
INSERT INTO `sys_menu` VALUES ('52', '公告修改', '11', '3', '#', '', '', '0', '1', '3', '1', '1', 'system:notice:edit', '#', '0', '2022-05-21 08:30:54', null, null, '', '0');
|
||||
INSERT INTO `sys_menu` VALUES ('53', '公告删除', '11', '4', '#', '', '', '0', '1', '3', '1', '1', 'system:notice:remove', '#', '0', '2022-05-21 08:30:54', null, null, '', '0');
|
||||
INSERT INTO `sys_menu` VALUES ('54', '操作查询', '18', '1', '#', '', '', '0', '1', '3', '1', '1', 'monitor:operlog:query', '#', '0', '2022-05-21 08:30:54', null, null, '', '0');
|
||||
INSERT INTO `sys_menu` VALUES ('55', '操作删除', '18', '2', '#', '', '', '0', '1', '3', '1', '1', 'monitor:operlog:remove', '#', '0', '2022-05-21 08:30:54', null, null, '', '0');
|
||||
INSERT INTO `sys_menu` VALUES ('56', '日志导出', '18', '4', '#', '', '', '0', '1', '3', '1', '1', 'monitor:operlog:export', '#', '0', '2022-05-21 08:30:54', null, null, '', '0');
|
||||
INSERT INTO `sys_menu` VALUES ('57', '登录查询', '19', '1', '#', '', '', '0', '1', '3', '1', '1', 'monitor:logininfor:query', '#', '0', '2022-05-21 08:30:54', null, null, '', '0');
|
||||
INSERT INTO `sys_menu` VALUES ('58', '登录删除', '19', '2', '#', '', '', '0', '1', '3', '1', '1', 'monitor:logininfor:remove', '#', '0', '2022-05-21 08:30:54', null, null, '', '0');
|
||||
INSERT INTO `sys_menu` VALUES ('59', '日志导出', '19', '3', '#', '', '', '0', '1', '3', '1', '1', 'monitor:logininfor:export', '#', '0', '2022-05-21 08:30:54', null, null, '', '0');
|
||||
INSERT INTO `sys_menu` VALUES ('60', '在线查询', '13', '1', '#', '', '', '0', '1', '3', '1', '1', 'monitor:online:query', '#', '0', '2022-05-21 08:30:54', null, null, '', '0');
|
||||
INSERT INTO `sys_menu` VALUES ('61', '批量强退', '13', '2', '#', '', '', '0', '1', '3', '1', '1', 'monitor:online:batchLogout', '#', '0', '2022-05-21 08:30:54', null, null, '', '0');
|
||||
INSERT INTO `sys_menu` VALUES ('62', '单条强退', '13', '3', '#', '', '', '0', '1', '3', '1', '1', 'monitor:online:forceLogout', '#', '0', '2022-05-21 08:30:54', null, null, '', '0');
|
||||
|
||||
|
||||
-- ----------------------------
|
||||
-- Table structure for sys_notice
|
||||
-- ----------------------------
|
||||
DROP TABLE IF EXISTS `sys_notice`;
|
||||
CREATE TABLE `sys_notice` (
|
||||
`notice_id` int NOT NULL AUTO_INCREMENT COMMENT '公告ID',
|
||||
`notice_title` varchar(64) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL COMMENT '公告标题',
|
||||
`notice_type` smallint NOT NULL COMMENT '公告类型(1通知 2公告)',
|
||||
`notice_content` text COMMENT '公告内容',
|
||||
`status` smallint NOT NULL DEFAULT '0' COMMENT '公告状态(1正常 0关闭)',
|
||||
`creator_id` bigint NOT NULL COMMENT '创建者ID',
|
||||
`create_time` datetime DEFAULT NULL COMMENT '创建时间',
|
||||
`updater_id` bigint DEFAULT NULL COMMENT '更新者ID',
|
||||
`update_time` datetime DEFAULT NULL COMMENT '更新时间',
|
||||
`remark` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' COMMENT '备注',
|
||||
`deleted` tinyint(1) NOT NULL DEFAULT '0' COMMENT '逻辑删除',
|
||||
PRIMARY KEY (`notice_id`)
|
||||
) ENGINE=InnoDB AUTO_INCREMENT=31 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci COMMENT='通知公告表';
|
||||
|
||||
-- ----------------------------
|
||||
-- Records of sys_notice
|
||||
-- ----------------------------
|
||||
INSERT INTO `sys_notice` VALUES ('1', '温馨提醒:2018-07-01 AgileBoot新版本发布啦', '2', '新版本内容~~~~~~~~~~', '1', '1', '2022-05-21 08:30:55', '1', '2022-08-29 20:12:37', '管理员', '0');
|
||||
INSERT INTO `sys_notice` VALUES ('2', '维护通知:2018-07-01 AgileBoot系统凌晨维护', '1', '维护内容', '1', '1', '2022-05-21 08:30:55', null, null, '管理员', '0');
|
||||
|
||||
|
||||
-- ----------------------------
|
||||
-- Table structure for sys_operation_log
|
||||
-- ----------------------------
|
||||
DROP TABLE IF EXISTS `sys_operation_log`;
|
||||
CREATE TABLE `sys_operation_log` (
|
||||
`operation_id` bigint NOT NULL AUTO_INCREMENT COMMENT '日志主键',
|
||||
`business_type` smallint NOT NULL DEFAULT '0' COMMENT '业务类型(0其它 1新增 2修改 3删除)',
|
||||
`request_method` smallint NOT NULL DEFAULT '0' COMMENT '请求方式',
|
||||
`request_module` varchar(64) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' COMMENT '请求模块',
|
||||
`request_url` varchar(256) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' COMMENT '请求URL',
|
||||
`called_method` varchar(128) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' COMMENT '调用方法',
|
||||
`operator_type` smallint NOT NULL DEFAULT '0' COMMENT '操作类别(0其它 1后台用户 2手机端用户)',
|
||||
`user_id` bigint DEFAULT '0' COMMENT '用户ID',
|
||||
`username` varchar(32) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT '' COMMENT '操作人员',
|
||||
`operator_ip` varchar(128) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT '' COMMENT '操作人员ip',
|
||||
`operator_location` varchar(256) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT '' COMMENT '操作地点',
|
||||
`dept_id` bigint DEFAULT '0' COMMENT '部门ID',
|
||||
`dept_name` varchar(64) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL COMMENT '部门名称',
|
||||
`operation_param` varchar(2048) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT '' COMMENT '请求参数',
|
||||
`operation_result` varchar(2048) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT '' COMMENT '返回参数',
|
||||
`status` smallint NOT NULL DEFAULT '1' COMMENT '操作状态(1正常 0异常)',
|
||||
`error_stack` varchar(2048) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT '' COMMENT '错误消息',
|
||||
`operation_time` datetime NOT NULL COMMENT '操作时间',
|
||||
`deleted` tinyint(1) NOT NULL DEFAULT '0' COMMENT '逻辑删除',
|
||||
PRIMARY KEY (`operation_id`)
|
||||
) ENGINE=InnoDB AUTO_INCREMENT=379 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci COMMENT='操作日志记录';
|
||||
|
||||
-- ----------------------------
|
||||
-- Records of sys_operation_log
|
||||
-- ----------------------------
|
||||
|
||||
-- ----------------------------
|
||||
-- Table structure for sys_post
|
||||
-- ----------------------------
|
||||
DROP TABLE IF EXISTS `sys_post`;
|
||||
CREATE TABLE `sys_post` (
|
||||
`post_id` bigint NOT NULL AUTO_INCREMENT COMMENT '岗位ID',
|
||||
`post_code` varchar(64) NOT NULL COMMENT '岗位编码',
|
||||
`post_name` varchar(64) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL COMMENT '岗位名称',
|
||||
`post_sort` int NOT NULL COMMENT '显示顺序',
|
||||
`status` smallint NOT NULL COMMENT '状态(1正常 0停用)',
|
||||
`remark` varchar(512) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL COMMENT '备注',
|
||||
`creator_id` bigint DEFAULT NULL,
|
||||
`create_time` datetime DEFAULT NULL COMMENT '创建时间',
|
||||
`updater_id` bigint DEFAULT NULL,
|
||||
`update_time` datetime DEFAULT NULL COMMENT '更新时间',
|
||||
`deleted` tinyint(1) NOT NULL DEFAULT '0' COMMENT '逻辑删除',
|
||||
PRIMARY KEY (`post_id`)
|
||||
) ENGINE=InnoDB AUTO_INCREMENT=11 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci COMMENT='岗位信息表';
|
||||
|
||||
-- ----------------------------
|
||||
-- Records of sys_post
|
||||
-- ----------------------------
|
||||
INSERT INTO `sys_post` VALUES ('1', 'ceo', '董事长', '1', '1', '', null, '2022-05-21 08:30:54', null, null, '0');
|
||||
INSERT INTO `sys_post` VALUES ('2', 'se', '项目经理', '2', '1', '', null, '2022-05-21 08:30:54', null, null, '0');
|
||||
INSERT INTO `sys_post` VALUES ('3', 'hr', '人力资源', '3', '1', '', null, '2022-05-21 08:30:54', null, null, '0');
|
||||
INSERT INTO `sys_post` VALUES ('4', 'user', '普通员工', '5', '0', '', null, '2022-05-21 08:30:54', null, null, '0');
|
||||
|
||||
-- ----------------------------
|
||||
-- Table structure for sys_role
|
||||
-- ----------------------------
|
||||
DROP TABLE IF EXISTS `sys_role`;
|
||||
CREATE TABLE `sys_role` (
|
||||
`role_id` bigint NOT NULL AUTO_INCREMENT COMMENT '角色ID',
|
||||
`role_name` varchar(32) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL COMMENT '角色名称',
|
||||
`role_key` varchar(128) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL COMMENT '角色权限字符串',
|
||||
`role_sort` int NOT NULL COMMENT '显示顺序',
|
||||
`data_scope` smallint DEFAULT '1' COMMENT '数据范围(1:全部数据权限 2:自定数据权限 3: 本部门数据权限 4: 本部门及以下数据权限 5: 本人权限)',
|
||||
`dept_id_set` varchar(1024) DEFAULT '' COMMENT '角色所拥有的部门数据权限',
|
||||
`status` smallint NOT NULL COMMENT '角色状态(1正常 0停用)',
|
||||
`creator_id` bigint DEFAULT NULL COMMENT '创建者ID',
|
||||
`create_time` datetime DEFAULT NULL COMMENT '创建时间',
|
||||
`updater_id` bigint DEFAULT NULL COMMENT '更新者ID',
|
||||
`update_time` datetime DEFAULT NULL COMMENT '更新时间',
|
||||
`remark` varchar(512) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL COMMENT '备注',
|
||||
`deleted` tinyint(1) NOT NULL DEFAULT '0' COMMENT '删除标志(0代表存在 1代表删除)',
|
||||
PRIMARY KEY (`role_id`)
|
||||
) ENGINE=InnoDB AUTO_INCREMENT=111 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci COMMENT='角色信息表';
|
||||
|
||||
-- ----------------------------
|
||||
-- Records of sys_role
|
||||
-- ----------------------------
|
||||
INSERT INTO `sys_role` VALUES ('1', '超级管理员', 'admin', '1', '1', '', '1', null, '2022-05-21 08:30:54', null, null, '超级管理员', '0');
|
||||
INSERT INTO `sys_role` VALUES ('2', '普通角色', 'common', '3', '2', '', '1', null, '2022-05-21 08:30:54', null, null, '普通角色', '0');
|
||||
INSERT INTO `sys_role` VALUES ('3', '闲置角色', 'unused', '4', '2', '', '0', null, '2022-05-21 08:30:54', null, null, '未使用的角色', '0');
|
||||
|
||||
-- ----------------------------
|
||||
-- Table structure for sys_role_menu
|
||||
-- ----------------------------
|
||||
DROP TABLE IF EXISTS `sys_role_menu`;
|
||||
CREATE TABLE `sys_role_menu` (
|
||||
`role_id` bigint NOT NULL COMMENT '角色ID',
|
||||
`menu_id` bigint NOT NULL COMMENT '菜单ID',
|
||||
PRIMARY KEY (`role_id`,`menu_id`)
|
||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci COMMENT='角色和菜单关联表';
|
||||
|
||||
-- ----------------------------
|
||||
-- Records of sys_role_menu
|
||||
-- ----------------------------
|
||||
INSERT INTO `sys_role_menu` VALUES ('2', '1');
|
||||
INSERT INTO `sys_role_menu` VALUES ('2', '2');
|
||||
INSERT INTO `sys_role_menu` VALUES ('2', '3');
|
||||
INSERT INTO `sys_role_menu` VALUES ('2', '4');
|
||||
INSERT INTO `sys_role_menu` VALUES ('2', '5');
|
||||
INSERT INTO `sys_role_menu` VALUES ('2', '6');
|
||||
INSERT INTO `sys_role_menu` VALUES ('2', '7');
|
||||
INSERT INTO `sys_role_menu` VALUES ('2', '8');
|
||||
INSERT INTO `sys_role_menu` VALUES ('2', '9');
|
||||
INSERT INTO `sys_role_menu` VALUES ('2', '10');
|
||||
INSERT INTO `sys_role_menu` VALUES ('2', '11');
|
||||
INSERT INTO `sys_role_menu` VALUES ('2', '12');
|
||||
INSERT INTO `sys_role_menu` VALUES ('2', '13');
|
||||
INSERT INTO `sys_role_menu` VALUES ('2', '14');
|
||||
INSERT INTO `sys_role_menu` VALUES ('2', '15');
|
||||
INSERT INTO `sys_role_menu` VALUES ('2', '16');
|
||||
INSERT INTO `sys_role_menu` VALUES ('2', '17');
|
||||
INSERT INTO `sys_role_menu` VALUES ('2', '18');
|
||||
INSERT INTO `sys_role_menu` VALUES ('2', '19');
|
||||
INSERT INTO `sys_role_menu` VALUES ('2', '20');
|
||||
INSERT INTO `sys_role_menu` VALUES ('2', '21');
|
||||
INSERT INTO `sys_role_menu` VALUES ('2', '22');
|
||||
INSERT INTO `sys_role_menu` VALUES ('2', '23');
|
||||
INSERT INTO `sys_role_menu` VALUES ('2', '24');
|
||||
INSERT INTO `sys_role_menu` VALUES ('2', '25');
|
||||
INSERT INTO `sys_role_menu` VALUES ('2', '26');
|
||||
INSERT INTO `sys_role_menu` VALUES ('2', '27');
|
||||
INSERT INTO `sys_role_menu` VALUES ('2', '28');
|
||||
INSERT INTO `sys_role_menu` VALUES ('2', '29');
|
||||
INSERT INTO `sys_role_menu` VALUES ('2', '30');
|
||||
INSERT INTO `sys_role_menu` VALUES ('2', '31');
|
||||
INSERT INTO `sys_role_menu` VALUES ('2', '32');
|
||||
INSERT INTO `sys_role_menu` VALUES ('2', '33');
|
||||
INSERT INTO `sys_role_menu` VALUES ('2', '34');
|
||||
INSERT INTO `sys_role_menu` VALUES ('2', '35');
|
||||
INSERT INTO `sys_role_menu` VALUES ('2', '36');
|
||||
INSERT INTO `sys_role_menu` VALUES ('2', '37');
|
||||
INSERT INTO `sys_role_menu` VALUES ('2', '38');
|
||||
INSERT INTO `sys_role_menu` VALUES ('2', '39');
|
||||
INSERT INTO `sys_role_menu` VALUES ('2', '40');
|
||||
INSERT INTO `sys_role_menu` VALUES ('2', '41');
|
||||
INSERT INTO `sys_role_menu` VALUES ('2', '42');
|
||||
INSERT INTO `sys_role_menu` VALUES ('2', '43');
|
||||
INSERT INTO `sys_role_menu` VALUES ('2', '44');
|
||||
INSERT INTO `sys_role_menu` VALUES ('2', '45');
|
||||
INSERT INTO `sys_role_menu` VALUES ('2', '46');
|
||||
INSERT INTO `sys_role_menu` VALUES ('2', '47');
|
||||
INSERT INTO `sys_role_menu` VALUES ('2', '48');
|
||||
INSERT INTO `sys_role_menu` VALUES ('2', '49');
|
||||
INSERT INTO `sys_role_menu` VALUES ('2', '50');
|
||||
INSERT INTO `sys_role_menu` VALUES ('2', '51');
|
||||
INSERT INTO `sys_role_menu` VALUES ('2', '52');
|
||||
INSERT INTO `sys_role_menu` VALUES ('2', '53');
|
||||
INSERT INTO `sys_role_menu` VALUES ('2', '54');
|
||||
INSERT INTO `sys_role_menu` VALUES ('2', '55');
|
||||
INSERT INTO `sys_role_menu` VALUES ('2', '56');
|
||||
INSERT INTO `sys_role_menu` VALUES ('2', '57');
|
||||
INSERT INTO `sys_role_menu` VALUES ('2', '58');
|
||||
INSERT INTO `sys_role_menu` VALUES ('2', '59');
|
||||
INSERT INTO `sys_role_menu` VALUES ('2', '60');
|
||||
INSERT INTO `sys_role_menu` VALUES ('2', '61');
|
||||
-- roleId = 2的权限 特地少一个 方便测试
|
||||
INSERT INTO `sys_role_menu` VALUES ('3', '1');
|
||||
|
||||
|
||||
-- ----------------------------
|
||||
-- Table structure for sys_user
|
||||
-- ----------------------------
|
||||
DROP TABLE IF EXISTS `sys_user`;
|
||||
CREATE TABLE `sys_user` (
|
||||
`user_id` bigint NOT NULL AUTO_INCREMENT COMMENT '用户ID',
|
||||
`post_id` bigint DEFAULT NULL COMMENT '职位id',
|
||||
`role_id` bigint DEFAULT NULL COMMENT '角色id',
|
||||
`dept_id` bigint DEFAULT NULL COMMENT '部门ID',
|
||||
`username` varchar(64) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL COMMENT '用户账号',
|
||||
`nick_name` varchar(32) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL COMMENT '用户昵称',
|
||||
`user_type` smallint DEFAULT '0' COMMENT '用户类型(00系统用户)',
|
||||
`email` varchar(128) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT '' COMMENT '用户邮箱',
|
||||
`phone_number` varchar(18) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT '' COMMENT '手机号码',
|
||||
`sex` smallint DEFAULT '0' COMMENT '用户性别(0男 1女 2未知)',
|
||||
`avatar` varchar(512) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT '' COMMENT '头像地址',
|
||||
`password` varchar(128) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL DEFAULT '' COMMENT '密码',
|
||||
`status` smallint NOT NULL DEFAULT '0' COMMENT '帐号状态(1正常 2停用 3冻结)',
|
||||
`login_ip` varchar(128) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT '' COMMENT '最后登录IP',
|
||||
`login_date` datetime DEFAULT NULL COMMENT '最后登录时间',
|
||||
`is_admin` tinyint(1) NOT NULL DEFAULT '0' COMMENT '超级管理员标志(1是,0否)',
|
||||
`creator_id` bigint DEFAULT NULL COMMENT '更新者ID',
|
||||
`create_time` datetime DEFAULT NULL COMMENT '创建时间',
|
||||
`updater_id` bigint DEFAULT NULL COMMENT '更新者ID',
|
||||
`update_time` datetime DEFAULT NULL COMMENT '更新时间',
|
||||
`remark` varchar(512) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL COMMENT '备注',
|
||||
`deleted` tinyint(1) NOT NULL DEFAULT '0' COMMENT '删除标志(0代表存在 1代表删除)',
|
||||
PRIMARY KEY (`user_id`)
|
||||
) ENGINE=InnoDB AUTO_INCREMENT=109 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_general_ci COMMENT='用户信息表';
|
||||
|
||||
-- ----------------------------
|
||||
-- Records of sys_user
|
||||
-- ----------------------------
|
||||
INSERT INTO `sys_user` VALUES ('1', '1', '1', '4', 'admin', 'valarchie1', '0', 'agileboot@163.com', '15888888889', '0', '', '$2a$10$rb1wRoEIkLbIknREEN1LH.FGs4g0oOS5t6l5LQ793nRaFO.SPHDHy', '1', '127.0.0.1', '2022-10-06 17:00:06', 1, null, '2022-05-21 08:30:54', '1', '2022-10-06 17:00:06', '管理员', '0');
|
||||
INSERT INTO `sys_user` VALUES ('2', '2', '2', '5', 'ag1', 'valarchie2', '0', 'agileboot1@qq.com', '15666666666', '1', '', '$2a$10$7JB720yubVSZvUI0rEqK/.VqGOZTH.ulu33dHOiBE8ByOhJIrdAu2', '1', '127.0.0.1', '2022-05-21 08:30:54', 0, null, '2022-05-21 08:30:54', null, null, '测试员1', '0');
|
||||
INSERT INTO `sys_user` VALUES ('3', '2', '0', '5', 'ag2', 'valarchie3', '0', 'agileboot2@qq.com', '15666666667', '1', '', '$2a$10$7JB720yubVSZvUI0rEqK/.VqGOZTH.ulu33dHOiBE8ByOhJIrdAu2', '1', '127.0.0.1', '2022-05-21 08:30:54', 0, null, '2022-05-21 08:30:54', null, null, '测试员2', '0');
|
||||
Reference in New Issue
Block a user