498
次編輯
小 (页面标题解析修复(参见 rev 2778)) |
小 (IV-α) |
||
第31行: | 第31行: | ||
local box = mw.html.create("table"):addClass("rotable") | local box = mw.html.create("table"):addClass("rotable") | ||
box:tag("tr"):tag("th"):wikitext("难度I"):done() | -- 如果有alpha难度,表格要多一列。 | ||
local alpha = query("ratingA") | |||
local tag = box:tag("tr"):tag("th"):wikitext("难度I"):done() | |||
if args["难度I曲目定数"] and args["难度II曲目定数"] and args["难度III曲目定数"] and args["难度IV曲目定数"] | :tag("th"):wikitext("难度II"):done() | ||
:tag("th"):wikitext("难度III"):done() | |||
:tag("th"):wikitext("难度IV"):done() | |||
if alpha then tag:tag("th"):wikitext("难度IV-α"):done() end | |||
if args["难度I曲目定数"] and args["难度II曲目定数"] and args["难度III曲目定数"] and args["难度IV曲目定数"] and (not alpha and args["难度IV_Alpha曲目定数"]) | |||
then | then | ||
box:tag("tr"):tag("td"):wikitext(args["难度I曲目定数"]):done() | tag = box:tag("tr"):tag("td"):wikitext(args["难度I曲目定数"]):done() | ||
:tag("td"):wikitext(args["难度II曲目定数"]):done() | :tag("td"):wikitext(args["难度II曲目定数"]):done() | ||
:tag("td"):wikitext(args["难度III曲目定数"]):done() | :tag("td"):wikitext(args["难度III曲目定数"]):done() | ||
:tag("td"):wikitext(args["难度IV曲目定数"]) | :tag("td"):wikitext(args["难度IV曲目定数"]):done() | ||
if alpha then tag:tag("td"):wikitext(args["难度IV_Alpha曲目定数"]):done() end | |||
else | else | ||
box:tag("tr"):tag("td"):wikitext(query("rating1")):done() | tag = box:tag("tr"):tag("td"):wikitext(query("rating1")):done() | ||
:tag("td"):wikitext(query("rating2")):done() | :tag("td"):wikitext(query("rating2")):done() | ||
:tag("td"):wikitext(query("rating3")):done() | :tag("td"):wikitext(query("rating3")):done() | ||
:tag("td"):wikitext(query("rating4")) | :tag("td"):wikitext(query("rating4")):done() | ||
if alpha then tag:tag("td"):wikitext(query("ratingA")):done() end | |||
end | end | ||