Skip to content

Commit

Permalink
refactor: return timestamp fields
Browse files Browse the repository at this point in the history
  • Loading branch information
isaacknjama authored and okjodom committed Dec 10, 2024
1 parent 2d66ba6 commit 60e14eb
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 3 deletions.
3 changes: 2 additions & 1 deletion apps/shares/src/shares.service.ts
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,8 @@ export class SharesService {
);
const shares = allShares.map((share) => ({
quantity: share.quantity,
purchasedAtUnix: Number(share.createdAt),
createdAt: share.createdAt.toDateString(),
updatedAt: share.updatedAt.toDateString(),
}));

const shareSubscription = await this.getShareSubscrition({});
Expand Down
3 changes: 2 additions & 1 deletion libs/common/src/types/proto/shares.ts

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 2 additions & 1 deletion proto/shares.proto
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,8 @@ message ShareDetails {
// Number of shared purchased
int32 quantity = 1;
// Unix timestamp for when the shares were purchased
int64 purchasedAtUnix = 3;
string createdAt = 11;
optional string updatedAt = 12;
}

message ShareSubscriptionResponse {
Expand Down

0 comments on commit 60e14eb

Please sign in to comment.