<?php
/**
  * Ahead WebSoft Technologies Pvt Ltd.
  * @copyright  Copyright 2006-2026 Ahead WebSoft Technologies Pvt Ltd.
  * @license    https://www.socialengine.com/policies
*/
class Forum_Api_Core extends Core_Api_Abstract
{
 
  public function getMaxCategoryOrder()
  {
    $table = Engine_Api::_()->getItemTable('forum_category');
    $select = new Zend_Db_Select($table->getAdapter());
    $select = $select->from($table->info('name'), new Zend_Db_Expr('MAX(`order`) as max_order'));
    $data = $select->query()->fetch();
    $order = (int) @$data['max_order'];
    return $order;

  }
 
}
