Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[ADD] Delivery Carrier Seur Module #76

Closed
wants to merge 1 commit into from
Closed

Conversation

ismaelcj
Copy link
Member

@ismaelcj ismaelcj commented Nov 2, 2015

Seur module for generate:

  • Label and tracking number
  • Manifest

@@ -0,0 +1,39 @@
Module for SEUR carrier labels
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@pedrobaeza
Copy link
Member

You should add seur library installatin in .travis.yml file.

@pedrobaeza
Copy link
Member

Anyway, I can't see the usage of the seur python library in the code.

@pedrobaeza
Copy link
Member

Another thing: is this only valid for Spain? If so, you should rename the module with the l10n_es_ prefix, and we have to think about placing this here, or in the l10n-spain repo.

##############################################################################
from openerp import models, fields, api, exceptions
from openerp.tools.translate import _
from seur.picking import Picking
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Here is the import of the Seur library. And i use it later.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

OK, I didn't see it. Then you should protect the import following this guideline: https://github.com/OCA/maintainer-tools/blob/master/CONTRIBUTING.md#importerror

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@ismaelcj
Copy link
Member Author

ismaelcj commented Nov 3, 2015

The truth is I do not know if it's just for Spain.

@pedrobaeza
Copy link
Member

For the deliver types, I would say it's only for Spain, so you should rename it to delivery_carrier_seur_es o l10n_es_delivery_carrier_seur. What others think?

@liebana
Copy link
Sponsor

liebana commented Nov 3, 2015

SEUR also operates at least in Portugal.

@pedrobaeza
Copy link
Member

But services name (SEUR 24 h, SEUR 8:30) seems very specific of Spain, doesn't it?

@bealdav
Copy link
Member

bealdav commented Nov 20, 2015

Hi @ismaelcj , maybe this PR can help you to have less code

class StockPicking(models.Model):
_inherit = 'stock.picking'

seur_service_code = fields.Selection(
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

res.append(('seur', 'SEUR'))
return res

seur_config_id = fields.Many2one('seur.config', string='SEUR Config')
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't know what you mean. It has a menu in Settings > Configuration > Carriers > SEUR

Copy link
Member

@yvaucher yvaucher May 5, 2017

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Usually configs are a transientmodel as it gather data from multiple origin and are linked to a company.

Here you seems to have a config shared by all companies that you can set on a specific delivery method.
In other delivery services we have a single account per company. With management of options on the delivery method.

Is there a reason to have multiple config for one company ?

@yvaucher
Copy link
Member

yvaucher commented Dec 4, 2015

Nice to see we are reaching spain with this repository, welcome here @ismaelcj

Thanks for your contribution.

I seems you need to add a python dependency "genshi" for travis
https://travis-ci.org/OCA/carrier-delivery/jobs/89049748

Also, it seems this module needs testing. Could you add some?
A good practice would be to use mock or even better https://github.com/kevin1024/vcrpy to simulate the talk with the webservice API

@ismaelcj
Copy link
Member Author

Hi,

@yvaucher About your comment:

'I seems you need to add a python dependency "genshi" for travis'

It was an error on the API setup.py. I proposed the changes in the API repository, and are already applied:
https://bitbucket.org/zikzakmedia/python-seur/commits/f853056f21d506e68e526cf1ca2363334f0047d7

About the tests, I will to do it.

@ismaelcj
Copy link
Member Author

The genshi dependence continuous falling in travis, I don't understand.

@@ -35,6 +35,7 @@ install:
- pip install unidecode
- pip install pycountry
- pip install suds-jurko==0.6
- pip install seur
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

have you tried to install genshi before seur ?

pip install genshi
pip install seur

@angelmoya
Copy link
Member

I start to migrate this module to version 10, and i found two problems:

I will create new PR for version 10

vrenaville pushed a commit to camptocamp/delivery-carrier that referenced this pull request Jul 2, 2018
…amount

Add expected amount and probability fields on building project
@rousseldenis
Copy link
Sponsor Contributor

@ismaelcj This one is really old. Do you plan to fix it ?

@ismaelcj
Copy link
Member Author

Me not. Maybe @liebana or @hugosantosred or @kikopeiro

OCA-git-bot pushed a commit that referenced this pull request Jul 3, 2021
Refactor error handling
@github-actions
Copy link

There hasn't been any activity on this pull request in the past 4 months, so it has been marked as stale and it will be closed automatically if no further activity occurs in the next 30 days.
If you want this PR to never become stale, please ask a PSC member to apply the "no stale" label.

@github-actions github-actions bot added the stale PR/Issue without recent activity, it'll be soon closed automatically. label Oct 24, 2021
@github-actions github-actions bot closed this Nov 28, 2021
OCA-git-bot pushed a commit that referenced this pull request Oct 4, 2023
Refactor error handling
OCA-git-bot pushed a commit that referenced this pull request Oct 4, 2023
Refactor error handling
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
needs fixing stale PR/Issue without recent activity, it'll be soon closed automatically.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

7 participants