diff --git a/cdTMP/package-lock.json b/cdTMP/package-lock.json index fbfbd8b..0ea81b5 100644 --- a/cdTMP/package-lock.json +++ b/cdTMP/package-lock.json @@ -13,6 +13,7 @@ "@tinymce/tinymce-vue": "^5.1.1", "@vueuse/core": "^10.1.2", "axios": "^1.4.0", + "axois": "^0.0.1-security", "crypto-js": "^4.1.1", "dayjs": "^1.11.7", "echarts": "^5.4.2", @@ -2015,6 +2016,11 @@ "proxy-from-env": "^1.1.0" } }, + "node_modules/axois": { + "version": "0.0.1-security", + "resolved": "https://registry.npmmirror.com/axois/-/axois-0.0.1-security.tgz", + "integrity": "sha512-8Nui4fwwyxHfjAfpDlg3Jt66EJA4i1D1eJch3D+wM/Oe+qhpyp7yfiszko/O5/adYu20wc37RG9/Eg8QIJHcvA==" + }, "node_modules/b-tween": { "version": "0.3.3", "resolved": "https://registry.npmmirror.com/b-tween/-/b-tween-0.3.3.tgz", diff --git a/cdTMP/package.json b/cdTMP/package.json index 0eb68c2..3404cad 100644 --- a/cdTMP/package.json +++ b/cdTMP/package.json @@ -16,6 +16,7 @@ "@tinymce/tinymce-vue": "^5.1.1", "@vueuse/core": "^10.1.2", "axios": "^1.4.0", + "axois": "^0.0.1-security", "crypto-js": "^4.1.1", "dayjs": "^1.11.7", "echarts": "^5.4.2", diff --git a/cdTMP/src/api/system/fragment.ts b/cdTMP/src/api/system/fragment.ts new file mode 100644 index 0000000..e0f7242 --- /dev/null +++ b/cdTMP/src/api/system/fragment.ts @@ -0,0 +1,15 @@ +import { request } from "@/api/request" +import { IFragSearchCondition } from "./types/fragmentTypes" +export class FragApi { + /** + * 根据参数获取文档片段 + * @returns 文档片段数组 + */ + static getFragList(params: IFragSearchCondition = {}) { + return request({ + url: "system/userField/getFragment", + method: "get", + params + }) + } +} diff --git a/cdTMP/src/api/system/types/fragmentTypes.ts b/cdTMP/src/api/system/types/fragmentTypes.ts new file mode 100644 index 0000000..b00919d --- /dev/null +++ b/cdTMP/src/api/system/types/fragmentTypes.ts @@ -0,0 +1,22 @@ +/** + * 所属产品文档名称的enum + */ +export enum FragBelongDoc { + dg = "大纲", + sm = "说明", + jl = "记录", + hsm = "回归说明", + hjl = "回归记录", + bg = "报告", + wtd = "问题单" +} + +/** + * 接口:文档片段查询条件 + */ +export interface IFragSearchCondition { + belongDocName?: FragBelongDoc + name?: string + isMain?: boolean + projectId?: number +} diff --git a/cdTMP/src/api/testmanage/project.js b/cdTMP/src/api/testmanage/project.js index a105858..baaf5ec 100644 --- a/cdTMP/src/api/testmanage/project.js +++ b/cdTMP/src/api/testmanage/project.js @@ -11,6 +11,16 @@ export default { params }) }, + /** + * 获取单个项目信息 + * @returns 单个项目信息 + */ + getProjectById(id) { + return request({ + url: "testmanage/project/findOneById/" + id, + method: "get" + }) + }, /** * 添加项目 * @returns @@ -43,5 +53,5 @@ export default { method: "delete", data }) - }, + } } diff --git a/cdTMP/src/env.d.ts b/cdTMP/src/env.d.ts index 9ec7276..e0c2065 100644 --- a/cdTMP/src/env.d.ts +++ b/cdTMP/src/env.d.ts @@ -1,2 +1,7 @@ declare module "@arco-design/web-vue/dist/arco-vue-icon" -declare module 'vue-virtual-scroller' +declare module "vue-virtual-scroller" +declare module "*.vue" { + import { DefineComponent } from "vue" + const component: DefineComponent<{}, {}, any> + export default component +} diff --git a/cdTMP/src/layout/components/navbar.vue b/cdTMP/src/layout/components/navbar.vue index 43c4ce5..6e7ec95 100644 --- a/cdTMP/src/layout/components/navbar.vue +++ b/cdTMP/src/layout/components/navbar.vue @@ -36,16 +36,6 @@ -