Commit 876e8b84 authored by 管新明's avatar 管新明

fix: 调整中奖名单筛选条件生成代码逻辑

parent 9d665f75
...@@ -44,7 +44,15 @@ Component({ ...@@ -44,7 +44,15 @@ Component({
if ( if (
<% for(var i = 0; i < winnersFilterData.length; ++i) {%> <% for(var i = 0; i < winnersFilterData.length; ++i) {%>
<%- `${winnersFilterData[i] == 'timeRange' ? `!${winnersFilterData[i]}.length` : `!${winnersFilterData[i]}`} ${i === winnersFilterData.length - 1 ? '' : '&&'}` %> <%- `${winnersFilterData[i] == 'timeRange' ?
`!${winnersFilterData[i]}.length` :
`!${((winnersFilterData[i] == 'prizeType' || winnersFilterData[i] == 'shipStatus' || winnersFilterData[i] == 'prizeDataType') ?
`${winnersFilterData[i]} == null` :
`!${winnersFilterData[i]}`
)}`
}
${i === winnersFilterData.length - 1 ? '' : ' &&'}`
%>
<% } %> <% } %>
) { ) {
this.resetData(); this.resetData();
...@@ -146,7 +154,15 @@ Component({ ...@@ -146,7 +154,15 @@ Component({
if ( if (
<% for(var i = 0; i < winnersFilterData.length; ++i) {%> <% for(var i = 0; i < winnersFilterData.length; ++i) {%>
<%- `${winnersFilterData[i] == 'timeRange' ? `!${winnersFilterData[i]}.length` : `!${winnersFilterData[i]}`} ${i === winnersFilterData.length - 1 ? '' : '&&'}` %> <%- `${winnersFilterData[i] == 'timeRange' ?
`!${winnersFilterData[i]}.length` :
`!${((winnersFilterData[i] == 'prizeType' || winnersFilterData[i] == 'shipStatus' || winnersFilterData[i] == 'prizeDataType') ?
`${winnersFilterData[i]} == null` :
`!${winnersFilterData[i]}`
)}`
}
${i === winnersFilterData.length - 1 ? '' : ' &&'}`
%>
<% } %> <% } %>
) { ) {
this.resetData(); this.resetData();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment