Merge remote-tracking branch 'refs/remotes/yudao/dev' into dev-crm
# Conflicts: # src/components/FormCreate/src/components/useApiSelect.tsx
This commit is contained in:
commit
cb82578b27
@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "yudao-ui-admin-vue3",
|
"name": "yudao-ui-admin-vue3",
|
||||||
"version": "2.0.1-snapshot",
|
"version": "2.1.0-snapshot",
|
||||||
"description": "基于vue3、vite4、element-plus、typesScript",
|
"description": "基于vue3、vite4、element-plus、typesScript",
|
||||||
"author": "xingyu",
|
"author": "xingyu",
|
||||||
"private": false,
|
"private": false,
|
||||||
|
@ -13,8 +13,8 @@ export interface ProductCategoryVO {
|
|||||||
// ERP 产品分类 API
|
// ERP 产品分类 API
|
||||||
export const ProductCategoryApi = {
|
export const ProductCategoryApi = {
|
||||||
// 查询产品分类列表
|
// 查询产品分类列表
|
||||||
getProductCategoryList: async (params) => {
|
getProductCategoryList: async () => {
|
||||||
return await request.get({ url: `/erp/product-category/list`, params })
|
return await request.get({ url: `/erp/product-category/list` })
|
||||||
},
|
},
|
||||||
|
|
||||||
// 查询产品分类精简列表
|
// 查询产品分类精简列表
|
||||||
|
@ -7,8 +7,8 @@ export interface Demo02CategoryVO {
|
|||||||
}
|
}
|
||||||
|
|
||||||
// 查询示例分类列表
|
// 查询示例分类列表
|
||||||
export const getDemo02CategoryList = async (params) => {
|
export const getDemo02CategoryList = async () => {
|
||||||
return await request.get({ url: `/infra/demo02-category/list`, params })
|
return await request.get({ url: `/infra/demo02-category/list` })
|
||||||
}
|
}
|
||||||
|
|
||||||
// 查询示例分类详情
|
// 查询示例分类详情
|
||||||
|
@ -17,6 +17,11 @@ export const SeckillConfigApi = {
|
|||||||
return await request.get({ url: `/promotion/seckill-config/page`, params })
|
return await request.get({ url: `/promotion/seckill-config/page`, params })
|
||||||
},
|
},
|
||||||
|
|
||||||
|
// 查询秒杀时段列表
|
||||||
|
getSimpleSeckillConfigList: async () => {
|
||||||
|
return await request.get({ url: `/promotion/seckill-config/simple-list` })
|
||||||
|
},
|
||||||
|
|
||||||
// 查询秒杀时段详情
|
// 查询秒杀时段详情
|
||||||
getSeckillConfig: async (id: number) => {
|
getSeckillConfig: async (id: number) => {
|
||||||
return await request.get({ url: `/promotion/seckill-config/get?id=` + id })
|
return await request.get({ url: `/promotion/seckill-config/get?id=` + id })
|
||||||
|
@ -141,7 +141,7 @@ export const getExpressTrackList = async (id: number | null) => {
|
|||||||
}
|
}
|
||||||
|
|
||||||
export interface DeliveryVO {
|
export interface DeliveryVO {
|
||||||
id: number // 订单编号
|
id?: number // 订单编号
|
||||||
logisticsId: number | null // 物流公司编号
|
logisticsId: number | null // 物流公司编号
|
||||||
logisticsNo: string // 物流编号
|
logisticsNo: string // 物流编号
|
||||||
}
|
}
|
||||||
|
@ -6,6 +6,7 @@ import { cloneDeep } from 'lodash-es'
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* 通用选择器规则 hook
|
* 通用选择器规则 hook
|
||||||
|
*
|
||||||
* @param option 规则配置
|
* @param option 规则配置
|
||||||
*/
|
*/
|
||||||
export const useSelectRule = (option: SelectRuleOption) => {
|
export const useSelectRule = (option: SelectRuleOption) => {
|
||||||
|
@ -17,6 +17,7 @@ import {
|
|||||||
import FcDesigner from '@form-create/designer'
|
import FcDesigner from '@form-create/designer'
|
||||||
import formCreate from '@form-create/element-ui'
|
import formCreate from '@form-create/element-ui'
|
||||||
import install from '@form-create/element-ui/auto-import'
|
import install from '@form-create/element-ui/auto-import'
|
||||||
|
|
||||||
//======================= 自定义组件 =======================
|
//======================= 自定义组件 =======================
|
||||||
import { UploadFile, UploadImg, UploadImgs } from '@/components/UploadFile'
|
import { UploadFile, UploadImg, UploadImgs } from '@/components/UploadFile'
|
||||||
import { useApiSelect } from '@/components/FormCreate'
|
import { useApiSelect } from '@/components/FormCreate'
|
||||||
|
@ -445,7 +445,7 @@ export function jsonParse(str: string) {
|
|||||||
try {
|
try {
|
||||||
return JSON.parse(str)
|
return JSON.parse(str)
|
||||||
} catch (e) {
|
} catch (e) {
|
||||||
console.log(`str[${str}] 不是一个 JSON 字符串`)
|
console.error(`str[${str}] 不是一个 JSON 字符串`)
|
||||||
return ''
|
return ''
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -62,7 +62,14 @@
|
|||||||
<template #header>
|
<template #header>
|
||||||
<div class="h-3 flex justify-between">
|
<div class="h-3 flex justify-between">
|
||||||
<span>{{ t('workplace.project') }}</span>
|
<span>{{ t('workplace.project') }}</span>
|
||||||
<el-link type="primary" :underline="false">{{ t('action.more') }}</el-link>
|
<el-link
|
||||||
|
type="primary"
|
||||||
|
:underline="false"
|
||||||
|
href="https://github.com/yudaocode"
|
||||||
|
target="_blank"
|
||||||
|
>
|
||||||
|
{{ t('action.more') }}
|
||||||
|
</el-link>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
<el-skeleton :loading="loading" animated>
|
<el-skeleton :loading="loading" animated>
|
||||||
@ -76,13 +83,13 @@
|
|||||||
:sm="24"
|
:sm="24"
|
||||||
:xs="24"
|
:xs="24"
|
||||||
>
|
>
|
||||||
<el-card shadow="hover">
|
<el-card shadow="hover" class="mr-5px mt-5px">
|
||||||
<div class="flex items-center">
|
<div class="flex items-center">
|
||||||
<Icon :icon="item.icon" :size="25" class="mr-8px" />
|
<Icon :icon="item.icon" :size="25" class="mr-8px" />
|
||||||
<span class="text-16px">{{ item.name }}</span>
|
<span class="text-16px">{{ item.name }}</span>
|
||||||
</div>
|
</div>
|
||||||
<div class="mt-16px text-14px text-gray-400">{{ t(item.message) }}</div>
|
<div class="mt-12px text-9px text-gray-400">{{ t(item.message) }}</div>
|
||||||
<div class="mt-16px flex justify-between text-12px text-gray-400">
|
<div class="mt-12px flex justify-between text-12px text-gray-400">
|
||||||
<span>{{ item.personal }}</span>
|
<span>{{ item.personal }}</span>
|
||||||
<span>{{ formatTime(item.time, 'yyyy-MM-dd') }}</span>
|
<span>{{ formatTime(item.time, 'yyyy-MM-dd') }}</span>
|
||||||
</div>
|
</div>
|
||||||
@ -204,45 +211,45 @@ let projects = reactive<Project[]>([])
|
|||||||
const getProject = async () => {
|
const getProject = async () => {
|
||||||
const data = [
|
const data = [
|
||||||
{
|
{
|
||||||
name: 'Github',
|
name: 'ruoyi-vue-pro',
|
||||||
icon: 'akar-icons:github-fill',
|
icon: 'akar-icons:github-fill',
|
||||||
message: 'workplace.introduction',
|
message: 'https://github.com/YunaiV/ruoyi-vue-pro',
|
||||||
personal: 'Archer',
|
personal: 'Spring Boot 单体架构',
|
||||||
time: new Date()
|
time: new Date()
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
name: 'Vue',
|
name: 'yudao-ui-admin-vue3',
|
||||||
icon: 'logos:vue',
|
icon: 'logos:vue',
|
||||||
message: 'workplace.introduction',
|
message: 'https://github.com/yudaocode/yudao-ui-admin-vue3',
|
||||||
personal: 'Archer',
|
personal: 'Vue3 + element-plus',
|
||||||
time: new Date()
|
time: new Date()
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
name: 'Angular',
|
name: 'yudao-ui-admin-vben',
|
||||||
icon: 'logos:angular-icon',
|
icon: 'logos:vue',
|
||||||
message: 'workplace.introduction',
|
message: 'https://github.com/yudaocode/yudao-ui-admin-vben',
|
||||||
personal: 'Archer',
|
personal: 'Vue3 + vben(antd)',
|
||||||
time: new Date()
|
time: new Date()
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
name: 'React',
|
name: 'yudao-cloud',
|
||||||
icon: 'logos:react',
|
icon: 'akar-icons:github',
|
||||||
message: 'workplace.introduction',
|
message: 'https://github.com/YunaiV/yudao-cloud',
|
||||||
personal: 'Archer',
|
personal: 'Spring Cloud 微服务架构',
|
||||||
time: new Date()
|
time: new Date()
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
name: 'Webpack',
|
name: 'yudao-ui-mall-uniapp',
|
||||||
icon: 'logos:webpack',
|
icon: 'logos:vue',
|
||||||
message: 'workplace.introduction',
|
message: 'https://github.com/yudaocode/yudao-ui-admin-uniapp',
|
||||||
personal: 'Archer',
|
personal: 'Vue3 + uniapp',
|
||||||
time: new Date()
|
time: new Date()
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
name: 'Vite',
|
name: 'yudao-ui-admin-vue2',
|
||||||
icon: 'vscode-icons:file-type-vite',
|
icon: 'logos:vue',
|
||||||
message: 'workplace.introduction',
|
message: 'https://github.com/yudaocode/yudao-ui-admin-vue2',
|
||||||
personal: 'Archer',
|
personal: 'Vue2 + element-ui',
|
||||||
time: new Date()
|
time: new Date()
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
@ -254,27 +261,27 @@ let notice = reactive<Notice[]>([])
|
|||||||
const getNotice = async () => {
|
const getNotice = async () => {
|
||||||
const data = [
|
const data = [
|
||||||
{
|
{
|
||||||
title: '系统升级版本',
|
title: '系统支持 JDK 8/17/21,Vue 2/3',
|
||||||
type: '通知',
|
type: '通知',
|
||||||
keys: ['通知', '升级'],
|
keys: ['通知', '8', '17', '21', '2', '3'],
|
||||||
date: new Date()
|
date: new Date()
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: '系统凌晨维护',
|
title: '后端提供 Spring Boot 2.7/3.2 + Cloud 双架构',
|
||||||
type: '公告',
|
type: '公告',
|
||||||
keys: ['公告', '维护'],
|
keys: ['公告', 'Boot', 'Cloud'],
|
||||||
date: new Date()
|
date: new Date()
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: '系统升级版本',
|
title: '全部开源,个人与企业可 100% 直接使用,无需授权',
|
||||||
type: '通知',
|
type: '通知',
|
||||||
keys: ['通知', '升级'],
|
keys: ['通知', '无需授权'],
|
||||||
date: new Date()
|
date: new Date()
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: '系统凌晨维护',
|
title: '国内使用最广泛的快速开发平台,超 300+ 人贡献',
|
||||||
type: '公告',
|
type: '公告',
|
||||||
keys: ['公告', '维护'],
|
keys: ['公告', '最广泛'],
|
||||||
date: new Date()
|
date: new Date()
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
|
166
src/views/ai/chat/index.vue
Normal file
166
src/views/ai/chat/index.vue
Normal file
@ -0,0 +1,166 @@
|
|||||||
|
<template>
|
||||||
|
<el-container>
|
||||||
|
<!-- 左侧:会话列表 -->
|
||||||
|
<el-aside width="260px" class="conversation-container">
|
||||||
|
<!-- 左顶部:新建对话 -->
|
||||||
|
<el-button class="w-1/1" type="primary">
|
||||||
|
<Icon icon="ep:plus" class="mr-5px" />
|
||||||
|
新建对话
|
||||||
|
</el-button>
|
||||||
|
<!-- 左顶部:搜索对话 -->
|
||||||
|
<el-input
|
||||||
|
v-model="searchName"
|
||||||
|
class="mt-10px"
|
||||||
|
placeholder="搜索历史记录"
|
||||||
|
@keyup="searchConversation"
|
||||||
|
>
|
||||||
|
<template #prefix>
|
||||||
|
<Icon icon="ep:search" />
|
||||||
|
</template>
|
||||||
|
</el-input>
|
||||||
|
<!-- 左中间:对话列表 -->
|
||||||
|
<div class="conversation-list" :style="{ height: leftHeight + 'px' }">
|
||||||
|
<el-row v-for="conversation in conversationList" :key="conversation.id">
|
||||||
|
<div
|
||||||
|
:class="conversation.id === conversationId ? 'conversation active' : 'conversation'"
|
||||||
|
@click="changeConversation(conversation)"
|
||||||
|
>
|
||||||
|
<el-image :src="conversation.avatar" class="avatar" />
|
||||||
|
<span class="title">{{ conversation.title }}</span>
|
||||||
|
<span class="button">
|
||||||
|
<!-- TODO 芋艿:缺置顶按钮 -->
|
||||||
|
<el-icon title="编辑" @click="updateConversationTitle(conversation)">
|
||||||
|
<Icon icon="ep:edit" />
|
||||||
|
</el-icon>
|
||||||
|
<el-icon title="删除会话" @click="deleteConversationTitle(conversation)">
|
||||||
|
<Icon icon="ep:delete" />
|
||||||
|
</el-icon>
|
||||||
|
</span>
|
||||||
|
</div>
|
||||||
|
</el-row>
|
||||||
|
</div>
|
||||||
|
<!-- 左底部:工具栏 TODO 芋艿:50% 不太对 -->
|
||||||
|
<div class="tool-box">
|
||||||
|
<sapn class="w-1/2"> <Icon icon="ep:user" /> 角色仓库 </sapn>
|
||||||
|
<sapn class="w-1/2"> <Icon icon="ep:delete" />清空未置顶对话</sapn>
|
||||||
|
</div>
|
||||||
|
</el-aside>
|
||||||
|
<!-- 右侧:会话详情 -->
|
||||||
|
<el-container class="detail-container">
|
||||||
|
<!-- 右顶部 TODO 芋艿:右对齐 -->
|
||||||
|
<el-header class="header">
|
||||||
|
<el-button>3.5-turbo-0125 <Icon icon="ep:setting" /></el-button>
|
||||||
|
<el-button>
|
||||||
|
<Icon icon="ep:user" />
|
||||||
|
</el-button>
|
||||||
|
<el-button>
|
||||||
|
<Icon icon="ep:download" />
|
||||||
|
</el-button>
|
||||||
|
<el-button>
|
||||||
|
<Icon icon="ep:arrow-up" />
|
||||||
|
</el-button>
|
||||||
|
</el-header>
|
||||||
|
<el-main>对话列表</el-main>
|
||||||
|
<el-footer>发送消息框</el-footer>
|
||||||
|
</el-container>
|
||||||
|
</el-container>
|
||||||
|
</template>
|
||||||
|
<script setup lang="ts">
|
||||||
|
const conversationList = [
|
||||||
|
{
|
||||||
|
id: 1,
|
||||||
|
title: '测试标题',
|
||||||
|
avatar:
|
||||||
|
'http://test.yudao.iocoder.cn/96c787a2ce88bf6d0ce3cd8b6cf5314e80e7703cd41bf4af8cd2e2909dbd6b6d.png'
|
||||||
|
},
|
||||||
|
{
|
||||||
|
id: 2,
|
||||||
|
title: '测试对话',
|
||||||
|
avatar:
|
||||||
|
'http://test.yudao.iocoder.cn/96c787a2ce88bf6d0ce3cd8b6cf5314e80e7703cd41bf4af8cd2e2909dbd6b6d.png'
|
||||||
|
}
|
||||||
|
]
|
||||||
|
const conversationId = ref(1)
|
||||||
|
const searchName = ref('')
|
||||||
|
const leftHeight = window.innerHeight - 240 // TODO 芋艿:这里还不太对
|
||||||
|
|
||||||
|
const changeConversation = (conversation) => {
|
||||||
|
console.log(conversation)
|
||||||
|
conversationId.value = conversation.id
|
||||||
|
// TODO 芋艿:待实现
|
||||||
|
}
|
||||||
|
|
||||||
|
const updateConversationTitle = (conversation) => {
|
||||||
|
console.log(conversation)
|
||||||
|
// TODO 芋艿:待实现
|
||||||
|
}
|
||||||
|
|
||||||
|
const deleteConversationTitle = (conversation) => {
|
||||||
|
console.log(conversation)
|
||||||
|
// TODO 芋艿:待实现
|
||||||
|
}
|
||||||
|
|
||||||
|
const searchConversation = () => {
|
||||||
|
// TODO 芋艿:待实现
|
||||||
|
}
|
||||||
|
</script>
|
||||||
|
<style lang="scss" scoped>
|
||||||
|
.conversation-container {
|
||||||
|
.conversation-list {
|
||||||
|
.conversation {
|
||||||
|
display: flex;
|
||||||
|
justify-content: flex-start;
|
||||||
|
width: 100%;
|
||||||
|
padding: 5px 5px 0 0;
|
||||||
|
cursor: pointer;
|
||||||
|
&.active {
|
||||||
|
// TODO 芋艿:这里不太对
|
||||||
|
background-color: #343540;
|
||||||
|
.button {
|
||||||
|
display: inline;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
.title {
|
||||||
|
padding: 5px 10px;
|
||||||
|
max-width: 220px;
|
||||||
|
font-size: 14px;
|
||||||
|
overflow: hidden;
|
||||||
|
white-space: nowrap;
|
||||||
|
text-overflow: ellipsis;
|
||||||
|
}
|
||||||
|
.avatar {
|
||||||
|
width: 28px;
|
||||||
|
height: 28px;
|
||||||
|
border-radius: 50%;
|
||||||
|
}
|
||||||
|
.button {
|
||||||
|
position: absolute;
|
||||||
|
right: 2px;
|
||||||
|
top: 16px;
|
||||||
|
.el-icon {
|
||||||
|
margin-right: 5px;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
.tool-box {
|
||||||
|
display: flex;
|
||||||
|
justify-content: flex-start;
|
||||||
|
padding: 0 20px 10px 20px;
|
||||||
|
border-top: 1px solid black;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
.detail-container {
|
||||||
|
.header {
|
||||||
|
width: 100%;
|
||||||
|
height: 30px;
|
||||||
|
display: flex;
|
||||||
|
flex-direction: row;
|
||||||
|
align-items: center;
|
||||||
|
justify-content: center;
|
||||||
|
padding-top: 10px;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
</style>
|
@ -100,7 +100,7 @@ const dialogTitle = ref('') // 弹窗的标题
|
|||||||
const formLoading = ref(false) // 表单的加载中:1)修改时的数据加载;2)提交的按钮禁用
|
const formLoading = ref(false) // 表单的加载中:1)修改时的数据加载;2)提交的按钮禁用
|
||||||
const formType = ref('') // 表单的组:create - 新增;update - 修改
|
const formType = ref('') // 表单的组:create - 新增;update - 修改
|
||||||
const formData = ref({
|
const formData = ref({
|
||||||
id: 0,
|
id: undefined,
|
||||||
name: '',
|
name: '',
|
||||||
deptIds: [],
|
deptIds: [],
|
||||||
statuses: []
|
statuses: []
|
||||||
@ -168,7 +168,7 @@ const submitForm = async () => {
|
|||||||
const resetForm = () => {
|
const resetForm = () => {
|
||||||
checkStrictly.value = true
|
checkStrictly.value = true
|
||||||
formData.value = {
|
formData.value = {
|
||||||
id: 0,
|
id: undefined,
|
||||||
name: '',
|
name: '',
|
||||||
deptIds: [],
|
deptIds: [],
|
||||||
statuses: []
|
statuses: []
|
||||||
|
@ -46,7 +46,7 @@
|
|||||||
</template>
|
</template>
|
||||||
<script setup lang="ts">
|
<script setup lang="ts">
|
||||||
import { getIntDictOptions, DICT_TYPE } from '@/utils/dict'
|
import { getIntDictOptions, DICT_TYPE } from '@/utils/dict'
|
||||||
import { ProductCategoryApi } from '@/api/erp/product/category'
|
import { ProductCategoryApi, ProductCategoryVO } from '@/api/erp/product/category'
|
||||||
import { defaultProps, handleTree } from '@/utils/tree'
|
import { defaultProps, handleTree } from '@/utils/tree'
|
||||||
import { CommonStatusEnum } from '@/utils/constants'
|
import { CommonStatusEnum } from '@/utils/constants'
|
||||||
|
|
||||||
@ -66,7 +66,7 @@ const formData = ref({
|
|||||||
name: undefined,
|
name: undefined,
|
||||||
code: undefined,
|
code: undefined,
|
||||||
sort: undefined,
|
sort: undefined,
|
||||||
status: undefined
|
status: CommonStatusEnum.ENABLE
|
||||||
})
|
})
|
||||||
const formRules = reactive({
|
const formRules = reactive({
|
||||||
parentId: [{ required: true, message: '上级编号不能为空', trigger: 'blur' }],
|
parentId: [{ required: true, message: '上级编号不能为空', trigger: 'blur' }],
|
||||||
@ -105,7 +105,7 @@ const submitForm = async () => {
|
|||||||
// 提交请求
|
// 提交请求
|
||||||
formLoading.value = true
|
formLoading.value = true
|
||||||
try {
|
try {
|
||||||
const data = formData.value as unknown as ProductCategoryApi.ProductCategoryVO
|
const data = formData.value as unknown as ProductCategoryVO
|
||||||
if (formType.value === 'create') {
|
if (formType.value === 'create') {
|
||||||
await ProductCategoryApi.createProductCategory(data)
|
await ProductCategoryApi.createProductCategory(data)
|
||||||
message.success(t('common.createSuccess'))
|
message.success(t('common.createSuccess'))
|
||||||
|
@ -157,7 +157,7 @@
|
|||||||
import { DICT_TYPE, getIntDictOptions } from '@/utils/dict'
|
import { DICT_TYPE, getIntDictOptions } from '@/utils/dict'
|
||||||
import { dateFormatter } from '@/utils/formatTime'
|
import { dateFormatter } from '@/utils/formatTime'
|
||||||
import * as SeckillActivityApi from '@/api/mall/promotion/seckill/seckillActivity'
|
import * as SeckillActivityApi from '@/api/mall/promotion/seckill/seckillActivity'
|
||||||
import * as SeckillConfigApi from '@/api/mall/promotion/seckill/seckillConfig'
|
import { SeckillConfigApi } from '@/api/mall/promotion/seckill/seckillConfig'
|
||||||
import SeckillActivityForm from './SeckillActivityForm.vue'
|
import SeckillActivityForm from './SeckillActivityForm.vue'
|
||||||
import { formatDate } from '@/utils/formatTime'
|
import { formatDate } from '@/utils/formatTime'
|
||||||
import { fenToYuanFormat } from '@/utils/formatter'
|
import { fenToYuanFormat } from '@/utils/formatter'
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
import type { CrudSchema } from '@/hooks/web/useCrudSchemas'
|
import type { CrudSchema } from '@/hooks/web/useCrudSchemas'
|
||||||
import { dateFormatter, dateFormatter2 } from '@/utils/formatTime'
|
import { dateFormatter2 } from '@/utils/formatTime'
|
||||||
import { getSimpleSeckillConfigList } from '@/api/mall/promotion/seckill/seckillConfig'
|
import { SeckillConfigApi } from '@/api/mall/promotion/seckill/seckillConfig'
|
||||||
|
|
||||||
// 表单校验
|
// 表单校验
|
||||||
export const rules = reactive({
|
export const rules = reactive({
|
||||||
@ -88,7 +88,7 @@ const crudSchemas = reactive<CrudSchema[]>([
|
|||||||
valueField: 'id'
|
valueField: 'id'
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
api: getSimpleSeckillConfigList
|
api: SeckillConfigApi.getSimpleSeckillConfigList
|
||||||
},
|
},
|
||||||
table: {
|
table: {
|
||||||
width: 300
|
width: 300
|
||||||
|
@ -26,9 +26,9 @@
|
|||||||
icon="ep:view"
|
icon="ep:view"
|
||||||
icon-color="bg-blue-100"
|
icon-color="bg-blue-100"
|
||||||
icon-bg-color="text-blue-500"
|
icon-bg-color="text-blue-500"
|
||||||
prefix="¥"
|
prefix=""
|
||||||
:decimals="2"
|
:decimals="0"
|
||||||
:value="fenToYuan(trendSummary?.value?.browseCount || 0)"
|
:value="trendSummary?.value?.browseCount || 0"
|
||||||
:percent="
|
:percent="
|
||||||
calculateRelativeRate(
|
calculateRelativeRate(
|
||||||
trendSummary?.value?.browseCount,
|
trendSummary?.value?.browseCount,
|
||||||
@ -44,9 +44,9 @@
|
|||||||
icon="ep:user-filled"
|
icon="ep:user-filled"
|
||||||
icon-color="bg-purple-100"
|
icon-color="bg-purple-100"
|
||||||
icon-bg-color="text-purple-500"
|
icon-bg-color="text-purple-500"
|
||||||
prefix="¥"
|
prefix=""
|
||||||
:decimals="2"
|
:decimals="0"
|
||||||
:value="fenToYuan(trendSummary?.value?.browseUserCount || 0)"
|
:value="trendSummary?.value?.browseUserCount || 0"
|
||||||
:percent="
|
:percent="
|
||||||
calculateRelativeRate(
|
calculateRelativeRate(
|
||||||
trendSummary?.value?.browseUserCount,
|
trendSummary?.value?.browseUserCount,
|
||||||
@ -62,9 +62,9 @@
|
|||||||
icon="fa-solid:money-check-alt"
|
icon="fa-solid:money-check-alt"
|
||||||
icon-color="bg-yellow-100"
|
icon-color="bg-yellow-100"
|
||||||
icon-bg-color="text-yellow-500"
|
icon-bg-color="text-yellow-500"
|
||||||
prefix="¥"
|
prefix=""
|
||||||
:decimals="2"
|
:decimals="0"
|
||||||
:value="fenToYuan(trendSummary?.value?.orderPayCount || 0)"
|
:value="trendSummary?.value?.orderPayCount || 0"
|
||||||
:percent="
|
:percent="
|
||||||
calculateRelativeRate(
|
calculateRelativeRate(
|
||||||
trendSummary?.value?.orderPayCount,
|
trendSummary?.value?.orderPayCount,
|
||||||
@ -98,9 +98,9 @@
|
|||||||
icon="fa-solid:wallet"
|
icon="fa-solid:wallet"
|
||||||
icon-color="bg-cyan-100"
|
icon-color="bg-cyan-100"
|
||||||
icon-bg-color="text-cyan-500"
|
icon-bg-color="text-cyan-500"
|
||||||
prefix="¥"
|
prefix=""
|
||||||
:decimals="2"
|
:decimals="0"
|
||||||
:value="fenToYuan(trendSummary?.value?.afterSaleCount || 0)"
|
:value="trendSummary?.value?.afterSaleCount || 0"
|
||||||
:percent="
|
:percent="
|
||||||
calculateRelativeRate(
|
calculateRelativeRate(
|
||||||
trendSummary?.value?.afterSaleCount,
|
trendSummary?.value?.afterSaleCount,
|
||||||
|
@ -27,7 +27,7 @@ const message = useMessage() // 消息弹窗
|
|||||||
const dialogVisible = ref(false) // 弹窗的是否展示
|
const dialogVisible = ref(false) // 弹窗的是否展示
|
||||||
const formLoading = ref(false) // 表单的加载中:1)修改时的数据加载;2)提交的按钮禁用
|
const formLoading = ref(false) // 表单的加载中:1)修改时的数据加载;2)提交的按钮禁用
|
||||||
const formData = ref({
|
const formData = ref({
|
||||||
id: 0, // 售后订单编号
|
id: undefined, // 售后订单编号
|
||||||
auditReason: '' // 审批备注
|
auditReason: '' // 审批备注
|
||||||
})
|
})
|
||||||
const formRef = ref() // 表单 Ref
|
const formRef = ref() // 表单 Ref
|
||||||
@ -62,7 +62,7 @@ const submitForm = async () => {
|
|||||||
/** 重置表单 */
|
/** 重置表单 */
|
||||||
const resetForm = () => {
|
const resetForm = () => {
|
||||||
formData.value = {
|
formData.value = {
|
||||||
id: 0, // 售后订单编号
|
id: undefined, // 售后订单编号
|
||||||
auditReason: '' // 审批备注
|
auditReason: '' // 审批备注
|
||||||
}
|
}
|
||||||
formRef.value?.resetFields()
|
formRef.value?.resetFields()
|
||||||
|
@ -103,7 +103,7 @@ const submitForm = async () => {
|
|||||||
/** 重置表单 */
|
/** 重置表单 */
|
||||||
const resetForm = () => {
|
const resetForm = () => {
|
||||||
formData.value = {
|
formData.value = {
|
||||||
id: 0,
|
id: undefined,
|
||||||
bindUserId: undefined
|
bindUserId: undefined
|
||||||
}
|
}
|
||||||
formRef.value?.resetFields()
|
formRef.value?.resetFields()
|
||||||
|
@ -43,7 +43,7 @@ const dialogVisible = ref(false) // 弹窗的是否展示
|
|||||||
const formLoading = ref(false) // 表单的加载中:1)修改时的数据加载;2)提交的按钮禁用
|
const formLoading = ref(false) // 表单的加载中:1)修改时的数据加载;2)提交的按钮禁用
|
||||||
const expressType = ref('express') // 如果值是 express,则是快递;none 则是无;未来做同城配送;
|
const expressType = ref('express') // 如果值是 express,则是快递;none 则是无;未来做同城配送;
|
||||||
const formData = ref<TradeOrderApi.DeliveryVO>({
|
const formData = ref<TradeOrderApi.DeliveryVO>({
|
||||||
id: 0, // 订单编号
|
id: undefined, // 订单编号
|
||||||
logisticsId: null, // 物流公司编号
|
logisticsId: null, // 物流公司编号
|
||||||
logisticsNo: '' // 物流编号
|
logisticsNo: '' // 物流编号
|
||||||
})
|
})
|
||||||
@ -86,7 +86,7 @@ const submitForm = async () => {
|
|||||||
/** 重置表单 */
|
/** 重置表单 */
|
||||||
const resetForm = () => {
|
const resetForm = () => {
|
||||||
formData.value = {
|
formData.value = {
|
||||||
id: 0, // 订单编号
|
id: undefined, // 订单编号
|
||||||
logisticsId: null, // 物流公司编号
|
logisticsId: null, // 物流公司编号
|
||||||
logisticsNo: '' // 物流编号
|
logisticsNo: '' // 物流编号
|
||||||
}
|
}
|
||||||
|
@ -44,7 +44,7 @@ const message = useMessage() // 消息弹窗
|
|||||||
const dialogVisible = ref(false) // 弹窗的是否展示
|
const dialogVisible = ref(false) // 弹窗的是否展示
|
||||||
const formLoading = ref(false) // 表单的加载中:1)修改时的数据加载;2)提交的按钮禁用
|
const formLoading = ref(false) // 表单的加载中:1)修改时的数据加载;2)提交的按钮禁用
|
||||||
const formData = ref({
|
const formData = ref({
|
||||||
id: 0, // 订单编号
|
id: undefined, // 订单编号
|
||||||
receiverName: '', // 收件人名称
|
receiverName: '', // 收件人名称
|
||||||
receiverMobile: '', // 收件人手机
|
receiverMobile: '', // 收件人手机
|
||||||
receiverAreaId: null, //收件人地区编号
|
receiverAreaId: null, //收件人地区编号
|
||||||
@ -82,7 +82,7 @@ const submitForm = async () => {
|
|||||||
/** 重置表单 */
|
/** 重置表单 */
|
||||||
const resetForm = () => {
|
const resetForm = () => {
|
||||||
formData.value = {
|
formData.value = {
|
||||||
id: 0, // 订单编号
|
id: undefined, // 订单编号
|
||||||
receiverName: '', // 收件人名称
|
receiverName: '', // 收件人名称
|
||||||
receiverMobile: '', // 收件人手机
|
receiverMobile: '', // 收件人手机
|
||||||
receiverAreaId: null, //收件人地区编号
|
receiverAreaId: null, //收件人地区编号
|
||||||
|
@ -31,7 +31,7 @@ const message = useMessage() // 消息弹窗
|
|||||||
const dialogVisible = ref(false) // 弹窗的是否展示
|
const dialogVisible = ref(false) // 弹窗的是否展示
|
||||||
const formLoading = ref(false) // 表单的加载中:1)修改时的数据加载;2)提交的按钮禁用
|
const formLoading = ref(false) // 表单的加载中:1)修改时的数据加载;2)提交的按钮禁用
|
||||||
const formData = ref({
|
const formData = ref({
|
||||||
id: 0, // 订单编号
|
id: undefined, // 订单编号
|
||||||
adjustPrice: 0, // 订单调价
|
adjustPrice: 0, // 订单调价
|
||||||
payPrice: '', // 应付金额(总)
|
payPrice: '', // 应付金额(总)
|
||||||
newPayPrice: '' // 调价后应付金额(总)
|
newPayPrice: '' // 调价后应付金额(总)
|
||||||
@ -85,7 +85,7 @@ const submitForm = async () => {
|
|||||||
/** 重置表单 */
|
/** 重置表单 */
|
||||||
const resetForm = () => {
|
const resetForm = () => {
|
||||||
formData.value = {
|
formData.value = {
|
||||||
id: 0, // 订单编号
|
id: undefined, // 订单编号
|
||||||
adjustPrice: 0, // 订单调价
|
adjustPrice: 0, // 订单调价
|
||||||
payPrice: '', // 应付金额(总)
|
payPrice: '', // 应付金额(总)
|
||||||
newPayPrice: '' // 调价后应付金额(总)
|
newPayPrice: '' // 调价后应付金额(总)
|
||||||
|
@ -27,7 +27,7 @@ const message = useMessage() // 消息弹窗
|
|||||||
const dialogVisible = ref(false) // 弹窗的是否展示
|
const dialogVisible = ref(false) // 弹窗的是否展示
|
||||||
const formLoading = ref(false) // 表单的加载中:1)修改时的数据加载;2)提交的按钮禁用
|
const formLoading = ref(false) // 表单的加载中:1)修改时的数据加载;2)提交的按钮禁用
|
||||||
const formData = ref({
|
const formData = ref({
|
||||||
id: 0, // 订单编号
|
id: undefined, // 订单编号
|
||||||
remark: '' // 订单备注
|
remark: '' // 订单备注
|
||||||
})
|
})
|
||||||
const formRef = ref() // 表单 Ref
|
const formRef = ref() // 表单 Ref
|
||||||
@ -62,7 +62,7 @@ const submitForm = async () => {
|
|||||||
/** 重置表单 */
|
/** 重置表单 */
|
||||||
const resetForm = () => {
|
const resetForm = () => {
|
||||||
formData.value = {
|
formData.value = {
|
||||||
id: 0, // 订单编号
|
id: undefined, // 订单编号
|
||||||
remark: '' // 订单备注
|
remark: '' // 订单备注
|
||||||
}
|
}
|
||||||
formRef.value?.resetFields()
|
formRef.value?.resetFields()
|
||||||
|
@ -1,5 +1,7 @@
|
|||||||
<template>
|
<template>
|
||||||
<ContentWrap>
|
<ContentWrap>
|
||||||
|
<doc-alert title="大屏设计器" url="https://doc.iocoder.cn/report/screen/" />
|
||||||
|
|
||||||
<IFrame :src="src" />
|
<IFrame :src="src" />
|
||||||
</ContentWrap>
|
</ContentWrap>
|
||||||
</template>
|
</template>
|
||||||
|
@ -1,5 +1,7 @@
|
|||||||
<template>
|
<template>
|
||||||
<ContentWrap>
|
<ContentWrap>
|
||||||
|
<doc-alert title="报表设计器" url="https://doc.iocoder.cn/report/" />
|
||||||
|
|
||||||
<IFrame :src="src" />
|
<IFrame :src="src" />
|
||||||
</ContentWrap>
|
</ContentWrap>
|
||||||
</template>
|
</template>
|
||||||
|
@ -130,7 +130,7 @@ const dialogTitle = ref('') // 弹窗的标题
|
|||||||
const formLoading = ref(false) // 表单的加载中:1)修改时的数据加载;2)提交的按钮禁用
|
const formLoading = ref(false) // 表单的加载中:1)修改时的数据加载;2)提交的按钮禁用
|
||||||
const formType = ref('') // 表单的类型:create - 新增;update - 修改
|
const formType = ref('') // 表单的类型:create - 新增;update - 修改
|
||||||
const formData = ref({
|
const formData = ref({
|
||||||
id: 0,
|
id: undefined,
|
||||||
name: '',
|
name: '',
|
||||||
permission: '',
|
permission: '',
|
||||||
type: SystemMenuTypeEnum.DIR,
|
type: SystemMenuTypeEnum.DIR,
|
||||||
@ -231,7 +231,7 @@ const getTree = async () => {
|
|||||||
/** 重置表单 */
|
/** 重置表单 */
|
||||||
const resetForm = () => {
|
const resetForm = () => {
|
||||||
formData.value = {
|
formData.value = {
|
||||||
id: 0,
|
id: undefined,
|
||||||
name: '',
|
name: '',
|
||||||
permission: '',
|
permission: '',
|
||||||
type: SystemMenuTypeEnum.DIR,
|
type: SystemMenuTypeEnum.DIR,
|
||||||
|
@ -58,7 +58,7 @@ const message = useMessage() // 消息弹窗
|
|||||||
const dialogVisible = ref(false) // 弹窗的是否展示
|
const dialogVisible = ref(false) // 弹窗的是否展示
|
||||||
const formLoading = ref(false) // 表单的加载中:1)修改时的数据加载;2)提交的按钮禁用
|
const formLoading = ref(false) // 表单的加载中:1)修改时的数据加载;2)提交的按钮禁用
|
||||||
const formData = reactive({
|
const formData = reactive({
|
||||||
id: 0,
|
id: undefined,
|
||||||
name: '',
|
name: '',
|
||||||
code: '',
|
code: '',
|
||||||
menuIds: []
|
menuIds: []
|
||||||
@ -126,7 +126,7 @@ const resetForm = () => {
|
|||||||
menuExpand.value = false
|
menuExpand.value = false
|
||||||
// 重置表单
|
// 重置表单
|
||||||
formData.value = {
|
formData.value = {
|
||||||
id: 0,
|
id: undefined,
|
||||||
name: '',
|
name: '',
|
||||||
code: '',
|
code: '',
|
||||||
menuIds: []
|
menuIds: []
|
||||||
|
@ -78,7 +78,7 @@ const message = useMessage() // 消息弹窗
|
|||||||
const dialogVisible = ref(false) // 弹窗的是否展示
|
const dialogVisible = ref(false) // 弹窗的是否展示
|
||||||
const formLoading = ref(false) // 表单的加载中:1)修改时的数据加载;2)提交的按钮禁用
|
const formLoading = ref(false) // 表单的加载中:1)修改时的数据加载;2)提交的按钮禁用
|
||||||
const formData = reactive({
|
const formData = reactive({
|
||||||
id: 0,
|
id: undefined,
|
||||||
name: '',
|
name: '',
|
||||||
code: '',
|
code: '',
|
||||||
dataScope: undefined,
|
dataScope: undefined,
|
||||||
@ -141,7 +141,7 @@ const resetForm = () => {
|
|||||||
checkStrictly.value = true
|
checkStrictly.value = true
|
||||||
// 重置表单
|
// 重置表单
|
||||||
formData.value = {
|
formData.value = {
|
||||||
id: 0,
|
id: undefined,
|
||||||
name: '',
|
name: '',
|
||||||
code: '',
|
code: '',
|
||||||
dataScope: undefined,
|
dataScope: undefined,
|
||||||
|
Loading…
Reference in New Issue
Block a user