文顶顶
5 years ago
committed by
GitHub
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with
15 additions and
8 deletions
-
src/controllers/menuButton.js
-
src/global/format.js
-
src/global/setdata.js
|
|
|
@ -4226,23 +4226,25 @@ const menuButton = { |
|
|
|
let cell = null; |
|
|
|
|
|
|
|
if(type == "c"){ |
|
|
|
cell = d[ed_m][fix]; |
|
|
|
cell = d[ed_m + 1][fix]; |
|
|
|
} |
|
|
|
else{ |
|
|
|
cell = d[fix][ed_m]; |
|
|
|
cell = d[fix][ed_m + 1]; |
|
|
|
} |
|
|
|
|
|
|
|
/* 备注:在搜寻的时候排除自己以解决单元格函数引用自己的问题 */ |
|
|
|
if(cell != null && cell.v != null && cell.v.toString().length > 0){ |
|
|
|
let c = ed_m; |
|
|
|
let c = ed_m + 1; |
|
|
|
|
|
|
|
if(type == "c"){ |
|
|
|
cell = d[ed_m][fix]; |
|
|
|
cell = d[ed_m + 1][fix]; |
|
|
|
} |
|
|
|
else{ |
|
|
|
cell = d[fix][ed_m]; |
|
|
|
cell = d[fix][ed_m + 1]; |
|
|
|
} |
|
|
|
|
|
|
|
while ( cell != null && cell.v != null && cell.v.toString().length > 0) { |
|
|
|
|
|
|
|
c++; |
|
|
|
let len = null; |
|
|
|
|
|
|
|
@ -4274,10 +4276,10 @@ const menuButton = { |
|
|
|
} |
|
|
|
else{ |
|
|
|
if(type == "c"){ |
|
|
|
_this.backFormulaInput(d, ed_m, fix, [st_m, ed_m], [fix ,fix], formula); |
|
|
|
_this.backFormulaInput(d, ed_m + 1, fix, [st_m, ed_m], [fix ,fix], formula); |
|
|
|
} |
|
|
|
else{ |
|
|
|
_this.backFormulaInput(d, fix, ed_m, [fix ,fix], [st_m, ed_m], formula); |
|
|
|
_this.backFormulaInput(d, fix, ed_m + 1, [fix ,fix], [st_m, ed_m], formula); |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
@ -934,6 +934,7 @@ var make_ssf = function make_ssf(SSF) { |
|
|
|
SSF.is_date = fmt_is_date; |
|
|
|
|
|
|
|
function eval_fmt(fmt, v, opts, flen) { |
|
|
|
let tempV = v; |
|
|
|
var out = [], |
|
|
|
o = "", |
|
|
|
i = 0, |
|
|
|
@ -1350,7 +1351,8 @@ var make_ssf = function make_ssf(SSF) { |
|
|
|
out[i].v = write_num(out[i].t, out[i].v, myv); |
|
|
|
out[i].t = 't'; |
|
|
|
} |
|
|
|
var retval = ""; |
|
|
|
// var retval = "";
|
|
|
|
var retval = tempV === 0 ? "0" : ""; |
|
|
|
for (i = 0; i !== out.length; ++i) |
|
|
|
if (out[i] != null) retval += out[i].v; |
|
|
|
return retval; |
|
|
|
|
|
|
|
@ -150,6 +150,9 @@ function setcellvalue(r, c, d, v) { |
|
|
|
// cell.m = mask[0].toString();
|
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
/* 如果是公式计算之后得到的结果:总是设置对齐方式为右对齐 */ |
|
|
|
cell.ht = cell.ht || 2; |
|
|
|
} |
|
|
|
else if(cell.ct != null && cell.ct.fa == "@"){ |
|
|
|
cell.m = vupdateStr; |
|
|
|
|