mirror of
https://github.com/hpd840321/starRiverProperty.git
synced 2026-06-16 11:50:30 +08:00
Initial commit: reorganized source tree
- backend/: 13 Maven modules (cw-elevator-application, cloudwalk-cloud, intelligent-cwoscomponent, ninca-crk, etc.) - frontend/: 4 Vue projects (elevator-front, cwos-portal, alarm-front, front_acs) + decompiled + scripts - scripts/: build, test-env, tools (Docker Compose, service templates, API parity) - docs/: AGENTS.md, superpowers specs, architecture docs - .gitignore: standard Java/Maven exclusions Moved from legacy maven-*/ root layout to backend/ organized structure.
This commit is contained in:
@@ -0,0 +1,43 @@
|
||||
-- 租户访客楼层策略最小核查 SQL(执行前确认数据库实例为电梯业务库)
|
||||
-- 目标租户:广发基金 business_id = 2524639890ba4f2cba9ba1a4eeaa4015
|
||||
|
||||
-- 1) 表结构与索引确认
|
||||
SHOW CREATE TABLE tenant_visitor_floor_policy;
|
||||
|
||||
-- 2) 广发租户策略主检查
|
||||
SELECT id,
|
||||
business_id,
|
||||
policy_type,
|
||||
allow_zone_ids,
|
||||
building_id,
|
||||
enabled,
|
||||
policy_version,
|
||||
updated_at,
|
||||
remark
|
||||
FROM tenant_visitor_floor_policy
|
||||
WHERE business_id = '2524639890ba4f2cba9ba1a4eeaa4015'
|
||||
ORDER BY updated_at DESC, policy_version DESC;
|
||||
|
||||
-- 3) 同租户是否存在多条默认策略(building_id 为空)
|
||||
SELECT business_id, COUNT(*) AS cnt
|
||||
FROM tenant_visitor_floor_policy
|
||||
WHERE business_id = '2524639890ba4f2cba9ba1a4eeaa4015'
|
||||
AND (building_id IS NULL OR building_id = '')
|
||||
GROUP BY business_id
|
||||
HAVING COUNT(*) > 1;
|
||||
|
||||
-- 4) enabled 与 policy_type 分布
|
||||
SELECT policy_type, enabled, COUNT(*) AS cnt
|
||||
FROM tenant_visitor_floor_policy
|
||||
WHERE business_id = '2524639890ba4f2cba9ba1a4eeaa4015'
|
||||
GROUP BY policy_type, enabled
|
||||
ORDER BY cnt DESC;
|
||||
|
||||
-- 5) allow_zone_ids 是否包含 28F zone_id
|
||||
SELECT id, allow_zone_ids
|
||||
FROM tenant_visitor_floor_policy
|
||||
WHERE business_id = '2524639890ba4f2cba9ba1a4eeaa4015'
|
||||
AND enabled = 1
|
||||
AND policy_type = 'INTERSECT_ALLOWLIST'
|
||||
AND allow_zone_ids LIKE '%605560545117995008%';
|
||||
|
||||
Reference in New Issue
Block a user