CN-647 fix: 图表接口对接
This commit is contained in:
@@ -754,3 +754,11 @@ export function scrollToTop (dom, toTop, duration, direction) {
|
||||
}
|
||||
window.requestAnimationFrame(step)
|
||||
}
|
||||
|
||||
export function getChainRatio (current, prev) {
|
||||
if (prev === 0) {
|
||||
return '-'
|
||||
} else {
|
||||
return (current - prev) / prev
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user