mirror of
https://github.com/colymba/GridFieldBulkEditingTools.git
synced 2024-10-22 11:05:57 +02:00
NEW: Defined global path to components folder
defined BULK_EDIT_TOOLS_PATH as root folder for Components, usefull in Requirements and make install easier.
This commit is contained in:
parent
a141aba650
commit
cf0a3262f7
@ -1 +1,6 @@
|
|||||||
<?php
|
<?php
|
||||||
|
|
||||||
|
if(!defined('BULK_EDIT_TOOLS_PATH'))
|
||||||
|
{
|
||||||
|
define('BULK_EDIT_TOOLS_PATH', rtrim(basename(dirname(__FILE__))));
|
||||||
|
}
|
@ -9,7 +9,7 @@ class GridFieldBulkEditingTools implements GridField_HTMLProvider
|
|||||||
{
|
{
|
||||||
public function getHTMLFragments($gridField)
|
public function getHTMLFragments($gridField)
|
||||||
{
|
{
|
||||||
Requirements::css('GridFieldBulkImageUpload/css/GridFieldBulkEditingTools.css');
|
Requirements::css(BULK_EDIT_TOOLS_PATH . '/css/GridFieldBulkEditingTools.css');
|
||||||
|
|
||||||
return array(
|
return array(
|
||||||
//"footer" => '<tr><td colspan="'.$columnsCount.'">\$DefineFragment(bulk-edit-tools)</td></tr>'
|
//"footer" => '<tr><td colspan="'.$columnsCount.'">\$DefineFragment(bulk-edit-tools)</td></tr>'
|
||||||
|
@ -262,9 +262,9 @@ class GridFieldBulkImageUpload_Request extends RequestHandler {
|
|||||||
// Calling forTemplate() before other requirements forces SS to add the Form's X-Include-JS before
|
// Calling forTemplate() before other requirements forces SS to add the Form's X-Include-JS before
|
||||||
$formHTML = $form->forTemplate();
|
$formHTML = $form->forTemplate();
|
||||||
|
|
||||||
Requirements::javascript('GridFieldBulkImageUpload/javascript/GridFieldBulkImageUpload.js');
|
Requirements::javascript(BULK_EDIT_TOOLS_PATH . '/javascript/GridFieldBulkImageUpload.js');
|
||||||
Requirements::css('GridFieldBulkImageUpload/css/GridFieldBulkImageUpload.css');
|
Requirements::css(BULK_EDIT_TOOLS_PATH . '/css/GridFieldBulkImageUpload.css');
|
||||||
Requirements::javascript('GridFieldBulkImageUpload/javascript/GridFieldBulkImageUpload_downloadtemplate.js');
|
Requirements::javascript(BULK_EDIT_TOOLS_PATH . '/javascript/GridFieldBulkImageUpload_downloadtemplate.js');
|
||||||
|
|
||||||
$response = new SS_HTTPResponse($formHTML);
|
$response = new SS_HTTPResponse($formHTML);
|
||||||
$response->addHeader('Content-Type', 'text/plain');
|
$response->addHeader('Content-Type', 'text/plain');
|
||||||
|
Loading…
Reference in New Issue
Block a user