rebuildAssignments example



    public function rebuildAssignmentsAction()
    {
        // Try to set maximum execution time         @set_time_limit(0);

        $categoryId = $this->Request()->getParam('categoryId');
        $offset = $this->Request()->getParam('offset');
        $count = $this->Request()->getParam('limit');

        $this->getCategoryComponent()->rebuildAssignments($categoryId$count$offset);

        $this->view->assign([
            'success' => true,
        ]);
    }

    /** * Returns the number of categories that exist under the given one */
    public function getCategoryTreeCountAction()
    {
        


    /** * @param int $categoryId */
    public function backlogMoveCategory($categoryId)
    {
        $component = $this->getCategoryComponent();

        $component->rebuildCategoryPath($categoryId);
        $component->removeOldAssignments($categoryId);
        $component->rebuildAssignments($categoryId);
    }

    protected function addPendingAddAssignment(Article $article, Category $category)
    {
        $this->pendingAddAssignments[$category->getId() . '_' . $article->getId()] = [
            'category' => $category,
            'article' => $article,
        ];
    }

    protected function addPendingRemoveAssignment(Article $article, Category $category)
    {
Home | Imprint | This part of the site doesn't use cookies.