Skip to content

Commit

Permalink
[MIG] Migration to version 10.0
Browse files Browse the repository at this point in the history
  • Loading branch information
Maxime Chambreuil committed Jan 19, 2017
1 parent 5023c61 commit b558936
Show file tree
Hide file tree
Showing 19 changed files with 397 additions and 560 deletions.
7 changes: 4 additions & 3 deletions document_page/README.rst
Expand Up @@ -16,7 +16,7 @@ This module depends on module knowledge. So make sure to have it in your addons
Configuration
=============

No configuration required
No configuration required.

Usage
=====
Expand All @@ -30,7 +30,7 @@ To use this module, you need to:

.. image:: https://odoo-community.org/website/image/ir.attachment/5784_f2813bd/datas
:alt: Try me on Runbot
:target: https://runbot.odoo-community.org/runbot/118/9.0
:target: https://runbot.odoo-community.org/runbot/118/10.0

Known issues / Roadmap
======================
Expand All @@ -40,7 +40,7 @@ Bug Tracker

Bugs are tracked on `GitHub Issues <https://github.com/OCA/Knowledge/issues>`_.
In case of trouble, please check there if your issue has already been reported.
If you spotted it first, help us smashing it by providing a detailed and welcomed feedback `here <https://github.com/OCA/knowledge/issues/new?body=module:%20document_page%0Aversion:%209.0%0A%0A**Steps%20to%20reproduce**%0A-%20...%0A%0A**Current%20behavior**%0A%0A**Expected%20behavior**>`_.
If you spotted it first, help us smashing it by providing a detailed and welcomed feedback `here <https://github.com/OCA/knowledge/issues/new?body=module:%20document_page%0Aversion:%2010.0%0A%0A**Steps%20to%20reproduce**%0A-%20...%0A%0A**Current%20behavior**%0A%0A**Expected%20behavior**>`_.

Credits
=======
Expand All @@ -51,6 +51,7 @@ Contributors
* Odoo SA <info@odoo.com>
* Savoir-faire Linux <support@savoirfairelinux.com>
* Gervais Naoussi <gervaisnaoussi@gmail.com>
* Maxime Chambreuil <mchambreuil@ursainfosystems.com>

Maintainer
----------
Expand Down
22 changes: 3 additions & 19 deletions document_page/__init__.py
@@ -1,22 +1,6 @@
# -*- coding: utf-8 -*-
##############################################################################
#
# OpenERP, Open Source Management Solution
# Copyright (C) 2004-2010 Tiny SPRL (<http://tiny.be>).
#
# 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/>.
#
##############################################################################
# Copyright (C) 2004-2010 Tiny SPRL (<http://tiny.be>).
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).

from . import models
from . import wizard
39 changes: 13 additions & 26 deletions document_page/__manifest__.py
@@ -1,32 +1,21 @@
# -*- coding: utf-8 -*-
##############################################################################
#
# OpenERP, Open Source Management Solution
# Copyright (C) 2004-2010 Tiny SPRL (<http://tiny.be>).
#
# 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/>.
#
##############################################################################
# Copyright (C) 2004-2010 Tiny SPRL (<http://tiny.be>).
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).


{
'name': 'Document Page',
'version': '9.0.1.0.1',
'version': '10.0.1.0.0',
'category': 'Knowledge Management',
'author': 'OpenERP SA, Odoo Community Association (OCA)',
'images': ['images/category_list.png', 'images/create_category.png',
'images/page_list.png', 'images/create_page.png',
'images/customer_invoice.jpeg', 'images/page_history.png'],
'images': [
'images/category_list.png',
'images/create_category.png',
'images/page_list.png',
'images/create_page.png',
'images/customer_invoice.jpeg',
'images/page_history.png',
],
'website': 'http://www.openerp.com/',
'license': 'AGPL-3',
'depends': [
Expand All @@ -39,11 +28,9 @@
'views/document_page.xml',
'security/document_page_security.xml',
'security/ir.model.access.csv',
'data/document_page.xml',
],
'demo': [
'demo/document_page.xml'
],
'installable': False,
'auto_install': False,
'css': ['static/src/css/document_page.css'],
}
43 changes: 4 additions & 39 deletions document_page/data/document_page.xml
@@ -1,41 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<?xml version="1.0" encoding="utf-8"?>
<odoo>
<data noupdate="1">
<record id="wiki_wiki_main" model="document.page">
<field name="name">The Odoo wiki</field>
<field name="tags">help, quick start, wiki, formatting</field>
<field name="minor_edit">0</field>
<field name="index">1</field>
<field name="summary">Initial Page</field>
<field name="content">== The Odoo wiki ==

[[File:https://www.odoo.com/openerp_website/static/src/img/logo_transparent_198px.png Odoo]]

The Odoo wiki allows you to manage your enterprise's contents using wiki
restructured texts. This module provides a collaborative way to manage internal
FAQs, quality manuals, technical references, etc.

==Keypoints==
* Same formating style than MediaWiki,
* Any number of wiki group for different purposes,
* Detailed history on all pages,
* Integrated with the document management system.

==Why you should use the OpenERP integrated wiki than a separate wiki system ?==
* Allows links to any document of the system,
* Uses the access controls of OpenERP for uniq access rights management,
* Use it to describe projects, tasks, products,
* Integrated with customer portal to provide restricted external accesses,
* Linked to users processes for quality manuals.

==To get more information==
* [[Basic Wiki Editing]]
* [[Wiki Documentation]]
* [http://openerp.com The OpenERP website]


</field>
<field name="parent_id" ref="wiki_groups_wikiformatting0"/>
</record>
</data>
<template id="document_page_css">
<link rel="stylesheet" type="text/less" href="/document_page/static/src/css/document_page.css"/>
</template>
</odoo>
22 changes: 3 additions & 19 deletions document_page/models/__init__.py
@@ -1,22 +1,6 @@
# -*- coding: utf-8 -*-
##############################################################################
#
# OpenERP, Open Source Management Solution
# Copyright (C) 2004-2010 Tiny SPRL (<http://tiny.be>).
#
# 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/>.
#
##############################################################################
# Copyright (C) 2004-2010 Tiny SPRL (<http://tiny.be>).
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).

from . import document_page
from . import document_page_history
32 changes: 8 additions & 24 deletions document_page/models/document_page.py
@@ -1,25 +1,9 @@
# -*- coding: utf-8 -*-
##############################################################################
#
# OpenERP, Open Source Management Solution
# Copyright (C) 2004-2010 Tiny SPRL (<http://tiny.be>).
#
# 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/>.
#
##############################################################################
# Copyright (C) 2004-2010 Tiny SPRL (<http://tiny.be>).
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).

import logging
from openerp import models, fields, api
from odoo import api, fields, models

_logger = logging.getLogger(__name__)

Expand Down Expand Up @@ -76,26 +60,26 @@ class DocumentPage(models.Model):

create_date = fields.Datetime(
"Created on",
select=True,
index=True,
readonly=True
)

create_uid = fields.Many2one(
'res.users',
'Author',
select=True,
index=True,
readonly=True
)

write_date = fields.Datetime(
"Modification Date",
select=True,
index=True,
readonly=True)

write_uid = fields.Many2one(
'res.users',
"Last Contributor",
select=True,
index=True,
readonly=True
)

Expand Down
26 changes: 5 additions & 21 deletions document_page/models/document_page_history.py
@@ -1,26 +1,10 @@
# -*- coding: utf-8 -*-
##############################################################################
#
# OpenERP, Open Source Management Solution
# Copyright (C) 2004-2010 Tiny SPRL (<http://tiny.be>).
#
# 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/>.
#
##############################################################################
# Copyright (C) 2004-2010 Tiny SPRL (<http://tiny.be>).
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).

import logging
import difflib
from openerp import models, fields, _
from odoo import fields, models

_logger = logging.getLogger(__name__)

Expand All @@ -34,7 +18,7 @@ class DocumentPageHistory(models.Model):
_rec_name = "create_date"

page_id = fields.Many2one('document.page', 'Page')
summary = fields.Char('Summary', select=True)
summary = fields.Char('Summary', index=True)
content = fields.Text("Content")
create_date = fields.Datetime("Date")
create_uid = fields.Many2one('res.users', "Modified By")
Expand Down
4 changes: 2 additions & 2 deletions document_page/security/document_page_security.xml
@@ -1,8 +1,8 @@
<?xml version="1.0" encoding="utf-8"?>
<odoo>
<data noupdate="0">

<record id="base.group_document_user" model="res.groups">
<field name="users" eval="[(4, ref('base.user_root'))]"/>
</record>
</data>

</odoo>
Binary file added document_page/static/description/icon.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion document_page/tests/test_document_page.py
@@ -1,6 +1,6 @@
# -*- coding: utf-8 -*-

from openerp.tests import common
from odoo.tests import common


class TestDocumentPage(common.TransactionCase):
Expand Down
2 changes: 1 addition & 1 deletion document_page/tests/test_document_page_create_menu.py
@@ -1,6 +1,6 @@
# -*- coding: utf-8 -*-

from openerp.tests import common
from odoo.tests import common


class TestDocumentPageCreateMenu(common.TransactionCase):
Expand Down
2 changes: 1 addition & 1 deletion document_page/tests/test_document_page_history.py
@@ -1,6 +1,6 @@
# -*- coding: utf-8 -*-

from openerp.tests import common
from odoo.tests import common


class TestDocumentPageHistory(common.TransactionCase):
Expand Down
4 changes: 2 additions & 2 deletions document_page/tests/test_document_page_show_diff.py
@@ -1,7 +1,7 @@
# -*- coding: utf-8 -*-

from openerp.tests import common
from openerp import _
from odoo.tests import common
from odoo import _


class TestDocumentPageShowDiff(common.TransactionCase):
Expand Down

0 comments on commit b558936

Please sign in to comment.