Add missing platform directory

This commit is contained in:
Eli Ribble 2026-01-04 17:30:28 -07:00
parent 71419a94d9
commit ffade2ae56
2 changed files with 40 additions and 0 deletions

25
platform/ios.go Normal file
View file

@ -0,0 +1,25 @@
package platform
import (
"context"
"time"
"github.com/Gleipnir-Technology/nidus-sync/db"
"github.com/Gleipnir-Technology/nidus-sync/db/models"
)
func fieldseeker(ctx context.Context, u *models.User, since *time.Time) (fsync FieldseekerRecordsSync, err error) {
pl, err := u.R.Organization.Pointlocations().All(ctx, db.PGInstance.BobDB)
if err != nil {
return
}
fsync.MosquitoSources = pl
return fsync, err
}
func ContentClientIos(ctx context.Context, u *models.User, since *time.Time) (csync ClientSync, err error) {
fsync, err := fieldseeker(ctx, u, since)
return ClientSync{
Fieldseeker: fsync,
}, err
}

15
platform/type.go Normal file
View file

@ -0,0 +1,15 @@
package platform
import (
"time"
"github.com/Gleipnir-Technology/nidus-sync/db/models"
)
type ClientSync struct {
Fieldseeker FieldseekerRecordsSync
Since time.Time
}
type FieldseekerRecordsSync struct {
MosquitoSources models.FieldseekerPointlocationSlice
}