fix(prod): sync production prisma schema, fix /testimonials endpoint and lazy routes
Deploy Canina / deploy (push) Has been cancelled
Deploy Canina / deploy (push) Has been cancelled
This commit is contained in:
1 parent
387519ff6b
commit
83dce41715
3 files changed
+5
-4
No files matched your search
@@ -35,6 +35,7 @@ const FinancialSettingsPage = lazy(() => import('../pages/FinancialSettingsPage'
|
||||
const SystemSettingsPage = lazy(() => import('../pages/SystemSettingsPage'));
|
||||
const SmsSettingsPage = lazy(() => import('../pages/SmsSettingsPage'));
|
||||
const SslSettingsPage = lazy(() => import('../pages/SslSettingsPage'));
|
||||
const Transactions = lazy(() => import('../pages/Transactions'));
|
||||
const Tickets = lazy(() => import('../pages/Tickets'));
|
||||
const Reviews = lazy(() => import('../pages/Reviews'));
|
||||
const DoctorsManager = lazy(() => import('../pages/DoctorsManager'));
|
||||
|
||||
@@ -26,7 +26,7 @@ export default function TestimonialsSection() {
|
||||
async function loadTestimonials() {
|
||||
try {
|
||||
setIsLoading(true);
|
||||
const res = await api.get('/cms/testimonials');
|
||||
const res = await api.get('/testimonials');
|
||||
const raw = res.data;
|
||||
const list = Array.isArray(raw?.testimonials)
|
||||
? raw.testimonials
|
||||
|
||||
+3
-3
@@ -84,9 +84,9 @@ if [ "$BRANCH" == "develop" ]; then
|
||||
echo "[STAGING] Running prisma db seed..."
|
||||
docker exec "$CONTAINER_PREFIX" npx prisma db seed || true
|
||||
else
|
||||
# Production: use migrate deploy only — NEVER seed, NEVER use --accept-data-loss
|
||||
echo "[PRODUCTION] Running prisma migrate deploy (safe, no data loss)..."
|
||||
docker exec "$CONTAINER_PREFIX" npx prisma migrate deploy || true
|
||||
# Production: use db push to sync schema additions without data loss
|
||||
echo "[PRODUCTION] Running prisma db push to ensure schema is up to date..."
|
||||
docker exec "$CONTAINER_PREFIX" npx prisma db push --skip-generate || true
|
||||
echo "[PRODUCTION] Seeder skipped to protect production data."
|
||||
fi
|
||||
|
||||
|
||||
Reference in new issue
Block a user