opened
friedaxvictoria
Before: The user could only view their bookmarked people on the dashboard.

Now: User can switch between their team and bookmarks. If the user doesn't have any bookmarks, the dashboard will automatically display the team and next to the dashboard button it says how to bookmark somebody. Otherwise, the bookmarks are the default view. If the user isn't logged in, there won't be the option to look at the team. 

Open question: Currently, the team is displayed in the following order: supervisor, assistents, employees, and learners. Should we add subheadings to showcase the different groups or leave it the way it is now?
feat(dashboard): Show Team on Dashboard
issue
created
paule96
there is a bug. If you navigate direct to https://pr-592.demo-phonebook.me/en/dashboard nothing is to see.
comment
created
DanielHabenicht
already mentioned in my comments ;)
comment
created
paule96
/azp run T-Systems-MMS.phonebook-preview
comment
created
paule96
sad demo broken. :) So I can't check the stuff..
comment
created
friedaxvictoria
For some reason the mock user doesn't work in the preview. The id that I used is a person and can be found in the preview but unfortunately it doesn't register as the user which is the reason why you can't see the team...
comment
created
friedaxvictoria
@DanielHabenicht Do you know how I can define a Mock UserTreeNode[] and not a UserTreeNode to compare with the Mock Person's OrgUnit?
comment
created
DanielHabenicht
Just use `Partial<UserTreeNode>`
comment
created
friedaxvictoria
To use it in getNodeForUser(user, organigram, 0), the organigram needs to be a UnitTreeNode[]. It doesn't accept Partial <UnitTreeNode>.
comment
created
DanielHabenicht
Then just cast it to UserTreeNode:

Your Object `as UserTreeNode[]`
comment
created
friedaxvictoria
Doesn't really work either. The only version that isn't an error is organigram: UnitTreeNode[] = []. I don't know whether that will work though because there is an error with the user as well. I copied a mock person's data and the data itself seems to be fine but apparently the Person is missing properties (isLearner, isSupervisor, isAssistent, isOfStatus). However, these 'properties' are functions from Person.ts and I can't add them to the Mock Person.
comment
created
paule96
/azbot
comment
created
paule96
/az
comment
created
mschwrdtnr
/azp run T-Systems-MMS.phonebook-preview
comment
created
paule96
This stuff is broken?

![image](https://user-images.githubusercontent.com/11291885/80919156-d0f42d80-8d68-11ea-985a-28020fdd2b82.png)
comment
created
paule96
also this switch doesn't working:

![image](https://user-images.githubusercontent.com/11291885/80919162-dea9b300-8d68-11ea-8bcb-f727de22d7e8.png)
comment
created
friedaxvictoria
@paule96 My cards aren't broken. There is a bit of an issue with the small cards, though. I'll see what I can do about that. 
The switch only works for the booksmarks so far. Should we implement it for the team as well @DanielHabenicht?
comment
created
friedaxvictoria
The Layout switch should now be working for the team as well. If you don't want that we can change it back although I would hide the button when the team is on display if this is the case. Otherwise, I think it would get to confusing. 

The cards also shouldn't spread out anymore. Furthermore, I had to add another if-statement to the organigram.service.ts since it only checked the first node of every depth. If the user is in the second or third node, it would return null. @DanielHabenicht
comment
created
paule96
no it's looks good 👍 I will start reviewing this code to night.
comment
created
DanielHabenicht
@friedaxvictoria waiting for merge
comment
created
DanielHabenicht
do you? @paule96
comment
created
friedaxvictoria
The function getUnitTreeById() has been added and it works when the UnitTreeNodes have been loaded. At the moment, the dashboard is finished loading before the UnitTreeNodes are. Therefore, the getUnitTreeById() is emty and doesn't return the user's UnitTreeNode. It is just a matter of getting the nodes before returning the dashboard.
comment
created
DanielHabenicht
forgot to push functions are still not there
comment
created
friedaxvictoria
I added the function and deleted some imports. However, I can’t check in localhost whether everything is all right because I can’t seem to get localhost to work in my browser...
comment
created
DanielHabenicht
/azp run T-Systems-MMS.phonebook-preview
comment
created
mschwrdtnr
@paule96 Please test it again locally
comment
created
DanielHabenicht
/azp run T-Systems-MMS.phonebook-preview
comment
created
paule96
/azp run T-Systems-MMS.phonebook-preview
comment
created
DanielHabenicht
Preview is not working at the moment ;(
comment
created
DanielHabenicht
/azp run T-Systems-MMS.phonebook-preview
comment
<samp>
Azure Pipelines successfully started running 1 pipeline(s).<br>

</samp>
This message directly preceded comment from bot *azure-pipelines[bot]* by author *paule96*:
/azp run T-Systems-MMS.phonebook-preview
Preview Environment ready at https://pr-592.demo-phonebook.me
This message directly preceded comment from bot *mmsgithub-ci* by author *paule96*:
sad demo broken. :) So I can't check the stuff..
<samp>
Azure Pipelines successfully started running 1 pipeline(s).<br>

</samp>
This message directly preceded comment from bot *azure-pipelines[bot]* by author *mschwrdtnr*:
/azp run T-Systems-MMS.phonebook-preview
Preview Environment ready at https://pr-592.demo-phonebook.me
This message directly preceded comment from bot *mmsgithub-ci* by author *DanielHabenicht*:
@friedaxvictoria waiting for merge
<samp>
Azure Pipelines successfully started running 1 pipeline(s).<br>

</samp>
This message directly preceded comment from bot *azure-pipelines[bot]* by author *DanielHabenicht*:
/azp run T-Systems-MMS.phonebook-preview
<samp>
Azure Pipelines successfully started running 1 pipeline(s).<br>

</samp>
This message directly preceded comment from bot *azure-pipelines[bot]* by author *DanielHabenicht*:
/azp run T-Systems-MMS.phonebook-preview
<samp>
Azure Pipelines successfully started running 1 pipeline(s).<br>

</samp>
This message directly preceded comment from bot *azure-pipelines[bot]* by author *paule96*:
/azp run T-Systems-MMS.phonebook-preview
<samp>
Azure Pipelines successfully started running 1 pipeline(s).<br>

</samp>
This message directly preceded comment from bot *azure-pipelines[bot]* by author *DanielHabenicht*:
/azp run T-Systems-MMS.phonebook-preview
This message directly preceded comment from bot *azure-pipelines[bot]* by author *paule96*:
/azp run T-Systems-MMS.phonebook-preview
This message directly preceded comment from bot *mmsgithub-ci* by author *paule96*:
sad demo broken. :) So I can't check the stuff..
This message directly preceded comment from bot *azure-pipelines[bot]* by author *mschwrdtnr*:
/azp run T-Systems-MMS.phonebook-preview
This message directly preceded comment from bot *mmsgithub-ci* by author *DanielHabenicht*:
@friedaxvictoria waiting for merge
This message directly preceded comment from bot *azure-pipelines[bot]* by author *DanielHabenicht*:
/azp run T-Systems-MMS.phonebook-preview
This message directly preceded comment from bot *azure-pipelines[bot]* by author *DanielHabenicht*:
/azp run T-Systems-MMS.phonebook-preview
This message directly preceded comment from bot *azure-pipelines[bot]* by author *paule96*:
/azp run T-Systems-MMS.phonebook-preview
This message directly preceded comment from bot *azure-pipelines[bot]* by author *DanielHabenicht*:
/azp run T-Systems-MMS.phonebook-preview