Overview
Several apps from the same publisher need the same helper code, so it is placed in one base module. This one installs itself automatically and adds utilities for cron triggering, e-mail sending, view validation, image download by URL and session info. It has no business menus of its own. Developers and administrators benefit from one shared foundation instead of duplicated code.
Usage steps
- 1
Automatic installation
The module installs as a dependency of other apps and runs pre-init, post-init and uninstall hooks. No screen is needed from the user.
- auto_install
- Hooks in hooks.py
- Depends on mail and web
- 2
Run a scheduled action directly
ir.cron gets a Last Trigger User field and a method method_direct_trigger. The list view of scheduled actions is extended so admins can trigger jobs and see who did.
- Field: Last Trigger User
- Manual run from the list
- 3
Shared helpers
The base model gains helpers such as get_image_from_url and get_ua_type, and controllers offer user agent detection and a distance calculation.
- Image from URL
- User agent type
- Haversine distance
- 4
Mail and view services
The mail server send_email, mail.mail and ir.ui.view are extended, including a relaxed view validation function used by dependent apps.
- ir.mail_server extension
- View schema check
- 5
Session info and import
The session_info response is extended for dependent apps, and app_quick_import lets modules load data files quickly.
- ir.http session_info
- Quick data import
Screens
Illustrative mockups with placeholder data.
Roles
| Role |
|---|
| System administrator |
| Developer |
Dependencies
Want to know more or try this app? Contact us
We can arrange a demo or a trial and answer your questions about Common Functions Core.