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
e13742c5
Commit
e13742c5
authored
Apr 26, 2016
by
GoshaZotov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Bug #31908 - Значения в фильтрованном списке отображаются с учетом регистра
parent
78336013
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
23 additions
and
5 deletions
+23
-5
cell/model/WorkbookElems.js
cell/model/WorkbookElems.js
+18
-2
cell/model/autofilters.js
cell/model/autofilters.js
+5
-3
No files found.
cell/model/WorkbookElems.js
View file @
e13742c5
...
...
@@ -5131,7 +5131,10 @@ FilterColumn.prototype.clone = function() {
FilterColumn
.
prototype
.
isHideValue
=
function
(
val
,
isDateTimeFormat
,
top10Length
)
{
var
res
=
false
;
if
(
this
.
Filters
)
res
=
this
.
Filters
.
isHideValue
(
val
,
isDateTimeFormat
);
{
this
.
Filters
.
_initLowerCaseValues
();
res
=
this
.
Filters
.
isHideValue
(
val
.
toLowerCase
(),
isDateTimeFormat
);
}
else
if
(
this
.
CustomFiltersObj
)
res
=
this
.
CustomFiltersObj
.
isHideValue
(
val
);
else
if
(
this
.
Top10
)
...
...
@@ -5197,6 +5200,8 @@ function Filters() {
this
.
Values
=
{};
this
.
Dates
=
[];
this
.
Blank
=
null
;
this
.
lowerCaseValues
=
null
;
}
Filters
.
prototype
.
clone
=
function
()
{
var
i
,
res
=
new
Filters
();
...
...
@@ -5236,6 +5241,7 @@ Filters.prototype.init = function(obj) {
allFilterOpenElements
=
false
;
}
this
.
_sortDate
();
this
.
_initLowerCaseValues
();
return
allFilterOpenElements
;
};
...
...
@@ -5251,7 +5257,7 @@ Filters.prototype.isHideValue = function(val, isDateTimeFormat) {
res
=
!
this
.
Blank
?
true
:
false
;
}
else
res
=
!
this
.
Values
[
val
]
?
true
:
false
;
res
=
!
this
.
lowerCase
Values
[
val
]
?
true
:
false
;
}
return
res
;
...
...
@@ -5288,6 +5294,16 @@ Filters.prototype.linearSearch = function(val, array) {
else
return
-
1
;
};
Filters
.
prototype
.
_initLowerCaseValues
=
function
()
{
if
(
this
.
lowerCaseValues
===
null
)
{
this
.
lowerCaseValues
=
{};
for
(
var
i
in
this
.
Values
)
{
this
.
lowerCaseValues
[
i
.
toLowerCase
()]
=
true
;
}
}
};
Filters
.
prototype
.
_sortDate
=
function
()
{
if
(
this
.
Dates
&&
this
.
Dates
.
length
)
...
...
cell/model/autofilters.js
View file @
e13742c5
...
...
@@ -3399,13 +3399,15 @@
var
cell
=
worksheet
.
getCell3
(
i
,
colId
+
ref
.
c1
);
var
text
=
cell
.
getValueWithFormat
();
var
val
=
cell
.
getValueWithoutFormat
();
var
textLowerCase
=
text
.
toLowerCase
();
isDateTimeFormat
=
cell
.
getNumFormat
().
isDateTimeFormat
();
//if(isDateTimeFormat)
//dataValue = NumFormat.prototype.parseDate(val);
//check duplicate value
if
(
temp
.
hasOwnProperty
(
text
))
if
(
temp
.
hasOwnProperty
(
text
LowerCase
))
continue
;
//apply filter by current button
...
...
@@ -3437,7 +3439,7 @@
addValueToMenuObj
(
tempResult
,
count
);
temp
[
text
]
=
1
;
temp
[
text
LowerCase
]
=
1
;
count
++
;
}
}
...
...
@@ -3453,7 +3455,7 @@
worksheet
.
setRowHidden
(
false
,
i
,
i
);
addValueToMenuObj
(
tempResult
,
count
);
temp
[
text
]
=
1
;
temp
[
text
LowerCase
]
=
1
;
count
++
;
}
...
...
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