Keep compta with Pierre Grimaud API
continuous-integration/drone/push Build is passing
Details
continuous-integration/drone/push Build is passing
Details
This commit is contained in:
parent
1096c01f44
commit
70e5347878
|
@ -99,6 +99,13 @@ func convertLineType(old string) string {
|
||||||
|
|
||||||
func convertCode(t, code string) string {
|
func convertCode(t, code string) string {
|
||||||
if !strings.HasPrefix(code, "line:IDFM:") {
|
if !strings.HasPrefix(code, "line:IDFM:") {
|
||||||
|
if t == "tram" && !strings.HasPrefix(code, "T") {
|
||||||
|
code = "T" + code
|
||||||
|
}
|
||||||
|
if t == "noctilien" && !strings.HasPrefix(code, "N") {
|
||||||
|
code = "N" + code
|
||||||
|
}
|
||||||
|
|
||||||
if len(code) != 6 || !strings.HasPrefix(code, "C") {
|
if len(code) != 6 || !strings.HasPrefix(code, "C") {
|
||||||
code = searchLine(t, code)
|
code = searchLine(t, code)
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue