Skip to content

Commit

Permalink
feat:希望支持分支进行上架测试 #4780
Browse files Browse the repository at this point in the history
  • Loading branch information
yjieliang committed Oct 18, 2023
1 parent 4316c26 commit aea5427
Show file tree
Hide file tree
Showing 2 changed files with 28 additions and 1 deletion.
2 changes: 1 addition & 1 deletion support-files/sql/1001_ci_store_ddl_mysql.sql
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ CREATE TABLE IF NOT EXISTS `T_ATOM` (
`SUMMARY` varchar(256) DEFAULT NULL COMMENT '简介',
`DESCRIPTION` text COMMENT '描述',
`CATEGROY` tinyint(4) NOT NULL DEFAULT '1' COMMENT '类别',
`VERSION` varchar(20) NOT NULL COMMENT '版本号',
`VERSION` varchar(30) NOT NULL COMMENT '版本号',
`LOGO_URL` varchar(256) DEFAULT NULL COMMENT 'LOGO URL地址',
`ICON` text COMMENT '插件图标',
`DEFAULT_FLAG` bit(1) NOT NULL DEFAULT b'0' COMMENT '是否为默认原子',
Expand Down
27 changes: 27 additions & 0 deletions support-files/sql/2003_v2.x/2020_ci_store-update_v2.0_mysql.sql
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
USE devops_ci_store;
SET NAMES utf8mb4;

DROP PROCEDURE IF EXISTS ci_store_schema_update;

DELIMITER <CI_UBF>

CREATE PROCEDURE ci_store_schema_update()
BEGIN

DECLARE db VARCHAR(100);
SET AUTOCOMMIT = 0;
SELECT DATABASE() INTO db;

IF EXISTS(SELECT 1
FROM information_schema.COLUMNS
WHERE TABLE_SCHEMA = db
AND TABLE_NAME = 'T_ATOM'
AND COLUMN_NAME = 'VERSION') THEN
ALTER TABLE T_ATOM MODIFY COLUMN VERSION varchar(30) CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL COMMENT '版本号';
END IF;

COMMIT;
END <CI_UBF>
DELIMITER ;
COMMIT;
CALL ci_store_schema_update();

0 comments on commit aea5427

Please sign in to comment.