Skip to content

Instantly share code, notes, and snippets.

View aldhinya's full-sized avatar
😂
I may be slow to respond.

Fadhilatur Rochman aldhinya

😂
I may be slow to respond.
View GitHub Profile
/tool fetch http-method=post http-data="number=085697583263&token=BI:psLa5c6Nd4MIKROTIK%9MJmKFdldYQX8UrJ%&message=[UP] PING ke orbiz.id" url="http://103.152.37.221:3000/send-message" keep-result=no
/tool fetch http-method=post http-data="number=085697583263&token=BI:psLa5c6Nd4MIKROTIK%9MJmKFdldYQX8UrJ%&message=[DOWN] PING ke orbiz.id" url="http://103.152.37.221:3000/send-message" keep-result=no
@aldhinya
aldhinya / Middleware.php
Last active December 11, 2023 07:17
Manual Auth
<?php
namespace App\Http\Middleware;
use Closure;
use Illuminate\Http\Request;
use Illuminate\Support\Facades\Auth;
use Illuminate\Support\Facades\Route;
class AuthLogin
<?php
namespace App\Exports;
use Maatwebsite\Excel\Concerns\FromCollection;
use Maatwebsite\Excel\Concerns\WithTitle;
use Maatwebsite\Excel\Concerns\FromView;
use Illuminate\Contracts\View\View;
use Maatwebsite\Excel\Concerns\ShouldAutoSize;
use Maatwebsite\Excel\Concerns\WithColumnFormatting;
<script>
$(() => {
const pivotGridChart = $('#pivotgrid-chart').dxChart({
commonSeriesSettings: {
type: 'bar',
},
tooltip: {
enabled: true,
customizeTooltip(args) {
return {
use Imagick;
$pdf = PDF::loadView('mitra.plotkunjungan.pdf', compact('surat'))->setPaper('a4', 'potrait');;
$path = public_path('docs/');
$fileName = time() . '.' . 'pdf';
$path_pdf = $path . $fileName;
$pdf->save($path_pdf);
$path_img = str_replace('pdf', 'jpg', $path_pdf);
$imgExt = new Imagick();
<?php
use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema;
return new class extends Migration
{
/**
* Run the migrations.
$tanggal = $this->transformDate($i[2])->toDateString();
public function transformDate($value, $format = 'Y-m-d')
{
try {
return \Carbon\Carbon::instance(\PhpOffice\PhpSpreadsheet\Shared\Date::excelToDateTimeObject($value));
} catch (\ErrorException $e) {
return \Carbon\Carbon::createFromFormat($format, $value);
}
}
public function index(Request $request)
{
if (request()->ajax()) {
$columnIndex_arr = $request->get('order');
$columnName_arr = $request->get('columns');
$order_arr = $request->get('order');
$search_arr = $request->get('search');
$columnIndex = $columnIndex_arr[0]['column'];
$columnName = $columnName_arr[$columnIndex]['data'];
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<meta http-equiv="x-ua-compatible" content="ie=edge">
<title>Reminder Kuota</title>
<meta name="viewport" content="width=device-width, initial-scale=1">
<style type="text/css">
@media screen {
@font-face {
// Controller
<?php
namespace App\Http\Controllers;
use App\Http\Controllers\Controller;
use App\Models\Buku;
use App\Models\Member;
use Illuminate\Http\Request;