View Issue Details
|ID||Project||Category||View Status||Date Submitted||Last Update|
|0019683||mantisbt||attachments||public||2015-05-01 01:36||2015-09-06 17:37|
|Priority||normal||Severity||minor||Reproducibility||have not tried|
|Target Version||1.3.0-beta.3||Fixed in Version||1.3.0-beta.3|
|Summary||0019683: Support attaching multiple files with same name|
At the moment if users attempt to upload a file with the same name, we provide an error message. We should rename the file to make it unique rather than rejecting it. For example:
The reasons this feature is useful are:
This will make attaching files more user friendly.
Here is the pull request:
Another option could be to ask the user if he wants to replace the existing file or create a new version.
You might also think about keeping the file name for the new file, but rename existing files.
Thanks @atrol for the feedback.
I prefer the current solution since it is low friction and doesn't change history and hence shouldn't be confusing. The filename modifications also kind of reflects versions of the file.
I kind of like the idea of being able to optionally overwrite an existing attachment as a single step (assuming the file bears the same name and user is original uploader or is authorized to delete attachments).
With regards to your 1st bullet, it's not so different from a manual deletion, and I don't believe it's a big deal.
In terms of history, this could be recorded as 2 distinct events, 1. deleting the old file and 2. uploading new one.
That being said, your solution works and the "replace" option is just a nice to have.
|2015-05-01 01:36||vboctor||New Issue|
|2015-05-01 01:36||vboctor||Status||new => assigned|
|2015-05-01 01:36||vboctor||Assigned To||=> vboctor|
|2015-05-01 01:40||vboctor||Note Added: 0050681|
|2015-05-01 01:46||vboctor||Tag Attached: mantishub|
|2015-05-01 08:02||atrol||Note Added: 0050682|
|2015-05-01 11:36||vboctor||Note Added: 0050684|
|2015-05-02 09:19||dregad||Note Added: 0050687|
|2015-05-02 15:42||vboctor||Changeset attached||=> MantisBT master 40074fa9|
|2015-05-02 15:42||vboctor||Status||assigned => resolved|
|2015-05-02 15:42||vboctor||Resolution||open => fixed|
|2015-05-02 15:42||vboctor||Fixed in Version||=> 1.3.0-beta.3|
|2015-09-06 17:37||vboctoradmin||Status||resolved => closed|