Language Change NPM Resource Changed ? Pending

User tests: Successful: Unsuccessful:

avatar Kaushik1216
Kaushik1216
5 Feb 2023

Pull Request for Issue #39263

Summary of Changes

Closing Create folder Modal On error while creating folder

Testing Instructions

Create a folder as mention in issue like folder with name ( joomla..... )

Actual result BEFORE applying this Pull Request

The create modal not closed to show error in case of error occuring while creating folder

Expected result AFTER applying this Pull Request

create modal closed to show error

Link to documentations

Please select:

  • Documentation link for docs.joomla.org:

  • No documentation changes for docs.joomla.org needed

  • Pull Request link for manual.joomla.org:

  • No documentation changes for manual.joomla.org needed

avatar joomla-cms-bot joomla-cms-bot - change - 5 Feb 2023
Category Administration com_media NPM Change
avatar Kaushik1216 Kaushik1216 - open - 5 Feb 2023
avatar Kaushik1216 Kaushik1216 - change - 5 Feb 2023
Status New Pending
avatar Kaushik1216 Kaushik1216 - change - 5 Feb 2023
The description was changed
avatar Kaushik1216 Kaushik1216 - edited - 5 Feb 2023
avatar Kaushik1216 Kaushik1216 - change - 5 Feb 2023
The description was changed
avatar Kaushik1216 Kaushik1216 - edited - 5 Feb 2023
avatar Kaushik1216 Kaushik1216 - change - 5 Feb 2023
The description was changed
avatar Kaushik1216 Kaushik1216 - edited - 5 Feb 2023
avatar Kaushik1216 Kaushik1216 - change - 5 Feb 2023
The description was changed
avatar Kaushik1216 Kaushik1216 - edited - 5 Feb 2023
avatar Kaushik1216 Kaushik1216 - change - 5 Feb 2023
The description was changed
avatar Kaushik1216 Kaushik1216 - edited - 5 Feb 2023
avatar dgrammatiko
dgrammatiko - comment - 5 Feb 2023

@Kaushik1216 around 10 lines before the line you've added there are couple of todos that should point you to the needed changes.
Essentially what your code is doing is closing the modal always although we should keep the modal open when there's an error, mark the field as invalid and also render (inside the modal) the error message. In short you're changing the workflow here and introducing more clicks to complete a task if there's an error.

avatar Kaushik1216
Kaushik1216 - comment - 6 Feb 2023

@dgrammatiko yes you are right ,so what can be best way to solve this issue .One way I think is ,when undesire folder name come,input field should become red and some text like invalid folder name above input field can be shown.

avatar Kaushik1216 Kaushik1216 - change - 11 Feb 2023
Labels Added: NPM Resource Changed ?
avatar joomla-cms-bot joomla-cms-bot - change - 11 Feb 2023
Category Administration com_media NPM Change Administration com_media NPM Change Language & Strings
avatar Kaushik1216
Kaushik1216 - comment - 11 Feb 2023

@dgrammatiko Please check this changes this will do as follow .

mediafoldercreate.mp4
avatar dgrammatiko
dgrammatiko - comment - 11 Feb 2023

Please check this changes this will do as follow .

There are many more cases that Joomla (the PHP side) will not accept a name as valid, so somehow you need to check for all these.

avatar Kaushik1216
Kaushik1216 - comment - 11 Feb 2023

Please check this changes this will do as follow .

There are many more cases that Joomla (the PHP side) will not accept a name as valid, so somehow you need to check for all these.

Ok ,then please provide me those cases I will do similiar things for all cases

avatar dgrammatiko
dgrammatiko - comment - 11 Feb 2023

Ok ,then please provide me those cases I will do similiar things for all cases

Dude if I have to do the research then I could as well do the PR...

avatar Kaushik1216
Kaushik1216 - comment - 11 Feb 2023

Ok ,then please provide me those cases I will do similiar things for all cases

Dude if I have to do the research then I could as well do the PR...

Hmm, Ok then I will do research and find some more constraint

avatar Kaushik1216 Kaushik1216 - change - 12 Feb 2023
Labels Added: Language Change
avatar Kaushik1216
Kaushik1216 - comment - 12 Feb 2023

Error show if fiolder name already exist in directory as folder or file name

error show as follows

1createfolderfileexisterror

avatar Kaushik1216
Kaushik1216 - comment - 12 Feb 2023

@dgrammatiko Is I am doing right for multiple case handling ?

avatar Kaushik1216
Kaushik1216 - comment - 14 Feb 2023

AS I notice php side only accept folder name which contain only Alphanumeric,underscore(_) ,period ( . ) and hyphen ( - ).
if you include any other charachater other than this php remove all other character from folder name .
Problem is that if you have a folder name for example ss and you attempt to try create folder with name s@s then you not get any error and folder also not created because php remove @ from folder name and ss result new folder name which is already present their and bad thing is that user also get a success msg Folder created .

avatar Kaushik1216
Kaushik1216 - comment - 14 Feb 2023

the only one error That I think should come from php side is when user not install INTL and ICONV php extension and writing non ascii character in folder name should we close modal for this error ?

avatar Kaushik1216 Kaushik1216 - change - 16 Feb 2023
Title
Closing create modal
Error handling while create folder in media manager
avatar Kaushik1216 Kaushik1216 - edited - 16 Feb 2023
avatar dgrammatiko
dgrammatiko - comment - 17 Feb 2023

Please rebase this to 4.3!

avatar dgrammatiko
dgrammatiko - comment - 17 Feb 2023

Lastly the media manager has the concept of adapters, ie supporting different online storage solutions (Amazon s3, Dropbox, etc). Therefore the checks here should cover all these options…

avatar Kaushik1216
Kaushik1216 - comment - 17 Feb 2023

Please rebase this to 4.3!

I think rebaseing this pr with 4.3 will increse work more that also occure in my no search result pr .
So I am creating new Pr for 4.3 branch .Should I closed it then ?

avatar Kaushik1216
Kaushik1216 - comment - 17 Feb 2023

closing by creating another Pr #39878 please refer this

avatar Kaushik1216 Kaushik1216 - change - 17 Feb 2023
Status Pending Closed
Closed_Date 0000-00-00 00:00:00 2023-02-17 14:21:42
Closed_By Kaushik1216
avatar Kaushik1216 Kaushik1216 - close - 17 Feb 2023

Add a Comment

Login with GitHub to post a comment