sonar fix 3 issues and now 0 left
This commit is contained in:
@@ -143,7 +143,7 @@
|
|||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
import { defineComponent, computed, ref, watch, onMounted, } from 'vue';
|
import { defineComponent, computed, ref, watch, } from 'vue';
|
||||||
import i18next from "@/i18n/i18n.js";
|
import i18next from "@/i18n/i18n.js";
|
||||||
import { mapActions, } from 'pinia';
|
import { mapActions, } from 'pinia';
|
||||||
import { useModalStore } from '@/stores/modal.js';
|
import { useModalStore } from '@/stores/modal.js';
|
||||||
@@ -202,16 +202,6 @@ export default defineComponent({
|
|||||||
return modalStore.whichModal === MODAL_CREATE_NEW ? i18next.t('AcctMgmt.CreateNew') : i18next.t('AcctMgmt.AccountEdit');
|
return modalStore.whichModal === MODAL_CREATE_NEW ? i18next.t('AcctMgmt.CreateNew') : i18next.t('AcctMgmt.AccountEdit');
|
||||||
});
|
});
|
||||||
|
|
||||||
const hasAtLeastOneEmptyField = (inputAccountToTest, inputNameToTest, inputPasswordToTest, inputConfirmPwdToTest) => {
|
|
||||||
return !inputAccountToTest?.length || !inputNameToTest?.length || !inputPasswordToTest?.length
|
|
||||||
|| !inputConfirmPwdToTest?.length;
|
|
||||||
}
|
|
||||||
|
|
||||||
const shouldDisalbeConfirmButton = (inputAccountToTest, inputNameToTest, inputPasswordToTest, inputConfirmPwdToTest, inputPwdMatchedToTest,
|
|
||||||
) => {
|
|
||||||
return hasAtLeastOneEmptyField(inputAccountToTest, inputNameToTest, inputPasswordToTest, inputConfirmPwdToTest) || !inputPwdMatchedToTest;
|
|
||||||
}
|
|
||||||
|
|
||||||
const togglePwdEyeBtn = () => {
|
const togglePwdEyeBtn = () => {
|
||||||
isPwdEyeOn.value = !isPwdEyeOn.value;
|
isPwdEyeOn.value = !isPwdEyeOn.value;
|
||||||
};
|
};
|
||||||
|
|||||||
Reference in New Issue
Block a user