Protected routes
This commit is contained in:
@@ -15,7 +15,7 @@ import (
|
||||
"gitlab.com/pactual1/backend/shared"
|
||||
)
|
||||
|
||||
func GetDevicesForContract(contractID uint64) ([]models.Device, int, error) {
|
||||
func GetDevicesForContract(contractID uint64, companyID int) ([]models.Device, int, error) {
|
||||
// Fetch the contract from the database
|
||||
var contract models.Contract
|
||||
if err := shared.GetDb().Where("id = ?", contractID).First(&contract).Error; err != nil {
|
||||
|
||||
Reference in New Issue
Block a user