odoo-addon-dms 18.0.1.0.5.1__py3-none-any.whl → 18.0.1.0.6.3__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -35,21 +35,18 @@ msgstr ""
35
35
  #. module: dms
36
36
  #. odoo-python
37
37
  #: code:addons/dms/models/access_groups.py:0
38
- #, python-format
39
38
  msgid "%s (copy)"
40
39
  msgstr ""
41
40
 
42
41
  #. module: dms
43
42
  #. odoo-python
44
43
  #: code:addons/dms/models/directory.py:0
45
- #, python-format
46
44
  msgid "%s Files"
47
45
  msgstr ""
48
46
 
49
47
  #. module: dms
50
48
  #. odoo-python
51
49
  #: code:addons/dms/models/directory.py:0
52
- #, python-format
53
50
  msgid "%s Subdirectories"
54
51
  msgstr ""
55
52
 
@@ -142,6 +139,30 @@ msgid ""
142
139
  " Unlock"
143
140
  msgstr ""
144
141
 
142
+ #. module: dms
143
+ #: model_terms:ir.ui.view,arch_db:dms.view_dms_directory_kanban
144
+ msgid ""
145
+ "<i class=\"fa fa-xs fa-file\"/>\n"
146
+ " <span>&amp;nbsp;</span>"
147
+ msgstr ""
148
+
149
+ #. module: dms
150
+ #: model_terms:ir.ui.view,arch_db:dms.view_dms_directory_kanban
151
+ msgid ""
152
+ "<i class=\"fa fa-xs fa-folder\"/>\n"
153
+ " <span>&amp;nbsp;</span>"
154
+ msgstr ""
155
+
156
+ #. module: dms
157
+ #: model_terms:ir.ui.view,arch_db:dms.view_dms_directory_kanban
158
+ msgid "<span class=\"ms-1\">Directories</span>"
159
+ msgstr ""
160
+
161
+ #. module: dms
162
+ #: model_terms:ir.ui.view,arch_db:dms.view_dms_directory_kanban
163
+ msgid "<span class=\"ms-1\">Files</span>"
164
+ msgstr ""
165
+
145
166
  #. module: dms
146
167
  #: model_terms:ir.ui.view,arch_db:dms.view_dms_directory_form
147
168
  msgid ""
@@ -151,8 +172,8 @@ msgid ""
151
172
  msgstr ""
152
173
 
153
174
  #. module: dms
175
+ #: model_terms:ir.ui.view,arch_db:dms.view_dms_directory_kanban
154
176
  #: model_terms:ir.ui.view,arch_db:dms.view_dms_file_kanban
155
- #: model_terms:ir.ui.view,arch_db:dms.view_dms_tag_kanban
156
177
  msgid "<span>Actions</span>"
157
178
  msgstr ""
158
179
 
@@ -166,6 +187,11 @@ msgstr ""
166
187
  msgid "<span>Operations</span>"
167
188
  msgstr ""
168
189
 
190
+ #. module: dms
191
+ #: model_terms:ir.ui.view,arch_db:dms.view_dms_directory_kanban
192
+ msgid "<span>Views</span>"
193
+ msgstr ""
194
+
169
195
  #. module: dms
170
196
  #: model:ir.model.fields,help:dms.field_dms_directory__alias_defaults
171
197
  msgid ""
@@ -176,49 +202,42 @@ msgstr ""
176
202
  #. module: dms
177
203
  #. odoo-python
178
204
  #: code:addons/dms/models/directory.py:0
179
- #, python-format
180
205
  msgid "A directory can't be a root and have a parent directory."
181
206
  msgstr ""
182
207
 
183
208
  #. module: dms
184
209
  #. odoo-python
185
210
  #: code:addons/dms/models/directory.py:0
186
- #, python-format
187
211
  msgid "A directory has to have a parent directory."
188
212
  msgstr ""
189
213
 
190
214
  #. module: dms
191
215
  #. odoo-python
192
216
  #: code:addons/dms/models/directory.py:0
193
- #, python-format
194
217
  msgid "A directory has to have model in attachment storage."
195
218
  msgstr ""
196
219
 
197
220
  #. module: dms
198
221
  #. odoo-python
199
222
  #: code:addons/dms/models/directory.py:0
200
- #, python-format
201
223
  msgid "A directory with the same name already exists."
202
224
  msgstr ""
203
225
 
204
226
  #. module: dms
205
227
  #. odoo-python
206
228
  #: code:addons/dms/models/dms_file.py:0
207
- #, python-format
208
229
  msgid "A file must have model and resource ID in attachment storage."
209
230
  msgstr ""
210
231
 
211
232
  #. module: dms
212
233
  #. odoo-python
213
234
  #: code:addons/dms/models/dms_file.py:0
214
- #, python-format
215
235
  msgid "A file with the same name already exists in this directory."
216
236
  msgstr ""
217
237
 
218
238
  #. module: dms
219
239
  #. odoo-python
220
240
  #: code:addons/dms/models/directory.py:0
221
- #, python-format
222
241
  msgid "A root directory has to have a storage."
223
242
  msgstr ""
224
243
 
@@ -262,11 +281,6 @@ msgstr ""
262
281
  msgid "Action Needed"
263
282
  msgstr ""
264
283
 
265
- #. module: dms
266
- #: model_terms:ir.ui.view,arch_db:dms.view_dms_directory_kanban
267
- msgid "Actions"
268
- msgstr ""
269
-
270
284
  #. module: dms
271
285
  #: model:ir.model.fields,field_description:dms.field_dms_category__active
272
286
  #: model:ir.model.fields,field_description:dms.field_dms_tag__active
@@ -367,7 +381,6 @@ msgstr ""
367
381
  #. module: dms
368
382
  #. odoo-python
369
383
  #: code:addons/dms/models/directory.py:0
370
- #, python-format
371
384
  msgid "Alias-Mail-Extraction"
372
385
  msgstr ""
373
386
 
@@ -390,7 +403,6 @@ msgstr ""
390
403
  #. module: dms
391
404
  #. odoo-javascript
392
405
  #: code:addons/dms/static/src/js/views/dms_file_upload.esm.js:0
393
- #, python-format
394
406
  msgid "An error occurred during the upload"
395
407
  msgstr ""
396
408
 
@@ -418,11 +430,8 @@ msgid "Are you sure? All files will be moved."
418
430
  msgstr ""
419
431
 
420
432
  #. module: dms
421
- #. odoo-python
422
- #: code:addons/dms/models/storage.py:0
423
433
  #: model:ir.model,name:dms.model_ir_attachment
424
434
  #: model:ir.model.fields.selection,name:dms.selection__dms_storage__save_type__attachment
425
- #, python-format
426
435
  msgid "Attachment"
427
436
  msgstr ""
428
437
 
@@ -778,10 +787,7 @@ msgid "DMS thumbnail and icon mixin"
778
787
  msgstr ""
779
788
 
780
789
  #. module: dms
781
- #. odoo-python
782
- #: code:addons/dms/models/storage.py:0
783
790
  #: model:ir.model.fields.selection,name:dms.selection__dms_storage__save_type__database
784
- #, python-format
785
791
  msgid "Database"
786
792
  msgstr ""
787
793
 
@@ -865,6 +871,12 @@ msgstr ""
865
871
  msgid "Display Name"
866
872
  msgstr ""
867
873
 
874
+ #. module: dms
875
+ #. odoo-javascript
876
+ #: code:addons/dms/static/src/js/fields/path_json/path_owl.esm.js:0
877
+ msgid "Dms Path Field"
878
+ msgstr ""
879
+
868
880
  #. module: dms
869
881
  #: model:ir.model,name:dms.model_dms_category
870
882
  msgid "Document Category"
@@ -946,14 +958,12 @@ msgstr ""
946
958
  #. module: dms
947
959
  #. odoo-python
948
960
  #: code:addons/dms/models/dms_category.py:0
949
- #, python-format
950
961
  msgid "Error! You cannot create recursive categories."
951
962
  msgstr ""
952
963
 
953
964
  #. module: dms
954
965
  #. odoo-python
955
966
  #: code:addons/dms/models/directory.py:0
956
- #, python-format
957
967
  msgid "Error! You cannot create recursive directories."
958
968
  msgstr ""
959
969
 
@@ -1042,10 +1052,7 @@ msgid "Files are used to save content directly in Odoo."
1042
1052
  msgstr ""
1043
1053
 
1044
1054
  #. module: dms
1045
- #. odoo-python
1046
- #: code:addons/dms/models/storage.py:0
1047
1055
  #: model:ir.model.fields.selection,name:dms.selection__dms_storage__save_type__file
1048
- #, python-format
1049
1056
  msgid "Filestore"
1050
1057
  msgstr ""
1051
1058
 
@@ -1303,7 +1310,6 @@ msgstr ""
1303
1310
  #. module: dms
1304
1311
  #. odoo-python
1305
1312
  #: code:addons/dms/models/dms_file.py:0
1306
- #, python-format
1307
1313
  msgid "Invalid attachments!"
1308
1314
  msgstr ""
1309
1315
 
@@ -1326,14 +1332,12 @@ msgstr ""
1326
1332
  #. module: dms
1327
1333
  #. odoo-python
1328
1334
  #: code:addons/dms/models/directory.py:0
1329
- #, python-format
1330
1335
  msgid "It is not possible to change the storage."
1331
1336
  msgstr ""
1332
1337
 
1333
1338
  #. module: dms
1334
1339
  #. odoo-python
1335
1340
  #: code:addons/dms/models/directory.py:0
1336
- #, python-format
1337
1341
  msgid "It is not possible to change to a parent with other storage."
1338
1342
  msgstr ""
1339
1343
 
@@ -1456,7 +1460,6 @@ msgstr ""
1456
1460
  #. module: dms
1457
1461
  #. odoo-python
1458
1462
  #: code:addons/dms/models/dms_file.py:0
1459
- #, python-format
1460
1463
  msgid "Migrate File %(index)s of %(record_count)s [ %(dms_file_migration)s ]"
1461
1464
  msgstr ""
1462
1465
 
@@ -1529,7 +1532,6 @@ msgstr ""
1529
1532
  #: model:ir.model.fields,field_description:dms.field_dms_storage__name
1530
1533
  #: model:ir.model.fields,field_description:dms.field_dms_tag__name
1531
1534
  #: model_terms:ir.ui.view,arch_db:dms.portal_my_dms
1532
- #, python-format
1533
1535
  msgid "Name"
1534
1536
  msgstr ""
1535
1537
 
@@ -1570,7 +1572,6 @@ msgstr ""
1570
1572
  #. module: dms
1571
1573
  #. odoo-python
1572
1574
  #: code:addons/dms/models/dms_file.py:0
1573
- #, python-format
1574
1575
  msgid "No attachment was provided"
1575
1576
  msgstr ""
1576
1577
 
@@ -1644,14 +1645,12 @@ msgstr ""
1644
1645
  #. module: dms
1645
1646
  #. odoo-python
1646
1647
  #: code:addons/dms/models/dms_file.py:0
1647
- #, python-format
1648
1648
  msgid "Only files in the same root directory can be moved."
1649
1649
  msgstr ""
1650
1650
 
1651
1651
  #. module: dms
1652
1652
  #. odoo-python
1653
1653
  #: code:addons/dms/models/storage.py:0
1654
- #, python-format
1655
1654
  msgid "Only managers can execute this action."
1656
1655
  msgstr ""
1657
1656
 
@@ -1703,7 +1702,6 @@ msgstr ""
1703
1702
  #. module: dms
1704
1703
  #. odoo-python
1705
1704
  #: code:addons/dms/models/access_groups.py:0
1706
- #, python-format
1707
1705
  msgid "Parent group '%(parent)s' is child of '%(current)s'."
1708
1706
  msgstr ""
1709
1707
 
@@ -1755,10 +1753,15 @@ msgstr ""
1755
1753
  #. module: dms
1756
1754
  #. odoo-javascript
1757
1755
  #: code:addons/dms/static/src/js/fields/preview_binary/preview_record.xml:0
1758
- #, python-format
1759
1756
  msgid "Preview"
1760
1757
  msgstr ""
1761
1758
 
1759
+ #. module: dms
1760
+ #. odoo-javascript
1761
+ #: code:addons/dms/static/src/js/fields/preview_binary/preview_record.esm.js:0
1762
+ msgid "Preview Record"
1763
+ msgstr ""
1764
+
1762
1765
  #. module: dms
1763
1766
  #: model:dms.tag,name:dms.tag_10_demo
1764
1767
  msgid "Product"
@@ -1860,7 +1863,6 @@ msgstr ""
1860
1863
  #. odoo-javascript
1861
1864
  #: code:addons/dms/static/src/js/views/file_kanban_renderer.xml:0
1862
1865
  #: code:addons/dms/static/src/js/views/file_list_renderer.xml:0
1863
- #, python-format
1864
1866
  msgid "Scan"
1865
1867
  msgstr ""
1866
1868
 
@@ -2040,28 +2042,24 @@ msgstr ""
2040
2042
  #. module: dms
2041
2043
  #. odoo-python
2042
2044
  #: code:addons/dms/models/directory.py:0
2043
- #, python-format
2044
2045
  msgid "The directory name is invalid."
2045
2046
  msgstr ""
2046
2047
 
2047
2048
  #. module: dms
2048
2049
  #. odoo-python
2049
2050
  #: code:addons/dms/models/dms_file.py:0
2050
- #, python-format
2051
2051
  msgid "The file has a forbidden file extension."
2052
2052
  msgstr ""
2053
2053
 
2054
2054
  #. module: dms
2055
2055
  #. odoo-python
2056
2056
  #: code:addons/dms/models/dms_file.py:0
2057
- #, python-format
2058
2057
  msgid "The file name is invalid."
2059
2058
  msgstr ""
2060
2059
 
2061
2060
  #. module: dms
2062
2061
  #. odoo-python
2063
2062
  #: code:addons/dms/models/dms_file.py:0
2064
- #, python-format
2065
2063
  msgid "The maximum upload size is %s MB."
2066
2064
  msgstr ""
2067
2065
 
@@ -2099,7 +2097,6 @@ msgstr ""
2099
2097
  #. module: dms
2100
2098
  #. odoo-python
2101
2099
  #: code:addons/dms/models/directory.py:0
2102
- #, python-format
2103
2100
  msgid "This directory needs to be associated to a record."
2104
2101
  msgstr ""
2105
2102
 
@@ -2159,7 +2156,6 @@ msgstr ""
2159
2156
  #: code:addons/dms/static/src/js/views/file_kanban_controller.xml:0
2160
2157
  #: code:addons/dms/static/src/js/views/file_kanban_renderer.xml:0
2161
2158
  #: code:addons/dms/static/src/js/views/file_list_renderer.xml:0
2162
- #, python-format
2163
2159
  msgid "Upload"
2164
2160
  msgstr ""
2165
2161
 
@@ -2189,11 +2185,6 @@ msgstr ""
2189
2185
  msgid "Vendor Bill"
2190
2186
  msgstr ""
2191
2187
 
2192
- #. module: dms
2193
- #: model_terms:ir.ui.view,arch_db:dms.view_dms_directory_kanban
2194
- msgid "Views"
2195
- msgstr ""
2196
-
2197
2188
  #. module: dms
2198
2189
  #: model:ir.model.fields,field_description:dms.field_dms_directory__website_message_ids
2199
2190
  #: model:ir.model.fields,field_description:dms.field_dms_file__website_message_ids
@@ -2227,7 +2218,6 @@ msgstr ""
2227
2218
  #. module: dms
2228
2219
  #. odoo-javascript
2229
2220
  #: code:addons/dms/static/src/js/views/dms_file_upload.esm.js:0
2230
- #, python-format
2231
2221
  msgid "You must select a directory first"
2232
2222
  msgstr ""
2233
2223
 
@@ -275,6 +275,17 @@ class DmsSecurityMixin(models.AbstractModel):
275
275
  result |= self._filtered_access_no_recursion(operation)
276
276
  return result
277
277
 
278
+ def _check_access_dms_record(self, operation: str) -> tuple | None:
279
+ """Specific method "similar" to _check_access() but with a different
280
+ behavior: check if you do not really have access to any of the records
281
+ in to avoid performing the corresponding create/write/unlink action."""
282
+ if any(self._ids) and not self.env.su:
283
+ Rule = self.env["ir.rule"]
284
+ domain = Rule._compute_domain(self._name, operation)
285
+ items = self.search(domain)
286
+ if any(x_id not in items.ids for x_id in self.ids):
287
+ raise Rule._make_access_error(operation, (self - items))
288
+
278
289
  @api.model_create_multi
279
290
  def create(self, vals_list):
280
291
  # Create as sudo to avoid testing creation permissions before DMS security
@@ -285,5 +296,13 @@ class DmsSecurityMixin(models.AbstractModel):
285
296
  res.flush_recordset()
286
297
  # Go back to the original sudo state and check we really had creation permission
287
298
  res = res.sudo(self.env.su)
288
- res.check_access("create")
299
+ res._check_access_dms_record("create")
289
300
  return res
301
+
302
+ def write(self, vals):
303
+ self._check_access_dms_record("write")
304
+ return super().write(vals)
305
+
306
+ def unlink(self):
307
+ self._check_access_dms_record("unlink")
308
+ return super().unlink()
@@ -3,7 +3,7 @@
3
3
  <head>
4
4
  <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
5
5
  <meta name="generator" content="Docutils: https://docutils.sourceforge.io/" />
6
- <title>Document Management System</title>
6
+ <title>README.rst</title>
7
7
  <style type="text/css">
8
8
 
9
9
  /*
@@ -360,16 +360,21 @@ ul.auto-toc {
360
360
  </style>
361
361
  </head>
362
362
  <body>
363
- <div class="document" id="document-management-system">
364
- <h1 class="title">Document Management System</h1>
363
+ <div class="document">
365
364
 
365
+
366
+ <a class="reference external image-reference" href="https://odoo-community.org/get-involved?utm_source=readme">
367
+ <img alt="Odoo Community Association" src="https://odoo-community.org/readme-banner-image" />
368
+ </a>
369
+ <div class="section" id="document-management-system">
370
+ <h1>Document Management System</h1>
366
371
  <!-- !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
367
372
  !! This file is generated by oca-gen-addon-readme !!
368
373
  !! changes will be overwritten. !!
369
374
  !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
370
- !! source digest: sha256:6cc32ae7c862eb90d0e1bdc14bd5cf0c6a0cc45ec00095fbbaa2e6b2a7b91972
375
+ !! source digest: sha256:45ce312f2b0dafc58147b67c526a9005653f2ba9a9208468707b3a5986c7450c
371
376
  !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! -->
372
- <p><a class="reference external image-reference" href="https://odoo-community.org/page/development-status"><img alt="Beta" src="https://img.shields.io/badge/maturity-Beta-yellow.png" /></a> <a class="reference external image-reference" href="http://www.gnu.org/licenses/lgpl-3.0-standalone.html"><img alt="License: LGPL-3" src="https://img.shields.io/badge/licence-LGPL--3-blue.png" /></a> <a class="reference external image-reference" href="https://github.com/OCA/dms/tree/18.0/dms"><img alt="OCA/dms" src="https://img.shields.io/badge/github-OCA%2Fdms-lightgray.png?logo=github" /></a> <a class="reference external image-reference" href="https://translation.odoo-community.org/projects/dms-18-0/dms-18-0-dms"><img alt="Translate me on Weblate" src="https://img.shields.io/badge/weblate-Translate%20me-F47D42.png" /></a> <a class="reference external image-reference" href="https://runboat.odoo-community.org/builds?repo=OCA/dms&amp;target_branch=18.0"><img alt="Try me on Runboat" src="https://img.shields.io/badge/runboat-Try%20me-875A7B.png" /></a></p>
377
+ <p><a class="reference external image-reference" href="https://odoo-community.org/page/development-status"><img alt="Beta" src="https://img.shields.io/badge/maturity-Beta-yellow.png" /></a> <a class="reference external image-reference" href="http://www.gnu.org/licenses/lgpl-3.0-standalone.html"><img alt="License: LGPL-3" src="https://img.shields.io/badge/license-LGPL--3-blue.png" /></a> <a class="reference external image-reference" href="https://github.com/OCA/dms/tree/18.0/dms"><img alt="OCA/dms" src="https://img.shields.io/badge/github-OCA%2Fdms-lightgray.png?logo=github" /></a> <a class="reference external image-reference" href="https://translation.odoo-community.org/projects/dms-18-0/dms-18-0-dms"><img alt="Translate me on Weblate" src="https://img.shields.io/badge/weblate-Translate%20me-F47D42.png" /></a> <a class="reference external image-reference" href="https://runboat.odoo-community.org/builds?repo=OCA/dms&amp;target_branch=18.0"><img alt="Try me on Runboat" src="https://img.shields.io/badge/runboat-Try%20me-875A7B.png" /></a></p>
373
378
  <p>DMS is a module for creating, managing and viewing document files
374
379
  directly within Odoo. This module is only the basis for an entire
375
380
  ecosystem of apps that extend and seamlessly integrate with the document
@@ -410,21 +415,21 @@ anonymous user.</p>
410
415
  </ul>
411
416
  </div>
412
417
  <div class="section" id="installation">
413
- <h1><a class="toc-backref" href="#toc-entry-1">Installation</a></h1>
418
+ <h2><a class="toc-backref" href="#toc-entry-1">Installation</a></h2>
414
419
  <div class="section" id="preview">
415
- <h2><a class="toc-backref" href="#toc-entry-2">Preview</a></h2>
420
+ <h3><a class="toc-backref" href="#toc-entry-2">Preview</a></h3>
416
421
  <p><tt class="docutils literal"><span class="pre">python-magic</span></tt> library is recommended to be installed for having whole
417
422
  support to get proper file types and file preview.</p>
418
423
  </div>
419
424
  </div>
420
425
  <div class="section" id="configuration">
421
- <h1><a class="toc-backref" href="#toc-entry-3">Configuration</a></h1>
426
+ <h2><a class="toc-backref" href="#toc-entry-3">Configuration</a></h2>
422
427
  </div>
423
428
  <div class="section" id="configuration-1">
424
- <h1><a class="toc-backref" href="#toc-entry-4">Configuration</a></h1>
429
+ <h2><a class="toc-backref" href="#toc-entry-4">Configuration</a></h2>
425
430
  <p>To configure this module, you need to:</p>
426
431
  <div class="section" id="create-a-storage">
427
- <h2><a class="toc-backref" href="#toc-entry-5">1. Create a storage</a></h2>
432
+ <h3><a class="toc-backref" href="#toc-entry-5">1. Create a storage</a></h3>
428
433
  <ol class="arabic simple">
429
434
  <li>Go to <em>Documents -&gt; Configuration -&gt; Storages</em>.</li>
430
435
  <li>Create a new document storage. You can choose between three options
@@ -437,7 +442,7 @@ on <tt class="docutils literal">Save Type</tt>:<ul>
437
442
  </ol>
438
443
  </div>
439
444
  <div class="section" id="create-an-access-group">
440
- <h2><a class="toc-backref" href="#toc-entry-6">2. Create an access group</a></h2>
445
+ <h3><a class="toc-backref" href="#toc-entry-6">2. Create an access group</a></h3>
441
446
  <ol class="arabic simple">
442
447
  <li>Next, create an administrative access group. Go to <em>Configuration -&gt;
443
448
  Access Groups</em>.<ul>
@@ -453,7 +458,7 @@ control.</li>
453
458
  </ol>
454
459
  </div>
455
460
  <div class="section" id="create-a-directory">
456
- <h2><a class="toc-backref" href="#toc-entry-7">3. Create a directory</a></h2>
461
+ <h3><a class="toc-backref" href="#toc-entry-7">3. Create a directory</a></h3>
457
462
  <ol class="arabic simple">
458
463
  <li>Afterward, go to <em>Documents -&gt; Directories</em>.</li>
459
464
  <li>Create a new directory, mark it as root and select the previously
@@ -476,7 +481,7 @@ Groups</em>).</li>
476
481
  </div>
477
482
  </div>
478
483
  <div class="section" id="migration">
479
- <h1><a class="toc-backref" href="#toc-entry-8">Migration</a></h1>
484
+ <h2><a class="toc-backref" href="#toc-entry-8">Migration</a></h2>
480
485
  <p>If you need to modify the storage <tt class="docutils literal">Save Type</tt> you might want to
481
486
  migrate the file data. To achieve it, you need to:</p>
482
487
  <ol class="arabic simple">
@@ -492,19 +497,19 @@ storages and migrate them manually on <em>Documents -&gt; Configuration -&gt;
492
497
  Migration</em></p>
493
498
  </div>
494
499
  <div class="section" id="file-wizard-selection">
495
- <h1><a class="toc-backref" href="#toc-entry-9">File Wizard Selection</a></h1>
500
+ <h2><a class="toc-backref" href="#toc-entry-9">File Wizard Selection</a></h2>
496
501
  <p>There is an action called <tt class="docutils literal">action_dms_file_wizard_selector</tt> to open a
497
502
  wizard to list files in kanban view. This can be used (example
498
503
  dms_attachment_link module) to add a button in kanban view with the
499
504
  action we need.</p>
500
505
  </div>
501
506
  <div class="section" id="usage">
502
- <h1><a class="toc-backref" href="#toc-entry-10">Usage</a></h1>
507
+ <h2><a class="toc-backref" href="#toc-entry-10">Usage</a></h2>
503
508
  <p>The best way to manage the documents is to switch to the Documents view.
504
509
  Existing documents can be managed there and new documents can be
505
510
  created.</p>
506
511
  <div class="section" id="portal-functionality">
507
- <h2><a class="toc-backref" href="#toc-entry-11">Portal functionality</a></h2>
512
+ <h3><a class="toc-backref" href="#toc-entry-11">Portal functionality</a></h3>
508
513
  <p>You can add any portal user to DMS access groups, and then allow that
509
514
  group in directories, so they will see in the portal such directories
510
515
  and their files. Another possibility is to click on “Share” button
@@ -513,7 +518,7 @@ access to that resource, no matter if logged or not.</p>
513
518
  </div>
514
519
  </div>
515
520
  <div class="section" id="known-issues-roadmap">
516
- <h1><a class="toc-backref" href="#toc-entry-12">Known issues / Roadmap</a></h1>
521
+ <h2><a class="toc-backref" href="#toc-entry-12">Known issues / Roadmap</a></h2>
517
522
  <ul class="simple">
518
523
  <li>Files preview in portal</li>
519
524
  <li>Allow to download folder in portal and create zip file with all
@@ -540,7 +545,7 @@ any part of Odoo.</li>
540
545
  </ul>
541
546
  </div>
542
547
  <div class="section" id="bug-tracker">
543
- <h1><a class="toc-backref" href="#toc-entry-13">Bug Tracker</a></h1>
548
+ <h2><a class="toc-backref" href="#toc-entry-13">Bug Tracker</a></h2>
544
549
  <p>Bugs are tracked on <a class="reference external" href="https://github.com/OCA/dms/issues">GitHub Issues</a>.
545
550
  In case of trouble, please check there if your issue has already been reported.
546
551
  If you spotted it first, help us to smash it by providing a detailed and welcomed
@@ -548,16 +553,16 @@ If you spotted it first, help us to smash it by providing a detailed and welcome
548
553
  <p>Do not contact contributors directly about support or help with technical issues.</p>
549
554
  </div>
550
555
  <div class="section" id="credits">
551
- <h1><a class="toc-backref" href="#toc-entry-14">Credits</a></h1>
556
+ <h2><a class="toc-backref" href="#toc-entry-14">Credits</a></h2>
552
557
  <div class="section" id="authors">
553
- <h2><a class="toc-backref" href="#toc-entry-15">Authors</a></h2>
558
+ <h3><a class="toc-backref" href="#toc-entry-15">Authors</a></h3>
554
559
  <ul class="simple">
555
560
  <li>MuK IT</li>
556
561
  <li>Tecnativa</li>
557
562
  </ul>
558
563
  </div>
559
564
  <div class="section" id="contributors">
560
- <h2><a class="toc-backref" href="#toc-entry-16">Contributors</a></h2>
565
+ <h3><a class="toc-backref" href="#toc-entry-16">Contributors</a></h3>
561
566
  <ul class="simple">
562
567
  <li>Mathias Markl &lt;<a class="reference external" href="mailto:mathias.markl&#64;mukit.at">mathias.markl&#64;mukit.at</a>&gt;</li>
563
568
  <li>Enric Tobella &lt;<a class="reference external" href="mailto:etobella&#64;creublanca.es">etobella&#64;creublanca.es</a>&gt;</li>
@@ -586,7 +591,7 @@ If you spotted it first, help us to smash it by providing a detailed and welcome
586
591
  </ul>
587
592
  </div>
588
593
  <div class="section" id="other-credits">
589
- <h2><a class="toc-backref" href="#toc-entry-17">Other credits</a></h2>
594
+ <h3><a class="toc-backref" href="#toc-entry-17">Other credits</a></h3>
590
595
  <p>Some pictures are based on or inspired by:</p>
591
596
  <ul class="simple">
592
597
  <li><a class="reference external" href="https://www.flaticon.com/authors/roundicons">Roundicons</a></li>
@@ -597,7 +602,7 @@ DMS icon</li>
597
602
  </ul>
598
603
  </div>
599
604
  <div class="section" id="maintainers">
600
- <h2><a class="toc-backref" href="#toc-entry-18">Maintainers</a></h2>
605
+ <h3><a class="toc-backref" href="#toc-entry-18">Maintainers</a></h3>
601
606
  <p>This module is maintained by the OCA.</p>
602
607
  <a class="reference external image-reference" href="https://odoo-community.org">
603
608
  <img alt="Odoo Community Association" src="https://odoo-community.org/logo.png" />
@@ -610,5 +615,6 @@ promote its widespread use.</p>
610
615
  </div>
611
616
  </div>
612
617
  </div>
618
+ </div>
613
619
  </body>
614
620
  </html>
@@ -6,7 +6,9 @@
6
6
 
7
7
  import os
8
8
 
9
- from odoo.exceptions import UserError
9
+ from odoo import Command
10
+ from odoo.exceptions import AccessError, UserError
11
+ from odoo.tests import new_test_user
10
12
  from odoo.tests.common import users
11
13
  from odoo.tools import mute_logger
12
14
 
@@ -266,6 +268,18 @@ class DirectoryTestCaseBase(StorageDatabaseBaseCase):
266
268
  msg="The tag_ids field should be a multi range field",
267
269
  )
268
270
 
271
+ def test_directory_unlink_custom(self):
272
+ user = new_test_user(
273
+ self.env, login="test-dms-customer-user", groups="dms.group_dms_user"
274
+ )
275
+ group = self.access_group_model.create(
276
+ {"name": "Test read group", "explicit_user_ids": [Command.set(user.ids)]}
277
+ )
278
+ root_directory = self.create_directory(storage=self.storage)
279
+ root_directory.group_ids = [Command.link(group.id)]
280
+ with self.assertRaises(AccessError):
281
+ root_directory.with_user(user).unlink()
282
+
269
283
 
270
284
  class DirectoryMailTestCase(StorageDatabaseBaseCase):
271
285
  @classmethod
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: odoo-addon-dms
3
- Version: 18.0.1.0.5.1
3
+ Version: 18.0.1.0.6.3
4
4
  Requires-Python: >=3.10
5
5
  Requires-Dist: odoo==18.0.*
6
6
  Summary: Document Management System for Odoo
@@ -13,6 +13,10 @@ Classifier: Framework :: Odoo
13
13
  Classifier: Framework :: Odoo :: 18.0
14
14
  Classifier: License :: OSI Approved :: GNU Lesser General Public License v3 (LGPLv3)
15
15
 
16
+ .. image:: https://odoo-community.org/readme-banner-image
17
+ :target: https://odoo-community.org/get-involved?utm_source=readme
18
+ :alt: Odoo Community Association
19
+
16
20
  ==========================
17
21
  Document Management System
18
22
  ==========================
@@ -22,13 +26,13 @@ Document Management System
22
26
  !! This file is generated by oca-gen-addon-readme !!
23
27
  !! changes will be overwritten. !!
24
28
  !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
25
- !! source digest: sha256:6cc32ae7c862eb90d0e1bdc14bd5cf0c6a0cc45ec00095fbbaa2e6b2a7b91972
29
+ !! source digest: sha256:45ce312f2b0dafc58147b67c526a9005653f2ba9a9208468707b3a5986c7450c
26
30
  !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
27
31
 
28
32
  .. |badge1| image:: https://img.shields.io/badge/maturity-Beta-yellow.png
29
33
  :target: https://odoo-community.org/page/development-status
30
34
  :alt: Beta
31
- .. |badge2| image:: https://img.shields.io/badge/licence-LGPL--3-blue.png
35
+ .. |badge2| image:: https://img.shields.io/badge/license-LGPL--3-blue.png
32
36
  :target: http://www.gnu.org/licenses/lgpl-3.0-standalone.html
33
37
  :alt: License: LGPL-3
34
38
  .. |badge3| image:: https://img.shields.io/badge/github-OCA%2Fdms-lightgray.png?logo=github