- Updated `payOrder` method in `OrderControllerRefactor` to accept `orderNum` instead of `id` for better clarity and functionality. - Implemented `findByOrderNum` method in `OrderRepository` to retrieve orders based on order number and customer ID. - Enhanced `InvoiceDetailResource` to include VMware details and removed unnecessary fields. - Added `service_plan_id` to `ProductResource` and updated the `Product` model to establish a relationship with `ServicePlan`. - Created `ServicePlan` and `ServicePlanPlesk` models along with their respective controllers and migrations for managing hosting service plans. - Updated API routes to include endpoints for managing service plans. - Modified email templates to standardize support phone number across various customer communications.
22 lines
320 B
PHP
22 lines
320 B
PHP
<?php
|
|
|
|
namespace App\Models;
|
|
|
|
use Illuminate\Database\Eloquent\Model;
|
|
|
|
class ServicePlan extends Model
|
|
{
|
|
protected $fillable = [
|
|
'title',
|
|
'vcpu',
|
|
'ram',
|
|
'disk',
|
|
'domain',
|
|
];
|
|
|
|
public function plesk()
|
|
{
|
|
return $this->hasOne(ServicePlanPlesk::class);
|
|
}
|
|
}
|