保誠-保戶業務員媒合平台
Tomas
2023-12-25 f065760fa7df1f88747395ab4b55349ce8b2faf0
PAMapp/components/singleSelectBtn.vue
@@ -21,7 +21,6 @@
<script lang="ts">
  import { Component, Prop, PropSync, Vue } from "nuxt-property-decorator";
  import { OptionBtnDto } from "~/shared/models/optionBtnDto.model";
  import * as _ from 'lodash';
  @Component
  export default class SingleSelectBtn extends Vue {
@@ -35,7 +34,7 @@
    //////////////////////////////////////////////////////////////////////
    patchValue(value: string | number): void {
      // 主要解決按鈕點擊兩次能回到,未點選的狀態
      this.syncSingleSelected = _.isEqual(this.syncSingleSelected, value) ? "" : value;
      this.syncSingleSelected = this.syncSingleSelected === value ? "" : value;
    }
  }
</script>