SproutCMS

This is the code documentation for the SproutCMS project

class PerRecordPerms

Helper for implementing per-record permissions

Extending this class

<?php
/**
* New class description goes here
* 
* @author Your Name, 2026-09-16
**/
class NewClassName extends PerRecordPerms {
    
    /**
    * Checks to see if per-record permissions apply to a particular controller
    **/
    public function controllerRestricted (ManagedAdminController $ctlr) {
        // Method code goes here
    }
    
    /**
    * Checks if a given controller has at least one permission rule in place
    **/
    public function hasRecordPerms (ManagedAdminController $ctlr) {
        // Method code goes here
    }
    
    /**
    * Gets a clause to restrict a query to the set of categories the current admin belongs to
    **/
    public function getCategoryClause () {
        // Method code goes here
    }
    
    /**
    * Gets the permission details from the database
    **/
    public function fetchDetails (ManagedAdminController $ctlr, int $item_id) {
        // Method code goes here
    }
    
    /**
    * Save the permissions for a particular record
    **/
    public function save (ManagedAdminController $ctlr, int $item_id) {
        // Method code goes here
    }
    
}
?>