Giter Site home page Giter Site logo

commission's Introduction

Runboat Pre-commit Status Build Status codecov Translation Status

commission

TODO: add repo description.

Available addons

addon version maintainers summary
account_commission 15.0.3.3.0 pedrobaeza Account commissions
commission 15.0.3.2.0 pedrobaeza Commissions
commission_formula 15.0.1.0.0 Commissions computed by formulas
hr_commission 15.0.1.0.1 HR commissions
sale_commission 15.0.2.1.1 pedrobaeza Sales commissions
sale_commission_salesman 15.0.1.0.1 Sales commissions from salesman

Licenses

This repository is licensed under AGPL-3.0.

However, each module can have a totally different license, as long as they adhere to Odoo Community Association (OCA) policy. Consult each module's __manifest__.py file, which contains a license key that explains its license.


OCA, or the Odoo Community Association, is a nonprofit organization whose mission is to support the collaborative development of Odoo features and promote its widespread use.

commission's People

Contributors

anasuarez1 avatar aungkokolin1997 avatar chienandalu avatar elbati avatar ernesto-garcia-tecnativa avatar etobella avatar francesco-ooops avatar ibuioli avatar ivorra78 avatar jabelchi avatar jguenat avatar joao-p-marques avatar liweijie0812 avatar luis-ron avatar marcelsavegnago avatar oca-git-bot avatar oca-transbot avatar oca-travis avatar oihane avatar pedrobaeza avatar pedrocasi avatar primes2h avatar rgarnau avatar ryoko04 avatar sbidoul avatar sergio-teruel avatar simorubi avatar sinerkiaid avatar weblate avatar yostashiro avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

commission's Issues

Commission for First time Purchase

Some companies will give commissions to their agents only for the first time purchase. I suggest you add a check when calculating the base commission. Is this something you would consider adding?

commission for employee

I have looked at the commissions video and it is done for an external (not an employee) agent. When I tried an employee agent it asked for a partner and continued as if the agent is not an employee. How does it work for an employee agent?

[sale_commission] V10 bug

There is a bug in combination of the project_issue module. If I install sale_commission and then project_issue I get the following error:

  File "/opt/odoo/odoo-server10/odoo/sql_db.py", line 231, in execute
    res = self._obj.execute(query, params)
ProgrammingError: foreign key constraint "res_partner_commission_fkey" cannot be implemented
DETAIL:  Key columns "commission" and "id" are of incompatible types: double precision and integer.

If I install project_issue first then it is fine.

Error installing sales_co....

Hello,

When installing Im getting:

openerp.addons.base.ir.ir_ui_view: El elemento '' no puede ser localizado en la vista padre

Error de contexto:
Vista account.invoice.form.agent
[view_id: 1552, xml_id: n/a, model: account.invoice, parent_id: 470]" while parsing /home/singleroot/erp-prod/odoo/addons/sale_commission/views/account_invoice_view.xml:29, near

account.invoice.form.agent
account.invoice



{'partner_id': partner_id}









Refund invoices settlements should be 'negative'

Even though account.invoice.commission_total is correct (ie: $ -10), when settling the sale.commission.settlement is incorrect (positive sign --> ie: $ 10), hence paying the agent twice for something it shouldn't have been paid.

Error when Agent is Clicked

Hi,
I get this error below when i click on an agent.
Traceback (most recent call last):
File "/usr/lib/python2.7/dist-packages/openerp/http.py", line 537, in _handle_exception
return super(JsonRequest, self)._handle_exception(exception)
File "/usr/lib/python2.7/dist-packages/openerp/http.py", line 574, in dispatch
result = self._call_function(*_self.params)
File "/usr/lib/python2.7/dist-packages/openerp/http.py", line 310, in _call_function
return checked_call(self.db, *args, *_kwargs)
File "/usr/lib/python2.7/dist-packages/openerp/service/model.py", line 118, in wrapper
return f(dbname, _args, *_kwargs)
File "/usr/lib/python2.7/dist-packages/openerp/http.py", line 307, in checked_call
return self.endpoint(_a, *_kw)
File "/usr/lib/python2.7/dist-packages/openerp/http.py", line 803, in call
return self.method(_args, *_kw)
File "/usr/lib/python2.7/dist-packages/openerp/http.py", line 403, in response_wrap
response = f(_args, *_kw)
File "/opt/odoo1/odoo/addons/web/controllers/main.py", line 944, in call_kw
return self._call_kw(model, method, args, kwargs)
File "/opt/odoo1/odoo/addons/web/controllers/main.py", line 936, in _call_kw
return getattr(request.registry.get(model), method)(request.cr, request.uid, _args, *_kwargs)
File "/usr/lib/python2.7/dist-packages/openerp/api.py", line 250, in wrapper
return old_api(self, _args, *_kwargs)
File "/usr/lib/python2.7/dist-packages/openerp/models.py", line 3143, in read
result = BaseModel.read(records, fields, load=load)
File "/usr/lib/python2.7/dist-packages/openerp/api.py", line 248, in wrapper
return new_api(self, _args, *_kwargs)
File "/usr/lib/python2.7/dist-packages/openerp/models.py", line 3189, in read
values[name] = field.convert_to_read(record[name], use_name_get)
File "/usr/lib/python2.7/dist-packages/openerp/fields.py", line 1572, in convert_to_read
return value_sudo.name_get()[0]
File "/usr/lib/python2.7/dist-packages/openerp/api.py", line 248, in wrapper
return new_api(self, _args, *_kwargs)
File "/usr/lib/python2.7/dist-packages/openerp/models.py", line 1672, in name_get
result.append((record.id, convert(record[name], record)))
File "/usr/lib/python2.7/dist-packages/openerp/models.py", line 5637, in getitem
return self._fields[key].get(self, type(self))
File "/usr/lib/python2.7/dist-packages/openerp/fields.py", line 819, in get
self.determine_value(record)
File "/usr/lib/python2.7/dist-packages/openerp/fields.py", line 912, in determine_value
record._prefetch_field(self)
File "/usr/lib/python2.7/dist-packages/openerp/api.py", line 248, in wrapper
return new_api(self, _args, *_kwargs)
File "/usr/lib/python2.7/dist-packages/openerp/models.py", line 3241, in _prefetch_field
result = records.read(list(fnames), load='_classic_write')
File "/usr/lib/python2.7/dist-packages/openerp/api.py", line 248, in wrapper
return new_api(self, _args, *_kwargs)
File "/usr/lib/python2.7/dist-packages/openerp/models.py", line 3178, in read
self._read_from_database(stored, inherited)
File "/usr/lib/python2.7/dist-packages/openerp/api.py", line 248, in wrapper
return new_api(self, _args, *_kwargs)
File "/usr/lib/python2.7/dist-packages/openerp/models.py", line 3310, in _read_from_database
cr.execute(query_str, [tuple(sub_ids)] + where_params)
File "/usr/lib/python2.7/dist-packages/openerp/sql_db.py", line 158, in wrapper
return f(self, _args, *_kwargs)
File "/usr/lib/python2.7/dist-packages/openerp/sql_db.py", line 234, in execute
res = self._obj.execute(query, params)
ProgrammingError: column sale_commission.invoice_state does not exist
LINE 1: ...ion"."write_date","sale_commission"."create_date","sale_comm...

Invoice line view becomes 'messy' when "Agents & Commissions" clicked

Hi @pedrobaeza, FYI, my invoice line view become like this (image attached) in draft invoice (from sale process), as standard practice for me when I want to confirm some invoices, I need to make sure the information is correct. So when I clicked on 'Agents & Commissions' columns in invoice line, the view become quite messy like this.
Thank you.

tree_view_invoice_commission

commission in invoice not set

If you switch the workflow from
Sales Order -> Invoice
to
Sales Order -> Delivery -> Invoice
the commission in the invoice is not set if in the sales order a commission is set.

Agents on invoice when invoicing from picking

Hi,

Just tested the module sale_commissions, it works nice, but there are too little questions i'd like to ask.

  1. Is there any way to reflect the agents in the invoice when a sale order is invoiced from picking? At the moment I think this is something the module should do (maybe it really does, but for me it is not working, should I configurate something?)
  2. Is there any kind of way to see/print a report of settlements without executing the "Settle commission" option? The problem here is that if you settle commissions before the end of the month, it won't increment the actual created settlement's amount in the agent data if you execute it again later...

Commission for Odoo v8?

I am interested in a module for Odoo Version 8 which I can use to allocate sales commission to agents who introduce customers. It looks like this could be the place to find it - is anyone working on it or have plans to do so in the near future?
Many thanks, Gill

I can't make settlements

I am in the group Sales Manager. When I try to make new Settlements, and I have done some sales orders, I find this warning:

image

I think Group Sales Manager must have all Access Rights to the object sale.commission.settlement.line.

Get in agent invoice in purchase the origin client invoice number

Hello

Just a question to upgrade the module. How to add in agent invoice the client invoice number ?

In settlement.py we have function prepare_invoice_header

def _prepare_invoice_header(self, settlement, journal, date=False): invoice_obj = self.env['account.invoice'] invoice_vals = { 'partner_id': settlement.agent.id, 'type': ('in_invoice' if journal.type == 'purchase' else 'in_refund'), 'date_invoice': date, 'journal_id': journal.id, 'company_id': self.env.user.company_id.id, 'state': 'draft', }

after 'state': 'draft',

Can we add something like 'origin': invoice.id or invoice.number ??

[BUG?] Editing the commision will recalculate all previous agent lines and settlements.

Editing a sale.commission that's already in use will trigger an update on every existing invoice, sale order, and settlements that were using that commission "rule".

This is because of @api.depends:

    @api.depends('commission.commission_type', 'invoice_line.price_subtotal',
                 'commission.amount_base_type')
    def _compute_amount(self):

I think this could cause consistency errors.

IMO, settled invoices's commissions (agent lines) should remain unchanged, even if the sale.commission percentage / formula / rule changes.

One could argue that it shouldn't even change on unsettled invoices / sale orders. IE: If an agent renegotiates it's commission percentage, the change should apply on new sales, not previous ones.. even if they are not settled yet.

What do you think?

Should we remove 'commission.commission_type' and 'commission.amount_base_type' from the @api.depends?

Commission based on product category

Hi,
I have a customer who has commission based on product category.
Would you welcome a PR or new module that would define a percentage on product category and set the commission type "Product Category based"?
Thanks for your feedback

error in form view sales_order with unit of measure

@pedrobaeza
When add 3th line in a sale quotation I recibe following errors:

commision1

And next when try again:

commision2

I've tried uninstalling other modules that affected the view and the error still occurs.

More info: if I remove Agent form customer sheet and create a new quotation this error does not occur.

P.D. to reproduce this error you must add at least 3 lines in the quotation

I can't seem to get the sales commision to work and settle Agents

I've installed this module, created a sales order and attached an agent to the sales order however when i try to make settlements no invoice gets raised. in fact nothing happens at all the dialog just dis appears. i also did a little investigation, the "settle commissions" and "make settlements" button are linked to the wizard/wizard_settle.py which is a TransientModel and is not going to be persisted to the database (if the module works at all the invoice should be created i should be able to see the commission summary when i view the agent at least for some time before odoo cleans it up, but i don't see anything)

i think I'm missing something about how this module should be installed

please can i get a definitive guide on how i can setup this module for the simplest use case to see that it actually makes commissions and raises invoices

Steps to 'Make it totally multi-company aware.' (it's in the roadmap)

Our business is using a two-company enviorment.

We need to settle commissions from sales of the 2 companies, but create the invoice only in one of them.

I intend to develop this feature, and since I'm at it, I'd like to know your thoughts/needs regarding what should be implemented to make this module 'totally multi-company aware'.

Should the settlement wizard ask the company of the sales to settle?
For instance, settle only invoices from company A.
Or add an option to settle invoices from all companies, or maybe select which companies (Many2Many)

Should the invoice wizard allow to..
A)..make settlement invoices in the company where the sale was invoiced?
B)..same as above, but selecting which companies' settlements to invoice
C)..make all settlement invoices in a selected company? (fyi, this is what I need)

Some terms are not being translated

Some terms like Net Amount, Gross Amount are not being translated.
They are not in the .pot file.

I've tried exporting the language file from Settings -> Translations -> Import / Export -> Export Translation but it seems it also adds some terms that are not of this module, so I don't know if it's reliable.

What's the proper way to generate and/or update them?

Problem with supplier invoice number

Hello

I have a problem with supplier invoice number. When i generate invoices from settlements, supplier invoice number is the same that client invoice number.

Do i something wrong ?

Access error. Document type: res.users on res.partner form

After installing the modules: sale_commission, hr_commission and sale_stock_commission:
When first accessing a partner, everything goes ok. But after trying to update a partner, I'm no longer able to access it.
I've tried modifying the users group permissions to specifically allow access to the res_users relation.
Tried also adding the sales groups, like "managers" or "see your leads" directly into the groups tab on the view_partner_form_agent_hr definition.
And at the end, disabled some security rules that might be on the way.
But still, nothing, still can't access partners.

Only Administrator can access the partners now.
I'm on a multi company environment.

Commission for employee

Hello Ecosystem

Can we use this module to pay commission to employees?

Is there another method of doing that?

Thank you
Theo

TypeError: Cannot read property 'constructor' of undefined

sale_commission_error
I am using "sale_commission" module for manage sales commission to sales team https://www.odoo.com/apps/modules/8.0/sale_commission/, when I am creating a sale order all work fine till I try to add sale order line whith a different product than before line.

May you help me?
Thanks very much : ]

Odoo V: 8.0.2

This is the trace:

TypeError: Cannot read property 'constructor' of undefined
at wrap_context (https://moogo.co/web/js/web.assets_backend/1efc6a0:2918:7)
at https://moogo.co/web/js/web.assets_backend/1efc6a0:2921:127
at Array.reduce (native)
at Function..reduce..foldl..inject (https://moogo.co/web/js/web.assets_common/87b133b:11:564)
at .(anonymous function) as reduce
at eval_contexts (https://moogo.co/web/js/web.assets_backend/1efc6a0:2919:175)
at https://moogo.co/web/js/web.assets_backend/1efc6a0:2921:253
at Array.reduce (native)
at Function.
.reduce.
.foldl._.inject (https://moogo.co/web/js/web.assets_common/87b133b:11:564)
at _.(anonymous function) as reduce
at eval_contexts (https://moogo.co/web/js/web.assets_backend/1efc6a0:2919:175)instance.web.FormView.instance.web.View.extend._process_save @ 1efc6a0:3564(anonymous function) @ 1efc6a0:3549(anonymous function) @ 87b133b:249fire @ 87b133b:243self.fireWith @ 87b133b:248(anonymous function) @ 87b133b:251fire @ 87b133b:243self.fireWith @ 87b133b:248self.fire @ 87b133b:249(anonymous function) @ 87b133b:1145fire @ 87b133b:243self.fireWith @ 87b133b:248self.fire @ 87b133b:249fire @ 87b133b:243self.add @ 87b133b:244(anonymous function) @ 87b133b:249fire @ 87b133b:243self.fireWith @ 87b133b:248(anonymous function) @ 87b133b:249fire @ 87b133b:243self.fireWith @ 87b133b:248self.fire @ 87b133b:249(anonymous function) @ 87b133b:1093(anonymous function) @ 87b133b:249fire @ 87b133b:243self.fireWith @ 87b133b:248self.fire @ 87b133b:249fire @ 87b133b:243self.fireWith @ 87b133b:248(anonymous function) @ 87b133b:249fire @ 87b133b:243self.fireWith @ 87b133b:248(anonymous function) @ 87b133b:249fire @ 87b133b:243self.fireWith @ 87b133b:248done @ 87b133b:682callback @ 87b133b:735
87b133b:730 POST https://moogo.co/longpolling/poll net::ERR_EMPTY_RESPONSEsend @ 87b133b:730jQuery.extend.ajax @ 87b133b:700(anonymous function) @ 87b133b:1122genericJsonRpc @ 87b133b:1120openerp.jsonRpc @ 87b133b:1122(anonymous function) @ 87b133b:1134(anonymous function) @ 87b133b:249fire @ 87b133b:243self.add @ 87b133b:244(anonymous function) @ 87b133b:249jQuery.extend.each @ 87b133b:225(anonymous function) @ 87b133b:249jQuery.extend.Deferred @ 87b133b:250promise.then @ 87b133b:249openerp.Session.openerp.Class.extend.rpc @ 87b133b:1131bus.Bus.openerp.Widget.extend.poll @ 1efc6a0:4040(anonymous function) @ 1efc6a0:4040(anonymous function) @ 87b133b:249fire @ 87b133b:243self.fireWith @ 87b133b:248self.fire @ 87b133b:249fire @ 87b133b:243self.fireWith @ 87b133b:248(anonymous function) @ 87b133b:249fire @ 87b133b:243self.fireWith @ 87b133b:248(anonymous function) @ 87b133b:249fire @ 87b133b:243self.fireWith @ 87b133b:248done @ 87b133b:682callback @ 87b133b:735

How to run settlement

Hi everyone,

I just found and tested this module. I know this module still in development but I just lost the flow.
How do I run commission settlement after I have done register payment for that invoice.
In that invoice line "Agent and commissions"s column, it shows there is a record.
Then how do I want to process payment for that agent?

Sorry for my english. Thank you. :)

Multi-lines commissions

This is to inform that we are working on improving the sale_commission module to allow to define multiple commissions on one agent.

For example, an agent can get 5% commission on his sales (his customers) in addition to 1% on the whole company sales.

The result should look like this:
agents - odoo 2015-07-16 14-07-14

Create commission invoices don't work

If I don't "Add an item" when I create commission invoices, any Invoices were created, although there is a message that says "keep empty for invoicing all the settlements".

install problem with 8.0.3.0.0

module: sale_commission
version: 8.0.3.0.0

Steps to reproduce

  • upload addon
  • clean all cookie and cache of browser
  • update modules
  • install

Current behavior
Odoo Server Error
Traceback (most recent call last):
File "/opt/odoo/openerp/http.py", line 544, in _handle_exception
return super(JsonRequest, self)._handle_exception(exception)
File "/opt/odoo/openerp/http.py", line 581, in dispatch
result = self._call_function(*_self.params)
File "/opt/odoo/openerp/http.py", line 317, in _call_function
return checked_call(self.db, *args, *_kwargs)
File "/opt/odoo/openerp/service/model.py", line 118, in wrapper
return f(dbname, _args, *_kwargs)
File "/opt/odoo/openerp/http.py", line 314, in checked_call
return self.endpoint(_a, *_kw)
File "/opt/odoo/openerp/http.py", line 810, in call
return self.method(_args, *_kw)
File "/opt/odoo/openerp/http.py", line 410, in response_wrap
response = f(_args, *_kw)
File "/opt/odoo/addons/web/controllers/main.py", line 948, in call_button
action = self._call_kw(model, method, args, {})
File "/opt/odoo/addons/web/controllers/main.py", line 936, in _call_kw
return getattr(request.registry.get(model), method)(request.cr, request.uid, _args, *_kwargs)
File "/opt/odoo/openerp/api.py", line 268, in wrapper
return old_api(self, _args, *_kwargs)
File "/opt/odoo/openerp/addons/base/module/module.py", line 447, in button_immediate_install
return self._button_immediate_function(cr, uid, ids, self.button_install, context=context)
File "/opt/odoo/openerp/api.py", line 268, in wrapper
return old_api(self, _args, *_kwargs)
File "/opt/odoo/openerp/addons/base/module/module.py", line 495, in _button_immediate_function
registry = openerp.modules.registry.RegistryManager.new(cr.dbname, update_module=True)
File "/opt/odoo/openerp/modules/registry.py", line 370, in new
openerp.modules.load_modules(registry._db, force_demo, status, update_module)
File "/opt/odoo/openerp/modules/loading.py", line 355, in load_modules
loaded_modules, update_module)
File "/opt/odoo/openerp/modules/loading.py", line 255, in load_marked_modules
loaded, processed = load_module_graph(cr, graph, progressdict, report=report, skip_modules=loaded_modules, perform_checks=perform_checks)
File "/opt/odoo/openerp/modules/loading.py", line 176, in load_module_graph
_load_data(cr, module_name, idref, mode, kind='data')
File "/opt/odoo/openerp/modules/loading.py", line 118, in _load_data
tools.convert_file(cr, module_name, filename, idref, mode, noupdate, kind, report)
File "/opt/odoo/openerp/tools/convert.py", line 900, in convert_file
convert_xml_import(cr, module, fp, idref, mode, noupdate, report)
File "/opt/odoo/openerp/tools/convert.py", line 986, in convert_xml_import
obj.parse(doc.getroot(), mode=mode)
File "/opt/odoo/openerp/tools/convert.py", line 852, in parse
self._tags[rec.tag](self.cr, rec, n, mode=mode)
File "/opt/odoo/openerp/tools/convert.py", line 762, in _tag_record
id = self.pool['ir.model.data']._update(cr, self.uid, rec_model, self.module, res, rec_id or False, not self.isnoupdate(data_node), noupdate=self.isnoupdate(data_node), mode=self.mode, context=rec_context )
File "/opt/odoo/openerp/api.py", line 268, in wrapper
return old_api(self, _args, *_kwargs)
File "/opt/odoo/openerp/addons/base/ir/ir_model.py", line 1069, in _update
res_id = model_obj.create(cr, uid, values, context=context)
File "/opt/odoo/openerp/api.py", line 268, in wrapper
return old_api(self, _args, *_kwargs)
File "/opt/odoo/openerp/addons/base/ir/ir_ui_view.py", line 257, in create
context=context)
File "/opt/odoo/openerp/api.py", line 268, in wrapper
return old_api(self, _args, *_kwargs)
File "/opt/odoo/openerp/api.py", line 372, in old_api
result = method(recs, _args, *_kwargs)
File "/opt/odoo/openerp/models.py", line 4100, in create
record = self.browse(self._create(old_vals))
File "/opt/odoo/openerp/api.py", line 266, in wrapper
return new_api(self, _args, *_kwargs)
File "/opt/odoo/openerp/api.py", line 508, in new_api
result = method(self._model, cr, uid, _args, *_old_kwargs)
File "/opt/odoo/openerp/models.py", line 4297, in _create
recs._validate_fields(vals)
File "/opt/odoo/openerp/api.py", line 266, in wrapper
return new_api(self, _args, *_kwargs)
File "/opt/odoo/openerp/models.py", line 1271, in _validate_fields
raise ValidationError('\n'.join(errors))
ParseError: "ValidateError
Field(s) arch 违反约束(against a constraint): Invalid view definition

详细错误(Detailed Error)
Field agents does not exist

Error context:
View res.partner.form.agent
[view_id: 3437, xml_id: n/a, model: res.partner, parent_id: 126]" while parsing /opt/odoo/addons/sale_commission/views/res_partner_view.xml:5, near

...

Expected behavior
But on my new fresh test environment, there is no problem with installation. How can I find the reason of this problem? thanks!

Flow chart to settle and invoice commissions please?

Hello,

sale_commission

This looks a brilliant module but not all of us can read through the code or know python.

Is there a clear step by step flow chart on how to start with an invoice, add commission agent on the line and end up paying the agent?

I have many invoices, and now that it is time to settle the payments (year closure) I get zero as settled amounts for all agents.

I tried in the lab with agent=user=supplier or agent=user or agent=supplier and in all cases agent!=employee

Thank you very much.

Single invoice for all settlements?

It would be really convenient to have the option to invoice all open settlements in a single invoice.

Maybe it can be done via journal entries, or it has been explained in other git reports, however I did not find it.

Apologies in advance if this is a duplicate.

Field `commission_id` does not exist

module: sale_commission
version: 8.0

Steps to reproduce

  • I'm not really sure about this... I installed Etherpad + mysql, rebooted the server and did get this error with the sale_commission module. I tried to uninstall it and reinstall it with no chance, then tried to update it with no chance as well. I'm pretty sure there is no relationship with the Etherpad install.

Current behavior
I have the following errors that prevents me from accessing to Odoo and that loops.

2015-06-09 13:48:14,480 5306 ERROR datapro openerp.addons.base.ir.ir_ui_view: Field commission_id does not exist

Error context:
View res.partner.form.agent
[view_id: 2818, xml_id: sale_commission.view_partner_form_agent, model: res.partner, parent_id: 126]
2015-06-09 13:48:14,481 5306 ERROR datapro openerp.http: Exception during JSON request handling.
Traceback (most recent call last):
File "/home/odoo/newOCBtest/openerp/http.py", line 530, in _handle_exception
return super(JsonRequest, self)._handle_exception(exception)
File "/home/odoo/newOCBtest/openerp/http.py", line 1399, in _dispatch_nodb
func, arguments = self.nodb_routing_map.bind_to_environ(request.httprequest.environ).match()
File "/usr/lib/python2.7/dist-packages/werkzeug/routing.py", line 1423, in match
raise NotFound()
NotFound: 404: Not Found

Expected behavior
Well...

[commision odoo 9] error after installing module

After installing the module, I can't create a procuct. This error appears:

Error: Campo desconocido cost_method en el dominio ["&",["valuation","=","real_time"],["cost_method","in",["standard","average"]]]

http://192.168.17.123:8069/web/content/431-4a157d1/web.assets_backend.js:3223
Traceback:
compute_domain@http://192.168.17.123:8069/web/content/431-4a157d1/web.assets_backend.js:3223:42
compute_domain@http://192.168.17.123:8069/web/content/431-4a157d1/web.assets_backend.js:3598:339
process_modifiers@http://192.168.17.123:8069/web/content/431-4a157d1/web.assets_backend.js:3639:41
trigger@http://192.168.17.123:8069/web/content/246-167c2f0/web.assets_common.js:2614:166
trigger@http://192.168.17.123:8069/web/content/246-167c2f0/web.assets_common.js:2616:636
on_form_changed@http://192.168.17.123:8069/web/content/431-4a157d1/web.assets_backend.js:3549:68
load_record/<@http://192.168.17.123:8069/web/content/431-4a157d1/web.assets_backend.js:3546:1
then/</</<@http://192.168.17.123:8069/web/content/246-167c2f0/web.assets_common.js:650:678
fire@http://192.168.17.123:8069/web/content/246-167c2f0/web.assets_common.js:644:281
add@http://192.168.17.123:8069/web/content/246-167c2f0/web.assets_common.js:645:467
then/</<@http://192.168.17.123:8069/web/content/246-167c2f0/web.assets_common.js:650:631
each@http://192.168.17.123:8069/web/content/246-167c2f0/web.assets_common.js:473:758
then/<@http://192.168.17.123:8069/web/content/246-167c2f0/web.assets_common.js:650:553
Deferred@http://192.168.17.123:8069/web/content/246-167c2f0/web.assets_common.js:651:189
then@http://192.168.17.123:8069/web/content/246-167c2f0/web.assets_common.js:650:518
load_record@http://192.168.17.123:8069/web/content/431-4a157d1/web.assets_backend.js:3545:360
trigger@http://192.168.17.123:8069/web/content/246-167c2f0/web.assets_common.js:2614:166
trigger@http://192.168.17.123:8069/web/content/246-167c2f0/web.assets_common.js:2616:636
load_defaults/<@http://192.168.17.123:8069/web/content/431-4a157d1/web.assets_backend.js:3548:215
then/</</<@http://192.168.17.123:8069/web/content/246-167c2f0/web.assets_common.js:650:678
fire@http://192.168.17.123:8069/web/content/246-167c2f0/web.assets_common.js:644:281
fireWith@http://192.168.17.123:8069/web/content/246-167c2f0/web.assets_common.js:649:198
Deferred/</deferred[tuple[0]]@http://192.168.17.123:8069/web/content/246-167c2f0/web.assets_common.js:651:31
fire@http://192.168.17.123:8069/web/content/246-167c2f0/web.assets_common.js:644:281
fireWith@http://192.168.17.123:8069/web/content/246-167c2f0/web.assets_common.js:649:198
then/</</<@http://192.168.17.123:8069/web/content/246-167c2f0/web.assets_common.js:650:849
fire@http://192.168.17.123:8069/web/content/246-167c2f0/web.assets_common.js:644:281
fireWith@http://192.168.17.123:8069/web/content/246-167c2f0/web.assets_common.js:649:198
then/</</<@http://192.168.17.123:8069/web/content/246-167c2f0/web.assets_common.js:650:849
fire@http://192.168.17.123:8069/web/content/246-167c2f0/web.assets_common.js:644:281
fireWith@http://192.168.17.123:8069/web/content/246-167c2f0/web.assets_common.js:649:198
done@http://192.168.17.123:8069/web/content/246-167c2f0/web.assets_common.js:1040:86
callback@http://192.168.17.123:8069/web/content/246-167c2f0/web.assets_common.js:1060:15

Error in module

Hi,
There is an error in the module, when a quotation is created and you add an agent and confirm the quotation, the agent added is not been forwarded to the invoice of that sale order under accounting, you need to manually do it again under the invoice even if you originally added the agent in the quotation. when u now add the agent in the invoice area it come up with an error.

Error when editing invoice lines

I'm getting this error when editing invoice lines.

Steps to reproduce:

  1. Create an invoice with commissions
  2. Save it (but don't validate)
  3. Open and Edit the invoice
  4. Edit some invoice line quantity or product. Maybe also click the invoice line agent lines.
  5. Try to save the line (lose focus)

This error window raises 3 times:

Traceback (most recent call last):
  File "/usr/local/lib/python2.7/dist-packages/odoo-8.0-py2.7.egg/openerp/http.py", line 537, in _handle_exception
    return super(JsonRequest, self)._handle_exception(exception)
  File "/usr/local/lib/python2.7/dist-packages/odoo-8.0-py2.7.egg/openerp/http.py", line 574, in dispatch
    result = self._call_function(**self.params)
  File "/usr/local/lib/python2.7/dist-packages/odoo-8.0-py2.7.egg/openerp/http.py", line 310, in _call_function
    return checked_call(self.db, *args, **kwargs)
  File "/usr/local/lib/python2.7/dist-packages/odoo-8.0-py2.7.egg/openerp/service/model.py", line 118, in wrapper
    return f(dbname, *args, **kwargs)
  File "/usr/local/lib/python2.7/dist-packages/odoo-8.0-py2.7.egg/openerp/http.py", line 307, in checked_call
    return self.endpoint(*a, **kw)
  File "/usr/local/lib/python2.7/dist-packages/odoo-8.0-py2.7.egg/openerp/http.py", line 803, in __call__
    return self.method(*args, **kw)
  File "/usr/local/lib/python2.7/dist-packages/odoo-8.0-py2.7.egg/openerp/http.py", line 403, in response_wrap
    response = f(*args, **kw)
  File "/home/itodorovich/odoo/server/addons/web/controllers/main.py", line 944, in call_kw
    return self._call_kw(model, method, args, kwargs)
  File "/home/itodorovich/odoo/server/addons/web/controllers/main.py", line 936, in _call_kw
    return getattr(request.registry.get(model), method)(request.cr, request.uid, *args, **kwargs)
  File "/usr/local/lib/python2.7/dist-packages/odoo-8.0-py2.7.egg/openerp/api.py", line 256, in wrapper
    return old_api(self, *args, **kwargs)
  File "/usr/local/lib/python2.7/dist-packages/odoo-8.0-py2.7.egg/openerp/api.py", line 387, in old_api
    result = method(recs, *args, **kwargs)
  File "/usr/local/lib/python2.7/dist-packages/odoo-8.0-py2.7.egg/openerp/models.py", line 5920, in onchange
    record = self.new(values)
  File "/usr/local/lib/python2.7/dist-packages/odoo-8.0-py2.7.egg/openerp/api.py", line 254, in wrapper
    return new_api(self, *args, **kwargs)
  File "/usr/local/lib/python2.7/dist-packages/odoo-8.0-py2.7.egg/openerp/models.py", line 5484, in new
    record._cache.update(record._convert_to_cache(values, update=True))
  File "/usr/local/lib/python2.7/dist-packages/odoo-8.0-py2.7.egg/openerp/models.py", line 5379, in _convert_to_cache
    for name, value in values.iteritems()
  File "/usr/local/lib/python2.7/dist-packages/odoo-8.0-py2.7.egg/openerp/models.py", line 5380, in <dictcomp>
    if name in fields
  File "/usr/local/lib/python2.7/dist-packages/odoo-8.0-py2.7.egg/openerp/fields.py", line 1645, in convert_to_cache
    ids = OrderedSet(command[2])
  File "/usr/local/lib/python2.7/dist-packages/odoo-8.0-py2.7.egg/openerp/tools/misc.py", line 1282, in __init__
    super(OrderedSet, self).__init__([(x, None) for x in seq])
TypeError: 'NoneType' object is not iterable

Also, not always, but continuing to mess with the invoice lines causes some other errors. For instance, this one:

Odoo Error del Cliente
Uncaught TypeError: Cannot read property 'constructor' of undefined
http://192.168.1.110:8069/web/js/web.assets_backend/45bced3:2918

Issue with sale commission in Portal View

Hi,
There is an issue with the sale commission module in portal view.
Here is the process, a customer is given portal access to see their invoices and sale orders but they are unable to see the document due to access right error.
On sale order the error is coming from (Document Module sale.order.line.agent) and
On Invoices its coming from (Document module account.invoice.line.agent).

Also if these errors where not there and a customer can see the agent commission on their accounts, i think that will be super wrong as well. I suggest the agent commission is somehow removed from the portal documents of the customer r blocked in a way the details are not shown to the customer.

Please see attached screenshots for the error.
account error
sale order error

Error on Sale Commission Module, can not add a second SO line. TypeError: Cannot read property 'constructor' of undefined

Steps to reproduce (tested on runbot and local):

  1. log in with admin
  2. Go into quoatations menu / enter SO "SO003"
  3. Enter partner "Chamber Works"
  4. Assign "Agents" with "agent 1", save and go back to sale order
  5. Click on "add an item", choose "ice cream", without saving click on "Add an item", you should get an error with "TypeError: Cannot read property 'constructor' of undefined"

I have try to investigate the issue but haven't found so much. It is related to the o2m editable inside the o2m editable of sale order lines. If you make sale order lines open in a form, it works ok.

Console log:

instance.web.FormView.instance.web.View.extend._process_save @ view_form.js:893
(anonymous function) @ view_form.js:619
(anonymous function) @ jquery.js:1129
fire @ jquery.js:974
self.add @ jquery.js:1020
(anonymous function) @ jquery.js:1127
jQuery.extend.each @ jquery.js:611
(anonymous function) @ jquery.js:1123
jQuery.extend.Deferred @ jquery.js:1184
promise.then @ jquery.js:1122
iterate @ view_form.js:616
(anonymous function) @ view_form.js:632
(anonymous function) @ openerpframework.js:1352
(anonymous function) @ jquery.js:1129
fire @ jquery.js:974
self.add @ jquery.js:1020
(anonymous function) @ jquery.js:1127
jQuery.extend.each @ jquery.js:611
(anonymous function) @ jquery.js:1123
jQuery.extend.Deferred @ jquery.js:1184
promise.then @ jquery.js:1122
openerp.Mutex.openerp.Class.extend.exec @ openerpframework.js:1351
instance.web.FormView.instance.web.View.extend._process_operations @ view_form.js:603
instance.web.FormView.instance.web.View.extend.save @ view_form.js:823
instance.web.list.Editor.instance.web.Widget.extend.save @ view_list_editable.js:773
(anonymous function) @ view_list_editable.js:329
instance.web.ListView.include.with_event @ view_list_editable.js:406
(anonymous function) @ view_list_editable.js:324
(anonymous function) @ openerpframework.js:1352
(anonymous function) @ jquery.js:1129
fire @ jquery.js:974
self.add @ jquery.js:1020
(anonymous function) @ jquery.js:1127
jQuery.extend.each @ jquery.js:611
(anonymous function) @ jquery.js:1123
jQuery.extend.Deferred @ jquery.js:1184
promise.then @ jquery.js:1122
openerp.Mutex.openerp.Class.extend.exec @ openerpframework.js:1351
instance.web.ListView.include.save_edition @ view_list_editable.js:320
instance.web.ListView.include.ensure_saved @ view_list_editable.js:198
instance.web.form.FieldOne2Many.instance.web.form.AbstractField.extend.save_any_view @ view_form.js:4341
instance.web.form.FieldOne2Many.instance.web.form.AbstractField.extend.commit_value @ view_form.js:4330
(anonymous function) @ view_form.js:610
(anonymous function) @ openerpframework.js:1352
(anonymous function) @ jquery.js:1129
fire @ jquery.js:974
self.add @ jquery.js:1020
(anonymous function) @ jquery.js:1127
jQuery.extend.each @ jquery.js:611
(anonymous function) @ jquery.js:1123
jQuery.extend.Deferred @ jquery.js:1184
promise.then @ jquery.js:1122
openerp.Mutex.openerp.Class.extend.exec @ openerpframework.js:1351
(anonymous function) @ view_form.js:609
(anonymous function) @ jquery.js:1129
fire @ jquery.js:974
self.add @ jquery.js:1020
(anonymous function) @ jquery.js:1127
jQuery.extend.each @ jquery.js:611
(anonymous function) @ jquery.js:1123
jQuery.extend.Deferred @ jquery.js:1184
promise.then @ jquery.js:1122
(anonymous function) @ view_form.js:608
.each..forEach @ underscore.js:87
iterate @ view_form.js:607
(anonymous function) @ view_form.js:632
(anonymous function) @ openerpframework.js:1352
(anonymous function) @ jquery.js:1129
fire @ jquery.js:974
self.add @ jquery.js:1020
(anonymous function) @ jquery.js:1127
jQuery.extend.each @ jquery.js:611
(anonymous function) @ jquery.js:1123
jQuery.extend.Deferred @ jquery.js:1184
promise.then @ jquery.js:1122
openerp.Mutex.openerp.Class.extend.exec @ openerpframework.js:1351
instance.web.FormView.instance.web.View.extend._process_operations @ view_form.js:603
instance.web.FormView.instance.web.View.extend.save @ view_form.js:823
instance.web.FormView.instance.web.View.extend.on_button_save @ view_form.js:727
(anonymous function) @ views.js:1539
jQuery.event.dispatch @ jquery.js:3058
elemData.handle.eventHandle @ jquery.js:2676

[sale_commission] Commissions are not being settled for invoices duplicated from a settled invoice.

  1. Create an invoice with agent lines
  2. Settle the invoice from the commissions wizard
  3. Duplicate the invoice
  4. Try to settle de invoice

Result: Invoice is ignored in the settlement.
Expected: Invoice commission should be settled.

This bug won't occur, though, if the invoice is duplicated from a not settled invoice.

I'm guessing the account.invoice.line.agent's settled field is being copied aswell when duplicating an invoice, hence ignoring this invoice line from settlements.

Is there a way to avoid this? a way to reset this field value when duplicating?
I don't know how to do it, yet, at least not without investigating the web for a few hours.

Commissions for Website Sales

module: sale_commission
version: 8.0

Current behavior
When a sales order/quotation is created on the backend, the commissions are duly calculated. However, when the same customer places an order to on the ecommerce shop, commissions are zero.
Expected behavior
1.If Customer1 places an order on the website, the commissions should be calculated just like when the order is placed from the backend.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.