mirror of
https://github.com/cgrates/cgrates.git
synced 2026-02-25 09:08:45 +05:00
Finish implementation for fwv in EventExporter
This commit is contained in:
committed by
Dan Christian Bogos
parent
31387e2fe2
commit
578d7030bf
@@ -138,6 +138,86 @@
|
||||
{"tag": "TotalSMSUsage", "path": "*trl.TotalSMSUsage", "type": "*variable", "value": "~*dc.TotalSMSUsage"},
|
||||
{"tag": "TotalCost", "path": "*trl.TotalCost", "type": "*variable", "value": "~*dc.TotalCost{*round:4}"},
|
||||
],
|
||||
},
|
||||
{
|
||||
"id": "FwvExporter",
|
||||
"type": "*file_fwv",
|
||||
"export_path": "/tmp/testFWV",
|
||||
"tenant": "cgrates.org",
|
||||
"flags": ["*attributes"],
|
||||
"attribute_context": "customContext",
|
||||
"attempts": 1,
|
||||
"field_separator": ",",
|
||||
"filters": ["*string:~*req.ExporterUsed:FWVExporter"],
|
||||
"fields":[
|
||||
{"tag": "TypeOfRecord", "path": "*hdr.TypeOfRecord", "type": "*constant",
|
||||
"value": "10", "width": 2},
|
||||
{"tag": "Filler1", "path": "*hdr.Filler1", "type": "*filler", "width": 3},
|
||||
{"tag": "DistributorCode", "path": "*hdr.DistributorCode",
|
||||
"type": "*constant", "value": "VOI","width": 3},
|
||||
{"tag": "FileSeqNr", "path": "*hdr.FileSeqNr", "type": "*variable",
|
||||
"value": "~*dc.ExportID","width": 5,"strip": "*right","padding": "*zeroleft"},
|
||||
{"tag": "FileCreationTime", "path": "*hdr.FileCreationTime",
|
||||
"type": "*variable","value":"~*dc.TimeNow{*time_string:020106150400}",
|
||||
"width": 12 },
|
||||
{"tag": "FileVersion", "path": "*hdr.FileVersion", "type": "*constant",
|
||||
"value": "01","width": 2},
|
||||
{"tag": "Filler2", "path": "*hdr.Filler2", "type": "*filler",
|
||||
"width": 105},
|
||||
|
||||
{"tag": "TypeOfRecord", "path": "*exp.TypeOfRecord", "type": "*constant",
|
||||
"value": "20","width": 2},
|
||||
{"tag": "Account", "path": "*exp.Account", "type": "*variable",
|
||||
"value": "~*req.Account","width": 12,"strip": "*left","padding": "*right"},
|
||||
{"tag": "Subject", "path": "*exp.Subject", "type": "*variable",
|
||||
"value": "~*req.Subject","width": 5,"strip": "*left","padding": "*right"},
|
||||
{"tag": "CLI", "path": "*exp.CLI", "type": "*constant",
|
||||
"value": "cli","width": 15,"strip": "*xright","padding": "*right"},
|
||||
{"tag": "Destination", "path": "*exp.Destination", "type": "*variable",
|
||||
"value": "~*req.Destination","width": 24,"strip": "*xright","padding": "*right"},
|
||||
{"tag": "ToR", "path": "*exp.ToR", "type": "*constant", "value": "02","width": 2},
|
||||
{"tag": "SubtypeTOR", "path": "*exp.SubtypeTOR", "type": "*constant", "value": "11",
|
||||
"width": 4, "padding": "*right"},
|
||||
{"tag": "SetupTime", "path": "*exp.SetupTime", "type": "*variable",
|
||||
"value": "~*req.SetupTime{*time_string:020106150400}", "width": 12, "padding": "*right","strip": "*right"},
|
||||
{"tag": "Duration", "path": "*exp.Duration", "type": "*variable", "value": "~*req.Usage",
|
||||
"width": 6, "strip": "*right","padding": "*right","layout": "seconds"},
|
||||
{"tag": "DataVolume", "path": "*exp.DataVolume", "type": "*filler","width": 6},
|
||||
{"tag": "TaxCode", "path": "*exp.TaxCode", "type": "*constant","value":"1","width": 1},
|
||||
{"tag": "OperatorCode", "path": "*exp.OperatorCode", "type": "*constant","value":"opercode",
|
||||
"width": 2, "strip": "*right", "padding": "*right"},
|
||||
{"tag": "ProductId", "path": "*exp.ProductId", "type": "*variable","value":"~*req.ProductId",
|
||||
"width": 5, "strip": "*right", "padding": "*right"},
|
||||
{"tag": "NetworkId", "path": "*exp.NetworkId", "type": "*constant","value":"3", "width": 1},
|
||||
{"tag": "CallId", "path": "*exp.CallId", "type": "*variable","value":"~*req.OriginID",
|
||||
"width": 16, "padding": "*right"},
|
||||
{"tag": "Filler1", "path": "*exp.Filler1", "type": "*filler", "width": 8},
|
||||
{"tag": "Filler2", "path": "*exp.Filler2", "type": "*filler", "width": 8},
|
||||
{"tag": "TerminationCode", "path": "*exp.TerminationCode", "type": "*variable",
|
||||
"value":"~*req.Operator;~*req.Product", "width": 5,"strip": "*right","padding": "*right"},
|
||||
{"tag": "Cost", "path": "*exp.Cost", "type": "*variable", "value": "~*req.Cost{*round:5}",
|
||||
"width": 9, "padding": "*zeroleft"},
|
||||
{"tag": "DestinationPrivacy", "path": "*exp.DestinationPrivacy", "type": "*masked_destination",
|
||||
"width": 1},
|
||||
|
||||
{"tag": "TypeOfRecord", "path": "*trl.TypeOfRecord", "type": "*constant",
|
||||
"value": "90", "width": 2},
|
||||
{"tag": "Filler1", "path": "*trl.Filler1", "type": "*filler", "width": 3},
|
||||
{"tag": "DistributorCode", "path": "*trl.DistributorCode",
|
||||
"type": "*constant", "value": "VOI","width": 3},
|
||||
{"tag": "FileSeqNr", "path": "*trl.FileSeqNr", "type": "*variable",
|
||||
"value": "~*dc.ExportID","width": 5,"strip": "*right","padding": "*zeroleft"},
|
||||
{"tag": "NumberOfRecords", "path": "*trl.NumberOfRecords",
|
||||
"type": "*variable", "value": "~*dc.NumberOfEvents","width": 6,"padding": "*zeroleft"},
|
||||
{"tag": "CdrsDuration", "path": "*trl.CdrsDuration", "type": "*variable",
|
||||
"value": "~*dc.TotalDuration","width": 8,"padding":"*zeroleft","layout": "seconds"},
|
||||
{"tag": "FirstCdrTime", "path": "*trl.FirstCdrTime", "type": "*variable",
|
||||
"value": "~*dc.FirstEventATime{*time_string:020106150400}", "width": 12},
|
||||
{"tag": "LastCdrTime", "path": "*hdr.LastCdrTime", "type": "*variable",
|
||||
"value": "~*dc.LastEventATime{*time_string:020106150400}", "width": 12,},
|
||||
{"tag": "Filler2", "path": "*trl.Filler2", "type": "*filler",
|
||||
"width": 93}
|
||||
],
|
||||
}
|
||||
]
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user