salesagility / SuiteCRM

SuiteCRM - Open source CRM for the world
https://www.suitecrm.com
GNU Affero General Public License v3.0
4.53k stars 2.09k forks source link

Cannot change email editor #6294

Open pichto opened 6 years ago

pichto commented 6 years ago

Issue

When writing or replying to an email, the WYSIWYG editor is always the same although i changed it under my profile.

It's alway a kind of green editor with very few options (see sceenshot)

capture d ecran 2018-09-10 a 09 41 51

Expected Behavior

The Editor should change when i change it under my profile preferences and should have more options.

Actual Behavior

It's never changing...

Possible Fix

Steps to Reproduce

  1. Go to Collaboration->emails->compose to see the editor
  2. go to profile->change the editor (bottom of the page), save changes
  3. go back to emails->compose
  4. no changes!

Context

Cannot add some links for example.

medium priority

Your Environment

pichto commented 3 years ago

Well... almost 3 years later and still no change... Any clue ?

pgorod commented 3 years ago

This is not strictly a bug, it's just something that was never added. The editor option affects the Email Templates module, but not the Email Compose dialogs.

I agree that the option should affect both. I actually did this change for my PowerReplacer add-on since I needed the ability to use direct HTML. It's quite messy code and it was a lot of work :-(

Technically speaking, what I did was create a new SugarField that renders the "configurable editor", and then use that in all the screens that need it.

My original plan was to make things progress so that I could eventually donate all this code to Core, where it belongs, but my plan didn't really work out and I am currently too busy with other things to think of another plan...

Dillon-Brown commented 3 years ago

What @pgorod says here is accurate, even worse the TinyMCE editor in the email compose isn't even the same one used in email templates, we have two separate versions of TinyMCE in the project....

I don't think this would be too terribly difficult to standardize (which is what we are currently doing for the Search and PDF engines), ideally we should do this in a way that will allow custom developers to easily add new HTML editors too. Although that does bring up the question of if there should be separate settings for each module or just a global one for Emails/EmailTemplates/Cases, etc.

pichto commented 3 years ago

Thank you both for your feedback. Didn't even think the two editors were so apart from each other.

Anyway, would be a really good idea to standardize all this and use the same editor everywhere. Would make things way more user friendly... The way it is done now made me thought it was a bug as it was supposed to be a normal behavior...

Also, writhing emails with this editor is not that friendly and welcoming... it makes the email module look a bit crappy and not finished for my taste.

I'm not into code, but let me know if i can help in any way.

pgorod commented 3 years ago

The SugarField scheme is quite customizable as it is. It can easily be sub-classed. Also the Editors class is ready to be expanded.

The only part I think is missing regarding customization is a really easy way to set the TinyMCE settings. This could be achieved by separating these settings in to config files and read them also from custom dir when they exist there (per-module, perhaps also per-screen). I used to think TinyMCE was crap but the recent versions, with all the extensibility they allow, are really powerful. So the goal should be to let SuiteCRM users (well, the ones who can code a bit) tap into that power.