??????????????
<?php namespace App\Libs;

/**
 * Created by PhpStorm.
 * User: Александр
 * Date: 19.05.2015
 * Time: 22:08
 */

use App;
use App\Size;

class Hour
{
    public function __construct()
    {
    }

    public function get($width = null, $height = null, $catalog_id = null)
    {
        $sd = \App::make('\App\Libs\Sum')->getPrice($width, $height);
        $price = Size::where('size', $sd)->where('catalogs_id', $catalog_id)->first();
        $p = $price->price;
        $h = ceil($p / 80) / 2;
        if ($h > 4) {
            $h = 4;
        }
        ret