-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Complete order edit functions and payment status edit for can manage …
…users
- Loading branch information
1 parent
3b7633a
commit da0cfb9
Showing
4 changed files
with
97 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
24 changes: 24 additions & 0 deletions
24
database/migrations/2024_06_18_122735_addfailedtopayments.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
<?php | ||
|
||
use Illuminate\Database\Migrations\Migration; | ||
use Illuminate\Database\Schema\Blueprint; | ||
use Illuminate\Support\Facades\Schema; | ||
|
||
return new class extends Migration | ||
{ | ||
/** | ||
* Run the migrations. | ||
*/ | ||
public function up(): void | ||
{ | ||
// | ||
} | ||
|
||
/** | ||
* Reverse the migrations. | ||
*/ | ||
public function down(): void | ||
{ | ||
// | ||
} | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,39 @@ | ||
<div> | ||
{{-- If you look to others for fulfillment, you will never truly be fulfilled. --}} | ||
<div class="max-w-7xl mx-auto py-10 sm:px-6 lg:px-8"> | ||
<div class="bg-white shadow overflow-hidden sm:rounded-lg p-6"> | ||
<h3 class="text-lg font-medium text-gray-900 mb-4">Edit Order</h3> | ||
|
||
@if (session()->has('message')) | ||
<div class="bg-green-500 text-white p-4 mb-4 rounded"> | ||
{{ session('message') }} | ||
</div> | ||
@endif | ||
|
||
<form wire:submit.prevent="save"> | ||
<div class="mb-4"> | ||
<label for="status" class="block text-sm font-medium text-gray-700">Order Status</label> | ||
<select id="status" wire:model="status" class="mt-1 block w-full pl-3 pr-10 py-2 text-base border-gray-300 focus:outline-none focus:ring-indigo-500 focus:border-indigo-500 sm:text-sm rounded-md"> | ||
<option value="in-progress">In Progress</option> | ||
<option value="completed">Completed</option> | ||
<option value="pending">Pending</option> | ||
</select> | ||
@error('status') <span class="text-red-500 text-sm">{{ $message }}</span> @enderror | ||
</div> | ||
|
||
<div class="mb-4"> | ||
<label for="paymentStatus" class="block text-sm font-medium text-gray-700">Payment Status</label> | ||
<select id="paymentStatus" wire:model="paymentStatus" class="mt-1 block w-full pl-3 pr-10 py-2 text-base border-gray-300 focus:outline-none focus:ring-indigo-500 focus:border-indigo-500 sm:text-sm rounded-md"> | ||
<option value="pending">Pending</option> | ||
<option value="completed">Completed</option> | ||
<option value="failed">Failed</option> | ||
</select> | ||
@error('paymentStatus') <span class="text-red-500 text-sm">{{ $message }}</span> @enderror | ||
</div> | ||
|
||
<div class="flex items-center justify-end mt-4"> | ||
<button type="submit" class="bg-blue-500 hover:bg-blue-700 text-white font-bold py-2 px-4 rounded"> | ||
Save Changes | ||
</button> | ||
</div> | ||
</form> | ||
</div> | ||
</div> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters