View file File name : Enquiries_list.php Content :<div class="container-fluid"> <div class="col-md-12 content-center"> <div class="card-plain"> <h2 CLASS="text-center">MANAGE ENQUIRIES</h2> <table id="myTable" class="table-bordered"> <thead> <tr> <th>Sr No</th> <th>Project Code</th> <th>Name</th> <th>Email</th> <th>Contact</th> <th>Comment</th> <th>Date</th> <th>Status</th> <th>Remark</th> <th>Next Action Date</th> <th>Total Logs</th> <th>Action</th> <th></th> <th></th> </tr> </thead> <tbody> <?php $count=0; foreach($test as $dt){ $count+=1; ?> <tr> <td><?=$count?></td> <td><a href="https://dhcprop.com/properties/details/<?=$dt->project_id?>" target="_blank"><?=$dt->project_code?></a></td> <td><?=$dt->name?></td> <td><?=$dt->email?></td> <td><?=$dt->contact?></td> <td><?=$dt->comment?></td> <td><?=$dt->date?></td> <td style="border-radius:10px;padding:5px;background:<?php if($dt->status=="PENDING") echo "lightblue"; else if($dt->status=="CALLBACK") echo "yellow"; else if($dt->status=="CONVERSION") echo "green"; else echo "red"; ?>;color:<?php if($dt->status=="CONVERSION") echo "white"; else echo "black"; ?>"><?=$dt->status?></td> <td><?=$dt->remark?></td> <td><?=$dt->next_action_date?></td> <td><a target="blank" class="btn btn-primary" href="<?=base_url()?>Enquiries/logs/<?=$dt->id?>"><?=$this->Enquiries_model->get_enquiries_logs($dt->id)->num_rows()?> Logs</td> <td> <?php if($dt->status!="CANCELLED" && $dt->status!="CONVERSION"){ ?> <a class="btn btn-success" href="<?=base_url()?>Enquiries/Make_conversion?enquiry_id=<?=$dt->id?>">Make As Conversion</a> <?php } ?></td> <td> <?php if($dt->status!="CANCELLED" && $dt->status!="CONVERSION"){ ?><a class="btn btn-primary" href="javascript:;" onclick="open_followup(<?=$dt->id?>)">Add Follow Up</a> <?php } ?></td> <td> <?php if($dt->status!="CANCELLED" && $dt->status!="CONVERSION"){ ?> <a class="btn btn-danger" href="<?=base_url()?>Enquiries/Make_cancel?enquiry_id=<?=$dt->id?>">Cancel Enquiry</a> <?php } ?></td> <td> <?php if($dt->status!="CANCELLED" && $dt->status!="CONVERSION"){ ?> <a class="btn btn-danger" href="<?=base_url()?>Enquiries/Make_delete?enquiry_id=<?=$dt->id?>">Delete Enquiry </a> <?php } ?></td> </tr> <?php } ?> </tbody> </table> </div> </div> </div>