-
Bug
-
Resolution: Fixed
-
Critical
-
3.9.1
-
Security Level: Jimmy
-
None
Steps to Reproduce
Open attached book1.xlsx in zss
The value of E3 cell is 0.015, formatted as percentage, rounded with 0 decimals
It's display result is 2%
double click on the cell to edit it
Current Result
edit mode display "2%"
Leaving the cell will save "0.02" as value
Expected Result
edit mode should display "1.5%"
leaving the cell without editing its value should not loose rounding precision
Debug Info
Text / value switch happen in zss.DataPanel.prototype._openEditbox
Root Cause
Workaround
<script><![CDATA[ zk.afterLoad('zss', function() { var xDataPanel = {}; zk.override(zss.DataPanel.prototype, xDataPanel ,{ _openEditbox: function(d, g) { var b = this.sheet , a = b.getFocusedCell(); if (a != null) { if (b.state == zss.SSheetCtrl.START_EDIT) { var c = b.inlineEditor , f = b.getLastFocus() , e = !d && d != "" ? b.isPercentCell(a.r, a.c) ? (parseFloat(a.edit)*100)+"%" : a.edit : d; c.edit(a.comp, f.row, f.column, e ? e : "", g); b.state = zss.SSheetCtrl.EDITING } } } });//zk.override });//zk.afterLoad ]]></script>
- relates to
-
ZSS-1214 Support percentage mask when editing a cell applied with "Percentage" format
- Closed