Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
C
CmsPetrolPay
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
11
Issues
11
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
Giang Tran
CmsPetrolPay
Commits
0ac19812
Commit
0ac19812
authored
Aug 09, 2024
by
tdgiang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
update build
parent
a18e4537
Hide whitespace changes
Inline
Side-by-side
Showing
9 changed files
with
67 additions
and
53 deletions
+67
-53
RootRoutes.jsx
src/app/RootRoutes.jsx
+1
-1
url.js
src/app/apis/url.js
+7
-0
Create.js
src/app/views/Company/Employee/Create.js
+24
-24
Update.js
src/app/views/Company/Employee/Update.js
+23
-23
Create.js
src/app/views/GasStation/Create.js
+3
-0
Update.js
src/app/views/GasStation/Update.js
+4
-0
Index.js
src/app/views/Ncc/Index.js
+2
-2
Analytics.jsx
src/app/views/dashboard/Analytics.jsx
+1
-1
Detail.js
src/app/views/landingpage/register/Detail.js
+2
-2
No files found.
src/app/RootRoutes.jsx
View file @
0ac19812
...
...
@@ -18,7 +18,7 @@ import GasStationRoutes from './views/GasStation/GasStationRoutes'
import
ListRequestRoutes
from
'./views/ListRequest/routes'
import
SignUp
from
'./views/SignUp/routes'
import
InvoiceSupplier
from
'./views/InvoiceSupplier/routes'
//
import Package from './views/package/routers'
import
Package
from
'./views/package/routers'
import
NccRouter
from
'./views/Ncc/router'
import
LandingpageRouter
from
'./views/landingpage/router'
...
...
src/app/apis/url.js
View file @
0ac19812
...
...
@@ -2,8 +2,15 @@
//const root = 'https://apigw.petropos.vn/api'
//const root = 'http://dcvf.tasvietnam.vn:9986/api'
//const root = 'https://apigw-v2.petropos.vn/api'
//v2
//const root = 'https://apitest-v2.petropos.vn/api'
//v3
const
root
=
'https://apitest.petropos.vn/api'
//const root = 'http://petropos-api.tasvietnam.vn/api'
export
default
{
//Dang nhap,thong tin ca nhan
urlLogin
:
`
${
root
}
/auth/adminLogin`
,
...
...
src/app/views/Company/Employee/Create.js
View file @
0ac19812
...
...
@@ -91,43 +91,43 @@ const SimpleForm = (props) => {
const
handleSubmit
=
async
(
event
)
=>
{
const
newValue
=
trimObject
(
state
)
if
(
listChecked
.
length
>
0
)
{
if
(
image
)
{
const
newList
=
listChecked
.
map
((
e
)
=>
{
return
{
action_id
:
e
}
})
props
.
showLoading
()
const
res
=
await
createEmployee
({
...
newValue
,
user_group_id
:
role
,
//
if (image) {
const
newList
=
listChecked
.
map
((
e
)
=>
{
return
{
action_id
:
e
}
})
props
.
showLoading
()
const
res
=
await
createEmployee
({
...
newValue
,
user_group_id
:
role
,
userPermissions
:
newList
,
avatar
:
image
,
status
:
1
,
})
console
.
log
(
res
)
props
.
hideLoading
()
userPermissions
:
newList
,
avatar
:
image
,
status
:
1
,
})
console
.
log
(
res
)
props
.
hideLoading
()
if
(
res
.
data
.
code
==
200
)
{
history
.
push
(
'/employee'
)
if
(
res
.
data
.
code
==
200
)
{
history
.
push
(
'/employee'
)
if
(
res
.
data
.
code
==
200
)
{
toast
.
success
(
'Tạo nhân viên thành công!'
,
{
theme
:
'colored'
,
})
}
}
else
{
toast
.
error
(
t
(
res
.
data
.
error
),
{
toast
.
success
(
'Tạo nhân viên thành công!'
,
{
theme
:
'colored'
,
})
}
}
else
{
toast
.
warning
(
'Bạn chưa chọn ảnh đại diện cho nhân viên!'
,
{
toast
.
error
(
t
(
res
.
data
.
error
)
,
{
theme
:
'colored'
,
})
}
}
else
{
toast
.
warning
(
'Bạn chưa
thêm quyề
n cho nhân viên!'
,
{
toast
.
warning
(
'Bạn chưa
chọn ảnh đại diệ
n cho nhân viên!'
,
{
theme
:
'colored'
,
})
}
// } else {
// toast.warning('Bạn chưa thêm quyền cho nhân viên!', {
// theme: 'colored',
// })
// }
}
const
handleChange
=
(
event
)
=>
{
...
...
src/app/views/Company/Employee/Update.js
View file @
0ac19812
...
...
@@ -128,42 +128,42 @@ const SimpleForm = (props) => {
const
handleSubmit
=
async
(
event
)
=>
{
const
newValue
=
trimObject
(
state
)
if
(
listChecked
.
length
>
0
)
{
if
(
image
)
{
const
newList
=
listChecked
.
map
((
e
)
=>
{
return
{
action_id
:
e
}
})
//
if (image) {
const
newList
=
listChecked
.
map
((
e
)
=>
{
return
{
action_id
:
e
}
})
props
.
showLoading
()
const
res
=
await
updateEmployee
({
...
newValue
,
user_group_id
:
role
,
userPermissions
:
newList
,
avatar
:
image
,
})
console
.
log
(
res
)
props
.
hideLoading
()
props
.
showLoading
()
const
res
=
await
updateEmployee
({
...
newValue
,
user_group_id
:
role
,
userPermissions
:
newList
,
avatar
:
image
,
})
console
.
log
(
res
)
props
.
hideLoading
()
if
(
res
.
data
.
code
==
200
)
{
history
.
push
(
'/employee'
)
if
(
res
.
data
.
code
==
200
)
{
history
.
push
(
'/employee'
)
if
(
res
.
data
.
code
==
200
)
{
toast
.
success
(
'Cập nhật nhân viên thành công!'
,
{
theme
:
'colored'
,
})
}
}
else
{
toast
.
error
(
t
(
res
.
data
.
error
),
{
toast
.
success
(
'Cập nhật nhân viên thành công!'
,
{
theme
:
'colored'
,
})
}
}
else
{
toast
.
warning
(
'Bạn chưa chọn ảnh đại diện cho nhân viên!'
,
{
toast
.
error
(
t
(
res
.
data
.
error
)
,
{
theme
:
'colored'
,
})
}
}
else
{
toast
.
warning
(
'Bạn chưa
thêm quyề
n cho nhân viên!'
,
{
toast
.
warning
(
'Bạn chưa
chọn ảnh đại diệ
n cho nhân viên!'
,
{
theme
:
'colored'
,
})
}
// } else {
// toast.warning('Bạn chưa thêm quyền cho nhân viên!', {
// theme: 'colored',
// })
// }
}
const
handleChange
=
(
event
)
=>
{
...
...
src/app/views/GasStation/Create.js
View file @
0ac19812
...
...
@@ -73,6 +73,9 @@ const SimpleForm = (props) => {
const
res
=
await
createGasStation
({
...
newValue
,
gas_fields
:
listField
,
account
:
newValue
?.
account
,
user_name
:
newValue
?.
user_name
,
password
:
newValue
?.
password
,
})
props
.
hideLoading
()
if
(
res
.
data
.
code
==
200
)
{
...
...
src/app/views/GasStation/Update.js
View file @
0ac19812
...
...
@@ -109,6 +109,10 @@ const SimpleForm = (props) => {
gas_fields
:
listField
,
store_code
:
newValue
?.
store_code
,
queue_name
:
newValue
?.
queue_name
,
account
:
newValue
?.
account
,
user_name
:
newValue
?.
user_name
,
password
:
newValue
?.
password
,
})
props
.
hideLoading
()
if
(
res
.
data
.
code
==
200
)
{
...
...
src/app/views/Ncc/Index.js
View file @
0ac19812
...
...
@@ -54,14 +54,14 @@ const ToolNotificate = (props) => {
if
(
isInit
)
{
setPageIndex
(
0
)
res
=
await
getListSupplier
({
fuel
_name
:
searchDebount
,
supp
_name
:
searchDebount
,
page_no
:
0
,
page_size
:
pageSize
,
status
,
})
}
else
{
res
=
await
getListSupplier
({
fuel
_name
:
searchDebount
,
supp
_name
:
searchDebount
,
page_no
:
pageIndex
+
1
,
page_size
:
pageSize
,
status
,
...
...
src/app/views/dashboard/Analytics.jsx
View file @
0ac19812
...
...
@@ -30,7 +30,7 @@ const dataLine = [
},
{
id
:
3
,
textLeft
:
"Sản phẩm mới"
,
textLeft
:
'Sản phẩm mới'
,
textRight
:
'Hợp đồng'
,
data
:
[
820
,
932
,
1901
,
934
,
1290
,
1330
,
120
],
bg
:
'yellow'
,
...
...
src/app/views/landingpage/register/Detail.js
View file @
0ac19812
...
...
@@ -31,9 +31,9 @@ const SimpleForm = (props) => {
props
.
hideLoading
()
if
(
res
.
data
.
code
==
200
&&
res
.
data
.
data
)
{
setState
({
...
res
.
data
.
data
,
...
res
.
data
.
data
?.
data
,
status_name
:
res
.
data
.
data
.
status
==
1
res
.
data
.
data
?.
data
.
status
==
1
?
'Đã thanh toán'
:
'Chưa thanh toán'
,
})
...
...
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