-
-
Notifications
You must be signed in to change notification settings - Fork 63
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #12 from lepistone/transport_information
add transport mode and vehicle, models and views
- Loading branch information
Showing
10 changed files
with
270 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
Transport Information | ||
===================== | ||
This simple module is an extraction of objects related to transportation of | ||
goods that are needed in some modules of the verticalization for NGOs, like | ||
logistic_requisition. | ||
|
||
Objects introduced here include: | ||
|
||
- Transport Mode | ||
- Transport Vehicle |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
# -*- coding: utf-8 -*- | ||
from . import model |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
# -*- coding: utf-8 -*- | ||
############################################################################## | ||
# | ||
# Copyright 2014 Camptocamp SA | ||
# Author: Leonardo Pistone | ||
# | ||
# This program is free software: you can redistribute it and/or modify | ||
# it under the terms of the GNU Affero General Public License as | ||
# published by the Free Software Foundation, either version 3 of the | ||
# License, or (at your option) any later version. | ||
# | ||
# This program is distributed in the hope that it will be useful, | ||
# but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
# GNU Affero General Public License for more details. | ||
# | ||
# You should have received a copy of the GNU Affero General Public License | ||
# along with this program. If not, see <http://www.gnu.org/licenses/>. | ||
# | ||
############################################################################## | ||
|
||
{"name": "Transport Information", | ||
"summary": "Transport Information", | ||
"version": "0.1", | ||
"author": "Camptocamp", | ||
"category": "Purchase Management", | ||
"license": "AGPL-3", | ||
'complexity': "easy", | ||
"depends": ["purchase", | ||
], | ||
"data": ["view/transport_mode.xml", | ||
"view/transport_vehicle.xml", | ||
"security/ir.model.access.csv", | ||
], | ||
"installable": True, | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,77 @@ | ||
# Translation of Odoo Server. | ||
# This file contains the translation of the following modules: | ||
# * transport_information | ||
# | ||
msgid "" | ||
msgstr "" | ||
"Project-Id-Version: Odoo Server 8.0\n" | ||
"Report-Msgid-Bugs-To: \n" | ||
"POT-Creation-Date: 2014-10-24 09:38+0000\n" | ||
"PO-Revision-Date: 2014-10-24 09:38+0000\n" | ||
"Last-Translator: <>\n" | ||
"Language-Team: \n" | ||
"MIME-Version: 1.0\n" | ||
"Content-Type: text/plain; charset=UTF-8\n" | ||
"Content-Transfer-Encoding: \n" | ||
"Plural-Forms: \n" | ||
|
||
#. module: transport_information | ||
#: field:transport.mode,create_uid:0 | ||
#: field:transport.vehicle,create_uid:0 | ||
msgid "Created by" | ||
msgstr "" | ||
|
||
#. module: transport_information | ||
#: field:transport.mode,create_date:0 | ||
#: field:transport.vehicle,create_date:0 | ||
msgid "Created on" | ||
msgstr "" | ||
|
||
#. module: transport_information | ||
#: field:transport.mode,id:0 | ||
#: field:transport.vehicle,id:0 | ||
msgid "ID" | ||
msgstr "" | ||
|
||
#. module: transport_information | ||
#: field:transport.mode,write_uid:0 | ||
#: field:transport.vehicle,write_uid:0 | ||
msgid "Last Updated by" | ||
msgstr "" | ||
|
||
#. module: transport_information | ||
#: field:transport.mode,write_date:0 | ||
#: field:transport.vehicle,write_date:0 | ||
msgid "Last Updated on" | ||
msgstr "" | ||
|
||
#. module: transport_information | ||
#: field:transport.mode,name:0 | ||
#: field:transport.vehicle,name:0 | ||
msgid "Name" | ||
msgstr "" | ||
|
||
#. module: transport_information | ||
#: view:transport.mode:transport_information.view_transport_mode_form | ||
msgid "Transport Mode" | ||
msgstr "" | ||
|
||
#. module: transport_information | ||
#: model:ir.actions.act_window,name:transport_information.action_transport_mode | ||
#: model:ir.ui.menu,name:transport_information.menu_transport_mode | ||
#: view:transport.mode:transport_information.view_transport_mode_tree | ||
msgid "Transport Modes" | ||
msgstr "" | ||
|
||
#. module: transport_information | ||
#: view:transport.vehicle:transport_information.view_transport_vehicle_tree | ||
msgid "Transport Vehicles" | ||
msgstr "" | ||
|
||
#. module: transport_information | ||
#: model:ir.actions.act_window,name:transport_information.action_transport_vehicle | ||
#: model:ir.ui.menu,name:transport_information.menu_transport_vehicle | ||
#: view:transport.vehicle:transport_information.view_transport_vehicle_form | ||
msgid "Vehicles" | ||
msgstr "" | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
# -*- coding: utf-8 -*- | ||
from . import transport_mode | ||
from . import transport_vehicle |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
# -*- coding: utf-8 -*- | ||
############################################################################## | ||
# | ||
# Copyright 2014 Camptocamp SA | ||
# Author: Leonardo Pistone | ||
# | ||
# This program is free software: you can redistribute it and/or modify | ||
# it under the terms of the GNU Affero General Public License as | ||
# published by the Free Software Foundation, either version 3 of the | ||
# License, or (at your option) any later version. | ||
# | ||
# This program is distributed in the hope that it will be useful, | ||
# but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
# GNU Affero General Public License for more details. | ||
# | ||
# You should have received a copy of the GNU Affero General Public License | ||
# along with this program. If not, see <http://www.gnu.org/licenses/>. | ||
# | ||
############################################################################## | ||
from openerp import models, fields | ||
|
||
|
||
class TransportMode(models.Model): | ||
_name = "transport.mode" | ||
|
||
name = fields.Char('Name', required=True, translate=True) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
# -*- coding: utf-8 -*- | ||
############################################################################## | ||
# | ||
# Copyright 2014 Camptocamp SA | ||
# Author: Leonardo Pistone | ||
# | ||
# This program is free software: you can redistribute it and/or modify | ||
# it under the terms of the GNU Affero General Public License as | ||
# published by the Free Software Foundation, either version 3 of the | ||
# License, or (at your option) any later version. | ||
# | ||
# This program is distributed in the hope that it will be useful, | ||
# but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
# GNU Affero General Public License for more details. | ||
# | ||
# You should have received a copy of the GNU Affero General Public License | ||
# along with this program. If not, see <http://www.gnu.org/licenses/>. | ||
# | ||
############################################################################## | ||
from openerp import models, fields | ||
|
||
|
||
class TransportVehicle(models.Model): | ||
_name = "transport.vehicle" | ||
|
||
name = fields.Char('Name', required=True, translate=True) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
id,name,model_id:id,group_id:id,perm_read,perm_write,perm_create,perm_unlink | ||
access_transport_mode_all,access_transport_mode_all,model_transport_mode,,1,0,0,0 | ||
access_transport_mode_manager,access_transport_mode_manager,model_transport_mode,purchase.group_purchase_manager,1,1,1,1 | ||
access_transport_vehicle_all,access_transport_vehicle_all,model_transport_vehicle,,1,0,0,0 | ||
access_transport_vehicle_manager,access_transport_vehicle_manager,model_transport_vehicle,purchase.group_purchase_manager,1,1,1,1 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,41 @@ | ||
<?xml version="1.0" encoding="utf-8"?> | ||
<openerp> | ||
<data> | ||
|
||
<record model="ir.ui.view" id="view_transport_mode_form"> | ||
<field name="name">view_transport_mode_form</field> | ||
<field name="model">transport.mode</field> | ||
<field name="arch" type="xml"> | ||
<form> | ||
<group string="Transport Mode"> | ||
<field name="name"/> | ||
</group> | ||
</form> | ||
</field> | ||
</record> | ||
|
||
<record model="ir.ui.view" id="view_transport_mode_tree"> | ||
<field name="name">view_transport_mode_tree</field> | ||
<field name="model">transport.mode</field> | ||
<field name="arch" type="xml"> | ||
<tree string="Transport Modes"> | ||
<field name="name"/> | ||
</tree> | ||
</field> | ||
</record> | ||
|
||
<record model="ir.actions.act_window" id="action_transport_mode"> | ||
<field name="name">Transport Modes</field> | ||
<field name="res_model">transport.mode</field> | ||
<field name="view_type">form</field> | ||
<field name="view_mode">tree,form</field> | ||
</record> | ||
|
||
<menuitem | ||
name="Transport Modes" | ||
parent="purchase.menu_purchase_config_purchase" | ||
action="action_transport_mode" | ||
id="menu_transport_mode"/> | ||
|
||
</data> | ||
</openerp> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,42 @@ | ||
<?xml version="1.0" encoding="utf-8"?> | ||
<openerp> | ||
<data> | ||
|
||
<record model="ir.ui.view" id="view_transport_vehicle_form"> | ||
<field name="name">view_transport_vehicle_form</field> | ||
<field name="model">transport.vehicle</field> | ||
<field name="arch" type="xml"> | ||
<form> | ||
<group string="Vehicles"> | ||
<field name="name"/> | ||
</group> | ||
</form> | ||
</field> | ||
</record> | ||
|
||
<record model="ir.ui.view" id="view_transport_vehicle_tree"> | ||
<field name="name">view_transport_vehicle_tree</field> | ||
<field name="model">transport.vehicle</field> | ||
<field name="arch" type="xml"> | ||
<tree string="Transport Vehicles"> | ||
<field name="name"/> | ||
</tree> | ||
</field> | ||
</record> | ||
|
||
<record model="ir.actions.act_window" id="action_transport_vehicle"> | ||
<field name="name">Vehicles</field> | ||
<field name="res_model">transport.vehicle</field> | ||
<field name="view_type">form</field> | ||
<field name="view_mode">tree,form</field> | ||
</record> | ||
|
||
<menuitem | ||
name="Vehicles" | ||
parent="purchase.menu_purchase_config_purchase" | ||
action="action_transport_vehicle" | ||
id="menu_transport_vehicle"/> | ||
|
||
</data> | ||
</openerp> | ||
|