-
-
Notifications
You must be signed in to change notification settings - Fork 171
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
25 changed files
with
1,398 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,96 @@ | ||
================================== | ||
Document Management System Version | ||
================================== | ||
|
||
.. !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! | ||
!! This file is generated by oca-gen-addon-readme !! | ||
!! changes will be overwritten. !! | ||
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! | ||
.. |badge1| image:: https://img.shields.io/badge/maturity-Beta-yellow.png | ||
:target: https://odoo-community.org/page/development-status | ||
:alt: Beta | ||
.. |badge2| image:: https://img.shields.io/badge/licence-LGPL--3-blue.png | ||
:target: http://www.gnu.org/licenses/lgpl-3.0-standalone.html | ||
:alt: License: LGPL-3 | ||
.. |badge3| image:: https://img.shields.io/badge/github-OCA%2Fdms-lightgray.png?logo=github | ||
:target: https://github.com/OCA/dms/tree/13.0/dms_version | ||
:alt: OCA/dms | ||
.. |badge4| image:: https://img.shields.io/badge/weblate-Translate%20me-F47D42.png | ||
:target: https://translation.odoo-community.org/projects/dms-13-0/dms-13-0-dms_version | ||
:alt: Translate me on Weblate | ||
.. |badge5| image:: https://img.shields.io/badge/runbot-Try%20me-875A7B.png | ||
:target: https://runbot.odoo-community.org/runbot/292/13.0 | ||
:alt: Try me on Runbot | ||
|
||
|badge1| |badge2| |badge3| |badge4| |badge5| | ||
|
||
Documents Versioning enables version control for the document management system. | ||
|
||
**Table of contents** | ||
|
||
.. contents:: | ||
:local: | ||
|
||
Usage | ||
===== | ||
|
||
Go to any file form and if the file has an older version its possible to revert it. | ||
|
||
Known issues / Roadmap | ||
====================== | ||
|
||
Creating an addon to compress attachments could be useful. | ||
|
||
Bug Tracker | ||
=========== | ||
|
||
Bugs are tracked on `GitHub Issues <https://github.com/OCA/dms/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 <https://github.com/OCA/dms/issues/new?body=module:%20dms_version%0Aversion:%2013.0%0A%0A**Steps%20to%20reproduce**%0A-%20...%0A%0A**Current%20behavior**%0A%0A**Expected%20behavior**>`_. | ||
|
||
Do not contact contributors directly about support or help with technical issues. | ||
|
||
Credits | ||
======= | ||
|
||
Authors | ||
~~~~~~~ | ||
|
||
* MuK IT | ||
* Tecnativa | ||
* elego | ||
|
||
Contributors | ||
~~~~~~~~~~~~ | ||
|
||
* Mathias Markl <[email protected]> | ||
* `Tecnativa <https://www.tecnativa.com>`_: | ||
|
||
* Víctor Martínez | ||
|
||
* `AgentERP <https://www.agenterp.com>`_: | ||
|
||
* Maria Sparenberg <[email protected]> | ||
|
||
* `Elego <https://www.elegosoft.com>`_: | ||
|
||
* Yu Weng <[email protected]> | ||
|
||
Maintainers | ||
~~~~~~~~~~~ | ||
|
||
This module is maintained by the OCA. | ||
|
||
.. image:: https://odoo-community.org/logo.png | ||
:alt: Odoo Community Association | ||
:target: https://odoo-community.org | ||
|
||
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. | ||
|
||
This module is part of the `OCA/dms <https://github.com/OCA/dms/tree/13.0/dms_version>`_ project on GitHub. | ||
|
||
You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute. |
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 @@ | ||
# Copyright 2017-2020 MuK IT GmbH | ||
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl). | ||
|
||
from . import models | ||
from . import wizard |
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 @@ | ||
# Copyright 2017-2020 MuK IT GmbH | ||
# Copyright 2021 Tecnativa - Víctor Martínez | ||
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl). | ||
|
||
{ | ||
"name": "Document Management System Version", | ||
"summary": """Version Control for Documents""", | ||
"version": "14.0.1.0.0", | ||
"category": "Document Management", | ||
"license": "AGPL-3", | ||
"website": "https://github.com/OCA/dms", | ||
"author": """MuK IT, | ||
Tecnativa, | ||
elego Software Solutions Gmbh, | ||
Odoo Community Association (OCA)""", | ||
"depends": ["dms", "base_revision"], | ||
"data": [ | ||
"security/ir.model.access.csv", | ||
"security/security.xml", | ||
"wizard/restore_old_revision_view.xml", | ||
"views/dms_file_view.xml", | ||
"views/dms_directory_view.xml", | ||
"views/dms_storage_view.xml", | ||
], | ||
"maintainers": ["victoralmau"], | ||
"application": False, | ||
} |
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,6 @@ | ||
# Copyright 2017-2020 MuK IT GmbH | ||
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl). | ||
|
||
from . import dms_file | ||
from . import dms_directory | ||
from . import dms_storage |
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,26 @@ | ||
# Copyright 2017-2020 MuK IT GmbH | ||
# Copyright 2021 Tecnativa - Víctor Martínez | ||
# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl). | ||
|
||
from odoo import api, fields, models | ||
|
||
|
||
class DmsDirectory(models.Model): | ||
_inherit = "dms.directory" | ||
|
||
has_versioning = fields.Boolean( | ||
default=False, | ||
help="Indicates if files have an active version control.", | ||
) | ||
|
||
@api.onchange("storage_id") | ||
def _onchange_storage_id(self): | ||
for record in self: | ||
if record.storage_id.save_type != "attachment" and record.is_root_directory: | ||
record.has_versioning = record.storage_id.has_versioning | ||
|
||
@api.onchange("parent_id") | ||
def _onchange_parent_id(self): | ||
for record in self: | ||
if record.parent_id: | ||
record.has_versioning = record.parent_id.has_versioning |
Oops, something went wrong.