new commit
This commit is contained in:
@@ -2,6 +2,7 @@
|
||||
|
||||
namespace App\Http\Controllers;
|
||||
|
||||
use App\Models\Services;
|
||||
use Illuminate\Http\Request;
|
||||
use App\Models\Categories;
|
||||
use SebastianBergmann\CodeCoverage\Report\Xml\Project;
|
||||
@@ -29,11 +30,15 @@ class CategoriesController extends Controller
|
||||
$name = $request->get(key:'name');
|
||||
$description = $request->get(key:'description');
|
||||
$creatoruserId = 1;
|
||||
$price = 1;
|
||||
$category_id = 1;
|
||||
|
||||
$Services = new Services();
|
||||
$Services->name = $name;
|
||||
$Services->description = $description;
|
||||
$Services->category_id = $category_id;
|
||||
$Services->price = $price;
|
||||
$Services->duration_minutes = 1;
|
||||
$Services->save();
|
||||
|
||||
return response()->json($Services->tojson());
|
||||
|
||||
Reference in New Issue
Block a user