swarooppatilx / scruter

Scruter is a local classifieds and community site designed to bring people together for buying, selling, and exchanging goods and services.
https://scruter.vercel.app
GNU General Public License v3.0
28 stars 135 forks source link

Implement Admin Functionality #518

Open ShivanshPlays opened 2 weeks ago

ShivanshPlays commented 2 weeks ago

Description

Issue: Implement Admin Functionality

Description

This issue focuses on implementing the super admin functionality for the website. The goal is to establish a robust backend infrastructure that enables admin users to manage the platform effectively, ensuring better control and oversight over vendor and customer activities.

PR1: #528

  1. Admin Role:

    • Introduce a super admin role within the user management system to distinguish super admins from regular admins and vendors.
    • This role will have elevated privileges to perform various management tasks across the platform.
  2. Login Functionality Page:

    • Implement a secure login mechanism for super admins to access the admin panel.
    • Ensure proper authentication and authorization checks are in place to protect sensitive operations.
  3. Backend Schema Updates:

    • Update the existing database schema to accommodate the new super admin role.
    • This may involve modifications to the user table to include role-based access control.

PR2: Admin Login with OTP Implementation #529

  1. Add OTP Form: Implement an OTP input form for admin authentication after initial login.
  2. Backend Logic:
    • Create an endpoint to verify admin credentials.
    • Upon successful verification, trigger the OTP form and send an OTP to the admin's email.
  3. Send and Verify OTP:
    • Implement logic to send OTP via email after admin login.
    • Verify OTP submitted by the admin and allow access only if the OTP is correct.

PR3: #546

add admin dashboard page will proper styling and responsiveness

PR4:

modify middleware to protect the admin route from trespassers

PR5:

implement serveractions and API, and connect them to the frontend for dynamic data fetching

PR6:

Add forum overview in which admin can perform read and delete forum

ShivanshPlays commented 1 week ago

@swarooppatilx the full implementation is not completed, please don't close the issue

swarooppatilx commented 1 week ago

@ShivanshPlays yes

ShivanshPlays commented 1 week ago

Yes please reopen the issue so that it is visible to all contributors