mirror of
https://github.com/1Panel-dev/MaxKB.git
synced 2025-12-26 01:33:05 +00:00
* fix: 修复提示问题 * fix: 上传文档限制 * feat: 问题管理 * fix: 修改分段正则,优化分段逻辑 * feat: 问题管理 * fix: word分段支持表格数据 * fix: 问题批量插入去重 * fix: 修复文档问题 * feat: 文档分页优化 * fix: 优化关联问题 * fix: 嵌入样式
31 lines
601 B
TypeScript
31 lines
601 B
TypeScript
import { defineStore } from 'pinia'
|
|
|
|
export interface commonTypes {
|
|
breadcrumb: any
|
|
paginationConfig: any | null
|
|
search: any
|
|
}
|
|
|
|
const useCommonStore = defineStore({
|
|
id: 'common',
|
|
state: (): commonTypes => ({
|
|
breadcrumb: null,
|
|
// 搜索和分页缓存
|
|
paginationConfig: {},
|
|
search: {}
|
|
}),
|
|
actions: {
|
|
saveBreadcrumb(data: any) {
|
|
this.breadcrumb = data
|
|
},
|
|
savePage(val: string, data: any) {
|
|
this.paginationConfig[val] = data
|
|
},
|
|
saveCondition(val: string, data: any) {
|
|
this.search[val] = data
|
|
}
|
|
}
|
|
})
|
|
|
|
export default useCommonStore
|