Skip to content
GitLab
Menu
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
hive
wallet
Commits
fb22f378
Commit
fb22f378
authored
Apr 15, 2019
by
motrebski
Committed by
Jonathan Porta
Jul 26, 2019
Browse files
Get SPS list in interval
parent
3dcb028f
Changes
1
Hide whitespace changes
Inline
Side-by-side
src/app/components/pages/SteemProposalSystem.jsx
View file @
fb22f378
...
...
@@ -22,6 +22,8 @@ class SteemProposalSystem extends React.Component {
'
voted
'
,
];
interval
=
2
*
60
*
1000
;
orderedProposalKeys
=
[
'
id
'
,
'
creator
'
,
...
...
@@ -61,6 +63,13 @@ class SteemProposalSystem extends React.Component {
}
}
componentDidMount
()
{
this
.
intervalId
=
setInterval
(()
=>
{
const
{
limit
,
status
,
last_id
}
=
this
.
state
;
this
.
getProposals
(
limit
,
status
,
last_id
);
},
this
.
interval
);
}
componentWillReceiveProps
(
nextProps
)
{
const
{
currentUser
}
=
nextProps
;
...
...
@@ -69,6 +78,10 @@ class SteemProposalSystem extends React.Component {
}
}
componentWillUnmount
()
{
clearInterval
(
this
.
intervalId
);
}
getSpsUrl
(
creator
,
permlink
)
{
const
{
social_url
}
=
global
.
$STM_Config
;
return
`
${
social_url
||
''
}
/@
${
creator
}
/
${
permlink
}
`
;
...
...
Write
Preview
Supports
Markdown
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