Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Added a URL for displaying the number of items in an album (excluding…

… sub-albums).

Signed-off-by: Tim Almdal <tnalmdal@shaw.ca>
  • Loading branch information...
commit 29c82a71494af556bdb595a5ae6b2fcdc67e20c8 1 parent 59ebb08
rWatcher authored talmdal committed
Showing with 10 additions and 0 deletions.
  1. +10 −0 modules/itemchecksum/controllers/itemchecksum.php
10 modules/itemchecksum/controllers/itemchecksum.php
View
@@ -18,6 +18,16 @@
* Foundation, Inc., 51 Franklin Street - Fifth Floor, Boston, MA 02110-1301, USA.
*/
class itemchecksum_Controller extends Controller {
+ public function albumcount($album_id) {
+ $item = ORM::factory("item")
+ ->viewable()
+ ->where("parent_id", $album_id)
+ ->where("type !=", "album")
+ ->find_all();
+
+ print count($item);
+ }
+
public function md5($album_id, $file_name) {
$item = ORM::factory("item")
->where("parent_id", $album_id)
Please sign in to comment.
Something went wrong with that request. Please try again.