In this article we are going to create Support Module for Admin.
Firstly we are going to create menu for admin then proceed to creating support files.

Demo
Note: Demo is available for Customer Pages Only.
Login details
email 1: cus7(a)gmail.com and pw: anneanne
email 2: cus2(a)gmail.com and pw: tonjetonje
Download page
Creating Support menu for Admin
Open system/application/views/admin/menu.php and add the following just before ul-closing tag at the end.
<?php
$this->load->view($this->config->item('backendpro_template_admin') . 'menu_support');
?>
Here we are loading menu_support.php, so we are going to create next.
system/application/views/admin/menu_support.php
<?php if(check('Customer Support',NULL,FALSE)):?>
<li id="menu_bep_support"><span class="icon_user_green"><?php print $this->lang->line('customer_support')?></span>
<ul>
<?php if(check('Customers Admin',NULL,FALSE)):?><li><?php print anchor('support/admin',$this->lang->line('customer_customers_admin'),array('class'=>'icon_user_orange'))?></li><?php echo "\n"; endif;?>
</ul>
</li>
<?php endif;?>
We are showing only Customer Support and sub-menu Cusotmers Admin as you see the image above.
Creating Resources
You are not able to see the menu yet. You need to create Resources in the back-end.
Login to the back-end and System > Access Control > Resources and click ‘Create Resources’.
Create Customer Support, Purchase Support, Customer Record and Customers Admin as you see in the next image.

Adding jquery calender js and css
Open modules/site/config/bep_assets.php
// Back-end Calendar CSS
$config['asset'][] = array('file'=>'jquery.datepick.css');
// Back-end Calendar JS
$config['asset'][] = array('file'=>'jquery.datepick.pack.js', 'needs'=>'jquery');
$config['asset'][] = array('file'=>'site.js', 'needs'=>'jquery');
And change $config['asset_group']['ADMIN'] to the following.
$config['asset_group']['ADMIN'] = 'bep_admin_layout|bep_admin_style|FlashStatus|forms|buttons|bep_navigation|treeview|bep_icons|bep_select_all|jquery.datepick|jquery.datepick.pack|site';
Download jquery datepicker from here. Unzip it and place jquery.date.pick.css to assets/css folder.
Place jquery.datepick.pack.js in assets/js folder.
Modify jquery.date.pick.css a bit to suit to Bep.
.datepick {
background-color: #fff;
color: #000;
border: 1px solid #444;
border-radius: 0.25em;
-moz-border-radius: 0.25em;
-webkit-border-radius: 0.25em;
font-family: Arial,Helvetica,Sans-serif;
/*font-size: 90%;*/
}
Create assets/js/site.js and copy the following code.
$(document).ready(function(){
//configure the date format to match mysql date
$('#date').datepick({dateFormat: 'yy-mm-dd'});
});
Now you can login to the back-end and see the menu you created as the previous image.
But clicking Customers Admin show nothing. We are going to create next.
Cretaing Support Module

Create modules/support directory and other directories and files as you see on the left image.
Copy and past the following codes.
modules/support/controllers/admin/admin.php
<?php if ( ! defined('BASEPATH')) exit('No direct script access allowed');
class Admin extends Admin_Controller {
function Admin(){
parent::Admin_Controller();
// Check for access permission
check('Customers Admin');
// Load models and language
$this->load->model('MSupport');
$this->load->module_model('auth','User_model');
$this->load->language('customer');
// Set breadcrumb
$this->bep_site->set_crumb($this->lang->line('customer_support_admin'),'support/admin');
}
function index(){
// we use the following variables in the view
$data['title'] = "Customer Page";
// get members details where group = 1 or not 2 from be_users
$id = 1;
$data['support_customers'] = $this->MSupport->getAllMemberProfile($id);
$data['header'] = $this->lang->line('customer_support');
// This how Bep load views
$data['page'] = $this->config->item('backendpro_template_admin') . "admin_support_home";
$data['module'] = 'support';
$this->load->view($this->_container,$data);
}
function customer_record($id= NULL){
$data['title'] = "Customer Record";
$id = $this->uri->segment(4);
$data['customer_records'] = $this->MSupport->getAllCustomerRecord($id);
$totaltime = $this->MSupport-> totalColumn($id,'time');
$totalcredit = $this->MSupport-> totalColumn($id, 'point_credit');
$total = $totalcredit->point_credit - $totaltime->time;
$data['totaltime']= $totaltime->time;
$data['totalcredit']= $totalcredit->point_credit;
$data['total']= $total;
// Get customer name and username to display by using $id which is segment 4
$data['customer_details']= $this->MSupport->getSingleMemberProfile($id);
$data['header'] = $this->lang->line('customer_record');
// Set breadcrumb
$this->bep_site->set_crumb($this->lang->line('customer_support_customer'),'support/admin/customer');
// This how Bep load views
$data['page'] = $this->config->item('backendpro_template_admin') . "admin_customer_home";
$data['module'] = 'support';
$this->load->view($this->_container,$data);
}
function enter_newcredit($id=0){
$data['title'] = "Enter Credit";
$data['header'] = $this->lang->line('customer_enter_credit');
// Set breadcrumb
$this->bep_site->set_crumb($this->lang->line('customer_enter_credit'),'support/admin/newcredit');
$data['id'] = $this->uri->segment(4);
if ($this->input->post('point_credit')){
$id = $this->input->post('id');
// fields filled up so,
$this->MSupport->enter_credit();
// CI way to set flashdata, but we are not using it
// $this->session->set_flashdata('message','Product updated');
// we are using Bep function for flash msg
flashMsg('success','Credit entered');
redirect('support/admin/customer_record/'.$id,'refresh');
}else{
// pull admin for 'by' dropdown field
// where group = 2 from be_users table
$member_id = 2;
$data['administrators'] = $this->MSupport->getMembersDropDown($member_id);
$data['page'] = $this->config->item('backendpro_template_admin') . "admin_enter_credit";
// This how Bep load views
$data['module'] = 'support';
$this->load->view($this->_container,$data);
}
}
function enter_workdone(){
$data['title'] = "Enter Work Done";
$data['header'] = $this->lang->line('customer_work_done');
// Set breadcrumb
$this->bep_site->set_crumb($this->lang->line('customer_work_done'),'support/admin/workdone');
$data['id'] = $this->uri->segment(4);
if ($this->input->post('date')){
$id = $this->input->post('id');
// fields filled up so,
$this->MSupport->enter_workdone();
// CI way to set flashdata, but we are not using it
// $this->session->set_flashdata('message','Product updated');
// we are using Bep function for flash msg
flashMsg('success','Work Done Entered');
redirect('support/admin/customer_record/'.$id,'refresh');
}else{
// pull admin for 'by' dropdown field
// where group = 2 from be_users table
$member_id = 2;
$data['administrators'] = $this->MSupport->getMembersDropDown($member_id);
$data['page'] = $this->config->item('backendpro_template_admin') . "admin_work_done";
// This how Bep load views
$data['module'] = 'support';
$this->load->view($this->_container,$data);
}
}
function update_record(){
$id = $this->uri->segment(4);
// if you are using TinyMCE here, load it.
// $this->bep_assets->load_asset_group('TINYMCE');
if ($this->input->post('date')){
$customer_id = $this->input->post('customer_id');
// info is filled out, do the followings
$this->MSupport->updateRecord($id);
// This is CI way to show flashdata
// $this->session->set_flashdata('message','Page updated');
// But here we use Bep way to display flash msg
flashMsg('success','Customer updated');
redirect('support/admin/customer_record/'.$customer_id,'refresh');
}else{
$data['title'] = "Update Record";
$data['page'] = $this->config->item('backendpro_template_admin') . "admin_edit_record";
$data['records'] = $this->MSupport->getRecord($id);
// pull admin for 'by' dropdown field
// where group = 2 from be_users table
$member_id = 2;
$data['administrators'] = $this->MSupport->getMembersDropDown($member_id);
//Pull user_names from be_users
// need to get user name and use them with dropdown to choose it
// this will be used in customersupport module to display customer's own support records
//$data['members'] = $this->user_model->getUsers();// not working at the moment
if (!count($data['records'])){
// if page is not specified redirect to index
redirect('support/admin/','refresh');
}
// $data['menus'] = $this->MMenus->getAllMenusDisplay();
// Set breadcrumb
$this->bep_site->set_crumb($this->lang->line('customer_support_admin_edit'),'support/admin/update_record');
$data['header'] = $this->lang->line('customer_edit_record');
$data['module'] = 'support';
$this->load->view($this->_container,$data);
}
}
function delete_record($id = NULL){
$customer_id = $this->uri->segment(4);
$id = $this->uri->segment(5);
$this->MSupport->deleteRecord($id);
flashMsg('success','Record deleted');
redirect('support/admin/customer_record/'.$customer_id,'refresh');
}
function supportDisplay(){
}
function details($id){
// we use the following variables in the view
$data['title'] = "Support Details";
$data['header'] = "Support Details" ;
$data['username']=$this->session->userdata('username');
$username = $this->session->userdata('username');
$id = $this->uri->segment(4);
$this->load->module_model('customersupport','MCustomer_support');
$data['details']= $this->MCustomer_support->admingetRecordDetails($id);
// Set breadcrumb
$this->bep_site->set_crumb('Details','customersupport/admin/details');
// This how Bep load views
$data['page'] = $this->config->item('backendpro_template_admin') . "details";
$data['module'] = 'customersupport';
$this->load->view($this->_container,$data);
}
}//end class
?>
modules/support/models/msupport.php
<?php if ( ! defined('BASEPATH')) exit('No direct script access allowed');
class MSupport extends Base_model{
function MSupport(){
parent::Base_model();
$this->_TABLES = array( 'support_details' => 'support_details'
);
}
function getCustomer($id){
$data = array();
$Q = $this->fetch('be_users','*',1,array('id'=>$id));
if ($Q->num_rows() > 0){
$data = $Q->row_array();
}
$Q->free_result();
return $data;
}
function getAllCustomerRecord($id){
$data = array();
$this->db->where('customer_id', $id);
$Q = $this->db->get('support_details');
if ($Q->num_rows() > 0){
foreach ($Q->result_array() as $row){
$data[] = $row;
}
}
$Q->free_result();
return $data;
}
function totalColumn($id, $column){
$data = array();
$this->db->select_sum($column);
$this->db->where('customer_id', $id);
$Q = $this->db->get('support_details');
if ($Q->num_rows() > 0){
$data = $Q->row();
}
$Q->free_result();
return $data;
}
function enter_credit(){
$data = array(
'customer_id' => $this->input->post('id'),
'date' => $this->input->post('date'),
'point_credit' => $this->input->post('point_credit'),
'note' => $this->input->post('note'),
'by' => $this->input->post('by'),
);
$this->insert('support_details',$data);
}
function enter_workdone(){
$data = array(
'customer_id' => $this->input->post('id'),
'date' => $this->input->post('date'),
'time' => $this->input->post('time'),
'note' => $this->input->post('note'),
'details' => $this->input->post('details'),
'by' => $this->input->post('by'),
);
$this->insert('support_details',$data);
}
function getMembers($id){
// admin id is 2 and member id is 1
$data = array();
$this->db->select('id,username');
$this->db->where('group', $id);
$Q = $this->db->get('be_users');
if ($Q->num_rows() > 0){
foreach ($Q->result_array() as $row){
$data[]=$row;
}
}
$Q->free_result();
return $data;
}
function getAllMemberProfile($id=NULL){
$data = array();
$this->db->select('*');
$this->db->from('be_user_profiles');
$this->db->join('be_users', 'be_users.id = be_user_profiles.user_id');
$this->db->where('be_users.group', $id);
$query = $this->db->get();
if ($query->num_rows() > 0){
foreach ($query->result_array() as $row){
$data[]=$row;
}
}
$query->free_result();
return $data;
}
function getSingleMemberProfile($id=NULL){
$data = array();
$this->db->select('*');
$this->db->from('be_user_profiles');
$this->db->join('be_users', 'be_users.id = be_user_profiles.user_id');
$this->db->where('be_user_profiles.user_id', $id);
$query = $this->db->get();
if ($query->num_rows() > 0){
foreach ($query->result_array() as $row){
$data[]=$row;
}
}
$query->free_result();
return $data;
}
function getMembersDropDown($id){
// admin id is 2 and member id is 1
$data = array();
$this->db->select('id,username');
$this->db->where('group', $id);
$Q = $this->db->get('be_users');
if ($Q->num_rows() > 0){
foreach ($Q->result_array() as $row){
$data[$row['username']] = $row['username'];
}
}
$Q->free_result();
return $data;
}
// not used delete
function getAdminsDropDown(){
$data = array();
$admin= 2;
$this->db->select('id,username');
$this->db->where('group', $admin);
$Q = $this->db->get('be_users');
if ($Q->num_rows() > 0){
foreach ($Q->result_array() as $row){
$data[$row['username']] = $row['username'];
}
}
$Q->free_result();
return $data;
}
function getRecord($id){
$data = array();
$Q = $this->fetch('support_details',NULL ,NULL ,array('id'=>$id));
if ($Q->num_rows() > 0){
$data = $Q->row_array();
}
$Q->free_result();
return $data;
}
function updateRecord($id){
$data = array(
'date' => $this->input->post('date'),
'time' => $this->input->post('time'),
'point_credit' => $this->input->post('point_credit'),
'note' => $this->input->post('note'),
'details' => $this->input->post('details'),
'by' => $this->input->post('by'),
);
$id = $this->input->post('id');
$this->update('support_details',$data,array('id'=>$id));
}
function deleteRecord($id){
$this->delete('support_details',array('id'=>$id));
}
}
modules/support/views/admin/admin_create_customers.php
<h2><?php echo $title;?></h2>
<div id="create_edit">
<?php
echo form_open('support/admin/create_customer');
echo "\n<p><label for='username'>User Name</label><br/>\n";
/*
foreach ($members->result_array() as $row){
$options[$row['username']] = $row['username'];
}
*/
echo form_dropdown('username',$members) ."</p>\n";
echo "\n<p><label for='comname'>Company Name</label><br/>\n";
$data = array('name'=>'company_name','id'=>'comname','size'=>40);
echo form_input($data) ."</p>\n";
echo "<p><label for='customer_name'>Cutomer Name</label><br/>\n";
$data = array('name'=>'customer_name','id'=>'customer_name','size'=>40);
echo form_input($data) ."</p>\n";
echo "<p><label for='web_address'>Web Address</label><br/>\n";
$data = array('name'=>'web_address','id'=>'web_address','size'=>40);
echo form_input($data) ."</p>\n";
echo "<p><label for='password'>Password for website</label><br/>\n";
$data = array('name'=>'password','id'=>'password','size'=>40);
echo form_input($data) ."</p>\n";
echo "<p><label for='phone'>Phone</label><br/>\n";
$data = array('name'=>'phone_number','id'=>'phone','size'=>40);
echo form_input($data) ."</p>\n";
echo "<p><label for='email'>email</label><br/>\n";
$data = array('name'=>'email','id'=>'email','size'=>40);
echo form_input($data) ."</p>\n";
echo "<p><label for='address'>Address</label><br/>\n";
$data = array('name'=>'address','id'=>'address','size'=>100);
echo form_input($data) ."</p>\n";
echo "<p><label for='city'>City</label><br/>\n";
$data = array('name'=>'city','id'=>'city','size'=>40);
echo form_input($data) ."</p>\n";
echo "<p><label for='postcode'>Postcode</label><br/>\n";
$data = array('name'=>'postcode','id'=>'postcode','size'=>10);
echo form_input($data) ."</p>\n";
echo "<p><label for='status'>Status</label><br/>\n";
$options = array('active' => 'active', 'inactive' => 'inactive');
echo form_dropdown('status',$options) ."</p>\n";
echo form_submit('submit','Create Customer');
echo form_close();
?>
</div>
modules/support/views/admin/admin_customer_home.php
<?php print displayStatus();?>
<h2><?php echo $title;?></h2>
<?php
foreach ($customer_details as $detail){
echo "<p>";
echo anchor("support/admin/enter_newcredit/".$detail['user_id'], "Enter New Credits");
echo "<br />";
echo anchor("support/admin/enter_workdone/".$detail['user_id'], "Enter Work Done");
echo "<br /></p>";
/* Display the customer details */
echo "<h4>Company Name: ".$detail['company_name']."</h4>";
echo "<h4>Customer Name: ".$detail['full_name']."</h4>";
echo "<h4>Web Address: ".$detail['web_address']."</h4>";
echo "+++++++++++++++++++++++";
}
/*
This is how CI display flash data. but we don't use it.
if ($this->session->flashdata('message')){
echo "<div class='status_box'>".$this->session->flashdata('message')."</div>";
}
*/
echo "<h4>Total time spent: ".$totaltime."</h4>";
echo "<h4>Total credit purchased: ".$totalcredit."</h4>";
echo "<h4>Total Points/Time Left: ".$total."</h4>";
echo "<h4>Support Details</h4>";
// print_r ($customer_records);
if (count($customer_records)){
echo "<table id='tablesorter' class='tablesorter' border='1' cellspacing='0' cellpadding='3' width='100%'>\n";
echo "<thead>\n<tr valign='top'>\n";
echo "<th>By</th>\n<th>Date</th><th>Time</th><th>Point Credit</th><th>Note</th><th>Details</th><th>Action</th>\n";
echo "</tr>\n</thead>\n<tbody>\n";
foreach ($customer_records as $list){
// print_r ($total);
echo "<tr valign='top'>\n";
echo "<td align='center'>".$list['by']."</td>\n";
echo "<td>".$list['date']."</td>\n";
echo "<td>".$list['time']. "</td>";
echo "<td>".$list['point_credit']. "</td>";
echo "<td>".$list['note']. "</td>";
echo "<td>";
echo anchor('support/admin/details/'.$list['id'],'Details');
echo "</td>";
echo "<td>";
echo anchor('support/admin/update_record/'.$list['id'],'edit');
echo " | ";
foreach ($customer_details as $detail)
echo anchor('support/admin/delete_record/'.$detail['user_id']."/".$list['id'],'delete');
echo "</td>\n";
echo "</tr>\n";
}
echo "</tbody>\n</table>";
}
?>
modules/support/views/admin/admin_edit_customer.php
<?php print displayStatus();?>
<h2><?php echo $title;?></h2>
<div id="create_edit">
<?php
echo form_open('support/admin/edit_customer');
echo "\n<p><label for='username'>User Name</label><br/>\n";
foreach ($members->result_array() as $row){
$options[$row['username']] = $row['username'];
}
echo form_dropdown('username',$options, $customerdetails['username']) ."</p>\n";
echo "\n<p><label for='comname'>Company Name</label><br/>\n";
$data = array('name'=>'company_name','id'=>'comname','size'=>40, 'value' => $customerdetails['company_name']);
echo form_input($data) ."</p>\n";
echo "<p><label for='customer_name'>Cutomer Name</label><br/>\n";
$data = array('name'=>'customer_name','id'=>'customer_name','size'=>40, 'value' => $customerdetails['customer_name']);
echo form_input($data) ."</p>\n";
echo "<p><label for='web_address'>Web Address</label><br/>\n";
$data = array('name'=>'web_address','id'=>'web_address','size'=>40, 'value' => $customerdetails['web_address']);
echo form_input($data) ."</p>\n";
echo "<p><label for='password'>Password for website</label><br/>\n";
$data = array('name'=>'password','id'=>'password','size'=>40, 'value' => $customerdetails['password']);
echo form_input($data) ."</p>\n";
echo "<p><label for='phone'>Phone</label><br/>\n";
$data = array('name'=>'phone_number','id'=>'phone','size'=>40, 'value' => $customerdetails['phone_number']);
echo form_input($data) ."</p>\n";
echo "<p><label for='email'>email</label><br/>\n";
$data = array('name'=>'email','id'=>'email','size'=>40, 'value' => $customerdetails['email']);
echo form_input($data) ."</p>\n";
echo "<p><label for='address'>Address</label><br/>\n";
$data = array('name'=>'address','id'=>'address','size'=>100, 'value' => $customerdetails['address']);
echo form_input($data) ."</p>\n";
echo "<p><label for='city'>City</label><br/>\n";
$data = array('name'=>'city','id'=>'city','size'=>40, 'value' => $customerdetails['city']);
echo form_input($data) ."</p>\n";
echo "<p><label for='post_code'>Postcode</label><br/>\n";
$data = array('name'=>'post_code','id'=>'postcode','size'=>10, 'value' => $customerdetails['post_code']);
echo form_input($data) ."</p>\n";
echo "<p><label for='status'>Status</label><br/>\n";
$options = array('active' => 'active', 'inactive' => 'inactive');
echo form_dropdown('status',$options, $customerdetails['status']) ."</p>\n";
echo form_hidden('id',$customerdetails['id']);
echo form_submit('submit','Update Customer');
echo form_close();
?>
</div>
modules/support/views/admin/admin_edit_record.php
<?php print displayStatus();?>
<h2><?php echo $title;?></h2>
<div id="editrecord">
<?php
echo form_open('support/admin/update_record');
echo "\n<p><label for='date'>Date</label><br/>\n";
$data = array('name'=>'date','id'=>'date','size'=>40, 'value' => $records['date']);
echo form_input($data) ."</p>\n";
echo "<p><label for='time'>Time</label><br/>\n";
$data = array('name'=>'time','id'=>'time','size'=>40, 'value' => $records['time']);
echo form_input($data) ."</p>\n";
echo "<p><label for='point_credit'>Point Credit</label><br/>\n";
$data = array('name'=>'point_credit','id'=>'point_credit','size'=>40, 'value' => $records['point_credit']);
echo form_input($data) ."</p>\n";
echo "<p><label for='note'>Note</label><br/>\n";
$data = array('name'=>'note','id'=>'note', 'value' => $records['note']);
echo form_textarea($data) ."</p>\n";
echo "<p><label for='details'>Details</label><br/>\n";
$data = array('name'=>'details','id'=>'details', 'value' => $records['details']);
echo form_textarea($data) ."</p>\n";
echo "<p><label for='by'>By</label><br/>\n";
echo form_dropdown('by',$administrators,$records['by']) ."</p>\n";
echo form_hidden('id',$records['id']);
echo form_hidden('customer_id',$records['customer_id']);
echo form_submit('submit','Update Record');
echo form_close();
?>
</div>
modules/support/views/admin/admin_enter_credit.php
<?php print displayStatus();?>
<h2><?php echo $title;?></h2>
<?php
echo form_open('support/admin/enter_newcredit/');
echo "\n<p><label for='date'>Date</label><br/>\n";
$data = array('name'=>'date','id'=>'date','size'=>40);
echo form_input($data) ."</p>\n";
echo "<p><label for='point_credit'>Point Credit</label><br/>\n";
$data = array('name'=>'point_credit','id'=>'point_credit','size'=>40);
echo form_input($data) ."</p>\n";
echo "<p><label for='note'>Note</label><br/>\n";
$data = array('name'=>'note','id'=>'note');
echo form_textarea($data) ."</p>\n";
echo "\n<p><label for='by'>By</label><br/>\n";
echo form_dropdown('by',$administrators) ."</p>\n";
echo form_hidden('id',$id);
echo form_submit('submit','Enter Credit');
echo form_close();
?>
modules/support/views/admin/admin_support_home.php
<?php print displayStatus();?>
<h2><?php echo $title;?></h2>
<p>
<?php
echo anchor("auth/admin/members/form", "Create new customer");
?>
</p>
<?php
/*
This is how CI display flash data. but we don't use it.
if ($this->session->flashdata('message')){
echo "<div class='status_box'>".$this->session->flashdata('message')."</div>";
}
*/
if (count($support_customers)){
echo "<table id='tablesorter' class='tablesorter' border='1' cellspacing='0' cellpadding='3' width='100%'>\n";
echo "<thead>\n<tr valign='top'>\n";
echo "<th>ID</th>\n<th>Company Name</th><th>Customer Name</th><th>User Name</th><th>Web Address</th><th class='middle'>Active</th><th>Actions</th>\n";
echo "</tr>\n</thead>\n<tbody>\n";
foreach ($support_customers as $key => $list){
echo "<tr valign='top'>\n";
echo "<td align='center'>".$list['id']."</td>\n";
echo "<td><a href=\"admin/customer_record/".$list['id']."\">".$list['company_name']."</a></td>\n";
echo "<td>".$list['full_name']. "</td>";
echo "<td>".$list['username']. "</td>";
echo "<td><a href=\"".$list['web_address']."\" target=\"_blank\">".$list['web_address']."</a></td>\n";
$active = ($list['active']?'tick':'cross');
echo '<td class="middle">'.$this->bep_assets->icon($active)."</td>";
echo "<td>";
echo anchor('auth/admin/members/form/'.$list['id'],'edit');
echo "</td>\n";
echo "</tr>\n";
}
echo "</tbody>\n</table>";
}
modules/support/views/admin/admin_work_done.php
<?php print displayStatus();?>
<h2><?php echo $title;?></h2>
<?php
echo form_open('support/admin/enter_workdone/');
echo "\n<p><label for='date'>Date</label><br/>\n";
$data = array('name'=>'date','id'=>'date','size'=>40);
echo form_input($data) ."</p>\n";
echo "<p><label for='time'>Time</label><br/>\n";
$data = array('name'=>'time','id'=>'time','size'=>40);
echo form_input($data) ."</p>\n";
echo "<p><label for='note'>Note</label><br/>\n";
$data = array('name'=>'note','id'=>'note');
echo form_textarea($data) ."</p>\n";
echo "<p><label for='details'>Details</label><br/>\n";
$data = array('name'=>'details','id'=>'details');
echo form_textarea($data) ."</p>\n";
echo "\n<p><label for='by'>By</label><br/>\n";
echo form_dropdown('by',$administrators) ."</p>\n";
echo form_hidden('id',$id);
echo form_submit('submit','Enter Work Done');
echo form_close();
?>
By this time you can see the Customers Admin page. However since we have not added profiles yet, we are not able to create customers.
In the next article we are going to add profiles.


















