上传
This commit is contained in:
30
src/api/clue/extraFee.js
Normal file
30
src/api/clue/extraFee.js
Normal file
@@ -0,0 +1,30 @@
|
||||
import request from '@/config/axios'
|
||||
|
||||
// 获得列表
|
||||
export const getExtraFeePage = (params) => {
|
||||
return request.get({ url: '/admin-api/crm/extra-pay/page', params })
|
||||
}
|
||||
|
||||
// 创建
|
||||
export const createExtraFee = (data) => {
|
||||
return request.post({ url: '/admin-api/crm/extra-pay/create', data, isSubmitForm: true })
|
||||
}
|
||||
|
||||
// 更新
|
||||
export const updateExtraFee = (data) => {
|
||||
return request.put({ url: '/admin-api/crm/extra-pay/update', data })
|
||||
}
|
||||
|
||||
// 删除
|
||||
export const deleteExtraFee = (id) => {
|
||||
return request.delete({ url: `/admin-api/crm/extra-pay/delete?id=${id}` })
|
||||
}
|
||||
|
||||
// 获得
|
||||
export const getExtraFee = (id) => {
|
||||
return request.get({ url: `/admin-api/crm/extra-pay/get?id=${id}` })
|
||||
}
|
||||
|
||||
export const getExtraFeeSimpleList = async () => {
|
||||
return await request.get({ url: '/admin-api/crm/extra-pay/simple-list' })
|
||||
}
|
||||
@@ -58,3 +58,7 @@ export const getPublicClue = async (data) => {
|
||||
export const getFollowUserList = async (params) => {
|
||||
return await request.get({ url: '/admin-api/crm/sch-clue/get-follow-user', params })
|
||||
}
|
||||
|
||||
export const batchUpdateFollowUser = async (data) => {
|
||||
return await request.put({ url: '/admin-api/crm/sch-clue/batchUpdateFollowUser', data })
|
||||
}
|
||||
|
||||
@@ -1,7 +1,12 @@
|
||||
<template>
|
||||
<div>
|
||||
<div class="flex">
|
||||
<el-table :data="tableObject.tableList" border style="flex: 1">
|
||||
<el-table
|
||||
:data="tableObject.tableList"
|
||||
border
|
||||
style="flex: 1"
|
||||
@selection-change="handleSelectionChange"
|
||||
>
|
||||
<slot></slot>
|
||||
</el-table>
|
||||
<el-button
|
||||
@@ -56,7 +61,7 @@ const props = defineProps({
|
||||
tableColumns: { type: Array, default: () => [] }
|
||||
})
|
||||
|
||||
const emit = defineEmits(['update:tableObject', 'getList', 'getCheckedColumns'])
|
||||
const emit = defineEmits(['update:tableObject', 'getList', 'getCheckedColumns', 'selection-change'])
|
||||
const route = useRoute()
|
||||
|
||||
const pageNo = ref(props.tableObject?.pageNo || 1)
|
||||
@@ -110,6 +115,10 @@ function onDragEnd() {
|
||||
emitColumns()
|
||||
}
|
||||
|
||||
function handleSelectionChange(val) {
|
||||
emit('selection-change', val)
|
||||
}
|
||||
|
||||
// 勾选确认
|
||||
function confirm() {
|
||||
ClueCacheApi.setClueCache({
|
||||
|
||||
@@ -4,16 +4,16 @@
|
||||
<el-tab-pane label="线索管理" :name="0" v-if="checkPermi(['basic:setting:clue'])">
|
||||
<BSClue v-if="tabIndex == 0" />
|
||||
</el-tab-pane>
|
||||
<el-tab-pane label="销售提成" :name="10" v-if="checkPermi(['basic:setting:comission'])">
|
||||
<!-- <el-tab-pane label="销售提成" :name="10" v-if="checkPermi(['basic:setting:comission'])">
|
||||
<BSSalerComission v-if="tabIndex == 10" />
|
||||
</el-tab-pane>
|
||||
</el-tab-pane> -->
|
||||
</el-tabs>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script setup name="GeneralSetting">
|
||||
import BSClue from './Comp/BSClue.vue'
|
||||
import BSSalerComission from './Comp/BSSalerComission.vue'
|
||||
// import BSSalerComission from './Comp/BSSalerComission.vue'
|
||||
import { checkPermi } from '@/utils/permission'
|
||||
|
||||
const tabIndex = ref(0)
|
||||
|
||||
@@ -28,9 +28,9 @@
|
||||
>
|
||||
<el-option
|
||||
v-for="item in extraPayOptions"
|
||||
:key="item.value"
|
||||
:label="item.label"
|
||||
:value="item.value"
|
||||
:key="item.id"
|
||||
:label="item.extraPayName"
|
||||
:value="item.id"
|
||||
/>
|
||||
</el-select>
|
||||
</template>
|
||||
@@ -73,9 +73,9 @@
|
||||
|
||||
<script setup name="DialogExtraPay">
|
||||
import { signAddPay, getSignExtraPayList } from '@/api/clue/sign'
|
||||
import { getDictOptions } from '@/utils/dict'
|
||||
import * as ExtraFeeApi from '@/api/clue/extraFee'
|
||||
|
||||
const extraPayOptions = getDictOptions('extra_pay_type')
|
||||
const extraPayOptions = ref([])
|
||||
const message = useMessage() // 消息弹窗
|
||||
|
||||
const show = ref(false)
|
||||
@@ -83,6 +83,7 @@ function open(id) {
|
||||
show.value = true
|
||||
resetForm(id)
|
||||
getFormList()
|
||||
getOptions()
|
||||
}
|
||||
defineExpose({
|
||||
open
|
||||
@@ -135,6 +136,12 @@ async function onSubmit() {
|
||||
function handleRemove(type, index) {
|
||||
form.value[type].splice(index, 1)
|
||||
}
|
||||
|
||||
function getOptions() {
|
||||
ExtraFeeApi.getExtraFeeSimpleList().then((data) => {
|
||||
extraPayOptions.value = data
|
||||
})
|
||||
}
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped></style>
|
||||
|
||||
@@ -39,6 +39,7 @@
|
||||
|
||||
<script setup name="ClueMap">
|
||||
import { getPlaceList } from '@/api/school/place'
|
||||
import { getConfigByConfigKey } from '@/api/system/set'
|
||||
|
||||
import ImgPostion from '@/assets/imgs/flag/position_black.png'
|
||||
import FlagRed from '@/assets/imgs/flag/flag_red.png'
|
||||
@@ -69,9 +70,17 @@ const defaultLatLng = ref({
|
||||
lat: 31.86119,
|
||||
lng: 117.283042
|
||||
})
|
||||
const defaultCity = ref('合肥')
|
||||
|
||||
let AutoComplete = ref(null)
|
||||
function initMap() {
|
||||
async function initMap() {
|
||||
const data = await getConfigByConfigKey({ configKey: 'defaultLocation' })
|
||||
const cityInfo = JSON.parse(data.configValue)
|
||||
defaultLatLng.value = {
|
||||
lat: cityInfo.lat,
|
||||
lng: cityInfo.lng
|
||||
}
|
||||
defaultCity.value = cityInfo.locationName
|
||||
AMapLoader.load({
|
||||
key: '713d839ff505943b0f18e6df45f3b0dc', //设置您的key
|
||||
version: '2.0',
|
||||
@@ -79,7 +88,7 @@ function initMap() {
|
||||
}).then((AMap) => {
|
||||
aMap.value = AMap
|
||||
AutoComplete.value = new AMap.AutoComplete({
|
||||
city: '合肥'
|
||||
city: defaultCity.value
|
||||
})
|
||||
clueMap.value = new AMap.Map('mapClue', {
|
||||
zoom: 14,
|
||||
|
||||
97
src/views/Clue/Pool/Comp/DialogBatchChangeFollow.vue
Normal file
97
src/views/Clue/Pool/Comp/DialogBatchChangeFollow.vue
Normal file
@@ -0,0 +1,97 @@
|
||||
<template>
|
||||
<Dialog title="批量修改跟进人" v-model="show" width="400px">
|
||||
<el-form :model="form" ref="formRef" :rules="rules" label-width="auto">
|
||||
<el-form-item label="修改线索数">
|
||||
{{ form.clueIdList.length }}
|
||||
</el-form-item>
|
||||
<el-form-item label="原跟进人" prop="originFollowUserId">
|
||||
<el-select v-model="form.originFollowUserId" placeholder="原跟进人" filterable>
|
||||
<el-option
|
||||
v-for="item in props.userOptions"
|
||||
:key="item.id"
|
||||
:label="item.nickname"
|
||||
:value="item.id"
|
||||
/>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
<el-form-item label="新跟进人" prop="newFollowUserId">
|
||||
<el-select v-model="form.newFollowUserId" placeholder="新跟进人" filterable>
|
||||
<el-option
|
||||
v-for="item in props.userOptions"
|
||||
:key="item.id"
|
||||
:label="item.nickname"
|
||||
:value="item.id"
|
||||
/>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
<template #footer>
|
||||
<span>
|
||||
<el-button @click="show = false">取 消</el-button>
|
||||
<el-button :disabled="formLoading" type="primary" @click="handleSave">保 存</el-button>
|
||||
</span>
|
||||
</template>
|
||||
</Dialog>
|
||||
</template>
|
||||
|
||||
<script setup name="DialogBatchChangeFollow">
|
||||
import { batchUpdateFollowUser } from '@/api/clue'
|
||||
|
||||
const props = defineProps({
|
||||
userOptions: {
|
||||
type: Array
|
||||
}
|
||||
})
|
||||
|
||||
const show = ref(false)
|
||||
const form = ref({
|
||||
clueIdList: [],
|
||||
originFollowUserId: undefined,
|
||||
newFollowUserId: undefined
|
||||
})
|
||||
|
||||
const rules = ref({
|
||||
originFollowUserId: { required: true, message: '原跟进人不可为空', trigger: 'change' },
|
||||
newFollowUserId: { required: true, message: '新跟进人不可为空', trigger: 'change' }
|
||||
})
|
||||
|
||||
function open(clueIdList) {
|
||||
resetForm(clueIdList)
|
||||
show.value = true
|
||||
}
|
||||
defineExpose({ open }) // 提供 open 方法,用于打开弹窗
|
||||
|
||||
function resetForm(clueIdList) {
|
||||
form.value = {
|
||||
clueIdList,
|
||||
originFollowUserId: undefined,
|
||||
newFollowUserId: undefined
|
||||
}
|
||||
}
|
||||
|
||||
const formLoading = ref(false)
|
||||
const emit = defineEmits(['success'])
|
||||
const formRef = ref()
|
||||
async function handleSave() {
|
||||
// 校验表单
|
||||
if (!formRef.value) return
|
||||
const valid = await formRef.value.validate()
|
||||
if (!valid) return
|
||||
|
||||
// 提交请求
|
||||
formLoading.value = true
|
||||
try {
|
||||
await batchUpdateFollowUser(form.value)
|
||||
message.success('修改成功!')
|
||||
show.value = false
|
||||
// 发送操作成功的事件
|
||||
emit('success')
|
||||
} catch (err) {
|
||||
console.log(err)
|
||||
} finally {
|
||||
formLoading.value = false
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
<style lang="scss" scoped></style>
|
||||
@@ -133,6 +133,7 @@
|
||||
import { useAppStore } from '@/store/modules/app'
|
||||
import { useUserStore } from '@/store/modules/user'
|
||||
import { getPlaceList } from '@/api/school/place'
|
||||
import { getConfigByConfigKey } from '@/api/system/set'
|
||||
import * as ClueApi from '@/api/clue'
|
||||
import { getDiyFieldList } from '@/api/clue/clueField'
|
||||
import { formatDate } from '@/utils/formatTime'
|
||||
@@ -226,6 +227,7 @@ const defaultLatLng = ref({
|
||||
lat: 31.86119,
|
||||
lng: 117.283042
|
||||
})
|
||||
const defaultCity = ref('合肥')
|
||||
const info = ref({})
|
||||
|
||||
const diyFieldArr = ref([])
|
||||
@@ -265,9 +267,14 @@ const open = async (type, id) => {
|
||||
}
|
||||
]
|
||||
address.value = ''
|
||||
defaultLatLng.value = {
|
||||
lat: 31.86119,
|
||||
lng: 117.283042
|
||||
if (appStore.getAppInfo?.instanceType == 1) {
|
||||
const data = await getConfigByConfigKey({ configKey: 'defaultLocation' })
|
||||
const cityInfo = JSON.parse(data.configValue)
|
||||
defaultLatLng.value = {
|
||||
lat: cityInfo.lat,
|
||||
lng: cityInfo.lng
|
||||
}
|
||||
defaultCity.value = cityInfo.locationName
|
||||
}
|
||||
nextTick(() => {
|
||||
formRef.value.setValues(info.value, true)
|
||||
@@ -396,7 +403,7 @@ function initMap(data) {
|
||||
})
|
||||
addmark(defaultLatLng.value.lng, defaultLatLng.value.lat, AMap)
|
||||
AutoComplete.value = new AMap.AutoComplete({
|
||||
city: '合肥'
|
||||
city: defaultCity.value
|
||||
})
|
||||
geoCoder.value = new AMap.Geocoder()
|
||||
dialogMap.value.on('click', (e) => {
|
||||
|
||||
@@ -328,6 +328,7 @@ import { getDiyFieldList } from '@/api/clue/orderField'
|
||||
import { getPlaceList } from '@/api/school/place'
|
||||
import { getClassTypeList } from '@/api/school/class'
|
||||
import { getSimpleProductList } from '@/api/mall/product'
|
||||
import { getConfigByConfigKey } from '@/api/system/set'
|
||||
|
||||
// import { getSimpleWarehouseList } from '@/api/mall/warehouse'
|
||||
import { formatDate } from '@/utils/formatTime'
|
||||
@@ -415,7 +416,8 @@ async function open(id) {
|
||||
}
|
||||
defineExpose({ open }) // 提供 open 方法,用于打开弹窗
|
||||
|
||||
function resetForm(id) {
|
||||
async function resetForm(id) {
|
||||
const data = await getConfigByConfigKey({ configKey: 'companyCollectionConfig' })
|
||||
form.value = {
|
||||
clueId: id,
|
||||
dealDate: formatDate(new Date()),
|
||||
@@ -423,7 +425,7 @@ function resetForm(id) {
|
||||
signPrice: 0,
|
||||
payAmount: 0,
|
||||
remark: undefined,
|
||||
isCompanyReceipts: appStore.getAppInfo?.instanceType == 2,
|
||||
isCompanyReceipts: data.configValue == 'true',
|
||||
receiver: undefined,
|
||||
extraPay: [],
|
||||
signProducts: []
|
||||
|
||||
@@ -53,6 +53,12 @@
|
||||
<template #actionMore>
|
||||
<el-button @click="getTableList" v-hasPermi="['clue:pool:search']"> 搜索 </el-button>
|
||||
<el-button @click="resetQuery" v-hasPermi="['clue:pool:reset']"> 重置 </el-button>
|
||||
<el-button
|
||||
@click="handleBatchChangeFollow"
|
||||
v-hasPermi="['clue:pool:batch-update-follow']"
|
||||
>
|
||||
批量修改跟进人
|
||||
</el-button>
|
||||
</template>
|
||||
</Search>
|
||||
<!-- 列表 -->
|
||||
@@ -63,7 +69,9 @@
|
||||
:tableColumns="allSchemas.tableColumns"
|
||||
@get-list="getTableList"
|
||||
@get-checked-columns="getCheckedColumns"
|
||||
@selection-change="handleSelectionChange"
|
||||
>
|
||||
<el-table-column type="selection" width="60" />
|
||||
<el-table-column
|
||||
v-for="item in showColumns"
|
||||
:key="item.field"
|
||||
@@ -178,6 +186,11 @@
|
||||
@success="getTableList"
|
||||
/>
|
||||
<DialogFollow ref="followRef" @success="getTableList" />
|
||||
<DialogBatchChangeFollow
|
||||
ref="batchChangeFollowDialog"
|
||||
:userOptions="userOptions"
|
||||
@success="getTableList"
|
||||
/>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
@@ -189,6 +202,7 @@ import DrawerClue from './Comp/DrawerClue.vue'
|
||||
import DialogSuccess from './Comp/DialogSuccess.vue'
|
||||
import DialogFollow from './Comp/DialogFollow.vue'
|
||||
import ClueMap from './Comp/ClueMap.vue'
|
||||
import DialogBatchChangeFollow from './Comp/DialogBatchChangeFollow.vue'
|
||||
import { getSimpleUserList as getUserOption, getAllUserList } from '@/api/system/user'
|
||||
|
||||
import { removeNullField } from '@/utils'
|
||||
@@ -216,7 +230,7 @@ async function getCurdSchemas() {
|
||||
try {
|
||||
const data = await getSimpleFieldList()
|
||||
data.forEach((elem) => {
|
||||
if (elem.field == 'followUser' || elem.field == 'convertPeople') {
|
||||
if (['followUser', 'convertPeople', 'firstFollowUser'].includes(elem.field)) {
|
||||
elem.search.options = userOptions.value
|
||||
}
|
||||
})
|
||||
@@ -295,6 +309,20 @@ function getSearchCount() {
|
||||
})
|
||||
}
|
||||
|
||||
const batchIds = ref([])
|
||||
function handleSelectionChange(val) {
|
||||
batchIds.value = val.map((it) => it.clueId)
|
||||
}
|
||||
|
||||
const batchChangeFollowDialog = ref()
|
||||
function handleBatchChangeFollow() {
|
||||
if (batchIds.value.length) {
|
||||
batchChangeFollowDialog.value.open(batchIds.value)
|
||||
} else {
|
||||
message.info('请选择表格中的数据!')
|
||||
}
|
||||
}
|
||||
|
||||
// 新增
|
||||
function handleInsert() {
|
||||
formRef.value.open('create', null)
|
||||
|
||||
@@ -5,10 +5,16 @@
|
||||
v-loading="formLoading"
|
||||
:model="formData"
|
||||
:rules="formRules"
|
||||
label-width="80px"
|
||||
label-width="auto"
|
||||
>
|
||||
<el-form-item label="支出项" prop="label">
|
||||
<el-input v-model="formData.label" placeholder="请输入支出项" />
|
||||
<el-form-item label="支出项" prop="extraPayName">
|
||||
<el-input v-model="formData.extraPayName" placeholder="请输入支出项" />
|
||||
</el-form-item>
|
||||
<el-form-item label="是否扣除提成" prop="isPercentage">
|
||||
<el-radio-group v-model="formData.isPercentage">
|
||||
<el-radio :label="true">是</el-radio>
|
||||
<el-radio :label="false">否</el-radio>
|
||||
</el-radio-group>
|
||||
</el-form-item>
|
||||
<el-form-item label="排序" prop="sort">
|
||||
<el-input v-model="formData.sort" placeholder="请输入排序" type="number" :min="0" />
|
||||
@@ -29,7 +35,8 @@
|
||||
</Dialog>
|
||||
</template>
|
||||
<script name="DialogExtraFee" setup>
|
||||
import * as dictApi from '@/api/system/dict/dict.data'
|
||||
import * as ExtraFeeApi from '@/api/clue/extraFee'
|
||||
|
||||
const { t } = useI18n() // 国际化
|
||||
const message = useMessage() // 消息弹窗
|
||||
|
||||
@@ -38,12 +45,13 @@ const dialogTitle = ref('') // 弹窗的标题
|
||||
const formLoading = ref(false) // 表单的加载中:1)修改时的数据加载;2)提交的按钮禁用
|
||||
const formType = ref('') // 表单的类型:create - 新增;update - 修改
|
||||
const formData = ref({
|
||||
label: '',
|
||||
extraPayName: '',
|
||||
isPercentage: false,
|
||||
sort: 1,
|
||||
remark: ''
|
||||
})
|
||||
const formRules = reactive({
|
||||
label: [{ required: true, message: '支出项不能为空', trigger: 'blur' }]
|
||||
extraPayName: [{ required: true, message: '支出项不能为空', trigger: 'blur' }]
|
||||
})
|
||||
const formRef = ref() // 表单 Ref
|
||||
|
||||
@@ -57,7 +65,7 @@ const open = async (type, id) => {
|
||||
if (id) {
|
||||
formLoading.value = true
|
||||
try {
|
||||
formData.value = await dictApi.getDictData(id)
|
||||
formData.value = await ExtraFeeApi.getExtraFee(id)
|
||||
} finally {
|
||||
formLoading.value = false
|
||||
}
|
||||
@@ -75,14 +83,11 @@ const submitForm = async () => {
|
||||
// 提交请求
|
||||
formLoading.value = true
|
||||
try {
|
||||
if (!formData.value.value) {
|
||||
formData.value.value = formData.value.label
|
||||
}
|
||||
if (formType.value === 'create') {
|
||||
await dictApi.createDictData(formData.value)
|
||||
await ExtraFeeApi.createExtraFee(formData.value)
|
||||
message.success(t('common.createSuccess'))
|
||||
} else {
|
||||
await dictApi.updateDictData(formData.value)
|
||||
await ExtraFeeApi.updateExtraFee(formData.value)
|
||||
message.success(t('common.updateSuccess'))
|
||||
}
|
||||
dialogVisible.value = false
|
||||
@@ -96,10 +101,10 @@ const submitForm = async () => {
|
||||
/** 重置表单 */
|
||||
const resetForm = () => {
|
||||
formData.value = {
|
||||
label: '',
|
||||
extraPayName: '',
|
||||
isPercentage: false,
|
||||
sort: 1,
|
||||
status: 0,
|
||||
dictType: 'extra_pay_type',
|
||||
remark: ''
|
||||
}
|
||||
formRef.value?.resetFields()
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
<el-form ref="queryForm" :model="searchForm" label-width="0" inline>
|
||||
<el-form-item>
|
||||
<el-input
|
||||
v-model="searchForm.name"
|
||||
v-model="searchForm.extraPayName"
|
||||
placeholder="请输入名称"
|
||||
clearable
|
||||
@keyup.enter="handleQuery"
|
||||
@@ -16,7 +16,12 @@
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
<el-table v-loading="loading" :data="tableList">
|
||||
<el-table-column prop="label" label="支出项" />
|
||||
<el-table-column prop="extraPayName" label="支出项" />
|
||||
<el-table-column prop="isPercentage" label="是否扣除提成">
|
||||
<template #default="{ row }">
|
||||
{{ row.isPercentage ? '是' : '否' }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="sort" label="排序" width="100px" />
|
||||
<el-table-column prop="remark" label="备注" />
|
||||
<el-table-column
|
||||
@@ -27,22 +32,10 @@
|
||||
/>
|
||||
<el-table-column label="操作">
|
||||
<template #default="scope">
|
||||
<el-button
|
||||
type="primary"
|
||||
:disabled="!scope.row.editable"
|
||||
text
|
||||
@click="openForm('update', scope.row.id)"
|
||||
>
|
||||
<el-button type="primary" text @click="openForm('update', scope.row.id)">
|
||||
修改
|
||||
</el-button>
|
||||
<el-button
|
||||
type="danger"
|
||||
:disabled="!scope.row.editable"
|
||||
text
|
||||
@click="handleDelete(scope.row.id)"
|
||||
>
|
||||
删除
|
||||
</el-button>
|
||||
<el-button type="danger" text @click="handleDelete(scope.row.id)"> 删除 </el-button>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
@@ -60,16 +53,16 @@
|
||||
<script setup name="ExtraFeeType">
|
||||
import { dateFormatter } from '@/utils/formatTime'
|
||||
import DialogExtraFee from './DialogExtraFee.vue'
|
||||
import * as dictApi from '@/api/system/dict/dict.data'
|
||||
import * as ExtraFeeApi from '@/api/clue/extraFee'
|
||||
import { removeNullField } from '@/utils'
|
||||
|
||||
const { t } = useI18n() // 国际化
|
||||
const message = useMessage() // 消息弹窗
|
||||
|
||||
const searchForm = ref({
|
||||
label: '',
|
||||
extraPayName: '',
|
||||
pageSize: 20,
|
||||
pageNo: 1,
|
||||
dictType: 'extra_pay_type'
|
||||
pageNo: 1
|
||||
})
|
||||
|
||||
const total = ref(0)
|
||||
@@ -83,10 +76,9 @@ function handleQuery() {
|
||||
}
|
||||
function resetQuery() {
|
||||
searchForm.value = {
|
||||
label: '',
|
||||
extraPayName: '',
|
||||
pageSize: 20,
|
||||
pageNo: 1,
|
||||
dictType: 'extra_pay_type'
|
||||
pageNo: 1
|
||||
}
|
||||
getList()
|
||||
}
|
||||
@@ -94,7 +86,7 @@ function resetQuery() {
|
||||
async function getList() {
|
||||
loading.value = true
|
||||
try {
|
||||
const data = await dictApi.getDictDataPage(searchForm.value)
|
||||
const data = await ExtraFeeApi.getExtraFeePage(removeNullField(searchForm.value))
|
||||
tableList.value = data.list
|
||||
total.value = data.total
|
||||
} finally {
|
||||
@@ -111,7 +103,7 @@ async function handleDelete(id) {
|
||||
// 删除的二次确认
|
||||
await message.delConfirm()
|
||||
// 发起删除
|
||||
await dictApi.deleteDictData(id)
|
||||
await ExtraFeeApi.deleteExtraFee(id)
|
||||
message.success(t('common.delSuccess'))
|
||||
// 刷新列表
|
||||
await getList()
|
||||
|
||||
@@ -61,6 +61,7 @@
|
||||
<script setup name="ClueSkill">
|
||||
import * as SkillApi from '@/api/clue/skill'
|
||||
import DialogSkill from './Comp/DialogSkill.vue'
|
||||
import { removeNullField } from '@/utils'
|
||||
|
||||
const skillDialog = ref()
|
||||
|
||||
@@ -95,7 +96,7 @@ function handleQuery() {
|
||||
async function getList() {
|
||||
loading.value = true
|
||||
try {
|
||||
const data = await SkillApi.getSkillPage(searchForm.value)
|
||||
const data = await SkillApi.getSkillPage(removeNullField(searchForm.value))
|
||||
tableList.value = data.list
|
||||
total.value = data.total
|
||||
} finally {
|
||||
@@ -108,7 +109,7 @@ function handleAdd() {
|
||||
}
|
||||
|
||||
function handleUpdate(row) {
|
||||
skillDialog.value.open('update', row.id)
|
||||
skillDialog.value.open('update', row.skillId)
|
||||
}
|
||||
|
||||
async function handleDelete(row) {
|
||||
|
||||
Reference in New Issue
Block a user