{% load seizou_tags seizou_icons %}{% comment %} 売掛の残の一覧の 1 行 (masters/_rows.html が売掛の残 receivable_list のときに core/_rows.html の row_template として渡す。依頼書 N409c)。 写した元: core/_rows.html (ff88e2b4 の main) の 17-28 行。土台の表の行の形が変わったら、ここも合わせる。 写した元から変えた所: 行の行き先 (行の押下と最初の欄の link) を、土台の row.url (一覧の model の取引先の詳細) でなく、 得意先の売掛の台帳 (billing:receivable_detail。pk は取引先) にした。行き先がいつもあるので、row.url の有無の分かれは外した。 名前の欄は土台のまま取引先の小窓 (master_link) を開く (在庫の一覧の部品の名前と同じ)。 {% endcomment %}{% url 'billing:receivable_detail' row.pk as ledger_url %} {% for cell in row.cells %} {% if forloop.first and not cell.numeric and not cell.master %}{% if cell.datetime %}{{ cell.value|date:"Y-m-d H:i" }}{% elif cell.date %}{{ cell.value|date:"Y-m-d" }}{% with day=cell.value|weekday_ja %}{% if day %} ({{ day }}){% endif %}{% endwith %}{% else %}{{ cell.value|default_if_none:"" }}{% endif %} {% elif cell.numeric %}{% if cell.master %}{% master_link cell.master cell.value %}{% elif cell.negative %}{{ cell.value|yen_if:cell.money }}{% else %}{{ cell.value|yen_if:cell.money }}{% endif %} {% elif cell.date or cell.datetime %}{% if cell.datetime %}{{ cell.value|date:"Y-m-d H:i" }}{% else %}{{ cell.value|date:"Y-m-d" }}{% with day=cell.value|weekday_ja %}{% if day %} ({{ day }}){% endif %}{% endwith %}{% endif %} {% elif cell.master %}{% master_link cell.master cell.value %} {% elif cell.boolean %}{% bool_mark cell.value %} {% elif cell.status %}{% status_badge row.obj %} {% else %}{{ cell.value|default_if_none:"" }} {% endif %} {% endfor %}