thankyou
Donate to the B3 fund!

"even a small donation helps!"
Donate with PayPal!
Echelon v2 is not yet officially released! If you cannot get this dev-version installed, revert to version 1 as available in our download section.

Author Topic: Level Permissions in Echelon  (Read 3983 times)

Offline Glock

  • Sr. Member
  • ****
  • Posts: 172
  • Running B3 on 4 busy BF3 servers myself! B3 FTW!
Level Permissions in Echelon
« on: June 09, 2013, 12:14:40 PM »
Hi,

Is there a way to manage what the 3 levels do in Echelon?
1, Superadmin should stay the same of course..

But as with the user accounts page I need to limit what mods can do with user levels in the databases.

I've tried and actually ending up reversing the permissions so the moderator then became the super admin..
Here's what I need to do;

I need to prevent admins and or mods from being able to adjust user permissions or user levels.
Now, I'm not on about Echelon account levels, but player levels from the game.
ANY mod right now can login, use the drop down menu on a selected player and can actually put him in the superadmin group! a moderator can do this..

Is there a way to change it please?
This is pretty urgent and I would appreciate a head's up

Like I said, I've done some things but reversed the permissions, what I need is to be able to disable the drop down menu;
Level   ID Level   >
On a user basis - superadmins or '1' fine, levels 2 + 3 should be unable to change levels.
Thanks a lot
Need B3 Bot Hosting for your gameservers in the UK & Europe?
Take a look at Rcon-Admin.com
Cheap + reliable B3 Bot hosting in the UK and Europe

Offline Glock

  • Sr. Member
  • ****
  • Posts: 172
  • Running B3 on 4 busy BF3 servers myself! B3 FTW!
Re: Level Permissions in Echelon
« Reply #1 on: June 14, 2013, 09:01:35 PM »
fixed.

Need B3 Bot Hosting for your gameservers in the UK & Europe?
Take a look at Rcon-Admin.com
Cheap + reliable B3 Bot hosting in the UK and Europe

Offline wally

  • Jr. Member
  • **
  • Posts: 35
Re: Level Permissions in Echelon
« Reply #2 on: March 04, 2014, 04:49:56 AM »
Hi Glock,

I'm having the same issue in Echelon v1.  How were you able to fix it?

And Glock hasn't been on the forum for 2 months.  If anyone knows the answer, please point me in the right direction.  Many thanks!

Offline 82ndAB.Bravo17

  • Dev. Team
  • Hero Member
  • *
  • Posts: 2628
Re: Level Permissions in Echelon
« Reply #3 on: March 04, 2014, 06:15:21 AM »
Take a look at the version in my git repo

[email protected]:82ndab-Bravo17/echelon.git

Offline wally

  • Jr. Member
  • **
  • Posts: 35
Re: Level Permissions in Echelon
« Reply #4 on: March 04, 2014, 10:17:29 PM »
Thanks!  I added your echelon files and now it seems to work almost the way I want it to.

The only thing missing is the ban button isn't showing up for level 2's, only tempban.  Is it possible to give lvl 2's access to the ban button?

Offline 82ndAB.Bravo17

  • Dev. Team
  • Hero Member
  • *
  • Posts: 2628
Re: Level Permissions in Echelon
« Reply #5 on: March 04, 2014, 10:38:41 PM »
That is by design. If you want to change it, I think it is in clientdetails.php.

Offline wally

  • Jr. Member
  • **
  • Posts: 35
Re: Level Permissions in Echelon
« Reply #6 on: March 06, 2014, 04:09:56 AM »
Thank you.  I think I'm making the changes to the correct code, see below.


These are your defaults:
Code: [Select]
	  </td>

 <td class="tabelkop" align="right">
  Banning
 </td>
 <td>
 <?php
 if ($_SESSION['xlradminlevel'] <= 2)
 {
 ?>
 <form name="tempbaninput" method="Post" Action="admin/tempban.php?id=<?php echo $row_rs_clientinfo['id']; ?>&pbid=<?php echo $row_rs_clientinfo['pbid']; ?>&clientname=<?php echo urlencode($row_rs_clientinfo['name']); ?>&client_ip=<?php echo $row_rs_clientinfo['ip']; ?>&game=<?php echo $game;?>">
      <input type="text" value="Banned by an Echelon WebAdmin" size="50" Maxlength="50" Name="reason">
     <input type="text" value="Number" size="9" Maxlength="9" Name="bantime">
     <SELECT name="time">
       <option>Minutes</option>
       <option>Hours</option>
       <option>Days</option>          
     </select>
      <input type="submit" name="submit2" value="tempban" class="button">
      </form>
 <?php
 }
 if ($_SESSION['xlradminlevel'] == 1)
 {
 ?>
 <form name="baninput" method="Post" Action="admin/ban.php?id=<?php echo $row_rs_clientinfo['id']; ?>&pbid=<?php echo $row_rs_clientinfo['pbid']; ?>&clientname=<?php echo urlencode($row_rs_clientinfo['name']); ?>&client_ip=<?php echo $row_rs_clientinfo['ip']; ?>&game=<?php echo $game;?>">
      <input type="text" value="Banned by an Echelon WebAdmin" size="50" Maxlength="50" Name="reason">
      <input type="submit" value="permban" class="button" style="background: #B9A489 url(img/insta_ban.gif) no-repeat top left; padding-left:15px">
      </form>
 <?php
 }
 ?>
 </td>

I changed    the second  if ($_SESSION['xlradminlevel'] == 1)  to    if ($_SESSION['xlradminlevel'] <= 2) and now level 2's are able to see the permban button.  However, whenever they try to ban, it redirects them to the index page with these options:
Admin login:
 
Hey test. You are already logged in!
Move on to the repository and start using Echelon
go to your available admintools
or logout by clicking here.


Any suggestions?

Offline 82ndAB.Bravo17

  • Dev. Team
  • Hero Member
  • *
  • Posts: 2628
Re: Level Permissions in Echelon
« Reply #7 on: March 06, 2014, 06:44:05 AM »
look at the requiredlevel in admin/ban.php

Offline wally

  • Jr. Member
  • **
  • Posts: 35
Re: Level Permissions in Echelon
« Reply #8 on: March 10, 2014, 02:37:15 AM »
That did the trick.  Many thanks!   ;D

 


Rate this page +1 at Google Search