Skip to content
This repository has been archived by the owner on Jan 16, 2024. It is now read-only.

Display Cascade Delete and Default Delete #108

Closed
alprinias opened this issue Oct 15, 2019 · 7 comments
Closed

Display Cascade Delete and Default Delete #108

alprinias opened this issue Oct 15, 2019 · 7 comments
Labels
enhancement New feature request released Issue is resolved in a current release
Milestone

Comments

@alprinias
Copy link

Hi,

If I change the "Show Cascade Deletes" property for the Designer from the default False to True, nothing shows in the designer surface no matter what delete behaviour I have assigned to relationships. If then I change a relationship's delete behaviour, it will show ALWAYS as a red dashed line. Even if I have set the Cascade Delete to None.

As an enhancement, tt would be nice to be able to set the default delete behaviour for the model.

Thanks.

@msawczyn msawczyn added investigating Looking into this bug Confirmed bug and removed investigating Looking into this labels Oct 16, 2019
msawczyn added a commit that referenced this issue Oct 16, 2019
@msawczyn msawczyn added this to the 1.3.0.8 milestone Oct 16, 2019
@msawczyn msawczyn added the enhancement New feature request label Oct 17, 2019
msawczyn pushed a commit that referenced this issue Oct 17, 2019
@msawczyn
Copy link
Owner

Wanted to drop you a note letting you know that this is currently being worked on. The bug, that is, but not the enhancement request. Turns out it's an uglier bug than it appears to be, almost to the point where I'm wondering if it's worth the effort to fix, or if the color-and-line-style-change feature should just be removed. It really doesn't add much. But I'm quite stubborn, so am still working it.

Regarding default delete behavior, that's pretty much set by the multiplicities (cardinalities) of the association, except for very special circumstances that should be thought through carefully before changing. The best bet is to leave it as default except for those edge cases ... other behaviors can cause big trouble down the road, or just plain not work.

@msawczyn msawczyn added pending release Issue is resolved in the current codebase, will be published with the next release and removed bug Confirmed bug labels Oct 20, 2019
@alprinias
Copy link
Author

Thank you for your answer!

I absolutely agree that the colouring itself is not worth the big effort to fix, but I see you already did! Hope you tried so hard to solve the "uglier" bug and not just the colouring.

Concerning the delete behaviour, I have a kind of "allergy" against cascade delete, I'd rather do it myself so that I know exactly what is being deleted, that's why I would like to define the default behaviour for the whole model to Restrict. But if this is too much work to do, it's fine with me.

@alprinias
Copy link
Author

Hi Michael,

As you said it's not important, but FYI, trying the 1.3.0.8 I still see all my associations in red dashed lines if I have set the "show cascade delete" flag to true for the model, no matter what their individual values are in the association properties window (Default/None/Cascade)

@msawczyn
Copy link
Owner

Fix available for review in v1.3.0.8-pre

@alprinias
Copy link
Author

Hi Michael,
Same with 1.3.0.8-pre, all associations show up as red dashed when the "show cascade.." property of the model is set to true, no matter what behaviour is set individually on associations.

@msawczyn
Copy link
Owner

I think I finally have a complete grasp on what you're reporting. Give 1.3.0.8-pre2 a go. You'll need to manually uninstall the prior 1.3.0.8 since it is the same version number.

@alprinias
Copy link
Author

Yes, now it works!

The behaviour I was expecting to see and was not seeing was:

line = black solid;
If (show cascade deletes && (association property == cascade or == default)
line = red dashed;

Sorry if my reporting was somehow misleading.

And after seeing the different colours it finally find it helpful. Thanks!

@msawczyn msawczyn added released Issue is resolved in a current release and removed pending release Issue is resolved in the current codebase, will be published with the next release labels Nov 10, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
enhancement New feature request released Issue is resolved in a current release
Projects
None yet
Development

No branches or pull requests

2 participants