Poprawki; bug fix z liczbą pojazdów w stringu wyjściowym

This commit is contained in:
2021-11-10 21:38:59 +01:00
parent 927a53217d
commit 7da3965163
6 changed files with 19 additions and 17 deletions
+3 -2
View File
@@ -486,9 +486,10 @@ export default class App extends Vue {
? stock.type
: `${stock.type}:${stock.cargo.id}`;
for (let i = 0; i < stock.count - 1; i++) s += ";" + s;
let final = s;
for (let i = 0; i < stock.count - 1; i++) final += `;${s}`;
return s;
return final;
})
.join(";");
+1 -1
View File
@@ -8,7 +8,7 @@
{ "type": "154a", "length": 26, "mass": 55, "cargo": ""},
{ "type": "158a", "length": 26, "mass": 50, "cargo": ""},
{ "type": "159a", "length": 26, "mass": 50, "cargo": ""},
{ "type": "203V", "length": 25, "mass": 12, "cargo": "stone_Fll:35"},
{ "type": "203V", "length": 8, "mass": 12, "cargo": "stone_Fll:35"},
{ "type": "208Kf", "length": 14, "mass": 15, "cargo": "mass_20:35;mass_30:45;mass_40:55"},
{ "type": "209c", "length": 25, "mass": 43, "cargo": ""},
{ "type": "29R", "length": 13, "mass": 23, "cargo": "mass_20:43;mass_30:53;mass_40:63"},