cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Helper IV
Helper IV

Historical Comments into App

Hi Team,

 

I need to lean on your creative brains once again. 

 

My boss has asked to see the comment history for the particular order. So when the client logs in on the 18/04/2020, he wants to be able to see the comment history from 12/04/2020 and 14/04/2020. 

 

I am at a loss to get this. Any help you can offer would be delightful! 

 

Sharepoint IDOrderReleased?CommentDate
11234NoDo not Release, no PO12/04/2020
21234NoDo not Release, no GRN14/04/2020
31234YesRelease, PO and GRN received18/04/2020
1 ACCEPTED SOLUTION

Accepted Solutions

Hi @milky_bar_may ,

Firstly, let me correct you one point:

The gallery2 that you mentioned should be a display form which displays details of the item selected in gallery1.

Am I right?

Secondly, let me express my understanding about your issue.

Do you want these feathers?

1)Gallery1 display all items of this list

2)If you click one item in gallery1, you will view details in a display form

3)In this display form, you want to display all comments of this selected account.

4)Use a control to dynamic filter these comments.

 

Thirdly, if my assumptions are right, please follow my steps:

1)set gallery1's Items: your list name

2)set display form's Item: Gallery1.Selected

Insert a list box in the display form to display all comments of this selected account.

Insert a combo box to display all the dates that the selected account‘s time to comment. (datepicker can not only display specific dates.)

set the combo box's Items:

Filter(your listname,Account&Name=Gallery1.Selected.Account&Name)

 set the combo box's Primarytext:

Comment from Business

set the listbox's Items:

If(IsEmpty(ComboBox1.SelectedItems),
Filter(your listname,Account&Name=Gallery1.Selected.Account&Name),
ComboBox1.SelectedItems
  )

set the listbox's Value:

Comment from Business

 

Then the combo box will display the dates that the selected account's time to comment.

If you select no date in this combo box, the list box will display all comments that the selected account sent.

If you select dates in this combo box, the list box will only display the comments that the selected account sent in selected dates.

 

 

Best regards,

Community Support Team _ Phoebe Liu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

5 REPLIES 5
Super User III
Super User III

Insert, 2 DatePickers and  a Gallery.

On the Gallery Items put:
Filter(SharepointList, Date>=DatePicker1.SelectedDate&&Date<=DatePicker2.SelectedDate)

 

Whenever you select the 2 datepickers, it will be filtered.

 

If you like this post, give a Thumbs up. Where it solved your request, Mark it as a Solution to enable other users find it.

 

 

Community Support
Community Support

Hi @milky_bar_may ,

Do you want to get Comments based on date?

Could you tell me the data type of Comment field and Date field?

I assume that Comment field is text type and Date field is date type.

1)get  Comments of 12/04/2020 and 14/04/2020

insert a gallery, set its Items:

Filter(sharepointlistname,Date=DateValue("12/04/2020")||Date=DateValue("14/04/2020"))
//please replace with your listname

 set one label's Text inside the gallery:

ThisItem.Comment

 

2)get get  Comments based on dynamic date

insert a datepicker to choose date that you want

insert a gallery, set its Items:

 

Filter(sharepointlistname,Date=DatePicker1.SelectedDate)
//please replace with your listname

 

 set one label's Text inside the gallery:

 

ThisItem.Comment

 

In this situation, you could get comment based one date that you select in the datepicker. You could choose different dates in your datepicker.

 

 

Best regards,

Community Support Team _ Phoebe Liu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Hi @eka24 & @v-yutliu-msft ,

 

I really appreciate your comments and really like the idea of the dynamic date filtering. 

 

Hopefully if I explain further it will make my situation clearer. 

 

This is Gallery 1:

 

 

At the far right when they click 'More', this brings up Gallery 2.

 

The Items in Gallery 2 is equal to 'Gallery1.Selected'. 

 

 

 

Where it says 'Comment from Business' I need to bring in the historical comments. At the moment the comment section is a rectangular label, set with ThisItem.Commentfrombusiness. 

 

From what you are saying @v-yutliu-msft & @eka24,

 

I should replace this rectangular label with another Gallery. Where the title says, 'comment from business', I should put a date picker. 

 

This date pate picker should then filter the new Gallery to the comment on whatever date the comment was left. 

 

For this:

The Date Picker should only return the dates when a comment was left for the particular item. 

The gallery needs to display that comment of the selected item and the selected date. 

 

This is the most complex thing I have ever been asked for with PowerApps and is causing great anxiety. 

 

Any help would be greatly appreciated.

 

Thanks

D

Still banging my head against a wall on this one unfortunately!

 

Any help would be greatly appreciated

Hi @milky_bar_may ,

Firstly, let me correct you one point:

The gallery2 that you mentioned should be a display form which displays details of the item selected in gallery1.

Am I right?

Secondly, let me express my understanding about your issue.

Do you want these feathers?

1)Gallery1 display all items of this list

2)If you click one item in gallery1, you will view details in a display form

3)In this display form, you want to display all comments of this selected account.

4)Use a control to dynamic filter these comments.

 

Thirdly, if my assumptions are right, please follow my steps:

1)set gallery1's Items: your list name

2)set display form's Item: Gallery1.Selected

Insert a list box in the display form to display all comments of this selected account.

Insert a combo box to display all the dates that the selected account‘s time to comment. (datepicker can not only display specific dates.)

set the combo box's Items:

Filter(your listname,Account&Name=Gallery1.Selected.Account&Name)

 set the combo box's Primarytext:

Comment from Business

set the listbox's Items:

If(IsEmpty(ComboBox1.SelectedItems),
Filter(your listname,Account&Name=Gallery1.Selected.Account&Name),
ComboBox1.SelectedItems
  )

set the listbox's Value:

Comment from Business

 

Then the combo box will display the dates that the selected account's time to comment.

If you select no date in this combo box, the list box will display all comments that the selected account sent.

If you select dates in this combo box, the list box will only display the comments that the selected account sent in selected dates.

 

 

Best regards,

Community Support Team _ Phoebe Liu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

Helpful resources

Announcements
New Badges

New Solution Badges!

Check out our new profile badges recognizing authored solutions!

New Power Super Users

Congratulations!

We are excited to announce the Power Apps Super Users!

Power Apps Community Call

Power Apps Community Call: February

Did you miss the call? Check out the Power Apps Community Call here.

Microsoft Ignite

Microsoft Ignite

Join digitally, March 2–4, 2021 to explore new tech that's ready to implement. Experience the keynote in mixed reality through AltspaceVR!

Top Solution Authors
Top Kudoed Authors
Users online (39,444)