Skip to content

Instantly share code, notes, and snippets.

View jiromm's full-sized avatar

Aram Baghdasaryan jiromm

View GitHub Profile
{
"list": [
{
"id": 1,
"parent_id": null,
"name": "Мадина Тулепкулова",
"value": 12.4
},
{
"id": 2,
@jiromm
jiromm / UnitTest.php
Last active March 31, 2020 11:21
wget -O phpunit https://phar.phpunit.de/phpunit-9.phar && php phpunit UnitTest.php
<?php
use PHPUnit\Framework\TestCase;
include 'get_next.php';
final class UnitTest extends TestCase
{
/**
* @dataProvider invalidDataProvider
<?php
use PHPUnit\Framework\TestCase;
include 'hayk.php';
final class UnitNumberTest extends TestCase
{
/**
* @dataProvider invalidDataProvider
@jiromm
jiromm / laravel.conf
Last active March 15, 2023 18:36
Logstash config file for laravel logs
input {
file {
path => "/var/www/laravel-project/storage/logs/laravel.log"
codec => multiline {
pattern => "^\[%{TIMESTAMP_ISO8601:timestamp}\]"
what => "previous"
negate => true
}
}
}
<?php
$list = [
[1, 2],
[2, 1],
[3, 1],
[4, 1],
[5, 2],
[6, 3],
[7, 3],
<?php
class x {
public $sum = 0;
public function __invoke($num = 0)
{
$this->sum += $num;
return $this;
}
<html>
<head>
<script src="https://cdn.pubnub.com/pubnub-3.7.13.min.js"></script>
<script type="text/javascript">
var isFreeze = false;
function freeze() {
$('#freezeModal').modal({
backdrop: 'static',
<?php
class x {
public $sum = 0;
public function __invoke($num = 0)
{
$this->sum += $num;
return $this;
}
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
<title>HTML Email Layout for Reports</title>
</head>
<body bgcolor="#E0E0E0" style="font-family: Arial, Helvetica; margin: 0; padding: 0; min-width: 100%!important;">
<table width="100%" bgcolor="#E0E0E0" border="0" cellpadding="0" cellspacing="0" style="font-family: Arial, Helvetica; color: #757575;">
<tr>
<td>
@jiromm
jiromm / Converse.php
Last active June 4, 2017 17:25
Converse.php
<?php
class Converse {
const CURRENCY_AMD = '051';
const CURRENCY_AMD = 'hy';
protected $endpoint = 'https://xxx/payment/rest/register.do';
protected $username = '';
protected $password = '';