Skip to content

laxswami/DataBased

Repository files navigation

🗄️ Databased

A Self-Hosted Database Application Platform
Built with CodeIgniter 2.1.4 and Flat UI Pro

CodeIgniter Version PHP Requirement License MySQL


🔖 Introduction

Databased is a self-hosted database application, allowing access to MySQL databases for both non-technical and technical users.

It’s not (yet) a replacement for phpMyAdmin or advanced MySQL administration tools — instead, it focuses on making MySQL management accessible to regular users such as sales teams, customer service, and accountants.

Built using CodeIgniter 2.1.4 and Flat UI Pro, Databased combines simplicity with a polished user interface.


⚙️ Before Installing

🧩 Requirements

To install Databased, ensure you have:

  • PHP 5.1.6 (older versions might work)
  • Apache webserver
  • MySQL (with InnoDB and foreign key support)
  • Root access to your MySQL server
  • phpMyAdmin for initial setup
  • FTP tool for uploading files

🧱 Structure Overview

Databased is built on CodeIgniter and Flat UI Pro.

📂 Custom Application Files

Controllers (/application/controllers/):

account.php, admin.php, columnnotes.php, columns.php, dashboard.php, db.php,
recordnotes.php, revisions.php, roles.php, table_datasource.php, tablenotes.php, users.php

Models (/application/models/):

columnnote_model.php, db_model.php, issue_model.php, recordnote_model.php,
relation_model.php, revision_model.php, role_model.php, table_model.php,
tablenote_model.php, user_model.php

Views (/application/views/): All files are custom except /application/views/auth.

🎨 Flat UI Pro Folders

/bootstrap   → Core Bootstrap elements  
/css         → Custom CSS  
/custom      → LESS + CSS  
/fonts       → Fonts used in Databased  
/images      → Application images  
/js          → Flat UI Pro JavaScript  
/less        → Original LESS files  

📦 Additional Directories

/assets  → jQuery plugins and support files  
/swf     → Files used by jQuery DataTables plugin  

💡 Before installing, ensure your hosting supports CodeIgniter 2.1.4 (99% of hosts do).


🪼 Installation Guide

Step 1: Upload Files

Upload or extract Databased.zip to your web hosting (root or subfolder). Verify that .htaccess is present in the target folder.

Step 2: Setup MySQL Database

  1. Create a new MySQL database via phpMyAdmin.
  2. Import Databased.sql from the application folder.
  3. Do not modify the created tables.

Step 3: Configuration

Edit these files via FTP:

/application/config/config.php

  • Update support email:

    $config['support_email'] = 'support@somedomain.com';
  • Set encryption key:

    $config['encryption_key'] = 'SecretKeyGoesHere';
  • Optional: Remove index.php from URLs by editing $config['index_page'].

/application/config/database.php

Enter your database credentials here. 🔙 Use a MySQL user with root access.

🔐 First Login

Default credentials:

Username: admin@admin.com
Password: password

⚠️ Change these immediately after login.


🚀 Features

🗃 Databases

  • Manage or create MySQL databases.
  • Enable or disable databases from the interface.
  • Only admin users can manage databases.
  • Green circle = supported, Red = not compatible.

📋 Tables

  • Access restricted by user role.
  • Admin users can manage permissions for each table.
  • Non-admin users can share or keep tables private.

🔒 Private Records

Define private tables per role — users only see their own records.

🧡 Columns

Supported types:

  • Numbers (up to 11 digits)
  • Text (small/big)
  • Date
  • Select dropdowns
  • Files and images (upload via advanced editor)

🔗 Connections

Link columns between tables for relational data. E.g., connect customers.customerBookbooks.books_title.

⚖️ Restrictions

Validation rules supported:

Rule Description Example
required Field cannot be empty
min_length Must be ≥ X characters min_length[6]
max_length Must be ≤ X characters max_length[12]
exact_length Must be exactly X characters exact_length[8]
greater_than Must be greater than X greater_than[8]
less_than Must be less than X less_than[8]
alpha Alphabetic only
alpha_numeric Alphanumeric only
alpha_dash Letters, numbers, dash, underscore
numeric Numbers only
integer Whole numbers
is_natural 0,1,2,3,…
is_natural_no_zero 1,2,3,…
valid_email Valid email format
valid_emails Comma-separated valid emails
valid_ip Valid IPv4/IPv6 address

📥 Importing Data

Supports CSV file imports (Excel → export as CSV first).

New Table Import

  • Use the green ➕ button at the bottom-left.
  • Select Import Data tab.
  • Enter table name and upload CSV file.
  • Optionally tick “First row contains column names”.

Existing Table Import

  • Open the table → click Import Data.
  • Upload CSV matching the table structure.
  • Adjust delimiter/enclosure only if needed.

👥 Roles, Users & Permissions

  • Define user roles (e.g., Sales, Support, Accounting).
  • Each user is mapped to a MySQL user.
  • Permissions apply per database and table.
  • Admins can manage users, roles, and reset passwords.
  • Built-in password recovery system.

⚠️ Do not delete or modify the “Administrator” role (ID = 1).


🕚 Revisions

  • Auto-saves old values of cells and records.
  • Restore any previous version anytime.
  • No auto-expiry (manual cleanup available).

🔗 Relational Data

  • Connect columns across tables (foreign keys).
  • Works only with InnoDB tables.
  • Admin permissions required for setup.
  • Once configured, linked columns show dropdowns.

📝 Notes System

Attach notes to:

  • Columns
  • Tables
  • Databases

All users can add notes. Admins can edit or delete any note.


❓ How Do I...?

✅ Enable Existing Database

  1. Login as Admin
  2. Go to Database → Manage Databases
  3. Find your database → ensure GREEN circle
  4. Check “Enable database in Databased”

🆕 Create New Database

  1. Login as Admin
  2. Database → Manage Databases → Create Database
  3. Enter name, tick “Enable in Databased”
  4. Click “Create database”

➕ Add a Table

  1. Login with table-modify permissions
  2. Click green ➕ button (bottom left)
  3. Enter table name and columns
  4. Click Add Table

🧩 Setup Foreign Key

  1. Login with modify permissions
  2. Go to Database → Table → Columns
  3. Edit column → choose “Connect to”
  4. Select table/column → click Update column

👁 Customize Data View

  1. Database → Table → Columns
  2. Use checkboxes to toggle visibility
  3. Click Reload Data View

✏️ Rename Table

  1. Database → Table → More
  2. Update table name → click Update Table

👤 Change User Details

  1. Login as Admin
  2. Go to Users → Select User
  3. Edit info → click Update

🔒 Change User Permissions

  1. Roles & Permissions → Select Role
  2. Adjust access levels → click Save Permissions

📤 Export Data

Browser must have Flash installed.

  1. Open database & table
  2. Use filters
  3. Click CSV / Excel / PDF button

🧠 Databased — Simplifying Database Management for Everyone.
Built with ❤️ using CodeIgniter and Flat UI Pro.

About

Databased is a self-hosted Database Application or A "Database Application Platform"

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors