Skip to content

Instantly share code, notes, and snippets.

View zloadmin's full-sized avatar
💭
I may be slow to respond.

Vladimir Karpovich zloadmin

💭
I may be slow to respond.
View GitHub Profile
<?php
private function getArrayRequest(string $token, array $data, bool $ios = false): array
{
if ($ios) $this->getIosArrayRequest($token, $data);
return $this->getAndroidArrayRequest($token, $data);
}
private function getIosArrayRequest(string $token, array $data)
{
return [
{
"api": {
"results": 1,
"standings": [
[
{
"rank": 1,
"team_id": 50,
"teamName": "Манчестер Сити",
"logo": "https://media.api-sports.io/teams/50.png",
{
"api": {
"results": 1,
"standings": [
[
{
"rank": 1,
"team_id": 50,
"teamName": "Манчестер Сити",
"logo": "https://media.api-sports.io/teams/50.png",
{
"_id" : ObjectId("5e613eb27d5aa0c3d9397948"),
"fixture_id" : NumberInt(65),
"updated_at" : ISODate("2020-03-05T18:02:26.000+0000"),
"created_at" : ISODate("2020-03-05T18:02:26.000+0000"),
"awayTeam" : {
"team_id" : NumberInt(46),
"team_name" : "Leicester",
"logo" : "https://media.api-sports.io/teams/46.png"
},
#!/usr/bin/env node
let WebSocketClient = require('websocket').client;
let client = new WebSocketClient();
let moment = require('moment');
const url = 'mongodb://localhost:27017';
const dbName = 'binance';
// const collectionName = "\u006D\u0061\u0074\u0069\u0063\u005F\u0062\u0074\u0063\u0073";
const collectionName = "trades";
const MongoClient = require('mongodb').MongoClient;
const assert = require('assert');
@zloadmin
zloadmin / CompanyController.php
Created November 28, 2019 09:05
CompanyController.php
<?php
namespace App\Http\Controllers\Api;
use App\Company;
use App\Http\Controllers\Controller;
use App\Http\Resources\CompanyCollection;
use App\Http\Resources\SingleCompany;
use Illuminate\Http\Request;
/**
* @group Companies
*
<?php
namespace App;
use Carbon\Carbon;
use Illuminate\Database\Eloquent\Model;
use Illuminate\Database\Eloquent\SoftDeletes;
use App\Instrument;
use App\Source;
use App\Person;
<?php
namespace App;
use Carbon\Carbon;
use Illuminate\Database\Eloquent\Model;
use Illuminate\Database\Eloquent\SoftDeletes;
use App\Instrument;
use App\Source;
use App\Person;
<?php
/**
* Created by PhpStorm.
* User: vladimir
* Date: 12/05/2018
* Time: 1:22 PM
*/
namespace App;
use Illuminate\Support\Facades\DB;
<template>
<div>
<steps
v-for="(step, index) in steps"
:step="step"
:current="current"
:index="index"
:button_url="button_url"
:button_text="button_text"
:button_type="button_type"