This file contains 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
public function staffs(){ | |
return $this->belongsToMany( | |
Staff::class, | |
OrganizationStaff::class, | |
'organization_id', | |
'staff_id', | |
'uuid', | |
'uuid' | |
); | |
} |
This file contains 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
using System; | |
using System.Collections.Generic; | |
using System.Linq; | |
using System.Web; | |
using System.Windows.Forms; | |
using System.IO; | |
using System.Drawing; | |
using System.Drawing.Imaging; | |
/// <summary> |
This file contains 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
using System; | |
using System.Collections.Generic; | |
using System.Linq; | |
using System.Web; | |
using System.Web.UI; | |
using System.Web.UI.WebControls; | |
public partial class public_convert : System.Web.UI.Page | |
{ | |
protected void Page_Load(object sender, EventArgs e) |
This file contains 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
FROM php:7.2-apache | |
RUN apt-get update | |
# WORKDIR /app | |
RUN apt-get install -y \ | |
git \ | |
zip \ | |
curl \ |
This file contains 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 | |
\Illuminate\Encryption\Encrypter; | |
$key = 'password12345678'; | |
$encrypter = new Encrypter($key); | |
$payload = ['username'=>'admin', 'password'=>'password']; | |
$encryption = $encrypter->encrypt($payload); |
This file contains 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
<!DOCTYPE html> | |
<head> | |
<meta charset="utf-8"> | |
<meta http-equiv="X-UA-Compatible" content="IE=edge"> | |
<meta name="viewport" content="width=device-width, initial-scale=1"> | |
<!-- The line below allows http requests to be upgraded to https. | |
if the request was initially served over https it will be safe | |
--> | |
<meta http-equiv="Content-Security-Policy" content="upgrade-insecure-requests"> |
This file contains 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\Http\Controllers; | |
use App\Services\ApiService; | |
use Illuminate\Http\Request; | |
This file contains 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
Basic laravel Queries | |
- Hopefully OPtimised |
This file contains 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 | |
public function decrypt($payload, $password, $iv = null, $method=null){ | |
if(empty($method)){ | |
$method = "AES-128-CBC"; | |
} | |
if(empty($iv)){ | |
$iv = ""; |
This file contains 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 | |
Schema::create('payments', function (Blueprint $table) { | |
$table->bigIncrements('id'); | |
$table->uuid('uuid')->unique(); | |
$table->uuid('member_id')->nullable(); // the person paying uuid | |
$table->uuid('subscription_id')->nullable(); //if you have a subscription table else delete this line | |
$table->uuid('transaction_id')->nullable(); | |
$table->float('amount', 10, 2)->nullable(); | |
$table->string('reference_id')->nullable(); //paystack or flutter reference |
OlderNewer