Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
A
atlas
Project
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
dataplatform
atlas
Commits
7435801a
Commit
7435801a
authored
5 years ago
by
kevalbhatt
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
ATLAS-3446:UI: Regression: Attribute filter buttons are highlighted by default
parent
5dffddd0
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
29 additions
and
19 deletions
+29
-19
SearchLayoutView.js
dashboardv2/public/js/views/search/SearchLayoutView.js
+29
-19
No files found.
dashboardv2/public/js/views/search/SearchLayoutView.js
View file @
7435801a
...
@@ -102,18 +102,18 @@ define(['require',
...
@@ -102,18 +102,18 @@ define(['require',
pageLimit
:
this
.
value
?
this
.
value
.
pageLimit
:
null
pageLimit
:
this
.
value
?
this
.
value
.
pageLimit
:
null
},
},
basic
:
{
basic
:
{
query
:
this
.
value
?
this
.
value
.
query
:
null
,
query
:
this
.
value
?
this
.
value
.
query
:
null
,
type
:
this
.
value
?
this
.
value
.
type
:
null
,
type
:
this
.
value
?
this
.
value
.
type
:
null
,
tag
:
this
.
value
?
this
.
value
.
tag
:
null
,
tag
:
this
.
value
?
this
.
value
.
tag
:
null
,
term
:
this
.
value
?
this
.
value
.
term
:
null
,
term
:
this
.
value
?
this
.
value
.
term
:
null
,
attributes
:
this
.
value
?
this
.
value
.
attributes
:
null
,
attributes
:
this
.
value
?
this
.
value
.
attributes
:
null
,
tagFilters
:
this
.
value
?
this
.
value
.
tagFilters
:
null
,
tagFilters
:
this
.
value
?
this
.
value
.
tagFilters
:
null
,
pageOffset
:
this
.
value
?
this
.
value
.
pageOffset
:
null
,
pageOffset
:
this
.
value
?
this
.
value
.
pageOffset
:
null
,
pageLimit
:
this
.
value
?
this
.
value
.
pageLimit
:
null
,
pageLimit
:
this
.
value
?
this
.
value
.
pageLimit
:
null
,
entityFilters
:
this
.
value
?
this
.
value
.
entityFilters
:
null
,
entityFilters
:
this
.
value
?
this
.
value
.
entityFilters
:
null
,
includeDE
:
this
.
value
?
this
.
value
.
includeDE
:
null
,
includeDE
:
this
.
value
?
this
.
value
.
includeDE
:
null
,
excludeST
:
this
.
value
?
this
.
value
.
excludeST
:
null
,
excludeST
:
this
.
value
?
this
.
value
.
excludeST
:
null
,
excludeSC
:
this
.
value
?
this
.
value
.
excludeSC
:
null
excludeSC
:
this
.
value
?
this
.
value
.
excludeSC
:
null
}
}
};
};
if
(
!
this
.
value
)
{
if
(
!
this
.
value
)
{
...
@@ -263,7 +263,7 @@ define(['require',
...
@@ -263,7 +263,7 @@ define(['require',
isTypeEl
=
$el
.
data
(
'id'
)
==
"typeLOV"
,
isTypeEl
=
$el
.
data
(
'id'
)
==
"typeLOV"
,
select2Data
=
$el
.
select2
(
'data'
);
select2Data
=
$el
.
select2
(
'data'
);
if
(
e
.
type
==
"change"
&&
select2Data
)
{
if
(
e
.
type
==
"change"
&&
select2Data
)
{
var
value
=
(
_
.
isEmpty
(
select2Data
)
?
select2Data
:
_
.
first
(
select2Data
).
id
)
||
this
.
value
.
tag
,
var
value
=
(
_
.
isEmpty
(
select2Data
)
?
select2Data
:
_
.
first
(
select2Data
).
id
),
key
=
"tag"
,
key
=
"tag"
,
filterType
=
isBasicSearch
?
'tagFilters'
:
null
,
filterType
=
isBasicSearch
?
'tagFilters'
:
null
,
value
=
value
&&
value
.
length
?
value
:
null
;
value
=
value
&&
value
.
length
?
value
:
null
;
...
@@ -486,7 +486,9 @@ define(['require',
...
@@ -486,7 +486,9 @@ define(['require',
var
isTypeOnly
=
options
&&
options
.
isTypeOnly
;
var
isTypeOnly
=
options
&&
options
.
isTypeOnly
;
this
.
ui
.
typeLov
.
empty
();
this
.
ui
.
typeLov
.
empty
();
var
typeStr
=
'<option></option>'
,
var
typeStr
=
'<option></option>'
,
tagStr
=
typeStr
;
tagStr
=
typeStr
,
foundNewClassification
=
false
,
optionsValue
=
this
.
options
.
value
;
this
.
typeHeaders
.
fullCollection
.
each
(
function
(
model
)
{
this
.
typeHeaders
.
fullCollection
.
each
(
function
(
model
)
{
var
name
=
Utils
.
getName
(
model
.
toJSON
(),
'name'
);
var
name
=
Utils
.
getName
(
model
.
toJSON
(),
'name'
);
if
(
model
.
get
(
'category'
)
==
'ENTITY'
&&
(
serviceTypeToBefiltered
&&
serviceTypeToBefiltered
.
length
?
_
.
contains
(
serviceTypeToBefiltered
,
model
.
get
(
'serviceType'
))
:
true
))
{
if
(
model
.
get
(
'category'
)
==
'ENTITY'
&&
(
serviceTypeToBefiltered
&&
serviceTypeToBefiltered
.
length
?
_
.
contains
(
serviceTypeToBefiltered
,
model
.
get
(
'serviceType'
))
:
true
))
{
...
@@ -495,9 +497,21 @@ define(['require',
...
@@ -495,9 +497,21 @@ define(['require',
}
}
if
(
isTypeOnly
==
undefined
&&
model
.
get
(
'category'
)
==
'CLASSIFICATION'
)
{
if
(
isTypeOnly
==
undefined
&&
model
.
get
(
'category'
)
==
'CLASSIFICATION'
)
{
var
tagEntityCount
=
that
.
entityCountObj
.
tag
.
tagEntities
[
name
];
var
tagEntityCount
=
that
.
entityCountObj
.
tag
.
tagEntities
[
name
];
if
(
optionsValue
)
{
// to check if wildcard classification is present in our data
if
(
name
===
optionsValue
.
tag
)
{
foundNewClassification
=
true
;
}
}
tagStr
+=
'<option value="'
+
(
name
)
+
'" data-name="'
+
(
name
)
+
'">'
+
(
name
)
+
' '
+
(
tagEntityCount
?
"("
+
_
.
numberFormatWithComa
(
tagEntityCount
)
+
")"
:
''
)
+
'</option>'
;
tagStr
+=
'<option value="'
+
(
name
)
+
'" data-name="'
+
(
name
)
+
'">'
+
(
name
)
+
' '
+
(
tagEntityCount
?
"("
+
_
.
numberFormatWithComa
(
tagEntityCount
)
+
")"
:
''
)
+
'</option>'
;
}
}
});
});
if
(
!
foundNewClassification
&&
optionsValue
)
{
if
(
optionsValue
.
tag
)
{
var
classificationValue
=
decodeURIComponent
(
optionsValue
.
tag
);
tagStr
+=
'<option value="'
+
(
classificationValue
)
+
'" data-name="'
+
(
classificationValue
)
+
'">'
+
classificationValue
+
'</option>'
;
}
}
if
(
_
.
isUndefined
(
isTypeOnly
))
{
if
(
_
.
isUndefined
(
isTypeOnly
))
{
//to insert extra classification list
//to insert extra classification list
_
.
each
(
Enums
.
addOnClassification
,
function
(
classificationName
)
{
_
.
each
(
Enums
.
addOnClassification
,
function
(
classificationName
)
{
...
@@ -595,7 +609,6 @@ define(['require',
...
@@ -595,7 +609,6 @@ define(['require',
this
.
ui
.
searchType
.
prop
(
"checked"
,
false
).
trigger
(
"change"
);
this
.
ui
.
searchType
.
prop
(
"checked"
,
false
).
trigger
(
"change"
);
}
}
}
}
if
(
this
.
value
.
type
)
{
this
.
ui
.
typeLov
.
val
(
this
.
value
.
type
);
this
.
ui
.
typeLov
.
val
(
this
.
value
.
type
);
if
(
this
.
ui
.
typeLov
.
data
(
'select2'
))
{
if
(
this
.
ui
.
typeLov
.
data
(
'select2'
))
{
if
(
this
.
ui
.
typeLov
.
val
()
!==
this
.
value
.
type
)
{
if
(
this
.
ui
.
typeLov
.
val
()
!==
this
.
value
.
type
)
{
...
@@ -605,22 +618,19 @@ define(['require',
...
@@ -605,22 +618,19 @@ define(['require',
this
.
ui
.
typeLov
.
trigger
(
"change"
,
{
'manual'
:
true
});
this
.
ui
.
typeLov
.
trigger
(
"change"
,
{
'manual'
:
true
});
}
}
}
}
}
if
(
!
this
.
dsl
)
{
if
(
!
this
.
dsl
)
{
if
(
this
.
value
.
tag
)
{
this
.
ui
.
tagLov
.
val
(
this
.
value
.
tag
);
this
.
ui
.
tagLov
.
val
(
this
.
value
.
tag
);
if
(
this
.
ui
.
tagLov
.
data
(
'select2'
))
{
if
(
this
.
ui
.
tagLov
.
data
(
'select2'
))
{
// To handle delete scenario.
// To handle delete scenario.
if
(
this
.
ui
.
tagLov
.
val
()
!==
this
.
value
.
tag
)
{
if
(
this
.
ui
.
tagLov
.
val
()
!==
this
.
value
.
tag
)
{
//
this.value.tag = null;
this
.
value
.
tag
=
null
;
this
.
ui
.
tagLov
.
val
(
""
).
trigger
(
"change"
,
{
'manual'
:
true
});
this
.
ui
.
tagLov
.
val
(
""
).
trigger
(
"change"
,
{
'manual'
:
true
});
}
else
{
}
else
{
this
.
ui
.
tagLov
.
trigger
(
"change"
,
{
'manual'
:
true
});
this
.
ui
.
tagLov
.
trigger
(
"change"
,
{
'manual'
:
true
});
}
}
}
}
}
if
(
this
.
value
.
term
)
{
if
(
this
.
value
.
term
)
{
this
.
ui
.
termLov
.
append
(
'<option value="'
+
this
.
value
.
term
+
'" selected="selected">'
+
this
.
value
.
term
+
'</option>'
);
this
.
ui
.
termLov
.
append
(
'<option value="'
+
this
.
value
.
term
+
'" selected="selected">'
+
this
.
value
.
term
+
'</option>'
);
...
...
This diff is collapsed.
Click to expand it.
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