Skip to content

Commit

Permalink
fix datetime autofill (#76)
Browse files Browse the repository at this point in the history
  • Loading branch information
Sorizen authored Jul 30, 2024
1 parent 731ba15 commit 6907b0d
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/common/modals/compositions/DepositModal.vue
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@
class="deposit-modal__form"
:pool-id="poolId"
:min-stake="minStake"
:lock-end="claimLockEnd"
@cancel="modal.close"
@stake-tx-sent="modal.close"
/>
Expand All @@ -36,6 +37,7 @@ withDefaults(
isShown: boolean
poolId: number
minStake: BigNumber
claimLockEnd: string
isCloseByClickOutside?: boolean
}>(),
{
Expand Down
9 changes: 9 additions & 0 deletions src/forms/DepositForm.vue
Original file line number Diff line number Diff line change
Expand Up @@ -119,6 +119,7 @@ const emit = defineEmits<{
const props = defineProps<{
poolId: number
minStake: BigNumber
lockEnd: string
}>()
const uid = uuidv4()
Expand Down Expand Up @@ -318,6 +319,14 @@ watch(
{ immediate: true },
)
watch(
() => props.lockEnd,
() => {
form.lockPeriod = props.lockEnd
},
{ immediate: true },
)
onMounted(() => {
init()
})
Expand Down
1 change: 1 addition & 0 deletions src/pages/HomePage/views/PublicPoolView.vue
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,7 @@
v-model:is-shown="isDepositModalShown"
:pool-id="poolId"
:min-stake="poolData.minimalStake"
:claim-lock-end="userPoolData?.claimLockEnd?.toString() ?? ''"
/>
</div>
</transition>
Expand Down

0 comments on commit 6907b0d

Please sign in to comment.