diff --git a/README.md b/README.md index bd70ca5..6778cec 100644 --- a/README.md +++ b/README.md @@ -12,18 +12,22 @@ Cash on delivery (COD) is a type of transaction in which the recipient makes payment for a good at the time of delivery. If the purchaser does not make payment when the good is delivered, the good is returned to the seller. The COD method is used by many businesses that sell goods through a catalog or online. - - # How to Install - ``` NexaMerchant\CheckoutCod\Providers\CheckoutCodServiceProvider::class, ``` Add it to config/app.php $providers -# How to Publish +# How to Install with Composer ``` composer require nexa-merchant/checkoutcod -``` \ No newline at end of file +``` + +# How to Publish the Config file + +```bash +php artisan vendor:publish --provider="NexaMerchant\CheckoutCod\Providers\CheckoutCodServiceProvider" +``` + diff --git a/src/Config/CheckoutCod.php b/src/Config/CheckoutCod.php index 12308d5..23030f2 100644 --- a/src/Config/CheckoutCod.php +++ b/src/Config/CheckoutCod.php @@ -17,12 +17,12 @@ * * The version of the package */ - 'version' => '1.0.3', + 'version' => '1.0.4', /** * * The version number of the package */ - 'versionNum' => '103', + 'versionNum' => '104', /** * @@ -85,4 +85,10 @@ 'email' => 'email@example.com', 'issues' => 'https://github.com/xxl4' ], + + /** + * + * financial_status pending + */ + 'financial_status' => 'pending', ]; \ No newline at end of file diff --git a/src/Database/Migrations/2024_11_04_133219_add_checkout_cod_orders.php b/src/Database/Migrations/2024_11_04_133219_add_checkout_cod_orders.php new file mode 100644 index 0000000..aaea790 --- /dev/null +++ b/src/Database/Migrations/2024_11_04_133219_add_checkout_cod_orders.php @@ -0,0 +1,32 @@ +id(); + $table->unsignedBigInteger("order_id")->comment("Order ID"); + // add create and update datetime + $table->timestamps(); + $table->foreign("order_id")->references("id")->on("orders")->onDelete("cascade"); + }); + } + + /** + * Reverse the migrations. + */ + public function down(): void + { + // + Schema::dropIfExists("orders_cod"); + } +};