Conpherence - add crop
Summary: mainly, this adds the image cropper - yay! - also removes the file image from the handle stuff I added in V1. now we do all this crazy photo stuff. Test Plan: - uploaded a photo by dragging to header and noted 120 x 80 showed up on reload - uploaded a photo by dragging to edit dialogue spot and noted 120 x 80 showed up on reload - cropped a photo - noted it cropped right - cropped a photo again and again and again - seems like it crops okay Reviewers: epriestley, chad Reviewed By: epriestley CC: aran, Korvin Maniphest Tasks: T2418, T2399 Differential Revision: https://secure.phabricator.com/D4790
This commit is contained in:
@@ -131,7 +131,10 @@ abstract class ConpherenceController extends PhabricatorController {
|
||||
$user = $this->getRequest()->getUser();
|
||||
foreach ($conpherences as $conpherence) {
|
||||
$uri = $this->getApplicationURI('view/'.$conpherence->getID().'/');
|
||||
$data = $conpherence->getDisplayData($user);
|
||||
$data = $conpherence->getDisplayData(
|
||||
$user,
|
||||
null
|
||||
);
|
||||
$title = $data['title'];
|
||||
$subtitle = $data['subtitle'];
|
||||
$unread_count = $data['unread_count'];
|
||||
@@ -220,6 +223,14 @@ abstract class ConpherenceController extends PhabricatorController {
|
||||
'form_pane' => 'conpherence-form'
|
||||
)
|
||||
);
|
||||
Javelin::initBehavior('conpherence-drag-and-drop-photo',
|
||||
array(
|
||||
'target' => 'conpherence-header-pane',
|
||||
'form_pane' => 'conpherence-form',
|
||||
'upload_uri' => '/file/dropupload/',
|
||||
'activated_class' => 'conpherence-header-upload-photo',
|
||||
)
|
||||
);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user