Skip to content
This repository has been archived by the owner on Nov 8, 2018. It is now read-only.

Show attachments as blocks instead of list to allow enhanced actions #1448

Merged
merged 6 commits into from
May 4, 2016

Conversation

ChristophWurst
Copy link
Contributor

@ChristophWurst ChristophWurst commented Apr 24, 2016

This moves attachment rendering out of the message view and shows attachment as blocks instead of a simple list:
bildschirmfoto von 2016-04-24 15-48-31

My goal is to make the attachments view ready for enhanced attachment actions, like integration with other apps (contacts, calendar, maps) and previews of other file types (ref #1374, #79).

TODO:

  • fix single attachment
  • make attachment width responsive (on mobile there should be only a single attachment per line)
  • rebase onto Remove ui.js and init.js #1447 once it's merged so the save-attachment-methods can be moved into the attachment(s) view
  • show attachments with previews first? cc @jancborchardt (is done by the server already)
  • show full attachment name on hover
  • open attachment on click (ref #1308)
  • fix 'save to cloud' urls (fixes #1437)
  • find out while core failes saving the files – it failed only on my dev instance apparently

Ideas for future PRs:

  • use popover for download and other attachment actions

fixes #1308

@mention-bot
Copy link

By analyzing the blame information on this pull request, we identified @jakobsack, @jancborchardt and @DeepDiver1975 to be potential reviewers

@jancborchardt
Copy link
Contributor

This looks super nice! 👍

show attachments with previews first?

Yeah, good call.

@ChristophWurst ChristophWurst modified the milestones: 0.4.4, 0.4.5 Apr 26, 2016
attachmentId: attachmentId
});
console.log(arguments);
console.log(url);
Copy link
Contributor Author

@ChristophWurst ChristophWurst Apr 28, 2016

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

  • TODO: remove

@ChristophWurst ChristophWurst force-pushed the enhanced-attachments branch 2 times, most recently from 85e5487 to abca7a4 Compare April 28, 2016 19:21
@ChristophWurst ChristophWurst modified the milestones: 0.4.4, 0.4.5 May 3, 2016
@skjnldsv
Copy link
Contributor

skjnldsv commented May 4, 2016

Can't save on my owncloud file error 500:

Error   index   OCP\Lock\LockedException: "Site.zip" is locked
/usr/share/webapps/owncloud/lib/private/files/view.php - line 1085: OC\Files\View-changeLock('/admin/files/Si...', 1)
/usr/share/webapps/owncloud/lib/private/files/view.php - line 506: OC\Files\View-basicOperation('touch', '/admin/files/Si...', Array, NULL)
/usr/share/webapps/owncloud/lib/private/files/node/folder.php - line 165: OC\Files\View-touch('/admin/files/Si...')
/usr/share/webapps/owncloud/apps/mail/lib/controller/messagescontroller.php - line 307: OC\Files\Node\Folder->newFile('//Site.zip')
[internal function] OCA\Mail\Controller\MessagesController->saveAttachment(2, 'QXJjaGl2ZXM=', '50', 2, '/')
/usr/share/webapps/owncloud/lib/private/appframework/http/dispatcher.php - line 159: call_user_func_array(Array, Array)
/usr/share/webapps/owncloud/lib/private/appframework/http/dispatcher.php - line 89: OC\AppFramework\Http\Dispatcher->executeController(Object(OCA\Mail\Controller\MessagesController), 'saveAttachment')
/usr/share/webapps/owncloud/lib/private/appframework/app.php - line 110: OC\AppFramework\Http\Dispatcher->dispatch(Object(OCA\Mail\Controller\MessagesController), 'saveAttachment')
/usr/share/webapps/owncloud/lib/private/appframework/routing/routeactionhandler.php - line 45: OC\AppFramework\App main('OCA\\Mail\\Contro...', 'saveAttachment', Object(OC\AppFramework\DependencyInjection\DIContainer), Array)
[internal function] OC\AppFramework\routing\RouteActionHandler->__invoke(Array)
/usr/share/webapps/owncloud/lib/private/route/router.php - line 276: call_user_func(Object(OC\AppFramework\routing\RouteActionHandler), Array)
/usr/share/webapps/owncloud/lib/base.php - line 882: OC\Route\Router->match('/apps/mail/acco...')
/usr/share/webapps/owncloud/index.php - line 39: OC handleRequest()
{main}

capture d ecran_2016-05-04_05-44-42

@skjnldsv
Copy link
Contributor

skjnldsv commented May 4, 2016

Except from that, it's working great. Congrats on using inline-block, good call!

@ChristophWurst
Copy link
Contributor Author

@skjnldsv could you please open a new issue for that bug? Seems unrelated, but we should definitely fix that too!

@ChristophWurst ChristophWurst merged commit 5e02f7f into master May 4, 2016
@ChristophWurst ChristophWurst deleted the enhanced-attachments branch May 4, 2016 06:39
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants