Update AddArtist.ts

parent a7ebee48
...@@ -656,95 +656,95 @@ export default defineComponent({ ...@@ -656,95 +656,95 @@ export default defineComponent({
} catch (error) {} } catch (error) {}
}; };
const checkValidate = () => { const checkValidate = () => {
// let hasError = false; let hasError = false;
// if (!avatarFile.value) { if (!avatarFile.value) {
// hasError = true; hasError = true;
// hidden_img.value = true; hidden_img.value = true;
// } }
// if (!artistCode.value || !artistCode.value?.trim().length) { if (!artistCode.value || !artistCode.value?.trim().length) {
// hasError = true; hasError = true;
// artistCodeRules.value = true; artistCodeRules.value = true;
// } }
// if (!fullName.value || !fullName.value?.trim().length) { if (!fullName.value || !fullName.value?.trim().length) {
// hasError = true; hasError = true;
// fullNameRules.value = true; fullNameRules.value = true;
// } }
// if (!artistName.value || !artistName.value?.trim().length) { if (!artistName.value || !artistName.value?.trim().length) {
// hasError = true; hasError = true;
// artistNameRules.value = true; artistNameRules.value = true;
// } }
// if (address.value) { if (address.value) {
// hasError = true; hasError = true;
// addressRules.value = true; addressRules.value = true;
// } }
// if (!birthday.value || !birthday.value?.trim().length) { if (!birthday.value || !birthday.value?.trim().length) {
// hasError = true; hasError = true;
// birthdayRules.value = true; birthdayRules.value = true;
// } }
// if (sex.value === null) { if (sex.value === null) {
// hasError = true; hasError = true;
// sexRules.value = true; sexRules.value = true;
// } }
// if (!phoneNumber.value || !phoneNumber.value?.trim().length) { if (!phoneNumber.value || !phoneNumber.value?.trim().length) {
// hasError = true; hasError = true;
// phoneNumberRules.value = true; phoneNumberRules.value = true;
// errorMessPhoneNumber.value = i18n.global.t( errorMessPhoneNumber.value = i18n.global.t(
// 'artist.artistInformation.validateMessages.requirePhoneNumber' 'artist.artistInformation.validateMessages.requirePhoneNumber'
// ); );
// } }
// if (!email.value || !email.value?.trim().length) { if (!email.value || !email.value?.trim().length) {
// hasError = true; hasError = true;
// emailRules.value = true; emailRules.value = true;
// errorMessEmail.value = i18n.global.t( errorMessEmail.value = i18n.global.t(
// 'artist.artistInformation.validateMessages.requireEmail' 'artist.artistInformation.validateMessages.requireEmail'
// ); );
// } }
// if ( if (
// (!mnBookingPhone.value || !mnBookingPhone.value?.trim().length) && (!mnBookingPhone.value || !mnBookingPhone.value?.trim().length) &&
// check_infoBooking.value check_infoBooking.value
// ) { ) {
// hasError = true; hasError = true;
// mnBookingPhoneRules.value = true; mnBookingPhoneRules.value = true;
// errorMessmnBookingPhone.value = i18n.global.t( errorMessmnBookingPhone.value = i18n.global.t(
// 'artist.artistInformation.validateMessages.requirePhoneNumberAdminister' 'artist.artistInformation.validateMessages.requirePhoneNumberAdminister'
// ); );
// } }
// if ( if (
// (!mnBookingEmail.value || !mnBookingEmail.value?.trim().length) && (!mnBookingEmail.value || !mnBookingEmail.value?.trim().length) &&
// check_infoBooking.value check_infoBooking.value
// ) { ) {
// hasError = true; hasError = true;
// mnBookingEmailRules.value = true; mnBookingEmailRules.value = true;
// errorMessmnBookingEmail.value = i18n.global.t( errorMessmnBookingEmail.value = i18n.global.t(
// 'artist.artistInformation.validateMessages.requireEmailAdminister' 'artist.artistInformation.validateMessages.requireEmailAdminister'
// ); );
// } }
// if (artistLevel.value === null) { if (artistLevel.value === null) {
// hasError = true; hasError = true;
// artistLevelRules.value = true; artistLevelRules.value = true;
// } }
// if (!fields.value) { if (!fields.value) {
// hasError = true; hasError = true;
// fieldRules.value = true; fieldRules.value = true;
// } }
// if (nationality.value === null) { if (nationality.value === null) {
// hasError = true; hasError = true;
// nationalityRules.value = true; nationalityRules.value = true;
// } }
// if (qualification.value === null) { if (qualification.value === null) {
// hasError = true; hasError = true;
// qualificationRules.value = true; qualificationRules.value = true;
// } }
// if (!works.value.length) { if (!works.value.length) {
// hasError = true; hasError = true;
// workRules.value = true; workRules.value = true;
// } }
// if (hasError === false) { if (hasError === false) {
void addArtist(); void addArtist();
// } }
}; };
const addArtist = async () => { const addArtist = async () => {
try { try {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment