Skip to content

Instantly share code, notes, and snippets.

View Adamwaheed's full-sized avatar
🙃

Adam Adamwaheed

🙃
View GitHub Profile
@Adamwaheed
Adamwaheed / useAPI.ts
Created June 9, 2023 19:09
Dependancy and useAPI
import { build } from "nuxt";
import { Data } from "~/types/generated";
export const useAPI = (
url: string,
items: any,
meta: any,
item: any,
status: any,
errors: {}
<?php
namespace App\Services;
use App\Models\Entity;
use Illuminate\Support\Arr;
use Illuminate\Support\Collection;
class EntityTree
<?php include 'components/head.php'; ?>
<!-- Sidebar -->
<?php include 'components/sidebar.php'; ?>
<!-- /#sidebar-wrapper -->
<!-- Page Content -->
<div id="page-content-wrapper">
<!-- Nav-->
<?php
include_once 'Db.php';
class Post
{
/* Fetch All */
public function readData()
{
try {
<?php
class Db
{
private $server = "mysql:host=localhost;dbname=project";
private $user = "root";
private $pass = "";
<?php
interface TelegramInterface
{
public function send();
}
import { Component, OnInit } from '@angular/core';
import {MatDialog, MatSnackBar, MatTableDataSource} from '@angular/material';
import {ActivatedRoute, Router} from '@angular/router';
import {FormControl} from '@angular/forms';
import {debounceTime} from 'rxjs/operators';
import {CustomerService} from '../../services/customer.service';
import {CustomerFormComponent} from './customer-form/customer-form.component';
@Component({
selector: 'bonito-customers',
@Adamwaheed
Adamwaheed / tree.php
Created February 20, 2018 10:25
Tree
<?php
namespace App\Model\Common;
class Tree {
//building tree
public function buildTree(array $elements, $parentId = 0) {
$branch = array();
$child = array();
foreach ($elements as $element) {
@Adamwaheed
Adamwaheed / Important awaguraana
Created October 26, 2016 09:05
Important awaguraana
$awaguraan = [
'fuck',
'nagoobalhu',
'wtf',
'rundi',
'fui',
'balaaeh',
'amaafui',
'foah',
'foakey',
<?php
interface CalculateInterface{
public function canculate();
}
class PilotageCharges implements CalculateInterface{
public $model;
public $profile_id;
public function __construct($model,$profile_id){