2sxc icon indicating copy to clipboard operation
2sxc copied to clipboard

WYSIWYG "Link a DNN file" opens ADAM menu instead on first interaction if files are already in ADAM

Open 6TELOIV opened this issue 1 year ago • 8 comments

I'm submitting a

[x] bug report => search github for a similar issue before submitting

...about

[x] edit experience / UI

Current Behavior / Expected Behavior

In a WYSIWYG field, if the user has uploaded a file with ADAM, then the second file upload button will open the ADAM UI instead of the DNN UI. Clicking the button 2 more times (to dismiss and bring back the menu) brings up the correct menu image

Instructions to Reproduce the Problem

  1. Upload a file using ADAM in a WYSIWYG field
  2. Refresh the page
  3. Try to upload a file with DNN in that same WYSIWYG field
  4. Observe behavior described above

Your environment

  • 2sxc version(s): 17.09.00
  • Browser: all
  • DNN: 9.13.2
  • Hosting platform: any
  • Language: english

6TELOIV avatar Aug 09 '24 15:08 6TELOIV

Based on the nature of this bug, I feel like the cause is this adam cache code that runs on first load.

From what I can tell, if there are no files in adam, it will return undefined and fall through to the "getAll" case. Otherwise, it'll return the adam files and set the adamItems to that (even if the adamConfig has usePortalRoot set, it still uses the wrong cache value)

I haven't been able to test that this is the cause, but it seems like the solution is to wrap the cache code on line 294 of adam-browser.component.ts in a check that usePortalRoot is false.

6TELOIV avatar Sep 17 '24 15:09 6TELOIV

@iJungleboy have you or another contributor had a chance to look at this yet?

I didn't specify in the original post, but as a consequence of this bug, our editors are running into confusing 403 errors, as we let them upload files into a specific folderin DNN, but not ADAM, because their documents need to be organized and shared in multiple locations. I've tried to explain to them the workaround, but it would be more ideal if they could get to the correct menu on the first click instead of the third 😅

6TELOIV avatar Oct 11 '24 12:10 6TELOIV

@6TELOIV would you like to sponsor 2h to get this prioritized?

iJungleboy avatar Oct 14 '24 07:10 iJungleboy

Good point ;)

Donations/payments/contracts are a bit above my paygrade at my org; if you could estimate how much it would cost them, I can let them know.

6TELOIV avatar Oct 14 '24 12:10 6TELOIV

Check out https://2sxc.org/en/contact and https://2sxc.org/en/contact/paypal

2 hours is my estimate for this.

iJungleboy avatar Oct 15 '24 05:10 iJungleboy

@6TELOIV any update on chance for sponsoring?

iJungleboy avatar Dec 04 '24 12:12 iJungleboy

Nothing, sorry :(

6TELOIV avatar Dec 05 '24 22:12 6TELOIV

Just updating for myself in case I have time to try and fix this myself. The lines I think are causing the issue are now this adam cache code

6TELOIV avatar Jan 13 '25 14:01 6TELOIV

I'll close this for now. We don't have the bandwidth and nobody is stepping in, so I assume it's not relevant to 99.99%

iJungleboy avatar Aug 01 '25 05:08 iJungleboy