修复BUG:
1.消息中心不加载目标数据问题; 2.地区数据加载问题
This commit is contained in:
@@ -60,12 +60,9 @@ class AreaViewSet(CustomModelViewSet):
|
||||
del params['page']
|
||||
if limit:
|
||||
del params['limit']
|
||||
if params:
|
||||
if pcode:
|
||||
if params and pcode:
|
||||
queryset = self.queryset.filter(enable=True, pcode=pcode)
|
||||
else:
|
||||
queryset = self.queryset.filter(enable=True)
|
||||
else:
|
||||
queryset = self.queryset.filter(enable=True, pcode__isnull=True)
|
||||
return queryset
|
||||
|
||||
|
||||
@@ -43,7 +43,7 @@
|
||||
import {defineProps, onMounted, reactive, ref, toRaw, watch} from 'vue'
|
||||
import {dict} from '@fast-crud/fast-crud'
|
||||
import XEUtils from 'xe-utils'
|
||||
|
||||
import {request} from '/@/utils/service'
|
||||
const props = defineProps({
|
||||
modelValue: {},
|
||||
tableConfig: {
|
||||
@@ -71,6 +71,7 @@ watch(multipleSelection, // 监听multipleSelection的变化,
|
||||
if (!tableConfig.isMultiple) {
|
||||
data.value = value ? value[tableConfig.label] : null
|
||||
} else {
|
||||
|
||||
const result = value ? value.map((item: any) => {
|
||||
return item[tableConfig.label]
|
||||
}) : null
|
||||
@@ -125,10 +126,10 @@ const getDict = async () => {
|
||||
limit: pageConfig.limit,
|
||||
search: search.value
|
||||
}
|
||||
const dicts = dict({url: url, params: params})
|
||||
await dicts.reloadDict()
|
||||
const dictData: any = dicts.data
|
||||
const {data, page, limit, total} = dictData
|
||||
const {data, page, limit, total} = await request({
|
||||
url:url,
|
||||
params:params
|
||||
})
|
||||
pageConfig.page = page
|
||||
pageConfig.limit = limit
|
||||
pageConfig.total = total
|
||||
|
||||
@@ -4,13 +4,18 @@ import tableSelector from '/@/components/tableSelector/index.vue';
|
||||
import {shallowRef, computed, ref, inject} from 'vue';
|
||||
import manyToMany from '/@/components/manyToMany/index.vue';
|
||||
import {auth} from '/@/utils/authFunction'
|
||||
import {createCrudOptions as userCrudOptions } from "/@/views/system/user/crud";
|
||||
import {request} from '/@/utils/service'
|
||||
const {compute} = useCompute();
|
||||
|
||||
interface CreateCrudOptionsTypes {
|
||||
crudOptions: CrudOptions;
|
||||
}
|
||||
|
||||
export const createCrudOptions = function ({ crudExpose, tabActivted }: { crudExpose: CrudExpose; tabActivted: any }): CreateCrudOptionsTypes {
|
||||
export const createCrudOptions = function ({
|
||||
crudExpose,
|
||||
tabActivted
|
||||
}: { crudExpose: CrudExpose; tabActivted: any }): CreateCrudOptionsTypes {
|
||||
const pageRequest = async (query: PageQuery) => {
|
||||
if (tabActivted.value === 'receive') {
|
||||
return await api.GetSelfReceive(query);
|
||||
@@ -292,6 +297,7 @@ export const createCrudOptions = function ({ crudExpose, tabActivted }: { crudEx
|
||||
{
|
||||
prop: 'name',
|
||||
label: '部门名称',
|
||||
width: 150,
|
||||
},
|
||||
{
|
||||
prop: 'status_label',
|
||||
|
||||
@@ -372,6 +372,9 @@ export const createCrudOptions = function ({crudExpose}: CreateCrudOptionsProps)
|
||||
form: {
|
||||
show: false,
|
||||
},
|
||||
column: {
|
||||
minWidth: 400, //最小列宽
|
||||
},
|
||||
},
|
||||
...commonCrudConfig({
|
||||
dept_belong_id: {
|
||||
|
||||
Reference in New Issue
Block a user