@@ -22,6 +22,7 @@ const price = computed(()=>{
|
||||
let p = s.poolPrices[route.pool]
|
||||
if( !p )
|
||||
return ''
|
||||
p = Number(p) // TODO: Temporary workaround. Better to fix reason for p being set to string.
|
||||
console.log('pool price is',p)
|
||||
if( props.inverted )
|
||||
p = 1/p
|
||||
|
||||
@@ -283,7 +283,8 @@ function placeOrder() {
|
||||
priceConstraint = !limitPrice.value ? null : newLimitConstraint(isAbove, isRatio, limit)
|
||||
}
|
||||
for (let i = 0; i < n; i++) {
|
||||
const start = Math.floor(i * (duration / (n-1)))
|
||||
// const start = Math.floor(i * (duration / (n - 1)))
|
||||
const start = Math.floor(i * (duration / Math.max((n - 1), 1)))
|
||||
const end = start + window
|
||||
console.log('tranche window', start, end, (end-start)/60)
|
||||
const cs = [newTimeConstraint(TimeMode.SinceOrderStart, start, TimeMode.SinceOrderStart, end)]
|
||||
|
||||
Reference in New Issue
Block a user