mirror of
https://github.com/filecoin-project/slate.git
synced 2024-11-10 13:14:04 +03:00
viewer: adds trusted relationships, subscriptions, and activity to the viewer model
This commit is contained in:
parent
06f02c7882
commit
785cecaeb6
@ -444,6 +444,8 @@ export default class ApplicationPage extends React.Component {
|
||||
};
|
||||
|
||||
render() {
|
||||
console.log({ viewer: this.state.viewer });
|
||||
|
||||
// NOTE(jim): Not authenticated.
|
||||
if (!this.state.viewer) {
|
||||
return (
|
||||
|
@ -19,6 +19,9 @@ export const getById = async ({ id }) => {
|
||||
let data = null;
|
||||
const slates = await Data.getSlatesByUserId({ userId: id });
|
||||
const keys = await Data.getAPIKeysByUserId({ userId: id });
|
||||
const subscriptions = await Data.getSubscriptionsByUserId({ userId: id });
|
||||
const activity = await Data.getActivityForUserId({ userId: id });
|
||||
const trusted = await Data.getTrustedRelationshipsByUserId({ userId: id });
|
||||
|
||||
let bytes = 0;
|
||||
user.data.library[0].children.forEach((each) => {
|
||||
@ -50,6 +53,9 @@ export const getById = async ({ id }) => {
|
||||
status: null,
|
||||
addrsList: null,
|
||||
info: null,
|
||||
subscriptions,
|
||||
activity,
|
||||
trusted,
|
||||
};
|
||||
} catch (e) {
|
||||
console.log(e);
|
||||
|
Loading…
Reference in New Issue
Block a user