1
This commit is contained in:
@@ -4,6 +4,7 @@ import api from '@/api'
|
||||
import type { IAlterInfo } from '@/api/info/type'
|
||||
import { getImageURL } from '@/utils/images'
|
||||
import router from '@/router'
|
||||
import { useDialog } from '@/components/hooks/dialog'
|
||||
|
||||
function job_icon(child: IAlterInfo) {
|
||||
return {
|
||||
@@ -13,7 +14,9 @@ function job_icon(child: IAlterInfo) {
|
||||
}
|
||||
|
||||
export default defineComponent(async () => {
|
||||
const ignores = ['empty']
|
||||
// const ignores = ['empty']
|
||||
|
||||
const { show, close, randomId } = useDialog()
|
||||
|
||||
// 获取角色相关信息,判定是否开放
|
||||
function choose_job(child: IAlterInfo) {
|
||||
@@ -27,7 +30,28 @@ export default defineComponent(async () => {
|
||||
if (child.open) {
|
||||
const options = child.options ?? []
|
||||
if (options.length > 0) {
|
||||
return
|
||||
const id = randomId()
|
||||
return await show({
|
||||
id,
|
||||
content: '请选择职业版本',
|
||||
action: () => {
|
||||
return (
|
||||
<div class="flex items-center justify-around flex-wrap" style="width:200px">
|
||||
{renderList(options, (option) => (
|
||||
<calc-button
|
||||
class="!w-40% !mb-2"
|
||||
onClick={() => {
|
||||
window.open('/character/' + (option.value || option.name), '_blank')
|
||||
close(id, 'ok')
|
||||
}}
|
||||
>
|
||||
{option.title}
|
||||
</calc-button>
|
||||
))}
|
||||
</div>
|
||||
)
|
||||
},
|
||||
})
|
||||
} else {
|
||||
return window.open('/character/' + (child.value || child.name), '_blank')
|
||||
}
|
||||
@@ -110,6 +134,7 @@ export default defineComponent(async () => {
|
||||
class="flex flex-col"
|
||||
style={`position: absolute;top: ${30 + 82 * 0}px;left: 800px;width: 160px;height: 150px;`}
|
||||
onClick={() => router.push({ path: '/dnfhelper' })}
|
||||
v-show={false}
|
||||
>
|
||||
<div
|
||||
class="w-70px h-50px bg-no-repeat"
|
||||
|
||||
@@ -9,11 +9,11 @@ const routes: RouteRecordRaw[] = [
|
||||
name: 'home',
|
||||
component: () => import('@/pages/Home/Index.vue'),
|
||||
},
|
||||
{
|
||||
path: '/dnfhelper',
|
||||
name: 'dnfhelper',
|
||||
component: () => import('@/pages/Dnfhelper/index.vue'),
|
||||
},
|
||||
// {
|
||||
// path: '/dnfhelper',
|
||||
// name: 'dnfhelper',
|
||||
// component: () => import('@/pages/Dnfhelper/index.vue'),
|
||||
// },
|
||||
{
|
||||
path: '/character/:alter',
|
||||
redirect: (to) => {
|
||||
|
||||
Reference in New Issue
Block a user