X-Git-Url: https://git.m6w6.name/?p=m6w6%2Fpq-gateway;a=blobdiff_plain;f=lib%2Fpq%2FQuery%2FExpressible.php;h=d123d8d8cc5fc2ea0816f282f6452d217e6af6ba;hp=ffcf7c2c0f0936d0b693ece11846b85261492156;hb=002783858d3a859b1bbae977cc6db4ed13ca0187;hpb=dc87da9c4ec52918e34f2e43eac3014f0f99a8bc diff --git a/lib/pq/Query/Expressible.php b/lib/pq/Query/Expressible.php index ffcf7c2..d123d8d 100644 --- a/lib/pq/Query/Expressible.php +++ b/lib/pq/Query/Expressible.php @@ -4,12 +4,22 @@ namespace pq\Query; class Expressible implements ExpressibleInterface { + /** + * @var string + */ + protected $name; + /** * @var mixed */ protected $data; - function __construct($data) { + /** + * @param string $name + * @param mixed $data + */ + function __construct($name, $data) { + $this->name = $name; $this->data = $data; } @@ -63,10 +73,9 @@ class Expressible implements ExpressibleInterface } elseif (!isset($op) && is_numeric($data)) { $this->data->add(new Expr("+ $data")); } else { - $data = $this->row->getTable()->getConnection()->quote($data); $this->data->add(new Expr("%s %s", isset($op) ? $op : "||", $data)); } return $this; - } -} \ No newline at end of file + } +}