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
21e9f2f9
Commit
21e9f2f9
authored
5 years ago
by
kevalbhatt
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
ATLAS-3696 : [Business Metadata] No option to check/uncheck Business Metadata…
ATLAS-3696 : [Business Metadata] No option to check/uncheck Business Metadata attributes in search results
parent
7b650f7a
Show whitespace changes
Inline
Side-by-side
Showing
9 changed files
with
45 additions
and
55 deletions
+45
-55
DetailPageLayoutView_tmpl.html
...c/js/templates/detail_page/DetailPageLayoutView_tmpl.html
+1
-1
EntityDetailTableLayoutView_tmpl.html
...js/templates/entity/EntityDetailTableLayoutView_tmpl.html
+1
-1
table.scss
dashboardv3/public/css/scss/table.scss
+4
-0
DetailPageLayoutView_tmpl.html
...c/js/templates/detail_page/DetailPageLayoutView_tmpl.html
+1
-1
EntityDetailTableLayoutView_tmpl.html
...js/templates/entity/EntityDetailTableLayoutView_tmpl.html
+1
-1
Overrides.js
dashboardv3/public/js/utils/Overrides.js
+1
-0
EntityDetailTableLayoutView.js
...dv3/public/js/views/entity/EntityDetailTableLayoutView.js
+3
-0
SearchDefaultLayoutView.js
...boardv3/public/js/views/search/SearchDefaultLayoutView.js
+1
-5
SearchResultLayoutView.js
dashboardv3/public/js/views/search/SearchResultLayoutView.js
+32
-46
No files found.
dashboardv2/public/js/templates/detail_page/DetailPageLayoutView_tmpl.html
View file @
21e9f2f9
...
...
@@ -34,7 +34,7 @@
</div>
</div>
<div
class=
"form-group termBox"
>
<span
class=
"control-label-sm-pr pull-left"
>
Term:
</span>
<span
class=
"control-label-sm-pr pull-left"
>
Term
s
:
</span>
<div
class=
"pull-left"
data-id=
"termList"
>
<button
class=
"btn btn-action btn-sm"
title=
"Add Term"
data-id=
"addTerm"
>
<i
class=
"fa fa-plus"
>
</i>
...
...
This diff is collapsed.
Click to expand it.
dashboardv2/public/js/templates/entity/EntityDetailTableLayoutView_tmpl.html
View file @
21e9f2f9
...
...
@@ -26,7 +26,7 @@
</div>
<div
class=
"panel-actions"
>
<div
class=
"pretty p-switch p-fill"
style=
"margin-right: 20px"
>
<input
type=
"checkbox"
data-id=
"noValueToggle"
title=
"Show
Empty V
alues"
/>
<input
type=
"checkbox"
data-id=
"noValueToggle"
title=
"Show
empty v
alues"
/>
<div
class=
"state p-primary"
>
<label></label>
</div>
...
...
This diff is collapsed.
Click to expand it.
dashboardv3/public/css/scss/table.scss
View file @
21e9f2f9
...
...
@@ -199,6 +199,10 @@ tr.empty {
font-size
:
14px
;
letter-spacing
:
0
.25px
;
color
:
#6a6a6a
;
&
.no-capitalize
{
text-transform
:
none
!
important
;
}
}
>
td
{
...
...
This diff is collapsed.
Click to expand it.
dashboardv3/public/js/templates/detail_page/DetailPageLayoutView_tmpl.html
View file @
21e9f2f9
...
...
@@ -37,7 +37,7 @@
</div>
</div>
<div
class=
"form-group termBox col-md-12"
>
<span
class=
"control-label-sm-pr pull-left"
>
Term:
</span>
<span
class=
"control-label-sm-pr pull-left"
>
Term
s
:
</span>
<div
class=
"pull-left"
data-id=
"termList"
>
<button
class=
"btn btn-action btn-sm"
title=
"Add Term"
data-id=
"addTerm"
>
<i
class=
"fa fa-plus"
>
</i>
...
...
This diff is collapsed.
Click to expand it.
dashboardv3/public/js/templates/entity/EntityDetailTableLayoutView_tmpl.html
View file @
21e9f2f9
...
...
@@ -26,7 +26,7 @@
</div>
<div
class=
"panel-actions"
>
<div
class=
"pretty p-switch p-fill"
style=
"margin-right: 20px"
>
<input
type=
"checkbox"
data-id=
"noValueToggle"
/>
<input
type=
"checkbox"
data-id=
"noValueToggle"
title=
"Show empty values"
/>
<div
class=
"state p-primary"
>
<label></label>
</div>
...
...
This diff is collapsed.
Click to expand it.
dashboardv3/public/js/utils/Overrides.js
View file @
21e9f2f9
...
...
@@ -98,6 +98,7 @@ define(['require', 'utils/Utils', 'marionette', 'backgrid', 'asBreadcrumbs', 'jq
if
(
modelValue
.
get
(
'width'
))
that
.
$el
.
find
(
'.'
+
modelValue
.
get
(
'name'
)).
css
(
'min-width'
,
modelValue
.
get
(
'width'
)
+
'px'
);
if
(
modelValue
.
get
(
'fixWidth'
))
that
.
$el
.
find
(
'.'
+
modelValue
.
get
(
'name'
)).
css
(
'width'
,
modelValue
.
get
(
'fixWidth'
)
+
'px'
);
if
(
modelValue
.
get
(
'toolTip'
))
that
.
$el
.
find
(
'.'
+
modelValue
.
get
(
'name'
)).
attr
(
'title'
,
modelValue
.
get
(
'toolTip'
));
if
(
modelValue
.
get
(
'headerClassName'
))
that
.
$el
.
find
(
'.'
+
modelValue
.
get
(
'name'
).
replace
(
"."
,
"
\\
."
)).
addClass
(
modelValue
.
get
(
'headerClassName'
));
});
return
this
;
}
...
...
This diff is collapsed.
Click to expand it.
dashboardv3/public/js/views/entity/EntityDetailTableLayoutView.js
View file @
21e9f2f9
...
...
@@ -51,6 +51,8 @@ define(['require',
events
:
function
()
{
var
events
=
{};
events
[
"click "
+
this
.
ui
.
noValueToggle
]
=
function
()
{
this
.
showAllProperties
=
!
this
.
showAllProperties
;
this
.
ui
.
noValueToggle
.
attr
(
"data-original-title"
,
(
this
.
showAllProperties
?
"Hide"
:
"Show"
)
+
" empty values"
);
Utils
.
togglePropertyRelationshipTableEmptyValues
({
"inputType"
:
this
.
ui
.
noValueToggle
,
"tableEl"
:
this
.
ui
.
detailValue
...
...
@@ -66,6 +68,7 @@ define(['require',
initialize
:
function
(
options
)
{
_
.
extend
(
this
,
_
.
pick
(
options
,
'entity'
,
'typeHeaders'
,
'attributeDefs'
,
'attributes'
,
'editEntity'
,
'guid'
,
'entityDefCollection'
,
'searchVent'
,
'fetchCollection'
));
this
.
entityModel
=
new
VEntity
({});
this
.
showAllProperties
=
false
;
},
bindEvents
:
function
()
{},
onRender
:
function
()
{
...
...
This diff is collapsed.
Click to expand it.
dashboardv3/public/js/views/search/SearchDefaultLayoutView.js
View file @
21e9f2f9
...
...
@@ -365,12 +365,8 @@ define(["require", "backbone", "utils/Globals", "hbs!tmpl/search/SearchDefaultLa
if
(
_
.
has
(
obj
,
"condition"
))
{
return
that
.
getIdFromRuleObj
(
obj
);
}
else
{
if
((
obj
&&
obj
.
data
&&
obj
.
data
.
entityType
===
"businessMetadata"
)
||
obj
.
id
.
indexOf
(
"."
)
>
-
1
)
{
return
col
.
add
(
"businessMetadata"
);
}
else
{
return
col
.
add
(
obj
.
id
);
}
}
});
return
Array
.
from
(
col
);
},
...
...
@@ -382,7 +378,7 @@ define(["require", "backbone", "utils/Globals", "hbs!tmpl/search/SearchDefaultLa
if
(
!
this
.
options
.
searchTableColumns
[
this
.
options
.
value
.
type
])
{
this
.
options
.
searchTableColumns
[
this
.
options
.
value
.
type
]
=
[
"selected"
,
"name"
,
"description"
,
"typeName"
,
"owner"
,
"tag"
,
"term"
];
}
this
.
options
.
searchTableColumns
[
this
.
options
.
value
.
type
]
=
_
.
sortBy
(
_
.
union
(
_
.
without
(
this
.
options
.
searchTableColumns
[
this
.
options
.
value
.
type
]
,
"businessMetadata"
),
this
.
getIdFromRuleObj
(
rule
)));
this
.
options
.
searchTableColumns
[
this
.
options
.
value
.
type
]
=
_
.
sortBy
(
_
.
union
(
_
.
without
(
this
.
options
.
searchTableColumns
[
this
.
options
.
value
.
type
]),
this
.
getIdFromRuleObj
(
rule
)));
}
},
renderQueryBuilder
:
function
(
obj
,
rQueryBuilder
)
{
...
...
This diff is collapsed.
Click to expand it.
dashboardv3/public/js/views/search/SearchResultLayoutView.js
View file @
21e9f2f9
...
...
@@ -153,7 +153,7 @@ define(['require',
* @constructs
*/
initialize
:
function
(
options
)
{
_
.
extend
(
this
,
_
.
pick
(
options
,
'value'
,
'guid'
,
'initialView'
,
'isTypeTagNotExists'
,
'classificationDefCollection'
,
'entityDefCollection'
,
'typeHeaders'
,
'searchVent'
,
'enumDefCollection'
,
'tagCollection'
,
'searchTableColumns'
,
'isTableDropDisable'
,
'fromView'
,
'glossaryCollection'
,
'termName'
));
_
.
extend
(
this
,
_
.
pick
(
options
,
'value'
,
'guid'
,
'initialView'
,
'isTypeTagNotExists'
,
'classificationDefCollection'
,
'entityDefCollection'
,
'typeHeaders'
,
'searchVent'
,
'enumDefCollection'
,
'tagCollection'
,
'searchTableColumns'
,
'isTableDropDisable'
,
'fromView'
,
'glossaryCollection'
,
'termName'
,
'businessMetadataDefCollection'
));
this
.
entityModel
=
new
VEntity
();
this
.
searchCollection
=
new
VSearchList
();
this
.
limit
=
25
;
...
...
@@ -368,7 +368,7 @@ define(['require',
this
.
searchTableColumns
[
this
.
value
.
type
]
=
listOfColumns
.
length
?
listOfColumns
:
null
;
}
}
else
if
(
this
.
value
&&
this
.
value
.
type
&&
this
.
searchTableColumns
&&
this
.
value
.
attributes
)
{
this
.
searchTableColumns
[
this
.
value
.
type
]
=
this
.
value
.
entityFilters
?
this
.
value
.
attributes
.
split
(
","
)
:
this
.
value
.
attributes
.
replace
(
"businessMetadata,"
,
""
)
.
split
(
","
);
this
.
searchTableColumns
[
this
.
value
.
type
]
=
this
.
value
.
attributes
.
split
(
","
);
}
},
fetchCollection
:
function
(
value
,
options
)
{
...
...
@@ -740,8 +740,6 @@ define(['require',
}
})
};
if
(
this
.
value
&&
this
.
value
.
profileDBView
)
{
col
[
'createTime'
]
=
{
label
:
"Date Created"
,
...
...
@@ -760,7 +758,6 @@ define(['require',
}
}
if
(
this
.
value
&&
!
this
.
value
.
profileDBView
)
{
col
[
'description'
]
=
{
label
:
"Description"
,
cell
:
"String"
,
...
...
@@ -777,8 +774,6 @@ define(['require',
}
})
};
col
[
'typeName'
]
=
{
label
:
"Type"
,
cell
:
"Html"
,
...
...
@@ -795,43 +790,6 @@ define(['require',
}
})
};
col
[
'businessMetadata'
]
=
{
label
:
"Business Metadata"
,
cell
:
"Html"
,
editable
:
false
,
resizeable
:
true
,
orderable
:
true
,
alwaysVisible
:
true
,
//Backgrid.ColumnManager.js -> render() to hide the name in dropdownlist
renderable
:
_
.
contains
(
columnToShow
,
'businessMetadata'
),
formatter
:
_
.
extend
({},
Backgrid
.
CellFormatter
.
prototype
,
{
fromRaw
:
function
(
rawValue
,
model
)
{
var
obj
=
model
.
toJSON
(),
businessMetadataStr
=
''
;
if
(
obj
&&
obj
.
attributes
)
{
_
.
each
(
obj
.
attributes
,
function
(
businessMetadataValue
,
attributeName
)
{
if
(
attributeName
.
indexOf
(
'.'
)
!=
-
1
)
{
var
isDate
=
false
,
businessMetadata
=
that
.
options
.
businessMetadataDefCollection
.
fullCollection
.
find
({
"name"
:
attributeName
.
split
(
'.'
)[
0
]
});
if
(
businessMetadata
)
{
var
getAttributes
=
businessMetadata
.
get
(
'attributeDefs'
);
getAttributes
.
every
(
function
(
attrTypeCheck
)
{
if
(
attributeName
.
split
(
'.'
)[
1
]
===
attrTypeCheck
.
name
&&
attrTypeCheck
.
typeName
.
indexOf
(
"date"
)
>
-
1
)
{
isDate
=
true
;
}
return
!
isDate
;
});
}
if
(
isDate
)
{
businessMetadataValue
=
moment
(
businessMetadataValue
).
format
(
"MM/DD/YYYY"
)
}
businessMetadataStr
+=
'<label class="btn btn-action btn-xs btn-blue no-pointer">'
+
attributeName
+
': '
+
businessMetadataValue
+
'</label>'
;
}
})
return
businessMetadataStr
;
}
}
})
};
this
.
getTagCol
({
'col'
:
col
,
'columnToShow'
:
columnToShow
});
if
((
!
_
.
contains
([
"glossary"
],
this
.
fromView
)))
{
this
.
getTermCol
({
'col'
:
col
,
'columnToShow'
:
columnToShow
});
...
...
@@ -839,7 +797,23 @@ define(['require',
if
(
this
.
value
&&
this
.
value
.
searchType
===
"basic"
)
{
var
def
=
this
.
entityDefCollection
.
fullCollection
.
find
({
name
:
this
.
value
.
type
}),
systemAttr
=
[];
systemAttr
=
[],
businessMetadataAttr
=
[],
businessAttributes
=
{};
if
(
this
.
value
.
type
==
"_ALL_ENTITY_TYPES"
)
{
this
.
businessMetadataDefCollection
.
each
(
function
(
model
)
{
var
sortedAttributes
=
model
.
get
(
'attributeDefs'
)
||
null
,
name
=
model
.
get
(
'name'
);
if
(
sortedAttributes
)
{
sortedAttributes
=
_
.
sortBy
(
sortedAttributes
,
function
(
obj
)
{
return
obj
.
name
;
});
businessAttributes
[
name
]
=
$
.
extend
(
true
,
{},
sortedAttributes
);
}
})
}
else
{
businessAttributes
=
def
?
(
$
.
extend
(
true
,
{},
def
.
get
(
'businessAttributeDefs'
))
||
null
)
:
null
;
}
if
(
def
||
Globals
[
this
.
value
.
type
]
||
(
this
.
value
.
tag
?
Globals
[
this
.
value
.
tag
]
?
...
...
@@ -854,6 +828,17 @@ define(['require',
systemAttr
=
(
Globals
[
this
.
value
.
tag
]
||
Globals
[
Enums
.
addOnClassification
[
0
]]).
attributeDefs
;
}
attrObj
=
attrObj
.
concat
(
systemAttr
);
if
(
businessAttributes
)
{
_
.
each
(
businessAttributes
,
function
(
businessMetadata
,
businessMetadataName
)
{
_
.
each
(
businessMetadata
,
function
(
attr
,
index
)
{
var
attribute
=
attr
;
attribute
.
isBusinessAttributes
=
true
;
attribute
.
name
=
businessMetadataName
+
'.'
+
attribute
.
name
;
businessMetadataAttr
.
push
(
attribute
);
})
})
}
attrObj
=
attrObj
.
concat
(
businessMetadataAttr
);
_
.
each
(
attrObj
,
function
(
obj
,
key
)
{
var
key
=
obj
.
name
,
isRenderable
=
_
.
contains
(
columnToShow
,
key
),
...
...
@@ -868,7 +853,7 @@ define(['require',
return
;
}
col
[
obj
.
name
]
=
{
label
:
Enums
.
systemAttributes
[
obj
.
name
]
?
Enums
.
systemAttributes
[
obj
.
name
]
:
_
.
escape
(
obj
.
name
).
capitalize
(
),
label
:
Enums
.
systemAttributes
[
obj
.
name
]
?
Enums
.
systemAttributes
[
obj
.
name
]
:
(
_
.
escape
(
obj
.
isBusinessAttributes
?
obj
.
name
:
obj
.
name
.
capitalize
())
),
cell
:
"Html"
,
headerCell
:
Backgrid
.
HeaderHTMLDecodeCell
,
editable
:
false
,
...
...
@@ -876,6 +861,7 @@ define(['require',
orderable
:
true
,
sortable
:
isSortable
,
renderable
:
isRenderable
,
headerClassName
:
obj
.
isBusinessAttributes
?
"no-capitalize"
:
""
,
formatter
:
_
.
extend
({},
Backgrid
.
CellFormatter
.
prototype
,
{
fromRaw
:
function
(
rawValue
,
model
)
{
var
modelObj
=
model
.
toJSON
();
...
...
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