优化玩家DicePlayer权重输入方式

This commit is contained in:
2026-03-07 11:51:34 +08:00
parent 4b6bbab9d1
commit 282d73a203
6 changed files with 241 additions and 35 deletions

View File

@@ -64,7 +64,7 @@
</template>
<script setup lang="ts">
import lotteryConfigApi from '../../../api/lottery_config/index'
import api from '../../../api/player/index'
interface Props {
modelValue: Record<string, any>
@@ -79,10 +79,10 @@
const isExpanded = ref<boolean>(false)
const lotteryConfigOptions = ref<Array<{ id: number; name: string }>>([])
/** 从 DiceLotteryConfig 拉取彩金池配置下拉选项,用于 lottery_config_id 筛选 */
/** 从玩家控制器获取 DiceLotteryConfig id/name 列表,用于 lottery_config_id 筛选 */
onMounted(async () => {
try {
lotteryConfigOptions.value = await lotteryConfigApi.getOptions()
lotteryConfigOptions.value = await api.getLotteryConfigOptions()
} catch {
lotteryConfigOptions.value = []
}