Update License
This commit is contained in:
@@ -106,7 +106,8 @@ func (r *LicenseRepository) FindByPartnerIDMaxEndDate(ctx context.Context, partn
|
||||
|
||||
if err := r.db.WithContext(ctx).
|
||||
Where("partner_id = ?", partnerID).
|
||||
Where("start_date >= ?", today).
|
||||
Where("start_date <= ?", today).
|
||||
Where("end_date >= ?", today).
|
||||
Order("end_date DESC").
|
||||
First(&licenseDB).Error; err != nil {
|
||||
|
||||
|
||||
Reference in New Issue
Block a user