Moving stuff around to make it more easy to manage
This commit is contained in:
@@ -97,60 +97,61 @@ async def get_account_obj_new(
|
||||
account_id: str = Query(..., min_length=1, max_length=22),
|
||||
enabled: str = 'enabled', # For now this covers any included objects or object lists
|
||||
limit: int = 500, # For now this covers any included objects or object lists
|
||||
inc_account_cfg: bool = False,
|
||||
inc_account_cfg: bool = False, # Priority l1
|
||||
inc_address: bool = False, # Under contact
|
||||
inc_address_list: bool = False,
|
||||
inc_archive: bool = False,
|
||||
inc_archive_list: bool = False,
|
||||
inc_archive_list: bool = False, # Priority l1
|
||||
inc_contact: bool = False,
|
||||
inc_contact_list: bool = False,
|
||||
inc_event: bool = False,
|
||||
inc_event_list: bool = False,
|
||||
inc_event_abstract: bool = False,
|
||||
inc_event_abstract_list: bool = False,
|
||||
inc_event_badge: bool = False,
|
||||
inc_event_badge_list: bool = False,
|
||||
inc_event_list: bool = False, # Priority l1
|
||||
# inc_event_abstract: bool = False,
|
||||
# inc_event_abstract_list: bool = False,
|
||||
# inc_event_badge: bool = False,
|
||||
# inc_event_badge_list: bool = False,
|
||||
inc_event_cfg: bool = False,
|
||||
inc_event_device: bool = False,
|
||||
inc_event_device_list: bool = False,
|
||||
inc_event_exhibit: bool = False,
|
||||
# inc_event_device: bool = False,
|
||||
# inc_event_device_list: bool = False,
|
||||
# inc_event_exhibit: bool = False,
|
||||
inc_event_exhibit_list: bool = False,
|
||||
inc_event_file: bool = False,
|
||||
# inc_event_file: bool = False,
|
||||
inc_event_file_list: bool = False,
|
||||
inc_event_location: bool = False, # For event_session child object
|
||||
# inc_event_location: bool = False, # For event_session child object
|
||||
inc_event_location_list: bool = False,
|
||||
inc_event_person: bool = False,
|
||||
# inc_event_person: bool = False,
|
||||
inc_event_person_list: bool = False,
|
||||
inc_event_presentation: bool = False,
|
||||
# inc_event_presentation: bool = False,
|
||||
inc_event_presentation_list: bool = False,
|
||||
inc_event_presenter_cat: bool = False, # For event_session child object
|
||||
inc_event_presenter: bool = False,
|
||||
# inc_event_presenter_cat: bool = False, # For event_session child object
|
||||
# inc_event_presenter: bool = False,
|
||||
inc_event_presenter_list: bool = False,
|
||||
inc_event_registration: bool = False,
|
||||
# inc_event_registration: bool = False,
|
||||
inc_event_registration_cfg: bool = False,
|
||||
inc_event_registration_list: bool = False,
|
||||
inc_event_session: bool = False,
|
||||
# inc_event_session: bool = False,
|
||||
inc_event_session_list: bool = False,
|
||||
inc_event_track: bool = False, # For event_session child object
|
||||
# inc_event_track: bool = False, # For event_session child object
|
||||
inc_event_track_list: bool = False,
|
||||
inc_fundraising_cfg: bool = False,
|
||||
inc_hosted_file_list: bool = False,
|
||||
inc_journal_list: bool = False,
|
||||
inc_membership: bool = False,
|
||||
# inc_membership: bool = False,
|
||||
inc_membership_cfg: bool = False,
|
||||
inc_membership_list: bool = False,
|
||||
inc_order: bool = False,
|
||||
# inc_order: bool = False,
|
||||
inc_order_list: bool = False,
|
||||
inc_order_cart: bool = False,
|
||||
# inc_order_cart: bool = False,
|
||||
inc_order_cart_list: bool = False,
|
||||
inc_organization: bool = False,
|
||||
inc_organization_list: bool = False,
|
||||
inc_person: bool = False,
|
||||
inc_person_list: bool = False,
|
||||
inc_post: bool = False,
|
||||
inc_post_list: bool = False,
|
||||
inc_product: bool = False,
|
||||
# inc_post: bool = False,
|
||||
inc_post_list: bool = False, # Priority l1
|
||||
# inc_product: bool = False,
|
||||
inc_product_list: bool = False,
|
||||
inc_site: bool = False,
|
||||
# inc_site: bool = False,
|
||||
inc_site_list: bool = False,
|
||||
inc_user: bool = False,
|
||||
inc_user_list: bool = False,
|
||||
@@ -177,47 +178,51 @@ async def get_account_obj_new(
|
||||
inc_contact_list=inc_contact_list,
|
||||
inc_event=inc_event,
|
||||
inc_event_list=inc_event_list,
|
||||
inc_event_abstract_list=inc_event_abstract_list,
|
||||
inc_event_badge_list=inc_event_badge_list,
|
||||
inc_event_device_list=inc_event_device_list,
|
||||
# inc_event_abstract_list=inc_event_abstract_list,
|
||||
# inc_event_badge_list=inc_event_badge_list,
|
||||
# inc_event_device_list=inc_event_device_list,
|
||||
inc_event_file_list=inc_event_file_list,
|
||||
inc_event_location=inc_event_location,
|
||||
inc_event_person=inc_event_person,
|
||||
# inc_event_location=inc_event_location,
|
||||
# inc_event_person=inc_event_person,
|
||||
inc_event_person_list=inc_event_person_list,
|
||||
inc_event_presentation_list=inc_event_presentation_list,
|
||||
inc_event_presenter_cat=inc_event_presenter_cat,
|
||||
# inc_event_presenter_cat=inc_event_presenter_cat,
|
||||
inc_event_presenter_list=inc_event_presenter_list,
|
||||
inc_event_registration_list=inc_event_registration_list,
|
||||
inc_event_track=inc_event_track,
|
||||
inc_event_session_list=inc_event_session_list,
|
||||
# inc_event_track=inc_event_track,
|
||||
inc_event_track_list=inc_event_track_list,
|
||||
inc_fundraising_cfg=inc_fundraising_cfg,
|
||||
inc_hosted_file_list=inc_hosted_file_list,
|
||||
inc_journal_list=inc_journal_list,
|
||||
inc_membership=inc_membership,
|
||||
# inc_membership=inc_membership,
|
||||
inc_membership_cfg=inc_membership_cfg,
|
||||
inc_membership_list=inc_membership_list,
|
||||
inc_order=inc_order,
|
||||
# inc_order=inc_order,
|
||||
inc_order_list=inc_order_list,
|
||||
inc_order_cart=inc_order_cart,
|
||||
# inc_order_cart=inc_order_cart,
|
||||
inc_order_cart_list=inc_order_cart_list,
|
||||
inc_organization=inc_organization,
|
||||
inc_organization_list=inc_organization_list,
|
||||
inc_person=inc_person,
|
||||
inc_person_list=inc_person_list,
|
||||
inc_post=inc_post,
|
||||
# inc_post=inc_post,
|
||||
inc_post_list=inc_post_list,
|
||||
inc_product=inc_product,
|
||||
# inc_product=inc_product,
|
||||
inc_product_list=inc_product_list,
|
||||
inc_site=inc_site,
|
||||
# inc_site=inc_site,
|
||||
inc_site_list=inc_site_list,
|
||||
inc_user=inc_user,
|
||||
inc_user_list=inc_user_list,
|
||||
):
|
||||
account_dict = account_obj.dict(by_alias=by_alias, exclude_unset=exclude_unset)
|
||||
pass
|
||||
if isinstance(account_obj, Account_Base):
|
||||
response_data = account_obj.dict(by_alias=by_alias, exclude_unset=exclude_unset) # pylint: disable=no-member
|
||||
else:
|
||||
response_data = account_obj
|
||||
else:
|
||||
return mk_resp(data=False, status_code=400) # Bad Request
|
||||
|
||||
return mk_resp(data=account_dict)
|
||||
return mk_resp(data=response_data)
|
||||
#return mk_resp(data=account_obj)
|
||||
# ### END ### API Account ### get_account_obj() ###
|
||||
|
||||
|
||||
Reference in New Issue
Block a user