forked from Yara724/api
Removed unncessary data from PDF
This commit is contained in:
@@ -25,6 +25,7 @@ const SKIP_FLATTEN_KEYS = new Set([
|
||||
"confirmation",
|
||||
"inquiries",
|
||||
"raw",
|
||||
"source",
|
||||
]);
|
||||
|
||||
type ReportRecord = Record<string, unknown>;
|
||||
@@ -39,6 +40,7 @@ type ReportParty = ReportRecord & {
|
||||
|
||||
function asString(value: unknown): string | undefined {
|
||||
if (value === undefined || value === null || value === "") return undefined;
|
||||
if (typeof value === "boolean") return value ? "بله" : "خیر";
|
||||
if (value instanceof Date) {
|
||||
const [d, t] = toJalaliDateAndTime(value);
|
||||
return `${d} ${t}`;
|
||||
|
||||
Reference in New Issue
Block a user