morgan / kohana-paginate Goto Github PK
View Code? Open in Web Editor NEWPaginate abstraction supporting Database, ORM, ORM-REST and Dispatch.
License: MIT License
Paginate abstraction supporting Database, ORM, ORM-REST and Dispatch.
License: MIT License
This is in response to: #1
Hi,
mysql_real_escape_string will be removed in future, please add alternative to mysql_real_escape_string in Kohana_Paginate_Database::_sort
and Kohana_Paginate_Database::_search
Hi,
This is a question rather than a bugs :)
With kohana-paginate, can I do something like this ( get all posts with 'news' tag)?
$tag = ORM::factory('tag', 5); // news tag
$articles = $tag->articles; // articles with news' tag
$paginate = Paginate::factory($articles);
I try the above code, but didn't work
Thanks.
Hi and sorry to bother you again :)
I'm trying to use paginate with this query :
$products = DB::query(Database::SELECT, '
SELECT * FROM shop_products
GROUP BY CASE configurable
WHEN 1 THEN configuration_id
ELSE id
END
')->as_object('Model_Product');
I have to go through a manual query because ORM does not support the group by case condition.
The thing is, DB::query() returns a Database_Query object which (logically) does not implement the order_by() and the offset() functions, so I'm getting this error : Call to undefined method Database_Query::order_by() in /modules/paginate/classes/Kohana/Paginate/Database.php on line 64
Would you have an idea to work around this problem? Right now the only way I can see this working, is to actually write a group_by_case function for the database query builder class, but I thought you might have another idea...?
Hi,
Is it possible to add a ->where('col','=','something') ORM condition to a paginate object ?
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.