Skip to content
Snippets Groups Projects
Commit afb512a6 authored by Nimesh Jethva's avatar Nimesh Jethva Committed by Yannick Tivisse
Browse files

[IMP]pos_*: Improvement in model description

Purpose of this commit is to give description more "business oriented"
because those descriptions appears in Odoo Studio which is supposed to be used by end users, not only by developers.

Related Task ID : 37311
parent dae97ee5
No related branches found
No related tags found
No related merge requests found
......@@ -4,7 +4,7 @@ from odoo import api, fields, models, tools, _
class PosCategory(models.Model):
_name = "pos.category"
_description = "PoS Category"
_description = "Point of Sale Category"
_order = "sequence, name"
@api.constrains('parent_id')
......
......@@ -37,6 +37,7 @@ class AccountBankStmtCashWizard(models.Model):
class PosConfig(models.Model):
_name = 'pos.config'
_description = 'Point of Sale Configuration'
def _default_sale_journal(self):
journal = self.env.ref('point_of_sale.pos_sale_journal', raise_if_not_found=False)
......
......@@ -942,7 +942,7 @@ class PosOrder(models.Model):
class PosOrderLine(models.Model):
_name = "pos.order.line"
_description = "Lines of Point of Sale Orders"
_description = "Point of Sale Order Lines"
_rec_name = "product_id"
def _order_line_fields(self, line, session_id=None):
......@@ -1064,6 +1064,7 @@ class PosOrderLineLot(models.Model):
class ReportSaleDetails(models.AbstractModel):
_name = 'report.point_of_sale.report_saledetails'
_description = 'Point of Sale Details'
@api.model
......
......@@ -8,6 +8,7 @@ from odoo.exceptions import UserError, ValidationError
class PosSession(models.Model):
_name = 'pos.session'
_order = 'id desc'
_description = 'Point of Sale Session'
POS_SESSION_STATE = [
('opening_control', 'Opening Control'), # method action_pos_session_open
......
......@@ -7,6 +7,7 @@ from odoo.exceptions import UserError
class PosInvoiceReport(models.AbstractModel):
_name = 'report.point_of_sale.report_invoice'
_description = 'Point of Sale Invoice Report'
@api.model
def _get_report_values(self, docids, data=None):
......
......@@ -6,7 +6,7 @@ from odoo import api, fields, models, tools
class PosOrderReport(models.Model):
_name = "report.pos.order"
_description = "Point of Sale Orders Statistics"
_description = "Point of Sale Orders Report"
_auto = False
_order = 'date desc'
......
......@@ -7,7 +7,7 @@ from odoo.exceptions import UserError
class PosDetails(models.TransientModel):
_name = 'pos.details.wizard'
_description = 'Open Sales Details Report'
_description = 'Point of Sale Details Report'
def _default_start_date(self):
""" Find the earliest start_date of the latests sessions """
......
......@@ -7,7 +7,7 @@ from odoo.exceptions import UserError
class PosOpenStatement(models.TransientModel):
_name = 'pos.open.statement'
_description = 'Open Statements'
_description = 'Point of Sale Open Statement'
@api.multi
def open_statement(self):
......
......@@ -19,6 +19,7 @@ class BarcodeRule(models.Model):
class PosMercuryConfiguration(models.Model):
_name = 'pos_mercury.configuration'
_description = 'Point of Sale Mercury Configuration'
name = fields.Char(required=True, help='Name of this Mercury configuration')
merchant_id = fields.Char(string='Merchant ID', required=True, help='ID of the merchant to authenticate him on the payment provider server')
......
......@@ -14,6 +14,7 @@ from odoo.tools import DEFAULT_SERVER_DATETIME_FORMAT, misc
class MercuryTransaction(models.Model):
_name = 'pos_mercury.mercury_transaction'
_description = 'Point of Sale Mercury Transaction'
def _get_pos_session(self):
pos_session = self.env['pos.session'].search([('state', '=', 'opened'), ('user_id', '=', self.env.uid)], limit=1)
......
......@@ -7,6 +7,7 @@ from odoo import api, fields, models
class RestaurantFloor(models.Model):
_name = 'restaurant.floor'
_description = 'Restaurant Floor'
name = fields.Char('Floor Name', required=True, help='An internal identification of the restaurant floor')
pos_config_id = fields.Many2one('pos.config', string='Point of Sale')
......@@ -19,6 +20,7 @@ class RestaurantFloor(models.Model):
class RestaurantTable(models.Model):
_name = 'restaurant.table'
_description = 'Restaurant Table'
name = fields.Char('Table Name', required=True, help='An internal identification of a table')
floor_id = fields.Many2one('restaurant.floor', string='Floor')
......@@ -54,6 +56,7 @@ class RestaurantTable(models.Model):
class RestaurantPrinter(models.Model):
_name = 'restaurant.printer'
_description = 'Restaurant Printer'
name = fields.Char('Printer Name', required=True, default='Printer', help='An internal identification of the printer')
proxy_ip = fields.Char('Proxy IP Address', help="The IP Address or hostname of the Printer's hardware proxy")
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment