nwrightau VIP
Total posts: 99
01 Sep 2014 02:00

Hi Everyone,

Needing to build a site with cobalt 8, when editing content it needs to be approved by another user before it goes live - content changes also need to be stored as versions and be able to restore back to them. I think Joomla 3 core has this feature and plugins can use it, not sure if it's setup in cobalt though.

Any ideas would be much appreciated!

Thanks

Last Modified: 30 Oct 2014


nwrightau VIP
Total posts: 99
06 Oct 2014 06:15

Konstantin Fixed. Will be in the next release.

There was a relase on oct 3, does that contain this fix? If not when will the next relase be out?


Konstantin
Total posts: 1,113
06 Oct 2014 09:18

It will be 9th oct.


nwrightau VIP
Total posts: 99
09 Oct 2014 23:19

Hi,

Just installed the latest version, when the user makes a change the article just goes blank and isn't viewable from the front end of the site. For public users the previous version still needs to display, otherwise any user without privleges can basically remove any pages content by making a change.

Thanks


Konstantin
Total posts: 1,113
10 Oct 2014 06:07

Give me credentionals to admin and link to the articele and I check it.


nwrightau VIP
Total posts: 99
14 Oct 2014 23:00

Konstantin Give me credentionals to admin and link to the articele and I check it.

You already have login details in previous post, nothing has changed...

Doesn't matter which article, I tested it on a page but it happens with everything.


Sergey
Total posts: 13,748
15 Oct 2014 02:57

nwrightau You already have login details in previous post, nothing has changed...

We have thousand of posts. It is very hard to remember whose credentials we do have. And even if we remember sometimes users have dozen of posts and it is also hard to go through all of them just to find a credentials. And sometimes, in new post user ask about problem they meet in completely different website than previous. ANd sometimes, people just turn credentials off after we fix prewious issue.

So it is hard to go through all this process. That is why we ask for credentials.


Konstantin
Total posts: 1,113
15 Oct 2014 09:53

CHeck it and feels all work fine. Register user edit records and records become not published, wait approve.


nwrightau VIP
Total posts: 99
16 Oct 2014 00:11

Konstantin CHeck it and feels all work fine. Register user edit records and records become not published, wait approve.

Hi, Yes that's how it currenlty works. However this it not good user experience for the client.

If we just unpublish the entire article when a user makes an edit that needs approval, we effectively give standard level uses permissions to take down pages off the website. This should not be displayed, ideal workflow see below:

  • Standard level user edits item
  • Edits are saved as latest version in item, but not published
  • The item its self displays the most recent approved version on the front end [for public users] until the administrator approves the edited version, then that version is displayed.

Perhaps this functionality could be added in the record template? If record has multiple versions and is unpublished due to edits, display most recently published version.

This is pretty critical functionality for us and are happy to finance it's development. Please contact me if you would like to discuss.


Sergey
Total posts: 13,748
16 Oct 2014 01:55

This cannot be solved with just template edited. Version are not saved as presentable information. Versions are saved as encoded snapshot.

In other words with a way versioning works now, it is impossible to do. It will require a lot of versioning system refactoring.


nwrightau VIP
Total posts: 99
17 Oct 2014 00:36

Sergey This cannot be solved with just template edited. Version are not saved as presentable information. Versions are saved as encoded snapshot.

In other words with a way versioning works now, it is impossible to do. It will require a lot of versioning system refactoring.

Any other ideas? Perhaps on save it stores the untouched version somewhere temporarily and displays that for public users until approval.


nwrightau VIP
Total posts: 99
20 Oct 2014 06:29

Any improvements or possibilities to improve the workflow here? It's extremely critical, we can't have pages going offline just because an edit is made.


Sergey
Total posts: 13,748
20 Oct 2014 08:57

nwrightau Any improvements or possibilities to improve the workflow here?

Right now it is not possible to chaneg the workflow.


nwrightau VIP
Total posts: 99
21 Oct 2014 04:49

Sergey

nwrightau Any improvements or possibilities to improve the workflow here?

Right now it is not possible to chaneg the workflow.

Where are the versions stored in the db? Will have to make my own plugin / hack core.

I have to say this is a huge let down, it doesn't accomplish what it needs to - just makes for a bad user experience. This feature was a deal breaker for choosing this component, it needs to work better than this. How can you seriously leave it how it is? It flat out doesn't work well enough, pages can't be unpublished because they have changes pending approval. I have even offered to fund doing this properly and you don't seem at all interested.

Can you recommend any developers that could fix your component?


Sergey
Total posts: 13,748
21 Oct 2014 05:42

nwrightau Where are the versions stored in the db? Will have to make my own plugin / hack core.

This is not matter of who can do. It is technicaly not possible. The snapshots are stored in jos_js_res_audit_versions. And those are compressed snapshots. Unusable. Only if you restore it into Cobalt tables. And after edict article you cannot save only a snapshot.

You can try of course, but as for me I do not see how this could be done right now.

nwrightau How can you seriously leave it how it is?

We will not leave it as it is. And we will advance it. But it will be done only on Cobalt 9. We cannot change that process in Cobalt 8. To sensetive. Change to this process may produce a lot of bugs with will be really not good expiriance to run into buggy state after regular update of stable product.

nwrightau I have even offered to fund doing this properly and you don't seem at all interested.

As I have metioned, it is not about that I am not interested. If it is a good feature I even can do it for free. The problem nere is that money cannot solve it. I either can do it or not. In this case I cannot. I can only consider this for Cobalt 9.

I really would like to sutisfy you. It is not that I try to ignore you or I do not care about your problems. It is just this one is not solvable for the moment.


nwrightau VIP
Total posts: 99
22 Oct 2014 23:06

Sergey

nwrightau Where are the versions stored in the db? Will have to make my own plugin / hack core.

This is not matter of who can do. It is technicaly not possible. The snapshots are stored in jos_js_res_audit_versions. And those are compressed snapshots. Unusable. Only if you restore it into Cobalt tables. And after edict article you cannot save only a snapshot.

You can try of course, but as for me I do not see how this could be done right now.

nwrightau How can you seriously leave it how it is?

We will not leave it as it is. And we will advance it. But it will be done only on Cobalt 9. We cannot change that process in Cobalt 8. To sensetive. Change to this process may produce a lot of bugs with will be really not good expiriance to run into buggy state after regular update of stable product.

nwrightau I have even offered to fund doing this properly and you don't seem at all interested.

As I have metioned, it is not about that I am not interested. If it is a good feature I even can do it for free. The problem nere is that money cannot solve it. I either can do it or not. In this case I cannot. I can only consider this for Cobalt 9.

I really would like to sutisfy you. It is not that I try to ignore you or I do not care about your problems. It is just this one is not solvable for the moment.

Hi

Thanks for your response there, much appreciated. Perhaps we could look at it a different way - if a user making and edit but their edits require approval, when they click save their edits are stored in a temporary location. When the administrator approves, those changes are then written into the main item table and published.

This way the current page is left online while the users changes are being approved. Also it would be good to have a list of records with pending approvals somewhere, as well as a message that appears on the page if it has edits awaiting approval "This record has changes pending approval by an administrator made by xx user on xx/xx/xxxx". Also need a message after user has made edits "Your changes have been saved, but require approval by an administrator"

Does this seem possible to you? Cobalt 9 is all well and good but we have projects on the go now, I understand that updating cobalt 8 with other features may cause bugs - can we have access to some sort of beta version?

Thanks


Sergey
Total posts: 13,748
24 Oct 2014 01:54

I understand what you are saying and how it should work in order to work.

nwrightau if a user making and edit but their edits require approval, when they click save their edits are stored in a temporary location.

This is obvious but what I am saying there is no sucha location right now. I cannot save it anywhere exept as new article. And I cannot add this location now also.

nwrightau Does this seem possible to you? Cobalt 9 is all well and good but we have projects on the go now, I understand that updating cobalt 8 with other features may cause bugs - can we have access to some sort of beta version?

I am very sorry. It is very rare, I tell people NO. But this is the case. I canont add this to Cobalt 8. There is no beta of Cobalt 9 available.


nwrightau VIP
Total posts: 99
25 Oct 2014 22:36

Well this was the first and last time we will use cobalt unfortunately. This workflow approvals was the reason we went with cobalt in the first place and the result is buggy and bad user experience. Along with this problem which is only resolved by hacking the core [just remove unwanted items from the title lol!].

So as good as cobalt is, just too many bugs and lack of key features for us.


nwrightau VIP
Total posts: 99
29 Oct 2014 22:26

Hi Sergey,

Another thought for this project as we must deliver workflow approvals for this site.

When a low level user is logged in, and makes a change the item is not unpublished - as this is useless and pointless - instead, I can write some javascript to:

  • Store the initial untouched content
  • When the user is finished, add both content together - except the new content is put inside a div wrapper
  • Unapproved content is hidden on the front end using Joomla PHP to check if the user is logged in
  • I would also need to make some custom controls on the edit page when an administrator is logged in, and a button that removes the old one and removes the div wrapper on the new content so only the new content remains on save.

Aside from that another idea would be to create an new Joomla article state 'Draft' or 'Awaiting Approval', when a user makes new changes:

  • I write javascript to get current data and store it in new SQL table via ajax
  • Article is changed to 'Awaiting Approval State'
  • In template, some PHP is added to handle the new state, if it is awaiting approval - display stored data from our new table.
  • Admin user can approve/moved article to published state and newer content shows
  • May also need to clear the data in the new SQL table

Any thoughts on these? Again very urgently happy to pay for your assistance to develop either of these, the latter is preferred - seems more robust.


Konstantin
Total posts: 1,113
30 Oct 2014 05:08

nwrightau

  • Store the initial untouched content
  • When the user is finished, add both content together - except the new content is put inside a div wrapper
  • Unapproved content is hidden on the front end using Joomla PHP to check if the user is logged in
  • I would also need to make some custom controls on the edit page when an administrator is logged in, and a button that removes the old one and removes the div wrapper on the new content so only the new content remains on save.
  • About this idea. You can create 2 html field, 1 for public and 2 for special users. Writer create new content in special field, when it checked you must edit record and move content from special field to public. This will work without hacking.

    Or can create own field with 2 html area and some button allowed only for admin which will do moving content. All this ways if you need approve only 1 field.

    If you need keep all field(only extra fields, not system like category, title, dates, access) you can copy data from column 'fields' from _js_res_record table before editing, and save it in another table. I think it can be done by custom mint plugin use event 'onBeforeArticleSaved'. Before approving replace fields data form this temp table, after approve don't do replacing.

    Powered by Cobalt