From f6caf2b0a4502f2ba888b58a88ff7c7e409e40d0 Mon Sep 17 00:00:00 2001
From: zhangzengfei <zhangzengfei@smartai.com>
Date: 星期日, 31 七月 2022 15:05:05 +0800
Subject: [PATCH] 将put修改为post
---
src/Pool/BaseManageData.ts | 135 ++++++++++++++++++++++-----------------------
1 files changed, 66 insertions(+), 69 deletions(-)
diff --git a/src/Pool/BaseManageData.ts b/src/Pool/BaseManageData.ts
index 0a99a6a..b58422d 100644
--- a/src/Pool/BaseManageData.ts
+++ b/src/Pool/BaseManageData.ts
@@ -7,67 +7,64 @@
getTagList,
copy,
move
-} from "@/api/baseLibrary";
+} from "@/api/baseLibrary"
export default class BaseManageData {
- public syncTables: Array<object> = [];
- public localTables: Array<object> = [];
- public personList: Array<object>;
- public personId: string = "";
- public blackList: Array<object> = [];
- public selectBlacks: Array<object> = [];
- public whiteList: Array<object> = [];
- public selectWhites: Array<object> = [];
- public page: number;
- public size: number;
- public contentValue: string = "";
- public tableId: number;
- public orderName: string = "createTime";
- public orderType: string = "desc";
- public faceUrl: string = "";
- public threshold: number = 60;
- public total: number;
- public picUrl: string = "";
-
+ public syncTables: Array<object> = []
+ public localTables: Array<object> = []
+ public personList: Array<object>
+ public personId: string = ""
+ public blackList: Array<object> = []
+ public selectBlacks: Array<object> = []
+ public whiteList: Array<object> = []
+ public selectWhites: Array<object> = []
+ public page: number
+ public size: number
+ public contentValue: string = ""
+ public tableId: number
+ public orderName: string = "createTime"
+ public orderType: string = "desc"
+ public faceUrl: string = ""
+ public threshold: number = 60
+ public total: number
+ public picUrl: string = ""
constructor() {
- this.personList = [];
- this.page = 1;
- this.size = 10;
- this.total = 0;
+ this.personList = []
+ this.page = 1
+ this.size = 10
+ this.total = 0
}
cleanData() {
- this.personList = [];
- this.page = 1;
- this.size = 10;
- this.total = 0;
+ this.personList = []
+ this.page = 1
+ this.size = 10
+ this.total = 0
}
async querySyncTables() {
- const rsp: any = await getSyncTables({
-
- });
+ const rsp: any = await getSyncTables({})
if (rsp && rsp.success) {
this.syncTables.splice(0, this.syncTables.length)
- rsp.data.datalist.forEach(element => {
- this.syncTables.push((element as any))
- });
+ rsp.data.datalist.forEach((element) => {
+ this.syncTables.push(element as any)
+ })
}
}
async queryLocalTables() {
- const rsp: any = await getLocalTables({
-
- });
+ const rsp: any = await getLocalTables({})
if (rsp && rsp.success) {
this.localTables.splice(0, this.localTables.length)
- rsp.data.datalist.forEach(element => {
- this.localTables.push((element as any))
- });
+ rsp.data.datalist.forEach((element) => {
+ this.localTables.push(element as any)
+ })
}
}
async queryPersonList() {
+ this.cleanData()
+
const rsp: any = await getPersonList({
tableId: this.tableId,
page: this.page,
@@ -75,32 +72,30 @@
contentValue: this.contentValue,
orderType: this.orderType,
orderName: this.orderName
- });
+ })
if (rsp && rsp.success) {
this.personList.splice(0, this.personList.length)
- rsp.data.datalist.forEach(element => {
+ rsp.data.datalist.forEach((element) => {
let carUrls = element.carPicUrls.split(";")
element.carUrls = []
- carUrls.forEach(picUrl => {
+ carUrls.forEach((picUrl) => {
element.carUrls.push({ url: "/httpImage/" + picUrl })
- });
+ })
element.faceUrl = []
element.faceUrl.push({ url: "/httpImage/" + element.personPicUrl })
- this.personList.push((element as any))
- });
+ this.personList.push(element as any)
+ })
this.total = rsp.data.total
}
}
async queryPersonListByPhoto() {
- const rsp: any = await getPersonListByPhoto({
-
- });
+ const rsp: any = await getPersonListByPhoto({})
if (rsp && rsp.success) {
this.personList.splice(0, this.personList.length)
- rsp.data.datalist.forEach(element => {
- this.personList.push((element as any))
- });
+ rsp.data.datalist.forEach((element) => {
+ this.personList.push(element as any)
+ })
}
}
async searchPhotoFromBase() {
@@ -115,40 +110,44 @@
picUrl: this.picUrl
})
console.log("搴曞簱浠ュ浘鎼滃浘杩斿洖锛�", rsp)
- this.personList = [];
+ this.personList = []
if (rsp && rsp.success) {
- rsp.data.totalList.forEach(element => {
- this.personList.push((element as any))
- });
+ rsp.data.totalList.forEach((element) => {
+ this.personList.push(element as any)
+ })
console.log("鍒楄〃锛�", this.personList)
this.total = rsp.data.total
}
}
async queryTagList() {
- const rsp: any = await getTagList({});
+ const rsp: any = await getTagList({})
// console.log("tag杩斿洖鍊�: ",rsp)
if (rsp && rsp.success) {
// 鏀剧疆榛戠櫧鍚嶅崟 0涓虹櫧鍚嶅崟
this.blackList.length = 0
this.whiteList.length = 0
- rsp.data.forEach(i => {
- if (i.status === 0 && i.bwType === "0") { //鐧藉悕鍗�
- if (i.analyServerId === "") { //鍚屾搴�
- i.title = i.title + '(鍚屾搴�)'
+ rsp.data.forEach((i) => {
+ if (i.status === 0 && i.bwType === "0") {
+ //鐧藉悕鍗�
+ if (i.analyServerId === "") {
+ //鍚屾搴�
+ i.title = i.title + "(鍚屾搴�)"
this.whiteList.push(i)
} else {
this.whiteList.push(i)
}
}
- if (i.status === 0 && i.bwType === "1") { //榛戝悕鍗�
- if (i.analyServerId === "") { //鍚屾搴�
- i.title = i.title + '(鍚屾搴�)'
+ if (i.status === 0 && i.bwType === "1") {
+ //榛戝悕鍗�
+ if (i.analyServerId === "") {
+ //鍚屾搴�
+ i.title = i.title + "(鍚屾搴�)"
this.blackList.push(i)
} else {
this.blackList.push(i)
}
}
- });
+ })
}
}
async copyTo() {
@@ -167,7 +166,5 @@
const rsp: any = await move(param)
return rsp
}
- mounted() {
-
- }
-}
\ No newline at end of file
+ mounted() {}
+}
--
Gitblit v1.8.0