From ccb19f88b2583c7dadb18b6b2e9571ec120c6c61 Mon Sep 17 00:00:00 2001 From: YM <479443481@qq.com> Date: 星期三, 24 四月 2024 22:34:38 +0800 Subject: [PATCH] 1 --- src/api/index.js | 372 +++++++++++++++++++++++++++++----------------------- 1 files changed, 208 insertions(+), 164 deletions(-) diff --git a/src/api/index.js b/src/api/index.js index e77eeec..eb5ef3c 100644 --- a/src/api/index.js +++ b/src/api/index.js @@ -1,222 +1,266 @@ -import req from '@/utils/request/req1.js' -import req1 from '@/utils/request/req1.js' -import qs from 'querystring' +import req from "@/utils/request/req1.js"; +import req1 from "@/utils/request/req1.js"; +import qs from "querystring"; // 娉ㄥ唽鐧诲綍 export const getaddLogin = (Obj) => { - return req1({ - url: '/account/register', - method: 'post', - data: Obj - }) -} + return req1({ + url: "/account/register", + method: "post", + data: Obj + }); +}; // 楠岃瘉鐮� /account/verifyCode export const getverifyCode = (req) => { - console.log(req, qs.encode(req), 'rrr'); - return req1({ - url: "/account/verifyCode", - method: "post", - data: req, - headers: { - 'Content-Type': 'multipart/form-data' - } - }) -} + console.log(req, qs.encode(req), "rrr"); + return req1({ + url: "/account/verifyCode", + method: "post", + data: req, + headers: { + "Content-Type": "multipart/form-data" + } + }); +}; // login 鐧诲綍 export const getLogin = (req) => { - console.log(req, qs.encode(req), 'rrr'); - return req1({ - url: "/account/verification", - method: "post", - data: req, - }) -} + console.log(req, qs.encode(req), "rrr"); + return req1({ + url: "/account/verification", + method: "post", + data: req + }); +}; // 鑾峰彇鐢ㄦ埛淇℃伅 export const getUserInfo = () => { - return req1({ - url: "/account/getUserInfo", - method: "post", - }) -} + return req1({ + url: "/account/getUserInfo", + method: "post" + }); +}; // 閲嶇疆瀵嗙爜 export const getRestPassword = (Obj) => { - return req1({ - url: '/account/resetPassword', - method: 'post', - data: Obj - }) -} + return req1({ + url: "/account/resetPassword", + method: "post", + data: Obj + }); +}; // 閫�鍑虹櫥褰� export const getlogout = () => { - return req1({ - url: "/account/logout", - method: "post", - }) -} + return req1({ + url: "/account/logout", + method: "post" + }); +}; // 淇敼瀵嗙爜 export const getchangePassword = (obj) => { - return req1({ - url: "/account/changePassword", - method: "post", - data: obj - }) -} + return req1({ + url: "/account/changePassword", + method: "post", + data: obj + }); +}; -// +// // 浜虹墿鐩稿叧鎺ュ彛鐨勬暟鎹緭鍑� export const getdataOutput = () => { - return req1({ - url: "/person/dataOutput", - method: "post", - }) -} + return req1({ + url: "/person/dataOutput", + method: "post" + }); +}; // 浜虹墿鐩稿叧鐨� 鐑棬鎼滅储 export const getHotSearch = () => { - return req1({ - url: '/person/hotSearch', - method: 'post' - }) -} + return req1({ + url: "/person/hotSearch", + method: "post" + }); +}; // 浜虹墿鐩稿叧鐨� 鏉ユ簮 -export const getSource = (id) => { - return req1({ - url: '/person/source', - method: 'post', - data: id - }) -} -// 浜虹墿鐩稿叧鐨� 涓汉鏃剁┖鍦板浘 -export const getSpaceTime = (id) => { - return req1({ - url: '/person/spaceTime', - method: 'post', - data: id - }) -} +export const getSource = (data) => { + return req1({ + url: "/person/source", + method: "post", + data: data + }); +}; +// 浜虹墿鐩稿叧鐨� 涓汉鏃剁┖鍦板浘 +export const getSpaceTime = (data) => { + return req1({ + url: "/person/spaceTime", + method: "post", + data: data + }); +}; // 鍖诲浜虹墿鐭ヨ瘑搴撶殑鐩稿叧鍥捐〃 -export const getImages = (id) => { - return req1({ - url: '/person/images', - method: 'post', - data: id - }) -} +export const getPersonImages = (data) => { + return req1({ + url: "/person/images", + method: "post", + data: data + }); +}; +// 鍖诲浜虹墿鐭ヨ瘑搴� 涓汉浜嬭抗 +export const getPersonBiog = (data) => { + return req1({ + url: "/person/biog", + method: "post", + data: data + }); +}; +// 鍖诲浜虹墿鐭ヨ瘑搴� 浜虹墿鍏崇郴 +export const getPersonRelationAtSchool = (data) => { + return req1({ + url: "/person/personRelationAtSchool", + method: "post", + data: data + }); +}; + // 鍖诲浜虹墿鐭ヨ瘑搴� 钁楄堪 -export const getWritings = (id) => { - return req1({ - url: '/person/writings', - method: 'post', - data: id - }) -} +export const getPersonWritings = (data) => { + return req1({ + url: "/person/writings", + method: "post", + data: data + }); +}; // 鍖诲浜虹墿鐭ヨ瘑搴� 浜虹墿璇︽儏 export const getPersonInfo = (Obj) => { - return req1({ - url: '/person/getPersonInfo', - method: 'post', - data: Obj - }) -} -// 鍖诲浜虹墿鐭ヨ瘑搴� 鍩虹妫�绱� -export const getFuzzySearch = (Obj) => { - console.log(Obj, 'sss'); - return req1({ - url: '/person/fuzzySearch?keyword=' + Obj, - method: 'post', - // data:Obj - }) -} + return req1({ + url: "/person/getPersonInfo", + method: "post", + data: Obj + }); +}; +// 鍖诲浜虹墿鐭ヨ瘑搴� 鍩虹妫�绱� +export const getFuzzySearch = (requestData) => { + return req1({ + url: "/person/fuzzySearch?keyword="+requestData?.keyword, + method: "post", + }); +}; -// 鍖诲浜虹墿鐭ヨ瘑搴� 楂樼骇妫�绱� +// 鍖诲浜虹墿鐭ヨ瘑搴� 楂樼骇妫�绱� export const getAdvanceSearch = (Obj) => { - return req1({ - url: '/person/advanceSearch', - method: 'post', - data: Obj - }) -} + return req1({ + url: "/person/advanceSearch", + method: "post", + data: Obj + }); +}; // 涓浗鍦板煙鍦拌氨妫�绱汉鐗� -export const getRetrieval = (dynastyNumber, name) => { - return req1({ - url: '/person/retrieval', - method: 'post', - data: { - dynasty: dynastyNumber, - keyword: name - } - }) -} +export const getRetrieval = (requestData) => { + return req1({ + url: "/person/retrieval", + method: "post", + data: { + keyword: requestData?.keyword || "", + dynasty: requestData?.dynasty || "" + } + }); +}; // 鍖诲浜虹墿鐭ヨ瘑搴� + +// 涓栧尰浼犳壙 +export const inheritMedicalList = (requestData) => { + return req1({ + url: "/inheritMedical/list", + method: "post", + data: requestData + }); +}; +export const inheritMedicalSataStatistics = (requestData) => { + return req1({ + url: "/inheritMedical/dataStatistics", + method: "post", + data: requestData + }); +}; +export const inheritMedicalCultureList = (requestData) => { + return req1({ + url: "/inheritMedical/cultureList", + method: "post", + data: requestData + }); +}; +export const inheritMedicalRelationList = (requestData) => { + return req1({ + url: "/inheritMedical/relationList", + method: "post", + data: requestData + }); +}; // 妫�绱㈤〉 // 鍩虹銆侀珮绾ф绱� ------------------------------ -export const getPList = (person) => { - return req1({ - url: '/person/list', - method: 'post', - data: person - }) -} +export const getPersonList = (data) => { + return req1({ + url: "/person/list", + method: "post", + data: data + }); +}; // 妫�绱㈡暟鎹埌鍑� export const getPDownload = () => { - return req1({ - url: '/person/download', - method: 'post' - }) -} + return req1({ + url: "/person/download", + method: "post" + }); +}; // -------------------------P - - - // 鍖讳簨鍒跺害 // 鏁版嵁缁熻 export const getDataStatistics = () => { - return req1({ - url: '/medical/dataStatistics', - method: 'post' - }) -} + return req1({ + url: "/medical/dataStatistics", + method: "post" + }); +}; // 鏌ヨ export const getMedicalList = (data) => { - return req1({ - url: '/medical/list', - method: 'post', - data: data - }) -} + return req1({ + url: "/medical/list", + method: "post", + data: data + }); +}; // 璇︽儏 export const getMedicalDetails = (Obj) => { - return req1({ - url: '/medical/details', - method: 'post', - data: Obj - }) -} + return req1({ + url: "/medical/details", + method: "post", + data: Obj + }); +}; // 鍙栧�硷細RDF銆丯T銆乆ML銆丣SON export const getMedicalDataOutput = (Obj) => { - return req1({ - url: '/medical/dataOutput', - method: 'post', - data: Obj - }) -} + return req1({ + url: "/medical/dataOutput", + method: "post", + data: Obj + }); +}; // ----------- + + // 涓浗鍖诲浜虹墿鐭ヨ瘑搴� // 鏁版嵁缁熻 export const getPDataStatistics = () => { - return req1({ - url: '/person/dataStatistics', - method: 'post' - }) -} -// ---------------- \ No newline at end of file + return req1({ + url: "/person/dataStatistics", + method: "post" + }); +}; +// ---------------- -- Gitblit v1.9.1