Skip to content

Commit

Permalink
feat: update pom.xml
Browse files Browse the repository at this point in the history
feat: simplify project
feat: remove wechat dependence
  • Loading branch information
feellmoose committed Jun 5, 2024
1 parent a76fbb9 commit 13d007d
Show file tree
Hide file tree
Showing 45 changed files with 216 additions and 1,348 deletions.
88 changes: 33 additions & 55 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -5,104 +5,82 @@
<parent>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-parent</artifactId>
<version>3.1.1</version>
<relativePath/> <!-- lookup parent from repository -->
<version>3.3.0</version>
<relativePath/>
</parent>
<groupId>sast.evento</groupId>
<artifactId>SAST-Evento</artifactId>
<version>0.0.1-SNAPSHOT</version>
<name>SAST-Evento-Backend</name>
<description>SAST-Evento-Backend</description>
<properties>
<java.version>17</java.version>
<java.version>21</java.version>
</properties>
<dependencies>

<!-- sast-link-sdk -->
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-web</artifactId>
<groupId>fun.feellmoose</groupId>
<artifactId>sast-link-SDK</artifactId>
<version>0.1.2</version>
</dependency>
<!-- jwt -->
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-aop</artifactId>
<groupId>com.auth0</groupId>
<artifactId>java-jwt</artifactId>
<version>3.4.0</version>
</dependency>
<!-- mybatis-plus -->
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-cache</artifactId>
<groupId>com.baomidou</groupId>
<artifactId>mybatis-plus-boot-starter</artifactId>
<version>3.5.3.1</version>
</dependency>

<!-- sast-link-sdk -->
<!-- mybatis -->
<dependency>
<groupId>fun.feellmoose</groupId>
<artifactId>sast-link-SDK</artifactId>
<version>0.1.2</version>
<groupId>org.mybatis</groupId>
<artifactId>mybatis-spring</artifactId>
<version>3.0.3</version>
</dependency>

<!-- quartz -->
<!-- cos_sdk-->
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-quartz</artifactId>
<groupId>com.qcloud</groupId>
<artifactId>cos_api</artifactId>
<version>5.6.213</version>
</dependency>

<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-test</artifactId>
<scope>test</scope>
<artifactId>spring-boot-starter-web</artifactId>
</dependency>

<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-data-redis</artifactId>
</dependency>
<dependency>
<groupId>com.baomidou</groupId>
<artifactId>mybatis-plus-boot-starter</artifactId>
<version>3.5.3.1</version>
<artifactId>spring-boot-starter-cache</artifactId>
</dependency>
<dependency>
<groupId>mysql</groupId>
<artifactId>mysql-connector-java</artifactId>
<version>8.0.33</version>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-data-redis</artifactId>
</dependency>

<dependency>
<groupId>org.projectlombok</groupId>
<artifactId>lombok</artifactId>
<optional>true</optional>
</dependency>

<!-- jwt -->
<dependency>
<groupId>com.auth0</groupId>
<artifactId>java-jwt</artifactId>
<version>3.4.0</version>
<groupId>com.mysql</groupId>
<artifactId>mysql-connector-j</artifactId>
<scope>runtime</scope>
</dependency>


<!-- cos_sdk-->
<dependency>
<groupId>com.qcloud</groupId>
<artifactId>cos_api</artifactId>
<version>5.6.155</version>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-test</artifactId>
<scope>test</scope>
</dependency>


</dependencies>

<repositories>
<repository>
<id>alimaven</id>
<url>https://maven.aliyun.com/repository/public</url>
</repository>
</repositories>

<pluginRepositories>
<pluginRepository>
<id>alimaven</id>
<url>https://maven.aliyun.com/repository/public</url>
</pluginRepository>
</pluginRepositories>

<build>
<plugins>
<plugin>
Expand Down
5 changes: 4 additions & 1 deletion src/main/java/sast/evento/annotation/DefaultActionState.java
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,13 @@
import java.lang.annotation.RetentionPolicy;
import java.lang.annotation.Target;

/**
* Require Authorization.
* Default action state of an event.
*/
@Target(ElementType.METHOD)
@Retention(RetentionPolicy.RUNTIME)
public @interface DefaultActionState {
/* 添加注释后,默认为管理员操作 */
ActionState value() default ActionState.ADMIN;
String group() default "default";
}
4 changes: 4 additions & 0 deletions src/main/java/sast/evento/annotation/EventId.java
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,10 @@

import java.lang.annotation.*;

/**
* Require Authorization.
* Description which param is needed for event check.
*/
@Target({ElementType.PARAMETER})
@Retention(RetentionPolicy.RUNTIME)
@Documented
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,12 +8,11 @@
import java.lang.annotation.Target;

/**
* @author: NicoAsuka
* @date: 4/29/23
* Describe operation of API.
*/
@Target(ElementType.METHOD)
@Retention(RetentionPolicy.RUNTIME)
public @interface OperateLog {
public @interface Operation {
@AliasFor(attribute = "description")
String value() default "";

Expand Down
97 changes: 0 additions & 97 deletions src/main/java/sast/evento/aop/OperateLogAspect.java

This file was deleted.

8 changes: 8 additions & 0 deletions src/main/java/sast/evento/common/Constants.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
package sast.evento.common;

/**
* Constants
*/
public interface Constants {

}
14 changes: 0 additions & 14 deletions src/main/java/sast/evento/common/constant/Constant.java

This file was deleted.

4 changes: 1 addition & 3 deletions src/main/java/sast/evento/common/enums/ErrorEnum.java
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,7 @@
import lombok.Getter;

/**
* @projectName: sast-evento-backend
* @author: feelMoose
* @date: 2023/7/12 22:04
* Error enum hold errMsg to FrontEnd
*/
@Getter
@AllArgsConstructor
Expand Down
4 changes: 4 additions & 0 deletions src/main/java/sast/evento/common/enums/EventState.java
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
package sast.evento.common.enums;

import com.baomidou.mybatisplus.annotation.EnumValue;
import com.fasterxml.jackson.annotation.JsonValue;
import sast.evento.annotation.EventId;
import sast.evento.exception.LocalRunTimeException;

import java.util.Arrays;
Expand All @@ -11,6 +13,8 @@ public enum EventState {
IN_PROGRESS(3, "进行中"),
CANCELED(4, "已取消"),
ENDED(5, "已结束");

@EnumValue
private final Integer state;
private final String description;

Expand Down
7 changes: 0 additions & 7 deletions src/main/java/sast/evento/common/enums/Platform.java

This file was deleted.

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,12 @@
import java.sql.SQLException;

/**
* @author Aiden
* @date 2023/12/31 14:50
* Type convertor for mybatis-plus
*/
public class FeedbackScoreTypeHandler extends BaseTypeHandler<Double> {

//TODO logic should not be here

@Override
public void setNonNullParameter(PreparedStatement preparedStatement, int i, Double aDouble, JdbcType jdbcType) throws SQLException {
preparedStatement.setDouble(i, aDouble * 10);
Expand Down
Loading

0 comments on commit 13d007d

Please sign in to comment.