InvoiceItem
InvoiceItem DocType definition.
Attributes: name: Unique identifier for this InvoiceItem.Source: doctype.py
Fields
Section titled “Fields”| Field | Type | Required | Description | Validators |
|---|---|---|---|---|
| item | Link | Linked Item ID | - | |
| item_name | None | Item Name | - | |
| qty | Decimal | Quantity | - | |
| rate | Decimal | Rate per unit | - | |
| amount | Decimal | Amount (qty * rate) | - | |
| tax_rate | Decimal | Tax Rate % | - | |
| tax_amount | Decimal | Tax Amount | - | |
| sac_code | None | SAC Code | - | |
| igst_rate | Decimal | IGST Rate % | - | |
| igst_amount | Decimal | IGST Amount | - | |
| warehouse | None | Warehouse ID | - | |
| indented_qty | Decimal | What customer asked for | - | |
| issued_qty | Decimal | What was given | - | |
| classification | None | Substitute, Denial, ForcedSale, Normal | - | |
| original_item | None | What they originally wanted | - | |
| denied_qty | Decimal | indented - issued (if no substitute) | - | |
| substituted_qty | Decimal | if substitute given | - | |
| forced_qty | Decimal | if forced sale | - |
Permissions
Section titled “Permissions”| Role | Create | Delete | Read | Write |
|---|---|---|---|---|
| All | ✓ | ✓ | ✓ | ✓ |
Configuration
Section titled “Configuration”| Setting | Value |
|---|---|
| Submittable | False |
| Track Changes | True |
Controller
Section titled “Controller”Controller hooks are implemented in *_controller.py files.
Available lifecycle hooks:
validate()- Called before save, raise exceptions for validation errorsbefore_insert()- Called before inserting a new documentafter_insert()- Called after successfully insertingbefore_save()- Called before saving (insert or update)after_save()- Called after savingbefore_delete()- Called before deletingafter_delete()- Called after deleting