View Issue Details
ID | Project | Category | View Status | Date Submitted | Last Update |
---|---|---|---|---|---|
0022323 | mantisbt | feature | public | 2017-02-06 09:37 | 2022-11-28 06:05 |
Reporter | aavagyan | Assigned To | |||
Priority | high | Severity | major | Reproducibility | always |
Status | new | Resolution | open | ||
Product Version | 2.1.0 | ||||
Summary | 0022323: Missing whole "Attached Files" section | ||||
Description | With all the great improvements in new MantisBT 2.x, me and my users (piloting new version with selected users) are confused about not finding "Attached Files" section, as well as central "Upload file" box (only under the 'add note' - something we have disabled in MantisBT 1.2.x). We use MantisBT more like case management system - and we use attachments extensively. People opening the case would like to see the case with all the supporting attachments. Now attachments are mixed-up with notes. It means that one needs to travel over all notes to collect attachments!? Some of our tickets have up to 200 notes and dozens of attachments. With new setup these cases are basically unmanageable - only 'small' tickets are more-or-less OK - while still not convenient. Can we have config option to re-enable display of attachments displayed in the old way - grouped together and not scattered in "Activity" messed-up with notes? Thank you, | ||||
Tags | No tags attached. | ||||
Attached Files | |||||
related to | 0021727 | closed | vboctor | Show attachments inline with notes |
related to | 0026631 | closed | vboctor | file_get_visible_attachments shows private files that should be invisible to the user |
has duplicate | 0023340 | closed | atrol | Missing whole "Attached Files" section |
has duplicate | 0029744 | closed | atrol | Want to add a location for attachment |
related to | 0028965 | closed | vboctor | Show issue attachments along with issue header information |
In case you need this functionality, do the following:
This makes it configurable, not absolutely neeeded but good practice,
Just behind this section, add the following code:
Here you are, your list is back in the main screen. |
|
This way it looks a bit funny because of the HTML thing. |
|
Changed 2 more lines to be in line with new lay-out, so it should read: |
|
Thanks a lot! Works nicely. Users can possibly use file attach under the 'add note' - doesn't seem to be a big problem. The only missing thing is date next to the attached file, but I looked into functions - it is removed in version 2.x so 'hack' needs to be deeper. My users would possible agree to live without date displayed in this box. Can these changes be made part of next release? |
|
@cas I edited your notes to add the markdown formatting so the code is displayed raw. It was the decision of @vboctor to handle attachments upload and display at note level moving forward, so I let him comment on the eventuality of adding back the notion of "issue-level" attachments. I have to say that I personally do not like the fact that a document uploaded as part of an issue's initial report appears as a separate bug note; this is made worse by the fact that I like to have notes sorted reverse (most recent first), so the initial attachments appear last. It's worth mentioning that the current data model would not allow us to differentiate a note vs an issue attachment (currently this is an arbitrary link is based on the upload timestamp). |
|
@aavagyan, it makes sense that the date is taken away since that is visible within the note. Can be added but most likely then also will show up within the note which is not desirable. |
|
I strongly believe that "ticket" or "issue" or "case" (no matter what is the term used) needs to have the main information, with supporting documentation (files) as "core" informational unit, whereas notes and the rest (e.g. change-sets, time-tracking info, issue log, etc.), can be appended to it as needed. It looks like it can be achieved more or less easily by displaying "File attachments" block. Config option would be even better to satisfy different needs, e.g.:
Wikipedia: I think that change is especially needed if we would like to keep last sentence valid. |
|
This is something that my department would also like to see reinstated. I agree with @aavagyan that for use as a project management tool having all attachments collated within one area is immensely useful. When uploading items such as: functional or business requirements, this could prove quite costly if they were missed. This is more likely to occur if they are 'hidden' away within the notes/activities section. A configuration option would be ideal. |
|
@cas I will test out those options on a test build of Mantis. Thank you for the effort. |
|
Discovered small glitch with this fix. Opening inline (+ sign) shows image in the top-block and not showing it in 'activity' block... |
|
The fix provided above works great, except that the details are coming on multiple lines as shown in the attachment here. Is there a way to make the details come on one line? |
|
Just change this line: Should do the trick! |
|
Please note that |
|
In order to be future compliant, I think that the line: |
|
@cas I think it is colspan=5 |
|
Hello, Is there an official means of making available the "Attached Files" section without modifying the core configuration suite? Thanks, |
|
@cas thanx for tip but how to delete comments with attachments since they are already in the attached file box? |
|
@dzaggiel, the attachements will show up on both places. Not much to do avbout that. |
|
@cas ahh :( It is possible to add a date and time to attachements? |
|
Hello, In addition to the previous question, please also comment when possible on the question posed in this comment: https://www.mantisbt.org/bugs/view.php?id=22323#c57637 Thanks very much, |
|
@ Ryan, @dzaggiel, |
|
Hello, |
|
really no clue. for now this is an easy fix! |
|
I also speak in favor of the possibility of choosing how to display attachments. |
|
I just upgraded mantis and I'm having a lot of complaints from the users on how the attachments are organized. Please would you add the feature to choose how to display the attachments. |
|
Since it is not being added to core yet, i suggest you follow my instructions on how to actieve the “old” way� |
|
Hi guys, i'm getting an error. |
|
@andresrom,What exactly is the error message? |
|
Hi @cas |
|
if ( ON == config_get('show_attachments') ) { |
|
@wuqixin |
|
If "print_bug_attachments_list" is used, clicking the "chevron" on attachment in the note expands the attachment in the list (duplicate id?). |
|
Be aware that with 2.23 the suggested patch ignores that privacy of attachments, because of security issue https://mantisbt.org/bugs/view.php?id=26631 |
|
This patch worked great until we upgraded from 2.17 to 2.24. Now the Attached files section is there but no attachments listed. Can someone tell me if it works in 2.24 and if there is anything that I need to configure to make it work? |
|
For version 2.24 please use the following code at line 612 in bug_view_inc.php:
This is after the custom fields section just before the closing 'body' statement. Do not forget to set the variable in core/config_inc.php: |
|
That fixed it. Thank you! |
|
Adjusted the code to give a better fit. Done this for 2.24.2. User list sponsoring the bugDo not forget to set the variable in core/config_inc.php: reinstate_attachment_list.txt (1,198 bytes)
// CN start reinstate Attachment section if ( ON == config_get('show_attachments') ) { echo '<div class="col-md-12 col-xs-12">'; echo '<a id="attachments"></a>'; echo '<div class="space-10"></div>'; $t_collapse_block = is_collapsed( 'attachments' ); $t_block_css = $t_collapse_block ? 'collapsed' : ''; $t_block_icon = $t_collapse_block ? 'fa-chevron-down' : 'fa-chevron-up'; ?> <div id="attachments" class="widget-box widget-color-blue2 <?php echo $t_block_css ?>"> <div class="widget-header widget-header-small"> <h4 class="widget-title lighter"> <i class="ace-icon fa fa-users"></i> <?php echo lang_get( 'attached_files' ) ?> </h4> <div class="widget-toolbar"> <a data-action="collapse" href="#"> <i class="1 ace-icon fa <?php echo $t_block_icon ?> bigger-125"></i> </a> </div> </div> <div class="widget-body"> <div class="widget-main no-padding"> <div class="table-responsive"> <table class="table table-bordered table-condensed table-striped"> <tr><td> <?php print_bug_attachments_list( $f_issue_id, null); ?> </td> </tr> </table> </div> </div> </div> </div> </div> <?php } // CN end reinstate Attachment section |
|
Thanks for the updates in this topic. I was able to re-enable this feature for 2.25 |
|
Here is a PR that shows issue attachments with issue information and notes attachments along with notes: |
|
A big reason why we can't yet upgrade from mantis 1.x to 2.x is due to how attachments are handled. We want either attachments to be always linked with the issue and displayed in one place at the top of the issue (as it's done in 1.x), or we want to be able to choose whether to link an attachment with a specific note (and have it displayed in the note) or with the issue (and displayed at the top of the issue). The fix posted in 0022323:0064733 partly resolves the problem (thank you for providing the fix!), but it's still not possible to attach files directly to an issue, without adding a note. Hopefully it will be resolved in 0021820. |
|
I guess it should be possible to include that section in the fix, i will have a look @ this . Fully agree here that it should be configurable. |
|
Here it is, a plugin that allows to re-instate the attachments section and allows for uploading an attachment without a note. |
|
I have made some improvements in version 2.02:
|
|
please use version 2.03, it contains a fix for the instructions to avoid showing top-level attachments as an activity. |
|
@cas I did not actually test your plugin so I don't know if this is the cause, but looking at your tracker the markup is bad (misaligned sections). I tried to post a note there with screenshots to illustrate but my note and the files got lost somehow... |
|
@dregad, well spotted, I need to verify that. Actually there are 2 plugins that have the same effect, the Gauge Issue Support and the Attachments one. |
|
Final update here. Alignments adjusted, enjoy! |
|
About 66037: I installed the plugin on mantis 2.25 successfully. Works well, thank you! :) |
|
Hello, I´m using the plugin Attachments204.zip and it works very well but I am asked if it is possible to show the date the attachment was uploaded. Regards |
|
That is possible but would require a change to one of the core scripts. So I can give info on how to do this but:
Including in the plugin is possible but it would require some additional work on it. |
|
Hello cas, Would you be so kind as to indicate me where I can make the change? |
|
Open core/print_api.php insert these 2 lines: |
|
Thank you very much for your help |
|
Hi @cas ,the code save me a lot of time, thank you! |
|
Add these lines in core/config_inc.php:
And of course set the value to zero |
|
Hi @cas , The following codes can not disable the previewing of attachments in the "Attachment section" . // CN start reinstate Attachment section |
|
Hi rexchen, |
|