mirror of
https://github.com/ArenMg/aren.git
synced 2024-11-24 17:38:02 +00:00
resolve baseurl problem
This commit is contained in:
parent
f82b9d8ea5
commit
1837aa5cc6
6 changed files with 33 additions and 35 deletions
|
@ -234,15 +234,13 @@ module.exports = {
|
||||||
},
|
},
|
||||||
copyToClipBoard(text) {
|
copyToClipBoard(text) {
|
||||||
const getUrl = window.location;
|
const getUrl = window.location;
|
||||||
let baseUrl =
|
|
||||||
getUrl.protocol +
|
// let baseUrl = getUrl.protocol + "//" + getUrl.host + "/" + getUrl.pathname.split("/")[1];
|
||||||
"//" +
|
// if (baseUrl.endsWith("/")) {
|
||||||
getUrl.host +
|
// baseUrl = baseUrl.slice(0, -1);
|
||||||
"/" +
|
// }
|
||||||
getUrl.pathname.split("/")[1];
|
|
||||||
if (baseUrl.endsWith("/")) {
|
let baseUrl = getUrl.protocol + "//" + getUrl.host
|
||||||
baseUrl = baseUrl.slice(0, -1);
|
|
||||||
}
|
|
||||||
|
|
||||||
navigator.clipboard.writeText(`${baseUrl}${text}`).then(
|
navigator.clipboard.writeText(`${baseUrl}${text}`).then(
|
||||||
function () {
|
function () {
|
||||||
|
|
|
@ -171,11 +171,11 @@
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
const getUrl = window.location;
|
const getUrl = window.location;
|
||||||
let baseUrl =
|
// let baseUrl = getUrl.protocol + "//" + getUrl.host + "/" + getUrl.pathname.split("/")[1];
|
||||||
getUrl.protocol + "//" + getUrl.host + "/" + getUrl.pathname.split("/")[1];
|
// if (baseUrl.endsWith("/")) {
|
||||||
if (baseUrl.endsWith("/")) {
|
// baseUrl = baseUrl.slice(0, -1);
|
||||||
baseUrl = baseUrl.slice(0, -1);
|
// }
|
||||||
}
|
let baseUrl = getUrl.protocol + "//" + getUrl.host
|
||||||
module.exports = {
|
module.exports = {
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
|
|
|
@ -131,11 +131,11 @@
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
const getUrl = window.location;
|
const getUrl = window.location;
|
||||||
let baseUrl =
|
// let baseUrl = getUrl.protocol + "//" + getUrl.host + "/" + getUrl.pathname.split("/")[1];
|
||||||
getUrl.protocol + "//" + getUrl.host + "/" + getUrl.pathname.split("/")[1];
|
// if (baseUrl.endsWith("/")) {
|
||||||
if (baseUrl.endsWith("/")) {
|
// baseUrl = baseUrl.slice(0, -1);
|
||||||
baseUrl = baseUrl.slice(0, -1);
|
// }
|
||||||
}
|
let baseUrl = getUrl.protocol + "//" + getUrl.host
|
||||||
module.exports = {
|
module.exports = {
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
|
|
|
@ -83,7 +83,7 @@
|
||||||
<img
|
<img
|
||||||
alt="image"
|
alt="image"
|
||||||
class="category-picture"
|
class="category-picture"
|
||||||
v-bind:src="sondage.choices[0].img"
|
src="assets/img/sondage.png"
|
||||||
/>
|
/>
|
||||||
</div>
|
</div>
|
||||||
<div>
|
<div>
|
||||||
|
@ -104,11 +104,11 @@
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
const getUrl = window.location;
|
const getUrl = window.location;
|
||||||
let baseUrl =
|
// let baseUrl = getUrl.protocol + "//" + getUrl.host + "/" + getUrl.pathname.split("/")[1];
|
||||||
getUrl.protocol + "//" + getUrl.host + "/" + getUrl.pathname.split("/")[1];
|
// if (baseUrl.endsWith("/")) {
|
||||||
if (baseUrl.endsWith("/")) {
|
// baseUrl = baseUrl.slice(0, -1);
|
||||||
baseUrl = baseUrl.slice(0, -1);
|
// }
|
||||||
}
|
let baseUrl = getUrl.protocol + "//" + getUrl.host
|
||||||
module.exports = {
|
module.exports = {
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
|
|
|
@ -212,11 +212,11 @@
|
||||||
</style>
|
</style>
|
||||||
<script>
|
<script>
|
||||||
const getUrl = window.location;
|
const getUrl = window.location;
|
||||||
let baseUrl =
|
// let baseUrl = getUrl.protocol + "//" + getUrl.host + "/" + getUrl.pathname.split("/")[1];
|
||||||
getUrl.protocol + "//" + getUrl.host + "/" + getUrl.pathname.split("/")[1];
|
// if (baseUrl.endsWith("/")) {
|
||||||
if (baseUrl.endsWith("/")) {
|
// baseUrl = baseUrl.slice(0, -1);
|
||||||
baseUrl = baseUrl.slice(0, -1);
|
// }
|
||||||
}
|
let baseUrl = getUrl.protocol + "//" + getUrl.host
|
||||||
module.exports = {
|
module.exports = {
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
|
|
|
@ -313,11 +313,11 @@
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
const getUrl = window.location;
|
const getUrl = window.location;
|
||||||
let baseUrl =
|
// let baseUrl = getUrl.protocol + "//" + getUrl.host + "/" + getUrl.pathname.split("/")[1];
|
||||||
getUrl.protocol + "//" + getUrl.host + "/" + getUrl.pathname.split("/")[1];
|
// if (baseUrl.endsWith("/")) {
|
||||||
if (baseUrl.endsWith("/")) {
|
// baseUrl = baseUrl.slice(0, -1);
|
||||||
baseUrl = baseUrl.slice(0, -1);
|
// }
|
||||||
}
|
let baseUrl = getUrl.protocol + "//" + getUrl.host
|
||||||
Vue.component("modal", {
|
Vue.component("modal", {
|
||||||
template: "#modal-template",
|
template: "#modal-template",
|
||||||
});
|
});
|
||||||
|
|
Loading…
Reference in a new issue