Documentation ¶
Index ¶
- func DeleteOneCompany(ctx context.Context, db *mongo.Database, companyID primitive.ObjectID) (*mongo.DeleteResult, error)
- func DeleteOneService(ctx context.Context, db *mongo.Database, companyID primitive.ObjectID, ...) (*mongo.UpdateResult, error)
- func FindManyCompanies(ctx context.Context, db *mongo.Database, startValue primitive.ObjectID, ...) (*mongo.Cursor, error)
- func FindManyCompaniesByIds(ctx context.Context, db *mongo.Database, companyIDS []primitive.ObjectID, ...) (*mongo.Cursor, error)
- func FindManyServices(ctx context.Context, db *mongo.Database, companyID primitive.ObjectID, ...) (*mongo.Cursor, error)
- func FindOneCompany(ctx context.Context, db *mongo.Database, companyID primitive.ObjectID) *mongo.SingleResult
- type Company
- type CompanyUpdate
- type Service
- type ServiceUpdate
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func DeleteOneCompany ¶
func DeleteOneService ¶
func FindManyCompanies ¶
func FindManyCompaniesByIds ¶
func FindManyServices ¶
func FindOneCompany ¶
Types ¶
type Company ¶
type Company struct { ID primitive.ObjectID `bson:"_id,omitempty"` Name string `bson:"name,omitempty"` Type string `bson:"type,omitempty"` Localisation string `bson:"localisation,omitempty"` ShortDescription string `bson:"short_description,omitempty"` LongDescription string `bson:"long_description,omitempty"` Services []Service `bson:"services,omitempty"` }
type CompanyUpdate ¶
type CompanyUpdate struct { Name *string `bson:"name,omitempty"` Type *string `bson:"type,omitempty"` Localisation *string `bson:"localisation,omitempty"` ShortDescription *string `bson:"short_description,omitempty"` LongDescription *string `bson:"long_description,omitempty"` Services []Service `bson:"services,omitempty"` }
type Service ¶
Click to show internal directories.
Click to hide internal directories.