销售类型同比表页面修改
This commit is contained in:
@@ -12,7 +12,7 @@
|
|||||||
>
|
>
|
||||||
<!-- 顶部统计 -->
|
<!-- 顶部统计 -->
|
||||||
<div
|
<div
|
||||||
v-if="summaryTop.show"
|
v-if="summaryTop.show&&tableId!=='2049373858120613889'"
|
||||||
class="low-table-summary absolute left-0 top-0 w-100% h-auto z-999"
|
class="low-table-summary absolute left-0 top-0 w-100% h-auto z-999"
|
||||||
v-hasResize="onSummaryTopResize"
|
v-hasResize="onSummaryTopResize"
|
||||||
>
|
>
|
||||||
@@ -28,7 +28,7 @@
|
|||||||
show_fixed_bar: isShowFixedBar,
|
show_fixed_bar: isShowFixedBar,
|
||||||
[`low-table-grid__${tableInfo.singleCardSpan}`]: tableOption.grid
|
[`low-table-grid__${tableInfo.singleCardSpan}`]: tableOption.grid
|
||||||
}"
|
}"
|
||||||
:style="{ paddingTop: summaryTop.height + 'px' }"
|
:style="{ paddingTop: tableId!=='2049373858120613889'?summaryTop.height:'0' + 'px' }"
|
||||||
>
|
>
|
||||||
<!-- 左树右表(树表) -->
|
<!-- 左树右表(树表) -->
|
||||||
<div
|
<div
|
||||||
@@ -109,6 +109,19 @@
|
|||||||
@menu-left-handle="menuLeftHandle"
|
@menu-left-handle="menuLeftHandle"
|
||||||
></TableButton>
|
></TableButton>
|
||||||
</template>
|
</template>
|
||||||
|
<template v-if="summaryTop.show&&tableId=='2049373858120613889'" #header>
|
||||||
|
|
||||||
|
<div
|
||||||
|
class="low-table-summary w-100% h-auto z-999"
|
||||||
|
v-hasResize="onSummaryTopResize"
|
||||||
|
>
|
||||||
|
<SummaryTop
|
||||||
|
ref="summaryTopRef"
|
||||||
|
v-if="tableSummary.topList?.length"
|
||||||
|
:summaryList="tableSummary.topList"
|
||||||
|
></SummaryTop>
|
||||||
|
</div>
|
||||||
|
</template>
|
||||||
<!-- 自定义操作列 -->
|
<!-- 自定义操作列 -->
|
||||||
<template #menu="{ size, row, index }">
|
<template #menu="{ size, row, index }">
|
||||||
<TableButton
|
<TableButton
|
||||||
@@ -621,6 +634,7 @@ const initTable = async () => {
|
|||||||
isPermi: props.isPermi,
|
isPermi: props.isPermi,
|
||||||
useFun
|
useFun
|
||||||
})
|
})
|
||||||
|
searchDefaultValue.value = {...searchDefaultValue.value,...optionData.defaultSearch}
|
||||||
if (isDicTable.value && props.dicRowKey) optionData.tableOption.rowKey = props.dicRowKey
|
if (isDicTable.value && props.dicRowKey) optionData.tableOption.rowKey = props.dicRowKey
|
||||||
if (
|
if (
|
||||||
['treeTable', 'treeAround'].includes(optionData.tableInfo.tableType) &&
|
['treeTable', 'treeAround'].includes(optionData.tableInfo.tableType) &&
|
||||||
@@ -710,7 +724,7 @@ const initTable = async () => {
|
|||||||
}
|
}
|
||||||
try {
|
try {
|
||||||
if (jsEnhanceObj.value.initOption) jsEnhanceObj.value.initOption()
|
if (jsEnhanceObj.value.initOption) jsEnhanceObj.value.initOption()
|
||||||
searchDefaultValue.value =JSON.parse(JSON.stringify(tableSearch.value))
|
searchDefaultValue.value = {...searchDefaultValue.value,...JSON.parse(JSON.stringify(tableSearch.value))}
|
||||||
|
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
enhanceErrorTip('js增强【initOption】方法执行异常,请检查', error)
|
enhanceErrorTip('js增强【initOption】方法执行异常,请检查', error)
|
||||||
|
|||||||
@@ -123,6 +123,7 @@ const initColumn = (data, componentData, columnParams) => {
|
|||||||
const ruleObj = {}
|
const ruleObj = {}
|
||||||
const summaryBottom = {}
|
const summaryBottom = {}
|
||||||
const tableDic = {}
|
const tableDic = {}
|
||||||
|
const defaultSearch = {}
|
||||||
data.forEach(item => {
|
data.forEach(item => {
|
||||||
const { dictEntity, webEntity, queryEntity, exportEntity, summaryEntity, fieldCode, fieldName, fieldType, fieldLen, fieldPointLen, fieldDefaultVal } = item
|
const { dictEntity, webEntity, queryEntity, exportEntity, summaryEntity, fieldCode, fieldName, fieldType, fieldLen, fieldPointLen, fieldDefaultVal } = item
|
||||||
const { cellWidthType, cellWidth, controlsConfig, verifyConfig, isShowForm, isShowList, isDbSelect, isShowColumn, isShowSort, isRequired } = webEntity
|
const { cellWidthType, cellWidth, controlsConfig, verifyConfig, isShowForm, isShowList, isDbSelect, isShowColumn, isShowSort, isRequired } = webEntity
|
||||||
@@ -139,6 +140,8 @@ const initColumn = (data, componentData, columnParams) => {
|
|||||||
label: t(`${tableId}.${fieldCode}`),
|
label: t(`${tableId}.${fieldCode}`),
|
||||||
prop: fieldCode,
|
prop: fieldCode,
|
||||||
type: controlType,
|
type: controlType,
|
||||||
|
searchType: fieldName == '年'?'year' : controlType,
|
||||||
|
valueFormat: fieldName == '年'?'YYYY' : undefined,
|
||||||
span,
|
span,
|
||||||
display: isShowForm == 'Y',
|
display: isShowForm == 'Y',
|
||||||
hide,
|
hide,
|
||||||
@@ -166,7 +169,10 @@ const initColumn = (data, componentData, columnParams) => {
|
|||||||
if (isDbSelect == 'Y') column[fieldCode].value = fieldDefaultVal
|
if (isDbSelect == 'Y') column[fieldCode].value = fieldDefaultVal
|
||||||
else column[fieldCode].addValue = fieldDefaultVal
|
else column[fieldCode].addValue = fieldDefaultVal
|
||||||
}
|
}
|
||||||
if (queryDefaultVal !== '' && fieldDefaultVal !== null) column[fieldCode].searchValue = queryDefaultVal
|
if (queryDefaultVal !== '' && fieldDefaultVal !== null) {
|
||||||
|
column[fieldCode].searchValue = queryDefaultVal
|
||||||
|
defaultSearch[fieldCode] = queryDefaultVal
|
||||||
|
}
|
||||||
//字典处理
|
//字典处理
|
||||||
if (dictTable) tableDic[fieldCode] = true
|
if (dictTable) tableDic[fieldCode] = true
|
||||||
else if (dictCode) {
|
else if (dictCode) {
|
||||||
@@ -547,7 +553,7 @@ const initColumn = (data, componentData, columnParams) => {
|
|||||||
summaryBottom[fieldCode] = true
|
summaryBottom[fieldCode] = true
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
return { column, control, ruleObj, summaryBottom }
|
return { column, control, ruleObj, summaryBottom ,defaultSearch}
|
||||||
}
|
}
|
||||||
|
|
||||||
//按钮初始化
|
//按钮初始化
|
||||||
@@ -709,7 +715,7 @@ export const initTableOption = (data, context) => {
|
|||||||
}
|
}
|
||||||
|
|
||||||
//字段处理
|
//字段处理
|
||||||
const { column, control, ruleObj, summaryBottom } = initColumn(fieldList, componentData, columnParams)
|
const { column, control, ruleObj, summaryBottom ,defaultSearch } = initColumn(fieldList, componentData, columnParams)
|
||||||
tableOption.column = column
|
tableOption.column = column
|
||||||
|
|
||||||
if (subDbFormIdList && subDbFormIdList.length) {
|
if (subDbFormIdList && subDbFormIdList.length) {
|
||||||
@@ -825,6 +831,7 @@ export const initTableOption = (data, context) => {
|
|||||||
tableInfo,
|
tableInfo,
|
||||||
jsEnhanceStr,
|
jsEnhanceStr,
|
||||||
scssEnhanceStr,
|
scssEnhanceStr,
|
||||||
|
defaultSearch
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user