|
20 | 20 | <div class="bu-is-flex bu-is-flex-direction-column">
|
21 | 21 | <a
|
22 | 22 | class="crash-group-title has-ellipsis"
|
| 23 | + :data-test-id="'datatable-crash-groups-group-title-' + col.$index" |
23 | 24 | :href="'#/crashes/' + col.row._id"
|
24 | 25 | v-html="col.row.name">
|
25 | 26 | </a>
|
26 | 27 | <div class="bu-mt-2 bu-is-flex">
|
27 |
| - <crash-badge :type="badge.type" v-html="badge.content" v-for="badge in badgesFor(col.row)"></crash-badge> |
| 28 | + <crash-badge :type="badge.type" v-html="badge.content" v-for="(badge, badgeIndex) in badgesFor(col.row)" :data-test-id="'datatable-crash-groups-badge-type-' + badgeIndex + '-col-' + col.$index"></crash-badge> |
28 | 29 | </div>
|
29 | 30 | </div>
|
30 | 31 | </template>
|
31 | 32 | </el-table-column>
|
32 | 33 | <template v-for="(col,idx) in scope.dynamicCols">
|
33 |
| - <el-table-column v-if="col.value === 'os'" :key="idx" prop="os" :label="i18n('crashes.platform')" width="120" show-overflow-tooltip sortable></el-table-column> |
| 34 | + <el-table-column v-if="col.value === 'os'" :key="idx" prop="os" :label="i18n('crashes.platform')" width="120" show-overflow-tooltip sortable> |
| 35 | + <template slot-scope="rowScope"> |
| 36 | + <span :data-test-id="'datatable-crash-groups-platform-' + rowScope.$index">{{rowScope.row.os}}</span> |
| 37 | + </template> |
| 38 | + </el-table-column> |
34 | 39 | <el-table-column v-if="col.value === 'reports'" :key="idx" prop="reports" :label="i18n('crashes.reports')" width="150" sortable :sort-method="occurrenceSort">
|
35 | 40 | <template slot-scope="rowScope">
|
36 |
| - <span v-if="singleAppVersionFilter.length">{{rowScope.row.app_version[singleAppVersionFilter.replace(/\./g, ':')]}}</span> |
37 |
| - <span v-else>{{rowScope.row.reports}}</span> |
| 41 | + <span v-if="singleAppVersionFilter.length" :data-test-id="'datatable-crash-groups-occurences-' + rowScope.$index">{{rowScope.row.app_version[singleAppVersionFilter.replace(/\./g, ':')]}}</span> |
| 42 | + <span v-else :data-test-id="'datatable-crash-groups-occurences-' + rowScope.$index">{{rowScope.row.reports}}</span> |
| 43 | + </template> |
| 44 | + </el-table-column> |
| 45 | + <el-table-column v-if="col.value === 'lastTs'" :key="idx" prop="lastTs" :label="i18n('crashes.last_time')" :formatter="formatDate" width="180" sortable> |
| 46 | + <template slot-scope="rowScope"> |
| 47 | + <div :data-test-id="'datatable-crash-groups-last-occurrence-' + rowScope.$index">{{formatDate(null,null,rowScope.row.lastTs)}}</div> |
| 48 | + </template> |
| 49 | + </el-table-column> |
| 50 | + <el-table-column v-if="col.value === 'users'" :key="idx" prop="users" :label="i18n('crashes.affected-users')" width="170" sortable> |
| 51 | + <template slot-scope="rowScope"> |
| 52 | + <span :data-test-id="'datatable-crash-groups-affected-users-' + rowScope.$index">{{rowScope.row.users}}</span> |
| 53 | + </template> |
| 54 | + </el-table-column> |
| 55 | + <el-table-column v-if="col.value === 'latest_version'" :key="idx" prop="latest_version" :label="i18n('crashes.latest_app')" width="190" sortable :sort-method="appVersionSort"> |
| 56 | + <template slot-scope="rowScope"> |
| 57 | + <span :data-test-id="'datatable-crash-groups-latest-app-version-' + rowScope.$index">{{rowScope.row.latest_version}}</span> |
38 | 58 | </template>
|
39 | 59 | </el-table-column>
|
40 |
| - <el-table-column v-if="col.value === 'lastTs'" :key="idx" prop="lastTs" :label="i18n('crashes.last_time')" :formatter="formatDate" width="180" sortable></el-table-column> |
41 |
| - <el-table-column v-if="col.value === 'users'" :key="idx" prop="users" :label="i18n('crashes.affected-users')" width="170" sortable></el-table-column> |
42 |
| - <el-table-column v-if="col.value === 'latest_version'" :key="idx" prop="latest_version" :label="i18n('crashes.latest_app')" width="190" sortable :sort-method="appVersionSort"></el-table-column> |
43 | 60 | </template>
|
44 | 61 | </template>
|
45 | 62 | <template v-slot:bottomline="scope">
|
|
116 | 133 | <div data-test-id="crash-statistics-top-platforms-label">{{i18n("crashes.top-platforms")}}</div>
|
117 | 134 | <div class="bu-ml-1"><cly-tooltip-icon data-test-id="crash-statistics-top-platforms-tooltip" icon="ion ion-help-circled" :tooltip="i18n('crashes.help-platforms')"></cly-tooltip-icon></div>
|
118 | 135 | </div>
|
119 |
| - <div class="bu-column bu-pt-0" v-for="platform in statistics.topPlatformsOrder"> |
| 136 | + <div class="bu-column bu-pt-0" v-for="(platform, platformIndex) in statistics.topPlatformsOrder"> |
120 | 137 | <div class="bu-columns bu-is-gapless bu-is-mobile text-medium color-gray-100 bu-mb-1">
|
121 |
| - <div class="bu-column">{{platform}}</div> |
122 |
| - <div class="bu-column bu-has-text-right"> |
| 138 | + <div class="bu-column" :data-test-id="'crash-statistics-top-platforms-platform-' + platformIndex">{{platform}}</div> |
| 139 | + <div class="bu-column bu-has-text-right" :data-test-id="'crash-statistics-top-platforms-platform-users-percentage-' + platformIndex"> |
123 | 140 | {{statistics.topPlatforms[platform].count}} Users ({{statistics.topPlatforms[platform].percent.toFixed(1)}}%)
|
124 | 141 | </div>
|
125 | 142 | </div>
|
126 |
| - <cly-progress-bar :percentage="statistics.topPlatforms[platform].percent" color="#F96300" backgroundColor="#ECECEC" :height="8"> |
| 143 | + <cly-progress-bar :test-id="'crash-statistics-top-platforms-platform-' + platformIndex" :percentage="statistics.topPlatforms[platform].percent" color="#F96300" backgroundColor="#ECECEC" :height="8"> |
127 | 144 | </cly-progress-bar>
|
128 | 145 | </div>
|
129 | 146 | </div>
|
|
0 commit comments