This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?php | |
| class Helper | |
| { | |
| public static $bn = ['১', '২', '৩', '৪', '৫', '৬', '৭', '৮', '৯', '০']; | |
| public static $en = ['1', '2', '3', '4', '5', '6', '7', '8', '9', '0']; | |
| public static function bn2en($number) | |
| { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /** | |
| * Continents and Countries MySQL Tables compiled from Wikipedia, Braintree Payments documentation | |
| * and a couple other places I don't recall at the moment. This data is compatible with the Braintree | |
| * Payment API as of Dec 2011 | |
| * | |
| * Compiled by Steve Kamerman, 2011 | |
| */ | |
| SET FOREIGN_KEY_CHECKS=0; | |
| -- ---------------------------- |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?php | |
| namespace App\Providers; | |
| use Illuminate\Support\Collection; | |
| use Illuminate\Pagination\LengthAwarePaginator; | |
| class AppServiceProvider extends ServiceProvider | |
| { | |
| public function boot() |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?php | |
| namespace App\Passport; | |
| use App\User; | |
| use Lcobucci\JWT\Builder; | |
| use Lcobucci\JWT\Signer\Key; | |
| use League\OAuth2\Server\CryptKey; | |
| use Lcobucci\JWT\Signer\Rsa\Sha256; | |
| use Laravel\Passport\Bridge\AccessToken as BaseToken; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?php | |
| /** | |
| * Gera a paginação dos itens de um array ou collection. | |
| * | |
| * @param array|Collection $items | |
| * @param int $perPage | |
| * @param int $page | |
| * @param array $options | |
| * | |
| * @return LengthAwarePaginator |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| axios({ | |
| url: 'http://localhost:5000/static/example.pdf', | |
| method: 'GET', | |
| responseType: 'blob', // important | |
| }).then((response) => { | |
| const url = window.URL.createObjectURL(new Blob([response.data])); | |
| const link = document.createElement('a'); | |
| link.href = url; | |
| link.setAttribute('download', 'file.pdf'); | |
| document.body.appendChild(link); |