-
Notifications
You must be signed in to change notification settings - Fork 6
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Managed max attachments&change bgColor&when get error add focus&make …
…btn disable
- Loading branch information
1 parent
e3c11e0
commit e4536bf
Showing
12 changed files
with
134 additions
and
131 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
20 changes: 20 additions & 0 deletions
20
...eStyle/Resource/BaseAssets.xcassets/Colors/SecondaryLightTextColor.colorset/Contents.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
{ | ||
"colors" : [ | ||
{ | ||
"color" : { | ||
"color-space" : "srgb", | ||
"components" : { | ||
"alpha" : "0.600", | ||
"blue" : "0x00", | ||
"green" : "0x00", | ||
"red" : "0x00" | ||
} | ||
}, | ||
"idiom" : "universal" | ||
} | ||
], | ||
"info" : { | ||
"author" : "xcode", | ||
"version" : 1 | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
38 changes: 0 additions & 38 deletions
38
functions/src/contact_support_service/contact_support_service.ts
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,48 @@ | ||
/* eslint-disable */ | ||
|
||
import {MailService} from "../mail/mail_service"; | ||
|
||
export class FeedbackService { | ||
private mailService: MailService; | ||
|
||
constructor(mailService: MailService) { | ||
this.mailService = mailService; | ||
} | ||
|
||
async onFeedbackCreated(support: any): Promise<any> { | ||
let body = "Feedback request created\n\n"; | ||
|
||
for (const key of Object.keys(support)) { | ||
let value = support[key]; | ||
|
||
// Check if the value is a Date object or has to be formatted & Convert created_at to local (IST) time | ||
if (key === "created_at" && typeof value === "object") { | ||
const date = new Date(value.seconds * 1000); // Convert Firebase Timestamp to Date | ||
value = date.toLocaleString("en-IN", { | ||
timeZone: "Asia/Kolkata", // Set timezone to IST | ||
year: "numeric", | ||
month: "long", | ||
day: "numeric", | ||
hour: "2-digit", | ||
minute: "2-digit", | ||
second: "2-digit", | ||
hour12: true, | ||
}); | ||
} | ||
|
||
// If the value is attachment urls separate them with a line break | ||
if (key === "attachment_urls" && Array.isArray(value)) { | ||
value = value.join("\n"); // Each URL in a new line | ||
} | ||
|
||
body += `${key}: ${value}\n`; | ||
} | ||
|
||
await this.mailService.sendEmail( | ||
["[email protected]"], | ||
"[email protected]", | ||
"Splito: Feedback Request Created", | ||
body, | ||
); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.