pos_container issues #1

Open
by Ghost opened 2 years ago · 1 comments
Ghost commented 2 years ago

Hello

I'm trying to use the module pos_container, found on your repository, on an odoo instance (in docker, I used odoo 12 from docker hub and a postgre DB).
I've added the pos_container module in my instance, and created a specific barcode nomenclature for containers.

In my PoS, when I scan a container, I have a red error message like this :

2022-10-29 12:44:51,228 1 ERROR xxxxxx odoo.http: Exception during JSON request handling. 
Traceback (most recent call last):
  File "/usr/lib/python3/dist-packages/odoo/http.py", line 656, in _handle_exception
    return super(JsonRequest, self)._handle_exception(exception)
  File "/usr/lib/python3/dist-packages/odoo/http.py", line 314, in _handle_exception
    raise pycompat.reraise(type(exception), exception, sys.exc_info()[2])
  File "/usr/lib/python3/dist-packages/odoo/tools/pycompat.py", line 87, in reraise
    raise value
  File "/usr/lib/python3/dist-packages/odoo/http.py", line 698, in dispatch
    result = self._call_function(**self.params)
  File "/usr/lib/python3/dist-packages/odoo/http.py", line 346, in _call_function
    return checked_call(self.db, *args, **kwargs)
  File "/usr/lib/python3/dist-packages/odoo/service/model.py", line 98, in wrapper
    return f(dbname, *args, **kwargs)
  File "/usr/lib/python3/dist-packages/odoo/http.py", line 339, in checked_call
    result = self.endpoint(*a, **kw)
  File "/usr/lib/python3/dist-packages/odoo/http.py", line 941, in __call__
    return self.method(*args, **kw)
  File "/usr/lib/python3/dist-packages/odoo/http.py", line 519, in response_wrap
    response = f(*args, **kw)
  File "/usr/lib/python3/dist-packages/odoo/addons/web/controllers/main.py", line 963, in call_kw
    return self._call_kw(model, method, args, kwargs)
  File "/usr/lib/python3/dist-packages/odoo/addons/web/controllers/main.py", line 955, in _call_kw
    return call_kw(request.env[model], method, args, kwargs)
  File "/usr/lib/python3/dist-packages/odoo/api.py", line 755, in call_kw
    return _call_kw_model(method, model, args, kwargs)
  File "/usr/lib/python3/dist-packages/odoo/api.py", line 728, in _call_kw_model
    result = method(recs, *args, **kwargs)
  File "/mnt/extra-addons/pos_container/models/container.py", line 39, in create_from_ui
    container_id = container.pop('id', False)
AttributeError: 'str' object has no attribute 'pop'

And the container is not created.

When I create manually a container from the backend, I can use it from the PoS but the weight of the container is not remove from the total weight.

Did I miss something ? any missing module I need to install ? any bug ? any thing we can do / test ?

Thanks for any help you can provide :)
Yannick

Hello I'm trying to use the module pos_container, found on your repository, on an odoo instance (in docker, I used odoo 12 from docker hub and a postgre DB). I've added the pos_container module in my instance, and created a specific barcode nomenclature for containers. In my PoS, when I scan a container, I have a red error message like this : ``` 2022-10-29 12:44:51,228 1 ERROR xxxxxx odoo.http: Exception during JSON request handling. Traceback (most recent call last): File "/usr/lib/python3/dist-packages/odoo/http.py", line 656, in _handle_exception return super(JsonRequest, self)._handle_exception(exception) File "/usr/lib/python3/dist-packages/odoo/http.py", line 314, in _handle_exception raise pycompat.reraise(type(exception), exception, sys.exc_info()[2]) File "/usr/lib/python3/dist-packages/odoo/tools/pycompat.py", line 87, in reraise raise value File "/usr/lib/python3/dist-packages/odoo/http.py", line 698, in dispatch result = self._call_function(**self.params) File "/usr/lib/python3/dist-packages/odoo/http.py", line 346, in _call_function return checked_call(self.db, *args, **kwargs) File "/usr/lib/python3/dist-packages/odoo/service/model.py", line 98, in wrapper return f(dbname, *args, **kwargs) File "/usr/lib/python3/dist-packages/odoo/http.py", line 339, in checked_call result = self.endpoint(*a, **kw) File "/usr/lib/python3/dist-packages/odoo/http.py", line 941, in __call__ return self.method(*args, **kw) File "/usr/lib/python3/dist-packages/odoo/http.py", line 519, in response_wrap response = f(*args, **kw) File "/usr/lib/python3/dist-packages/odoo/addons/web/controllers/main.py", line 963, in call_kw return self._call_kw(model, method, args, kwargs) File "/usr/lib/python3/dist-packages/odoo/addons/web/controllers/main.py", line 955, in _call_kw return call_kw(request.env[model], method, args, kwargs) File "/usr/lib/python3/dist-packages/odoo/api.py", line 755, in call_kw return _call_kw_model(method, model, args, kwargs) File "/usr/lib/python3/dist-packages/odoo/api.py", line 728, in _call_kw_model result = method(recs, *args, **kwargs) File "/mnt/extra-addons/pos_container/models/container.py", line 39, in create_from_ui container_id = container.pop('id', False) AttributeError: 'str' object has no attribute 'pop' ``` And the container is not created. When I create manually a container from the backend, I can use it from the PoS but the weight of the container is not remove from the total weight. Did I miss something ? any missing module I need to install ? any bug ? any thing we can do / test ? Thanks for any help you can provide :) Yannick
Owner

hello, You have to create a Barcode Nomenclature to handle containers before using the
module.

have you done this ?

hello, You have to create a Barcode Nomenclature to handle containers before using the module. have you done this ?
Sign in to join this conversation.
No Label
No Milestone
No Assignees
2 Participants
Notifications
Due Date

No due date set.

Dependencies

This issue currently doesn't have any dependencies.

Loading…
There is no content yet.