Skip to content
This repository has been archived by the owner on Mar 28, 2024. It is now read-only.

Commit

Permalink
纯文本判断
Browse files Browse the repository at this point in the history
  • Loading branch information
CN\wuwx26 committed Dec 30, 2020
1 parent 1b571f9 commit dc3cfdf
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions src/controllers/selection.js
Original file line number Diff line number Diff line change
Expand Up @@ -811,7 +811,7 @@ const selection = {
for (let r = 0; r < rlen; r++) {
let x = [].concat(d[r + curR]);
for (let c = 0; c < clen; c++) {

let originCell = x[c + curC];
let value = dataChe[r][c];
if(isRealNum(value)){
// 如果单元格设置了纯文本格式,那么就不要转成数值类型了,防止数值过大自动转成科学计数法
Expand All @@ -821,7 +821,6 @@ const selection = {
value = parseFloat(value);
}
}
let originCell = x[c + curC];
if(originCell instanceof Object){
originCell.v = value;
if(originCell.ct!=null && originCell.ct.fa!=null){
Expand Down

0 comments on commit dc3cfdf

Please sign in to comment.