...
|
...
|
@@ -92,7 +92,7 @@ func (repo *DepartmentRepository) FindOne(queryOptions map[string]interface{}) ( |
|
|
func (repo *DepartmentRepository) Find(queryOptions map[string]interface{}) (int, []*domain.Department, error) {
|
|
|
tx := repo.transactionContext.PgTx
|
|
|
dparmentModel := []models.Department{}
|
|
|
query := tx.Model(&dparmentModel).Where("delete_at isnull")
|
|
|
query := tx.Model(&dparmentModel)
|
|
|
if v, ok := queryOptions["id"]; ok {
|
|
|
query.Where("id=?", v)
|
|
|
}
|
...
|
...
|
|