feat: 客户页面改为站内查看存证和证书
This commit is contained in:
@@ -44,10 +44,17 @@ export function fetchAppInfo(): Promise<any> {
|
||||
return instance.get('/settings/public') as unknown as Promise<any>;
|
||||
}
|
||||
|
||||
export interface TraceCertificateRecord {
|
||||
text: string;
|
||||
digest: string;
|
||||
txHash: string;
|
||||
author: string;
|
||||
createdAt: string | null;
|
||||
}
|
||||
export interface TraceCertificateResult {
|
||||
status: 'NONE' | 'PENDING' | 'SUBMITTING' | 'CHECKING' | 'WAITING' | 'READY' | 'UNKNOWN' | 'FAILED';
|
||||
url: string | null;
|
||||
generatedAt: string | null;
|
||||
certificate: TraceCertificateRecord | null;
|
||||
}
|
||||
export function requestTraceCertificate(shortCode: string): Promise<TraceCertificateResult> {
|
||||
return instance.post(`/public/trace/${encodeURIComponent(shortCode)}/certificate`, {}) as unknown as Promise<TraceCertificateResult>;
|
||||
|
||||
Reference in New Issue
Block a user