Custom codes
Custom Codes for different purposes
Description
| Field | Description |
|---|---|
| Code Name | |
| Description |
Query Filters
| Field | Description |
|---|---|
| Start date | Start date for the Report / Code |
| End date | End date for the Report / Code |
| Branch |
Programmatic Configuration
| Field | Description |
|---|---|
| Type of Code | Options:
|
| Class/Action name | Options:
|
| Related models | Options:
|
| Custom attributes | To store the values of other attributes that are necessary within the code. To access this dictionary in code: custom_report.custom_attrs.get('attribute_name') |
| Schema for Custom Attributes | To define the scheme of the extra fields. The values of the fields defined here are stored in 'custom_attrs'. Schemas could have the attributes 'label' (text), 'help_text' (text), 'required' (boolean), 'type' (BooleanField, IntegerField, CharField, ChoiceField, etc) and 'choices' (with type ChoiceField). Schemas must be defined in a list, and the key nameof the list must be 'fields' |
| Python code | If it's a Custom Report: you must declare a function called 'get_report()' that returns an instance of type Django File. If it's a Custom Bonus: you must declare a function called 'get_bonus()' that return the class that builds the bonus. If it's a Custom Benefit: you must declare a function called 'get_benefit_value()' that return the 'BenefitValue' class that builds Benefit values. In admin is available: request, custom_report, branch, start_date, end_date. |
Custom codes It has the following related modules and may be of interest to you:
- Branch Offices
- Airports
- Product categories
- Settings per Account
- Social Administrators
- Agreements Social Administrator
- Permissions
- Advertising channels
- Editable forms by account
- Editable forms by company
- Workflows
- Person groups
- People
- Profile
- Numerations
- My Companies
- Personal settings
- Retentions
- Impuestos
- Lock accounting
- Payment methods
- Templates by Company/Account
- Signals
- Custom codes
- Indicators
- Verbose names
- Task progresses
- Customer sync conflicts
- POS floor plans
- Customs Menus
- custom models
- Public Custom Models
- Log entry
- Settings per Company
- Blocked Emails
- Email send logs
- Blocked Cells
- Consecutives
- Vehicles
- Visibility filters
- Products/Services
- Contracts Patterns