feat: 完成喂养计划,宠物信息填充
This commit is contained in:
1 parent
08d03cfbe0
commit
6dfcc0076a
15 files changed
+276
-38
No files matched your search
@@ -0,0 +1,34 @@
|
||||
import { type CreatePetRequest, Gender, PetBodyType, PetType } from '@/model/pet'
|
||||
import { defineStore } from 'pinia'
|
||||
|
||||
export const useFeedingPlanStore = defineStore('feeding-plan', () => {
|
||||
const petTypeOptions = [
|
||||
{ value: PetType.CAT, label: '猫猫' },
|
||||
{ value: PetType.DOG, label: '狗狗' },
|
||||
]
|
||||
|
||||
const genderOptions = [
|
||||
{ value: Gender.MALE, label: '男孩' },
|
||||
{ value: Gender.FEMALE, label: '女孩' },
|
||||
]
|
||||
|
||||
const pet = ref <CreatePetRequest>({
|
||||
birthday: new Date().toISOString().split('T')[0],
|
||||
bodyType: PetBodyType.IDEAL,
|
||||
gender: Gender.MALE,
|
||||
isActive: false,
|
||||
isLactation: false,
|
||||
isPregnant: false,
|
||||
isSterilization: false,
|
||||
name: '子龙',
|
||||
photo: '',
|
||||
type: PetType.CAT,
|
||||
weight: 0,
|
||||
})
|
||||
|
||||
return {
|
||||
pet,
|
||||
petTypeOptions,
|
||||
genderOptions,
|
||||
}
|
||||
})
|
||||
Reference in new issue
Block a user