Skip to content

Instantly share code, notes, and snippets.

View dhimasanb's full-sized avatar
🎯
Focusing

Dhimas Akbar Noor Baihaque dhimasanb

🎯
Focusing
View GitHub Profile
@dhimasanb
dhimasanb / AppServiceProvider.php
Last active April 9, 2017 17:40
Syntax error or access violation: 1071 Specified key was too long; max key length is 767 bytes on Laravel 5.4
<?php
namespace App\Providers;
use Illuminate\Support\ServiceProvider;
use Illuminate\Support\Facades\Schema; // Add this
class AppServiceProvider extends ServiceProvider
{
/**
@dhimasanb
dhimasanb / PHP.ini
Created May 17, 2017 11:58
Config PHP.ini on Linux to Installation Laravel
[PHP]
;;;;;;;;;;;;;;;;;;;
; About php.ini ;
;;;;;;;;;;;;;;;;;;;
; PHP's initialization file, generally called php.ini, is responsible for
; configuring many of the aspects of PHP's behavior.
; PHP attempts to find and load this configuration from a number of locations.
; The following is a summary of its search order:
@dhimasanb
dhimasanb / php.ini
Created May 28, 2017 21:11
My PHP Config for Laravel
[PHP]
;;;;;;;;;;;;;;;;;;;
; About php.ini ;
;;;;;;;;;;;;;;;;;;;
; PHP's initialization file, generally called php.ini, is responsible for
; configuring many of the aspects of PHP's behavior.
; PHP attempts to find and load this configuration from a number of locations.
; The following is a summary of its search order:
@dhimasanb
dhimasanb / laravel
Last active February 5, 2018 08:17
Simple Config Laravel + Nginx
server {
# Port that the web server will listen on.
listen 8081 default_server;;
# listen [::]:80 default_server ipv6only=on;
# SSL Config
#
# listen 443 ssl default_server;
# listen [::]:443 ssl default_server;
@dhimasanb
dhimasanb / Vagrantfile
Created July 15, 2017 06:09
Vagrantfile
# -*- mode: ruby -*-
# vi: set ft=ruby :
# All Vagrant configuration is done below. The "2" in Vagrant.configure
# configures the configuration version (we support older styles for
# backwards compatibility). Please don't change it unless you know what
# you're doing.
Vagrant.configure("2") do |config|
# The most common configuration options are documented and commented below.
# For a complete reference, please see the online documentation at
@dhimasanb
dhimasanb / muach.php
Created February 14, 2018 16:23
Cari 3 Level yg sama
// Koneksi.php
<?php
class Koneksi {
private $SERVER = "localhost";
private $DATABASE = "contoh_test";
private $USERNAME = "root";
private $PASSWORD = "";
private $koneksi;
public function __construct() {
import React from "react";
import { Table } from "antd";
import { convertToRupiah } from "../../../../../utils/helpers";
import column from "./column";
const amountLeftTable = ({ amountLeft }) => {
return (
<Table
showHeader={false}
// Column table
export default function column(title, dataIndex, width, render) {
return {
title,
dataIndex,
key: dataIndex,
width,
render
};
}
import React from "react";
import { Table } from "antd";
import column from "./column";
const dataTable = ({ dataSource }) => {
return (
<Table
pagination={false}
dataSource={dataSource}
@dhimasanb
dhimasanb / index.js
Created June 25, 2019 16:36
Table Result Index.js
import React from "react";
import PropTypes from "prop-types";
import { convertToRupiah } from "../../../../utils/helpers";
import DataTable from "./components/dataTable";
import AmountLeftTable from "./components/amountLeftTable";
import "./index.css";
const TableResult = ({ data, amountLeft }) => {
// Result data fractions
const dataSource = [];