[色子游戏]玩家获取抽奖券记录-重构DicePlayerCoinRecord为DicePlayerTicketRecord
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
import request from '@/utils/http'
|
||||
|
||||
/**
|
||||
* 玩家购买抽奖记录 API接口
|
||||
* 抽奖券获取记录 API接口
|
||||
*/
|
||||
export default {
|
||||
/**
|
||||
@@ -11,7 +11,7 @@ export default {
|
||||
*/
|
||||
list(params: Record<string, any>) {
|
||||
return request.get<Api.Common.ApiPage>({
|
||||
url: '/dice/player_coin_record/DicePlayerCoinRecord/index',
|
||||
url: '/dice/player_ticket_record/DicePlayerTicketRecord/index',
|
||||
params
|
||||
})
|
||||
},
|
||||
@@ -23,7 +23,7 @@ export default {
|
||||
*/
|
||||
read(id: number | string) {
|
||||
return request.get<Api.Common.ApiData>({
|
||||
url: '/dice/player_coin_record/DicePlayerCoinRecord/read?id=' + id
|
||||
url: '/dice/player_ticket_record/DicePlayerTicketRecord/read?id=' + id
|
||||
})
|
||||
},
|
||||
|
||||
@@ -34,7 +34,7 @@ export default {
|
||||
*/
|
||||
save(params: Record<string, any>) {
|
||||
return request.post<any>({
|
||||
url: '/dice/player_coin_record/DicePlayerCoinRecord/save',
|
||||
url: '/dice/player_ticket_record/DicePlayerTicketRecord/save',
|
||||
data: params
|
||||
})
|
||||
},
|
||||
@@ -46,7 +46,7 @@ export default {
|
||||
*/
|
||||
update(params: Record<string, any>) {
|
||||
return request.put<any>({
|
||||
url: '/dice/player_coin_record/DicePlayerCoinRecord/update',
|
||||
url: '/dice/player_ticket_record/DicePlayerTicketRecord/update',
|
||||
data: params
|
||||
})
|
||||
},
|
||||
@@ -58,7 +58,7 @@ export default {
|
||||
*/
|
||||
delete(params: Record<string, any>) {
|
||||
return request.del<any>({
|
||||
url: '/dice/player_coin_record/DicePlayerCoinRecord/destroy',
|
||||
url: '/dice/player_ticket_record/DicePlayerTicketRecord/destroy',
|
||||
data: params
|
||||
})
|
||||
},
|
||||
@@ -68,7 +68,7 @@ export default {
|
||||
*/
|
||||
getPlayerOptions() {
|
||||
return request.get<Api.Common.ApiData>({
|
||||
url: '/dice/player_coin_record/DicePlayerCoinRecord/getPlayerOptions'
|
||||
url: '/dice/player_ticket_record/DicePlayerTicketRecord/getPlayerOptions'
|
||||
})
|
||||
}
|
||||
}
|
||||
@@ -8,14 +8,14 @@
|
||||
<ArtTableHeader v-model:columns="columnChecks" :loading="loading" @refresh="refreshData">
|
||||
<template #left>
|
||||
<ElSpace wrap>
|
||||
<ElButton v-permission="'dice:player_coin_record:index:save'" @click="showDialog('add')" v-ripple>
|
||||
<ElButton v-permission="'dice:player_ticket_record:index:save'" @click="showDialog('add')" v-ripple>
|
||||
<template #icon>
|
||||
<ArtSvgIcon icon="ri:add-fill" />
|
||||
</template>
|
||||
新增
|
||||
</ElButton>
|
||||
<ElButton
|
||||
v-permission="'dice:player_coin_record:index:destroy'"
|
||||
v-permission="'dice:player_ticket_record:index:destroy'"
|
||||
:disabled="selectedRows.length === 0"
|
||||
@click="deleteSelectedRows(api.delete, refreshData)"
|
||||
v-ripple
|
||||
@@ -46,12 +46,12 @@
|
||||
<template #operation="{ row }">
|
||||
<div class="flex gap-2">
|
||||
<SaButton
|
||||
v-permission="'dice:player_coin_record:index:update'"
|
||||
v-permission="'dice:player_ticket_record:index:update'"
|
||||
type="secondary"
|
||||
@click="showDialog('edit', row)"
|
||||
/>
|
||||
<SaButton
|
||||
v-permission="'dice:player_coin_record:index:destroy'"
|
||||
v-permission="'dice:player_ticket_record:index:destroy'"
|
||||
type="error"
|
||||
@click="deleteRow(row, api.delete, refreshData)"
|
||||
/>
|
||||
@@ -73,7 +73,7 @@
|
||||
<script setup lang="ts">
|
||||
import { useTable } from '@/hooks/core/useTable'
|
||||
import { useSaiAdmin } from '@/composables/useSaiAdmin'
|
||||
import api from '../../api/player_coin_record/index'
|
||||
import api from '../../api/player_ticket_record/index'
|
||||
import TableSearch from './modules/table-search.vue'
|
||||
import EditDialog from './modules/edit-dialog.vue'
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
<template>
|
||||
<el-dialog
|
||||
v-model="visible"
|
||||
:title="dialogType === 'add' ? '新增玩家购买抽奖记录' : '编辑玩家购买抽奖记录'"
|
||||
:title="dialogType === 'add' ? '新增抽奖券获取记录' : '编辑抽奖券获取记录'"
|
||||
width="600px"
|
||||
align-center
|
||||
:close-on-click-modal="false"
|
||||
@@ -71,7 +71,7 @@
|
||||
</template>
|
||||
|
||||
<script setup lang="ts">
|
||||
import api from '../../../api/player_coin_record/index'
|
||||
import api from '../../../api/player_ticket_record/index'
|
||||
import { ElMessage } from 'element-plus'
|
||||
import type { FormInstance, FormRules } from 'element-plus'
|
||||
|
||||
Reference in New Issue
Block a user