Age | Commit message (Collapse) | Author | Files | Lines |
|
This view template can be included from object setting tab view to
display controls for adjusting object permissions.
|
|
Increase the scope of this function so it may be used by groups.
|
|
|
|
To maintain forward compatability with newer versions of PHP (and since
my dev environment is now running PHP 7), this patch is made to address
the following breaking change from PHP 5:
PHP 7 now uses an abstract syntax tree when parsing source files. This
has permitted many improvements to the language which were previously
impossible due to limitations in the parser used in earlier versions of
PHP, but has resulted in the removal of a few special cases for
consistency reasons, which has resulted in backward compatibility
breaks. Indirect access to variables, properties, and methods will now
be evaluated strictly in left-to-right order, as opposed to the previous
mix of special cases.
|
|
This reverts commit 112a510bb7ba358fd4195b5b2f3c8203ab4fb91d.
Conflicts:
app/model/obj.mod.php
|
|
Created empty <div> for the group setting tab. Also added code to the
common model for initializing the $mod->group variable and setting a
flag marking what tabs to include in the setting modal (group tab in
this case). Added logic to the main setting modal view file for picking
up these flags and including appropriate additional content.
|
|
This commit makes the Obj controller compatable with changes introduced
in the previous commit.
|
|
Some logic to initialize the current system object, its owner, and
members has been moved into the Common model since this code will be
relevant to other views and to support a new feature being added to
display additional tabs in the setting modal box.
|
|
|
|
The setting modal window will need to support showing unknown tabs at
the beginning of the tab list. These functions handle assigning specific
CSS classes to tab-panes ONLY if that tab will appear in the left-most
position in the modal's tab list.
|
|
|
|
|
|
This function returns all groups the user either owns or is a member of.
This is not necessarily the same as all groups the user has access
permission to. The *not-yet-implemented* object explorer feature should
be used to browse those.
|
|
In the Obj MVC, rename group in the model to obj. This will help with
referencing the active object from template views without knowing what
type of object it is.
|
|
|
|
If the current user does not have access permission to the requested
object, throw an exception and do not proceed.
|
|
Added a variety of functions to the Object base class for testing a
user's access level to another object. Also added functions to test
whether a given user or group is an owner or member of another object.
|
|
|
|
|
|
|
|
Added object function to get the owner of an object. This base-class
function returns a User object, however a user might not always be the
kind of owner (eg: a group can own a pad). In these situations, Object
sub-classes should override this function and return the appropriate
type of object.
|
|
Added object function to get an array of all its members. These will
always be user objects, so this is always a safe function to call.
|
|
Finish initializing the Obj MVC by writing an empty view/action for
groups.
|
|
This MVC will be used to browse scrott datastructures.
|
|
Made the name field (the only field) on this form as required.
|
|
Added handler function to common model to create new use groups from the
modal view.
|
|
This function will initialize a new group object and write it to the
database, with a given group name and owner user.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
These are extra files distributed with Bootstrap that I do not need. I
am keeping the minified Bootstrap main JS file, which is already used by
the Scrott application.
|
|
These are extra files distributed with Bootstrap that I do not need, I
am retaining the minified main Bootstrap CSS file, which is already used
by the Scrott application.
|
|
|
|
|
|
Added handler for the button added in the previous commit.
|
|
Added button for admins to remove any user account
|
|
This action will validate the user's password, and make sure you're not
removing the last admin, then proceed to delete the current user's
account from the database and log them out, for good.
|
|
Function to count the number of admin accounts that exist. This is used
to make sure that while deleteing accounts, the number of administrators
never drops to zero.
|
|
This page prompts for user password before actually deleteing their
account.
|
|
There are two functions that need called in the common model whenever a
page is rendered. Rather than requiring all of the base MVC controllers
to call them, I am placing them in a constructor for this model class.
This constructor should fire automatically (since base mvc models
inherit this class), unless base classes define their own constructors.
I don't antisipate this happening, however in that case, they would just
need to call parent::__construct().
|
|
|
|
This will prompt the user for their password if they opt to delete their
own account. This is to prevent malicious attempt by others to trick
users into having there accounts deleted by way of a XSS attack.
|