Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
S
sdkjs
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Boris Kocherov
sdkjs
Commits
5880c0cd
Commit
5880c0cd
authored
Feb 28, 2017
by
Alexander.Trofimov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix date matching in logical criterias
parent
ff3d7eca
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
10 additions
and
5 deletions
+10
-5
cell/model/FormulaObjects/mathematicFunctions.js
cell/model/FormulaObjects/mathematicFunctions.js
+2
-2
cell/model/FormulaObjects/parserFormula.js
cell/model/FormulaObjects/parserFormula.js
+5
-0
cell/model/FormulaObjects/statisticalFunctions.js
cell/model/FormulaObjects/statisticalFunctions.js
+3
-3
No files found.
cell/model/FormulaObjects/mathematicFunctions.js
View file @
5880c0cd
...
@@ -4045,7 +4045,7 @@ cSQRTPI.prototype.getInfo = function () {
...
@@ -4045,7 +4045,7 @@ cSQRTPI.prototype.getInfo = function () {
}
else
{
}
else
{
search
=
arg1
;
search
=
arg1
;
}
}
valueForSearching
=
AscCommonExcel
.
parseNum
(
search
)
?
new
cNumber
(
search
)
:
new
cString
(
search
);
valueForSearching
=
AscCommonExcel
.
matchingValue
(
search
);
if
(
cElementType
.
cellsRange
===
arg0
.
type
)
{
if
(
cElementType
.
cellsRange
===
arg0
.
type
)
{
var
arg0Matrix
=
arg0
.
getMatrix
(),
arg2Matrix
=
arg2
.
getMatrix
(),
valMatrix2
;
var
arg0Matrix
=
arg0
.
getMatrix
(),
arg2Matrix
=
arg2
.
getMatrix
(),
valMatrix2
;
for
(
var
i
=
0
;
i
<
arg0Matrix
.
length
;
i
++
)
{
for
(
var
i
=
0
;
i
<
arg0Matrix
.
length
;
i
++
)
{
...
@@ -4138,7 +4138,7 @@ cSQRTPI.prototype.getInfo = function () {
...
@@ -4138,7 +4138,7 @@ cSQRTPI.prototype.getInfo = function () {
search
=
arg2
;
search
=
arg2
;
oper
=
null
;
oper
=
null
;
}
}
valueForSearching
=
AscCommonExcel
.
parseNum
(
search
)
?
new
cNumber
(
search
)
:
new
cString
(
search
);
valueForSearching
=
AscCommonExcel
.
matchingValue
(
search
);
var
arg1Matrix
=
arg1
.
getMatrix
();
var
arg1Matrix
=
arg1
.
getMatrix
();
if
(
arg0Matrix
.
length
!==
arg1Matrix
.
length
)
{
if
(
arg0Matrix
.
length
!==
arg1Matrix
.
length
)
{
...
...
cell/model/FormulaObjects/parserFormula.js
View file @
5880c0cd
...
@@ -5364,6 +5364,10 @@ function parseNum( str ) {
...
@@ -5364,6 +5364,10 @@ function parseNum( str ) {
return
!
isNaN
(
str
);
return
!
isNaN
(
str
);
}
}
function
matchingValue
(
search
)
{
var
parseRes
=
AscCommon
.
g_oFormatParser
.
parse
(
search
);
return
parseRes
?
new
cNumber
(
parseRes
.
value
)
:
new
cString
(
search
);
}
function
matching
(
x
,
y
,
operator
)
{
function
matching
(
x
,
y
,
operator
)
{
var
res
=
false
,
rS
;
var
res
=
false
,
rS
;
if
(
cElementType
.
string
===
y
.
type
)
{
if
(
cElementType
.
string
===
y
.
type
)
{
...
@@ -5673,6 +5677,7 @@ function rtl_math_erfc( x ) {
...
@@ -5673,6 +5677,7 @@ function rtl_math_erfc( x ) {
window
[
'
AscCommonExcel
'
].
parseNum
=
parseNum
;
window
[
'
AscCommonExcel
'
].
parseNum
=
parseNum
;
window
[
'
AscCommonExcel
'
].
matching
=
matching
;
window
[
'
AscCommonExcel
'
].
matching
=
matching
;
window
[
'
AscCommonExcel
'
].
matchingValue
=
matchingValue
;
window
[
'
AscCommonExcel
'
].
GetDiffDate360
=
GetDiffDate360
;
window
[
'
AscCommonExcel
'
].
GetDiffDate360
=
GetDiffDate360
;
window
[
'
AscCommonExcel
'
].
searchRegExp2
=
searchRegExp2
;
window
[
'
AscCommonExcel
'
].
searchRegExp2
=
searchRegExp2
;
window
[
'
AscCommonExcel
'
].
rtl_math_erf
=
rtl_math_erf
;
window
[
'
AscCommonExcel
'
].
rtl_math_erf
=
rtl_math_erf
;
...
...
cell/model/FormulaObjects/statisticalFunctions.js
View file @
5880c0cd
...
@@ -588,7 +588,7 @@
...
@@ -588,7 +588,7 @@
}
else
{
}
else
{
search
=
arg1
;
search
=
arg1
;
}
}
valueForSearching
=
parseNum
(
search
)
?
new
cNumber
(
search
)
:
new
cString
(
search
);
valueForSearching
=
AscCommonExcel
.
matchingValue
(
search
);
if
(
cElementType
.
cellsRange
===
arg0
.
type
)
{
if
(
cElementType
.
cellsRange
===
arg0
.
type
)
{
ws
=
arg0
.
getWS
();
ws
=
arg0
.
getWS
();
var
tmpCellArg0
=
arg0
.
getRange
().
getCells
()[
0
],
tmpCellArg2
=
arg2
.
getRange
(),
offset
,
bbox
,
r2
;
var
tmpCellArg0
=
arg0
.
getRange
().
getCells
()[
0
],
tmpCellArg2
=
arg2
.
getRange
(),
offset
,
bbox
,
r2
;
...
@@ -1104,7 +1104,7 @@
...
@@ -1104,7 +1104,7 @@
}
else
{
}
else
{
search
=
arg1
;
search
=
arg1
;
}
}
valueForSearching
=
parseNum
(
search
)
?
new
cNumber
(
search
)
:
new
cString
(
search
);
valueForSearching
=
AscCommonExcel
.
matchingValue
(
search
);
if
(
cElementType
.
cellsRange
===
arg0
.
type
)
{
if
(
cElementType
.
cellsRange
===
arg0
.
type
)
{
arg0
.
foreach2
(
function
(
_val
)
{
arg0
.
foreach2
(
function
(
_val
)
{
_count
+=
matching
(
_val
,
valueForSearching
,
oper
);
_count
+=
matching
(
_val
,
valueForSearching
,
oper
);
...
@@ -1173,7 +1173,7 @@
...
@@ -1173,7 +1173,7 @@
}
else
{
}
else
{
search
=
arg1
;
search
=
arg1
;
}
}
valueForSearching
=
parseNum
(
search
)
?
new
cNumber
(
search
)
:
new
cString
(
search
);
valueForSearching
=
AscCommonExcel
.
matchingValue
(
search
);
arg1Matrix
=
arg0
.
getMatrix
();
arg1Matrix
=
arg0
.
getMatrix
();
if
(
!
arg0Matrix
)
{
if
(
!
arg0Matrix
)
{
arg0Matrix
=
arg1Matrix
;
arg0Matrix
=
arg1Matrix
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment