|
|
@@ -40,9 +40,11 @@ import { fullloading } from '@/utils/vant'
|
|
|
import { ClientType } from '@/constants/client'
|
|
|
import { useLogin } from '@/business/login'
|
|
|
import { useNavigation } from '@/hooks/navigation'
|
|
|
+import { themeStore } from '@/stores'
|
|
|
import service from '@/services'
|
|
|
import plus from '@/utils/h5plus'
|
|
|
|
|
|
+const { getClientAgent } = themeStore.actions
|
|
|
const { routerBack, routerTo } = useNavigation()
|
|
|
const { formData, userLogin } = useLogin()
|
|
|
const checked = shallowRef(false) // 是否同意协议管理
|
|
|
@@ -63,7 +65,8 @@ const navigationTo = (name: string) => {
|
|
|
const formSubmit = () => {
|
|
|
if (checked.value) {
|
|
|
fullloading((hideLoading) => {
|
|
|
- userLogin(ClientType.Android).then(() => {
|
|
|
+ const client = getClientAgent()
|
|
|
+ userLogin(client.isiPhone ? ClientType.IOS : client.isAndroid ? ClientType.Android : ClientType.PCTrade).then(() => {
|
|
|
hideLoading()
|
|
|
routerBack()
|
|
|
showSuccessToast('登录成功')
|