File tree Expand file tree Collapse file tree 3 files changed +8
-2
lines changed
generators/app/templates/app Expand file tree Collapse file tree 3 files changed +8
-2
lines changed Original file line number Diff line number Diff line change 3131< body >
3232
3333 < div id ="<%= root %> " class ="hidden ">
34- < h1 > Welcome to my add-in</ h1 >
34+ < h1 > Welcome to < span id =" <%= root %>-user " > my </ span > add-in</ h1 >
3535 </ div >
3636
3737</ body >
Original file line number Diff line number Diff line change @@ -40,6 +40,12 @@ geotab.addin.<%= root %> = function () {
4040 freshState . setState ( {
4141 hello : 'world'
4242 } ) ;
43+
44+ // getting the current user to display in the UI
45+ freshApi . getSession ( session => {
46+ document . querySelector ( '#<%= root %>-user' ) . textContent = `${ session . userName } 's` ;
47+ } ) ;
48+
4349 // show main content
4450 elAddin . className = '' ;
4551 } ,
Original file line number Diff line number Diff line change 11{
22 "name" : " generator-addin" ,
3- "version" : " 0.1.7 " ,
3+ "version" : " 0.1.8 " ,
44 "description" : " MyGeotab/Geotab Drive add-in generator" ,
55 "homepage" : " https://github.com/geotab/generator-addin" ,
66 "author" : {
You can’t perform that action at this time.
0 commit comments