fix(standardization): apply safe sort padding across all remaining modules
- Hardened 'JournalEntry' and 'Sponsorship' object processors to handle null sort values. - Disabled aggressive pre-loading of archive content in main archives list to improve performance.
This commit is contained in:
@@ -975,14 +975,15 @@ export async function process_ae_obj__journal_entry_props({
|
||||
obj.history_md_html = history_md_html;
|
||||
|
||||
// Journal entry-specific computed sort fields, overriding generic ones if needed
|
||||
const sort_val = (obj.sort ?? 0).toString().padStart(3, '0');
|
||||
obj.tmp_sort_1 = `${obj.group ?? ''}_${obj.priority ? '1' : '0'}_${
|
||||
obj.sort?.toString().padStart(3, '0') ?? ''
|
||||
sort_val
|
||||
}_${obj.updated_on ?? obj.created_on}`;
|
||||
obj.tmp_sort_2 = `${obj.group ?? ''}_${obj.priority ? '1' : '0'}_${
|
||||
obj.sort?.toString().padStart(3, '0') ?? ''
|
||||
sort_val
|
||||
}_${obj.name ?? ''}_${obj.updated_on ?? obj.created_on}`;
|
||||
obj.tmp_sort_3 = `${obj.group ?? ''}_${obj.priority ? '1' : '0'}_${
|
||||
obj.sort?.toString().padStart(3, '0') ?? ''
|
||||
sort_val
|
||||
}_${obj.name ?? ''}_${obj.updated_on ?? obj.created_on}`;
|
||||
|
||||
return obj;
|
||||
|
||||
@@ -44,11 +44,12 @@ export async function process_ae_obj__sponsorship_cfg_props({
|
||||
log_lvl,
|
||||
specific_processor: (obj) => {
|
||||
// Sponsorship Cfg-specific computed sort fields
|
||||
const sort_val = (obj.sort ?? 0).toString().padStart(3, '0');
|
||||
obj.tmp_sort_1 = `${obj.group ?? ''}_${obj.priority ? '1' : '0'}_${
|
||||
obj.sort?.toString().padStart(3, '0') ?? ''
|
||||
sort_val
|
||||
}_${obj.updated_on ?? obj.created_on}`;
|
||||
obj.tmp_sort_2 = `${obj.group ?? ''}_${obj.priority ? '1' : '0'}_${
|
||||
obj.sort?.toString().padStart(3, '0') ?? ''
|
||||
sort_val
|
||||
}_${obj.updated_on}_${obj.created_on}`;
|
||||
|
||||
return obj;
|
||||
@@ -110,11 +111,12 @@ export async function process_ae_obj__sponsorship_props({
|
||||
log_lvl,
|
||||
specific_processor: (obj) => {
|
||||
// Sponsorship-specific computed sort fields
|
||||
const sort_val = (obj.sort ?? 0).toString().padStart(3, '0');
|
||||
obj.tmp_sort_1 = `${obj.group ?? ''}_${obj.priority ? '1' : '0'}_${
|
||||
obj.sort?.toString().padStart(3, '0') ?? ''
|
||||
sort_val
|
||||
}_${obj.updated_on ?? obj.created_on}`;
|
||||
obj.tmp_sort_2 = `${obj.group ?? ''}_${obj.priority ? '1' : '0'}_${
|
||||
obj.sort?.toString().padStart(3, '0') ?? ''
|
||||
sort_val
|
||||
}_${obj.updated_on}_${obj.created_on}`;
|
||||
|
||||
return obj;
|
||||
|
||||
@@ -40,7 +40,7 @@ export async function load({ fetch, params, parent }) {
|
||||
api_cfg: ae_acct.api,
|
||||
for_obj_type: 'account',
|
||||
for_obj_id: account_id,
|
||||
inc_content_li: true,
|
||||
inc_content_li: false,
|
||||
enabled: 'enabled',
|
||||
hidden: 'not_hidden',
|
||||
limit: 29,
|
||||
|
||||
Reference in New Issue
Block a user