-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Working on showing the Users of a Segment re-using the user table component. - Ran pint and lint - Fixed the route issue
- Loading branch information
Showing
9 changed files
with
199 additions
and
105 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
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
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,31 @@ | ||
<?php | ||
|
||
namespace App\Http\Controllers; | ||
|
||
use App\Domain\Segment\Models\Segment; | ||
use Illuminate\Http\Request; | ||
|
||
class SegmentUserController extends Controller | ||
{ | ||
public function index(Segment $segment) | ||
{ | ||
$users = $segment->customers()->paginate(10); | ||
|
||
return inertia('SegmentUser/Index', [ | ||
'segment' => $segment, | ||
'users' => $users, | ||
]); | ||
} | ||
|
||
public function create() {} | ||
|
||
public function store(Request $request) {} | ||
|
||
public function show($id) {} | ||
|
||
public function edit($id) {} | ||
|
||
public function update(Request $request, $id) {} | ||
|
||
public function destroy($id) {} | ||
} |
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
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
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
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
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,37 @@ | ||
<script setup> | ||
import PageContainer from '../../Components/PageContainer.vue' | ||
import Breadcrumb from '../../Components/Breadcrumb.vue' | ||
import PageTitle from '../../Components/PageTitle.vue' | ||
import UserTable from '../User/UserTable.vue' | ||
const { users, segment } = defineProps({ | ||
users: { | ||
type: Object, | ||
required: true | ||
}, | ||
segment: { | ||
type: Object, | ||
required: true | ||
} | ||
}) | ||
const breadCrumb = [{ name: 'Notifications', link: route('user.index') }] | ||
</script> | ||
|
||
<template> | ||
<div> | ||
<PageContainer> | ||
<div class="mb-4"> | ||
<Breadcrumb :links="breadCrumb" /> | ||
<PageTitle title="Customers in this segment" /> | ||
</div> | ||
|
||
<div | ||
class="items-center justify-between block sm:flex md:divide-x md:divide-gray-100 dark:divide-gray-700" | ||
> | ||
<div class="flex items-center mb-4 sm:mb-0"></div> | ||
</div> | ||
</PageContainer> | ||
|
||
<UserTable :users="users" /> | ||
</div> | ||
</template> |
Oops, something went wrong.