暂存提交

This commit is contained in:
2026-08-19 16:49:41 +08:00
parent 6acb6178da
commit 63618c20dc
6 changed files with 30 additions and 12 deletions
+5 -5
View File
@@ -71,9 +71,9 @@ PREPARE migration_stmt FROM @ddl; EXECUTE migration_stmt; DEALLOCATE PREPARE mig
-- Warehouse locations, pallets, resource locks and UTF-8 descriptions
-- ============================================================================
CREATE DATABASE IF NOT EXISTS baiyue_warehouse_overseas
CREATE DATABASE IF NOT EXISTS baiyue_lastlag_warehouse
DEFAULT CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci;
USE baiyue_warehouse_overseas;
USE baiyue_lastlag_warehouse;
CREATE TABLE IF NOT EXISTS wh_location (
id BIGINT UNSIGNED NOT NULL COMMENT '库位ID(雪花ID)',
@@ -520,7 +520,7 @@ PREPARE migration_stmt FROM @ddl; EXECUTE migration_stmt; DEALLOCATE PREPARE mig
-- Warehouse master-data descriptions and query indexes
-- ============================================================================
USE baiyue_warehouse_overseas;
USE baiyue_lastlag_warehouse;
CREATE TABLE IF NOT EXISTS wh_warehouse (
id BIGINT UNSIGNED NOT NULL COMMENT '仓库ID(雪花ID)', tenant_id BIGINT UNSIGNED NOT NULL COMMENT '仓库所属租户ID',
@@ -752,7 +752,7 @@ CREATE TABLE IF NOT EXISTS ll_inbound_stock_receipt (
) ENGINE=InnoDB COMMENT='入仓PDA库存实收快照';
-- 2026-08-17 warehouse virtual location and generated pallet code support.
USE baiyue_warehouse_overseas;
USE baiyue_lastlag_warehouse;
SET @ddl = (SELECT IF(EXISTS (SELECT 1 FROM information_schema.columns WHERE table_schema=DATABASE()
AND table_name='wh_pallet' AND column_name='pallet_code'),
@@ -3319,7 +3319,7 @@ SET @ddl = (SELECT IF(EXISTS (SELECT 1 FROM information_schema.columns WHERE tab
PREPARE schema_comments_025 FROM @ddl; EXECUTE schema_comments_025; DEALLOCATE PREPARE schema_comments_025;
USE baiyue_warehouse_overseas;
USE baiyue_lastlag_warehouse;
SET @ddl = (SELECT IF(EXISTS (SELECT 1 FROM information_schema.tables WHERE table_schema=DATABASE() AND table_name='wh_location' AND COALESCE(table_comment,'') <> '仓库库位表:按租户和仓库维护库位及承重信息'), 'ALTER TABLE wh_location COMMENT = ''仓库库位表:按租户和仓库维护库位及承重信息''', 'SELECT 1'));
PREPARE schema_comments_025 FROM @ddl; EXECUTE schema_comments_025; DEALLOCATE PREPARE schema_comments_025;