subtotal
subtotal copied to clipboard
Auto-derive: change rowAttrs duplicate first row.
Hi.
I'm working on auto deriving date attributes.
I've changed SubtotalPivotData.processKeys
to replace attribute name to list, if derivedAttributes
returns array instead of string.
But I have an issue there: first row of result set is duplicated.
Link to example: http://pivot.src.ilyaguy.me/examples/subtotal_pivotui_autodate.html Link to source code: https://github.com/ilyaguy/pivottable-subtotal-renderer/blob/master/subtotal.coffee#L20
Could you take a look on this?
Sorry... I couldn't understand what you mean by "first row of result set is duplicated"
Please detail the steps to reproduce the scenario.
Thanks for your feedback.

Do you see two rows with "2016 - 01 - 01" keys and "6" as totals? The first of them is generated by mistake. Thank you for help.
Yes. Thanks. Got it :)
Will need more time to understand the implications of your change:
I've changed SubtotalPivotData.processKeys to replace attribute name to list, if derivedAttributes returns array instead of string.
Will go through your code changes and let you know.