Roberto Rosario
c7e9a4dc99
Add keyword arguments
...
Signed-off-by: Roberto Rosario <roberto.rosario.gonzalez@gmail.com >
2019-05-12 02:09:26 -04:00
Roberto Rosario
4617afafb2
Replace get_object_list() with self.object_list
...
Signed-off-by: Roberto Rosario <roberto.rosario.gonzalez@gmail.com >
2019-05-12 01:25:53 -04:00
Roberto Rosario
74ec939779
Fix optional metadata remove
...
Soleve issue of removing an optional document metadata
from a document that also contained existing required metadata.
Signed-off-by: Roberto Rosario <roberto.rosario.gonzalez@gmail.com >
2019-05-11 18:14:01 -04:00
Roberto Rosario
6330e40036
Use get_object_list instead of get_queryset
...
Signed-off-by: Roberto Rosario <roberto.rosario.gonzalez@gmail.com >
2019-05-07 03:17:52 -04:00
Roberto Rosario
5e4518211f
Remove related attribute of check_access
...
Remove filter_by_access. Replaced by restrict_queryset.
Signed-off-by: Roberto Rosario <roberto.rosario.gonzalez@gmail.com >
2019-05-07 02:26:50 -04:00
Roberto Rosario
95a1df8072
Backport common mixin and generics improvements
...
* Rename get_object_list to get_source_queryset.
* Add uniqueness validation to SingleObjectCreateView.
* Remove MultipleInstanceActionMixin.
* Backport MultipleObjectMixin improvements.
* Remove ObjectListPermissionFilterMixin.
* Add and improve tests.
Signed-off-by: Roberto Rosario <roberto.rosario.gonzalez@gmail.com >
2019-05-06 02:07:35 -04:00
Roberto Rosario
8e731d6280
Backport ACL computation improvements
...
Signed-off-by: Roberto Rosario <roberto.rosario.gonzalez@gmail.com >
2019-05-04 03:27:30 -04:00
Roberto Rosario
74c97314d7
Code style cleanups
...
Add keyword arguments. Sort arguments and models.
Move literals to their own module. Prepend handler_ to
signal handlers.
Signed-off-by: Roberto Rosario <roberto.rosario.gonzalez@gmail.com >
2019-04-26 03:32:35 -04:00
Roberto Rosario
1c5681c79d
Code style cleanups
...
Sort arguments, methods. Add keyword arguments.
Signed-off-by: Roberto Rosario <roberto.rosario.gonzalez@gmail.com >
2019-04-25 05:06:56 -04:00
Roberto Rosario
296c580a5e
Add sortable columns to all apps
...
Signed-off-by: Roberto Rosario <roberto.rosario.gonzalez@gmail.com >
2019-04-24 04:20:50 -04:00
Roberto Rosario
4c0b3e9134
Add keyword arguments to the reverse use in views
...
Signed-off-by: Roberto Rosario <Roberto.Rosario.Gonzalez@gmail.com >
2019-04-16 19:25:37 -04:00
Roberto Rosario
6bd8206236
Add keyword arguments to messages uses
...
Signed-off-by: Roberto Rosario <Roberto.Rosario.Gonzalez@gmail.com >
2019-04-16 19:02:41 -04:00
Roberto Rosario
f6f9287e33
Add keyword arguments to get_object_or_404 uses
...
Signed-off-by: Roberto Rosario <roberto.rosario.gonzalez@gmail.com >
2019-04-11 20:53:33 -04:00
Roberto Rosario
36a51eeb73
Switch to full app paths
...
Instead of inserting the path of the apps into the Python app,
the apps are now referenced by their full import path.
This solves name clashes with external or native Python libraries.
Example: Mayan statistics app vs. Python new statistics library.
Every app reference is now prepended with 'mayan.apps'.
Existing config.yml files need to be updated manually.
Signed-off-by: Roberto Rosario <roberto.rosario.gonzalez@gmail.com >
2019-04-05 02:02:57 -04:00
Roberto Rosario
4ad84195e0
Fix document metadata app view error when adding multiple optional metadata types. Closes GitLab issue #521 . Thanks to the TheOneValen @TheOneValen for the report.
...
Signed-off-by: Roberto Rosario <roberto.rosario.gonzalez@gmail.com >
2018-10-08 19:51:17 -04:00
Roberto Rosario
cdcf9096fb
Fix text and formatting typo.
...
Signed-off-by: Roberto Rosario <roberto.rosario.gonzalez@gmail.com >
2018-09-27 15:52:08 -04:00
Roberto Rosario
9f17d7662b
Add no results help text to the document type -> metadata type association view.
...
Signed-off-by: Roberto Rosario <roberto.rosario.gonzalez@gmail.com >
2018-09-26 16:52:13 -04:00
Roberto Rosario
5b806a43e9
Add creation icons for document cabinet, metadata, comments and tags links.
...
Signed-off-by: Roberto Rosario <roberto.rosario.gonzalez@gmail.com >
2018-09-06 01:46:48 -04:00
Roberto Rosario
64ca5a623f
PEP8 cleanups.
...
Signed-off-by: Roberto Rosario <roberto.rosario.gonzalez@gmail.com >
2018-09-05 04:56:39 -04:00
Roberto Rosario
d6b767eb93
Fix typos from the 3-way "papercut" patch merge.
...
Signed-off-by: Roberto Rosario <roberto.rosario.gonzalez@gmail.com >
2018-08-24 01:23:13 -04:00
Roberto Rosario
9273eccbd6
Add support for extended templates when there are no results. Add help messages and useful links to several apps when there are no results available.
...
Signed-off-by: Roberto Rosario <roberto.rosario.gonzalez@gmail.com >
2018-08-23 19:45:48 -04:00
Roberto Rosario
78c374dfe6
Add ACL support for metadata types.
...
Signed-off-by: Roberto Rosario <roberto.rosario.gonzalez@gmail.com >
2018-08-21 18:42:40 -04:00
Roberto Rosario
0022548e35
Add support for document metadata events: add, edit and remove.
...
Signed-off-by: Roberto Rosario <roberto.rosario.gonzalez@gmail.com >
2018-08-15 05:04:09 -04:00
Roberto Rosario
4e762d7522
Add new metadata app events: metadata type created, metadata type edited, metadata type to document type relationship update. Add link to metadata type events. Add support for subscribing to metadata type events.
...
Signed-off-by: Roberto Rosario <roberto.rosario.gonzalez@gmail.com >
2018-08-15 03:23:30 -04:00
Roberto Rosario
061366ffec
Update apps' other modules to use the new Icon class.
...
Signed-off-by: Roberto Rosario <roberto.rosario.gonzalez@gmail.com >
2018-06-29 02:54:14 -04:00
Roberto Rosario
bdd6849d83
Fix metadata edit form submit button icon.
...
Signed-off-by: Roberto Rosario <roberto.rosario.gonzalez@gmail.com >
2018-05-10 17:51:24 -04:00
Michael Price
d64f72351d
Customize the empty formset message for the document type metadata type relationship view.
...
Signed-off-by: Michael Price <loneviking72@gmail.com >
2018-04-01 01:52:42 -04:00
Roberto Rosario
2052caada4
Remove PreserveGetQuerySet mixin. Update SingleObjectList and
...
MultipleObjectFormActionView views to use a new get_object_list method.
Signed-off-by: Roberto Rosario <roberto.rosario.gonzalez@gmail.com >
2017-08-16 22:12:24 -04:00
Roberto Rosario
f09321f6ab
Fix deprecation warnings for Django 1.11 and Django 2.0.
...
Signed-off-by: Roberto Rosario <roberto.rosario.gonzalez@gmail.com >
2017-07-21 00:25:18 -04:00
Roberto Rosario
42a762481b
Fix issue when editing or removing metadata from multiple documents.
...
Bump version to 2.6.1.
Signed-off-by: Roberto Rosario <roberto.rosario.gonzalez@gmail.com >
2017-07-18 17:56:30 -04:00
Roberto Rosario
6c6ca38374
Replace all instances of unicode only handling to use force_text.
...
Replace all __unicode__ methods to __str__ and the
@python_2_unicode_compatible decorator.
Replace all instance of smart_str, smart_unicode, force_uncode
with force_text.
Signed-off-by: Roberto Rosario <roberto.rosario.gonzalez@gmail.com >
2017-07-05 15:03:24 -04:00
Roberto Rosario
95157460cb
Add new UI method to switch between required metadata and optional
...
metadata without incurring in metadata value loss.
Add modifying relationship of document type and metadata type
from the document type and from the metadata type views.
Closes GitLab issues #337 #373 .
Signed-off-by: Roberto Rosario <roberto.rosario.gonzalez@gmail.com >
2017-07-05 04:39:54 -04:00
Roberto Rosario
08dcbef2fc
Don't silence validation errors.
...
Signed-off-by: Roberto Rosario <roberto.rosario.gonzalez@gmail.com >
2017-06-12 16:18:03 -04:00
Roberto Rosario
6af1010f3a
Preload metadata add form with metadata type valid for the context document.
...
Signed-off-by: Roberto Rosario <roberto.rosario.gonzalez@gmail.com >
2017-06-12 16:16:28 -04:00
Roberto Rosario
c769f7bd1b
Don't silence exceptions in production mode.
...
Signed-off-by: Roberto Rosario <roberto.rosario.gonzalez@gmail.com >
2017-06-10 18:13:23 -04:00
Roberto Rosario
22a14d6a20
Fix document add metadata view and form to work when there are no documents in the view.
...
ie: when the user has no permissions.
2017-01-14 03:08:53 -04:00
Roberto Rosario
5167bbadee
Refactor the document metadata add, edit and remove views.
2016-12-28 00:57:04 -04:00
Roberto Rosario
5893e149e0
Reduce the check_access boilerplate code.
2016-11-02 04:58:05 -04:00
Roberto Rosario
621c988809
Simplify filter_by_access boilerplate code
2016-11-02 03:48:16 -04:00
Roberto Rosario
6bf352ecbb
Fix queryset assigment, should always be of MetadataType not DocumentTypeMetadataType, errors out on Postgres.
2016-03-15 18:39:48 -04:00
Roberto Rosario
ce6a1f4020
Merge branch 'master' into feature/merge_master
2016-03-03 16:46:11 -04:00
Roberto Rosario
03e7339f9b
Only extract validation error messages from ValidationError exception instances.
2016-02-10 02:26:57 -04:00
Roberto Rosario
24644e3538
Remove select_related using reverse related name field.
2016-01-27 18:34:32 -04:00
Roberto Rosario
460076004a
Fix GitLab issue #245 , "Add multiple metadata not possible"
2016-01-12 03:48:21 -04:00
Roberto Rosario
23270e948c
PEP8 cleanups.
2015-11-02 17:40:27 -04:00
Roberto Rosario
750127eb92
Raise PermissionDenied on single document access, show 'Selected at least 1 document' when the multidocument view is used. GL issue #240 .
2015-11-01 03:06:40 -04:00
Roberto Rosario
414c55f824
Update the metadata_add and metadata_remove views to use the new ACL filter_by_access code. Update and improve tests.
2015-10-23 02:52:27 -04:00
Roberto Rosario
8744bd82ee
Fix allow editing a required metadata after changing the document type. Closes issue GL #204 .
2015-10-15 16:40:35 -04:00
Roberto Rosario
cb98f0f2d2
Pass document_type to the remove metadata formset.
2015-10-10 02:44:29 -04:00
Roberto Rosario
7392e80fc2
PEP8 Cleanups.
2015-08-24 20:55:45 -04:00