Skip to content

Commit

Permalink
Add click action event "grant search result" to grant rows (#2464)
Browse files Browse the repository at this point in the history
* Add grant search results as a datadog action

* Update GrantsTable.vue

* Update GrantsTable.vue

* add datadog action attribute 'grant search result' to grant result rows

* Reset .env.example

* Fixing requested changes

Adding back .env.example files, deleting launch.json, editing datadog action call and import.

* Update GrantsTable.vue
  • Loading branch information
mayabose authored Jan 18, 2024
1 parent b774fe1 commit d0ff748
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions packages/client/src/components/GrantsTable.vue
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@
<b-table id="grants-table" hover responsive stacked="sm" :items="formattedGrants"
:fields="fields.filter(field => !field.hideGrantItem)" selectable striped :sort-by.sync="orderBy"
:sort-desc.sync="orderDesc" :no-local-sorting="true" :bordered="true" select-mode="single" :busy="loading"
:tbody-tr-attr="{'data-dd-action-name': 'grant search result'}"
@row-selected="onRowSelected" @row-clicked="onRowClicked" show-empty emptyText="No matches found">
<template #cell(award_floor)="row">
<p> {{ formatMoney(row.item.award_floor) }}</p>
Expand Down Expand Up @@ -77,6 +78,7 @@
<script>
import { mapActions, mapGetters } from 'vuex';
import { newTerminologyEnabled, newGrantsDetailPageEnabled } from '@/helpers/featureFlags';
import { datadogRum } from '@datadog/browser-rum';
import { titleize } from '../helpers/form-helpers';
import GrantDetailsLegacy from './Modals/GrantDetailsLegacy.vue';
import SearchPanel from './Modals/SearchPanel.vue';
Expand Down Expand Up @@ -340,6 +342,7 @@ export default {
return;
}
this.$router.push(`grant/${item.grant_id}`);
datadogRum.addAction('view grant details', { grant: item });
},
onRowSelected(items) {
const [row] = items;
Expand Down
Empty file modified packages/server/.env.example
100755 → 100644
Empty file.

0 comments on commit d0ff748

Please sign in to comment.