更新版本
This commit is contained in:
2540
cdTMP/package-lock.json
generated
2540
cdTMP/package-lock.json
generated
File diff suppressed because it is too large
Load Diff
@@ -1,7 +1,7 @@
|
|||||||
{
|
{
|
||||||
"name": "cdtmp",
|
"name": "testplant",
|
||||||
"private": true,
|
"private": true,
|
||||||
"version": "0.0.5",
|
"version": "0.0.6",
|
||||||
"type": "module",
|
"type": "module",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"dev": "vite",
|
"dev": "vite",
|
||||||
@@ -13,54 +13,54 @@
|
|||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@arco-design/color": "^0.4.0",
|
"@arco-design/color": "^0.4.0",
|
||||||
"@arco-design/web-vue": "^2.57.0",
|
"@arco-design/web-vue": "^2.57.0",
|
||||||
"@tanstack/vue-query": "^5.77.2",
|
"@tanstack/vue-query": "^5.83.1",
|
||||||
"@tinymce/tinymce-vue": "^6.1.0",
|
"@tinymce/tinymce-vue": "^6.3.0",
|
||||||
"@vueuse/core": "^13.3.0",
|
"@vueuse/core": "^13.6.0",
|
||||||
"axios": "^1.9.0",
|
"axios": "^1.11.0",
|
||||||
"class-variance-authority": "^0.7.1",
|
"class-variance-authority": "^0.7.1",
|
||||||
"clsx": "^2.1.1",
|
"clsx": "^2.1.1",
|
||||||
"dayjs": "^1.11.13",
|
"dayjs": "^1.11.13",
|
||||||
"file2md5": "^1.3.0",
|
"file2md5": "^1.3.0",
|
||||||
"lodash-es": "^4.17.21",
|
"lodash-es": "^4.17.21",
|
||||||
"lucide-vue-next": "^0.511.0",
|
"lucide-vue-next": "^0.539.0",
|
||||||
"mammoth": "^1.9.0",
|
"mammoth": "^1.10.0",
|
||||||
"mitt": "^3.0.1",
|
"mitt": "^3.0.1",
|
||||||
"nprogress": "^0.2.0",
|
"nprogress": "^0.2.0",
|
||||||
"pinia": "^3.0.2",
|
"pinia": "^3.0.3",
|
||||||
"pinyin-match": "^1.2.8",
|
"pinyin-match": "^1.2.8",
|
||||||
"postcss-import": "^16.1.0",
|
"postcss-import": "^16.1.1",
|
||||||
"qs": "^6.14.0",
|
"qs": "^6.14.0",
|
||||||
"tailwind-merge": "^3.3.0",
|
"tailwind-merge": "^3.3.1",
|
||||||
"tinymce": "^7.9.0",
|
"tinymce": "^8.0.2",
|
||||||
"tw-animate-css": "^1.3.0",
|
"tw-animate-css": "^1.3.6",
|
||||||
"vue": "^3.5.15",
|
"vue": "^3.5.18",
|
||||||
"vue-clipboard3": "^2.0.0",
|
"vue-clipboard3": "^2.0.0",
|
||||||
"vue-color-kit": "^1.0.6",
|
"vue-color-kit": "^1.0.6",
|
||||||
"vue-data-ui": "^2.7.6",
|
"vue-data-ui": "^2.17.11",
|
||||||
"vue-router": "^4.5.1",
|
"vue-router": "^4.5.1",
|
||||||
"vuedraggable": "^2.24.3"
|
"vuedraggable": "^2.24.3"
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"@tailwindcss/postcss": "^4.1.7",
|
"@tailwindcss/postcss": "^4.1.11",
|
||||||
"@tailwindcss/vite": "^4.1.7",
|
"@tailwindcss/vite": "^4.1.11",
|
||||||
"@types/lodash-es": "^4.17.12",
|
"@types/lodash-es": "^4.17.12",
|
||||||
"@types/node": "^22.15.23",
|
"@types/node": "^24.2.1",
|
||||||
"@types/nprogress": "^0.2.3",
|
"@types/nprogress": "^0.2.3",
|
||||||
"@types/qs": "^6.14.0",
|
"@types/qs": "^6.14.0",
|
||||||
"@vitejs/plugin-vue": "^5.2.4",
|
"@vitejs/plugin-vue": "^6.0.1",
|
||||||
"@vitejs/plugin-vue-jsx": "^4.2.0",
|
"@vitejs/plugin-vue-jsx": "^5.0.1",
|
||||||
"@vue/babel-plugin-jsx": "^1.4.0",
|
"@vue/babel-plugin-jsx": "^1.5.0",
|
||||||
"browserslist": "^4.24.5",
|
"browserslist": "^4.25.2",
|
||||||
"eslint": "^9.27.0",
|
"eslint": "^9.33.0",
|
||||||
"eslint-plugin-vue": "^10.1.0",
|
"eslint-plugin-vue": "^10.4.0",
|
||||||
"less": "^4.3.0",
|
"less": "^4.4.0",
|
||||||
"less-loader": "^12.3.0",
|
"less-loader": "^12.3.0",
|
||||||
"postcss": "^8.5.3",
|
"postcss": "^8.5.6",
|
||||||
"prettier": "^3.5.3",
|
"prettier": "^3.6.2",
|
||||||
"rollup-plugin-visualizer": "^6.0.1",
|
"rollup-plugin-visualizer": "^6.0.3",
|
||||||
"tailwindcss": "^4.1.7",
|
"tailwindcss": "^4.1.11",
|
||||||
"typescript": "^5.8.3",
|
"typescript": "^5.9.2",
|
||||||
"vite": "^6.3.5",
|
"vite": "^7.1.2",
|
||||||
"vue-eslint-parser": "^10.1.3"
|
"vue-eslint-parser": "^10.2.0"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -99,10 +99,15 @@ const submit = async () => {
|
|||||||
if (isFunction(options.beforeEdit) && !(await options.beforeEdit(formData))) {
|
if (isFunction(options.beforeEdit) && !(await options.beforeEdit(formData))) {
|
||||||
return false
|
return false
|
||||||
}
|
}
|
||||||
if (!options.parameters) {
|
// 修改源码2025-06-24,使用try...catch捕获信息
|
||||||
response = await options.edit.api(formData[options.pk], formData)
|
try {
|
||||||
} else {
|
if (!options.parameters) {
|
||||||
response = await options.edit.api(formData[options.pk], { ...formData, ...options.parameters })
|
response = await options.edit.api(formData[options.pk], formData)
|
||||||
|
} else {
|
||||||
|
response = await options.edit.api(formData[options.pk], { ...formData, ...options.parameters })
|
||||||
|
}
|
||||||
|
} catch (e) {
|
||||||
|
return false
|
||||||
}
|
}
|
||||||
isFunction(options.afterEdit) && (await options.afterEdit(response, formData))
|
isFunction(options.afterEdit) && (await options.afterEdit(response, formData))
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -61,7 +61,7 @@
|
|||||||
</a-button>
|
</a-button>
|
||||||
</a-tooltip>
|
</a-tooltip>
|
||||||
<a-button-group shape="round" size="mini">
|
<a-button-group shape="round" size="mini">
|
||||||
<a-button type="primary" @click="moveUp(index)">
|
<a-button type="primary" @click="moveUp(index)">
|
||||||
<icon-arrow-rise />
|
<icon-arrow-rise />
|
||||||
</a-button>
|
</a-button>
|
||||||
<a-button type="primary" @click="moveDown(index)">
|
<a-button type="primary" @click="moveDown(index)">
|
||||||
@@ -100,6 +100,7 @@
|
|||||||
|
|
||||||
<script setup lang="ts">
|
<script setup lang="ts">
|
||||||
import { type Ref, nextTick } from "vue"
|
import { type Ref, nextTick } from "vue"
|
||||||
|
import { cloneDeep } from "lodash-es"
|
||||||
|
|
||||||
// 辅助函数:当modelValue不是列表时候
|
// 辅助函数:当modelValue不是列表时候
|
||||||
function handleIsNotArray() {
|
function handleIsNotArray() {
|
||||||
@@ -129,7 +130,7 @@ const deleteItem = (index: number) => {
|
|||||||
|
|
||||||
// 复制单项
|
// 复制单项
|
||||||
const copyItem = (index: number) => {
|
const copyItem = (index: number) => {
|
||||||
const newItem = modelValue.value[index]
|
const newItem = cloneDeep(modelValue.value[index])
|
||||||
modelValue.value = [...modelValue.value, newItem]
|
modelValue.value = [...modelValue.value, newItem]
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -261,6 +261,20 @@ function swapItems(idx1, idx2) {
|
|||||||
;[arr[idx1], arr[idx2]] = [arr[idx2], arr[idx1]]
|
;[arr[idx1], arr[idx2]] = [arr[idx2], arr[idx1]]
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// 辅助函数:触发充分性分析
|
||||||
|
// 2025-06-24:新增子项后需对触发更新
|
||||||
|
function updateChongFen() {
|
||||||
|
if (formModel.value.testContent && formModel.value.testContent.length > 0) {
|
||||||
|
// 如果有testContent则更新“充分性要求”
|
||||||
|
const subItemFormData = formModel.value.testContent
|
||||||
|
const mapRes = subItemFormData.map((subItem) => subItem.subName || "")
|
||||||
|
formModel.value.adequacy &&
|
||||||
|
(formModel.value.adequacy = `测试用例覆盖${mapRes.join(
|
||||||
|
"、"
|
||||||
|
)}子项要求的全部内容。\n所有用例执行完毕,对于未执行的用例说明未执行原因。`)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// 修改源码:上移动和下移动
|
// 修改源码:上移动和下移动
|
||||||
const moveUp = (itemIndex) => {
|
const moveUp = (itemIndex) => {
|
||||||
const itemLength = formModel.value[props.component.dataIndex].length
|
const itemLength = formModel.value[props.component.dataIndex].length
|
||||||
@@ -270,6 +284,8 @@ const moveUp = (itemIndex) => {
|
|||||||
}
|
}
|
||||||
// 进行移动
|
// 进行移动
|
||||||
swapItems(itemIndex, itemIndex - 1)
|
swapItems(itemIndex, itemIndex - 1)
|
||||||
|
// 2025-06-24修改
|
||||||
|
updateChongFen()
|
||||||
}
|
}
|
||||||
|
|
||||||
const moveDown = (itemIndex) => {
|
const moveDown = (itemIndex) => {
|
||||||
@@ -280,6 +296,8 @@ const moveDown = (itemIndex) => {
|
|||||||
}
|
}
|
||||||
// 进行移动
|
// 进行移动
|
||||||
swapItems(itemIndex, itemIndex + 1)
|
swapItems(itemIndex, itemIndex + 1)
|
||||||
|
// 2025-06-24修改
|
||||||
|
updateChongFen()
|
||||||
}
|
}
|
||||||
|
|
||||||
const addItem = async (data = {}) => {
|
const addItem = async (data = {}) => {
|
||||||
@@ -289,6 +307,8 @@ const addItem = async (data = {}) => {
|
|||||||
viewFormList.value[index] = cloneDeep(formList)
|
viewFormList.value[index] = cloneDeep(formList)
|
||||||
rv("onAdd", { formList: viewFormList.value[index], newData, index }) // 修改源码:深度复制data->newData
|
rv("onAdd", { formList: viewFormList.value[index], newData, index }) // 修改源码:深度复制data->newData
|
||||||
formModel.value[props.component.dataIndex].push(newData) // 修改源码:深度复制data->newData
|
formModel.value[props.component.dataIndex].push(newData) // 修改源码:深度复制data->newData
|
||||||
|
// 修改源码,触发充分性更新
|
||||||
|
updateChongFen()
|
||||||
}
|
}
|
||||||
|
|
||||||
const deleteItem = async (index) => {
|
const deleteItem = async (index) => {
|
||||||
@@ -298,6 +318,8 @@ const deleteItem = async (index) => {
|
|||||||
await nextTick()
|
await nextTick()
|
||||||
formModel.value[props.component.dataIndex].splice(index, 1)
|
formModel.value[props.component.dataIndex].splice(index, 1)
|
||||||
}
|
}
|
||||||
|
// 2025-06-24修改
|
||||||
|
updateChongFen()
|
||||||
}
|
}
|
||||||
|
|
||||||
const getChildrenDataIndex = (index, dataIndex) => {
|
const getChildrenDataIndex = (index, dataIndex) => {
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
<template>
|
<template>
|
||||||
<a-modal v-model:visible="visible" width="80%" draggable :footer="false" unmount-on-close>
|
<a-modal v-model:visible="visible" width="80%" draggable :footer="false">
|
||||||
<template #title>维护数据字典 →【{{ currentRow.name }}】</template>
|
<template #title>维护数据字典 →【{{ currentRow.name }}】</template>
|
||||||
<!-- crud组件 -->
|
<!-- crud组件 -->
|
||||||
<div class="lg:w-full w-full lg:mt-0">
|
<div class="lg:w-full w-full lg:mt-0">
|
||||||
@@ -35,6 +35,7 @@ import useOpenChangeModal from "./useOpenChangeModal"
|
|||||||
|
|
||||||
const currentRow = ref({ id: undefined, name: undefined }) // 当前选择的行
|
const currentRow = ref({ id: undefined, name: undefined }) // 当前选择的行
|
||||||
const { crudRef, crudOptions, columns } = useCrudRef(currentRow)
|
const { crudRef, crudOptions, columns } = useCrudRef(currentRow)
|
||||||
|
|
||||||
const { visible, changeSort, changeStatus, open } = useOpenChangeModal(crudRef, currentRow)
|
const { visible, changeSort, changeStatus, open } = useOpenChangeModal(crudRef, currentRow)
|
||||||
// 暴露自己的open方法
|
// 暴露自己的open方法
|
||||||
defineExpose({ open })
|
defineExpose({ open })
|
||||||
|
|||||||
@@ -24,10 +24,14 @@ export default function (updateApiFunc: Function, updateTreeFunc: Function, widt
|
|||||||
return false
|
return false
|
||||||
} else {
|
} else {
|
||||||
// 成功 **变化**
|
// 成功 **变化**
|
||||||
const res = await updateApiFunc(formData.value.id, { project_id, ...formData.value })
|
try {
|
||||||
updateTreeFunc(res.data, project_id) // 刷新树节点信息
|
const res = await updateApiFunc(formData.value.id, { project_id, ...formData.value })
|
||||||
!(rightViewRef as any).value.refresh()
|
updateTreeFunc(res.data, project_id) // 刷新树节点信息
|
||||||
Message.success("修改成功")
|
!(rightViewRef as any).value.refresh()
|
||||||
|
Message.success("修改成功")
|
||||||
|
} catch (e) {
|
||||||
|
return false
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
const modalOptions = {
|
const modalOptions = {
|
||||||
|
|||||||
File diff suppressed because one or more lines are too long
1
cdTMP/版本记录防止升级错误.md
Normal file
1
cdTMP/版本记录防止升级错误.md
Normal file
@@ -0,0 +1 @@
|
|||||||
|
1. tinymce 7.9.1
|
||||||
Reference in New Issue
Block a user