電車・バス・空路の表示

このコミットが含まれているのは:
守矢諏訪子 2023-06-22 23:19:16 +09:00
コミット 7e75e8d558
2個のファイルの変更4行の追加1行の削除

ファイルの表示

@ -1,2 +1,5 @@
# 1.0.1
* -vを修正
# 1.0.0
* 最初リリース

ファイルの表示

@ -78,7 +78,7 @@ func scrape (gurl string) []Route {
e.ForEach("div.routeDetail div.fareSection div.access", func (jf int, elf *colly.HTMLElement) {
Fares.Stops = nil
if jf == j {
Fares.Train = strings.ReplaceAll(elf.ChildText("li.transport div"), "[train]", "")
Fares.Train = strings.ReplaceAll(strings.ReplaceAll(strings.ReplaceAll(elf.ChildText("li.transport div"), "[train]", "【電車】"), "[bus]", "【バス】"), "[air]", "【空路】")
Fares.Platform = elf.ChildText("li.platform")
Fares.Color = strings.ReplaceAll(elf.ChildAttr("span", "style"), "border-color:#", "")
elf.ForEach("li.stop ul", func (js int, els *colly.HTMLElement) {