Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unable to save articles with "No User" selected #43674

Open
SimVT opened this issue Jun 19, 2024 · 10 comments
Open

Unable to save articles with "No User" selected #43674

SimVT opened this issue Jun 19, 2024 · 10 comments

Comments

@SimVT
Copy link

SimVT commented Jun 19, 2024

Steps to reproduce the issue

On my J5.1.1 sites I create a new article. Under the "publishing" tab I select "No User" under the "Created By" field.

Expected result

Article saves with "No User" listed as author.

Actual result

Article saves with the logged-in user listed as author. Going back to the Publishing tab and selecting "No User" and choosing
save produces the following error:

"Save failed with the following error: Incorrect integer value: '' for column phhyb_24bran.ceb_content.created_by at row 1"

On another site the error is:

"Save failed with the following error: Incorrect integer value: '' for column iadlee_sens0514.iwo_content.created_by at row 1"

on another site the error appears as:

"Save failed with the following error: Incorrect integer value: '' for column peline_24ap45.sgjml_content.created_by at row 1"

System information (as much as possible)

PHP Built On Linux 3.10.0 #1 SMP Thu Dec 15 20:31:06 MSK 2022 x86_64
Database Type mysql
Database Version 10.6.18-MariaDB
Database Collation latin1_swedish_ci
Database Connection Collation utf8mb4_general_ci
Database Connection Encryption None
Database Server Supports Connection Encryption No
PHP Version 8.1.29
Web Server Apache/2
WebServer to PHP Interface fpm-fcgi
Joomla! Version Joomla! 5.1.1 Stable [ Kudumisha ] 28-May-2024 16:00 GMT
Joomla Backward Compatibility Plugin Enabled ()

Additional comments

Articles are saved despite the error.

@brianteeman
Copy link
Contributor

confirmed

@chmst
Copy link
Contributor

chmst commented Jun 19, 2024

Please test #43675.
The button is wrong and miseading here. Every article needs an author. If you don't want to select a user, just close the modal.

@chmst chmst closed this as completed Jun 19, 2024
@SimVT
Copy link
Author

SimVT commented Jun 19, 2024

This is an incorrect statement. To test, I created a J3.1.2 instance and created a sample article

When I saved the article it correctly saved it with me as the author. I then went back into the article and chose "No User" for the Author and successfully saved it - see attached.

The article shows "None" as the author. Something changed and this is a useful feature if for no other reason that if a user is deleted from the system what happens to "their' articles? And in our case we have many articles with None listed as the Author, be design.

Something changed.
gh1

@chmst
Copy link
Contributor

chmst commented Jun 19, 2024

Thanks for this hint. I know nothing about J 3.1 but will re-open your issue.

@chmst chmst reopened this Jun 19, 2024
@SimVT
Copy link
Author

SimVT commented Jun 19, 2024

Thank you! This also worked as far as I recall in J4 and J5.

@chmst chmst removed the UI/UX label Jun 19, 2024
@brianteeman
Copy link
Contributor

Just checked in j3 and selecting the no user button lets you save the article with author none

image

@chmst
Copy link
Contributor

chmst commented Jun 22, 2024

It is possible for other items. I suppose that there is something with com_workflow but cannot find what happens.

@SimVT
Copy link
Author

SimVT commented Jun 23, 2024

For what it's worth, I was working with a J4.4.5 site today and created an article and, after saving it, was able to save it with no user as per the attached image so whatever happened it was at least after 4.4.5.


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/43674.

@chmst
Copy link
Contributor

chmst commented Jun 24, 2024

Found changes here #42256.
Changing data-user-value="" to data-user-value="0" resolves the problem here but could have unexpected side effects on other places. Please @Fedik could you have a look?

@Fedik
Copy link
Member

Fedik commented Jun 25, 2024

Changing to data-user-value="0" should be fine 😉
I have no idea why it makes difference, but if it helps then can change

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

5 participants