From f3d048c240aa0cf0c812173fdbb985b3ffc30aa3 Mon Sep 17 00:00:00 2001 From: zhangshuai Date: Fri, 9 Aug 2024 17:21:29 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20application=20=E6=B7=BB=E5=8A=A0=20packa?= =?UTF-8?q?geName=20=20website=20developer=20=E5=B1=9E=E6=80=A7?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/main/java/net/geedge/asw/common/util/RCode.java | 1 + .../asw/module/app/entity/ApplicationEntity.java | 3 +++ .../asw/module/app/entity/ApplicationLogEntity.java | 3 +++ .../app/service/impl/ApplicationServiceImpl.java | 13 +++++++++++-- .../resources/db/mapper/app/ApplicationMapper.xml | 3 +++ .../resources/db/migration/V1.0.01__INIT_TABLES.sql | 6 ++++++ 6 files changed, 27 insertions(+), 2 deletions(-) diff --git a/src/main/java/net/geedge/asw/common/util/RCode.java b/src/main/java/net/geedge/asw/common/util/RCode.java index 26d7dba..2ca7ab1 100644 --- a/src/main/java/net/geedge/asw/common/util/RCode.java +++ b/src/main/java/net/geedge/asw/common/util/RCode.java @@ -33,6 +33,7 @@ public enum RCode { APP_DESCRIPTION_CANNOT_EMPTY(201006, "application description cannot be empty"), APP_DUPLICATE_RECORD(201007, "application duplicate record"), APP_NOT_EXIST(201008, "application does not exist"), + APP_PACKAGE_NAME_FORMAT_ERROR(201009, "application package name format error"), // Package diff --git a/src/main/java/net/geedge/asw/module/app/entity/ApplicationEntity.java b/src/main/java/net/geedge/asw/module/app/entity/ApplicationEntity.java index ab9e3fc..5815104 100644 --- a/src/main/java/net/geedge/asw/module/app/entity/ApplicationEntity.java +++ b/src/main/java/net/geedge/asw/module/app/entity/ApplicationEntity.java @@ -18,6 +18,9 @@ public class ApplicationEntity { private String properties; private String description; private String surrogates; + private String packageName; + private String website; + private String developer; private Long createTimestamp; private Long updateTimestamp; diff --git a/src/main/java/net/geedge/asw/module/app/entity/ApplicationLogEntity.java b/src/main/java/net/geedge/asw/module/app/entity/ApplicationLogEntity.java index 16a7661..6d41f95 100644 --- a/src/main/java/net/geedge/asw/module/app/entity/ApplicationLogEntity.java +++ b/src/main/java/net/geedge/asw/module/app/entity/ApplicationLogEntity.java @@ -13,6 +13,9 @@ public class ApplicationLogEntity { private String properties; private String description; private String surrogates; + private String packageName; + private String website; + private String developer; private Long createTimestamp; private Long updateTimestamp; diff --git a/src/main/java/net/geedge/asw/module/app/service/impl/ApplicationServiceImpl.java b/src/main/java/net/geedge/asw/module/app/service/impl/ApplicationServiceImpl.java index 66b1ead..0e582f2 100644 --- a/src/main/java/net/geedge/asw/module/app/service/impl/ApplicationServiceImpl.java +++ b/src/main/java/net/geedge/asw/module/app/service/impl/ApplicationServiceImpl.java @@ -2,6 +2,7 @@ package net.geedge.asw.module.app.service.impl; import cn.dev33.satoken.stp.SaTokenInfo; import cn.dev33.satoken.stp.StpUtil; +import cn.hutool.core.map.MapUtil; import cn.hutool.core.net.url.UrlBuilder; import cn.hutool.log.Log; import com.alibaba.fastjson2.JSONArray; @@ -78,7 +79,11 @@ public class ApplicationServiceImpl extends ServiceImpl + + + diff --git a/src/main/resources/db/migration/V1.0.01__INIT_TABLES.sql b/src/main/resources/db/migration/V1.0.01__INIT_TABLES.sql index 7724e65..ac15669 100644 --- a/src/main/resources/db/migration/V1.0.01__INIT_TABLES.sql +++ b/src/main/resources/db/migration/V1.0.01__INIT_TABLES.sql @@ -246,6 +246,9 @@ CREATE TABLE `application` ( `name` varchar(256) NOT NULL DEFAULT '' COMMENT '应用名称', `long_name` varchar(256) NOT NULL DEFAULT '' COMMENT '应用全称', `properties` text NOT NULL DEFAULT '' COMMENT '应用数据', + `package_name` VARCHAR(512) NOT NULL DEFAULT '' COMMENT '包名', + `website` VARCHAR(1024) NOT NULL DEFAULT '' COMMENT '网站', + `developer` VARCHAR(256) NOT NULL DEFAULT '' COMMENT '开发者', `description` text NOT NULL DEFAULT '' COMMENT '描述信息', `surrogates` text NOT NULL DEFAULT '' COMMENT '', `create_timestamp` bigint(20) NOT NULL COMMENT '创建时间戳', @@ -270,6 +273,9 @@ CREATE TABLE `application_log` ( `name` varchar(256) NOT NULL DEFAULT '' COMMENT '应用名称', `long_name` varchar(256) NOT NULL DEFAULT '' COMMENT '应用全称', `properties` text NOT NULL DEFAULT '' COMMENT '应用数据', + `package_name` VARCHAR(512) NOT NULL DEFAULT '' COMMENT '包名', + `website` VARCHAR(1024) NOT NULL DEFAULT '' COMMENT '网站', + `developer` VARCHAR(256) NOT NULL DEFAULT '' COMMENT '开发者', `description` text NOT NULL DEFAULT '' COMMENT '描述信息', `surrogates` text NOT NULL DEFAULT '' COMMENT '', `create_timestamp` bigint(20) NOT NULL COMMENT '创建时间戳',