Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Sign in
Toggle navigation
C
cms
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
Pedro-dev_2
cms
Commits
9797b0aa
Commit
9797b0aa
authored
May 17, 2021
by
PDuarte
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
*add menu page fix
* datable components fix
parent
1ea2548f
Changes
7
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
24 additions
and
11 deletions
+24
-11
index.js
src/@core/components/datatable/index.js
+2
-2
tableHeader.js
src/@core/components/datatable/tableHeader.js
+1
-1
index.js
src/views/menupages/mainpages/add/index.js
+7
-1
index.js
src/views/menupages/mainpages/card/index.js
+4
-4
manageplaylist.js
src/views/menupages/mainpages/card/manageplaylist.js
+1
-1
tablayoutplaylists.js
src/views/menupages/mainpages/card/tablayoutplaylists.js
+4
-1
module.js
src/views/menupages/mainpages/module.js
+5
-1
No files found.
src/@core/components/datatable/index.js
View file @
9797b0aa
...
...
@@ -20,7 +20,7 @@ const DataTableServerSide = ({cardTitle, allData, total, getData, serverSideColu
// ** States
const
[
currentPage
,
setCurrentPage
]
=
useState
(
1
)
const
[
rowsPerPage
,
setRowsPerPage
]
=
useState
(
7
)
const
[
rowsPerPage
,
setRowsPerPage
]
=
useState
(
10
)
const
[
searchValue
,
setSearchValue
]
=
useState
(
''
)
const
[
searchTerm
,
setSearchTerm
]
=
useState
(
''
)
...
...
@@ -77,7 +77,7 @@ const DataTableServerSide = ({cardTitle, allData, total, getData, serverSideColu
// ** Custom Pagination
const
CustomPagination
=
()
=>
{
const
count
=
Number
((
total
/
rowsPerPage
).
toFixed
(
0
))
const
count
=
Number
((
total
/
rowsPerPage
).
toFixed
(
0
))
+
1
return
(
<
ReactPaginate
previousLabel
=
{
''
}
...
...
src/@core/components/datatable/tableHeader.js
View file @
9797b0aa
...
...
@@ -21,7 +21,7 @@ const CustomHeader = ({ linkAddButton, handlePerPage, rowsPerPage, handleFilter,
backgroundPosition
:
'calc(100% - 3px) 11px, calc(100% - 20px) 13px, 100% 0'
}}
>
<
option
value
=
'10'
>
10
<
/option
>
<
option
value
=
'10'
defaultValue
>
10
<
/option
>
<
option
value
=
'25'
>
25
<
/option
>
<
option
value
=
'50'
>
50
<
/option
>
<
/CustomInput
>
...
...
src/views/menupages/mainpages/add/index.js
View file @
9797b0aa
...
...
@@ -63,7 +63,13 @@ const Tables = () => {
display
:
''
,
pagetypeid
:
''
,
order
:
'0'
,
menu_page_layouts
:
[]
menu_page_layouts
:
[
{
order
:
1
,
layout_id
:
null
,
playlists
:
[]
}
]
}}
onSubmitHandler
=
{
onSubmitHandler
}
/
>
...
...
src/views/menupages/mainpages/card/index.js
View file @
9797b0aa
...
...
@@ -139,7 +139,7 @@ const handleError = (text) => {
useEffect
(()
=>
{
if
(
!
settingStore
.
allDataPagetypes
||
settingStore
.
allDataPagetypes
.
length
<
1
)
{
dispatch
(
getData_pagetypes
({
start
:
1
,
start
:
0
,
length
:
1000
,
q
:
null
}))
...
...
@@ -160,7 +160,7 @@ const handleError = (text) => {
useEffect
(()
=>
{
if
(
!
screensStore
.
allDataLayoutMenus
||
screensStore
.
allDataLayoutMenus
.
length
<
1
)
{
dispatch
(
getData_layoutmenus
({
start
:
1
,
start
:
0
,
length
:
1000
,
q
:
null
}))
...
...
@@ -334,7 +334,7 @@ return (
<
Nav
pills
>
{
dataElement
&&
dataElement
.
menu_page_layouts
.
map
((
block
,
index
)
=>
{
return
<
NavItem
>
return
<
NavItem
key
=
{
index
}
>
<
NavLink
key
=
{
index
}
active
=
{
activeTab
===
index
}
onClick
=
{()
=>
toggle
(
index
)}
...
...
@@ -356,7 +356,7 @@ return (
activeTab
=
{
activeTab
}
>
{
!!
dataElement
&&
dataElement
.
menu_page_layouts
.
map
((
block
,
index
)
=>
{
return
<
TabPane
tabId
=
{
index
}
>
return
<
TabPane
tabId
=
{
index
}
key
=
{
index
}
>
<
TabLayoutPlaylist
block
=
{
block
}
selectedDataElement
=
{
dataElement
}
setElementData
=
{
setElementData
}
/
>
<
/TabPane
>
}
...
...
src/views/menupages/mainpages/card/manageplaylist.js
View file @
9797b0aa
...
...
@@ -140,7 +140,7 @@ const ManagePlaylist = ({dataElement, selectedDataElement, handleChange}) => {
return
<
div
className
=
"card"
>
<
div
className
=
"card-header"
>
<
h4
className
=
"card-title"
>
playlist
<
/h4
>
<
h4
className
=
"card-title"
>
Playlists
<
/h4
>
<
/div
>
<
div
className
=
"card-body"
>
<
Row
>
...
...
src/views/menupages/mainpages/card/tablayoutplaylists.js
View file @
9797b0aa
...
...
@@ -67,7 +67,7 @@ const TabLayoutPlaylist = ({block, selectedDataElement, setElementData}) => {
<
Col
sm
=
'12'
>
<
div
className
=
"card"
>
<
div
className
=
"card-header"
>
<
h4
className
=
"card-title"
>
ElementCard
{
dataElement
&&
dataElement
.
id
}
<
/h4
>
{
/* <h4 className="card-title">ElementCard {dataElement && dataElement.id} </h4> */
}
<
/div
>
<
div
className
=
"card-body"
>
<
Row
>
...
...
@@ -99,6 +99,9 @@ const TabLayoutPlaylist = ({block, selectedDataElement, setElementData}) => {
>
{
!!
layoutPlaylists
?
layoutPlaylists
.
map
(
option
=>
{
if
(
dataElement
.
layout_id
===
null
)
{
dataElement
.
layout_id
=
option
.
id
}
return
<
option
key
=
{
option
.
id
}
selected
=
{
option
.
id
===
dataElement
.
layout_id
?
option
.
id
:
''
}
value
=
{
option
.
id
}
>
{
option
.
name
}
<
/option
>
...
...
src/views/menupages/mainpages/module.js
View file @
9797b0aa
...
...
@@ -5,9 +5,13 @@ const moduleSettings = {
baseURL
:
'/menupages/mainpages'
,
newElement
:
{
slug
:
0
,
type
:
0
type
:
0
,
menu_page_layouts
:
{
playlists
:
[]
}
},
elementsOption
:
{
playlists
:
[]
}
}
...
...
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