更新开发环境配置文件,切换API基础URL。
This commit is contained in:
parent
6cc78efbd0
commit
8e571a57e5
|
@ -2,5 +2,5 @@ NODE_ENV = 'development'
|
|||
VITE_NOW_TYPE = 'dist'
|
||||
|
||||
# Base API
|
||||
VITE_APP_BASE_URL='http://192.168.1.22:8545'
|
||||
# VITE_APP_BASE_URL='https://test-multi-store.lihaink.cn'
|
||||
# VITE_APP_BASE_URL='http://192.168.1.22:8545'
|
||||
VITE_APP_BASE_URL='https://test-multi-store.lihaink.cn'
|
||||
|
|
|
@ -0,0 +1,8 @@
|
|||
{
|
||||
"path": {
|
||||
"root": "@=src",
|
||||
"api": "src/api",
|
||||
"request": "../utils/request"
|
||||
},
|
||||
"api": []
|
||||
}
|
|
@ -0,0 +1,26 @@
|
|||
import request from '@/utils/request'
|
||||
|
||||
// 财务转账表列表
|
||||
export function apiFinancialTransfersLists(params: any) {
|
||||
return request.get({ url: '/financial_transfers/financialtransfers/lists', params })
|
||||
}
|
||||
|
||||
// 添加财务转账表
|
||||
export function apiFinancialTransfersAdd(params: any) {
|
||||
return request.post({ url: '/financial_transfers/financialtransfers/add', params })
|
||||
}
|
||||
|
||||
// 编辑财务转账表
|
||||
export function apiFinancialTransfersEdit(params: any) {
|
||||
return request.post({ url: '/financial_transfers/financialtransfers/edit', params })
|
||||
}
|
||||
|
||||
// 删除财务转账表
|
||||
export function apiFinancialTransfersDelete(params: any) {
|
||||
return request.post({ url: '/financial_transfers/financialtransfers/delete', params })
|
||||
}
|
||||
|
||||
// 财务转账表详情
|
||||
export function apiFinancialTransfersDetail(params: any) {
|
||||
return request.get({ url: '/financial_transfers/financialtransfers/detail', params })
|
||||
}
|
|
@ -0,0 +1,92 @@
|
|||
<template>
|
||||
<div>
|
||||
<el-card class="!border-none mb-4" shadow="never">
|
||||
<el-form class="mb-[-16px]" :model="queryParams" inline>
|
||||
<el-form-item label="金额" prop="money">
|
||||
<el-input class="w-[280px]" v-model="queryParams.money" clearable placeholder="请输入金额" />
|
||||
</el-form-item>
|
||||
<el-form-item>
|
||||
<el-button type="primary" @click="resetPage">查询</el-button>
|
||||
<el-button @click="resetParams">重置</el-button>
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
</el-card>
|
||||
<el-card class="!border-none" v-loading="pager.loading" shadow="never">
|
||||
<div class="mt-4">
|
||||
<el-table :data="pager.lists" @selection-change="handleSelectionChange">
|
||||
<el-table-column label="id" prop="store_id" show-overflow-tooltip />
|
||||
<el-table-column label="时间" prop="create_time" show-overflow-tooltip />
|
||||
<el-table-column label="收款方" prop="store_name" show-overflow-tooltip />
|
||||
<el-table-column label="结算金额" prop="money" show-overflow-tooltip />
|
||||
<el-table-column label="结算方式" prop="extract_type" show-overflow-tooltip />
|
||||
<el-table-column label="确认时间" prop="initiation_time" show-overflow-tooltip />
|
||||
<el-table-column label="操作" width="120" fixed="right">
|
||||
<template #default="{ row }">
|
||||
<el-button link type="primary" @click="handleDelete(row.id)">
|
||||
起飞
|
||||
</el-button>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
</div>
|
||||
<div class="flex mt-4 justify-end">
|
||||
<pagination v-model="pager" @change="getLists" />
|
||||
</div>
|
||||
</el-card>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script lang="ts" setup name="financialTransfersLists">
|
||||
import { usePaging } from '@/hooks/usePaging'
|
||||
import { useDictData } from '@/hooks/useDictOptions'
|
||||
import { apiFinancialTransfersLists } from '@/api/financial_transfers'
|
||||
import { timeFormat } from '@/utils/util'
|
||||
import feedback from '@/utils/feedback'
|
||||
|
||||
|
||||
const editRef = shallowRef<InstanceType<typeof EditPopup>>()
|
||||
// 是否显示编辑框
|
||||
const showEdit = ref(false)
|
||||
|
||||
|
||||
// 查询条件
|
||||
const queryParams = reactive({
|
||||
store_id: '',
|
||||
admin_id: '',
|
||||
uid: '',
|
||||
status: '',
|
||||
initiation_time: '',
|
||||
confirmation_time: '',
|
||||
mark: '',
|
||||
money: '',
|
||||
remark_time: ''
|
||||
})
|
||||
|
||||
// 选中数据
|
||||
const selectData = ref<any[]>([])
|
||||
|
||||
// 表格选择后回调事件
|
||||
const handleSelectionChange = (val: any[]) => {
|
||||
selectData.value = val.map(({ id }) => id)
|
||||
}
|
||||
|
||||
// 获取字典数据
|
||||
const { dictData } = useDictData('')
|
||||
|
||||
// 分页相关
|
||||
const { pager, getLists, resetParams, resetPage } = usePaging({
|
||||
fetchFun: apiFinancialTransfersLists,
|
||||
params: queryParams
|
||||
})
|
||||
|
||||
|
||||
// 删除
|
||||
const handleDelete = async (id: number | any[]) => {
|
||||
await feedback.confirm('确定要起飞吗?')
|
||||
// await apiFinancialTransfersDelete({ id })
|
||||
getLists()
|
||||
}
|
||||
|
||||
getLists()
|
||||
</script>
|
||||
|
Loading…
Reference in New Issue