How can I implement onChange with TomSelect in my code?
<TomSelect
:disabled="disableForm"
v-model="wareHouse.agent.id"
:onChange="changeAgentData"
class="w-full"
>
<option value="">No Agent</option>
<template v-for="(business, indexKey) in company.agentCompanies">
<option v-if="business.companyType.includes('Shipper')" :key="indexKey" :value="business.id">{{business.name}}</option>
</template>
</TomSelect>
The current implementation is not working as expected. The changeAgentData
function is not being triggered.
I have tried using @change
, change
, and changed
but none of them worked.