2017 © Pedro Peláez
 

library json-where

image

sukohi/json-where

  • Wednesday, August 19, 2015
  • by Sukohi
  • Repository
  • 1 Watchers
  • 0 Stars
  • 20 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 0 Forks
  • 0 Open issues
  • 7 Versions
  • 5 % Grown

The README.md

JsonWhere

A PHP package mainly developed for Laravel to easily set where clause for JSON.
(This is for Laravel 5+. For Laravel 4.2), (*1)

Installation

Add this package name in composer.json, (*2)

"require": {
  "sukohi/json-where": "2.*"
}

Execute composer command., (*3)

composer update

Register the service provider in app.php, (*4)

'providers' => [
    ...Others...,  
    Sukohi\JsonWhere\JsonWhereServiceProvider::class,
]

Also alias, (*5)

'aliases' => [
    ...Others...,  
    'JsonWhere'   => Sukohi\JsonWhere\Facades\JsonWhere::class
]

Usage

$jsons = DB::table('tests')->where(function($query){

                \JsonWhere::query($query)
                    ->column('json')
                    ->value(3, $type = 'auto'); // $type: (default: auto), string or int. Optional.

            })->get();

or You also can use model like so., (*6)

$jsons = \App\Test::where(function($query){

                \JsonWhere::query($query)
                    ->column('json')
                    ->value(3, 'int');

            })->get();

License

This package is licensed under the MIT License., (*7)

Copyright 2015 Sukohi Kuhoh, (*8)

The Versions

19/08 2015

1.0.x-dev

1.0.9999999.9999999-dev

  Sources   Download

MIT

The Requires

 

by Avatar Sukohi

19/08 2015

1.0.2

1.0.2.0

  Sources   Download

MIT

The Requires

 

by Avatar Sukohi

16/08 2015

2.0.x-dev

2.0.9999999.9999999-dev

A PHP package mainly developed for Laravel to easily set where clause for JSON.

  Sources   Download

MIT

The Requires

 

by Avatar Sukohi

08/08 2015

dev-master

9999999-dev

  Sources   Download

MIT

The Requires

 

by Avatar Sukohi

08/08 2015

2.0.0

2.0.0.0

  Sources   Download

MIT

The Requires

 

by Avatar Sukohi

08/08 2015

1.0.1

1.0.1.0

  Sources   Download

MIT

The Requires

 

by Avatar Sukohi

08/08 2015

1.0.0

1.0.0.0

  Sources   Download

MIT

The Requires

 

by Avatar Sukohi