erp5_officejs_support_request_ui: improvements in SupportRequest_getSupportTypeList code
- fix `NoneType` as no attribute `getTitle` (service_obj.getTitle()) ; - use existing variable as most as possible (portal, result) ; - avoid call `getTitle` on the same object in a loop (project.getTitle()) ; - avoid compare projects by title as many projects may have the same ; - avoid using `set` as service id cannot be present twice (set(service_pairs)) ; - optimise catalog request to get project (limit) ; - optimise catalog request to get sale supply (destination_project_uid) ; - rename plurals in variable (service_pairs) ; - rename abbreviations in variable (*_obj) ; - remove trailing spaces.
Showing
Please register or sign in to comment