short code in client payment, edit logic for short codes
This commit is contained in:
@@ -41,6 +41,6 @@ class ProcessClientContractRenewalAlert extends Command
|
||||
{
|
||||
|
||||
$this->client_contractRenewalReminder->getClientDetails();
|
||||
\Log::info('SendClientContractRenewalReminders command completed...');
|
||||
// \Log::info('SendClientContractRenewalReminders command completed...');
|
||||
}
|
||||
}
|
||||
|
||||
@@ -41,6 +41,6 @@ class SendContractRenewalReminders extends Command
|
||||
{
|
||||
|
||||
$this->contractRenewalReminder->getMnos();
|
||||
\Log::info('SendContractRenewalReminders command completed...');
|
||||
// \Log::info('SendContractRenewalReminders command completed...');
|
||||
}
|
||||
}
|
||||
|
||||
@@ -13,7 +13,7 @@ class Kernel extends ConsoleKernel
|
||||
* @var array
|
||||
*/
|
||||
protected $commands = [
|
||||
Commands\SendContractRenewalReminders::class
|
||||
Commands\SendContractRenewalReminders::class,
|
||||
Commands\ProcessClientContractRenewalAlert::class
|
||||
];
|
||||
|
||||
|
||||
@@ -15,7 +15,7 @@ use Carbon\Carbon;
|
||||
|
||||
|
||||
class ClientsController extends Controller
|
||||
{
|
||||
{
|
||||
/**
|
||||
* Display a listing of the resource.
|
||||
*
|
||||
@@ -51,11 +51,11 @@ class ClientsController extends Controller
|
||||
/*
|
||||
$client_arr = new Models\Client;
|
||||
$client_arr = $client_arr->with('auth_user_info','country_info', 'created_by_info', 'modified_by_info')->orderBy('name', 'ASC')->paginate(20);
|
||||
|
||||
|
||||
dump($request->all());
|
||||
$client_arr = $client_arr->with('auth_user_info','country_info', 'created_by_info', 'modified_by_info')
|
||||
->orderBy('name', 'ASC')->paginate(20);
|
||||
}
|
||||
}
|
||||
*/
|
||||
$client_arr = \DB::table('clients')
|
||||
->join('auth_users AS aumngr', 'aumngr.id', '=', 'clients.auth_user_id')
|
||||
@@ -75,8 +75,8 @@ class ClientsController extends Controller
|
||||
->whereRaw("clients.name like '%$keyword%' or clients.status like '%$keyword%' OR clients.country like '%$keyword%' OR aumngr.name like '%$keyword%' OR aumodify.name like '%$keyword%' OR clients.progress_indicator_score like '%$keyword%'")
|
||||
->orderBy('name', 'ASC')
|
||||
->paginate(15);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
return response()->json($client_arr);
|
||||
}
|
||||
public function getClientJsonRawJs(Request $request){
|
||||
@@ -100,7 +100,7 @@ class ClientsController extends Controller
|
||||
}
|
||||
return response()->json($client_arr);
|
||||
}
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* Show the form for creating a new resource.
|
||||
@@ -118,7 +118,7 @@ class ClientsController extends Controller
|
||||
$company_types = ['Aggregator/Supplier' => 'Aggregator/Supplier', 'Enterprise' => 'Enterprise', 'Hybrid' => 'Hybrid'];
|
||||
$industries = Models\Industry::orderBy('name', 'ASC')->pluck('name', 'name');
|
||||
// $industries = Models\Industry::pluck('name', 'name')->orderBy('name', 'ASC');
|
||||
|
||||
|
||||
|
||||
$data = [
|
||||
'page_title' => 'Create Client',
|
||||
@@ -134,7 +134,7 @@ class ClientsController extends Controller
|
||||
|
||||
return view('client.create', $data);
|
||||
}
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* Store a newly created resource in storage.
|
||||
@@ -160,11 +160,11 @@ class ClientsController extends Controller
|
||||
$onboarding_stages = Models\ClientOnboardingMainStage::orderBy('stage_id')->get();
|
||||
// dd($onboarding_stages);
|
||||
$client_current_stages = [];
|
||||
|
||||
|
||||
foreach ($onboarding_stages as $value) {
|
||||
$client_current_stages[$value->stage] = "PENDING";
|
||||
}
|
||||
|
||||
|
||||
$client_arr = [
|
||||
'name' => $request->name,
|
||||
'email' => $request->email,
|
||||
@@ -176,7 +176,7 @@ class ClientsController extends Controller
|
||||
'created_by' => session('current_user.id'),
|
||||
'last_modified_by' => session('current_user.id'),
|
||||
'progress_indicator_score' => 10,
|
||||
'progress_indicator' => $onboarding_stages[0]->stage, // 'Agreement Stage', //
|
||||
'progress_indicator' => $onboarding_stages[0]->stage, // 'Agreement Stage', //
|
||||
'onboarding_progress_stage' => json_encode($client_current_stages)
|
||||
];
|
||||
if ($request->has('notes')) {
|
||||
@@ -206,16 +206,16 @@ class ClientsController extends Controller
|
||||
if ($request->has('payment_mode')) {
|
||||
$client_arr['pay_mode'] = $request->payment_mode;
|
||||
}
|
||||
|
||||
|
||||
$result = Models\Client::create($client_arr);
|
||||
|
||||
|
||||
//add entries for client_onboarding_progress
|
||||
$get_stage_subs_items = Models\ClientOnboardingSubItem::get();
|
||||
$get_stage_subs_items = Models\ClientOnboardingSubItem::get();
|
||||
foreach ($get_stage_subs_items as $value) {
|
||||
$progress_arr = [
|
||||
'stage_id' => $value->stage_id,
|
||||
'client_id' => $result->id,
|
||||
'name' => $value->name,
|
||||
'stage_id' => $value->stage_id,
|
||||
'client_id' => $result->id,
|
||||
'name' => $value->name,
|
||||
'status' => 'PENDING'
|
||||
];
|
||||
$clients_onboarding_progress = Models\ClientOnboardingProgress::create($progress_arr);
|
||||
@@ -228,7 +228,7 @@ class ClientsController extends Controller
|
||||
'last_modified_by_id' => session('current_user.id')
|
||||
];
|
||||
$retval = Models\UssdClientPayment::create($ussd_client_payment_arr);
|
||||
//TODO send an email to jim/priscilla about new USSD client,
|
||||
//TODO send an email to jim/priscilla about new USSD client,
|
||||
#dispatch(new SendNewUssdClientEmail($result));
|
||||
}
|
||||
#save services this has been moved to the main client table
|
||||
@@ -261,8 +261,8 @@ class ClientsController extends Controller
|
||||
if ($request->has('highlight')) {
|
||||
$notes_arr['highlight'] = 'YES';
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
//dd($notes_arr);
|
||||
$result = Models\ClientNote::create($notes_arr);
|
||||
// dd($result);
|
||||
@@ -285,7 +285,7 @@ class ClientsController extends Controller
|
||||
public function getSingleNote($id){
|
||||
$note = Models\ClientNote::find($id);
|
||||
if ($note) {
|
||||
|
||||
|
||||
$current_date = date_create(date('Y-m-d'));
|
||||
// dump($current_date);
|
||||
$expiry_date = date_create($note->created_at);
|
||||
@@ -304,7 +304,7 @@ class ClientsController extends Controller
|
||||
else{
|
||||
return response()->json([ 'code' => 3, 'msg' => 'Request could not be handled at this time']);
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
public function notesUpdate(Request $request)
|
||||
{
|
||||
@@ -316,14 +316,14 @@ class ClientsController extends Controller
|
||||
$note = Models\ClientNote::find($request->note_id);
|
||||
$note->notes_body = $request->notes_body;
|
||||
$note->services = implode(',', $request->services);
|
||||
|
||||
|
||||
if ($request->has('highlight')) {
|
||||
$note->highlight = 'YES';
|
||||
}
|
||||
$result = $note->save();
|
||||
|
||||
|
||||
$notes = Models\ClientNote::with('client_info', 'created_by_info')->find($request->note_id);
|
||||
|
||||
|
||||
//dispatch(new SendNewNotesEmailAlert($notes));
|
||||
|
||||
if ($result) {
|
||||
@@ -338,15 +338,15 @@ class ClientsController extends Controller
|
||||
$this->logUsersActivity($type = 'staff', $content);
|
||||
return response()->json($data, 200);
|
||||
}
|
||||
public function financeStore(Request $request)
|
||||
{
|
||||
public function financeStore(Request $request){
|
||||
$request->validate([
|
||||
'client_id' => 'required',
|
||||
'services' => 'required',
|
||||
'invoice_number' => 'required',
|
||||
'invoice_amount' => 'required|numeric',
|
||||
'invoice_date' => 'required',
|
||||
'invoice_status' => 'required'
|
||||
'invoice_status' => 'required',
|
||||
'short_code' => 'sometimes|numeric'
|
||||
]);
|
||||
$auth_user = session('current_user');
|
||||
|
||||
@@ -356,6 +356,7 @@ class ClientsController extends Controller
|
||||
'invoice_amount' => $request->invoice_amount,
|
||||
'invoice_date' => $request->invoice_date,
|
||||
'invoice_status' => $request->invoice_status,
|
||||
'short_code' => ($request->short_code) ? $request->short_code : "",
|
||||
'services' => implode(',', $request->services),
|
||||
'user_id' => $auth_user['id'],
|
||||
'client_id' => $request->client_id
|
||||
@@ -363,7 +364,7 @@ class ClientsController extends Controller
|
||||
if ($request->has('remarks')) {
|
||||
$finance_arr['remarks'] = $request->remarks;
|
||||
}
|
||||
|
||||
|
||||
$result = Models\ClientPayment::create($finance_arr);
|
||||
|
||||
#$payments = Models\ClientPayment::with('client_info', 'created_by_info')->find($result->id);
|
||||
@@ -394,19 +395,24 @@ class ClientsController extends Controller
|
||||
]);
|
||||
$auth_user = session('current_user');
|
||||
#$network = Models\NetworkOps::find($request->network);
|
||||
|
||||
$mnoCountry = $this->getMnoCountry($request->network);
|
||||
if ($mnoCountry == false) {
|
||||
$data = ['code' => 3, 'msg' => 'Your request could not be handled at this time'];
|
||||
return response()->json($data, 200);
|
||||
}
|
||||
/*
|
||||
$networks_raw = [
|
||||
'AirtelTigo GH' => 'AirtelTigo GH',
|
||||
'MTN GH' => 'MTN GH',
|
||||
'Airtel MW' => 'Airtel MW',
|
||||
'Airtel Zambia' => 'Airtel Zambia',
|
||||
'TNM MW' => 'TNM MW',
|
||||
'Airtel Zambia' => 'Airtel Zambia',
|
||||
'TNM MW' => 'TNM MW',
|
||||
'Airtel MW' => 'Airtel MW',
|
||||
'Safaricom Kenya' => 'Safaricom Kenya',
|
||||
'Safaricom Kenya' => 'Safaricom Kenya',
|
||||
'Airtel Kenya' => 'Airtel Kenya',
|
||||
'Telkom Kenya' => 'Telkom Kenya',
|
||||
'Telkom Kenya' => 'Telkom Kenya',
|
||||
'Orange Kenya' => 'Orange Kenya'
|
||||
];
|
||||
];
|
||||
if (stripos($request->network, 'MW') !== false ) {
|
||||
$country = 'Malawi';
|
||||
}
|
||||
@@ -426,16 +432,17 @@ class ClientsController extends Controller
|
||||
$data = ['code' => 3, 'msg' => 'Your request could not be handled at this time'];
|
||||
return response()->json($data, 200);
|
||||
}
|
||||
*/
|
||||
|
||||
$shortcode_arr = [
|
||||
'name' => $request->name,
|
||||
'client_id' => $request->client_id,
|
||||
'network' => $request->network,
|
||||
'country' => $country, //$network->country,
|
||||
'country' => $mnoCountry, //$network->country,
|
||||
'shortcode' => $request->shortcode,
|
||||
'code_type' => $request->code_type,
|
||||
'toll_free' => $request->toll_free,
|
||||
'last_updaed_by' => $auth_user['id'],
|
||||
'last_updated_by' => $auth_user['id'],
|
||||
'launch_date' => $request->launch_date,
|
||||
'expiry_date' => $request->expiry_date,
|
||||
'status' => $request->status
|
||||
@@ -443,7 +450,7 @@ class ClientsController extends Controller
|
||||
if ($request->has('remarks')) {
|
||||
$shortcode_arr['remarks'] = $request->remarks;
|
||||
}
|
||||
|
||||
|
||||
$result = Models\ClientShortCode::create($shortcode_arr);
|
||||
|
||||
if ($result) {
|
||||
@@ -458,8 +465,7 @@ class ClientsController extends Controller
|
||||
$this->logUsersActivity($type = 'staff', $content);
|
||||
return response()->json($data, 200);
|
||||
}
|
||||
public function financeUpdate(Request $request)
|
||||
{
|
||||
public function financeUpdate(Request $request){
|
||||
$request->validate([
|
||||
'payment_id' => 'required',
|
||||
'client_id' => 'required',
|
||||
@@ -491,14 +497,63 @@ class ClientsController extends Controller
|
||||
$this->logUsersActivity($type = 'staff', $content);
|
||||
return response()->json($data, 200);
|
||||
}
|
||||
public function shortCodeUpdate(Request $request){
|
||||
$request->validate([
|
||||
'client_id' => 'required',
|
||||
'network' => 'required',
|
||||
'shortcode' => 'required',
|
||||
'code_type' => 'required',
|
||||
'toll_free' => 'required',
|
||||
'status' => 'required',
|
||||
'remarks' => 'required',
|
||||
'launch_date' => 'required',
|
||||
'expiry_date' => 'required'
|
||||
]);
|
||||
$auth_user = session('current_user');
|
||||
$mnoCountry = $this->getMnoCountry($request->network);
|
||||
if ($mnoCountry == false) {
|
||||
$data = ['code' => 3, 'msg' => 'Your request could not be handled at this time'];
|
||||
return response()->json($data, 200);
|
||||
// code...
|
||||
}
|
||||
$shortcode_arr = [
|
||||
'name' => $request->name,
|
||||
'client_id' => $request->client_id,
|
||||
'network' => $request->network,
|
||||
'country' => $mnoCountry, //$network->country,
|
||||
'shortcode' => $request->shortcode,
|
||||
'code_type' => $request->code_type,
|
||||
'toll_free' => $request->toll_free,
|
||||
'last_updated_by' => $auth_user['id'],
|
||||
'launch_date' => $request->launch_date,
|
||||
'expiry_date' => $request->expiry_date,
|
||||
'status' => $request->status
|
||||
];
|
||||
if ($request->has('remarks')) {
|
||||
$shortcode_arr['remarks'] = $request->remarks;
|
||||
}
|
||||
// $payment = Models\ClientShortCode::findOrFail($request->shortcode_id);
|
||||
$result = Models\ClientShortCode::where('id', $request->shortcode_id)->update($shortcode_arr);
|
||||
|
||||
if ($result) {
|
||||
$data = ['code' => 1, 'msg' => 'Payment Details successfully updated'];
|
||||
}
|
||||
else{
|
||||
$data = ['code' => 3, 'msg' => 'Your request could not be handled at this time'];
|
||||
}
|
||||
$user_id = session('current_user.id');
|
||||
$username = session('current_user.name');
|
||||
$content = "User ID : " . $user_id . " (" . $username . ") updated short code enty";
|
||||
$this->logUsersActivity($type = 'staff', $content);
|
||||
return response()->json($data, 200);
|
||||
}
|
||||
/**
|
||||
* Display the specified resource.
|
||||
*
|
||||
* @param int $id
|
||||
* @return \Illuminate\Http\Response
|
||||
*/
|
||||
public function show($id)
|
||||
{
|
||||
public function show($id){
|
||||
//with('short_code_info')->
|
||||
$showclient = Models\Client::with('service_info', 'country_flag_info', 'auth_user_info', 'short_code_info')->find($id);
|
||||
// dd(json_decode($showclient->progress_indicators, true));
|
||||
@@ -515,17 +570,17 @@ class ClientsController extends Controller
|
||||
$service_type = Models\Service::pluck('name', 'id');
|
||||
$service_type_names = Models\Service::pluck('name', 'name');
|
||||
$show_services = Models\ClientCategory::where('client_id', $id)->get();
|
||||
//$networks_raw = ['AirtelTigo GH' => 'AirtelTigo GH','MTN GH' => 'MTN GH', 'Airtel MW' => 'Airtel MW', 'Airtel Zambia' => 'Airtel Zambia', 'TNM MW' => 'TNM MW', 'Airtel MW' => 'Airtel MW'];
|
||||
//$networks_raw = ['AirtelTigo GH' => 'AirtelTigo GH','MTN GH' => 'MTN GH', 'Airtel MW' => 'Airtel MW', 'Airtel Zambia' => 'Airtel Zambia', 'TNM MW' => 'TNM MW', 'Airtel MW' => 'Airtel MW'];
|
||||
$networks_raw = [
|
||||
'AirtelTigo GH' => 'AirtelTigo GH',
|
||||
'MTN GH' => 'MTN GH',
|
||||
'Airtel MW' => 'Airtel MW',
|
||||
'Airtel Zambia' => 'Airtel Zambia',
|
||||
'TNM MW' => 'TNM MW',
|
||||
'Airtel Zambia' => 'Airtel Zambia',
|
||||
'TNM MW' => 'TNM MW',
|
||||
'Airtel MW' => 'Airtel MW',
|
||||
'Safaricom Kenya' => 'Safaricom Kenya',
|
||||
'Safaricom Kenya' => 'Safaricom Kenya',
|
||||
'Airtel Kenya' => 'Airtel Kenya',
|
||||
'Telkom Kenya' => 'Telkom Kenya',
|
||||
'Telkom Kenya' => 'Telkom Kenya',
|
||||
'Orange Kenya' => 'Orange Kenya'
|
||||
];
|
||||
//->where('highlight', 'NO')
|
||||
@@ -568,27 +623,27 @@ class ClientsController extends Controller
|
||||
else{
|
||||
$expiry_date = Carbon::parse($showclient->contract_validity);
|
||||
$current_date = Carbon::parse(date('Y-m-d'));
|
||||
|
||||
$polar = ($expiry_date < $current_date) ? "-" : "+";
|
||||
|
||||
$polar = ($expiry_date < $current_date) ? "-" : "+";
|
||||
$days = $expiry_date->diffInDays($current_date);
|
||||
if($days > 365){
|
||||
if ($polar == '-') {
|
||||
$highlight_colour = 'warning';
|
||||
$renewal_due = "Contract expired " . floor($days/365) . " year(s) ago";
|
||||
|
||||
|
||||
}
|
||||
else{
|
||||
$renewal_due = "In " . floor($days/365) . " year(s)";
|
||||
$renewal_due = "In " . floor($days/365) . " year(s)";
|
||||
}
|
||||
}
|
||||
elseif($days > 31){
|
||||
if ($polar == '-') {
|
||||
$highlight_colour = 'warning';
|
||||
$renewal_due = "Contract expired " . floor($days/31) . " month(s) ago";
|
||||
|
||||
|
||||
}
|
||||
else{
|
||||
$renewal_due = "In " . floor($days/31) . " months";
|
||||
$renewal_due = "In " . floor($days/31) . " months";
|
||||
}
|
||||
}
|
||||
else{
|
||||
@@ -598,9 +653,9 @@ class ClientsController extends Controller
|
||||
$renewal_due = "Contract expired $days days(s) ago";
|
||||
}
|
||||
else{
|
||||
$renewal_due = "In $days day(s)" ;
|
||||
$renewal_due = "In $days day(s)" ;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
sort($networks_raw);
|
||||
@@ -629,14 +684,13 @@ class ClientsController extends Controller
|
||||
];
|
||||
return view('client.show', $data);
|
||||
}
|
||||
public function showReadonly($id)
|
||||
{
|
||||
public function showReadonly($id){
|
||||
//with('short_code_info')->
|
||||
$showclient = Models\Client::with('service_info', 'country_info', 'auth_user_info', 'short_code_info')->find($id);
|
||||
$service_type = Models\Service::pluck('name', 'id');
|
||||
$service_type_names = Models\Service::pluck('name', 'name');
|
||||
$show_services = json_decode($showclient->services, true); //Models\ClientCategory::where('client_id', $id)->get();
|
||||
|
||||
|
||||
//->where('highlight', 'NO')
|
||||
$show_notes = Models\ClientNote::with('created_by_info', 'client_info')->where('client_id', $id)->orderBy('id', 'DESC')->get()->take(20);
|
||||
$voice_codes = Models\ClientShortCode::where('client_id', $id)->where('code_type', 'voice')->get();
|
||||
@@ -647,7 +701,7 @@ class ClientsController extends Controller
|
||||
$networks = Models\NetworkOps::pluck('name', 'name');
|
||||
$all_shortcodes = Models\ClientShortCode::with('client_info', 'client_info', 'update_info')->where('client_id', $id)->orderBy('code_type', 'ASC')->get();
|
||||
$showdocuments = Models\ClientFile::where('client_id', $id)->get();
|
||||
|
||||
|
||||
if ($showclient->status == 'Live') {
|
||||
$status_bg = "info";
|
||||
}
|
||||
@@ -665,18 +719,18 @@ class ClientsController extends Controller
|
||||
$renewal_due = "N/A";
|
||||
}
|
||||
else{
|
||||
|
||||
|
||||
|
||||
$current_date = date_create(date('Y-m-d'));
|
||||
|
||||
$expiry_date = date_create($showclient->contract_validity);
|
||||
|
||||
$diff = date_diff($current_date, $expiry_date);
|
||||
|
||||
|
||||
$polar = $diff->format("%R");
|
||||
|
||||
|
||||
$months = $diff->format("%m");
|
||||
|
||||
|
||||
$days = $diff->format("%a");
|
||||
if ($days < 31) {
|
||||
if ($polar == '-') {
|
||||
@@ -684,7 +738,7 @@ class ClientsController extends Controller
|
||||
$renewal_due = "Contract expired $days days(s) ago";
|
||||
}
|
||||
else{
|
||||
$renewal_due = "In $days day(s)" ;
|
||||
$renewal_due = "In $days day(s)" ;
|
||||
}
|
||||
}
|
||||
else{
|
||||
@@ -692,12 +746,12 @@ class ClientsController extends Controller
|
||||
if ($polar == '-') {
|
||||
$highlight_colour = 'warning';
|
||||
$renewal_due = "Contract expired $months month(s) ago";
|
||||
|
||||
|
||||
}
|
||||
else{
|
||||
$renewal_due = "In $months months";
|
||||
$renewal_due = "In $months months";
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
$data = [
|
||||
'page_title' => 'Client Profile',
|
||||
@@ -738,8 +792,7 @@ class ClientsController extends Controller
|
||||
];
|
||||
return view('client.service-edit', $data);
|
||||
}
|
||||
public function getPayment($id)
|
||||
{
|
||||
public function getPayment($id){
|
||||
$payment = Models\ClientPayment::find($id);
|
||||
if ($payment) {
|
||||
$services_arr = explode(',', $payment->services);
|
||||
@@ -749,9 +802,17 @@ class ClientsController extends Controller
|
||||
else{
|
||||
return response()->json([ 'code' => 3, 'msg' => 'Request could not be handled at this time']);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
public function getShortCodeDetails($id){
|
||||
$shortcode = Models\ClientShortCode::with('client_info', 'update_info')->find($id);
|
||||
if ($shortcode) {
|
||||
$services_arr = Models\Service::pluck('name', 'id');
|
||||
return response()->json([ 'code' => 1, 'result' => $shortcode, 'services_arr' => $services_arr]);
|
||||
}
|
||||
else{
|
||||
return response()->json([ 'code' => 3, 'msg' => 'Request could not be handled at this time']);
|
||||
}
|
||||
}
|
||||
public function getShortCodes($type){
|
||||
//$auth_users = Models\SystemUser::pluck('name', 'id');
|
||||
//todo : separate the short codes into individual pages
|
||||
@@ -770,7 +831,7 @@ class ClientsController extends Controller
|
||||
break;
|
||||
}
|
||||
$codes = Models\ClientShortCode::with('update_info')->get();
|
||||
|
||||
|
||||
$data = [
|
||||
'page_title' => 'Client Short Codes',
|
||||
'codes_data' => $codes_data,
|
||||
@@ -789,7 +850,7 @@ class ClientsController extends Controller
|
||||
{
|
||||
$client = Models\Client::find($id);
|
||||
$service_type = Models\Service::orderBy('name', 'ASC')->pluck('name', 'name');
|
||||
|
||||
|
||||
$countries = Models\Country::orderBy('en_short_name', 'ASC')->pluck('en_short_name','en_short_name');
|
||||
|
||||
$payment_type = ['Prepaid' => 'Prepaid', 'Postpaid' => 'Postpaid']; // Models\PaymentType::pluck('name', 'id')->toArray();
|
||||
@@ -814,10 +875,10 @@ class ClientsController extends Controller
|
||||
// dump($stage_details);
|
||||
$onboarding_sub_items_progress = Models\ClientOnboardingProgress::where('stage_id', $stage_details->stage_id)->where('client_id', $id)->pluck('name', 'name');
|
||||
// dd($onboarding_sub_items_progress);
|
||||
$onboarding_sub_items = Models\ClientOnboardingSubItem::where('stage_id', $stage_details->stage_id)->pluck('name', 'name');
|
||||
$onboarding_sub_items = Models\ClientOnboardingSubItem::where('stage_id', $stage_details->stage_id)->pluck('name', 'name');
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
/*
|
||||
else{
|
||||
|
||||
@@ -829,7 +890,7 @@ class ClientsController extends Controller
|
||||
}
|
||||
*/
|
||||
$how_we_got_clients_arr = ['Event : (GCCM) etc' => 'Event : (GCCM) etc', 'Referral' => 'Referral', 'Word of Mouth' => 'Word of Mouth', 'Marketing' => 'Marketing', 'Other' => 'Other'];
|
||||
|
||||
|
||||
|
||||
// 'current_services' => json_decode($client->services, true);
|
||||
|
||||
@@ -891,7 +952,7 @@ class ClientsController extends Controller
|
||||
$sender_ids = ['click' => 'click'];
|
||||
$old_sender_ids = [];
|
||||
}
|
||||
|
||||
|
||||
|
||||
if ($client->status == 'Live') {
|
||||
$status_bg = "info";
|
||||
@@ -902,10 +963,10 @@ class ClientsController extends Controller
|
||||
else{
|
||||
$status_bg = "danger";
|
||||
}
|
||||
|
||||
|
||||
$contract_types = ['Bilateral' => 'Bilateral', 'Unilateral' => 'Unilateral'];
|
||||
$connections = ['SMPP' => 'SMPP', 'HTTP' => 'HTTP'];
|
||||
|
||||
|
||||
$data = [
|
||||
'client' => $client,
|
||||
'countries' => $countries,
|
||||
@@ -924,7 +985,7 @@ class ClientsController extends Controller
|
||||
'rate_emails' => $rate_emails,
|
||||
'support_skype_arr' => $support_skype_arr,
|
||||
'support_phones' => $support_phones,
|
||||
|
||||
|
||||
'old_finance_emails' => $old_finance_emails,
|
||||
'old_rate_emails' => $old_rate_emails,
|
||||
'old_support_emails' => $old_support_emails,
|
||||
@@ -938,7 +999,7 @@ class ClientsController extends Controller
|
||||
'industries' => $industries,
|
||||
'how_we_got_clients_arr' => $how_we_got_clients_arr,
|
||||
'current_services' => json_decode($client->services, true),
|
||||
|
||||
|
||||
'onboarding_sub_items_progress' => $onboarding_sub_items_progress,
|
||||
'onboarding_sub_items' => $onboarding_sub_items,
|
||||
'current_pending_stage' => $client->progress_indicator,
|
||||
@@ -956,21 +1017,21 @@ class ClientsController extends Controller
|
||||
*/
|
||||
public function update(Requests\UpdateClientRequest $request, $id)
|
||||
{
|
||||
|
||||
|
||||
$client_update = Models\Client::find($id);
|
||||
if ($client_update->progress_indicator != 'COMPLETED') {
|
||||
$current_pending_stage_details = Models\ClientOnboardingMainStage::where('stage', $request->current_pending_stage)->first();
|
||||
$get_stage_subs_items = Models\ClientOnboardingSubItem::where('stage_id', $current_pending_stage_details->stage_id)->get();
|
||||
$get_stage_subs_items = Models\ClientOnboardingSubItem::where('stage_id', $current_pending_stage_details->stage_id)->get();
|
||||
#update the table for onboarding progress
|
||||
foreach ($request->onboarding_sub_items_progress as $value) {
|
||||
$stage_id = ['stage_id' => $current_pending_stage_details->stage_id, 'client_id' => $id, 'name' => $value ];
|
||||
$progress_arr = [
|
||||
'status' => 'COMPLETED'
|
||||
'status' => 'COMPLETED'
|
||||
];
|
||||
$clients_onboarding_progress = Models\ClientOnboardingProgress::updateOrCreate($stage_id, $progress_arr);
|
||||
}
|
||||
|
||||
//update the status of onboarding progress stage in clients
|
||||
//update the status of onboarding progress stage in clients
|
||||
$get_stage_onboarding_status = Models\ClientOnboardingProgress::where('client_id', $id)->where('stage_id', $current_pending_stage_details->stage_id)->where('status', 'COMPLETED')->get();
|
||||
// dd($get_stage_onboarding_status);
|
||||
$onboarding_progress_stage = json_decode($client_update->onboarding_progress_stage, true);
|
||||
@@ -979,11 +1040,11 @@ class ClientsController extends Controller
|
||||
if (count($get_stage_subs_items) == count($get_stage_onboarding_status)) {
|
||||
//check if all items have been completed and update
|
||||
$onboarding_progress_stage[$current_pending_stage_details->stage] = 'COMPLETED';
|
||||
}
|
||||
}
|
||||
$pending_stage = Arr::where($onboarding_progress_stage, function ($value, $key) {
|
||||
return $value == "PENDING";
|
||||
});
|
||||
|
||||
|
||||
#$pending_stage = array_key_first($pending_stage);
|
||||
reset($pending_stage);
|
||||
$pending_stage = key($pending_stage);
|
||||
@@ -1006,7 +1067,7 @@ class ClientsController extends Controller
|
||||
$request->document_one->storeAs('client_files', $filename, 'public');
|
||||
$document_arr['file_path'] = $filename;
|
||||
$client_update->name = $request->name;
|
||||
|
||||
|
||||
$document_arr['file_extension'] = $request->document_one->extension();
|
||||
$document_arr['file_reff'] = time() . uniqid();
|
||||
$document_arr['name'] = $request->document_one_name;
|
||||
@@ -1021,7 +1082,7 @@ class ClientsController extends Controller
|
||||
$request->document_two->storeAs('client_files', $filename, 'public');
|
||||
$document_arr['file_path'] = $filename;
|
||||
$client_update->name = $request->name;
|
||||
|
||||
|
||||
$document_arr['file_extension'] = $request->document_two->extension();
|
||||
$document_arr['file_reff'] = time() . uniqid();
|
||||
$document_arr['name'] = $request->document_two_name;
|
||||
@@ -1036,7 +1097,7 @@ class ClientsController extends Controller
|
||||
$request->document_three->storeAs('client_files', $filename, 'public');
|
||||
$document_arr['file_path'] = $filename;
|
||||
$client_update->name = $request->name;
|
||||
|
||||
|
||||
$document_arr['file_extension'] = $request->document_three->extension();
|
||||
$document_arr['file_reff'] = time() . uniqid();
|
||||
$document_arr['name'] = $request->document_three_name;
|
||||
@@ -1051,7 +1112,7 @@ class ClientsController extends Controller
|
||||
$request->other_document->storeAs('client_files', $filename, 'public');
|
||||
$document_arr['file_path'] = $filename;
|
||||
$client_update->name = $request->name;
|
||||
|
||||
|
||||
$document_arr['file_extension'] = $request->other_document->extension();
|
||||
$document_arr['file_reff'] = time() . uniqid();
|
||||
$document_arr['name'] = $request->document_three_name;
|
||||
@@ -1074,14 +1135,14 @@ class ClientsController extends Controller
|
||||
#$client_update->progress_indicators = json_encode($request->onboarding_sub_items_progress);
|
||||
if ($client_update->progress_indicator != 'COMPLETED') {
|
||||
$client_update->onboarding_progress_stage = json_encode($onboarding_progress_stage);
|
||||
|
||||
|
||||
$progress_breakdown = array_count_values($onboarding_progress_stage);
|
||||
if (array_has($progress_breakdown, ['COMPLETED']) == false) {
|
||||
$indicator_score = "0";
|
||||
}
|
||||
else{
|
||||
$indicator_score = ($progress_breakdown['COMPLETED']/count($onboarding_progress_stage)) * 100;
|
||||
}
|
||||
$indicator_score = ($progress_breakdown['COMPLETED']/count($onboarding_progress_stage)) * 100;
|
||||
}
|
||||
|
||||
$indicator_score = number_format($indicator_score);
|
||||
$client_update->progress_indicator_score = $indicator_score;
|
||||
@@ -1093,7 +1154,7 @@ class ClientsController extends Controller
|
||||
$client_update->skype_name = $request->skype_name ?? "";
|
||||
$client_update->linkedin_name = $request->linkedin_name ?? "";
|
||||
$client_update->smpp_username = $request->smpp_username ?? "";
|
||||
|
||||
|
||||
$client_update->company_type = $request->company_type ?? "";
|
||||
$client_update->auth_user_id = $request->auth_user_id ?? "";
|
||||
$client_update->contract_type = $request->contract_type ?? "";
|
||||
@@ -1116,13 +1177,13 @@ class ClientsController extends Controller
|
||||
$client_update->how_we_got_client = $request->how_we_got_client_other ?? "";
|
||||
}
|
||||
else{
|
||||
$client_update->how_we_got_client = $request->how_we_got_client ?? "";
|
||||
$client_update->how_we_got_client = $request->how_we_got_client ?? "";
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
$client_update->created_by = session('current_user.id');
|
||||
$client_update->last_modified_by = session('current_user.id');
|
||||
$client_update->last_modified_by = session('current_user.id');
|
||||
|
||||
$result = $client_update->save();
|
||||
|
||||
@@ -1162,7 +1223,7 @@ class ClientsController extends Controller
|
||||
public function store_services($services_arr, $client_id){
|
||||
foreach ($services_arr as $id) {
|
||||
$client_arr = [
|
||||
'client_id' => $client_id,
|
||||
'client_id' => $client_id,
|
||||
'category_id' => $id
|
||||
];
|
||||
$result = Models\ClientCategory::create($client_arr);
|
||||
@@ -1175,7 +1236,7 @@ class ClientsController extends Controller
|
||||
|
||||
foreach ($services_arr as $id) {
|
||||
$client_arr = [
|
||||
'client_id' => $client_id,
|
||||
'client_id' => $client_id,
|
||||
'category_id' => $id
|
||||
];
|
||||
$result = Models\ClientCategory::create($client_arr);
|
||||
@@ -1212,7 +1273,7 @@ class ClientsController extends Controller
|
||||
$client_file = Models\ClientFile::with('client_info')->findOrFail($id);
|
||||
//PDF file is stored under project/public/download/info.pdf
|
||||
$file = public_path('documents/client_files/') . $client_file->file_path;
|
||||
|
||||
|
||||
$headers = []; //['Content-Type: application/pdf'];
|
||||
$filename = $client_file->client_info->name . "_" . $client_file->name;
|
||||
$filename = $this->cleanStr($filename);
|
||||
@@ -1223,7 +1284,7 @@ class ClientsController extends Controller
|
||||
}
|
||||
public function showOnboardingForm($client_id){
|
||||
$client = Models\Client::findOrFail($client_id);
|
||||
|
||||
|
||||
$onboarding_stages = Models\ClientOnboardingProgress::where('client_id', $client_id)->orderBy('stage_id')->get();
|
||||
//dd($onboarding_stages);
|
||||
$data = [
|
||||
@@ -1241,7 +1302,41 @@ class ClientsController extends Controller
|
||||
$string = preg_replace('/[^A-Za-z0-9\-]/', '', $string);
|
||||
// Replaces multiple hyphens with single one.
|
||||
$string = preg_replace('/-+/', '_', $string);
|
||||
|
||||
|
||||
return $string;
|
||||
}
|
||||
|
||||
public function getMnoCountry($network){
|
||||
$networks_raw = [
|
||||
'AirtelTigo GH' => 'AirtelTigo GH',
|
||||
'MTN GH' => 'MTN GH',
|
||||
'Airtel MW' => 'Airtel MW',
|
||||
'Airtel Zambia' => 'Airtel Zambia',
|
||||
'TNM MW' => 'TNM MW',
|
||||
'Airtel MW' => 'Airtel MW',
|
||||
'Safaricom Kenya' => 'Safaricom Kenya',
|
||||
'Airtel Kenya' => 'Airtel Kenya',
|
||||
'Telkom Kenya' => 'Telkom Kenya',
|
||||
'Orange Kenya' => 'Orange Kenya'
|
||||
];
|
||||
if (stripos($network, 'MW') !== false ) {
|
||||
$country = 'Malawi';
|
||||
}
|
||||
elseif (stripos($network, 'GH') !== false) {
|
||||
$country = 'Ghana';
|
||||
}
|
||||
elseif (stripos($network, 'Zambia') !== false) {
|
||||
$country = 'Zambia';
|
||||
}
|
||||
elseif (stripos($network, 'Bots') !== false) {
|
||||
$country = 'Botswana';
|
||||
}
|
||||
elseif (stripos($network, 'KE') !== false) {
|
||||
$country = 'Kenya';
|
||||
}
|
||||
else{
|
||||
$country = false;
|
||||
}
|
||||
return $country;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -5,7 +5,7 @@ namespace App\Http\Controllers;
|
||||
use Illuminate\Http\Request;
|
||||
|
||||
use App\Models;
|
||||
use Illuminate\Contracts\Mail\Mailer;
|
||||
// use Illuminate\Contracts\Mail\Mailer;
|
||||
|
||||
|
||||
|
||||
@@ -32,6 +32,11 @@ class UtilityController extends Controller
|
||||
|
||||
return view('utility.map');
|
||||
}
|
||||
|
||||
public function showPage(){
|
||||
|
||||
return view('utility.arraylogic');
|
||||
}
|
||||
public function ntfyTest(){
|
||||
$this->sendNtfy('In the ERP');
|
||||
}
|
||||
|
||||
@@ -38,8 +38,6 @@ class SendMnoContractRenewalEmailAlert implements ShouldQueue
|
||||
'mno_name' => $renewalSet['mno_name'],
|
||||
'alert_body' => 'Contract for ' . $renewalSet['mno_name'] . ' will expire in ' . $renewalSet['days_to_expire'] . ' days. Take note'
|
||||
];
|
||||
|
||||
\Log::info("Contract Renewal Alert triggered by : ");
|
||||
$mailer->send('emails.renewal-alert', $data, function ($message) use ($data, $emails) {
|
||||
$message->from('support@click-mobile.com', 'Click Mobile ERP');
|
||||
$message->to($emails)->subject('Contract Renewal Alert');
|
||||
|
||||
146
public/assets/js/clientshow.js
vendored
146
public/assets/js/clientshow.js
vendored
@@ -11,10 +11,10 @@
|
||||
var returnVal = confirm("Are you sure?");
|
||||
$(this).prop("checked", returnVal);
|
||||
}
|
||||
$('#textbox1').val(this.checked);
|
||||
$('#textbox1').val(this.checked);
|
||||
});
|
||||
*/
|
||||
$('.progressIndicatorCheckbox').on('change', function() {
|
||||
$('.progressIndicatorCheckbox').on('change', function() {
|
||||
// From the other examples
|
||||
// console.log('finker');
|
||||
if (!this.checked) {
|
||||
@@ -45,7 +45,7 @@
|
||||
evt.preventDefault();
|
||||
$('#progressIndicatorDetailsModal').modal('show');
|
||||
});
|
||||
|
||||
|
||||
$('#createSmsShortCodeBtn').click(function(evt){
|
||||
evt.preventDefault();
|
||||
$('#shortCodeType').val('sms');
|
||||
@@ -101,11 +101,56 @@
|
||||
title: 'Alert!',
|
||||
content: 'Your request could not be handled. Try again !',
|
||||
});
|
||||
|
||||
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
|
||||
});
|
||||
|
||||
|
||||
$('.shortCodeEditBtn').click(function(tve){
|
||||
tve.preventDefault();
|
||||
var theIDD = $(this).siblings('.shortCodeEntryRowId').val();
|
||||
$.ajax({
|
||||
type: "GET",
|
||||
url: base_url + '/clients/get_shortcode/' + theIDD,
|
||||
processData: false,
|
||||
contentType: false,
|
||||
async: false,
|
||||
success: function (data){
|
||||
if (data.code === 1) {
|
||||
console.log(theIDD);
|
||||
console.log(data);
|
||||
$('#shortCodeIDEdit').val(theIDD);
|
||||
$('#nameEdit').val(data.result.name);
|
||||
$('#shortCodeClientIdEdit').val(data.result.client_id);
|
||||
$('#shortCodeTypeEdit').val(data.result.code_type);
|
||||
$('#shortCodeEdit').val(data.result.shortcode);
|
||||
$('#tollFreeEdit').val(data.result.toll_free).change();
|
||||
$('#launchDateEdit').val(data.result.launch_date);
|
||||
$('#expiryDateEdit').val(data.result.expiry_date);
|
||||
$('#codeStatusEdit').val(data.result.status).change();
|
||||
$('#network').val(data.result.network).change();
|
||||
$('#remarksEdit').val(data.result.remarks);
|
||||
$('#shortCodeEditModal').modal('show');
|
||||
}
|
||||
else if (data.code > 1) {
|
||||
$.alert({
|
||||
title: 'Alert!',
|
||||
content: data.msg,
|
||||
});
|
||||
}
|
||||
else {
|
||||
$.alert({
|
||||
title: 'Alert!',
|
||||
content: 'Your request could not be handled. Try again !',
|
||||
});
|
||||
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
});
|
||||
|
||||
|
||||
@@ -143,17 +188,17 @@
|
||||
title: 'Alert!',
|
||||
content: 'Your request could not be handled. Try again !',
|
||||
});
|
||||
|
||||
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
|
||||
|
||||
|
||||
});
|
||||
|
||||
$('#newNotesFormForm').submit(function(evt){
|
||||
evt.preventDefault();
|
||||
evt.preventDefault();
|
||||
var formData = new FormData($(this)[0]);
|
||||
$.ajax({
|
||||
type: "POST",
|
||||
@@ -184,14 +229,14 @@
|
||||
title: 'Alert!',
|
||||
content: 'Your request could not be handled. Try again !',
|
||||
});
|
||||
|
||||
|
||||
}
|
||||
}
|
||||
});
|
||||
});
|
||||
|
||||
});
|
||||
|
||||
$('#financeForm').submit(function(evt){
|
||||
evt.preventDefault();
|
||||
evt.preventDefault();
|
||||
var formData = new FormData($(this)[0]);
|
||||
$.ajax({
|
||||
type: "POST",
|
||||
@@ -222,7 +267,7 @@
|
||||
title: 'Alert!',
|
||||
content: 'Your request could not be handled. Try again !',
|
||||
});
|
||||
|
||||
|
||||
}
|
||||
},
|
||||
error: function(error){
|
||||
@@ -237,11 +282,26 @@
|
||||
$('#financeNotifyArea').text(value[0]);
|
||||
});
|
||||
}
|
||||
});
|
||||
});
|
||||
});
|
||||
|
||||
$('#financeServicesStore').change(function(evtt){
|
||||
let currentServices = $('#financeServicesStore').val();
|
||||
$.each(currentServices, function (key, value) {
|
||||
// console.log(value);
|
||||
let short_code_services = ["USSD", "SMS Application", "IVR"];
|
||||
let checkArray = $.inArray(value, short_code_services) > -1;
|
||||
// console.log(checkArray);
|
||||
if (checkArray == true) {
|
||||
$('#ShortCodeFormGrp').removeClass('hidden');
|
||||
}
|
||||
else{
|
||||
$('#ShortCodeFormGrp').addClass('hidden');
|
||||
}
|
||||
});
|
||||
});
|
||||
$('#financeEditForm').submit(function(evt){
|
||||
evt.preventDefault();
|
||||
evt.preventDefault();
|
||||
var formData = new FormData($(this)[0]);
|
||||
$.ajax({
|
||||
type: "POST",
|
||||
@@ -271,14 +331,50 @@
|
||||
title: 'Alert!',
|
||||
content: 'Your request could not be handled. Try again !',
|
||||
});
|
||||
|
||||
|
||||
}
|
||||
}
|
||||
});
|
||||
});
|
||||
});
|
||||
|
||||
$('#shortCodeEditForm').submit(function(evt){
|
||||
evt.preventDefault();
|
||||
var formData = new FormData($(this)[0]);
|
||||
$.ajax({
|
||||
type: "POST",
|
||||
url: base_url + '/clients/shortcode_update',
|
||||
data : formData,
|
||||
processData: false,
|
||||
contentType: false,
|
||||
async: false,
|
||||
success: function (data){
|
||||
if (data.code === 1) {
|
||||
$.alert({
|
||||
title: 'Alert!',
|
||||
content: 'Short Code Details successfully updated',
|
||||
});
|
||||
setTimeout(function(){
|
||||
location.reload();
|
||||
}, 8000);
|
||||
}
|
||||
else if (data.code > 1) {
|
||||
$.alert({
|
||||
title: 'Alert!',
|
||||
content: data.msg,
|
||||
});
|
||||
}
|
||||
else {
|
||||
$.alert({
|
||||
title: 'Alert!',
|
||||
content: 'Your request could not be handled. Try again !',
|
||||
});
|
||||
|
||||
}
|
||||
}
|
||||
});
|
||||
});
|
||||
|
||||
$('#editNotesForm').submit(function(evt){
|
||||
evt.preventDefault();
|
||||
evt.preventDefault();
|
||||
// console.log($(this).length);
|
||||
var formData = new FormData($(this)[0]);
|
||||
$.ajax({
|
||||
@@ -309,14 +405,14 @@
|
||||
title: 'Alert!',
|
||||
content: 'Your request could not be handled. Try again !',
|
||||
});
|
||||
|
||||
|
||||
}
|
||||
}
|
||||
});
|
||||
});
|
||||
});
|
||||
|
||||
$('#shortCodeForm').submit(function(evt){
|
||||
evt.preventDefault();
|
||||
evt.preventDefault();
|
||||
var formData = new FormData($(this)[0]);
|
||||
$.ajax({
|
||||
type: "POST",
|
||||
@@ -346,7 +442,7 @@
|
||||
title: 'Alert!',
|
||||
content: 'Your request could not be handled. Try again !',
|
||||
});
|
||||
|
||||
|
||||
}
|
||||
},
|
||||
error: function (data) {
|
||||
@@ -361,7 +457,7 @@
|
||||
fail : function(errordata){
|
||||
// console.log(errordata);
|
||||
}
|
||||
});
|
||||
});
|
||||
});
|
||||
|
||||
});
|
||||
});
|
||||
|
||||
107
resources/views/client/partials/edit-shortcodes.blade.php
Normal file
107
resources/views/client/partials/edit-shortcodes.blade.php
Normal file
@@ -0,0 +1,107 @@
|
||||
<div class="modal fade" id="shortCodeEditModal" tabindex="-1" role="dialog" aria-labelledby="shortCodeEditModalLabel" aria-hidden="true">
|
||||
<div class="modal-dialog">
|
||||
<div class="modal-content">
|
||||
<div class="modal-header">
|
||||
<!-- <h4 class="modal-title">Default Modal</h4> -->
|
||||
<h5 class="modal-title text-center" id="shortCodeEditModalLabelHeading">Edit Short Code Form</h5>
|
||||
<button type="button" class="close" data-dismiss="modal" aria-label="Close">
|
||||
<span aria-hidden="true">×</span>
|
||||
</button>
|
||||
</div>
|
||||
<div class="modal-body">
|
||||
<div id="notifyAreaEdit" class="alert alert-danger hidden"></div>
|
||||
<form class="form-vertical" method="POST" id="shortCodeEditForm" action="{{ url('clients/shortcodes_update') }}">
|
||||
{{ csrf_field() }}
|
||||
<input type="hidden" name="shortcode_id" id="shortCodeIDEdit">
|
||||
<input type="hidden" name="code_type" id="shortCodeTypeEdit">
|
||||
<input type="hidden" name="client_id" id="shortCodeClientIdEdit">
|
||||
<div class="row">
|
||||
|
||||
<div class="form-group" >
|
||||
<div class="col-md-12" style="padding-bottom: 5px;">
|
||||
<label for="nameEdit">Friendly Name *</label>
|
||||
<input type="text" class="form-control" name="name" id="nameEdit" required >
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<div class="col-md-12" style="padding-bottom: 5px">
|
||||
<label for="networks">Network *</label>
|
||||
<!-- 'multiple'=> 'true', -->
|
||||
{!! Form::select('network', $networks_raw, null, ['class' => 'form-control' , 'id' => 'networks', 'required' => 'required', 'style' => 'width: 100%']) !!}
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group" >
|
||||
<div class="col-md-12" style="padding-bottom: 5px;">
|
||||
<label for="shortCodeEdit">Code *</label>
|
||||
<input type="number" class="form-control" name="shortcode" id="shortCodeEdit" required >
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<div class="col-md-12" style="padding-bottom: 5px">
|
||||
<label for="tollFreeEdit">Toll Free</label>
|
||||
<select name="toll_free" id="tollFreeEdit" class="form-control" required style="width: 100%;">
|
||||
<option value="YES">YES</option>
|
||||
<option value="NO">NO</option>
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<div class="col-md-6">
|
||||
<div class='input-group date' id='myDatepicker22Edit' style="padding-bottom: 5px;">
|
||||
<label for="launchDateEdit">Launch Date</label>
|
||||
<input type="text" class="form-control" name="launch_date" id="launchDateEdit" required >
|
||||
<div class="input-group-addon">
|
||||
<span class="fa fa-calendar"></span>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
<div class='input-group date' id='myDatepicker223Edit' style="padding-bottom: 5px;">
|
||||
<label for="expiryDateEdit">Expiry Date</label>
|
||||
<input type="text" class="form-control" name="expiry_date" id="expiryDateEdit" required >
|
||||
<div class="input-group-addon">
|
||||
<span class="fa fa-calendar"></span>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<div class="col-md-12" style="padding-bottom: 5px">
|
||||
<label for="codeStatusEdit">Status</label>
|
||||
<select id="codeStatusEdit" name="status" class="form-control" required style="width: 100%;">
|
||||
<option value="LIVE">Live</option>
|
||||
<option value="PENDING">Pending</option>
|
||||
<option value="TESTING">Testing</option>
|
||||
<option value="INACTIVE">Inactive </option>
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group" >
|
||||
<div class="col-md-12" style="padding-bottom: 5px;">
|
||||
<label for="remarksEdit">Remarks</label>
|
||||
<input type="text" class="form-control" name="remarks" id="remarksEdit"></textarea>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="form-group" style="margin-bottom: 0.2rem; padding-bottom: 5px; padding-top: 5px;">
|
||||
<div class="col-md-12" style="padding-bottom: 10px;">
|
||||
<button type="submit" class="btn btn-success btn-block updateBtn"> <i class="fa fa-send"></i> Submit</button>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group" style="margin-bottom: 0.5rem; padding-bottom: 5px; padding-top: 5px;">
|
||||
<div class="col-md-12">
|
||||
<button type="button" class="btn btn-dark btn-block" data-dismiss="modal"><i class="fa fa-close"></i> Close</button>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</form>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
<!-- /.modal-content -->
|
||||
</div>
|
||||
<!-- /.modal-dialog -->
|
||||
</div>
|
||||
<!-- /.modal -->
|
||||
@@ -14,16 +14,23 @@
|
||||
{{ csrf_field() }}
|
||||
<input type="hidden" name="client_id" id="clientID" value="{{ $showclient->id }}">
|
||||
<div class="row">
|
||||
<div class="form-group">
|
||||
<div class="form-group">
|
||||
<div class="col-md-12">
|
||||
<label for="financeServices">Services *</label>
|
||||
{!! Form::select('services[]', $service_type_names , old('services'), ['class' => 'form-control' , 'id' => 'financeServices', 'required' => 'required', 'multiple'=> 'true', 'style' => 'width: 100%']) !!}
|
||||
<label for="financeServicesStore">Services *</label>
|
||||
{!! Form::select('services[]', $service_type_names , old('services'), ['class' => 'form-control' , 'id' => 'financeServicesStore', 'required' => 'required', 'multiple'=> 'true', 'style' => 'width: 100%']) !!}
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group hidden" id="ShortCodeFormGrp" >
|
||||
<div class="col-md-12" style="padding-bottom: 5px;">
|
||||
<label for="shortCode">Short Code</label>
|
||||
<input type="text" class="form-control" name="short_code" id="shortCode" required >
|
||||
<p class="text-warning">Enter Short related to the selected service</p>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group" >
|
||||
<div class="col-md-12" style="padding-bottom: 5px;">
|
||||
<label for="invoiceNumber">Invoice Number *</label>
|
||||
<input type="text" class="form-control" name="invoice_number" id="invoiceNumber" required >
|
||||
<input type="text" class="form-control" name="invoice_number" id="invoiceNumber" required >
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group" >
|
||||
@@ -32,7 +39,7 @@
|
||||
<input type="text" class="form-control" name="invoice_amount" id="invoiceAmount" required >
|
||||
<div class="help-block text-warning">Enter Amount without commas</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<div class="col-md-12">
|
||||
<div class='input-group date' id='myDatepicker2' style="padding-bottom: 5px;">
|
||||
@@ -44,13 +51,13 @@
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<div class="col-md-12" style="padding-bottom: 5px">
|
||||
<label for="invoiceStatus">Status *</label>
|
||||
{!! Form::select('invoice_status', [ 'PAID' => 'PAID', 'UNPAID' => 'UNPAID'] , old('services'), ['class' => 'form-control' , 'id' => 'invoiceStatus', 'required' => 'required', 'placeholder' => '', 'style' => 'width: 100%']) !!}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group" >
|
||||
<div class="col-md-12" style="padding-bottom: 5px;">
|
||||
<label for="remarks">Remarks</label>
|
||||
@@ -58,7 +65,7 @@
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
<div class="form-group" style="margin-bottom: 0.2rem; padding-bottom: 5px; padding-top: 5px;">
|
||||
<div class="col-md-12" style="padding-bottom: 10px;">
|
||||
<button type="submit" class="btn btn-success btn-block updateBtn"> <i class="fa fa-send"></i> Submit</button>
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
<th class="column-title">Renewal Date</th>
|
||||
<th class="column-title no-link last"><span class="nobr">Action</span>
|
||||
</th>
|
||||
|
||||
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
@@ -27,7 +27,7 @@
|
||||
<td class="mes-td col-md-2">{{ $row->name }}</td>
|
||||
<td class="mes-td col-md-1">{{ $row->shortcode }}</td>
|
||||
<td class="mes-td col-md-2">{{ $row->network }}</td>
|
||||
<td class="mes-td col-md-1">{{ $row->toll_free }}</td>
|
||||
<td class="mes-td col-md-1">{{ $row->toll_free }}</td>
|
||||
<td class="mes-td col-md-1">{{ $row->status }}</td>
|
||||
<td class="mes-td col-md-1" style="width: 100px;">{{ date('d-m-Y', strtotime($row->launch_date)) }}</td>
|
||||
<td class="mes-td col-md-1" style="width: 100px;">
|
||||
@@ -39,7 +39,8 @@
|
||||
</td>
|
||||
<td class="last col-md-1" style="width: 100px;">
|
||||
<span>
|
||||
<a href="" class="btn btn-xs btn-primary"><i class="fa fa-edit"></i></a>
|
||||
<input type="hidden" name="short_code_entry_id" value="{{ $row->id }}" class="shortCodeEntryRowId">
|
||||
<a href="" class="btn btn-xs btn-primary shortCodeEditBtn"><i class="fa fa-edit"></i></a>
|
||||
</span>
|
||||
</td>
|
||||
</tr>
|
||||
@@ -48,4 +49,4 @@
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
<th class="column-title">Expiry Date</th>
|
||||
<th class="column-title no-link last"><span class="nobr">Action</span>
|
||||
</th>
|
||||
|
||||
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
@@ -28,21 +28,22 @@
|
||||
<td class="mes-td col-md-2">{{ $row->name }}</td>
|
||||
<td class="mes-td col-md-1">{{ $row->shortcode }}</td>
|
||||
<td class="mes-td col-md-2">{{ $row->network }}</td>
|
||||
<td class="mes-td col-md-1">{{ $row->toll_free }}</td>
|
||||
<td class="mes-td col-md-1">{{ $row->toll_free }}</td>
|
||||
<td class="mes-td col-md-1">{{ $row->status }}</td>
|
||||
<td class="mes-td col-md-1" style="width: 100px;">{{ date('d-m-Y', strtotime($row->launch_date)) }}</td>
|
||||
<td class="mes-td col-md-1" style="width: 100px;">
|
||||
|
||||
|
||||
@if($row->expiry_date == false)
|
||||
{{ "No found"}}
|
||||
@else
|
||||
{{ date('d-m-Y', strtotime($row->expiry_date)) }}
|
||||
@endif
|
||||
@endif
|
||||
</td>
|
||||
|
||||
|
||||
<td class="last col-md-1" style="width: 100px;">
|
||||
<span>
|
||||
<a href="" class="btn btn-xs btn-primary"><i class="fa fa-edit"></i></a>
|
||||
<input type="hidden" name="short_code_entry_id" value="{{ $row->id }}" class="shortCodeEntryRowId">
|
||||
<a href="" class="btn btn-xs btn-primary shortCodeEditBtn"><i class="fa fa-edit"></i></a>
|
||||
<a title="" data-val="{{ $row->id }}" class="btn btn-xs btn-danger removeCode"><i class="fa fa-trash"></i></a>
|
||||
</span>
|
||||
</td>
|
||||
@@ -52,4 +53,4 @@
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -1,52 +1,53 @@
|
||||
<div>
|
||||
<div class="table-responsive">
|
||||
<table class="table table-striped ">
|
||||
<thead>
|
||||
<tr class="headings">
|
||||
{{-- <th>#</th> --}}
|
||||
<th class="column-title">Name</th>
|
||||
<th class="column-title">Code</th>
|
||||
<th class="column-title">Network/Country</th>
|
||||
<th class="column-title">Toll Free</th>
|
||||
<th class="column-title">Status</th>
|
||||
<th class="column-title">Launch Date</th>
|
||||
<th class="column-title">Expiry Date</th>
|
||||
<th class="column-title no-link last"><span class="nobr">Action</span>
|
||||
</th>
|
||||
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
@if ($voice_codes->isEmpty())
|
||||
<tr>
|
||||
<td class="" colspan="12">No Records found</td>
|
||||
</tr>
|
||||
@else
|
||||
@foreach ($voice_codes as $row)
|
||||
<tr class="even pointer">
|
||||
<td class="mes-td col-md-2">{{ $row->name }}</td>
|
||||
<td class="mes-td col-md-1">{{ $row->shortcode }}</td>
|
||||
<td class="mes-td col-md-2">{{ $row->network }}</td>
|
||||
<td class="mes-td col-md-1">{{ $row->toll_free }}</td>
|
||||
<td class="mes-td col-md-1">{{ $row->status }}</td>
|
||||
<td class="mes-td col-md-1" style="width: 100px;">{{ date('d-m-Y', strtotime($row->launch_date)) }}</td>
|
||||
<td class="mes-td col-md-1" style="width: 100px;">
|
||||
@if($row->expiry_date == false)
|
||||
{{ "No found"}}
|
||||
@else
|
||||
{{ date('d-m-Y', strtotime($row->expiry_date)) }}
|
||||
@endif
|
||||
</td>
|
||||
<td class="last col-md-1" style="width: 100px;">
|
||||
<span>
|
||||
<a href="" class="btn btn-xs btn-primary"><i class="fa fa-edit"></i></a>
|
||||
<a title="" data-val="{{ $row->id }}" class="btn btn-xs btn-danger removeCode"><i class="fa fa-trash"></i></a>
|
||||
</span>
|
||||
</td>
|
||||
</tr>
|
||||
@endforeach
|
||||
@endif
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
<div class="table-responsive">
|
||||
<table class="table table-striped ">
|
||||
<thead>
|
||||
<tr class="headings">
|
||||
{{-- <th>#</th> --}}
|
||||
<th class="column-title">Name</th>
|
||||
<th class="column-title">Code</th>
|
||||
<th class="column-title">Network/Country</th>
|
||||
<th class="column-title">Toll Free</th>
|
||||
<th class="column-title">Status</th>
|
||||
<th class="column-title">Launch Date</th>
|
||||
<th class="column-title">Expiry Date</th>
|
||||
<th class="column-title no-link last"><span class="nobr">Action</span>
|
||||
</th>
|
||||
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
@if ($voice_codes->isEmpty())
|
||||
<tr>
|
||||
<td class="" colspan="12">No Records found</td>
|
||||
</tr>
|
||||
@else
|
||||
@foreach ($voice_codes as $row)
|
||||
<tr class="even pointer">
|
||||
<td class="mes-td col-md-2">{{ $row->name }}</td>
|
||||
<td class="mes-td col-md-1">{{ $row->shortcode }}</td>
|
||||
<td class="mes-td col-md-2">{{ $row->network }}</td>
|
||||
<td class="mes-td col-md-1">{{ $row->toll_free }}</td>
|
||||
<td class="mes-td col-md-1">{{ $row->status }}</td>
|
||||
<td class="mes-td col-md-1" style="width: 100px;">{{ date('d-m-Y', strtotime($row->launch_date)) }}</td>
|
||||
<td class="mes-td col-md-1" style="width: 100px;">
|
||||
@if($row->expiry_date == false)
|
||||
{{ "No found"}}
|
||||
@else
|
||||
{{ date('d-m-Y', strtotime($row->expiry_date)) }}
|
||||
@endif
|
||||
</td>
|
||||
<td class="last col-md-1" style="width: 100px;">
|
||||
<span>
|
||||
<input type="hidden" name="short_code_entry_id" value="{{ $row->id }}" class="shortCodeEntryRowId">
|
||||
<a href="" class="btn btn-xs btn-primary shortCodeEditBtn"><i class="fa fa-edit"></i></a>
|
||||
<a title="" data-val="{{ $row->id }}" class="btn btn-xs btn-danger removeCode"><i class="fa fa-trash"></i></a>
|
||||
</span>
|
||||
</td>
|
||||
</tr>
|
||||
@endforeach
|
||||
@endif
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -13,6 +13,7 @@
|
||||
@include('client.partials.edit-notes')
|
||||
@include('client.partials.finance')
|
||||
@include('client.partials.create-shortcodes')
|
||||
@include('client.partials.edit-shortcodes')
|
||||
@include('client.partials.edit-finance')
|
||||
@include('client.partials.progress_indicator_details')
|
||||
<?php ?>
|
||||
@@ -44,7 +45,7 @@
|
||||
<div id="crop-avatar">
|
||||
<!-- Current avatar -->
|
||||
@if($showclient->country_flag_info !== null)
|
||||
<img class="img-responsives avatar-views" src="{{ url($showclient->country_flag_info->url) }}" alt="Generic Client Icon" title="Country Flag" width="100px">
|
||||
<img class="img-responsives avatar-views" src="{{ url($showclient->country_flag_info->url) }}" alt="Generic Client Icon" title="Country Flag" width="100px">
|
||||
@else
|
||||
|
||||
<img class="img-responsive avatar-view" src="{{ url('public/assets/img/generic-client.png') }}" alt="Generic Client Icon" title="Change the avatar" width="100px">
|
||||
@@ -76,7 +77,7 @@
|
||||
<?php for ($i = 0; $i < $show_notes->count(); $i++) { ?>
|
||||
|
||||
<?php if ($show_notes[$i]->highlight == 'NO'): continue; endif; ?>
|
||||
<strong> {{ $i+1 . "." }}</strong> {{ $show_notes[$i]->notes_body }}
|
||||
<strong> {{ $i+1 . "." }}</strong> {{ $show_notes[$i]->notes_body }}
|
||||
<?php } ?>
|
||||
</span>
|
||||
</p>
|
||||
@@ -88,8 +89,8 @@
|
||||
<a class="btn btn-primary" href="{{ url('clients/onboarding', $showclient->id) }}"><i class="fa fa-edit m-right-xs"></i> Onboarding Checklist</a>
|
||||
@endif
|
||||
<a class="btn btn-primary" href="{{ url('clients/readonly/'. $showclient->id) }}"><i class="fa fa-eye m-right-xs"></i> Full Details (Readonly)</a>
|
||||
|
||||
<br />
|
||||
|
||||
<br />
|
||||
|
||||
<!-- start skills -->
|
||||
<!-- <h4>Finance</h4>
|
||||
@@ -97,7 +98,7 @@
|
||||
<li><i class="fa fa-phone user-profile-icon"></i> [Phone Number here]</li>
|
||||
<li><i class="fa fa-envelope user-profile-icon"></i> [email here] </li>
|
||||
<li class="m-top-xs"><i class="fa fa-skype user-profile-icon"></i> [Skype ID Here]</li>
|
||||
</ul> -->
|
||||
</ul> -->
|
||||
<!-- end of skills -->
|
||||
</div>
|
||||
<div class="col-md-9 col-sm-9 col-xs-12" style="border: 1px solid; min-height: 500px;">
|
||||
@@ -115,10 +116,10 @@
|
||||
<div id="myTabContent" class="tab-content">
|
||||
<div role="tabpanel" class="tab-pane fade active in" id="tabCompany" aria-labelledby="company-tab">
|
||||
<div class="col-md-4">
|
||||
|
||||
|
||||
|
||||
|
||||
<h4 class="lead"><strong>Company Details</strong></h4>
|
||||
|
||||
|
||||
<blockquote>
|
||||
<p>Country : <strong> {{ $showclient->country or "N/A" }}</strong></p>
|
||||
<p>Company Type : <strong> {{ $showclient->company_type or "N/A" }}</strong></p>
|
||||
@@ -135,12 +136,12 @@
|
||||
<p>SMPP Username : <em>
|
||||
<?php if($showclient->smpp_username) { echo $showclient->smpp_username; } else {echo "N/A"; } ?></em></p>
|
||||
<p>Message Types : <em>
|
||||
<?php if($showclient->message_types) {
|
||||
<?php if($showclient->message_types) {
|
||||
$types_array = json_decode($showclient->message_types);
|
||||
echo implode(', ', $types_array);
|
||||
}
|
||||
echo implode(', ', $types_array);
|
||||
}
|
||||
else {
|
||||
echo "N/A";
|
||||
echo "N/A";
|
||||
} ?>
|
||||
</em>
|
||||
</p>
|
||||
@@ -151,13 +152,13 @@
|
||||
<h4 class="lead"><strong>Support Phone(s)</strong></h4>
|
||||
@if(!empty($showclient->support_phones))
|
||||
<blockquote>
|
||||
<?php
|
||||
<?php
|
||||
$the_arr = json_decode($showclient->support_phones, true) ?>
|
||||
<ul>
|
||||
<?php foreach ($the_arr as $row): ?>
|
||||
|
||||
|
||||
<li>{{ $row }}</li>
|
||||
|
||||
|
||||
<?php endforeach ?>
|
||||
</ul>
|
||||
</blockquote>
|
||||
@@ -167,13 +168,13 @@
|
||||
<h4 class="lead"><strong>Support Email(s)</strong></h4>
|
||||
@if(!empty($showclient->support_emails))
|
||||
<blockquote>
|
||||
<?php
|
||||
<?php
|
||||
$the_arr = json_decode($showclient->support_emails, true) ?>
|
||||
<ul>
|
||||
<?php foreach ($the_arr as $row): ?>
|
||||
|
||||
|
||||
<li>{{ $row }}</li>
|
||||
|
||||
|
||||
<?php endforeach ?>
|
||||
</ul>
|
||||
</blockquote>
|
||||
@@ -183,13 +184,13 @@
|
||||
@if(!empty($showclient->rate_emails))
|
||||
<h4 class="lead"><strong>Rates Email(s)</strong></h4>
|
||||
<blockquote>
|
||||
<?php
|
||||
<?php
|
||||
$the_arr = json_decode($showclient->rate_emails, true) ?>
|
||||
<ul>
|
||||
<?php foreach ($the_arr as $row): ?>
|
||||
|
||||
|
||||
<li>{{ $row }}</li>
|
||||
|
||||
|
||||
<?php endforeach ?>
|
||||
</ul>
|
||||
</blockquote>
|
||||
@@ -199,39 +200,39 @@
|
||||
<h4 class="lead"><strong>Finance Email(s)</strong></h4>
|
||||
@if(!empty($showclient->finance_email))
|
||||
<blockquote>
|
||||
<?php
|
||||
<?php
|
||||
$the_arr = json_decode($showclient->finance_email, true) ?>
|
||||
<ul>
|
||||
<?php foreach ($the_arr as $row): ?>
|
||||
|
||||
|
||||
<li>{{ $row }}</li>
|
||||
|
||||
|
||||
<?php endforeach ?>
|
||||
</ul>
|
||||
</blockquote>
|
||||
@else
|
||||
N/A
|
||||
N/A
|
||||
@endif
|
||||
|
||||
|
||||
</div>
|
||||
<div class="col-md-4">
|
||||
<h4 class="lead"><strong>Support Skype ID(s)</strong></h4>
|
||||
@if(!empty($showclient->support_skype))
|
||||
<blockquote>
|
||||
<?php
|
||||
<?php
|
||||
$the_arr = json_decode($showclient->support_skype, true) ?>
|
||||
<ul>
|
||||
<?php foreach ($the_arr as $row): ?>
|
||||
|
||||
|
||||
<li>{{ $row }}</li>
|
||||
|
||||
|
||||
<?php endforeach ?>
|
||||
</ul>
|
||||
</blockquote>
|
||||
@else
|
||||
N/A
|
||||
N/A
|
||||
@endif
|
||||
<div class="well">
|
||||
<div class="well">
|
||||
<h4>How We Got This Client</h4>
|
||||
<?php echo $showclient->how_we_got_client ?? "N/A" ?>
|
||||
</div>
|
||||
@@ -289,7 +290,7 @@
|
||||
</div>
|
||||
<div class="clearfix"></div>
|
||||
<div style="background-color: #dce2e4; height: 400px; overflow: scroll;">
|
||||
|
||||
|
||||
<ul class="messages list-group" style="padding: 15px;">
|
||||
@if($show_notes->isEmpty())
|
||||
<li style="" class="">No notes found</li>
|
||||
@@ -350,7 +351,7 @@
|
||||
<script src="{{ url('public/assets/vendors/iCheck/icheck.min.js') }}"></script>
|
||||
<script src="{{ url('public/assets/js/clientshow.js') }}"></script>
|
||||
<script type="text/javascript">
|
||||
|
||||
|
||||
// iCheck
|
||||
$(document).ready(function() {
|
||||
if ($("input.flat")[0]) {
|
||||
@@ -398,4 +399,4 @@ $('.bulk_action input#check-all').on('ifUnchecked', function () {
|
||||
});
|
||||
|
||||
</script>
|
||||
@endsection
|
||||
@endsection
|
||||
|
||||
166
resources/views/utility/arraylogic.blade.php
Normal file
166
resources/views/utility/arraylogic.blade.php
Normal file
@@ -0,0 +1,166 @@
|
||||
@extends('layouts.master')
|
||||
@section('page_title')
|
||||
@if(isset($page_title))
|
||||
{{ $page_title }}
|
||||
@endif
|
||||
@endsection
|
||||
@section('css')
|
||||
<!-- JQVMap -->
|
||||
|
||||
@endsection
|
||||
@section('content')
|
||||
<div class="">
|
||||
<div class="page-title">
|
||||
<div class="title_left">
|
||||
<div class="title_left">
|
||||
<ol class="breadcrumb">
|
||||
<li><a href="{!! url('dashboard') !!}">Dashboard</a></li>
|
||||
<!-- <li class=""><a href=""> Reports</a></li> -->
|
||||
<li class="active">Client Payments</li>
|
||||
</ol>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="title_right">
|
||||
<div class="row">
|
||||
<form method="GET" action="{!! url('clientpaymentreports') !!}">
|
||||
<div class="col-md-5 col-sm-5 col-xs-12 form-group">
|
||||
<div style="margin-top:1px; margin-right:-90px;" class="top_search">
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-5 col-sm-5 col-xs-12 form-group pull-right top_search" style="margin-top: -2px;">
|
||||
<div class="input-group">
|
||||
<input type="text" name="keyword" class="form-control" id="keywordField" placeholder="Keyword here...">
|
||||
<span class="input-group-btn">
|
||||
<button type="submit" class="btn btn-primary" style="color: #fff;" type="button">Go!</button>
|
||||
</span>
|
||||
</div>
|
||||
</div>
|
||||
</form>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="clearfix"></div>
|
||||
<div class="row">
|
||||
@include('commons.notifications')
|
||||
<div class="col-md-12 col-sm-12 col-xs-12">
|
||||
<div class="x_panel">
|
||||
<div class="x_title">
|
||||
<h2> Testing </h2>
|
||||
<div class="clearfix"></div>
|
||||
</div>
|
||||
|
||||
<div class="x_content">
|
||||
<div class="row">
|
||||
<div class="col-md-12">
|
||||
<div class="x_panel">
|
||||
<div class="x_title">
|
||||
<h2>Transaction Summary <small>Weekly progress</small></h2>
|
||||
<div class="filter">
|
||||
<div id="reportrange" class="pull-right" style="background: #fff; cursor: pointer; padding: 5px 10px; border: 1px solid #ccc">
|
||||
<i class="glyphicon glyphicon-calendar fa fa-calendar"></i>
|
||||
<span>December 30, 2014 - January 28, 2015</span> <b class="caret"></b>
|
||||
</div>
|
||||
</div>
|
||||
<div class="clearfix"></div>
|
||||
</div>
|
||||
<div class="x_content">
|
||||
<div class="col-md-9 col-sm-12 col-xs-12">
|
||||
<div class="demo-container" style="height:280px">
|
||||
<div id="chart_plot_02" class="demo-placeholder"></div>
|
||||
</div>
|
||||
<div class="tiles">
|
||||
<div class="col-md-4 tile">
|
||||
<span>Total Sessions</span>
|
||||
<h2>231,809</h2>
|
||||
<span class="sparkline11 graph" style="height: 160px;">
|
||||
<canvas width="200" height="60" style="display: inline-block; vertical-align: top; width: 94px; height: 30px;"></canvas>
|
||||
</span>
|
||||
</div>
|
||||
<div class="col-md-4 tile">
|
||||
<span>Total Revenue</span>
|
||||
<h2>$231,809</h2>
|
||||
<span class="sparkline22 graph" style="height: 160px;">
|
||||
<canvas width="200" height="60" style="display: inline-block; vertical-align: top; width: 94px; height: 30px;"></canvas>
|
||||
</span>
|
||||
</div>
|
||||
<div class="col-md-4 tile">
|
||||
<span>Total Sessions</span>
|
||||
<h2>231,809</h2>
|
||||
<span class="sparkline11 graph" style="height: 160px;">
|
||||
<canvas width="200" height="60" style="display: inline-block; vertical-align: top; width: 94px; height: 30px;"></canvas>
|
||||
</span>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="col-md-3 col-sm-12 col-xs-12">
|
||||
<div>
|
||||
<div class="x_title">
|
||||
<h2>Top Profiles</h2>
|
||||
<ul class="nav navbar-right panel_toolbox">
|
||||
<li><a class="collapse-link"><i class="fa fa-chevron-up"></i></a>
|
||||
</li>
|
||||
<li class="dropdown">
|
||||
<a href="#" class="dropdown-toggle" data-toggle="dropdown" role="button" aria-expanded="false"><i class="fa fa-wrench"></i></a>
|
||||
<ul class="dropdown-menu" role="menu">
|
||||
<li><a href="#">Settings 1</a>
|
||||
</li>
|
||||
<li><a href="#">Settings 2</a>
|
||||
</li>
|
||||
</ul>
|
||||
</li>
|
||||
<li><a class="close-link"><i class="fa fa-close"></i></a>
|
||||
</li>
|
||||
</ul>
|
||||
<div class="clearfix"></div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@endsection
|
||||
|
||||
@section('javascript')
|
||||
|
||||
|
||||
|
||||
<script type="text/javascript">
|
||||
$(document).ready(function(){
|
||||
|
||||
// $('#financeServicesStore').change(function(evtt){
|
||||
console.log('we have changed');
|
||||
var currentServices =['USSD', 'SMS', 'IVR', 'Hosting', 'Ninped'];
|
||||
console.log(currentServices);
|
||||
// var myarr = ["USSD", "like", "turtles"];
|
||||
var selected_services = ["USSD", "SMS"]
|
||||
// var checkArray = $.inArray(selected_services, currentServices) > -1;
|
||||
// console.log(checkArray);
|
||||
// var success = selected_services.every(function(val) {
|
||||
// return currentServices.indexOf(val) !== -1;
|
||||
// });
|
||||
// var success = $.grep(currentServices, function(v,i) {
|
||||
// return $.inArray(v, selected_services) !== -1;
|
||||
// }).length === selected_services.length;
|
||||
let success = selected_services.every((val) => currentServices.includes(val));
|
||||
console.log(success);
|
||||
// });
|
||||
//
|
||||
|
||||
});
|
||||
</script>
|
||||
@endsection
|
||||
@@ -22,12 +22,17 @@ Auth::routes();
|
||||
|
||||
Route::get('/home', 'HomeController@index')->name('home');
|
||||
*/
|
||||
// Route::post('testjs', 'UtilityController@showPage');
|
||||
// Route::get('/testjs', function () {
|
||||
// return view('contacts');
|
||||
// return view('utility.arraylogic');
|
||||
// });
|
||||
//Route::post('ipstore', 'NetworkOperatorsController@ipStore');
|
||||
|
||||
Route::get('testemail', 'UtilityController@EmailTest');
|
||||
Route::get('testmno', 'ContractRenewalReminderController@getMnos');
|
||||
Route::get('ntfy', 'UtilityController@ntfyTest');
|
||||
Route::get('client-renewal', 'ClientContractRenewalAlertsController@getClientDetails');
|
||||
//Route::get('testemail', 'UtilityController@EmailTest');
|
||||
//Route::get('testmno', 'ContractRenewalReminderController@getMnos');
|
||||
//Route::get('ntfy', 'UtilityController@ntfyTest');
|
||||
//Route::get('client-renewal', 'ClientContractRenewalAlertsController@getClientDetails');
|
||||
//insertOnboardingProgress
|
||||
|
||||
|
||||
@@ -94,8 +99,10 @@ Route::group(['middleware' => ['checklogin', 'checkcurrentlylogged']], function(
|
||||
Route::post('clients/notes_store', 'ClientsController@notesStore');
|
||||
Route::post('clients/finance_store', 'ClientsController@financeStore');
|
||||
Route::post('clients/finance_update', 'ClientsController@financeUpdate');
|
||||
Route::post('clients/shortcode_update', 'ClientsController@shortCodeUpdate');
|
||||
|
||||
Route::get('clients/get_payment/{id}', 'ClientsController@getPayment');
|
||||
Route::get('clients/get_shortcode/{id}', 'ClientsController@getShortCodeDetails');
|
||||
Route::get('clients/get_note/{id}', 'ClientsController@getSingleNote');
|
||||
Route::get('clients/create-notes', 'ClientsController@createNotes');
|
||||
Route::get('clients/shortcodes/{type}', 'ClientsController@getShortCodes');
|
||||
|
||||
1
storage/laravel-2024-06-11.log
Normal file
1
storage/laravel-2024-06-11.log
Normal file
@@ -0,0 +1 @@
|
||||
[2024-06-11 21:10:55] production.INFO: Kwesi Banson Successfully logged in at : 2024-06-11 21:10:55
|
||||
Reference in New Issue
Block a user