Sale Rental
sale_rental · OCA/vertical-rental
OCA/sale-workflow 8.0–15.0 → OCA/vertical-rental 16.0–18.0
-
Security25/25No findings
-
Activity25/25Last human commit 1 month ago
-
Required by5/250 modules depend on it
-
Maturity25/25In 9 Odoo series since 8.0
Heuristic over the facts below, not an audit · How it's computed
Migration considerations
SaleOrderLine— Migrating to 19.0: `_sql_constraints` is ignored and its constraints are silently not created: declare `models.Constraint` attributes instead. migration-sql-constraints · source
Migration review checklist, not a compatibility verdict. "Migrating to X.0" applies once you upgrade to that version; "Since X.0" means this version already ignores or rejects that code. Methodology
Description
With this module, you can rent products with Odoo. This module supports:
- regular rentals.
- rental extensions.
- sale of rented products.
Dependencies
Code analysis
Extracted from the source by best-effort static analysis (no code is executed); details may be incomplete.
Views touched 12
| XML ID | Name | Model | Type | Status |
|---|---|---|---|---|
create_rental_product_form |
rental.product.product.form | create.rental.product | form | New |
product_normal_form_view |
rental.product.product.form | product.product | form | Inherits product.product_normal_form_view |
product_template_only_form_view |
rental.product.template.only.form | product.template | form | Inherits product.product_template_only_form_view |
res_config_settings_view_form_sale_rental |
res.config.settings.view.form.inherit.sale.stock.sale | res.config.settings | form | Inherits sale.res_config_settings_view_form |
sale_rental_calendar |
sale.rental.calendar | sale.rental | calendar | New |
sale_rental_form |
sale.rental.form | sale.rental | form | New |
sale_rental_graph |
sale.rental.graph | sale.rental | graph | New |
sale_rental_pivot |
sale.rental.pivot | sale.rental | pivot | New |
sale_rental_search |
sale.rental.search | sale.rental | search | New |
sale_rental_tree |
sale.rental.tree | sale.rental | list | New |
view_order_form |
sale_rental.view_order_form | sale.order | form | Inherits sale_start_end_dates.view_order_form |
view_warehouse |
rental.stock.warehouse.form | stock.warehouse | form | Inherits stock.view_warehouse |
HTTP endpoints 0
No HTTP endpoints found for this module.
Models touched 10
-
categ_idMany2one → product.categoryrequired=Truestring='Product Category' args: 'product.category' -
copy_imageBooleanstring='Copy Product Image' -
default_codeChar -
hw_product_idMany2one → product.productreadonly=Truerequired=Truestring='Product to Rent' args: 'product.product' -
nameCharrequired=Truestring='Rental Service Name' -
sale_price_per_dayFloatdefault=1.0digits='Product Price'required=Truestring='Rental Price per Day'
-
create_rental_product(self) -
default_get(self, fields_list)@api.model
-
rental_service_idsOne2many → product.productstring='Related Rental Services' args: 'product.product', 'rented_product_id' -
rented_product_idMany2one → product.productdomain=[('type', '=', 'consu')]string='Related Rented Product' args: 'product.product'
No public methods.
-
rental_service_tmpl_idsOne2many → product.templatestring='Rental Services' args: 'product.template', 'rented_product_tmpl_id' -
rented_product_tmpl_idMany2one → product.templatecompute='_compute_rented_product_tmpl_id'inverse='_inverse_rented_product_tmpl_id'store=Truestring='Rented Product' args: 'product.template'
No public methods.
-
reminder_daysIntegerconfig_parameter='sale_rental.reminder_days'default=3.0string='Rental Reminder Days' -
send_return_reminderBooleanconfig_parameter='sale_rental.send_return_reminder'string='Send Return Reminders'
No public methods.
No new fields.
Public methods (1)-
action_cancel(self)When the user cancels a rental extension, Odoo writes the initial end date on the return picking
-
can_sell_rentalBooleanstring='Can Sell from Rental' -
extension_rental_idMany2one → sale.rentalcheck_company=Truestring='Rental to Extend' args: 'sale.rental' -
rentalBooleandefault=False -
rental_qtyFloatdigits='Product Unit of Measure'help='Indicate the number of items that will be rented.'string='Rental Quantity' -
rental_typeSelectionargs: [('new_rental', 'New Rental'), ('rental_extension', 'Rental Extension')] -
sell_rental_idMany2one → sale.rentalcheck_company=Truestring='Rental to Sell' args: 'sale.rental'
-
extension_rental_id_change(self)@api.onchange('extension_rental_id') -
rental_product_id_change(self)@api.onchange('product_id', 'rental_qty') -
rental_qty_number_of_days_change(self)@api.onchange('rental_qty', 'number_of_days', 'product_id') -
rental_type_change(self)@api.onchange('rental_type') -
sell_rental_id_change(self)@api.onchange('sell_rental_id')
-
company_idMany2one → res.companyrelated='start_order_line_id.company_id'store=Truestring='Company' args: 'res.company' -
end_dateDatecompute='_compute_end_date'help='End Date of the Rental (extensions included), taking into account all the extensions sold to the customer.'store=True -
extension_order_line_idsOne2many → sale.order.linestring='Rental Extensions' args: 'sale.order.line', 'extension_rental_id' -
in_move_idMany2one → stock.movecompute='_compute_move_and_state'store=Truestring='Incoming Move' args: 'stock.move' -
in_picking_idMany2one → stock.pickingrelated='in_move_id.picking_id'string='Receipt' args: 'stock.picking' -
in_stateSelectionrelated='in_move_id.state'string='In Move State' -
out_move_idMany2one → stock.movecompute='_compute_move_and_state'store=Truestring='Outgoing Move' args: 'stock.move' -
out_picking_idMany2one → stock.pickingrelated='out_move_id.picking_id'string='Delivery Order' args: 'stock.picking' -
out_stateSelectionrelated='out_move_id.state'string='Out Move State' -
partner_idMany2one → res.partnerrelated='start_order_line_id.order_id.partner_id'store=Truestring='Customer' args: 'res.partner' -
rental_product_idMany2one → product.productrelated='start_order_line_id.product_id'store=Truestring='Rental Service' args: 'product.product' -
rental_qtyFloatrelated='start_order_line_id.rental_qty'store=True -
rented_product_idMany2one → product.productrelated='start_order_line_id.product_id.rented_product_id'store=Truestring='Rented Product' args: 'product.product' -
sell_move_idMany2one → stock.movecompute='_compute_move_and_state'store=Truestring='Selling Move' args: 'stock.move' -
sell_order_line_idsOne2many → sale.order.linestring='Sell Rented Product' args: 'sale.order.line', 'sell_rental_id' -
sell_picking_idMany2one → stock.pickingrelated='sell_move_id.picking_id'string='Sell Delivery Order' args: 'stock.picking' -
sell_stateSelectionrelated='sell_move_id.state'string='Sell Move State' -
start_dateDatereadonly=Truerelated='start_order_line_id.start_date'store=True -
start_order_idMany2one → sale.orderrelated='start_order_line_id.order_id'store=Truestring='Rental SO' args: 'sale.order' -
start_order_line_idMany2one → sale.order.linereadonly=Truestring='Rental SO Line' args: 'sale.order.line' -
stateSelectioncompute='_compute_move_and_state'store=True args: [('ordered', 'Ordered'), ('out', 'Out'), ('sell_progress', 'Sell in progress'), ('sold', 'Sold'), ('in', 'Back In'), ('cancel', 'Cancelled')]
-
cron_send_return_reminders(self)@api.modelSend reminder emails X days before end_date.
No new fields.
Public methods (1)-
create_demo_and_validate(self)@api.model
No new fields.
Public methods (0)No public methods.
-
rental_allowedBoolean -
rental_in_location_idMany2one → stock.locationcheck_company=Truedomain="[('usage', '=', 'internal'), ('company_id', '=', company_id)]" args: 'stock.location', 'Rental In' -
rental_out_location_idMany2one → stock.locationcheck_company=Truedomain="[('usage', '=', 'internal'), ('company_id', '=', company_id)]" args: 'stock.location', 'Rental Out' -
rental_route_idMany2one → stock.routestring='Rental Route' args: 'stock.route' -
rental_view_location_idMany2one → stock.locationcheck_company=Truedomain="[('usage', '=', 'view'), ('company_id', '=', company_id)]" args: 'stock.location', 'Parent Rental' -
sell_rented_product_route_idMany2one → stock.routestring='Sell Rented Product Route' args: 'stock.route'
-
write(self, vals)
Loading…
Loading…
Loading…
Loading…
Loading…
Loading…
Loading…
Loading…
Loading…