I want to create a script to shows in a Ui SplitLayoutPanel the data from a spreadsheet base on the user logged in the Google. I wrote something like this until now:
function doGet() {
var app = UiApp.createApplication();
var sPanel = app.createSplitLayoutPanel();
sPanel.addWest(app.createLabel('Hierarchy'), 100);
var handler=app.createClientHandler("MyHierarchy");
handler
sPanel.addNorth(app.createLabel('List of my Hierarchy'), 200);
sPanel.add(app.createLabel('Timesheet'));
sPanel.setHeight('100%').setWidth('100%');
app.add(sPanel);
return app;
}
function MyHierarchy() {
var app = UiApp.createApplication();
var ss=SpreadsheetApp.openById("id_of_the_Spreadsheet")
var user=Session.getActiveUser().getEmail();
return app;
}
In the spreadsheet i will have a list of employees and theirs respective managers (with their Google Apps email accounts). I want to filter the data based on the email of this managers. Any idea on how can i continue?