Merge pull request 'xbx' (#149) from xbx into master
Reviewed-on: http://git.luyuan.tk/luyuan/beelink/pulls/149
This commit is contained in:
commit
b4477c0a39
@ -8,7 +8,7 @@
|
||||
<link rel="icon" href="<%= BASE_URL %>favicon.ico">
|
||||
<title><%= htmlWebpackPlugin.options.title %></title>
|
||||
<link href="https://imgcache.qq.com/open/qcloud/video/tcplayer/tcplayer.css" rel="stylesheet">
|
||||
<script data-ad-client="ca-pub-7145171713084445" async src="https://pagead2.googlesyndication.com/pagead/js/adsbygoogle.js"></script>
|
||||
|
||||
<!-- 如需在IE8、9浏览器中初始化播放器,浏览器需支持Flash并在页面中引入 -->
|
||||
<!--[if lt IE 9]>
|
||||
<script src="//imgcache.qq.com/open/qcloud/video/tcplayer/ie8/videojs-ie8.js"></script>
|
||||
@ -107,6 +107,19 @@
|
||||
</script>
|
||||
<script async defer crossorigin="anonymous" src="https://connect.facebook.net/en_US/sdk.js"></script>
|
||||
<script src="/js/cropper.min.js"></script>
|
||||
<div id="divadsensedisplaynone" style="width: 500px;height: 100px;display: none;" >
|
||||
<script data-ad-client="ca-pub-7145171713084445" async src="https://pagead2.googlesyndication.com/pagead/js/adsbygoogle.js"></script>
|
||||
<!-- 测试 -->
|
||||
<ins class="adsbygoogle"
|
||||
style="display:block"
|
||||
data-ad-client="ca-pub-7145171713084445"
|
||||
data-ad-slot="4213570423"
|
||||
data-ad-format="auto"
|
||||
data-full-width-responsive="true"></ins>
|
||||
<script>
|
||||
(adsbygoogle = window.adsbygoogle || []).push({});
|
||||
</script>
|
||||
</div>
|
||||
</body>
|
||||
|
||||
</html>
|
@ -27,6 +27,7 @@ export default defineComponent({
|
||||
if(getValue('token')){
|
||||
console.log("token")
|
||||
store.commit("login", true)
|
||||
store.dispatch("getcode");
|
||||
store.dispatch("setUserInfo");
|
||||
}else{
|
||||
|
||||
|
@ -1040,7 +1040,7 @@ export async function luzhi(roomid: string){
|
||||
}
|
||||
|
||||
export function getaddr() {
|
||||
return new Promise((r)=>{
|
||||
return new Promise(async (r)=>{
|
||||
console.log("开始定位")
|
||||
const lan = getValue("Lanvuage");
|
||||
if ("geolocation" in navigator) {
|
||||
@ -1056,7 +1056,7 @@ export function getaddr() {
|
||||
if(qh.data.ename == "China"){
|
||||
r({hb: '人民币¥', qh});
|
||||
}else {
|
||||
r({hb: '美元$'})
|
||||
r({hb: '美元$', qh})
|
||||
}
|
||||
}else{
|
||||
if(qh.data.ename == "China"){
|
||||
@ -1065,11 +1065,45 @@ export function getaddr() {
|
||||
r({yy: 'en', yyx: 'English', hb: '美元$', qh})
|
||||
}
|
||||
}
|
||||
},(err) => {
|
||||
message.error(err.message)
|
||||
console.log(err, 'err')
|
||||
},async () => {
|
||||
const qh = await get<any>('countryCode', {
|
||||
|
||||
});
|
||||
console.log(qh)
|
||||
if(lan != null && lan){
|
||||
if(qh.data.ename == "China"){
|
||||
r({hb: '人民币¥', qh});
|
||||
}else {
|
||||
r({hb: '美元$', qh})
|
||||
}
|
||||
}else{
|
||||
if(qh.data.ename == "China"){
|
||||
r({yy: "zh", yyx: "中文", hb: '人民币¥', qh});
|
||||
}else {
|
||||
r({yy: 'en', yyx: 'English', hb: '美元$', qh})
|
||||
}
|
||||
}
|
||||
// message.error(err.message)
|
||||
// console.log(err, 'err')
|
||||
})
|
||||
} else {
|
||||
const qh = await get<any>('countryCode', {
|
||||
|
||||
});
|
||||
console.log(qh)
|
||||
if(lan != null && lan){
|
||||
if(qh.data.ename == "China"){
|
||||
r({hb: '人民币¥', qh});
|
||||
}else {
|
||||
r({hb: '美元$', qh})
|
||||
}
|
||||
}else{
|
||||
if(qh.data.ename == "China"){
|
||||
r({yy: "zh", yyx: "中文", hb: '人民币¥', qh});
|
||||
}else {
|
||||
r({yy: 'en', yyx: 'English', hb: '美元$', qh})
|
||||
}
|
||||
}
|
||||
/* 地理位置服务不可用 */
|
||||
console.log("无法定位")
|
||||
}
|
||||
|
@ -110,6 +110,9 @@ export default createStore({
|
||||
}
|
||||
|
||||
},
|
||||
setquhao(state, data){
|
||||
state.qh = data.qh.data;
|
||||
},
|
||||
setWlan(state){
|
||||
const lan = getValue("Lanvuage");
|
||||
if(lan != null && lan){
|
||||
@ -134,6 +137,11 @@ export default createStore({
|
||||
const info = await getaddr();
|
||||
console.log(info,11256445);
|
||||
commit("setLanguage", info)
|
||||
},
|
||||
async getcode({ commit }){
|
||||
const info = await getaddr();
|
||||
console.log(info,11256445);
|
||||
commit("setquhao", info)
|
||||
}
|
||||
},
|
||||
modules: {
|
||||
|
@ -23,7 +23,7 @@
|
||||
</a-select-option>
|
||||
<a-select-option value="Jiangsu"> Jiangsu </a-select-option>
|
||||
</a-select> -->
|
||||
<a-select :default-value="mrqh.name + '+' + mrqh.code" size="small" option-label-prop="label" @change="getquhao" class="getcode" show-search >
|
||||
<a-select v-model:value="hqqh" size="small" option-label-prop="label" @change="getquhao" class="getcode" show-search >
|
||||
<a-select-option v-for="(i,j) in quhaolist" :key="j" :value="i.name + '+' + i.code" :label="'+' + i.code">
|
||||
{{i.name}}+{{i.code}}
|
||||
</a-select-option>
|
||||
@ -147,6 +147,7 @@ export default defineComponent({
|
||||
password: '123456'
|
||||
})
|
||||
const mrqh = computed(() => store.state.qh)
|
||||
const hqqh = computed(() => { return mrqh.value.name + '+' + mrqh.value.code })
|
||||
const quhaolist = ref<any>([
|
||||
{
|
||||
code: "86",
|
||||
@ -284,7 +285,8 @@ export default defineComponent({
|
||||
navto,
|
||||
lan,
|
||||
slogin,
|
||||
mrqh
|
||||
mrqh,
|
||||
hqqh
|
||||
};
|
||||
},
|
||||
});
|
||||
|
Loading…
Reference in New Issue
Block a user