fix bug artist-page

parent b1b14c35
......@@ -41,7 +41,7 @@ export default defineComponent({
(val?: string) =>
(val && val.trim().length) ||
i18n.global.t(
'artist.artistInformation.validateMessages.requireFullName'
'artist.artistInformation.validateMessages.requireAccount'
),
];
const uploadBanner = (value: FileList) => {
......@@ -56,7 +56,7 @@ export default defineComponent({
'managingUnit.confirmActionsTitle.confirmDeleteManagingUnitsTitle'
),
message: i18n.global.t(
'managingUnit.confirmActionsTitle.confirmDeleteManagingUnitsContent'
'artist.confirmActionsTitle.confirmDeleteBannerContent'
),
cancel: i18n.global.t(
'managingUnit.confirmActionsTitle.confirmDeleteManagingUnitsCancelBtnLabel'
......
......@@ -21,6 +21,7 @@
:model-value="account"
@update:model-value="$emit('update:account', $event)"
:rules="accountRules"
type="text"
dense
hide-bottom-space
outlined
......
......@@ -2,7 +2,7 @@ import { defineComponent, PropType, ref, Ref } from 'vue';
import { i18n } from 'src/boot/i18n';
import UploadImage from '../../upload-image/index.vue';
import moment from 'moment';
import { FieldType } from 'src/assets/type';
import { FieldType, NationalityType } from 'src/assets/type';
export default defineComponent({
props: {
id: { type: Number, required: true },
......@@ -12,7 +12,7 @@ export default defineComponent({
artistName: { type: String, required: true },
birthday: { type: String, required: true },
sex: { type: Number, required: true },
nationality: { type: Number, required: true },
nationality: { type: Object as PropType<NationalityType>, required: true },
status: { type: Number, required: true },
address: { type: String, required: true },
fields: { type: Object as PropType<FieldType>, required: true },
......
......@@ -13,8 +13,8 @@ export default {
pageTitle: 'Đăng nhập',
usernameInputLabel: 'Tên đăng nhập',
passwordInputLabel: 'Mật khẩu',
requireUsername: 'Vui lòng nhập tên đăng nhập',
requirePassword: 'Vui lòng nhập mật khẩu',
requireUsername: 'Vui lòng Nhập tên đăng nhập',
requirePassword: 'Vui lòng Nhập mật khẩu',
submitLoginBtnLabel: 'Đăng nhập',
loginSuccess: 'Đăng nhập thành công',
},
......@@ -90,7 +90,7 @@ export default {
fullName: 'Họ Tên *',
email: 'Email *',
mobileNumber: 'Số điện thoại *',
address: 'Địa chỉ *',
address: 'Địa chỉ',
phoneNumber: 'Số máy bàn',
unit: 'Đơn vị phòng ban *',
sex: 'Giới tính *',
......@@ -369,11 +369,11 @@ export default {
isEmail: 'Email không hợp lệ',
requirePhone: 'Vui lòng nhập Số điện thoại',
isPhone: 'Số điện thoại không hợp lệ',
requireAddress: 'Vui lòng nhập địa chỉ',
requireAddress: 'Vui lòng nhập Địa chỉ',
requireBusinessType: 'Vui lòng nhập Loại doanh nghiệp',
requireRatings: 'Vui lòng chọn xếp hạng',
requireRepresentative: 'Vui lòng nhập người đại diện',
requiredPosition: 'Vui lòng nhập chức vụ',
requireRatings: 'Vui lòng chọn Xếp hạng',
requireRepresentative: 'Vui lòng nhập Người đại diện',
requiredPosition: 'Vui lòng nhập Chức vụ',
},
confirmActionsTitle: {
confirmDeleteUserTitle: 'Xác nhận',
......@@ -419,11 +419,11 @@ export default {
isDefault: 'Mặc định',
},
validateMessages: {
requireAccountNumber: 'Vui lòng nhập số tài khoản',
requireAccountNumber: 'Vui lòng nhập Số tài khoản',
accountNumberExits: 'Số tài khoản đã tồn tại',
requireCardNumber: 'Vui lòng nhập số ghi trên thẻ',
requireBankName: 'Vui lòng chọn ngân hàng',
requireCardType: 'Vui lòng chọn loại thẻ',
requireCardNumber: 'Vui lòng nhập Số ghi trên thẻ',
requireBankName: 'Vui lòng chọn Ngân hàng',
requireCardType: 'Vui lòng chọn Loại thẻ',
errorIsDefault: 'Nghệ sỹ đã có tài khoản ngân hàng mặc định',
addAccess: 'Thêm tài khoản ngân hàng thành công',
editAccess: 'Cập nhật thông tin tài khoản ngân hàng thành công',
......@@ -435,6 +435,7 @@ export default {
confirmDeleteArtistTitle: 'Xác nhận',
confirmDeleteArtistContent: 'Bạn có chắc muốn xoá nghệ sỹ này không?',
confirmDeleteEmbedContent: 'Bạn có chắc muốn xoá Embed này không?',
confirmDeleteBannerContent: 'Bạn có chắc muốn xoá Ảnh banner này không?',
confirmDeleteArtistBtnLabel: 'Huỷ',
},
actionMessages: {
......@@ -472,23 +473,24 @@ export default {
whatsapp: 'Whatsapp',
},
validateMessages: {
requireProducCode: 'Vui lòng nhập mã sản phẩm',
requireProducCode: 'Vui lòng nhập Mã sản phẩm',
requireUrlembed: 'Vui lòng nhập Url Embed',
requireArtistCode: 'Vui lòng nhập mã nghệ sỹ',
requireFullName: 'Vui lòng nhập họ tên nghệ sỹ',
requireArtistName: 'Vui lòng nhập nghệ danh',
requireBirthday: 'Vui lòng chọn ngày sinh',
requireEmail: 'Vui lòng nhập email',
requireArtistCode: 'Vui lòng nhập Mã nghệ sỹ',
requireFullName: 'Vui lòng nhập Họ tên nghệ sỹ',
requireAccount: 'Vui lòng nhập Tên đăng nhập',
requireArtistName: 'Vui lòng nhập Nghệ danh',
requireBirthday: 'Vui lòng chọn Ngày sinh',
requireEmail: 'Vui lòng nhập Email',
isEmail: 'Email không hợp lệ',
requireAddress: 'Vui lòng nhập địa chỉ',
requirePhoneNumber: 'Vui lòng nhập số điện thoại',
requireAddress: 'Vui lòng nhập Địa chỉ',
requirePhoneNumber: 'Vui lòng nhập Số điện thoại',
isPhone: 'Số điện thoại không hợp lệ',
requireSex: 'Vui lòng chọn giới tính',
requireNationality: 'Vui lòng chọn quốc tịch',
requireField: 'Vui lòng chọn lĩnh vực',
requiredWork: 'Vui lòng chọn công việc',
requireQualification: 'Vui lòng chọn độ chuyên',
requireArtistLevel: 'Vui lòng chọn xếp hạng',
requireSex: 'Vui lòng chọn Giới tính',
requireNationality: 'Vui lòng chọn Quốc tịch',
requireField: 'Vui lòng chọn Lĩnh vực',
requiredWork: 'Vui lòng chọn Công việc',
requireQualification: 'Vui lòng chọn Độ chuyên',
requireArtistLevel: 'Vui lòng chọn Xếp hạng',
},
},
bankAccount: {
......
......@@ -93,7 +93,12 @@ export default defineComponent({
const artistName: Ref<string | null> = ref(null);
const birthday: Ref<string | null> = ref(null);
const sex: Ref<number | null> = ref(null);
const nationality: Ref<NationalityType | null> = ref(null);
const nationality: Ref<NationalityType> = ref({
id: 1,
name: 'Việt Nam',
numIndex: 1,
status: 1,
});
const qualification: Ref<QualificationType | null> = ref(null);
const artistLevel: Ref<ArtistLevelType | null> = ref(null);
const address: Ref<string | null> = ref(null);
......
......@@ -92,7 +92,12 @@ export default defineComponent({
const artistName: Ref<string | null> = ref(null);
const birthday: Ref<string | null> = ref(null);
const sex: Ref<number | null> = ref(null);
const nationality: Ref<NationalityType | null> = ref(null);
const nationality: Ref<NationalityType> = ref({
id: 1,
name: 'Việt Nam',
numIndex: 1,
status: 1,
});
const qualification: Ref<QualificationType | null> = ref(null);
const artistLevel: Ref<ArtistLevelType | null> = ref(null);
const address: Ref<string | null> = ref(null);
......@@ -674,6 +679,7 @@ export default defineComponent({
avatar: avatarUploaded.value,
artistCode: artistCode.value,
artistName: artistName.value,
// eslint-disable-next-line @typescript-eslint/restrict-plus-operands
birthday: birthday.value + ' 00:00:00',
sex: sex.value,
......@@ -687,7 +693,7 @@ export default defineComponent({
fullName: fullName.value,
// "workStatus": 1,
shortDescription: null,
account: null,
account: account.value,
socialEmbedded: socialEmbedded.value,
artistLevel: artistLevel.value,
fields: [fields.value],
......
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