Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Sign in
Toggle navigation
K
kiaisoft_tuananh_nuxt
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
1
Issues
1
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
TTS Tran Viet Anh
kiaisoft_tuananh_nuxt
Commits
fd18168c
Commit
fd18168c
authored
Feb 01, 2023
by
Kemm23
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix UI
parent
ef3630f7
Changes
3
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
454 additions
and
307 deletions
+454
-307
admin.vue
layouts/admin.vue
+2
-2
index.vue
pages/categories/index.vue
+337
-191
index.vue
pages/users/index.vue
+115
-114
No files found.
layouts/admin.vue
View file @
fd18168c
<
template
>
<
div
>
<
v-app
>
<NavBar
/>
<nuxt
/>
</
div
>
</
v-app
>
</
template
>
<
script
>
...
...
pages/categories/index.vue
View file @
fd18168c
This diff is collapsed.
Click to expand it.
pages/users/index.vue
View file @
fd18168c
<!-- eslint-disable vue/valid-v-slot -->
<
template
>
<v-app>
<div>
<div
/>
<div>
<v-breadcrumbs
:items=
"items"
>
<template
#divider
>
<v-icon>
mdi-chevron-right
</v-icon>
</
template
>
</v-breadcrumbs>
</div>
<div
style=
"float: right"
>
<div>
<v-breadcrumbs
:items=
"items"
>
<template
#divider
>
<v-icon>
mdi-chevron-right
</v-icon>
</
template
>
</v-breadcrumbs>
</div>
<div
style=
"float: right"
>
<v-dialog
v-model=
"dialog1"
persistent
max-width=
"600px"
@
submit.prevent=
"createUser"
>
<
template
#activator
="{
on
,
attrs
}"
>
<v-btn
color=
"primary"
dark
v-bind=
"attrs"
v-on=
"on"
>
New USER
</v-btn>
</
template
>
<v-card>
<v-card-title>
<span
class=
"text-h5"
>
User Profile
</span>
</v-card-title>
<v-card-text>
<v-container>
<v-row>
<v-col
cols=
"12"
sm=
"6"
md=
"4"
>
<v-text-field
v-model=
"name"
label=
"Legal name*"
required
/>
</v-col>
<v-col
cols=
"12"
>
<v-text-field
v-model=
"email"
label=
"Email*"
required
/>
</v-col>
<v-col
cols=
"12"
>
<v-text-field
v-model=
"password"
label=
"Password*"
type=
"password"
required
/>
</v-col>
</v-row>
</v-container>
<small>
*indicates required field
</small>
</v-card-text>
<v-card-actions>
<v-spacer
/>
<v-btn
color=
"blue darken-1"
text
@
click=
"dialog1 = false"
>
Close
</v-btn>
<v-btn
color=
"blue darken-1"
text
type=
"submit"
@
click=
"dialog1 = false; createUser();"
>
Save
</v-btn>
</v-card-actions>
</v-card>
</v-dialog>
</div>
<!-- modal-create -->
<v-dialog
v-model=
"dialog
1
"
v-model=
"dialog
2
"
persistent
max-width=
"600px"
@
submit.prevent=
"createUser"
>
<
template
#activator
="{
on
,
attrs
}"
>
<v-btn
color=
"primary"
dark
v-bind=
"attrs"
v-on=
"on"
>
New USER
</v-btn>
</
template
>
<v-card>
<v-card-title>
<span
class=
"text-h5"
>
User
Profile
</span>
<span
class=
"text-h5"
>
User
Edit
</span>
</v-card-title>
<v-card-text>
<v-container>
...
...
@@ -39,21 +103,21 @@
md=
"4"
>
<v-text-field
v-model=
"
n
ame"
v-model=
"
eN
ame"
label=
"Legal name*"
required
/>
</v-col>
<v-col
cols=
"12"
>
<v-text-field
v-model=
"email"
v-model=
"e
E
mail"
label=
"Email*"
required
/>
</v-col>
<v-col
cols=
"12"
>
<v-text-field
v-model=
"
p
assword"
v-model=
"
eP
assword"
label=
"Password*"
type=
"password"
required
...
...
@@ -68,7 +132,7 @@
<v-btn
color=
"blue darken-1"
text
@
click=
"dialog
1
= false"
@
click=
"dialog
2
= false"
>
Close
</v-btn>
...
...
@@ -76,101 +140,38 @@
color=
"blue darken-1"
text
type=
"submit"
@
click=
"dialog
1 = false; cre
ateUser();"
@
click=
"dialog
2 = false; upd
ateUser();"
>
Save
</v-btn>
</v-card-actions>
</v-card>
</v-dialog>
</div>
<!-- modal-create -->
<v-dialog
v-model=
"dialog2"
persistent
max-width=
"600px"
>
<v-card>
<v-card-title>
<span
class=
"text-h5"
>
User Edit
</span>
</v-card-title>
<v-card-text>
<v-container>
<v-row>
<v-col
cols=
"12"
sm=
"6"
md=
"4"
>
<v-text-field
v-model=
"eName"
label=
"Legal name*"
required
/>
</v-col>
<v-col
cols=
"12"
>
<v-text-field
v-model=
"eEmail"
label=
"Email*"
required
/>
</v-col>
<v-col
cols=
"12"
>
<v-text-field
v-model=
"ePassword"
label=
"Password*"
type=
"password"
required
/>
</v-col>
</v-row>
</v-container>
<small>
*indicates required field
</small>
</v-card-text>
<v-card-actions>
<v-spacer
/>
<v-btn
color=
"blue darken-1"
text
@
click=
"dialog2 = false"
>
Close
</v-btn>
<v-btn
color=
"blue darken-1"
text
type=
"submit"
@
click=
"dialog2 = false; updateUser();"
>
Save
<v-data-table
:headers=
"headers"
:items=
"users"
sort-by=
"calories"
class=
"elevation-1"
>
<
template
#top
>
<v-toolbar
flat
>
<v-toolbar-title>
User Manage
</v-toolbar-title>
<v-divider
class=
"mx-4"
inset
vertical
/>
<v-spacer
/>
</v-toolbar>
</
template
>
// eslint-disable-next-line vue/valid-v-slot
<
template
#item.actions=
"{ item }"
>
<v-icon
:id=
"item.id"
small
class=
"mr-2"
@
click=
"dialog2 = true; editUser(item);"
>
mdi-pencil
</v-icon>
<v-icon
:id=
"item.id"
small
@
click=
"deleteUser(item.id, item)"
>
mdi-delete
</v-icon>
</
template
>
<
template
#no-data
>
<v-btn
color=
"primary"
@
click=
"initialize"
>
Reset
</v-btn>
</v-card-actions>
</v-card>
</v-dialog>
<v-data-table
:headers=
"headers"
:items=
"users"
sort-by=
"calories"
class=
"elevation-1"
>
<
template
#top
>
<v-toolbar
flat
>
<v-toolbar-title>
User Manage
</v-toolbar-title>
<v-divider
class=
"mx-4"
inset
vertical
/>
<v-spacer
/>
</v-toolbar>
</
template
>
<
template
#item.actions=
"{ item }"
>
<v-icon
:id=
"item.id"
small
class=
"mr-2"
@
click=
"dialog2 = true; editUser(item);"
>
mdi-pencil
</v-icon>
<v-icon
:id=
"item.id"
small
@
click=
"deleteUser(item.id, item)"
>
mdi-delete
</v-icon>
</
template
>
<
template
#no-data
>
<v-btn
color=
"primary"
@
click=
"initialize"
>
Reset
</v-btn>
</
template
>
</v-data-table>
</div>
</v-app>
</
template
>
</v-data-table>
</div>
</v-app>
</template>
<
script
>
export
default
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment