Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
We need a warning to the user before disassociating all content from Lingotek.
Comment | File | Size | Author |
---|---|---|---|
#36 | interdiff-32-33.txt | 857 bytes | mdahl328151 |
#36 | 2884160-disassociate-confirm-33.patch | 2.91 KB | mdahl328151 |
| |||
#34 | Selection_105.png | 187.25 KB | mdahl328151 |
#34 | 2884160-disassociate-confirm-32.patch | 2.92 KB | mdahl328151 |
#34 | interdiff-31-32.txt | 836 bytes | mdahl328151 |
Comments
Comment #2
mdahl328151 CreditAttribution: mdahl328151 commentedComment #3
penyaskitoI guess the proper status is Needs review. We would need tests for this (hopefully they exist, and we only need to update them)
Comment #5
mdahl328151 CreditAttribution: mdahl328151 commentedComment #6
mdahl328151 CreditAttribution: mdahl328151 commentedComment #8
mdahl328151 CreditAttribution: mdahl328151 commentedComment #9
mdahl328151 CreditAttribution: mdahl328151 commentedComment #11
mdahl328151 CreditAttribution: mdahl328151 commentedComment #12
mdahl328151 CreditAttribution: mdahl328151 commentedComment #13
penyaskitoWe need to update the class docs.
I have to check if this is the best way of doing this. I wonder what happens if I go directly to this path.
We need to update this docs.
What is this for?
I think lots of class properties here are unused?
lowercase
Let's inject this on the class.
Let's inject this on the class.
Comment #14
mdahl328151 CreditAttribution: mdahl328151 commentedPatch didn't include the disassociated form.
Comment #16
mdahl328151 CreditAttribution: mdahl328151 commentedComment #18
mdahl328151 CreditAttribution: mdahl328151 commentedComment #19
mdahl328151 CreditAttribution: mdahl328151 commentedComment #20
mdahl328151 CreditAttribution: mdahl328151 commentedComment #22
mdahl328151 CreditAttribution: mdahl328151 commentedComment #24
mdahl328151 CreditAttribution: mdahl328151 commentedComment #25
mdahl328151 CreditAttribution: mdahl328151 commentedComment #27
penyaskitoRerolled.
Comment #28
penyaskitoMade some changes:
*
lingotek.confirm_disassociate
should be a form, not a controller. We skip one redirect call with that.* Remove
LingotekSettingsController::disassociate()
then, as it is not needed.* Renamed
LingotekSettingsTabDisassociateForm
toLingotekDisassociateAllConfirmForm
and made it extend fromConfirmFormBase
* Expanded testing in
LingotekUtilitiesDisassociateAllDocumentsTest.
Comment #29
penyaskitoCode standards and fixed undefined variable in exception report.
Comment #31
penyaskitoCommitted 03c548c and pushed to 8.x-2.x. Thanks!
Comment #32
mdahl328151 CreditAttribution: mdahl328151 commentedMinor change. This test simulates content with missing metadata
Comment #34
mdahl328151 CreditAttribution: mdahl328151 commentedAnother minor change to avoid this display:
Comment #36
mdahl328151 CreditAttribution: mdahl328151 commentedComment #38
mdahl328151 CreditAttribution: mdahl328151 commentedComment #39
penyaskitoComment #40
penyaskitoI'm guessing this leaves all those metadata still around and never got removed, right?
Comment #41
mdahl328151 CreditAttribution: mdahl328151 commentedYes. This is for the metatdata that is still in the database, but that is missing a content entity type id or a content entity id
I guess this is a work around. The real solution is to completely get rid of metadata if there is no content assigned to it, right?
Comment #42
penyaskitoRight, I'm going to commit this as it is. See #2899711: "Disassociate All" could be faster just by deleting all metadata objects for a follow up that we may want to explore.
Comment #44
penyaskitoCommitted 4e3fa42 and pushed to 8.x-2.x. Thanks!