mirror of
https://gitlab.com/omair-personal/exchange.git
synced 2026-08-19 04:24:08 +00:00
add bookingcontroller@report, still in testing
This commit is contained in:
@@ -11,6 +11,7 @@ use App\UserBankSlip;
|
||||
use App\User;
|
||||
use App\Invoice;
|
||||
use App\SettingCredit;
|
||||
use Anam\PhantomMagick\Converter;
|
||||
use Auth;
|
||||
use Validator;
|
||||
use DateTime;
|
||||
@@ -635,13 +636,13 @@ class BookingController extends Controller
|
||||
return response()->json(['message'=>"Success"],200);
|
||||
}
|
||||
|
||||
public function report(Request $request){
|
||||
$conv = new \Anam\PhantomMagick\Converter();
|
||||
$conv->source('http://google.com')
|
||||
->toPng()
|
||||
->save('/your/destination//google.png');
|
||||
$conv->toPng();
|
||||
|
||||
}
|
||||
public function report(Request $request, $id)
|
||||
{
|
||||
$conv = new Converter();
|
||||
// $conv->setBinary('/vendor/anam/phantomjs-linux-x86-binary/bin/phantomjs');
|
||||
$conv->addPage('<html><body><h1>Welcome to PhantomMagick</h1></body></html>')
|
||||
->save('/storage/app/report/multipage.pdf');
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user