External creation (crudity app)

Issue #26 open
Raphaël BECK
created an issue

No description provided.

Comments (149)

  1. Guillaume Englert

    refs #6 #26 Fix a lots of problems in emails.js: bugs, coding style and some code used by crudity ('crudity' should not depend on 'emails'). Bugs: GET instead of POST, new dialog API was not well used. Coding style: functions that were not named with camelCase convention. API breakings are listed in the CHANGELOG.

    → <<cset 821c85c63340>>

  2. Guillaume Englert

    refs #6 #26 Fix a lots of problems in emails.js: bugs, coding style and some code used by crudity ('crudity' should not depend on 'emails'). Bugs: GET instead of POST, new dialog API was not well used. Coding style: functions that were not named with camelCase convention. API breakings are listed in the CHANGELOG.

    → <<cset 821c85c63340>>

  3. Guillaume Englert

    refs #26 #95 Jobs can now have a custom configuration form ; Crudity sync use it for the default backend user.

    API breaking: - The setting CREME_GET_EMAIL_JOB_USER_ID is now only useful during the installation ; it will be removed in the next version.

    → <<cset 345558bfb78f>>

  4. Guillaume Englert

    refs #26 #95 Jobs can now have a custom configuration form ; Crudity sync use it for the default backend user.

    API breaking: - The setting CREME_GET_EMAIL_JOB_USER_ID is now only useful during the installation ; it will be removed in the next version.

    → <<cset 345558bfb78f>>

  5. Guillaume Englert

    refs #26 #29 Small improvements of tests for 'crudity', and code cleaning. Eg: now the 'pop'lib classes are mocked.

    API breaking: - In class crudity.fetchers.pop.PopFetcher, the following class attributes have been removed: server, username, password, port, is_ssl, ssl_keyfile, ssl_certfile. - In the module crudity.fetchers.pop, the following 'constants' have been removed: CREME_GET_EMAIL_SERVER, CREME_GET_EMAIL_USERNAME, CREME_GET_EMAIL_PASSWORD, CREME_GET_EMAIL_PORT, CREME_GET_EMAIL_SSL, CREME_GET_EMAIL_SSL_KEYFILE, CREME_GET_EMAIL_SSL_CERTFILE.

    → <<cset 27f15409683b>>

  6. Guillaume Englert

    refs #26 #29 Small improvements of tests for 'crudity', and code cleaning. Eg: now the 'pop'lib classes are mocked.

    API breaking: - In class crudity.fetchers.pop.PopFetcher, the following class attributes have been removed: server, username, password, port, is_ssl, ssl_keyfile, ssl_certfile. - In the module crudity.fetchers.pop, the following 'constants' have been removed: CREME_GET_EMAIL_SERVER, CREME_GET_EMAIL_USERNAME, CREME_GET_EMAIL_PASSWORD, CREME_GET_EMAIL_PORT, CREME_GET_EMAIL_SSL, CREME_GET_EMAIL_SSL_KEYFILE, CREME_GET_EMAIL_SSL_CERTFILE.

    → <<cset 27f15409683b>>

  7. Guillaume Englert

    refs #26 Fix several bugs related to name collision (backend with the same subject), in block relaoding & action validation. The validation of the configuration has been fixed, improved & tested.

    Note: in a backend configuration of settings.CRUDITY_BACKENDS, you can now omit input/method for the fallback subject "*".

    Behaviour changes: These changes are not real API breakings, because they can only reveal some problems in your current configuration.

    • In Crudity (settings.CRUDITY_BACKENDS): the subject (after normalisation) must be unique for a couple fetcher/input. Before, when a subject was duplicated between, only one input was used (the other ones were ignored) ; now a exception is raised.
    • If a backend cannot be used as a fallback, it will raised an exception with the rigth reason, instead of a "crash".
    • CRUDityRegistry.register_fetchers() now works correctly when it is called several times.

    Note: the new command 'crudity_factory' has problems with unicode characters ; it will be fixed later (is problem in the command or elsewhere ?).

    API breaking: - crudity.registry.CRUDityRegistry.get_configured_backend(): - takes now 3 arguments. - raises a KeyError instead of returning 'None'. - crudity.views.actions.reload() has been removed ; use crudity.views.actions.reload_block() instead. - crudity.blocks.WaitingActionBlock: generated ID has changed. - crudity: the characters in fetchers & inputs name must be letters, digit, underscore or dot. (check if you created your own file 'crudity_register.py'). - crudity.WaitingAction.source: when creating one, you must respect the pattern "fetcher_name - input_name" (or only "fetcher_name" for default backend) ; this was not clearly documented. - crudity_register: - 'fetchers' must now contain iterable of fetcher classes (& not instances anymore). - 'inputs' must now contain iterable of input classes (& not instances anymore). - crudity.registry.FetcherInterface.add_fetcher() is deprecated ; use add_fetchers() instead. - crudity.inputs.email.CreateEmailInput & CreateInfopathInput: they now have a button by default. - (internal) CRUDityRegistry.dispatch() takes now the configuration data as argument.

    → <<cset c3f2bc6e37f9>>

  8. Guillaume Englert

    refs #26 Fix several bugs related to name collision (backend with the same subject), in block relaoding & action validation. The validation of the configuration has been fixed, improved & tested.

    Note: in a backend configuration of settings.CRUDITY_BACKENDS, you can now omit input/method for the fallback subject "*".

    Behaviour changes: These changes are not real API breakings, because they can only reveal some problems in your current configuration.

    • In Crudity (settings.CRUDITY_BACKENDS): the subject (after normalisation) must be unique for a couple fetcher/input. Before, when a subject was duplicated between, only one input was used (the other ones were ignored) ; now a exception is raised.
    • If a backend cannot be used as a fallback, it will raised an exception with the rigth reason, instead of a "crash".
    • CRUDityRegistry.register_fetchers() now works correctly when it is called several times.

    Note: the new command 'crudity_factory' has problems with unicode characters ; it will be fixed later (is problem in the command or elsewhere ?).

    API breaking: - crudity.registry.CRUDityRegistry.get_configured_backend(): - takes now 3 arguments. - raises a KeyError instead of returning 'None'. - crudity.views.actions.reload() has been removed ; use crudity.views.actions.reload_block() instead. - crudity.blocks.WaitingActionBlock: generated ID has changed. - crudity: the characters in fetchers & inputs name must be letters, digit, underscore or dot. (check if you created your own file 'crudity_register.py'). - crudity.WaitingAction.source: when creating one, you must respect the pattern "fetcher_name - input_name" (or only "fetcher_name" for default backend) ; this was not clearly documented. - crudity_register: - 'fetchers' must now contain iterable of fetcher classes (& not instances anymore). - 'inputs' must now contain iterable of input classes (& not instances anymore). - crudity.registry.FetcherInterface.add_fetcher() is deprecated ; use add_fetchers() instead. - crudity.inputs.email.CreateEmailInput & CreateInfopathInput: they now have a button by default. - (internal) CRUDityRegistry.dispatch() takes now the configuration data as argument.

    → <<cset c3f2bc6e37f9>>

  9. Guillaume Englert

    refs #106 #26 Bricks system for 'crudity'.

    API breaking: - The module crudity.blocks is deprecated ; use crudity.bricks instead. - The method CrudityInput.handle() returns a backend instance or None (instead of a boolean). So the handling methods (create() etc...) of child classes must return a backend/None. - These functions of crudity.views.actions are deprecated: - fetch(). - fetch(): use crudity_registry.fetch() instead. - reload_block(): use crudity.views.actions.reload_bricks() instead. - crudity.views.history.reload() is deprecated ; use crudity.views.history.reload_bricks() instead. - These templates files are deprecated: - creme/crudity/templates/templatetags/blocks* - creme/crudity/templates/crudity/frags/ajax/waiting_actions.html - creme/crudity/templates/crudity/waiting_actions.html

    → <<cset d2418cfe8ecf>>

  10. Guillaume Englert

    refs #106 #26 Bricks system for 'crudity'.

    API breaking: - The module crudity.blocks is deprecated ; use crudity.bricks instead. - The method CrudityInput.handle() returns a backend instance or None (instead of a boolean). So the handling methods (create() etc...) of child classes must return a backend/None. - These functions of crudity.views.actions are deprecated: - fetch(). - fetch(): use crudity_registry.fetch() instead. - reload_block(): use crudity.views.actions.reload_bricks() instead. - crudity.views.history.reload() is deprecated ; use crudity.views.history.reload_bricks() instead. - These templates files are deprecated: - creme/crudity/templates/templatetags/blocks* - creme/crudity/templates/crudity/frags/ajax/waiting_actions.html - creme/crudity/templates/crudity/waiting_actions.html

    → <<cset d2418cfe8ecf>>

  11. Guillaume Englert

    refs #26 Avoid getting a staff user for fallback sandbox owner in more situations.

    API breaking: - The owner of WaitingAction, History or EntityEmail instances can be different (compared to Creme 1.6) when the email sender does not correspond to a User/Contact.

    → <<cset 8a77c7bc0cb7>>

  12. Guillaume Englert

    refs #26 Avoid getting a staff user for fallback sandbox owner in more situations.

    API breaking: - The owner of WaitingAction, History or EntityEmail instances can be different (compared to Creme 1.6) when the email sender does not correspond to a User/Contact.

    → <<cset 8a77c7bc0cb7>>

  13. Guillaume Englert

    refs #26 Remove deprecated code in 'crudity'.

    API breaking: - Remove the setting CREME_GET_EMAIL_JOB_USER_ID. - Remove the module 'blocks'. - Remove these functions: - In 'views.actions' : fetch(), _fetch(), reload_block(). - crudity.views.history.reload(). - Remove the method registry.FetcherInterface.add_fetcher(). - In views.history.history(), the context variable "blocks" is not injected anymore. - Remove these global variables : - In 'buttons' : infopath_create_form_button & email_template_create_button. - In 'fetchers.pop' : pop_fetcher. - in 'inputs.email' : create_email_input & create_infopath_input. - Remove these template files: - crudity/templatetags/block_history.html - crudity/templatetags/block_waiting_action.html - crudity/frags/ajax/waiting_actions.html - crudity/waiting_actions.html

    → <<cset bff627f470c0>>

  14. Guillaume Englert

    refs #26 Remove deprecated code in 'documents'.

    API breaking: - Remove the module 'blocks'. - Remove the template files documents/templatetags/block_*.html - Remove the argument 'count' in: - 'views.quick_forms.abstract_add_doc_from_widget()'. - 'views.quick_forms.add_csv_from_widget()'. - In Bricks, these variable are not injected anymore : - FolderDocsBrick: "ct_id". - LinkedDocsBrick: "ct_doc".

    → <<cset 86c1e19a45f3>>

  15. Guillaume Englert

    refs #26 Remove deprecated code in 'crudity'.

    API breaking: - Remove the setting CREME_GET_EMAIL_JOB_USER_ID. - Remove the module 'blocks'. - Remove these functions: - In 'views.actions' : fetch(), _fetch(), reload_block(). - crudity.views.history.reload(). - Remove the method registry.FetcherInterface.add_fetcher(). - In views.history.history(), the context variable "blocks" is not injected anymore. - Remove these global variables : - In 'buttons' : infopath_create_form_button & email_template_create_button. - In 'fetchers.pop' : pop_fetcher. - in 'inputs.email' : create_email_input & create_infopath_input. - Remove these template files: - crudity/templatetags/block_history.html - crudity/templatetags/block_waiting_action.html - crudity/frags/ajax/waiting_actions.html - crudity/waiting_actions.html

    → <<cset bff627f470c0>>

  16. Guillaume Englert

    refs #26 Remove deprecated code in 'documents'.

    API breaking: - Remove the module 'blocks'. - Remove the template files documents/templatetags/block_*.html - Remove the argument 'count' in: - 'views.quick_forms.abstract_add_doc_from_widget()'. - 'views.quick_forms.add_csv_from_widget()'. - In Bricks, these variable are not injected anymore : - FolderDocsBrick: "ct_id". - LinkedDocsBrick: "ct_doc".

    → <<cset 86c1e19a45f3>>

  17. Guillaume Englert

    refs #1 #26 Deprecate some old sh*tty code.

    API breaking: - The exception class creme_core.registry.NotRegistered is deprecated. - creme_core.registry.CremeRegistry.register() is deprecated. - creme_core.registry.CremeRegistry.get() is deprecated. - The method crudity.registry.CRUDityRegistry.get_backend() raises now CRUDityRegistry.RegistrationError exceptions (it raised creme_core.registry.NotRegistered).

    → <<cset 4ea77f46d5b1>>

  18. Guillaume Englert

    refs #1 #26 Deprecate some old sh*tty code.

    API breaking: - The exception class creme_core.registry.NotRegistered is deprecated. - creme_core.registry.CremeRegistry.register() is deprecated. - creme_core.registry.CremeRegistry.get() is deprecated. - The method crudity.registry.CRUDityRegistry.get_backend() raises now CRUDityRegistry.RegistrationError exceptions (it raised creme_core.registry.NotRegistered).

    → <<cset 4ea77f46d5b1>>

  19. Guillaume Englert

    refs #26 Some code fix in 'crudity'.

    API breaking: - The field crudity.models.WaitingAction.data has been renamed 'raw_data'. - The method crudity.models.WaitingAction.set_data() now assigns really the data (woot!) & returns nothing.

    → <<cset ff9f46cb4388>>

  20. Guillaume Englert

    refs #26 Some code fix in 'crudity'.

    API breaking: - The field crudity.models.WaitingAction.data has been renamed 'raw_data'. - The method crudity.models.WaitingAction.set_data() now assigns really the data (woot!) & returns nothing.

    → <<cset ff9f46cb4388>>

  21. Log in to comment