Hi Guys,
please help me to integrate/add the data on SharePoint list data with helpdesk app.
ClearCollect(
TicketList,
{
Id: "1",
Title: "Mouse",
Description: "Where is my mouse",
Category:"LAPTOP / PC Software",
PercentComplete: "0.9",
Priority: "HIGH",
AssignedTO: "THOMAS ANDERSEN",
TaskStatus: "COMPLETED",
Author: "ScottK@contoso.com",
Editor: "Scott Konersmann",
Created: "2/8/2018 3:29 PM",
Modified: "2/5/2018 3:29 PM"
}
);
how to save the data to sharepoint and call from the shasrepoint?
Solved! Go to Solution.
Hi @shebeerahmmed :
I think this link will help you a lot:
Share a site
Best Regards,
Bof
If this post helps, then please consider Accept it as the solution to help the other members find it
HI @shebeerahmmed :
Do you want to use SharePoint as your data source instead of Office365Users?
Could you tell me whether these fields you mentioned have any special requirements for the data type, or only need the program to run correctly.
I’ve made a test for your reference:
1\Add a list('SP TicketList')
I assume that the data type is configured in the following way.
Column (click to edit) | Type | |
Single line of text | ||
Single line of text | ||
Single line of text | ||
Single line of text | ||
Single line of text | ||
Single line of text | ||
Single line of text |
In addition,ID, Author, Editor, Modified, Created, Created By, Modified By are the default fields of SharePoint list, do not need us to customize
2\Modify the list
I have listed as many detailed steps as possible, but the actual operation is only to replace the data source and adjust some value reference. For specific operations, you can follow the guidance of APP Checker.
MyTicketsScreen(Screen):
MyTicketsScreenGallery-Items:
If(isAdmin,Sort('SP TicketList',ID,Descending),Sort(Filter('SP TicketList',Author.Email = MyProfile.Mail ),ID,Descending))
MyTicketsScreenGalleryId-Text:
ThisItem.ID
ViewTicketScreen(Screen):
ViewTicketScreenCanvas
ViewTicketScreenDataCard
ViewTicketScreenId-Text:
SelectedTicket.ID
ViewTicketScreenModifiedBy-Text:
Coalesce(First(Office365Users.SearchUser({searchTerm:Text(SelectedTicket.Editor.Email)})).DisplayName, SelectedTicket.Editor.Email)
ViewTicketScreenCreatedBy-Text:
Coalesce(First(Office365Users.SearchUser({searchTerm:Text(SelectedTicket.Author.Email)})).DisplayName, SelectedTicket.Author.Email)
CreateTicketScreen(Screen):
CreateTicketScreenCreateButton-Items:
Patch('SP TicketList',Defaults('SP TicketList'),{
Title:CreateTicketScreenTitleText.Text,
Priority: CreateTicketScreenPriorityDropDown.SelectedText.Value,
TaskStatus:"NOT STARTED",
PercentComplete: "0",
AssignedTO:"",
Description:CreateTicketScreenTaskDescription.Text,
Category:CreateTicketScreenCategoryDropDown.SelectedText.Value});
Reset(CreateTicketScreenTitleText);
Reset(CreateTicketScreenTaskDescription);
Reset(CreateTicketScreenCategoryDropDown);
Reset(CreateTicketScreenPriorityDropDown);
Navigate(ConfirmSubmitScreen,None)
ConfirmationDeleteScreen(Screen):
ConfirmationDeleteScreenDeleteButton-OnSelect:
Remove('SP TicketList',LookUp('SP TicketList',ID =TicketToDelete.ID));
Navigate(MyTicketsScreen,ScreenTransition.None)
EditTicketScreen(Screen):
EditTicketScreenCanvas
EditTicketScreenDataCard
EditTicketScreenHeaderTickerNumber-Text:
SelectedTicket.ID
EditTicketScreenHeaderTickerCreatedBy- Text :
Coalesce(First(Office365Users.SearchUser({searchTerm:Text(SelectedTicket.Author.Email)})).DisplayName, SelectedTicket.Author.Email)
EditTicketScreenHeaderTickerModifiedBy- Text :
Coalesce(First(Office365Users.SearchUser({searchTerm:Text(SelectedTicket.Editor.Email)})).DisplayName, SelectedTicket.Editor.Email)
EditTicketScreenUpdateButton-OnSelect:
If(isAdmin,
Patch(TicketList,LookUp(TicketList,Id=SelectedTicket.ID),{
Priority:EditTicketScreenPriorityDropDown.SelectedText.Value,
Category:EditTicketScreenCategoryDropDown.SelectedText.Value,
TaskStatus:EditTicketScreenStatusDropdown.SelectedText.Value,
PercentComplete:EditTicketScreenCompletedSlider.Value/100,
AssignedTO:AssignedToUserDisplayName,
Editor:MyProfile.Mail,
Modified:Now(),
Description:EditTicketScreenDescriptionInput.Text
}),
Patch(TicketList,LookUp(TicketList,Id = SelectedTicket.ID),{
Priority:EditTicketScreenPriorityDropDown.SelectedText.Value,
Category:EditTicketScreenCategoryDropDown.SelectedText.Value,
Editor:MyProfile.Mail,
Modified:Now(),
Description:EditTicketScreenDescriptionInput.Text
}
));
Reset(EditTicketScreenCompletedSlider);
Reset(EditTicketScreenStatusDropdown);
Navigate(MyTicketsScreen,None)
Best Regards,
Bof
@v-bofeng-msft can you please send me the zip file of the app?I am getting 56 errors after following your steps
Hi @shebeerahmmed :
Sorry, I cannot do this due to internal regulations.
I suggest you check the name of your datasource.
The key is to replace all "TicketList" in the app with new data sources.
Best Regards,
Bof
Hi @shebeerahmmed :
These are all reference errors(Name isn't vaild), and I cannot judge which field reference is wrong through the screenshot.
Could you show me a screenshot of the wrong code?It is best to have a screenshot of your SP List.
Best Regards,
Bof
Hi @shebeerahmmed :
Attachment1:
1\I notice you use "Categary" insteard of "Catagary".But in your datasourc,the cloumn name is "Catagary".
2\I think ".Value" is unnecessary, it caused the second error
Try this code:
SelectedTicket.Catagory
Attachment2:
1\I notice you use "Categary" insteard of "Catagary".But in your datasourc,the cloumn name is "Catagary".
Try this code:
SelectedTicket.Catagory
Attachment3:
1\I notice you use "PercentComplete" insteard of "%Complete".But in your datasourc,the cloumn name is "%Complete".
Try this code:
SelectedTicket.'%Complete'
Best Regards,
Bof
Please check if they have access to your data source.
Best Regards,
Bof
If this post helps, then please consider Accept it as the solution to help the other members find it
User | Count |
---|---|
20 | |
13 | |
8 | |
5 | |
5 |
User | Count |
---|---|
33 | |
30 | |
15 | |
13 | |
9 |