Skip to content
Snippets Groups Projects
Commit bfa9b917 authored by esikkala's avatar esikkala
Browse files

Clean up

parent 97a20b32
No related branches found
No related tags found
No related merge requests found
...@@ -8,7 +8,6 @@ import { ...@@ -8,7 +8,6 @@ import {
updatePlace, updatePlace,
updateFacet, updateFacet,
updateResults, updateResults,
//updateGeoJSON,
FETCH_FACET, FETCH_FACET,
//FETCH_FACET_FAILED, //FETCH_FACET_FAILED,
FETCH_MANUSCRIPTS, FETCH_MANUSCRIPTS,
...@@ -17,8 +16,6 @@ import { ...@@ -17,8 +16,6 @@ import {
FETCH_PLACE, FETCH_PLACE,
FETCH_RESULTS FETCH_RESULTS
//FETCH_PLACES_FAILED, //FETCH_PLACES_FAILED,
//GET_GEOJSON,
//GET_GEOJSON_FAILED
} from '../actions'; } from '../actions';
const apiUrl = (process.env.NODE_ENV === 'development') const apiUrl = (process.env.NODE_ENV === 'development')
...@@ -80,35 +77,12 @@ const getResultCount = action$ => action$.pipe( ...@@ -80,35 +77,12 @@ const getResultCount = action$ => action$.pipe(
}) })
); );
// const getGeoJSONEpic = (action$) => {
// const wfsUrl = apiUrl + 'wfs';
// return action$.ofType(GET_GEOJSON)
// .switchMap(action => {
// let s = '';
// action.layerIDs.map(layerID => {
// s += `&layerID=${layerID}`;
// });
// const requestUrl = `${wfsUrl}?${s}`;
// return ajax.getJSON(requestUrl)
// // .map(response => {
// // console.log(response)
// // })
// .map(response => updateGeoJSON({ geoJSON: response }))
// .catch(error => Observable.of({
// type: GET_GEOJSON_FAILED,
// error: error,
// }));
// });
// };
const rootEpic = combineEpics( const rootEpic = combineEpics(
getManuscripts, getManuscripts,
getPlaces, getPlaces,
getPlace, getPlace,
getFacet, getFacet,
getResultCount, getResultCount,
// getGeoJSONEpic
); );
export default rootEpic; export default rootEpic;
...@@ -24,17 +24,17 @@ app.use(function(req, res, next) { ...@@ -24,17 +24,17 @@ app.use(function(req, res, next) {
app.use(express.static(__dirname + './../public/')); app.use(express.static(__dirname + './../public/'));
// const filterObj = { const filterObj = {
// creationPlace: { creationPlace: {
// predicate: '^<http://erlangen-crm.org/efrbroo/R18_created>/<http://www.cidoc-crm.org/cidoc-crm/P7_took_place_at>', predicate: '^<http://erlangen-crm.org/efrbroo/R18_created>/<http://www.cidoc-crm.org/cidoc-crm/P7_took_place_at>',
// values: ['<http://ldf.fi/mmm/place/7>', '<http://ldf.fi/mmm/place/5>'] values: ['<http://ldf.fi/mmm/place/7>', '<http://ldf.fi/mmm/place/5>']
// }, },
// author: { author: {
// predicate: '^<http://erlangen-crm.org/efrbroo/R18_created>/<http://www.cidoc-crm.org/cidoc-crm/P14_carried_out_by>', predicate: '^<http://erlangen-crm.org/efrbroo/R18_created>/<http://www.cidoc-crm.org/cidoc-crm/P14_carried_out_by>',
// values: ['<http://ldf.fi/mmm/person/84>', '<http://ldf.fi/mmm/person/894>'] values: ['<http://ldf.fi/mmm/person/84>', '<http://ldf.fi/mmm/person/894>']
// } }
// }; };
const filterObj = {} //const filterObj = {}
app.get('/manuscripts', (req, res) => { app.get('/manuscripts', (req, res) => {
const page = req.query.page || 1; const page = req.query.page || 1;
......
...@@ -26,7 +26,7 @@ export const getManuscriptCount = (filterObj) => { ...@@ -26,7 +26,7 @@ export const getManuscriptCount = (filterObj) => {
}; };
export const getPlaces = variant => { export const getPlaces = variant => {
console.log(variant) // console.log(variant)
const config = datasetConfig['mmm']; const config = datasetConfig['mmm'];
return sparqlSearchEngine.doSearch(config[`${variant}Query`], config.endpoint, makeObjectList); return sparqlSearchEngine.doSearch(config[`${variant}Query`], config.endpoint, makeObjectList);
}; };
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment