Make all model exportable

Created on 28 January 2023, almost 2 years ago

Problem/Motivation

Currently, only bpmn_io models can be exported, but models from eca_cm should also be exportable, especially for support purposes.

📌 Task
Status

Fixed

Version

1.2

Component

Code

Created by

🇩🇪Germany jurgenhaas Gottmadingen

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

  • Issue created by @jurgenhaas
  • @jurgenhaas opened merge request.
  • Issue was unassigned.
  • Status changed to Needs review almost 2 years ago
  • 🇩🇪Germany jurgenhaas Gottmadingen
  • Status changed to RTBC almost 2 years ago
  • 🇩🇪Germany danielspeicher Steisslingen

    Very useful supplement.

  • Status changed to Fixed almost 2 years ago
  • 🇩🇪Germany jurgenhaas Gottmadingen

    Merged and back ported. Thanks @danielspeicher for reviewing this.

  • 🇩🇪Germany mxh Offenburg

    1.1.x is currently a bugfix branch, where 1.2.x exists for new features. This issue is not a bugfix, and the last commit changes existing API and thus breaks compatibility, in this case specifically with eca_cm.

  • 🇩🇪Germany jurgenhaas Gottmadingen

    The missing export for some models is a big one and as 1.2 is most likely a few months away, it seems worth bringing this into 1.1 too.

    It's been built in a way where it won't break compatibility. Even if you don't change eca_cm, it will still be perfectly valid - just that the export feature won't be available, which is no difference from what we have now. However, with Enable general model export in latest ECA version Fixed this would be resolved too then.

  • Status changed to Needs work almost 2 years ago
  • 🇩🇪Germany mxh Offenburg

    I'm getting the following error when trying to export a model via UI:

    The website encountered an unexpected error. Please try again later.
    
    Error: Call to undefined method Drupal\eca\Entity\Eca::isExportable() in Drupal\eca_ui\Controller\EcaController->export() (line 185 of modules/contrib/eca/modules/ui/src/Controller/EcaController.php).
    call_user_func_array(Array, Array) (Line: 123)
    Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->Drupal\Core\EventSubscriber\{closure}() (Line: 580)
    Drupal\Core\Render\Renderer->executeInRenderContext(Object, Object) (Line: 124)
    Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->wrapControllerExecutionInRenderContext(Array, Array) (Line: 97)
    Drupal\Core\EventSubscriber\EarlyRenderingControllerWrapperSubscriber->Drupal\Core\EventSubscriber\{closure}() (Line: 163)
    Symfony\Component\HttpKernel\HttpKernel->handleRaw(Object, 1) (Line: 74)
    Symfony\Component\HttpKernel\HttpKernel->handle(Object, 1, 1) (Line: 58)
    Drupal\Core\StackMiddleware\Session->handle(Object, 1, 1) (Line: 48)
    Drupal\Core\StackMiddleware\KernelPreHandle->handle(Object, 1, 1) (Line: 106)
    Drupal\page_cache\StackMiddleware\PageCache->pass(Object, 1, 1) (Line: 85)
    Drupal\page_cache\StackMiddleware\PageCache->handle(Object, 1, 1) (Line: 48)
    Drupal\Core\StackMiddleware\ReverseProxyMiddleware->handle(Object, 1, 1) (Line: 51)
    Drupal\Core\StackMiddleware\NegotiationMiddleware->handle(Object, 1, 1) (Line: 51)
    Drupal\Core\StackMiddleware\StackedHttpKernel->handle(Object, 1, 1) (Line: 681)
    Drupal\Core\DrupalKernel->handle(Object) (Line: 19)
    It's been built in a way where it won't break compatibility. Even if you don't change eca_cm, it will still be perfectly valid - just that the export feature won't be available, which is no difference from what we have now.

    Not sure about this. The export link now shows up for core models, but the modeller won't do anything (I guess).

  • Status changed to Needs review almost 2 years ago
  • 🇩🇪Germany jurgenhaas Gottmadingen

    I'm getting the following error when trying to export a model via UI:

    I missed one change during the back port. Now fixed.

    ... but the modeller won't do anything

    Yes, that's how the export function was built originally because we didn't have any access control on the route, only that display control by the modeller. Do you think we should add a message here?

  • Status changed to Fixed almost 2 years ago
  • 🇩🇪Germany mxh Offenburg

    Thanks for fixing this.

    Do you think we should add a message here?

    Guess there's no need for it. The Core modeller should now be able to automatically support the export.

  • Automatically closed - issue fixed for 2 weeks with no activity.

Production build 0.71.5 2024