integarting admin dashboard

This commit is contained in:
UronShrestha
2024-07-12 12:51:02 +05:45
parent 2510de390a
commit 1550ab5d30
1758 changed files with 313760 additions and 10 deletions

View File

@ -0,0 +1,13 @@
<?php
namespace App\Http\Controllers;
use Illuminate\Http\Request;
class AdminController extends Controller
{
public function admin()
{
return view('Dashboard.index');
}
}

View File

@ -60,6 +60,8 @@ class OnboardingConversation extends Conversation
{
$this->ask('Can you tell us your email?', function (Answer $answer) {
$this->email = $answer->getText();
// Validate Email
if (filter_var($this->email, FILTER_VALIDATE_EMAIL)) {
$this->say("Your email is " . $this->email);
$this->confirmEmail();
@ -74,7 +76,7 @@ class OnboardingConversation extends Conversation
{
$this->ask('Confirm your Email (Y/N):', function (Answer $answer) {
$confirmEmail = $answer->getText();
if (strtolower($confirmEmail) == 'y') {
if (strtolower($confirmEmail) == 'y' || strtolower($confirmEmail) == 'yes') {
$this->say("We got your details. Thank you!");
// Save the details to the database
@ -83,7 +85,7 @@ class OnboardingConversation extends Conversation
'phone_number' => $this->phoneNumber,
'email' => $this->email,
]);
} elseif (strtolower($confirmEmail) == 'n') {
} elseif (strtolower($confirmEmail) == 'n' || strtolower($confirmEmail) == 'no') {
$this->say("Please confirm your email.");
$this->askEmail(); // Re-ask for the email
} else {

View File

@ -233,14 +233,6 @@ class MainController extends Controller
}
public function checkout(Request $data)
{
if (session()->has('id')) {