Opened 3 years ago

Closed 3 years ago

#18926 closed defect (invalid)

In dojox/dtl counter0 not count from 0 (zero) but return empty - DOJO 1.11.2

Reported by: leader Owned by: Neil Roberts
Priority: undecided Milestone: 1.12.1
Component: DojoX DTL Version: 1.11.2
Keywords: Cc:
Blocked By: Blocking:

Description

This template work well with Dojo 1.9.2 but with version 1.11.2 the counter counter0 on the first array element return empty string!

{% for datarow in Rows_array %}
  <tr class="DivSelect_{% cycle Pari,Dispari %}">
    <td class="DivSelect_Detail"><button class="DivSelect_Detail" onclick="window.Input_DivSelect_PopupDetail('forward', {{forloop.counter0}}, {})">DET</button></td>
{% for datacol in Cols %}
    <td class="DivSelect_Column" onclick="window.Input_DivSelect_PopupHandler({{forloop.parentloop.counter0}})">&nbsp;</td>
{% endfor %}
  </tr>   
{% endfor %}

To temporary resolve this bug I have change in this manner:

{% for datarow in Rows_array %}
  <tr class="DivSelect_{% cycle Pari,Dispari %}">
    <td class="DivSelect_Detail"><button class="DivSelect_Detail" onclick="window.Input_DivSelect_PopupDetail('forward', {{forloop.counter}}-1, {})">DET</button></td>
{% for datacol in Cols %}
    <td class="DivSelect_Column" onclick="window.Input_DivSelect_PopupHandler({{forloop.parentloop.counter}}-1)">&nbsp;</td>
{% endfor %}
  </tr>   
{% endfor %}

Change History (3)

comment:1 Changed 3 years ago by dylan

Milestone: tbd1.12
Status: newpending

My guess is that either https://github.com/dojo/dojox/commit/1dcf38ea5f15079355ac20df0b372753da9dd6bc (#17251) or https://github.com/dojo/dojox/commit/fbd5c210de892042af350bf1ff909d9024c6e8ac (#17486) is what is breaking you.

If it's the former, there's a fix in https://github.com/dojo/dojox/commit/5099079f4af2ba0d848ba6ec558c779593311863 (#18865) which will make its way into the next release. If it's the latter, then it's a subtle change in behavior that fixes another issue.

comment:2 Changed 3 years ago by dylan

Milestone: 1.121.12.1

comment:3 Changed 3 years ago by trac-o-bot

Resolution: invalid
Status: pendingclosed

Because we get so many tickets, we often need to return them to the initial reporter for more information. If that person does not reply within 14 days, the ticket will automatically be closed, and that has happened in this case. If you still are interested in pursuing this issue, feel free to add a comment with the requested information and we will be happy to reopen the ticket if it is still valid. Thanks!

Note: See TracTickets for help on using tickets.