feat(M03-D): 完成场景码NFC与受控WiFi
This commit is contained in:
@@ -36,6 +36,9 @@ const contentVerifySql = read('database/migrations/2026061808_m03b_decoration_ad
|
||||
const discoveryUpSql = read('database/migrations/2026061809_m03c_store_discovery.up.sql');
|
||||
const discoveryDownSql = read('database/migrations/2026061809_m03c_store_discovery.down.sql');
|
||||
const discoveryVerifySql = read('database/migrations/2026061809_m03c_store_discovery.verify.sql');
|
||||
const accessUpSql = read('database/migrations/2026061810_m03d_scene_wifi_access.up.sql');
|
||||
const accessDownSql = read('database/migrations/2026061810_m03d_scene_wifi_access.down.sql');
|
||||
const accessVerifySql = read('database/migrations/2026061810_m03d_scene_wifi_access.verify.sql');
|
||||
|
||||
const coreTables = [
|
||||
'qipai_schema_migrations',
|
||||
@@ -170,5 +173,15 @@ for (const column of ['city', 'district']) {
|
||||
}
|
||||
assert.match(discoveryUpSql, /idx_qipai_stores_tenant_city_status/);
|
||||
assert.match(discoveryUpSql, /idx_qipai_stores_tenant_coordinates/);
|
||||
for (const table of [
|
||||
'qipai_scene_codes', 'qipai_scene_scan_events', 'qipai_order_user_access'
|
||||
]) {
|
||||
assert.match(accessUpSql, new RegExp(`CREATE TABLE IF NOT EXISTS ${table}`));
|
||||
assert.match(accessDownSql, new RegExp(`DROP TABLE IF EXISTS ${table}`));
|
||||
assert.match(accessVerifySql, new RegExp(`'${table}'`));
|
||||
}
|
||||
assert.match(accessUpSql, /scan_count BIGINT UNSIGNED/);
|
||||
assert.match(accessUpSql, /target_type = 'STORE'/);
|
||||
assert.match(accessUpSql, /PRIMARY KEY \(tenant_id, order_id, user_id\)/);
|
||||
|
||||
console.log('PASS: M01-B through M03-C migration contracts are present.');
|
||||
console.log('PASS: M01-B through M03-D migration contracts are present.');
|
||||
|
||||
Reference in New Issue
Block a user