Skip to content

Commit

Permalink
Merge pull request #20 from SwimResults/develop
Browse files Browse the repository at this point in the history
sponsors in meeting data
  • Loading branch information
konrad2002 authored Nov 6, 2024
2 parents d2493e4 + c67fd3a commit a8d5266
Show file tree
Hide file tree
Showing 3 changed files with 21 additions and 13 deletions.
23 changes: 12 additions & 11 deletions model/meeting_data.go
Original file line number Diff line number Diff line change
@@ -1,15 +1,16 @@
package model

type MeetingData struct {
LivetimingUrl string `json:"livetiming_url,omitempty" bson:"livetiming_url,omitempty"`
WebsiteUrl string `json:"website_url,omitempty" bson:"website_url,omitempty"`
StreamUrl string `json:"stream_url,omitempty" bson:"stream_url,omitempty"`
StreamEmbedUrl string `json:"stream_embed_url,omitempty" bson:"stream_embed_url,omitempty"`
InstagramUrl string `json:"instagram_url,omitempty" bson:"instagram_url,omitempty"`
FacebookUrl string `json:"facebook_url,omitempty" bson:"facebook_url,omitempty"`
HasLivetiming bool `json:"has_livetiming,omitempty" bson:"has_livetiming,omitempty"`
HasFtpStartList bool `json:"has_ftp_start_list,omitempty" bson:"has_ftp_start_list,omitempty"`
HasFtpResultList bool `json:"has_ftp_result_list,omitempty" bson:"has_ftp_result_list,omitempty"`
FtpStartListMask string `json:"ftp_start_list_mask,omitempty" bson:"ftp_start_list_mask,omitempty"`
FtpResultListMask string `json:"ftp_result_list_mask,omitempty" bson:"ftp_result_list_mask,omitempty"`
LivetimingUrl string `json:"livetiming_url,omitempty" bson:"livetiming_url,omitempty"`
WebsiteUrl string `json:"website_url,omitempty" bson:"website_url,omitempty"`
StreamUrl string `json:"stream_url,omitempty" bson:"stream_url,omitempty"`
StreamEmbedUrl string `json:"stream_embed_url,omitempty" bson:"stream_embed_url,omitempty"`
InstagramUrl string `json:"instagram_url,omitempty" bson:"instagram_url,omitempty"`
FacebookUrl string `json:"facebook_url,omitempty" bson:"facebook_url,omitempty"`
HasLivetiming bool `json:"has_livetiming,omitempty" bson:"has_livetiming,omitempty"`
HasFtpStartList bool `json:"has_ftp_start_list,omitempty" bson:"has_ftp_start_list,omitempty"`
HasFtpResultList bool `json:"has_ftp_result_list,omitempty" bson:"has_ftp_result_list,omitempty"`
FtpStartListMask string `json:"ftp_start_list_mask,omitempty" bson:"ftp_start_list_mask,omitempty"`
FtpResultListMask string `json:"ftp_result_list_mask,omitempty" bson:"ftp_result_list_mask,omitempty"`
Sponsors []Sponsor `json:"sponsors,omitempty" bson:"sponsors,omitempty"`
}
7 changes: 7 additions & 0 deletions model/sponsor.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
package model

type Sponsor struct {
Name string `json:"name,omitempty" bson:"name,omitempty"`
ImageUrl string `json:"image_url,omitempty" bson:"image_url,omitempty"`
WebsiteUrl string `json:"website_url,omitempty" bson:"website_url,omitempty"`
}
4 changes: 2 additions & 2 deletions service/incident_service.go
Original file line number Diff line number Diff line change
Expand Up @@ -126,8 +126,8 @@ func UpdateIncidentDateByMeeting(meeting string, t time.Time, updateTimeZone boo
tz2 = t2.Location()
}

incident.End = time.Date(t1.Year(), t1.Month(), t1.Day(), t1.Hour(), t1.Minute(), t1.Second(), t1.Nanosecond(), tz1)
incident.Start = time.Date(t2.Year(), t2.Month(), t2.Day(), t2.Hour(), t2.Minute(), t2.Second(), t2.Nanosecond(), tz2)
incident.Start = time.Date(t1.Year(), t1.Month(), t1.Day(), t1.Hour(), t1.Minute(), t1.Second(), t1.Nanosecond(), tz1)
incident.End = time.Date(t2.Year(), t2.Month(), t2.Day(), t2.Hour(), t2.Minute(), t2.Second(), t2.Nanosecond(), tz2)

saved, err := UpdateIncident(incident)
if err != nil {
Expand Down

0 comments on commit a8d5266

Please sign in to comment.