public function onGenerateThumbnails()
    {
        $batch = Input::get('batch');
        if (!is_array($batch)) {
            return;
        }

        $result = [];
        foreach ($batch as $thumbnailInfo) {
            $result[] = $this->generateThumbnail($thumbnailInfo);
        }

        return [
            'generatedThumbnails'=>$result
        ];
    }
public function onGenerateThumbnails()
    {
        $batch = Input::get('batch');
        if (!is_array($batch)) {
            return;
        }

        $result = [];
        foreach ($batch as $thumbnailInfo) {
            $result[] = $this->generateThumbnail($thumbnailInfo);
        }

        return [
            'generatedThumbnails'=>$result
        ];
    }
public function onGenerateThumbnails ( ) { $ batch = Input :: get ( 'batch' ) ; if ( ! is_array ( $ batch ) ) { return ; } $ result = [ ] ; foreach ( $ batch as $ thumbnailInfo ) { $ result [ ] = $ this -> generateThumbnail ( $ thumbnailInfo ) ; } return [ 'generatedThumbnails' => $ result ] ; }
Generate thumbnail AJAX handler
@return array
Generate thumbnail AJAX handler