|
@@ -367,7 +367,7 @@ func NewCow(pastureId int64, req *pasturePb.EventEnterRequest, penMap map[int32]
|
|
}
|
|
}
|
|
}
|
|
}
|
|
|
|
|
|
-func NewCalfCow(motherId int64, fatherNumber string, calf *CalvingCalf) *Cow {
|
|
|
|
|
|
+func NewCalfCow(motherNumber, fatherNumber string, calf *CalvingCalf) *Cow {
|
|
return &Cow{
|
|
return &Cow{
|
|
PastureId: calf.PastureId,
|
|
PastureId: calf.PastureId,
|
|
Sex: calf.Sex,
|
|
Sex: calf.Sex,
|
|
@@ -381,7 +381,7 @@ func NewCalfCow(motherId int64, fatherNumber string, calf *CalvingCalf) *Cow {
|
|
BirthAt: calf.BirthAt,
|
|
BirthAt: calf.BirthAt,
|
|
SourceId: pasturePb.CowSource_Calving, // 产犊方式
|
|
SourceId: pasturePb.CowSource_Calving, // 产犊方式
|
|
FatherNumber: fatherNumber,
|
|
FatherNumber: fatherNumber,
|
|
- MotherNumber: fmt.Sprintf("%d", motherId),
|
|
|
|
|
|
+ MotherNumber: motherNumber,
|
|
AdmissionStatus: pasturePb.AdmissionStatus_Admission,
|
|
AdmissionStatus: pasturePb.AdmissionStatus_Admission,
|
|
IsPregnant: pasturePb.IsShow_No,
|
|
IsPregnant: pasturePb.IsShow_No,
|
|
AdmissionAt: calf.BirthAt,
|
|
AdmissionAt: calf.BirthAt,
|