Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-ce
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
1
Merge Requests
1
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
nexedi
gitlab-ce
Commits
62643e3b
Commit
62643e3b
authored
Dec 21, 2021
by
Jannik Lehmann
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Replace GlTable with GlTableLite for merge-request-analytics-table
parent
63732b69
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
14 additions
and
7 deletions
+14
-7
ee/app/assets/javascripts/analytics/code_review_analytics/components/merge_request_table.vue
.../code_review_analytics/components/merge_request_table.vue
+12
-5
ee/spec/frontend/analytics/code_review_analytics/components/merge_request_table_spec.js
...e_review_analytics/components/merge_request_table_spec.js
+2
-2
No files found.
ee/app/assets/javascripts/analytics/code_review_analytics/components/merge_request_table.vue
View file @
62643e3b
<
script
>
import
{
GlTable
,
GlLink
,
GlIcon
,
GlAvatarLink
,
GlAvatar
,
GlTooltipDirective
}
from
'
@gitlab/ui
'
;
import
{
escape
}
from
'
lodash
'
;
import
{
mapState
}
from
'
vuex
'
;
import
{
escape
}
from
'
lodash
'
;
import
{
GlTableLite
,
GlLink
,
GlIcon
,
GlAvatarLink
,
GlAvatar
,
GlTooltipDirective
,
}
from
'
@gitlab/ui
'
;
import
{
getTimeago
}
from
'
~/lib/utils/datetime_utility
'
;
import
{
__
,
sprintf
,
n__
}
from
'
~/locale
'
;
import
ApproversColumn
from
'
./approvers_column.vue
'
;
...
...
@@ -9,7 +16,7 @@ import ApproversColumn from './approvers_column.vue';
export
default
{
name
:
'
MergeRequestTable
'
,
components
:
{
GlTable
,
GlTable
Lite
,
GlLink
,
GlIcon
,
GlAvatarLink
,
...
...
@@ -88,7 +95,7 @@ export default {
</
script
>
<
template
>
<gl-table
<gl-table
-lite
class=
"my-3"
:fields=
"$options.tableHeaderFields"
:items=
"mergeRequests"
...
...
@@ -140,5 +147,5 @@ export default {
<span
class=
"font-weight-bold cgreen"
>
+
{{
items
.
item
.
diff_stats
.
additions
}}
</span>
<span
class=
"font-weight-bold cred"
>
-
{{
items
.
item
.
diff_stats
.
deletions
}}
</span>
</
template
>
</gl-table>
</gl-table
-lite
>
</template>
ee/spec/frontend/analytics/code_review_analytics/components/merge_request_table_spec.js
View file @
62643e3b
import
{
GlTable
}
from
'
@gitlab/ui
'
;
import
{
GlTable
Lite
}
from
'
@gitlab/ui
'
;
import
{
mount
}
from
'
@vue/test-utils
'
;
import
Vue
from
'
vue
'
;
import
Vuex
from
'
vuex
'
;
...
...
@@ -39,7 +39,7 @@ describe('MergeRequestTable component', () => {
wrapper
.
destroy
();
});
const
findTable
=
()
=>
wrapper
.
findComponent
(
GlTable
);
const
findTable
=
()
=>
wrapper
.
findComponent
(
GlTable
Lite
);
const
findTableRow
=
(
index
)
=>
findTable
().
findAll
(
'
tbody tr
'
).
at
(
index
);
const
findReviewTimeCol
=
(
rowIndex
)
=>
findTableRow
(
rowIndex
).
findAll
(
'
td
'
).
at
(
1
);
...
...
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