diff --git a/engine/callcost.go b/engine/callcost.go index 9e6bf6244..333aa1e3c 100644 --- a/engine/callcost.go +++ b/engine/callcost.go @@ -133,8 +133,8 @@ func (cc *CallCost) ToDataCost() (*DataCost, error) { DataIndex: callDuration, MatchedSubject: ts.MatchedSubject, MatchedPrefix: ts.MatchedPrefix, - MatchedDestID: ts.MatchedDestID, - RatingPlanID: ts.RatingPlanID, + MatchedDestId: ts.MatchedDestId, + RatingPlanId: ts.RatingPlanId, } dc.DataSpans[i].Increments = make([]*DataIncrement, len(ts.Increments)) for j, incr := range ts.Increments { diff --git a/engine/calldesc_test.go b/engine/calldesc_test.go index 4690af94a..2c4f95ac1 100644 --- a/engine/calldesc_test.go +++ b/engine/calldesc_test.go @@ -133,7 +133,7 @@ func TestSplitSpansWeekend(t *testing.T) { &RatingInfo{ MatchedSubject: "*out:foehn:postpaid:foehn", MatchedPrefix: "0034678", - MatchedDestID: "SPN_MOB", + MatchedDestId: "SPN_MOB", ActivationTime: time.Date(2015, 4, 23, 0, 0, 0, 0, time.UTC), RateIntervals: []*RateInterval{ &RateInterval{ diff --git a/engine/datacost.go b/engine/datacost.go index c389a69eb..36698295a 100644 --- a/engine/datacost.go +++ b/engine/datacost.go @@ -31,7 +31,7 @@ type DataSpan struct { RateInterval *RateInterval DataIndex float64 // the data transfer so far till DataEnd Increments []*DataIncrement - MatchedSubject, MatchedPrefix, MatchedDestID, RatingPlanID string + MatchedSubject, MatchedPrefix, MatchedDestId, RatingPlanId string } type DataIncrement struct { diff --git a/engine/ratingprofile.go b/engine/ratingprofile.go index 3a3ef0cdc..b4a89f189 100644 --- a/engine/ratingprofile.go +++ b/engine/ratingprofile.go @@ -82,9 +82,9 @@ func (rpas RatingPlanActivations) GetActiveForCall(cd *CallDescriptor) RatingPla type RatingInfo struct { MatchedSubject string - RatingPlanID string + RatingPlanId string MatchedPrefix string - MatchedDestID string + MatchedDestId string ActivationTime time.Time RateIntervals RateIntervalList FallbackKeys []string @@ -163,7 +163,7 @@ func (rp *RatingProfile) GetRatingPlansForPrefix(cd *CallDescriptor) (err error) ris = append(ris, &RatingInfo{ MatchedSubject: "", MatchedPrefix: "", - MatchedDestID: "", + MatchedDestId: "", ActivationTime: cd.TimeStart, RateIntervals: nil, FallbackKeys: []string{cd.GetKey(FALLBACK_SUBJECT)}}) @@ -171,9 +171,9 @@ func (rp *RatingProfile) GetRatingPlansForPrefix(cd *CallDescriptor) (err error) if len(prefix) > 0 { ris = append(ris, &RatingInfo{ MatchedSubject: rp.Id, - RatingPlanID: rpl.Id, + RatingPlanId: rpl.Id, MatchedPrefix: prefix, - MatchedDestID: destinationId, + MatchedDestId: destinationId, ActivationTime: rpa.ActivationTime, RateIntervals: rps, FallbackKeys: rpa.FallbackKeys}) @@ -182,7 +182,7 @@ func (rp *RatingProfile) GetRatingPlansForPrefix(cd *CallDescriptor) (err error) ris = append(ris, &RatingInfo{ MatchedSubject: "", MatchedPrefix: "", - MatchedDestID: "", + MatchedDestId: "", ActivationTime: rpa.ActivationTime, RateIntervals: nil, FallbackKeys: rpa.FallbackKeys, diff --git a/engine/timespans.go b/engine/timespans.go index 10f1de9b3..23a74b477 100644 --- a/engine/timespans.go +++ b/engine/timespans.go @@ -37,7 +37,7 @@ type TimeSpan struct { RateInterval *RateInterval DurationIndex time.Duration // the call duration so far till TimeEnd Increments Increments - MatchedSubject, MatchedPrefix, MatchedDestID, RatingPlanID string + MatchedSubject, MatchedPrefix, MatchedDestId, RatingPlanId string } type Increment struct { @@ -281,8 +281,8 @@ func (ts *TimeSpan) setRatingInfo(rp *RatingInfo) { ts.ratingInfo = rp ts.MatchedSubject = rp.MatchedSubject ts.MatchedPrefix = rp.MatchedPrefix - ts.MatchedDestID = rp.MatchedDestID - ts.RatingPlanID = rp.RatingPlanID + ts.MatchedDestId = rp.MatchedDestId + ts.RatingPlanId = rp.RatingPlanId } func (ts *TimeSpan) createIncrementsSlice() {