@bash-app/bash-common 30.289.0 → 30.291.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/extendedSchemas.d.ts +85 -9
- package/dist/extendedSchemas.d.ts.map +1 -1
- package/dist/extendedSchemas.js +9 -0
- package/dist/extendedSchemas.js.map +1 -1
- package/dist/index.d.ts +1 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +1 -0
- package/dist/index.js.map +1 -1
- package/dist/utils/__tests__/entertainmentServiceTypeOptions.test.d.ts +2 -0
- package/dist/utils/__tests__/entertainmentServiceTypeOptions.test.d.ts.map +1 -0
- package/dist/utils/__tests__/entertainmentServiceTypeOptions.test.js +17 -0
- package/dist/utils/__tests__/entertainmentServiceTypeOptions.test.js.map +1 -0
- package/dist/utils/entertainmentServiceTypeOptions.d.ts +9 -0
- package/dist/utils/entertainmentServiceTypeOptions.d.ts.map +1 -0
- package/dist/utils/entertainmentServiceTypeOptions.js +46 -0
- package/dist/utils/entertainmentServiceTypeOptions.js.map +1 -0
- package/dist/utils/luxonUtils.d.ts.map +1 -1
- package/dist/utils/luxonUtils.js +20 -8
- package/dist/utils/luxonUtils.js.map +1 -1
- package/dist/utils/recurrenceUtils.d.ts.map +1 -1
- package/dist/utils/recurrenceUtils.js +7 -3
- package/dist/utils/recurrenceUtils.js.map +1 -1
- package/package.json +1 -1
- package/prisma/schema.prisma +32 -0
- package/src/extendedSchemas.ts +28 -10
- package/src/index.ts +1 -0
- package/src/utils/__tests__/entertainmentServiceTypeOptions.test.ts +18 -0
- package/src/utils/entertainmentServiceTypeOptions.ts +56 -0
- package/src/utils/luxonUtils.ts +22 -14
- package/src/utils/recurrenceUtils.ts +6 -3
- package/prisma/prisma/COMPREHENSIVE-MIGRATION-README.md +0 -295
- package/prisma/prisma/MIGRATION-CHECKLIST.md +0 -198
- package/prisma/prisma/MIGRATION-FILES-GUIDE.md +0 -76
- package/prisma/prisma/comprehensive-migration-20260120.sql +0 -5751
- package/prisma/prisma/delta-migration-20260120.sql +0 -302
- package/prisma/prisma/manual-migration-add-missing-columns.sql +0 -182
- package/prisma/prisma/migrations/competition-prize-catalog-entry-tier.sql +0 -39
- package/prisma/prisma/quick-migration.sql +0 -47
- package/prisma/prisma/schema.prisma +0 -10850
- package/prisma/prisma/verify-migration.sql +0 -132
|
@@ -1,132 +0,0 @@
|
|
|
1
|
-
-- ============================================================================
|
|
2
|
-
-- POST-MIGRATION VERIFICATION SCRIPT
|
|
3
|
-
-- Run this after applying comprehensive-migration-20260120.sql
|
|
4
|
-
-- ============================================================================
|
|
5
|
-
|
|
6
|
-
-- 1. Count all tables (expect 160+)
|
|
7
|
-
SELECT COUNT(*) as total_tables
|
|
8
|
-
FROM information_schema.tables
|
|
9
|
-
WHERE table_schema = 'public';
|
|
10
|
-
|
|
11
|
-
-- 2. Count all enums (expect 170+)
|
|
12
|
-
SELECT COUNT(*) as total_enums
|
|
13
|
-
FROM pg_type
|
|
14
|
-
WHERE typtype = 'e';
|
|
15
|
-
|
|
16
|
-
-- 3. Count all indexes (expect 400+)
|
|
17
|
-
SELECT COUNT(*) as total_indexes
|
|
18
|
-
FROM pg_indexes
|
|
19
|
-
WHERE schemaname = 'public';
|
|
20
|
-
|
|
21
|
-
-- 4. Verify critical tables exist
|
|
22
|
-
SELECT
|
|
23
|
-
CASE
|
|
24
|
-
WHEN EXISTS (SELECT 1 FROM information_schema.tables WHERE table_name = 'User') THEN '✅'
|
|
25
|
-
ELSE '❌'
|
|
26
|
-
END as "User",
|
|
27
|
-
CASE
|
|
28
|
-
WHEN EXISTS (SELECT 1 FROM information_schema.tables WHERE table_name = 'BashEvent') THEN '✅'
|
|
29
|
-
ELSE '❌'
|
|
30
|
-
END as "BashEvent",
|
|
31
|
-
CASE
|
|
32
|
-
WHEN EXISTS (SELECT 1 FROM information_schema.tables WHERE table_name = 'Service') THEN '✅'
|
|
33
|
-
ELSE '❌'
|
|
34
|
-
END as "Service",
|
|
35
|
-
CASE
|
|
36
|
-
WHEN EXISTS (SELECT 1 FROM information_schema.tables WHERE table_name = 'Ticket') THEN '✅'
|
|
37
|
-
ELSE '❌'
|
|
38
|
-
END as "Ticket",
|
|
39
|
-
CASE
|
|
40
|
-
WHEN EXISTS (SELECT 1 FROM information_schema.tables WHERE table_name = 'BashFeedPost') THEN '✅'
|
|
41
|
-
ELSE '❌'
|
|
42
|
-
END as "BashFeedPost",
|
|
43
|
-
CASE
|
|
44
|
-
WHEN EXISTS (SELECT 1 FROM information_schema.tables WHERE table_name = 'Competition') THEN '✅'
|
|
45
|
-
ELSE '❌'
|
|
46
|
-
END as "Competition",
|
|
47
|
-
CASE
|
|
48
|
-
WHEN EXISTS (SELECT 1 FROM information_schema.tables WHERE table_name = 'Organization') THEN '✅'
|
|
49
|
-
ELSE '❌'
|
|
50
|
-
END as "Organization",
|
|
51
|
-
CASE
|
|
52
|
-
WHEN EXISTS (SELECT 1 FROM information_schema.tables WHERE table_name = 'TaskComment') THEN '✅'
|
|
53
|
-
ELSE '❌'
|
|
54
|
-
END as "TaskComment",
|
|
55
|
-
CASE
|
|
56
|
-
WHEN EXISTS (SELECT 1 FROM information_schema.tables WHERE table_name = 'TaskInvitation') THEN '✅'
|
|
57
|
-
ELSE '❌'
|
|
58
|
-
END as "TaskInvitation",
|
|
59
|
-
CASE
|
|
60
|
-
WHEN EXISTS (SELECT 1 FROM information_schema.tables WHERE table_name = 'AuditLog') THEN '✅'
|
|
61
|
-
ELSE '❌'
|
|
62
|
-
END as "AuditLog";
|
|
63
|
-
|
|
64
|
-
-- 5. Verify critical enums exist
|
|
65
|
-
SELECT
|
|
66
|
-
CASE
|
|
67
|
-
WHEN EXISTS (SELECT 1 FROM pg_type WHERE typname = 'BashStatus') THEN '✅'
|
|
68
|
-
ELSE '❌'
|
|
69
|
-
END as "BashStatus",
|
|
70
|
-
CASE
|
|
71
|
-
WHEN EXISTS (SELECT 1 FROM pg_type WHERE typname = 'ServiceStatus') THEN '✅'
|
|
72
|
-
ELSE '❌'
|
|
73
|
-
END as "ServiceStatus",
|
|
74
|
-
CASE
|
|
75
|
-
WHEN EXISTS (SELECT 1 FROM pg_type WHERE typname = 'NotificationType') THEN '✅'
|
|
76
|
-
ELSE '❌'
|
|
77
|
-
END as "NotificationType",
|
|
78
|
-
CASE
|
|
79
|
-
WHEN EXISTS (SELECT 1 FROM pg_type WHERE typname = 'Privacy') THEN '✅'
|
|
80
|
-
ELSE '❌'
|
|
81
|
-
END as "Privacy";
|
|
82
|
-
|
|
83
|
-
-- 6. Check for any foreign key constraint errors
|
|
84
|
-
SELECT
|
|
85
|
-
conname as constraint_name,
|
|
86
|
-
conrelid::regclass as table_name,
|
|
87
|
-
confrelid::regclass as referenced_table
|
|
88
|
-
FROM pg_constraint
|
|
89
|
-
WHERE contype = 'f'
|
|
90
|
-
AND connamespace = 'public'::regnamespace
|
|
91
|
-
LIMIT 10;
|
|
92
|
-
|
|
93
|
-
-- 7. Verify specific columns from November migration
|
|
94
|
-
SELECT
|
|
95
|
-
CASE
|
|
96
|
-
WHEN EXISTS (
|
|
97
|
-
SELECT 1 FROM information_schema.columns
|
|
98
|
-
WHERE table_name = 'Service' AND column_name = 'acceptsBashCash'
|
|
99
|
-
) THEN '✅ Service.acceptsBashCash exists'
|
|
100
|
-
ELSE '❌ Service.acceptsBashCash MISSING'
|
|
101
|
-
END as service_column,
|
|
102
|
-
CASE
|
|
103
|
-
WHEN EXISTS (
|
|
104
|
-
SELECT 1 FROM information_schema.columns
|
|
105
|
-
WHERE table_name = 'User' AND column_name = 'isLightweightAccount'
|
|
106
|
-
) THEN '✅ User.isLightweightAccount exists'
|
|
107
|
-
ELSE '❌ User.isLightweightAccount MISSING'
|
|
108
|
-
END as user_column;
|
|
109
|
-
|
|
110
|
-
-- 8. List all tables (alphabetically)
|
|
111
|
-
SELECT table_name
|
|
112
|
-
FROM information_schema.tables
|
|
113
|
-
WHERE table_schema = 'public'
|
|
114
|
-
AND table_type = 'BASE TABLE'
|
|
115
|
-
ORDER BY table_name;
|
|
116
|
-
|
|
117
|
-
-- ============================================================================
|
|
118
|
-
-- Expected Results
|
|
119
|
-
-- ============================================================================
|
|
120
|
-
--
|
|
121
|
-
-- Query 1: total_tables should be 160+
|
|
122
|
-
-- Query 2: total_enums should be 170+
|
|
123
|
-
-- Query 3: total_indexes should be 400+
|
|
124
|
-
-- Query 4: All columns should show ✅
|
|
125
|
-
-- Query 5: All enums should show ✅
|
|
126
|
-
-- Query 6: Should return 10 foreign keys without errors
|
|
127
|
-
-- Query 7: Both columns should show ✅
|
|
128
|
-
-- Query 8: Should list all your tables alphabetically
|
|
129
|
-
--
|
|
130
|
-
-- If any ❌ appears, the migration may have failed partially
|
|
131
|
-
-- Check postgres logs for errors
|
|
132
|
-
-- ============================================================================
|