This repository was archived by the owner on Feb 22, 2024. It is now read-only.
File tree Expand file tree Collapse file tree 1 file changed +5
-2
lines changed
src/javascript/app/pages/trade Expand file tree Collapse file tree 1 file changed +5
-2
lines changed Original file line number Diff line number Diff line change @@ -3,6 +3,7 @@ const HighchartUI = require('./charts/highchart.ui');
33const requireHighstock = require ( './common' ) . requireHighstock ;
44const countDecimalPlaces = require ( './common_independent' ) . countDecimalPlaces ;
55const Reset = require ( './reset' ) ;
6+ const getUnderlyingPipSize = require ( './symbols' ) . getUnderlyingPipSize ;
67const Tick = require ( './tick' ) ;
78const updatePurchaseStatus = require ( './update_values' ) . updatePurchaseStatus ;
89const ViewPopupUI = require ( '../user/view_popup/view_popup.ui' ) ;
@@ -303,7 +304,7 @@ const TickDisplay = (() => {
303304 applicable_ticks = [ ] ;
304305 } ;
305306
306- const dispatch = ( data ) => {
307+ const dispatch = async ( data ) => {
307308 const tick_chart = CommonFunctions . getElementById ( id_render ) ;
308309
309310 if ( ! CommonFunctions . isVisible ( tick_chart ) || ! data || ( ! data . tick && ! data . history ) ) {
@@ -322,7 +323,9 @@ const TickDisplay = (() => {
322323 if ( document . getElementById ( 'sell_content_wrapper' ) ) {
323324 if ( ! chart_display_decimals ) {
324325 // We're getting the pip size based on standard `display_value` provided by API
325- chart_display_decimals = countDecimalPlaces ( contract . display_value ) ;
326+ chart_display_decimals = countDecimalPlaces ( contract . display_value ) ||
327+ data . history ? await getUnderlyingPipSize ( data . echo_req . ticks_history )
328+ : data . tick ? await getUnderlyingPipSize ( data . echo_req . ticks ) : Tick . pipSize ( ) ;
326329 }
327330 if ( data . tick ) {
328331 Tick . details ( data ) ;
You can’t perform that action at this time.
0 commit comments