Commit a766dbf1 authored by Yasset Perez-Riverol's avatar Yasset Perez-Riverol
Browse files

merge

parents 29bef79f 88e85b74
...@@ -35,7 +35,9 @@ const webpackConfig = merge(baseWebpackConfig, { ...@@ -35,7 +35,9 @@ const webpackConfig = merge(baseWebpackConfig, {
new UglifyJsPlugin({ new UglifyJsPlugin({
uglifyOptions: { uglifyOptions: {
compress: { compress: {
warnings: false warnings: false,
drop_debugger: true, // self added for removing logs in productions
drop_console: true // self added for removing logs in productions
} }
}, },
sourceMap: config.build.productionSourceMap, sourceMap: config.build.productionSourceMap,
......
This diff is collapsed.
...@@ -28,7 +28,8 @@ ...@@ -28,7 +28,8 @@
"vue-resource": "^1.5.0", "vue-resource": "^1.5.0",
"vue-router": "^3.0.1", "vue-router": "^3.0.1",
"vue-text-highlight": "^1.1.1", "vue-text-highlight": "^1.1.1",
"vue-tweet-embed": "^2.1.1" "vue-tweet-embed": "^2.1.1",
"vuex": "^3.0.1"
}, },
"devDependencies": { "devDependencies": {
"autoprefixer": "^7.1.2", "autoprefixer": "^7.1.2",
......
...@@ -50,9 +50,10 @@ ...@@ -50,9 +50,10 @@
}, },
beforeRouteEnter: function(to, from, next){ beforeRouteEnter: function(to, from, next){
console.log('from',from);
//console.log(from); //console.log(from);
//console.log(document.getElementById('elixir-banner')); //console.log(document.getElementById('elixir-banner'));
//document.getElementById('elixir-banner').setAttribute('display','none'); //document.getElementById('elixir-banner').setAttribute('display','none');
next(); next();
}, },
mounted(){ mounted(){
......
...@@ -121,7 +121,7 @@ ...@@ -121,7 +121,7 @@
<!--<read-more class="readMore" more-str="(More)" :text="publicationItem.projectDescription" link="#" less-str="Less" :max-chars="200"></read-more>--> <!--<read-more class="readMore" more-str="(More)" :text="publicationItem.projectDescription" link="#" less-str="Less" :max-chars="200"></read-more>-->
</span> </span>
<p><span class="project-info">{{projectItemsPublicationDate}}: </span><text-highlight :queries="highlightKeyword" :caseSensitive="HighlightKeywordSensitive">{{publicationItem.publicationDate}}</text-highlight></p> <p><span class="project-info">{{projectItemsPublicationDate}}: </span><text-highlight :queries="highlightKeyword" :caseSensitive="HighlightKeywordSensitive">{{publicationItem.publicationDate}}</text-highlight></p>
<Dropdown class="dataset-wrapper" v-for="datesetItem in publicationItem.projectTags"> <Dropdown class="dataset-wrapper" v-for="(datesetItem, index) in publicationItem.projectTags" :key="index">
<a v-if="datesetItem == 'Biological'" class="button biological-dataset-button" href="javascript:void(0)"> <a v-if="datesetItem == 'Biological'" class="button biological-dataset-button" href="javascript:void(0)">
<Icon type="ios-pricetag"></Icon> <Icon type="ios-pricetag"></Icon>
<text-highlight :queries="highlightKeyword" :caseSensitive="HighlightKeywordSensitive">{{datesetItem}}</text-highlight> Dataset <text-highlight :queries="highlightKeyword" :caseSensitive="HighlightKeywordSensitive">{{datesetItem}}</text-highlight> Dataset
...@@ -168,6 +168,7 @@ ...@@ -168,6 +168,7 @@
<script> <script>
import NavBar from '@/components/archive/Nav' import NavBar from '@/components/archive/Nav'
import store from "@/store/store.js"
var paramsFromLandingPage=''; var paramsFromLandingPage='';
export default { export default {
name: 'archive', name: 'archive',
...@@ -182,11 +183,11 @@ ...@@ -182,11 +183,11 @@
querySpecificFacetsLoading:false, querySpecificFacetsLoading:false,
highlightKeyword:'', highlightKeyword:'',
HighlightKeywordSensitive:false, HighlightKeywordSensitive:false,
facetsURL:'http://ves-pg-41:9020/facet/projects', facetsURL: this.$store.state.baseApiURL + '/facet/projects',
searchConfigURL:'/static/config/facets/config.json', searchConfigURL: this.$store.state.baseURL + '/static/config/facets/config.json',
projectItemsConfigURL:'/static/config/projectItems/config.json', projectItemsConfigURL: this.$store.state.baseURL + '/static/config/projectItems/config.json',
queryArchiveProjectListApi:'http://ves-pg-41:9020/search/projects', queryArchiveProjectListApi: this.$store.state.baseApiURL + '/search/projects',
autoCompleteApi:"http://ves-pg-41:9020/search/autocomplete?keyword=", autoCompleteApi: this.$store.state.baseApiURL + '/search/autocomplete?keyword=',
containItemSearch:'', containItemSearch:'',
fieldSelectors:[], fieldSelectors:[],
currentPage:1, currentPage:1,
...@@ -328,7 +329,6 @@ ...@@ -328,7 +329,6 @@
this.publicaitionList = []; this.publicaitionList = [];
this.loading = true; this.loading = true;
let query = q || this.$route.query; let query = q || this.$route.query;
console.log('queryArchiveProjectList');
query.dateGap = '+1YEAR'; query.dateGap = '+1YEAR';
let pageSizeFound = false; let pageSizeFound = false;
for(let i in query){ for(let i in query){
...@@ -359,7 +359,6 @@ ...@@ -359,7 +359,6 @@
submissionType: projectsList[i].submissionType, submissionType: projectsList[i].submissionType,
hightlightItemArray:[], hightlightItemArray:[],
} }
//console.log('projectsList[i].highlights',projectsList[i].highlights); //console.log('projectsList[i].highlights',projectsList[i].highlights);
for(let j in projectsList[i].highlights){ for(let j in projectsList[i].highlights){
let content=''; let content='';
......
...@@ -376,7 +376,7 @@ ...@@ -376,7 +376,7 @@
<Card class="card" v-if="similarProjects.length>0"> <Card class="card" v-if="similarProjects.length>0">
<p slot="title"><i class="fas fa-link icon-tag"></i>Similar Studies</p> <p slot="title"><i class="fas fa-link icon-tag"></i>Similar Studies</p>
<div class="list-wrapper"> <div class="list-wrapper">
<Card class="similarity-card" v-for="item in similarProjects"> <Card class="similarity-card" v-for="item in similarProjects" :key="item.accession">
<div class="similarity-title"><a @click="gotoDetails(item.accession)">{{item.title}}</a></div> <div class="similarity-title"><a @click="gotoDetails(item.accession)">{{item.title}}</a></div>
<div><span>{{item.submissionDate}}</span></div> <div><span>{{item.submissionDate}}</span></div>
</Card> </Card>
...@@ -392,6 +392,7 @@ ...@@ -392,6 +392,7 @@
<script> <script>
import NavBar from '@/components/landingpage/Nav' import NavBar from '@/components/landingpage/Nav'
import store from "@/store/store.js"
export default { export default {
name: 'archive', name: 'archive',
data(){ data(){
...@@ -412,13 +413,13 @@ ...@@ -412,13 +413,13 @@
experimentTypes:[], experimentTypes:[],
softwares:[], softwares:[],
modification:[], modification:[],
queryArchiveProjectApi:'http://ves-pg-41:9020/projects/', queryArchiveProjectApi: this.$store.state.baseApiURL + '/projects/',
queryArchiveProjectFilesApi:'http://ves-pg-41:9020/projects/', queryArchiveProjectFilesApi: this.$store.state.baseApiURL + '/projects/',
queryAssayApi:'https://www.ebi.ac.uk:443/pride/ws/archive/assay/list/project/', queryAssayApi:'https://www.ebi.ac.uk:443/pride/ws/archive/assay/list/project/',
europepmcApi:'http://europepmc.org/abstract/MED/', europepmcApi:'http://europepmc.org/abstract/MED/',
reactomeApi:'https://reactome.org/AnalysisService/identifiers/url?pageSize=1&page=1', reactomeApi:'https://reactome.org/AnalysisService/identifiers/url?pageSize=1&page=1',
viewInreactomeApi:'https://www.ebi.ac.uk/pride/ws/archive/protein/list/assay/', viewInreactomeApi:'https://www.ebi.ac.uk/pride/ws/archive/protein/list/assay/',
similarityApi:'http://ves-pg-41:9020/projects/', similarityApi: this.$store.state.baseApiURL + '/projects/',
contactors:[], contactors:[],
similarProjects:[], similarProjects:[],
similarityLoading:false, similarityLoading:false,
......
...@@ -120,6 +120,7 @@ ...@@ -120,6 +120,7 @@
</div> </div>
</template> </template>
<script> <script>
import store from "@/store/store.js"
export default { export default {
data () { data () {
return { return {
...@@ -127,7 +128,7 @@ ...@@ -127,7 +128,7 @@
selected: 'archive', selected: 'archive',
title:'', title:'',
subnav:[], subnav:[],
landingPageJsonURL:'/static/landingPage/landing_page.json' landingPageJsonURL: this.$store.state.baseURL + '/static/landingPage/landing_page.json'
} }
}, },
methods:{ methods:{
...@@ -200,7 +201,7 @@ ...@@ -200,7 +201,7 @@
border: 0 !important; border: 0 !important;
} }
.ebi-masthead{ .ebi-masthead{
background-image: url('/static/image/hero-beta-banner.png'); background-image: url('../../../static/image/hero-beta-banner.png');
} }
.ebi-masthead nav ul.menu li{ .ebi-masthead nav ul.menu li{
border-right: 1px solid rgb(248,248,248,0.7); border-right: 1px solid rgb(248,248,248,0.7);
......
...@@ -5,7 +5,7 @@ ...@@ -5,7 +5,7 @@
<Affix :offset-top="20"> <Affix :offset-top="20">
<div class="menu-wrapper"> <div class="menu-wrapper">
<Menu mode="vertical" :active-name="activeName" @on-select="menuSlect"> <Menu mode="vertical" :active-name="activeName" @on-select="menuSlect">
<MenuItem v-for="item in tableList" :name="item.name"> <MenuItem v-for="item in tableList" :name="item.name" :key="item.name">
<Icon type="ios-paper"></Icon>{{item.content}} <Icon type="ios-paper"></Icon>{{item.content}}
</MenuItem> </MenuItem>
</Menu> </Menu>
...@@ -23,12 +23,13 @@ ...@@ -23,12 +23,13 @@
</template> </template>
<script> <script>
import NavBar from '@/components/landingpage/Nav' import NavBar from '@/components/landingpage/Nav'
import store from "@/store/store.js"
export default { export default {
data () { data () {
return { return {
source: '', source: '',
activeName:'', activeName:'',
landingPageJsonURL:'/static/landingPage/landing_page.json', landingPageJsonURL: this.$store.state.baseURL + '/static/landingPage/landing_page.json',
tableList:[], tableList:[],
/* /*
anchorAttrs: { anchorAttrs: {
...@@ -66,7 +67,7 @@ ...@@ -66,7 +67,7 @@
this.source = ''; this.source = '';
this.activeName=''; this.activeName='';
this.tableList=[]; this.tableList=[];
this.markdownURL = '/static/markdown/'+subpage+'/content.md'; this.markdownURL = this.$store.state.baseURL + '/static/markdown/'+subpage+'/content.md';
this.$http this.$http
.get(this.markdownURL) .get(this.markdownURL)
.then(function(res){ .then(function(res){
......
...@@ -8,11 +8,12 @@ ...@@ -8,11 +8,12 @@
</template> </template>
<script> <script>
import NavBar from '@/components/landingpage/Nav' import NavBar from '@/components/landingpage/Nav'
import store from "@/store/store.js"
export default { export default {
data () { data () {
return { return {
source: '', source: '',
markdownURL:'/static/markdown/citationPage/content.md', markdownURL: this.$store.state.baseURL + '/static/markdown/citationPage/content.md',
} }
}, },
components: { components: {
......
...@@ -32,7 +32,7 @@ ...@@ -32,7 +32,7 @@
News News
}, },
mounted: function(){ mounted: function(){
console.log('this.$router',this.$router);
} }
} }
</script> </script>
......
...@@ -6,7 +6,7 @@ ...@@ -6,7 +6,7 @@
<!-- local-title --> <!-- local-title -->
<div class="columns medium-5" id="local-title"> <div class="columns medium-5" id="local-title">
<div class="pride-logo"> <div class="pride-logo">
<a href="../../" title="Back to [service-name] homepage"><img src="/static/logo/PRIDE_logo.png" alt="logo" width="500"></a> <a href="../../" title="Back to [service-name] homepage"><img :src="logoURL" alt="logo" width="500"></a>
</div> </div>
</div> </div>
<!-- /local-title --> <!-- /local-title -->
...@@ -121,6 +121,7 @@ ...@@ -121,6 +121,7 @@
</div> </div>
</template> </template>
<script> <script>
import store from "@/store/store.js"
export default { export default {
data () { data () {
return { return {
...@@ -128,7 +129,8 @@ ...@@ -128,7 +129,8 @@
selected: 'archive', selected: 'archive',
title:'', title:'',
subnav:[], subnav:[],
landingPageJsonURL:'/static/landingPage/landing_page.json' landingPageJsonURL: this.$store.state.baseURL + '/static/landingPage/landing_page.json',
logoURL: this.$store.state.baseURL + '/static/logo/PRIDE_logo.png',
} }
}, },
methods:{ methods:{
...@@ -204,7 +206,7 @@ ...@@ -204,7 +206,7 @@
border: 0 !important; border: 0 !important;
} }
.ebi-masthead{ .ebi-masthead{
background-image: url('/static/image/hero-beta-banner.png'); background-image: url('../../../static/image/hero-beta-banner.png');
} }
.ebi-masthead nav ul.menu li{ .ebi-masthead nav ul.menu li{
border-right: 1px solid rgb(248,248,248,0.7); border-right: 1px solid rgb(248,248,248,0.7);
......
...@@ -16,11 +16,11 @@ ...@@ -16,11 +16,11 @@
<div class="content-text"> <div class="content-text">
{{item.content}} {{item.content}}
</div> </div>
<a class="content-button" @click="moreButtonAction(item.markdownFolder,item.moreID)">More</a> <a class="content-button" @click="moreButtonAction(item.markdownFolder,item.moreID,item.externalURL)">More</a>
</div> </div>
</div> </div>
<Button class="news-button" @click="moreButtonAction(toolsButton.markdownFolder,toolsButton.moreID)">MORE</Button> <Button class="news-button" @click="moreButtonAction(toolsButton.markdownFolder,toolsButton.moreID,toolsButton.externalURL)">MORE</Button>
</div> </div>
</Col> </Col>
<Col :xs="{ span: 24 }" :sm="{span: 12}" :md="{ span: 12}" :lg="{ span: 6}"> <Col :xs="{ span: 24 }" :sm="{span: 12}" :md="{ span: 12}" :lg="{ span: 6}">
...@@ -37,10 +37,10 @@ ...@@ -37,10 +37,10 @@
<div class="content-text"> <div class="content-text">
{{item.content}} {{item.content}}
</div> </div>
<a class="content-button"@click="moreButtonAction(item.markdownFolder,item.moreID)">More</a> <a class="content-button"@click="moreButtonAction(item.markdownFolder,item.moreID,item.externalURL)">More</a>
</div> </div>
</div> </div>
<Button class="news-button" @click="moreButtonAction(documentationButton.markdownFolder,documentationButton.moreID)">MORE</Button> <Button class="news-button" @click="moreButtonAction(documentationButton.markdownFolder,documentationButton.moreID,documentationButton.externalURL)">MORE</Button>
</div> </div>
</Col> </Col>
<Col :xs="{ span: 24 }" :sm="{span: 12}" :md="{ span: 12}" :lg="{ span: 6}"> <Col :xs="{ span: 24 }" :sm="{span: 12}" :md="{ span: 12}" :lg="{ span: 6}">
...@@ -87,6 +87,7 @@ ...@@ -87,6 +87,7 @@
</template> </template>
<script> <script>
import Timeline from 'vue-tweet-embed/timeline' import Timeline from 'vue-tweet-embed/timeline'
import store from "@/store/store.js"
export default { export default {
components: { components: {
Timeline Timeline
...@@ -113,7 +114,7 @@ ...@@ -113,7 +114,7 @@
linefour:'', linefour:'',
button:{} button:{}
}, },
landingPageJsonURL:'/static/landingPage/landing_page.json' landingPageJsonURL: this.$store.state.baseURL + '/static/landingPage/landing_page.json'
} }
}, },
methods:{ methods:{
...@@ -161,7 +162,11 @@ ...@@ -161,7 +162,11 @@
}); });
*/ */
}, },
moreButtonAction(subpage, id){ moreButtonAction(subpage, id, externalLink){
if(externalLink){
window.open(externalLink);
return;
}
if(id){ if(id){
id = id.replace(/(^\s*)|(\s*$)/g,'').replace(/\s/g,'_').toLowerCase(); id = id.replace(/(^\s*)|(\s*$)/g,'').replace(/\s/g,'_').toLowerCase();
this.$router.push({path:'/markdownpage/'+subpage+'#'+id}); this.$router.push({path:'/markdownpage/'+subpage+'#'+id});
......
...@@ -32,11 +32,12 @@ ...@@ -32,11 +32,12 @@
</template> </template>
<script> <script>
import NavBar from '@/components/landingpage/Nav' import NavBar from '@/components/landingpage/Nav'
import store from "@/store/store.js"
export default { export default {
data () { data () {
return { return {
source: '', source: '',
markdownURL:'/static/markdown/documentationPage/content.md', markdownURL:this.$store.state.baseURL + '/static/markdown/documentationPage/content.md',
activeName:'one' activeName:'one'
/* /*
anchorAttrs: { anchorAttrs: {
......
...@@ -59,6 +59,7 @@ ...@@ -59,6 +59,7 @@
</div> </div>
</template> </template>
<script> <script>
import store from "@/store/store.js"
export default { export default {
data () { data () {
return { return {
...@@ -176,7 +177,7 @@ ...@@ -176,7 +177,7 @@
} }
], ],
searchExample:[], searchExample:[],
landingPageJsonURL:'/static/landingPage/landing_page.json' landingPageJsonURL: this.$store.state.baseURL + '/static/landingPage/landing_page.json'
} }
}, },
methods:{ methods:{
......
...@@ -42,13 +42,14 @@ ...@@ -42,13 +42,14 @@
import SankeyPrideSimple from './statistics_chart/SankeySimple.vue' import SankeyPrideSimple from './statistics_chart/SankeySimple.vue'
import MapPrideSimple from './statistics_chart/MapSimple.vue' import MapPrideSimple from './statistics_chart/MapSimple.vue'
import TreePrideSimple from './statistics_chart/TreeSimple.vue' import TreePrideSimple from './statistics_chart/TreeSimple.vue'
import store from "@/store/store.js"
export default { export default {
data () { data () {
return { return {
treePrideApi:'http://ves-pg-41:9020/stats/SUBMISSIONS_PER_CATEGORIES', treePrideApi: this.$store.state.baseApiURL + '/stats/SUBMISSIONS_PER_CATEGORIES',
sankeyPrideApi:'http://ves-pg-41:9020/stats/SUBMISSIONS_PER_MONTH', sankeyPrideApi: this.$store.state.baseApiURL + '/stats/SUBMISSIONS_PER_MONTH',
mapPrideApi:'http://ves-pg-41:9020/stats/SUBMISSIONS_PER_COUNTRY', mapPrideApi: this.$store.state.baseApiURL + '/stats/SUBMISSIONS_PER_COUNTRY',
linePrideApi:'http://ves-pg-41:9020/stats/SUBMISSIONS_PER_YEAR', linePrideApi: this.$store.state.baseApiURL + '/stats/SUBMISSIONS_PER_YEAR',
treePrideShow:true, treePrideShow:true,
sankeyPrideShow:true, sankeyPrideShow:true,
mapPrideShow:true, mapPrideShow:true,
......
...@@ -99,15 +99,16 @@ ...@@ -99,15 +99,16 @@
import PiePride from './statistics_chart/Pie.vue' import PiePride from './statistics_chart/Pie.vue'
import MapPride from './statistics_chart/Map.vue' import MapPride from './statistics_chart/Map.vue'
import NavBar from '@/components/landingpage/Nav' import NavBar from '@/components/landingpage/Nav'
import store from "@/store/store.js"
export default { export default {
data () { data () {
return { return {
treePrideApi:'http://ves-pg-41:9020/stats/SUBMISSIONS_PER_CATEGORIES', treePrideApi: this.$store.state.baseApiURL + '/stats/SUBMISSIONS_PER_CATEGORIES',
sunburstPrideApi:'http://ves-pg-41:9020/stats/SUBMISSIONS_PER_CATEGORIES', sunburstPrideApi: this.$store.state.baseApiURL + '/stats/SUBMISSIONS_PER_CATEGORIES',
sankeyPrideApi:'http://ves-pg-41:9020/stats/SUBMISSIONS_PER_MONTH', sankeyPrideApi: this.$store.state.baseApiURL + '/stats/SUBMISSIONS_PER_MONTH',
mapPrideApi:'http://ves-pg-41:9020/stats/SUBMISSIONS_PER_COUNTRY', mapPrideApi: this.$store.state.baseApiURL +'/stats/SUBMISSIONS_PER_COUNTRY',
linePrideYearApi:'http://ves-pg-41:9020/stats/SUBMISSIONS_PER_YEAR', linePrideYearApi: this.$store.state.baseApiURL + '/stats/SUBMISSIONS_PER_YEAR',
linePrideMonthApi:'http://ves-pg-41:9020/stats/SUBMISSIONS_PER_MONTH', linePrideMonthApi: this.$store.state.baseApiURL + '/stats/SUBMISSIONS_PER_MONTH',
sunburstPrideShow:true, sunburstPrideShow:true,
sankeyPrideShow:true, sankeyPrideShow:true,
mapPrideShow:true, mapPrideShow:true,
...@@ -188,7 +189,7 @@ ...@@ -188,7 +189,7 @@
facetsTypeChange(facets){ facetsTypeChange(facets){
this.piePrideShow=true; this.piePrideShow=true;
this.$http this.$http
.get('http://ves-pg-41:9020/stats/SUBMISSIONS_PER_'+facets) .get( this.$store.state.baseApiURL + '/stats/SUBMISSIONS_PER_'+facets)
.then(function(res){ .then(function(res){
this.piePrideShow=false; this.piePrideShow=false;
this.$bus.$emit('show-pie', res.body); this.$bus.$emit('show-pie', res.body);
......
...@@ -86,6 +86,7 @@ ...@@ -86,6 +86,7 @@
</div> </div>
</template> </template>
<script> <script>
import store from "@/store/store.js"
export default { export default {
data () { data () {
return { return {
...@@ -119,7 +120,7 @@ ...@@ -119,7 +120,7 @@
four: '', four: '',
five: '' five: ''
}, },
landingPageJsonURL:'/static/landingPage/landing_page.json', landingPageJsonURL: this.$store.state.baseURL + '/static/landingPage/landing_page.json',
markdownFolder:'' markdownFolder:''
} }
},