-
Notifications
You must be signed in to change notification settings - Fork 1.4k
Adding new column to list view in 2.1
667bdrm edited this page Oct 30, 2018
·
4 revisions
- Implement statCorrector function to retrieve extra info and extend file stat. In this example used custom volume driver method:
public static function stat_corrector(&$stat, $path, $statOwner, $volumeDriveInstance) {
$stat['owner'] = $volumeDriveInstance->MyOwnerFunction($volumeDriveInstance->encode($path));
}
- Add statCorrector parameter to the elFinder Connector initialization
'statCorrector' => 'elFinderVolumeMyCustom::stat_corrector',
- Add the new column before $.elfinder call in ui:
elFinder.prototype._options.uiOptions.cwd.listView.columns.push('owner');
elFinder.prototype._options.uiOptions.cwd.listView.columnsCustomName['owner'] = 'Owner';