|
@@ -24,7 +24,6 @@
|
|
|
</div>
|
|
|
</div>
|
|
|
<div class="userInfoBox">
|
|
|
-
|
|
|
<!-- 地区 -->
|
|
|
<div v-if="isInland && user.type != '0'">
|
|
|
<div v-if="!areaShow" class="userInfo l-flex-between">
|
|
@@ -104,29 +103,6 @@
|
|
|
</div>
|
|
|
</div>
|
|
|
|
|
|
- <!-- 关联上级 -->
|
|
|
- <!-- <div v-if="isInland && user.type == '2'">
|
|
|
- <div v-if="!relationType" class="userInfo l-flex-between">
|
|
|
- <span class="userInfoLeft">{{ $t("user.associateParent") }}: </span>
|
|
|
- <div >
|
|
|
- <van-field class="relationClass" v-model="cofficentForm.associateParent"
|
|
|
- :placeholder="$t('user.associateParentPlace')">
|
|
|
- <template #button>
|
|
|
- <van-button type="primary" @click="mailboxChg(cofficentForm.associateParent, 1)">{{
|
|
|
- $t("user.confirmLog") }}
|
|
|
- </van-button>
|
|
|
- </template>
|
|
|
- </van-field>
|
|
|
- </div>
|
|
|
- <van-icon name="edit" class="editIcon" @click="editClk(1)" />
|
|
|
- </div>
|
|
|
- <div v-else class="userInfo l-flex-between">
|
|
|
- <span class="userInfoLeft">{{ $t("user.associateParent") }}: </span>
|
|
|
- <span>{{ relationAdminName }}</span>
|
|
|
- <van-icon name="edit" class="editIcon" @click="editClk(1)" />
|
|
|
- </div>
|
|
|
- </div> -->
|
|
|
-
|
|
|
<!-- 自定义货币符号 -->
|
|
|
<div v-if="!symbolShow" class="userInfo l-flex-between">
|
|
|
<span class="userInfoLeft">{{ $t("user.currencySymbol") }}: </span>
|
|
@@ -148,6 +124,34 @@
|
|
|
<span>{{ accountDetail.currencySymbol }}</span>
|
|
|
<van-icon name="edit" class="editIcon" @click="editClk(5)" />
|
|
|
</div>
|
|
|
+ <!-- 时区 -->
|
|
|
+ <div v-if="user.type > 1">
|
|
|
+ <div v-if="!timezoneShow" class="userInfo l-flex-between">
|
|
|
+ <span class="userInfoLeft">{{ $t("user.setTheTimezone") }}: </span>
|
|
|
+ <div class="cust_vantBorder">
|
|
|
+ <div class="filedInpPad">
|
|
|
+ <van-field @click-input="tzFieldValueInpClk" readonly clearable v-model="tzFieldValue"
|
|
|
+ :placeholder="$t('user.setTheTimezonePlace')">
|
|
|
+ <template #right-icon>
|
|
|
+ <div class="l-flex-RC">
|
|
|
+ <van-icon v-if="tzFieldValue" @click="tzFieldValue = ''; accountDetail.timeZone = '';"
|
|
|
+ class="o-mr-6" name="clear" />
|
|
|
+ <van-icon @click="tzFieldValueInpClk" name="arrow-down" />
|
|
|
+ </div>
|
|
|
+ </template>
|
|
|
+ </van-field>
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+ <van-icon name="edit" class="editIcon" @click="editClk(7)" />
|
|
|
+ </div>
|
|
|
+ <div v-else class="userInfo l-flex-between">
|
|
|
+ <span class="userInfoLeft">{{ $t("user.setTheTimezone") }}: </span>
|
|
|
+ <span>{{ tzFieldValue }}</span>
|
|
|
+ <van-icon name="edit" class="editIcon" @click="editClk(7)" />
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+
|
|
|
+ <!-- DIY使用密码 -->
|
|
|
<div v-if="user.type == '0'">
|
|
|
<div v-if="!diyPasswordShow" class="userInfo l-flex-between">
|
|
|
<span class="userInfoLeft">{{ $t("user.diyPassword") }}: </span>
|
|
@@ -238,23 +242,6 @@
|
|
|
</div>
|
|
|
</div>
|
|
|
|
|
|
- <!-- 提现帐号 -->
|
|
|
- <!-- <div v-if="isInland" class="taskListRow flex-col" @click="pushPageList('/joinpayMch')">
|
|
|
- <div class="taskIcon joinPayMchIcon"></div>
|
|
|
- <div class="taskRight">
|
|
|
- <div class="taskTitle">{{ $t("user.withdrawalAccountNo") }}</div>
|
|
|
- </div>
|
|
|
- </div> -->
|
|
|
-
|
|
|
- <!-- Airwallex 钱包 -->
|
|
|
- <!-- <div v-if="isAbroad && user.companyType != '1'" class="taskListRow flex-col"
|
|
|
- @click="pushPageList('/airwallex')">
|
|
|
- <div class="taskIcon airwallexIcon"></div>
|
|
|
- <div class="taskRight">
|
|
|
- <div class="taskTitle">{{ $t("user.airwallex") }}</div>
|
|
|
- </div>
|
|
|
- </div> -->
|
|
|
-
|
|
|
<!-- 公告编辑 -->
|
|
|
<div v-if="user.type == '0'" class="taskListRow flex-col" @click="pushPageList('/announcement')">
|
|
|
<div class="taskIcon announcementIcon"></div>
|
|
@@ -264,14 +251,7 @@
|
|
|
</div>
|
|
|
</div>
|
|
|
</div>
|
|
|
- <!-- <div class="taskListRow flex-col" @click="pushPageList('/shandeMch')">
|
|
|
- <div class="taskIcon shandeMchIcon"></div>
|
|
|
- <div class="taskRight">
|
|
|
- <div class="taskTitle">
|
|
|
- {{ $t("user.standbyWithdrawalAccountNo") }}
|
|
|
- </div>
|
|
|
- </div>
|
|
|
- </div>-->
|
|
|
+
|
|
|
<!-- 绑定微信 -->
|
|
|
<div v-if="isInWeChat" class="taskListRow flex-col" @click="pushPageList('/bindWechat')">
|
|
|
<!-- <div class="taskListRow flex-col" @click="pushPageList('/bindWechat')">-->
|
|
@@ -321,13 +301,6 @@
|
|
|
</div>
|
|
|
</div>
|
|
|
|
|
|
- <!-- 自动充值 -->
|
|
|
- <!-- <div v-if="isInland" class="taskListRow flex-col" @click="operUnipay()">
|
|
|
- <div class="taskIcon selfPayIcon"></div>
|
|
|
- <div class="taskRight">
|
|
|
- <div class="taskTitle">{{ $t("user.selfRecharging") }}</div>
|
|
|
- </div>
|
|
|
- </div> -->
|
|
|
|
|
|
<div class="taskListRow flex-col" @click="onperExitSys()">
|
|
|
<div class="taskIcon loginOutIcon"></div>
|
|
@@ -346,12 +319,18 @@
|
|
|
<!-- 地区弹窗 -->
|
|
|
<kCascader @getareaname="getAreaName" :selectId="accountDetail.areaId" @areapopfinish="areaPopFinish"
|
|
|
ref="kCascaderRef"></kCascader>
|
|
|
+ <!-- 时区弹窗 -->
|
|
|
+ <kTimezone @gettimezone="getTimezone" :selectId="accountDetail.timezone" @timezonepopfinish="timezonePopFinish"
|
|
|
+ ref="kTimezoneRef"></kTimezone>
|
|
|
+
|
|
|
</div>
|
|
|
</template>
|
|
|
|
|
|
<script>
|
|
|
// 导入地区弹窗
|
|
|
import kCascader from "@/components/commom/kCascader/index.vue";
|
|
|
+// 导入时区弹窗
|
|
|
+import kTimezone from "@/components/commom/kTimezone/index.vue";
|
|
|
// 导入接口
|
|
|
import { getAdmin } from "@/service/merchantManage";
|
|
|
import { updateAdmin } from "@/service/merchantManage";
|
|
@@ -371,7 +350,7 @@ import { useI18n } from "vue-i18n";
|
|
|
import { styleUrl } from "../common/js/utils";
|
|
|
|
|
|
export default {
|
|
|
- components: { sHeader, kDialog, kCascader },
|
|
|
+ components: { sHeader, kDialog, kCascader, kTimezone },
|
|
|
setup() {
|
|
|
// 引入语言
|
|
|
const { t } = useI18n();
|
|
@@ -387,6 +366,8 @@ export default {
|
|
|
const symbolShow = ref(true);
|
|
|
// 控制DIY使用密码显示隐藏
|
|
|
const diyPasswordShow = ref(true);
|
|
|
+ // 控制时区显示隐藏
|
|
|
+ const timezoneShow = ref(true);
|
|
|
// 控制切换支付平台按钮显示隐藏
|
|
|
const chaSzPayShow = ref(false);
|
|
|
const chaScPayShow = ref(false);
|
|
@@ -414,6 +395,7 @@ export default {
|
|
|
phone: accountDetail.value.phone,
|
|
|
area: "",
|
|
|
currencySymbol: accountDetail.value.currencySymbol,
|
|
|
+ timeZone: accountDetail.value.timeZone,
|
|
|
});
|
|
|
//
|
|
|
const params = reactive({
|
|
@@ -431,6 +413,7 @@ export default {
|
|
|
areaShow.value = true;
|
|
|
symbolShow.value = true;
|
|
|
diyPasswordShow.value = true;
|
|
|
+ timezoneShow.value = true;
|
|
|
break;
|
|
|
case 2:
|
|
|
cofficentForm.mailBox = accountDetail.value.email;
|
|
@@ -440,6 +423,7 @@ export default {
|
|
|
areaShow.value = true;
|
|
|
symbolShow.value = true;
|
|
|
diyPasswordShow.value = true;
|
|
|
+ timezoneShow.value = true;
|
|
|
break;
|
|
|
case 3:
|
|
|
cofficentForm.phone = accountDetail.value.phone;
|
|
@@ -449,6 +433,7 @@ export default {
|
|
|
areaShow.value = true;
|
|
|
symbolShow.value = true;
|
|
|
diyPasswordShow.value = true;
|
|
|
+ timezoneShow.value = true;
|
|
|
break;
|
|
|
case 4:
|
|
|
cofficentForm.area = accountDetail.value.area;
|
|
@@ -458,6 +443,7 @@ export default {
|
|
|
areaShow.value = !areaShow.value;
|
|
|
symbolShow.value = true;
|
|
|
diyPasswordShow.value = true;
|
|
|
+ timezoneShow.value = true;
|
|
|
break;
|
|
|
case 5:
|
|
|
cofficentForm.currencySymbol = accountDetail.value.currencySymbol;
|
|
@@ -467,6 +453,7 @@ export default {
|
|
|
areaShow.value = true;
|
|
|
symbolShow.value = !symbolShow.value;
|
|
|
diyPasswordShow.value = true;
|
|
|
+ timezoneShow.value = true;
|
|
|
break;
|
|
|
case 6:
|
|
|
cofficentForm.currencySymbol = accountDetail.value.currencySymbol;
|
|
@@ -476,9 +463,22 @@ export default {
|
|
|
areaShow.value = true;
|
|
|
symbolShow.value = true;
|
|
|
diyPasswordShow.value = !diyPasswordShow.value;
|
|
|
+ timezoneShow.value = true;
|
|
|
+ break;
|
|
|
+ case 7:
|
|
|
+ cofficentForm.timeZone = accountDetail.value.timeZone;
|
|
|
+ relationType.value = true;
|
|
|
+ mailboxShow.value = true;
|
|
|
+ phoneNumberShow.value = true;
|
|
|
+ areaShow.value = true;
|
|
|
+ symbolShow.value = true;
|
|
|
+ diyPasswordShow.value = true;
|
|
|
+ timezoneShow.value = !timezoneShow.value;
|
|
|
break;
|
|
|
}
|
|
|
};
|
|
|
+
|
|
|
+
|
|
|
// 点击邮箱的确定按钮
|
|
|
const mailboxChg = async (e, idx) => {
|
|
|
switch (idx) {
|
|
@@ -592,6 +592,8 @@ export default {
|
|
|
}
|
|
|
// 查询地址回显
|
|
|
kCascaderRef.value.init(accountDetail.value.areaId);
|
|
|
+ // 查询时区回显
|
|
|
+ kTimezoneRef.value.init(accountDetail.value.timeZone)
|
|
|
});
|
|
|
};
|
|
|
// 获取申泽支付平台
|
|
@@ -821,7 +823,6 @@ export default {
|
|
|
};
|
|
|
// 选择地区完成
|
|
|
const areaPopFinish = async (e) => {
|
|
|
- console.log("e", e);
|
|
|
fieldValue.value = e.selectName;
|
|
|
accountDetail.value.areaId = e.selectId;
|
|
|
const params = {
|
|
@@ -837,6 +838,37 @@ export default {
|
|
|
}, 500);
|
|
|
}
|
|
|
};
|
|
|
+ // 时区弹窗
|
|
|
+ const tzFieldValue = ref("");
|
|
|
+ const kTimezoneRef = ref(null);
|
|
|
+ // 点击时区输入框
|
|
|
+ const tzFieldValueInpClk = () => {
|
|
|
+ kTimezoneRef.value.openPopup();
|
|
|
+ };
|
|
|
+ // 选择时区完成
|
|
|
+ const timezonePopFinish = async (e) => {
|
|
|
+ tzFieldValue.value = e.selectName;
|
|
|
+ accountDetail.value.timeZone = e.selectId;
|
|
|
+ const params = {
|
|
|
+ id: user.id,
|
|
|
+ timeZone: e.selectId,
|
|
|
+ };
|
|
|
+ const { data } = await updateAdmin(params);
|
|
|
+ timezoneShow.value = true;
|
|
|
+ if (data.code === "00000") {
|
|
|
+ showToast(data.message);
|
|
|
+ setTimeout(() => {
|
|
|
+ getAcccountDetail();
|
|
|
+ }, 500);
|
|
|
+ }
|
|
|
+ };
|
|
|
+
|
|
|
+ const timezoneShowPicker = ref(false);
|
|
|
+ const timezoneOnConfirm = ({ selectedOptions }) => {
|
|
|
+ timezoneShowPicker.value = false;
|
|
|
+ tzFieldValue.value = selectedOptions[0].text;
|
|
|
+ };
|
|
|
+
|
|
|
const isInWeChat = ref(false);
|
|
|
const checkInWechat = () => {
|
|
|
const ua = window.navigator.userAgent.toLowerCase();
|
|
@@ -855,20 +887,6 @@ export default {
|
|
|
haveRelation.value = true;
|
|
|
}
|
|
|
}
|
|
|
- // const checkIsAbroad = async () => {
|
|
|
- // try {
|
|
|
- // const { data } = await getIfForeign(user.id);
|
|
|
- // console.log("isAbroad >>> ", data);
|
|
|
-
|
|
|
- // if (data.data === '1') {
|
|
|
- // // TODO: 这里先把isAbroad设置为fasle,等开发完成再改成true;
|
|
|
- // isAbroad.value = false;
|
|
|
- // isInland.value = false;
|
|
|
- // }
|
|
|
- // } catch (error) {
|
|
|
- // console.error(error);
|
|
|
- // }
|
|
|
- // };
|
|
|
const checkIsAbroad = async () => {
|
|
|
try {
|
|
|
const userInfo = localStorage.getItem("loginUser");
|
|
@@ -889,10 +907,14 @@ export default {
|
|
|
checkIsAbroad();
|
|
|
haveRelationCheck();
|
|
|
})
|
|
|
- // 获取回显的值
|
|
|
+ // 获取地区回显的值
|
|
|
const getAreaName = (e) => {
|
|
|
fieldValue.value = e;
|
|
|
};
|
|
|
+ // 获取时区回显的值
|
|
|
+ const getTimezone = (e) => {
|
|
|
+ tzFieldValue.value = e;
|
|
|
+ };
|
|
|
return {
|
|
|
user,
|
|
|
operUnipay,
|
|
@@ -911,13 +933,20 @@ export default {
|
|
|
cofficentForm,
|
|
|
params,
|
|
|
areaShow,
|
|
|
+ timezoneShow,
|
|
|
accountDetail,
|
|
|
fieldValue,
|
|
|
+ tzFieldValue,
|
|
|
kCascaderRef,
|
|
|
+ kTimezoneRef,
|
|
|
fieldValueInpClk,
|
|
|
+ tzFieldValueInpClk,
|
|
|
areaPopFinish,
|
|
|
+ timezonePopFinish,
|
|
|
+ timezoneShowPicker,
|
|
|
isInWeChat,
|
|
|
getAreaName,
|
|
|
+ getTimezone,
|
|
|
isAbroad,
|
|
|
haveRelation,
|
|
|
checkIsAbroad,
|
|
@@ -935,6 +964,7 @@ export default {
|
|
|
changeOrderNotice,
|
|
|
onOffNotice,
|
|
|
changeOnOffNotice,
|
|
|
+ timezoneOnConfirm,
|
|
|
};
|
|
|
}
|
|
|
};
|