Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Q
quasar-web-base
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
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
Nguyễn Hải Sơn
quasar-web-base
Commits
7109f100
Commit
7109f100
authored
Mar 27, 2023
by
Nguyễn Đức Thắng
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
update
parent
1a359cee
Changes
6
Show whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
42 additions
and
44 deletions
+42
-44
type.ts
src/assets/type.ts
+6
-7
index.vue
src/components/customer/add-new-customer-dialog/index.vue
+1
-3
UpdateNewCustomerDialog.ts
...mer/update-new-customer-dialog/UpdateNewCustomerDialog.ts
+4
-3
index.vue
src/components/customer/update-new-customer-dialog/index.vue
+3
-3
index.vue
src/components/detailBooking/index.vue
+5
-5
index.vue
src/pages/khach-hang/index.vue
+23
-23
No files found.
src/assets/type.ts
View file @
7109f100
...
...
@@ -154,14 +154,12 @@ export type ProvinceType = {
level
:
string
;
};
export
type
Coordinates
=
{
image
:
{
src
:
string
}
canvas
:
any
}
src
:
string
;
};
canvas
:
any
;
};
export
type
MusicType
=
{
id
:
number
;
...
...
@@ -370,6 +368,7 @@ export type CustomerLevelType = {
description
:
string
;
level
:
string
;
status
:
number
;
levelId
:
number
;
};
export
type
CustomerRank
=
{
...
...
@@ -481,7 +480,7 @@ export type PostDetailType = {
createTime
?:
string
;
updateBy
?:
string
;
updateTime
?:
string
;
filePost
:
string
filePost
:
string
;
};
export
type
PostCategoryDetailType
=
{
...
...
src/components/customer/add-new-customer-dialog/index.vue
View file @
7109f100
...
...
@@ -11,7 +11,7 @@
<q-item-section>
<q-item-label
class=
"text-h6 text-weight-regular"
>
{{
$t
(
'customer.dialogLabel.title.addCustomer'
)
}}
</q-item-label>
}}
</q-item-label>
</q-item-section>
</q-item>
</q-card-section>
...
...
@@ -121,8 +121,6 @@
:options=
"levelOptions"
:rules=
"levelRules"
map-options
option-value=
"id"
option-label=
"name"
type=
"text"
class=
"q-my-sm"
outlined
...
...
src/components/customer/update-new-customer-dialog/UpdateNewCustomerDialog.ts
View file @
7109f100
...
...
@@ -39,7 +39,7 @@ export default defineComponent({
const
type
:
Ref
<
string
|
null
>
=
ref
(
null
);
const
representative
:
Ref
<
string
|
null
>
=
ref
(
null
);
const
position
:
Ref
<
string
|
null
>
=
ref
(
null
);
const
level
:
Ref
<
CustomerLevelType
|
null
>
=
ref
(
null
);
const
level
=
ref
(
null
);
const
confirmEditCustomer
=
()
=>
{
context
.
emit
(
'editCustomer'
,
{
...
...
@@ -75,6 +75,9 @@ export default defineComponent({
type
.
value
=
props
.
customerInfo
.
type
;
representative
.
value
=
props
.
customerInfo
.
representative
;
position
.
value
=
props
.
customerInfo
.
position
;
// eslint-disable-next-line
// @ts-ignore
// eslint-disable-next-line
level
.
value
=
props
.
customerInfo
.
level
;
};
// const userNameRules = [
...
...
@@ -96,7 +99,6 @@ export default defineComponent({
// i18n.global.t('customer.validateMessages.lengthCode'),
// ];
const
customerNameRules
=
[
(
val
?:
string
)
=>
(
val
&&
val
.
trim
().
length
)
||
...
...
@@ -106,7 +108,6 @@ export default defineComponent({
i18n
.
global
.
t
(
'customer.validateMessages.lengthCustomerName'
),
];
// const businessNameRules = [
// (val?: string) =>
// (val && val.trim().length) ||
...
...
src/components/customer/update-new-customer-dialog/index.vue
View file @
7109f100
...
...
@@ -11,7 +11,7 @@
<q-item-section>
<q-item-label
class=
"text-h6 text-weight-regular"
>
{{
$t
(
'customer.dialogLabel.title.editCustomer'
)
}}
</q-item-label>
}}
122
</q-item-label>
</q-item-section>
</q-item>
</q-card-section>
...
...
@@ -122,12 +122,12 @@
:options=
"levelOptions"
:rules=
"levelRules"
map-options
option-value=
"id"
option-label=
"name"
type=
"text"
class=
"q-my-sm"
outlined
clearable
hide-bottom-space
></q-select>
...
...
src/components/detailBooking/index.vue
View file @
7109f100
...
...
@@ -12,7 +12,7 @@
<q-item-label
class=
"text-h6 text-weight-regular"
style=
"text-align: center"
>
{{
$t
(
'listBooking.dialogLabel.title'
)
}}
</q-item-label
>
{{
$t
(
'listBooking.dialogLabel.title'
)
}}
</q-item-label
>
</q-item-section>
</q-item>
...
...
@@ -133,11 +133,11 @@
</div>
</div>
<v-row>
<
!--
<
v-row>
<v-col>
<tableDeposit
:id=
"detailInfoBooking.id"
></tableDeposit>
</v-col>
</v-row>
</v-row>
-->
</q-card-section>
<q-separator
/>
<q-card-actions
align=
"right"
>
...
...
@@ -157,10 +157,10 @@
<
script
lang=
"ts"
>
import
{
defineComponent
,
PropType
,
watch
}
from
'vue'
;
import
{
ListBooking
}
from
'src/assets/type'
;
import
tableDeposit
from
'../../components/detailBooking/tableDeposit/index.vue'
;
//
import tableDeposit from '../../components/detailBooking/tableDeposit/index.vue';
export
default
defineComponent
({
components
:
{
tableDeposit
,
//
tableDeposit,
},
props
:
{
showDialog
:
{
...
...
src/pages/khach-hang/index.vue
View file @
7109f100
...
...
@@ -27,21 +27,11 @@
<q-select
v-model=
"levelSelected"
:options=
"levelOptions"
option-label=
"level"
option-value=
"level"
dense
outlined
label=
"Đánh giá sao"
clearable
>
<template
v-slot:option=
"scope"
>
<q-item
v-bind=
"scope.itemProps"
>
<q-item-section>
<q-item-label>
{{
scope
.
opt
.
level
}}
</q-item-label>
<!--
<q-item-label
caption
>
{{
scope
.
opt
.
description
}}
</q-item-label>
-->
</q-item-section>
</q-item>
</
template
>
</q-select>
</div>
<div
class=
"col-auto"
>
...
...
@@ -389,7 +379,17 @@ export default defineComponent({
const
position
:
Ref
<
string
|
null
>
=
ref
(
null
);
const
level
:
Ref
<
CustomerLevelType
|
null
>
=
ref
(
null
);
const
levelOptions
:
Ref
<
CustomerLevelType
[]
|
null
>
=
ref
([]);
const
levelOptions
=
ref
([
'1'
,
'1.5'
,
'2'
,
'2.5'
,
'3'
,
'3.5'
,
'4'
,
'4.5'
,
'5'
,
]);
const
getListCustomers
=
async
()
=>
{
try
{
const
response
=
(
await
api
({
...
...
@@ -411,16 +411,16 @@ export default defineComponent({
}
}
catch
(
error
)
{}
};
const
getCustomerLevelOptions
=
async
()
=>
{
const
response
=
(
await
api
({
url
:
API_PATHS
.
listCustomerLevel
,
method
:
'GET'
,
params
:
{},
}))
as
AxiosResponse
<
BaseResponseBody
<
CustomerLevelType
[]
>>
;
if
(
response
.
data
.
error
.
code
===
config
.
API_RES_CODE
.
OK
.
code
)
{
levelOptions
.
value
=
response
.
data
.
data
;
}
};
//
const getCustomerLevelOptions = async () => {
//
const response = (await api({
//
url: API_PATHS.listCustomerLevel,
//
method: 'GET',
//
params: {},
//
})) as AxiosResponse
<
BaseResponseBody
<
CustomerLevelType
[]
>>
;
//
if (response.data.error.code === config.API_RES_CODE.OK.code) {
//
levelOptions.value = response.data.data;
//
}
//
};
const
confirmDeleteCustomer
=
(
id
:
number
)
=>
{
Dialog
.
create
({
title
:
i18n
.
global
.
t
(
...
...
@@ -654,7 +654,7 @@ export default defineComponent({
onMounted
(()
=>
{
void
getListCustomers
();
void
getCustomerLevelOptions
();
//
void getCustomerLevelOptions();
});
return
{
openUpdateCustomerDialog
,
...
...
@@ -692,7 +692,7 @@ export default defineComponent({
totalPage
,
listRating
,
changePageSize
,
getCustomerLevelOptions
,
//
getCustomerLevelOptions,
confirmDeleteCustomer
,
confirmBrowserCustomer
,
customerInfo
,
...
...
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