充值多语言暂存

This commit is contained in:
dragon
2024-05-31 17:04:32 +08:00
parent 4bbf91e941
commit e4be094fc5
7 changed files with 177 additions and 85 deletions

Binary file not shown.

After

Width:  |  Height:  |  Size: 14 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 16 KiB

View File

@@ -45,18 +45,18 @@
<!-- tab -->
<div class="tab tab1">
<div class="active">
在線儲值
<b class="text6"></b>
<span></span>
</div>
<div class="tabs">
官方代儲
<b class="text7"></b>
<span></span>
<i>推薦</i>
<i class="text8"></i>
</div>
</div>
<!-- 充值页面 -->
<div class="page1">
<h3>儲值方式</h3>
<h3 class="text9"></h3>
<div class="way">
<!-- <div class="">
<img src="./images/logo.png" alt="">
@@ -64,7 +64,7 @@
<span>推薦</span>
</div> -->
</div>
<h3>儲值金額</h3>
<h3 class="text10"></h3>
<div class="position">
<!-- <div class="">
<p><img src="./images/gold.png" alt="">0</p>
@@ -73,17 +73,15 @@
</div>
<div class="payButBox">
<!-- 确认充值 -->
<div class="payBut">確認儲值</div>
<div class="payBut text11"></div>
</div>
</div>
<!-- 代充页面 -->
<div class="page2">
<div class="rule">
<p>官方代儲說明:</p>
<p>若您有各種儲值需求可以使用官方代儲服務點擊聯系可直接前往molistar App咨詢相應代儲如點擊聯系無效果可復製代儲molistar
ID進入App後搜索相應代儲並聯系官方代儲在收到款項後會直接對您的賬戶進行鉆石儲值</p>
<div class="rule text12">
</div>
<h3>平臺簽約代儲</h3>
<h3 class="text13"></h3>
<!-- 代充列表 -->
<ul>
<!-- <li>
@@ -97,71 +95,66 @@
<div class="but">聯系</div>
<div class="copy">復製ID</div>
</li> -->
<li class="null">
<!-- <li class="null">
<img src="./images/null.png" alt="">
<p>該地區暫無簽約代儲</p>
</li>
</li> -->
</ul>
</div>
<!-- 充值说明 -->
<div class="rule">
<p><img src="./images/trueIcon.png" alt="" class="">已閱讀並同意<a
href="../rule/rechargeAgreement.html">《用戶充值協議》</a>以及<a href="../rule/privacy-wap.html">《隱私政策》</a>
</p>
<p>如有疑問,請聯系官方客服</p>
<p>客服WeChat:sd245376</p>
<!-- <p>客服Line:molistaryuyin</p> -->
<div class="rule text14">
</div>
<!-- 选择地区弹窗 -->
<div class="area">
<div class="area_in">
<h3>請選擇储值地区</h3>
<h3 class="text15"></h3>
</div>
</div>
<!-- 绑定信息失败弹窗 -->
<div class="userNull">
<div class="userNull_in">
<p>用戶ID有誤請更換ID後重試</p>
<div class="but">確認</div>
<p class="text16"></p>
<div class="but text4"></div>
</div>
</div>
<!-- 二次确认充值对象弹窗弹窗 -->
<div class="sure">
<div class="sure_in">
<h3>請確認儲值對象</h3>
<h3 class="text17"></h3>
<img src="./images/logo.png" alt="">
<p>昵稱我是昵稱</p>
<b>molistar ID123456</b>
<div class="close">取消</div>
<div class="ok">確認</div>
<p></p>
<b></b>
<div class="close text18"></div>
<div class="ok text4"></div>
</div>
</div>
<!-- 信息弹窗提示 -->
<div class="toastMasge">
<div class="toastMasge_in">
<p>请打开molistar并搜索该用户</p>
<div class="but">確認</div>
<p class="text19"></p>
<div class="but text4"></div>
</div>
</div>
<!-- 首次选择弹窗 -->
<div class="selectAddress">
<div class="selectAddress_in">
<div class="title">請確認儲值地區</div>
<div class="title text15"></div>
<div class="selectAddressList">
<img src="./images/more_icon.png" alt="">
</div>
<div class="list_in">
<p>台湾</p>
<p>台湾</p>
<p>台湾</p>
<p>台湾</p>
<p></p>
<p></p>
<p></p>
<p></p>
</div>
<div class="but">確認</div>
<div class="but text4"></div>
</div>
</div>
<!-- 引导图 -->
<div class="guidd">
<img src="./images/guide.png" alt="">
<img class="text20" src="./images/guide.png" alt="">
</div>
</div>
</body>

View File

@@ -79,14 +79,15 @@ function translateFun() {
$('.text9').text(langReplace(localLang.demoModule.text9));
$('.text10').text(langReplace(localLang.demoModule.text10));
$('.text11').text(langReplace(localLang.demoModule.text11));
$('.text12').text(langReplace(localLang.demoModule.text12));
$('.text12').html(langReplace(localLang.demoModule.text12));
$('.text13').text(langReplace(localLang.demoModule.text13));
$('.text14').text(langReplace(localLang.demoModule.text14));
$('.text14').html(langReplace(localLang.demoModule.text14));
$('.text15').text(langReplace(localLang.demoModule.text15));
$('.text16').text(langReplace(localLang.demoModule.text16));
$('.text17').text(langReplace(localLang.demoModule.text17));
$('.text18').text(langReplace(localLang.demoModule.text18));
$('.text19').text(langReplace(localLang.demoModule.text19));
$('.text20').attr('src', langReplace(localLang.demoModule.text20));
}
// 请求地区列表
function getArea() {
@@ -212,7 +213,7 @@ function getChargePageInfoForH5Html(res, id, bool) {
<div style="${(i + 1) % 3 == 0 ? 'margin-right:0rem' : ''}" class="${i == 0 ? 'active' : ''}" id=${i} payChannel=${res.chargeWays[0].payChannel} paymentType=${res.chargeWays[0].paymentType}>
<img src="${res.chargeWays[0].logo}" alt="">
<p>${res.groupName}</p>
<span style="display:${res.chargeWays[0].recommend == 1 ? 'block' : 'none'}">推薦</span>
<span style="display:${res.chargeWays[0].recommend == 1 ? 'block' : 'none'}">${langReplace(localLang.demoModule.text8)}</span>
</div>
`
});
@@ -284,19 +285,19 @@ $('.rule p img').click(function () {
// 确认充值按钮
$('.page1 .payBut').click(function () {
if (!erbanNo) {
toastMsg('請先確認綁定molistar ID')
toastMsg(langReplace(localLang.demoModule.text21))
return
}
if (!payChannel) {
toastMsg('請選擇儲值方式')
toastMsg(langReplace(localLang.demoModule.text22))
return
}
if (!chargeProdId) {
toastMsg('請選擇您的儲值金額')
toastMsg(langReplace(localLang.demoModule.text23))
return
}
if (textLock == false) {
toastMsg('請先勾選充值協議')
toastMsg(langReplace(localLang.demoModule.text24))
return
}
if (apply2NewLock) {
@@ -315,7 +316,7 @@ $('.page1 .payBut').click(function () {
// 确定绑定按钮
$('.bindingBox .binding .but').click(function () {
if ($('.bindingBox .binding input').val() == '') {
toastMsg('請輸入平台號');
toastMsg(langReplace(localLang.demoModule.text25));
return
}
getSimpleUser($('.bindingBox .binding input').val());
@@ -425,7 +426,7 @@ function rechargeUserList(regionCode) {
if (res.code == 200) {
var str = ''
if (res.data.length <= 0) {
str = '<li class="null"><img src="./images/null.png" alt=""><p>該地區暫無簽約代儲</p></li>'
str = `<li class="null"><img src="./images/null.png" alt=""><p>${langReplace(localLang.demoModule.text26)}</p></li>`
} else {
res.data.forEach((res) => {
str += `
@@ -433,12 +434,12 @@ function rechargeUserList(regionCode) {
<div class="left">
<div class="name">
<b>${res.nick.length > 9 ? res.nick.slice(0, 9) + '...' : res.nick}</b>
<span style="display:${res.isOnline == 0 ? 'none' : 'block'}"><i></i>在線</span>
<span style="display:${res.isOnline == 0 ? 'none' : 'block'}"><i></i>${langReplace(localLang.demoModule.text27)}</span>
</div>
<div class="id">molistar ID${res.erbanNo}</div>
</div>
<div class="but" uid=${res.uid} erbanNo=${res.erbanNo}>聯系</div>
<div id="copy" class="copy" uid=${res.uid} erbanNo=${res.erbanNo}>復製ID</div>
<div class="but" uid=${res.uid} erbanNo=${res.erbanNo}>${langReplace(localLang.demoModule.text28)}</div>
<div id="copy" class="copy" uid=${res.uid} erbanNo=${res.erbanNo}>${langReplace(localLang.demoModule.text29)}</div>
</li>
`
});
@@ -535,10 +536,10 @@ function copyToClipboard(text) {
try {
var successful = document.execCommand('copy');
var msg = successful ? '復制成功' : '該瀏覽器不支持點擊復制到剪貼闆';
var msg = successful ? langReplace(localLang.demoModule.text30) : langReplace(localLang.demoModule.text31);
toastMsg(msg);
} catch (err) {
toastMsg('該瀏覽器不支持點擊復制到剪貼闆');
toastMsg(langReplace(localLang.demoModule.text32));
}
document.body.removeChild(textArea);
@@ -587,14 +588,14 @@ $('.sure .sure_in .ok').click(function () {
})
//返回页面 重新请求接口
var hiddenProperty = 'hidden' in document ? 'hidden' :
'webkitHidden' in document ? 'webkitHidden' :
'mozHidden' in document ? 'mozHidden' : null;
// var hiddenProperty = 'hidden' in document ? 'hidden' :
// 'webkitHidden' in document ? 'webkitHidden' :
// 'mozHidden' in document ? 'mozHidden' : null;
var visibilityChangeEvent = hiddenProperty.replace(/hidden/i, 'visibilitychange');
var onVisibilityChange = function () {
if (!document[hiddenProperty]) {
location.reload()
}
}
document.addEventListener(visibilityChangeEvent, onVisibilityChange);
// var visibilityChangeEvent = hiddenProperty.replace(/hidden/i, 'visibilitychange');
// var onVisibilityChange = function () {
// if (!document[hiddenProperty]) {
// location.reload()
// }
// }
// document.addEventListener(visibilityChangeEvent, onVisibilityChange);

View File

@@ -2,5 +2,44 @@
langAr = {
// 模块
demoModule: {
text20: './images/guide.png',
layerIndex1: `جارٍ التحميل...`,
layerIndex2: `تمت العملية بنجاح`,
layerIndex3: `خطأ في الشبكة`,
text1: `إعادة الشحن`,
text2: `مركز شحن MoliStar`,
text3: `الرجاء إدخال معرف Molistar لإعادة الشحن`,
text4: `تأكيد`,
text5: `تبديل المعرف`,
text6: `الشحن عبر الإنترنت`,
text7: `الشحن الرسمي`,
text8: `توصية`,
text9: `طريقة الشحن`,
text10: `مبلغ الشحن`,
text11: `تأكيد الشحن`,
text12: `<p>شرح الشحن الرسمي:</p>
<p>إذا كانت لديك احتياجات مختلفة للشحن، يمكنك استخدام خدمة الشحن الرسمية. انقر على الاتصال للانتقال مباشرة إلى تطبيق موليستار للتشاور حول الشحن المتعلق (إذا لم يكن النقر على الاتصال له تأثير، يمكنك نسخ معرف الشحن موليستار وإدخال التطبيق للبحث عن الشحن ذي الصلة والاتصال). بعد استلام الدفعة، سيقوم الشحن الرسمي بشحن الماس مباشرة إلى حسابك.</p>`,
text13: `توقيع المنصة للشحن`,
text14: `<p><img src="./images/trueIcon.png" alt="" class="">لقد قرأت ووافقت على <a href="../rule/rechargeAgreement.html">"اتفاقية شحن المستخدم"</a> و <a href="../rule/privacy-wap.html">"سياسة الخصوصية"</a></p>
<p>إذا كان لديك أي أسئلة، يرجى الاتصال بخدمة العملاء</p>
<p>خدمة العملاء WeChat: sd245376</p>
<!-- <p>خدمة العملاء Line: molistaryuyin</p> -->`,
text15: `يرجى تأكيد منطقة الشحن`,
text16: `معرف المستخدم غير صحيح، يرجى المحاولة مرة أخرى بعد تغيير المعرف`,
text17: `يرجى تأكيد هدف الشحن`,
text18: `إلغاء`,
text19: `يرجى فتح موليستار والبحث عن المستخدم`,
text21: `يرجى تأكيد ربط معرف موليستار أولاً`,
text22: `يرجى اختيار طريقة الشحن`,
text23: `يرجى تحديد مبلغ الشحن الخاص بك`,
text24: `يرجى التحقق من اتفاقية الشحن أولاً`,
text25: `الرجاء إدخال رقم المنصة`,
text26: `لا يوجد وكيل شحن موقع في هذه المنطقة مؤقتًا`,
text27: `عبر الإنترنت`,
text28: `اتصال`,
text29: `نسخ المعرف`,
text30: `نسخ بنجاح`,
text31: `هذا المتصفح لا يدعم النقر للنسخ إلى الحافظة`,
text32: `هذا المتصفح لا يدعم النقر للنسخ إلى الحافظة`,
}
}

View File

@@ -2,5 +2,44 @@
langEn = {
// 模块
demoModule: {
text20: './images/guide.png',
layerIndex1: `Loading...`,
layerIndex2: `Operation completed`,
layerIndex3: `Network error`,
text1: `Recharge`,
text2: `MoliStar Recharge Center`,
text3: `Please enter the Molistar ID to recharge`,
text4: `Confirm`,
text5: `Switch ID`,
text6: `Online recharge`,
text7: `Official recharge`,
text8: `Recommendation`,
text9: `Recharge method`,
text10: `Recharge amount`,
text11: `Confirm recharge`,
text12: `<p>Official recharge explanation:</p>
<p>If you have various recharge needs, you can use the official recharge service. Click contact to go directly to the molistar App for relevant recharge consultation (if clicking contact has no effect, you can copy the recharge molistar ID and enter the App to search for the relevant recharge and contact). After receiving the payment, the official recharge will directly recharge diamonds to your account.</p>`,
text13: `Platform signing recharge`,
text14: `<p><img src="./images/trueIcon.png" alt="" class="">Have read and agree to <a href="../rule/rechargeAgreement.html">"User Recharge Agreement"</a> and <a href="../rule/privacy-wap.html">"Privacy Policy"</a></p>
<p>If you have any questions, please contact customer service</p>
<p>Customer Service WeChat: sd245376</p>
<!-- <p>Customer Service Line: molistaryuyin</p> -->`,
text15: `Please confirm the recharge region`,
text16: `Incorrect user ID, please try again after changing ID`,
text17: `Please confirm the recharge target`,
text18: `Cancel`,
text19: `Please open molistar and search for the user`,
text21: `Please confirm binding molistar ID first`,
text22: `Please select recharge method`,
text23: `Please select your recharge amount`,
text24: `Please check the recharge agreement first`,
text25: `Please enter the platform number`,
text26: `No signed recharge agent in this region temporarily`,
text27: `Online`,
text28: `Contact`,
text29: `Copy ID`,
text30: `Copy successful`,
text31: `This browser does not support click to copy to clipboard`,
text32: `This browser does not support click to copy to clipboard`,
}
}

View File

@@ -1,28 +1,48 @@
// 简体中文
// 簡體中文
langZh = {
// 模
// 模
demoModule: {
layerIndex1:`加载中...`,
layerIndex2:`操作完成`,
layerIndex3:`網絡錯誤`,
text1:`充值`,
text2:`MoliStar儲值中心`,
text3:`請輸入要儲值的molistar ID`,
text4:`確定`,
text5:`切換ID`,
text6:``,
text7:``,
text7:``,
text9:``,
text10:``,
text11:``,
text12:``,
text13:``,
text14:``,
text15:``,
text16:``,
text17:``,
text18:``,
text19:``,
text20:'./images/guide.png',
layerIndex1: `加載中...`,
layerIndex2: `操作完成`,
layerIndex3: `網絡錯誤`,
text1: `充值`,
text2: `MoliStar儲值中心`,
text3: `請輸入要儲值的molistar ID`,
text4: `確定`,
text5: `切換ID`,
text6: `在線儲值`,
text7: `官方代儲`,
text8: `推薦`,
text9: `儲值方式`,
text10: `儲值金額`,
text11: `確認儲值`,
text12: `<p>官方代儲說明:</p>
<p>若您有各種儲值需求可以使用官方代儲服務點擊聯繫可直接前往molistar App咨詢相應代儲如點擊聯繫無效果可復製代儲molistar
ID進入App後搜索相應代儲並聯繫官方代儲在收到款項後會直接對您的賬戶進行鉆石儲值</p>`,
text13: `平臺簽約代儲`,
text14: `<p><img src="./images/trueIcon.png" alt="" class="">已閱讀並同意<a
href="../rule/rechargeAgreement.html">《用戶充值協議》</a>以及<a href="../rule/privacy-wap.html">《隱私政策》</a>
</p>
<p>如有疑問,請聯繫官方客服</p>
<p>客服WeChat:sd245376</p>
<!-- <p>客服Line:molistaryuyin</p> -->`,
text15: `請確認儲值地區`,
text16: `用戶ID有誤請更換ID後重試`,
text17: `請確認儲值對象`,
text18: `取消`,
text19: `請打開molistar併搜索該用戶`,
text21: `請先確認綁定molistar ID`,
text22: `請選擇儲值方式`,
text23: `請選擇您的儲值金額`,
text24: `請先勾選充值協議`,
text25: `請輸入平臺號`,
text26: `該地區暫無簽約代儲`,
text27: `在線`,
text28: `聯繫`,
text29: `復製ID`,
text30: `復制成功`,
text31: `該瀏覽器不支持點擊復制到剪貼闆`,
text32: `該瀏覽器不支持點擊復制到剪貼闆`,
}
}