<template>
  <div class="lc--custom--btn">
    <v-select
      v-model="props.params.data.inhibitStatus"
      :items="sltInhibit"
      variant="outlined"
      class="custom-select"
      style="width:15rem"
      @click.stop
    >
    </v-select>
    <v-btn class="custom-btn mini apply-btn" @click="btnClickedHandler">적용</v-btn>
  </div>
</template>

<script setup>
  // props
  const props = defineProps({
    params: Object,
  })
  const sltInhibit = ref([])
  function btnClickedHandler(event){
    event.stopPropagation();
    props.params.clicked(props.params)
  }
  watchEffect(() =>{
    fnGetEnumCode(useLangStore().getLang)
  })
  /**
   * ENUM 업데이트
   * @param lang
   */
  function fnGetEnumCode(lang){
    lang = useUtil.nvl(lang, 'kr')
    let objEnum = useEnumCode.getEnumCode(lang)
    let deleteAllInhibit = objEnum.inhibitStatus.filter(item=>item.value !== -1)
    sltInhibit.value = deleteAllInhibit
  }
</script>