feat: 新增腾讯广告素材合规校验管理页面及接口
新增了腾讯图片/视频素材自动校验的完整业务页面,包含统计看板、素材列表管理、校验日志查询等功能,同时封装了对应的后端请求接口。
This commit is contained in:
158
src/api/ads/compliance/tencent/materialVerify.ts
Normal file
158
src/api/ads/compliance/tencent/materialVerify.ts
Normal file
@@ -0,0 +1,158 @@
|
|||||||
|
import request, { type RequestOptions } from '/@/utils/request';
|
||||||
|
|
||||||
|
export interface StatsParams {
|
||||||
|
pending?: number;
|
||||||
|
verified?: number;
|
||||||
|
rejected?: number;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface ImageMaterialItem {
|
||||||
|
id: number;
|
||||||
|
imageId: string;
|
||||||
|
accountId: string;
|
||||||
|
imageUsage?: string;
|
||||||
|
previewUrl?: string;
|
||||||
|
verifyStatus: string;
|
||||||
|
description?: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface VideoMaterialItem {
|
||||||
|
id: number;
|
||||||
|
videoId: string;
|
||||||
|
accountId: string;
|
||||||
|
previewUrl?: string;
|
||||||
|
verifyStatus: string;
|
||||||
|
description?: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface VerifyLogItem {
|
||||||
|
id: number;
|
||||||
|
materialType: string;
|
||||||
|
materialId: string;
|
||||||
|
accountId: string;
|
||||||
|
taskId?: string;
|
||||||
|
verifyStatus: string;
|
||||||
|
suggestion?: number;
|
||||||
|
requestParams?: string;
|
||||||
|
responseResult?: string;
|
||||||
|
errorMsg?: string;
|
||||||
|
createdAt: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface PageParams {
|
||||||
|
page: number;
|
||||||
|
pageSize: number;
|
||||||
|
status?: string;
|
||||||
|
accountId?: string;
|
||||||
|
materialType?: string;
|
||||||
|
verifyStatus?: string;
|
||||||
|
materialId?: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface ListResponse<T> {
|
||||||
|
code: number;
|
||||||
|
message: string;
|
||||||
|
data: {
|
||||||
|
list: T[];
|
||||||
|
total: number;
|
||||||
|
};
|
||||||
|
}
|
||||||
|
|
||||||
|
export interface StatsResponse {
|
||||||
|
code: number;
|
||||||
|
message: string;
|
||||||
|
data: StatsParams;
|
||||||
|
}
|
||||||
|
|
||||||
|
export function getImageStats(requestOptions?: RequestOptions) {
|
||||||
|
return request({
|
||||||
|
url: '/cid/material/verify/controller/stats-image',
|
||||||
|
method: 'get',
|
||||||
|
requestOptions,
|
||||||
|
}) as Promise<StatsResponse>;
|
||||||
|
}
|
||||||
|
|
||||||
|
export function getVideoStats(requestOptions?: RequestOptions) {
|
||||||
|
return request({
|
||||||
|
url: '/cid/material/verify/controller/stats-video',
|
||||||
|
method: 'get',
|
||||||
|
requestOptions,
|
||||||
|
}) as Promise<StatsResponse>;
|
||||||
|
}
|
||||||
|
|
||||||
|
export function getImageList(params: PageParams, requestOptions?: RequestOptions) {
|
||||||
|
return request({
|
||||||
|
url: '/cid/material/verify/controller/list-image',
|
||||||
|
method: 'get',
|
||||||
|
params,
|
||||||
|
requestOptions,
|
||||||
|
}) as Promise<ListResponse<ImageMaterialItem>>;
|
||||||
|
}
|
||||||
|
|
||||||
|
export function getVideoList(params: PageParams, requestOptions?: RequestOptions) {
|
||||||
|
return request({
|
||||||
|
url: '/cid/material/verify/controller/list-video',
|
||||||
|
method: 'get',
|
||||||
|
params,
|
||||||
|
requestOptions,
|
||||||
|
}) as Promise<ListResponse<VideoMaterialItem>>;
|
||||||
|
}
|
||||||
|
|
||||||
|
export function getVerifyLogList(params: PageParams, requestOptions?: RequestOptions) {
|
||||||
|
return request({
|
||||||
|
url: '/cid/material/verify/controller/list-log',
|
||||||
|
method: 'get',
|
||||||
|
params,
|
||||||
|
requestOptions,
|
||||||
|
}) as Promise<ListResponse<VerifyLogItem>>;
|
||||||
|
}
|
||||||
|
|
||||||
|
export function manualVerifyImage(data: { materialId: string }, requestOptions?: RequestOptions) {
|
||||||
|
return request({
|
||||||
|
url: '/cid/material/verify/controller/manual-verify-image',
|
||||||
|
method: 'post',
|
||||||
|
data,
|
||||||
|
requestOptions,
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
export function manualVerifyVideo(data: { materialId: string }, requestOptions?: RequestOptions) {
|
||||||
|
return request({
|
||||||
|
url: '/cid/material/verify/controller/manual-verify-video',
|
||||||
|
method: 'post',
|
||||||
|
data,
|
||||||
|
requestOptions,
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
export function pollImageResults(requestOptions?: RequestOptions) {
|
||||||
|
return request({
|
||||||
|
url: '/cid/yidun/callback/controller/poll-image-results',
|
||||||
|
method: 'post',
|
||||||
|
requestOptions,
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
export function pollVideoResults(requestOptions?: RequestOptions) {
|
||||||
|
return request({
|
||||||
|
url: '/cid/yidun/callback/controller/poll-video-results',
|
||||||
|
method: 'post',
|
||||||
|
requestOptions,
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
export function batchVerifyImage(requestOptions?: RequestOptions) {
|
||||||
|
return request({
|
||||||
|
url: '/cid/material/verify/controller/batch-verify-image',
|
||||||
|
method: 'post',
|
||||||
|
requestOptions,
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
export function batchVerifyVideo(requestOptions?: RequestOptions) {
|
||||||
|
return request({
|
||||||
|
url: '/cid/material/verify/controller/batch-verify-video',
|
||||||
|
method: 'post',
|
||||||
|
requestOptions,
|
||||||
|
});
|
||||||
|
}
|
||||||
1023
src/views/ads/compliance/tencent/index.vue
Normal file
1023
src/views/ads/compliance/tencent/index.vue
Normal file
File diff suppressed because it is too large
Load Diff
Reference in New Issue
Block a user