11< div >
2- < cly-header
3- :title ="i18n('remote-config.title') "
4- >
2+ < cly-header :title ="i18n('remote-config.title') ">
53 < template v-slot:header-right >
64 < div class ="bu-level-item " v-if ="hasCreateRight ">
7- < el-button :disabled ="isParamterLimitExceeded " @click ="create " type ="success " size ="small " icon ="el-icon-circle-plus " data-test-id ="add-parameter-button "> {{i18n('remote-config.add-parameter-title')}}</ el-button >
5+ < el-button :disabled ="isParamterLimitExceeded " @click ="create " type ="success " size ="small "
6+ icon ="el-icon-circle-plus "
7+ data-test-id ="add-parameter-button "> {{i18n('remote-config.add-parameter-title')}}</ el-button >
88 </ div >
99 </ template >
1010 </ cly-header >
1313 < cly-notification class ="bu-mb-5 " :text ="i18n('remote-config.maximum_parameters_added') " color ="light-warning ">
1414 </ cly-notification >
1515 </ div >
16- < cly-datatable-n :rows ="tableRows " :exportFormat ="formatExportFunction " :force-loading ="isTableLoading " class ="cly-vue-remote-config-home-table " ref ="table " @row-click ="handleTableRowClick " :row-class-name ="tableRowClassName ">
16+ < cly-datatable-n test-id ="remote-config " :rows ="tableRows " :exportFormat ="formatExportFunction "
17+ :force-loading ="isTableLoading " class ="cly-vue-remote-config-home-table " ref ="table "
18+ @row-click ="handleTableRowClick " :row-class-name ="tableRowClassName ">
1719 < template v-slot:default ="scope ">
18- < el-table-column type ="expand " min-width ="50 ">
20+ < el-table-column :test-id ="'remote-config-expand-' + scope.$index "
21+ type ="expand " min-width ="50 ">
1922 < template v-slot ="props ">
2023 < cly-section >
21- < condition-stats :parameter ="props.row "> </ condition-stats >
24+ < condition-stats :test-id =" 'datatable-remote-config-' + scope.$index " : parameter ="props.row "> </ condition-stats >
2225 </ cly-section >
2326 </ template >
2427 </ el-table-column >
25- < el-table-column min-width ="160 " prop ="parameter_key " :label ="i18n('remote-config.parameter') " sortable ="custom ">
28+ < el-table-column min-width ="160 " prop ="parameter_key " :label ="i18n('remote-config.parameter') "
29+ sortable ="custom ">
2630 < template v-slot:default ="rowScope ">
2731 < div >
28- < div class ="cly-vue-remote-config-conditions-drawer__margin-bottom "> {{rowScope.row.parameter_key}}</ div >
29- < div v-if ="isDrillEnabled " class ="color-cool-gray-40 text-small "> < span > {{getNumberOfConditionsText(rowScope.row.conditions)}} </ span > </ div >
32+ < div class ="cly-vue-remote-config-conditions-drawer__margin-bottom "
33+ :data-test-id ="'datatable-remote-config-parameter-' + rowScope.$index "> {{rowScope.row.parameter_key}}
34+ </ div >
35+ < div v-if ="isDrillEnabled " class ="color-cool-gray-40 text-small "> < span >
36+ {{getNumberOfConditionsText(rowScope.row.conditions)}} </ span > </ div >
3037 </ div >
3138 </ template >
3239 </ el-table-column >
3340 < el-table-column min-width ="160 " prop ="status " :label ="i18n('remote-config.parameter.status') ">
3441 < template v-slot:default ="rowScope ">
3542 < div >
3643 < div class ="cly-vue-remote-config-conditions-drawer__margin-bottom ">
37- < cly-status-tag v-if ="rowScope.row.status==='Stopped' " :text ="i18n('remote-config.parameter.disabled') " color ="red "> </ cly-status-tag >
38- < cly-status-tag v-else-if ="rowScope.row.status==='Expired' " :text ="i18n('remote-config.parameter.expired') " color ="yellow "> </ cly-status-tag >
39- < cly-status-tag v-else :text ="i18n('remote-config.parameter.enabled') " color ="blue "> </ cly-status-tag >
44+ < cly-status-tag v-if ="rowScope.row.status==='Stopped' " :text ="i18n('remote-config.parameter.disabled') "
45+ color ="red " :data-test-id ="'datatable-remote-config-status-' + rowScope.$index "> </ cly-status-tag >
46+ < cly-status-tag v-else-if ="rowScope.row.status==='Expired' "
47+ :text ="i18n('remote-config.parameter.expired') " color ="yellow "
48+ :data-test-id ="'datatable-remote-config-status-' + rowScope.$index "> </ cly-status-tag >
49+ < cly-status-tag v-else :text ="i18n('remote-config.parameter.enabled') " color ="blue "
50+ :data-test-id ="'datatable-remote-config-status-' + rowScope.$index "> </ cly-status-tag >
4051 </ div >
41- < div class ="color-cool-gray-40 text-small " v-if ="rowScope.row.expiry_dttm "> {{i18n('remote-config.expire.date')}} {{getDate(rowScope.row.expiry_dttm)}}</ div >
52+ < div class ="color-cool-gray-40 text-small " v-if ="rowScope.row.expiry_dttm "
53+ :data-test-id ="'datatable-remote-config-expire-date-' + rowScope.$index ">
54+ {{i18n('remote-config.expire.date')}} {{getDate(rowScope.row.expiry_dttm)}}</ div >
4255 </ div >
4356 </ template >
4457 </ el-table-column >
4558 < el-table-column min-width ="160 " prop ="description " :label ="i18n('remote-config.description') ">
4659 < template v-slot:default ="rowScope ">
47- {{displayDescription(rowScope.row.description)}}
60+ < div :data-test-id ="'datatable-remote-config-description-' + rowScope.$index ">
61+ {{displayDescription(rowScope.row.description)}}
62+ </ div >
4863 </ template >
4964 </ el-table-column >
5065 < el-table-column min-width ="160 " prop ="ts " :label ="i18n('remote-config.parameter.created') " sortable ="custom ">
5166 < template v-slot:default ="rowScope ">
5267 < div >
53- < div class ="cly-vue-remote-config-conditions-drawer__margin-bottom "> {{getDate(rowScope.row.ts)}}</ div >
54- < div class ="color-cool-gray-40 text-small "> {{getTime(rowScope.row.ts)}}</ div >
68+ < div class ="cly-vue-remote-config-conditions-drawer__margin-bottom "
69+ :data-test-id ="'datatable-remote-config-created-date-' + rowScope.$index "> {{getDate(rowScope.row.ts)}}
70+ </ div >
71+ < div class ="color-cool-gray-40 text-small "
72+ :data-test-id ="'datatable-remote-config-created-time-' + rowScope.$index "> {{getTime(rowScope.row.ts)}}
73+ </ div >
5574 </ div >
5675 </ template >
5776 </ el-table-column >
5877 < el-table-column min-width ="160 " prop ="abStatus " :label ="i18n('remote-config.parameter.ab.status') ">
5978 < template v-slot:default ="rowScope ">
60- {{rowScope.row.abStatus || "-"}}
79+ < div :data-test-id ="'datatable-remote-config-ab-status-' + rowScope.$index ">
80+ {{rowScope.row.abStatus || "-"}}
81+ </ div >
6182 </ template >
6283 </ el-table-column >
6384 < el-table-column min-width ="160 " v-if ="hasUpdateRight || hasDeleteRight " type ="options ">
6485 < template v-slot ="rowScope ">
65- < cly-more-options
66- v-if ="rowScope.row.hover "
67- size ="small "
86+ < cly-more-options :test-id ="'datatable-remote-config-' + rowScope.$index " v-if ="rowScope.row.hover " size ="small "
6887 v-tooltip.left ="rowScope.row.editable ? '' : i18n('remote-config.parameter.action-tooltip-content') "
6988 :disabledButton ="rowScope.row.editable ? false : true "
7089 @command ="handleCommand($event, scope, rowScope.row) ">
71- < el-dropdown-item v-if ="hasUpdateRight && rowScope.row.editable " command ="edit "> {{i18n('common.edit')}}</ el-dropdown-item >
72- < el-dropdown-item v-if ="hasDeleteRight && rowScope.row.editable " command ="remove "> {{i18n('common.delete')}}</ el-dropdown-item >
90+ < el-dropdown-item v-if ="hasUpdateRight && rowScope.row.editable "
91+ command ="edit " :data-test-id ="'datatable-remote-config-button-edit-' + rowScope.$index "> {{i18n('common.edit')}}</ el-dropdown-item >
92+ < el-dropdown-item v-if ="hasDeleteRight && rowScope.row.editable "
93+ command ="remove " :data-test-id ="'datatable-remote-config-button-delete-' + rowScope.$index "> {{i18n('common.delete')}}</ el-dropdown-item >
7394 </ cly-more-options >
7495 </ template >
7596 </ el-table-column >
7697 < el-table-column v-if ="hasUpdateRight " min-width ="110 ">
7798 < template v-slot ="rowScope ">
7899 < div v-if ="rowScope.row.hover && rowScope.row.editable ">
79- < el-button v-if ="rowScope.row.status==='Stopped' || rowScope.row.status==='Expired' " @click.stop ="startParameter(rowScope.row) " size ="small " icon ="el-icon-remove "> {{i18n('remote-config.enable')}}
80- </ el-button >
81- < el-button v-else @click.stop ="stopParameter(rowScope.row) " size ="small " icon ="el-icon-remove "> {{i18n('remote-config.disable')}}
82- </ el-button >
100+ < el-button v-if ="rowScope.row.status==='Stopped' || rowScope.row.status==='Expired' "
101+ @click.stop ="startParameter(rowScope.row) " size ="small "
102+ icon ="el-icon-remove " :data-test-id ="'datatable-remote-config-button-enable-' + rowScope.$index "> {{i18n('remote-config.enable')}}
103+ </ el-button >
104+ < el-button :data-test-id ="'datatable-remote-config-button-disable-' + rowScope.$index " v-else @click.stop ="stopParameter(rowScope.row) " size ="small "
105+ icon ="el-icon-remove "> {{i18n('remote-config.disable')}}
106+ </ el-button >
83107 </ div >
84108 </ template >
85109 </ el-table-column >
86110 </ template >
87111 </ cly-datatable-n >
88112 </ cly-main >
89113 < drawer :controls ="drawers.parameters " @submit ="onSubmit "> </ drawer >
90- </ div >
114+ </ div >
0 commit comments