Skip to content

Commit

Permalink
Merge pull request #38 from KPMP/KPMP-1483_ChangeGoogleAnalyticsId
Browse files Browse the repository at this point in the history
Kpmp 1483 change google analytics
  • Loading branch information
zwright authored Nov 15, 2019
2 parents 5813a4a + f925829 commit c32cfdf
Show file tree
Hide file tree
Showing 3 changed files with 1 addition and 125 deletions.
5 changes: 1 addition & 4 deletions src/App.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@ import thunk from 'redux-thunk';
import loadedState from './initialState';
import rootReducer from './reducers';
import { Router, Route, Switch } from 'react-router-dom';
import SlidePrintManager from './components/Slides/Menu/SlidePrintManager';
import ReactGA from 'react-ga';
import createHistory from 'history/createBrowserHistory';
import Oops from './components/Error/Oops';
Expand All @@ -24,7 +23,7 @@ const store = applyMiddleware(thunk)(createStore)(rootReducer, initialState, win
const saveState = () => {
window.sessionStorage.setItem('dpr', JSON.stringify(store.getState()));
};
const GA_TRACKING_ID = 'UA-124331187-3';
const GA_TRACKING_ID = 'UA-124331187-9';

ReactGA.initialize(GA_TRACKING_ID);
function logPageView(location, action) {
Expand All @@ -42,8 +41,6 @@ store.subscribe(function () {

store.subscribe(saveState);

SlidePrintManager.getInstance().setReduxStore(store);

class App extends Component {

componentWillMount() {
Expand Down
12 changes: 0 additions & 12 deletions src/components/Slides/Menu/Header.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,14 +3,12 @@ import { FontAwesomeIcon } from '@fortawesome/react-fontawesome';
import { faCaretLeft, faChevronRight, faChevronLeft, faDownload } from '@fortawesome/free-solid-svg-icons';
import { Col, Row } from 'reactstrap';
import ReactGA from 'react-ga';
import SlidePrintManager from './SlidePrintManager';
import { getNextSlide, getPreviousSlide, downloadSlide } from '../slideHelpers.js';

class Header extends Component {

constructor(props) {
super(props);
this.onPrint = this.onPrint.bind(this);
this.handleDownload = this.handleDownload.bind(this);
}

Expand All @@ -35,16 +33,6 @@ class Header extends Component {
let downloadFileName = this.props.selectedParticipant.selectedSlide.slideName + ".jpg";
downloadSlide(downloadFileName);
}

onPrint() {
ReactGA.event({
category: 'Slide View',
action: 'Print Slide',
label: this.props.selectedParticipant.selectedSlide.slideName
});
SlidePrintManager.getInstance().beforePrint();
setTimeout(window.print, 10);
}

render() {
return(
Expand Down
109 changes: 0 additions & 109 deletions src/components/Slides/Menu/SlidePrintManager.js

This file was deleted.

0 comments on commit c32cfdf

Please sign in to comment.