Working on better bug fix for downloading export files. Some columns were missing.
This commit is contained in:
@@ -308,7 +308,7 @@ async function handle_download_export__obj_type(
|
||||
log_lvl?: number
|
||||
}
|
||||
) {
|
||||
console.log('*** stores_event_api.js: get_sponsorship_export() ***');
|
||||
console.log('*** ae_core_functions.js: handle_download_export__obj_type() ***');
|
||||
|
||||
const endpoint = `/v2/crud/${get_obj_type}/list`;
|
||||
params['for_obj_type'] = for_obj_type;
|
||||
@@ -319,6 +319,8 @@ async function handle_download_export__obj_type(
|
||||
}
|
||||
params['return_file'] = true;
|
||||
|
||||
params['mdl_alt'] = 'out';
|
||||
|
||||
// let clean_filename = filename.replace(/[^a-z0-9]/gi, '_');
|
||||
// let clean_filename = filename.replace(/[^a-z0-9\[\]-]/gi, '_');
|
||||
let clean_filename = filename.replace(/[^a-zA-Z0-9\[\]-_.]/gi, '_');
|
||||
|
||||
@@ -391,8 +391,8 @@ async function handle_load_ae_obj_id__event_presenter({event_presenter_id, try_c
|
||||
ae_promises.download__events_speakers_export = core_func.handle_download_export__obj_type({
|
||||
api_cfg: $ae_api,
|
||||
get_obj_type: 'event_presenter',
|
||||
for_obj_type: 'account',
|
||||
for_obj_id: $slct.account_id,
|
||||
for_obj_type: 'event',
|
||||
for_obj_id: $slct.event_id,
|
||||
file_type: 'Excel',
|
||||
return_file: true,
|
||||
filename: `${$ae_loc.account_code}_Speakers_Hub_export_${ae_util.iso_datetime_formatter()}.xlsx`,
|
||||
|
||||
@@ -367,7 +367,7 @@ async function handle_load_ae_obj_id__sponsorship({sponsorship_id, try_cache=fal
|
||||
</script>
|
||||
|
||||
|
||||
<section class="ae_events_speakers md:container h-full mx-auto flex flex-col items-center space-y-4">
|
||||
<section class="ae_sponsorships md:container h-full mx-auto flex flex-col items-center space-y-4">
|
||||
|
||||
<header>
|
||||
<h1 class="h1 text-center">
|
||||
@@ -402,7 +402,7 @@ async function handle_load_ae_obj_id__sponsorship({sponsorship_id, try_cache=fal
|
||||
}
|
||||
ae_promises.download__sponsorships_export = core_func.handle_download_export__obj_type({
|
||||
api_cfg: $ae_api,
|
||||
get_obj_type: 'event_presenter',
|
||||
get_obj_type: 'sponsorship',
|
||||
for_obj_type: 'account',
|
||||
for_obj_id: $slct.account_id,
|
||||
file_type: 'Excel',
|
||||
|
||||
Reference in New Issue
Block a user