Copy and layout improvements.
This commit is contained in:
parent
39eb9e039a
commit
02222a5c16
20 changed files with 464 additions and 652 deletions
|
|
@ -109,8 +109,9 @@ export default defineEventHandler(async (event) => {
|
|||
// Complete ticket purchase (updates sold/reserved counts)
|
||||
await completeTicketPurchase(eventData, ticketInfo.ticketType);
|
||||
|
||||
// Save event with registration
|
||||
await eventData.save();
|
||||
// Save event with registration; skip validators to avoid tripping on
|
||||
// legacy location data unrelated to this write.
|
||||
await eventData.save({ validateBeforeSave: false });
|
||||
|
||||
// Send confirmation email
|
||||
try {
|
||||
|
|
|
|||
|
|
@ -78,7 +78,6 @@ const memberSchema = new mongoose.Schema({
|
|||
|
||||
notifications: {
|
||||
events: { type: Boolean, default: true },
|
||||
updates: { type: Boolean, default: true },
|
||||
},
|
||||
|
||||
inviteEmailSent: { type: Boolean, default: false },
|
||||
|
|
|
|||
|
|
@ -27,8 +27,7 @@ export const memberProfileUpdateSchema = z.object({
|
|||
}).optional(),
|
||||
showInDirectory: z.boolean().optional(),
|
||||
notifications: z.object({
|
||||
events: z.boolean().optional(),
|
||||
updates: z.boolean().optional()
|
||||
events: z.boolean().optional()
|
||||
}).optional(),
|
||||
craftTags: z.array(z.string().max(100)).max(16).optional(),
|
||||
boardSlackHandle: z.string().max(200).optional()
|
||||
|
|
@ -416,3 +415,12 @@ export const adminAlertRestoreSchema = z.object({
|
|||
.min(1)
|
||||
.max(ADMIN_ALERT_TYPES.length)
|
||||
})
|
||||
|
||||
// --- Site content (key/value editable copy blocks) ---
|
||||
|
||||
export const SITE_CONTENT_KEYS = ['homepage.wiki_feature']
|
||||
|
||||
export const siteContentUpsertSchema = z.object({
|
||||
title: z.string().max(300).optional(),
|
||||
body: z.string().max(5000).optional()
|
||||
})
|
||||
|
|
|
|||
|
|
@ -292,7 +292,7 @@ export const releaseTicket = async (event, ticketType) => {
|
|||
);
|
||||
}
|
||||
|
||||
await event.save();
|
||||
await event.save({ validateBeforeSave: false });
|
||||
};
|
||||
|
||||
/**
|
||||
|
|
@ -309,7 +309,7 @@ export const completeTicketPurchase = async (event, ticketType) => {
|
|||
event.tickets.public.sold = (event.tickets.public.sold || 0) + 1;
|
||||
}
|
||||
|
||||
await event.save();
|
||||
await event.save({ validateBeforeSave: false });
|
||||
};
|
||||
|
||||
/**
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue