2008-08-23 17:53:54

redbot
Plugin Author
upsilon

bot_privs: edit user level privileges

This plugin allows to modify user level privileges with the help of an interface located under the “extensions” tab.
You can choose to hide or show entire admin tabs or sub-tabs for each privilege level defined in the “users” tab (“designer”, “staff writer”, etc.).
Moreover you can set other privileges (all normally hard coded in the “admin_config” file) such as “can edit article” or “can edit own article” or “can edit own published article” and so on.

Ok, nothing special really (even if it was not so easy task for me), all in all it simply avoids to have to hack admin_config.php and it just adds an interface to the existing plugin tame_privs (which does the same thing but is a little raw cos it requires to change plugin’s code by hand). Maybe someone will find it useful.

The plugin creates his own table so it doesn’t mess with anything in the db. It provides also an option to remove the installation table and to reset privs to their default state.

This is my first plugin (and I’m no programmer) so be patient if something does not work. If I have the time I’ll try to add more functionality in the future.

features

  • modify user level privileges through an interface
  • can easily reset privs to default
  • should not interfere at all with other txp tables and functions

Installation
Once the plugin is activated go to extensions=>privileges and click “install” to install the plugin table.

Changes v0.3.2

  • Slight code change. This doesen’t introduce new ‘official’ features but let’s you easily hack the plugin to add new privileges

Changes v0.3.1

  • Fixes a bug with the privileges added by txp 4.2.0

Changes v0.3

  • This version works only with Txp 4.2.0. – for previous versions use v. 0.2.
  • More privileges are added following the changes in admin_config.php
  • I’ve removed the sloppy “can see all articles” feature added by me in v. 0.2. If you need such functionality use this plugin by Variaas instead

download
bot_privs_v0.3.2.txt

Last edited by redbot (2009-11-16 00:27:39)

Offline

 

2008-08-23 18:49:23

graeme
Plugin Author
iota
Real name: Graeme
Website

Re: bot_privs: edit user level privileges

This looks great and will be useful. Cool first plugin.

One request, I would like to define custom privilege levels. Any idea if this will be possible in the future?

Offline

 

2008-08-23 19:36:35

wet
Developer
omega
Real name: Robert
From: Lenzing, Austria
Known languages: de-AT, en, PL/M-80
Website

Re: bot_privs: edit user level privileges

redbot wrote:

P.S. I’m posting here because I don’t seem to be allowed to post in “author support” […]

Well, now you are.

Offline

 

2008-08-23 23:52:59

redbot
Plugin Author
upsilon

Re: bot_privs: edit user level privileges

graeme wrote:

This looks great and will be useful. Cool first plugin.

Thank you very much! But before you speak is better to assure it works as expected (I’ve tried to test it thoroughly but as I said I’m absolutely not an expert).

One request, I would like to define custom privilege levels. Any idea if this will be possible in the future?

I was thinking exactly the same thing.
Maybe a viable first workaround (at least for my limited php skills) could be the capacity to add an infinite number of profiles (overcoming the existing limit of six profiles), which is an indirect way to obtain the same result because if you want to define privileges for author x you can create a new user level that suits your author.
I’m not sure but I think this is doable. As soon as I can (maybe not so soon) I’ll try to see if I manage to do it .

wet wrote:

Well, now you are.

Thank you wet! As soon as someone tries it and reassures me it works I’ll open a new thread (is it ok?)

Offline

 

2008-08-24 07:47:29

jstubbs
Moderator
omega
Real name: Jonathan
From: Hong Kong
Known languages: en-gb, es-es, fr-fr
Website

Re: bot_privs: edit user level privileges

redbot wrote:

Thank you wet! As soon as someone tries it and reassures me it works I’ll open a new thread (is it ok?)

Think you should just move it over now, for tidiness if nothing else.


TXP Tips | @txptips | Me | @jonathanstubbs | Github

TXP Builders – finely-crafted code, design and txp @txpbuilders

Offline

 

2008-08-24 08:20:38

net-carver
Admin
psi
Real name: Steve
From: UK
Known languages: English
Website

Re: bot_privs: edit user level privileges

Redbot

Congratulations on becoming a plugin author! Looking forward to more useful plugins from you :)


Steve
Textile | My plugins on GitHub | @netcarver

Offline

 

2008-08-24 08:46:05

ruud
Developer emeritus
omega
Real name: Ruud van Melick
From: a galaxy far far away
Known languages: li,nl,en,(de)
Website

Re: bot_privs: edit user level privileges

[topic moved to plugin support]

Offline

 

2008-08-24 10:56:27

Zanza
Plugin Author
nu
Website

Re: bot_privs: edit user level privileges

Thanks! I was used to tame_privs, but an easier interface was definitely needed! :)

Z

Offline

 

2008-08-24 11:51:02

redbot
Plugin Author
upsilon

Re: bot_privs: edit user level privileges

net-carver wrote:

Congratulations on becoming a plugin author! Looking forward to more useful plugins from you :)

Thank you very much Steve ;)

Zanza wrote:

Thanks! I was used to tame_privs, but an easier interface was definitely needed! :)

Thanks to you, if it weren’t for you I never knew about tame_privs

ruud wrote:

[topic moved to plugin support]

Thanks!

Offline

 

2008-11-14 20:23:48

pieman
Member
lambda
Real name: Stuart Charlton
From: Bristol, UK
Known languages: Mackem
Website

Re: bot_privs: edit user level privileges

great work, thank you!

Offline

 

Powered by FluxBB