hello my name is Todd Baginski I'm a Microsoft MVP and the CTO of canvas
consulting and this video I'm going to show you how to install and setup the
expense report power apps sample alright let's get started to install and
configure the expense report power app sample you're going to follow the
instructions you see on my screen here these instructions will be posted to
Doc's Microsoft comm where you will be viewing them when you go through this
process this process takes about 10 to 15 minutes to complete and you don't
have to write any code to do it when we're done we will have the expense
report power app sample like you see right here installed as well as the
supporting lists and connections that allow it to work in order to do this you
need to first accomplish what is in the prerequisites section by signing up for
power ups clicking the link that you see in the instructions will take you to the
page where you can sign up for a free trial after you've signed up for the
power ups free trial the first thing you need to do is create the expenses and
the line items SharePoint lists these two SharePoint lists are where the power
app stores the data that it works with the expenses list holds the expense
reports and the line items list holds the line items associated with the
expense reports the steps you see here show you how you can create these lists
after you've created the line items SharePoint list you're going to create
several different columns within that list here you can see the instructions
to do that we have the category column the cost date description and report ID
columns these columns are used by the power-up we also need to edit the title
column and turn off require that this column contains information to allow the
powerup to work creating the SharePoint list in the columns is an easy
tasks to do as you can see as you look at the steps here I've already created
them to expedite how long this video takes to watch here is my expenses list
and here is my line items list after you have created the lists in the columns
the next thing you're going to do is download the expense report power up in
a web browser you will navigate to the URL that you will see here this URL will
probably be updated by the time you watch this video this URL is a link to
the zip file that contains the exported expense report power apt sample so go to
this link and download that file and save it to your computer now that you
save the exported expense report power up sample template the next thing you're
going to do is go create connections inside of power apps these connections
are going to be created ahead of time so that when we import the expense report
power up they are ready to choose from so that the installation for the power
out goes as fast as possible now I'll demonstrate how we create those
connections first you'll go to web power app's calm and go to the environment
where you'd like to put the app in this case I'm putting it in my environment
called demo next click the connections link then in the top right select new
connection we're going to be creating three connections here one for approvals
one for the office 365 outlook connection and one for our sharepoint
connection after you've clicked the new connection button first type in
approvals that will filter it down to allow you to find the approvals
connection once you have that click create and now you have your approval
connection created next in the textbox at the top or part of me click new
connection first again after you've clicked a new connection in the text box
at the top this time enter office 365 Outlook there is our office 365 Outlook
connection so we will hit create here it will prompt us to authenticate we will
select the count we wish to authenticate with and once we select that account
then we can click the Create button and our connection will be added the final
connection to add again I'm clicking new connection waiting for the new
connection page to appear in the search box at the top I'm going to type
SharePoint select the SharePoint connection in this case I'm connecting
directly to data in office 365 if you are connecting the data in an
on-premises SharePoint environment and have set up a gateway you will select
the second radio button here again I click create I pick the account I wish
to authenticate with after I have selected that account now my connection
is created now that I have all my connections created I'm ready to import
the power out the steps here in the documentation describe how this is done
I'm going to go through them now and show you how to do it first I'll go back
to web powerups calm and I will click the apps button then I will select
import package click the upload button and select the package that I downloaded
previously in this exercise
after the package is imported it will look like this what I need to do now is
double check my import setup steps for my app right here is my power out and
make sure that set to create is new I also need to check the flow associated
with this power app is set to create as new they should be by default for you
the next thing that I'm going to do is select my connection for SharePoint
right here I'm going to click on the red icon next to it and and then then the
connections list I'm going to select that connection I just created and click
Save I will do the same thing for approvals
as well as my office 365 outlook connection now that I have the import
package configured I'll click the import button here in the bottom right of the
screen to start the process it takes about a minute to import the package
when it's done you'll see the message at the top of the screen that indicates all
package resources were successfully imported if you scroll down you'll see
everything has a green checkmark to indicate success we're almost done
flipping back to my installation instructions I will skip down to the
next set of documentation on what we need to do here I'm going to configure
the power app to actually use the SharePoint lists that I created earlier
let me show you how that's done first I'll head back in my web browser to web
power Apps calm and here I will click the apps button now you can see the
expense report power up that you have successfully imported the next thing I
will do is head over to the right side of the screen click the ellipse and pick
edit on the web now wait for my powerup to load
it typically takes about a minute for the powerup to load here I can see the
different connections that I have and I will click the allow button that's going
to authenticate to those connections and give them permission to be used within
my power up
now that the powerup is loaded in the editor I will add the connections to
those SharePoint lists to do this I will go to the View menu and click it and
then select data sources I already see the data sources in here because I've
worked with this powerup if you see them as well what you're going to want to do
is first remove them these are going to be removing the connections to the
specific SharePoint lists after we've removed them like that then what we want
to do is click add data source pick new connection or you can select SharePoint
right here so I'll select my SharePoint connection and my recent sites list I'll
go to the site collection where I created the list my case it's the top
one in the list then what I will do is I will first
pick the expenses list and click connect that will create my data connection to
the expenses list we previously created the next thing I will do is repeat the
process and create new connections again to SharePoint for my line items list
that I previously created as well now our power app configuration is complete
I'll click the file button select save and after it is saved that I will
publish the powerup
once the powerup is published there's just one step left to do and that's to
modify the flow associated with this powerup to modify the flow associated
with the powerup I will first close the powerup that I'm
working with and head back to WebP our apps calm then I will select the flows
button like this next thing I need to do is go to the approve expense flow that
was imported along with my powerup click the ellipsis button or part of me click
the edit button to open the flow once the flow is edited are opened in the
editor mode I'm going to change some valuables in it to point it to the
SharePoint lists specific to my tenancy and site collection where I've created
them when the flow is loaded the first thing I'll do is click on the get items
action I will expand that action and here is where you will enter the URL to
the site collection where you created the expenses SharePoint list after you
add that URL you can use the drop down list here to select the expenses list
you created once you have that done go down to the condition section and expand
it like this expand the if conduct condition and click the change item
status to approve action to expand it as well perform the same steps you did
above here to put in the site address in the list name of the expenses list
finally click the change item status to open action and perform the same thing
here to edit the site address and list name once you've got that done you want
to click the update flow button in the top of the page
after you've saved your flow now you can play the power app click on the apps
link on the left of web stop our apps calm and then click on the expense
report power app to open it up you're now playing your power app and really
running it for the first time this is what the power app will look like once
it is loaded check out my video where I give you a tour of all the functionality
and how to use this powerup you can find a link to that video on the
documentation page where you learned how to set up and configure this powerup
thanks and I hope you enjoy this power out