mirror of
https://github.com/cgrates/cgrates.git
synced 2026-02-11 18:16:24 +05:00
Uniformize the logic in model_helpers.go
This commit is contained in:
committed by
Dan Christian Bogos
parent
0303ab4fd7
commit
ac1addb6e9
@@ -1816,14 +1816,12 @@ func (tps TpSuppliers) AsTPSuppliers() (result []*utils.TPSupplierProfile) {
|
||||
sup, found := suppliersMap[tenID][supID]
|
||||
if !found {
|
||||
sup = &utils.TPSupplier{
|
||||
ID: tp.SupplierID,
|
||||
Weight: tp.SupplierWeight,
|
||||
Blocker: tp.SupplierBlocker,
|
||||
ID: tp.SupplierID,
|
||||
Weight: tp.SupplierWeight,
|
||||
Blocker: tp.SupplierBlocker,
|
||||
SupplierParameters: tp.SupplierParameters,
|
||||
}
|
||||
}
|
||||
if tp.SupplierParameters != utils.EmptyString {
|
||||
sup.SupplierParameters = tp.SupplierParameters
|
||||
}
|
||||
if tp.SupplierFilterIDs != utils.EmptyString {
|
||||
supFilterSplit := strings.Split(tp.SupplierFilterIDs, utils.INFIELD_SEP)
|
||||
sup.FilterIDs = append(sup.FilterIDs, supFilterSplit...)
|
||||
|
||||
@@ -1,5 +1,7 @@
|
||||
cgrates (0.10.2~dev) UNRELEASED; urgency=medium
|
||||
|
||||
* [SupplierS] Uniformize the logic in model_helpers.go
|
||||
|
||||
-- DanB <danb@cgrates.org> Tue, 12 May 2020 13:08:15 +0300
|
||||
|
||||
cgrates (0.10.1) UNRELEASED; urgency=medium
|
||||
|
||||
Reference in New Issue
Block a user