Open rssidlowski opened 9 years ago
Need to do the following:
1) create an application in the mobile portal
2) incorporate the icon (to be provided by Tiffany by Wednesday)
3) Include description: Mobile tool for fire hydrant inspection and status tracking.
4) Create admin for access to portal. Note need to have different role for fire dept users. See #16.
5) Create report section
Create in dpwdev first.
Regarding 4 - Are there multiple roles inside of the application? If so what are they?
5 - Do you mean reports on the portal page?
Just two roles: fire dept and non-fire dept. Yes reports on the portal page - similar to what we have for PST.
Do you mean the PST reports in the Activity Manager? There are no PST reports in the portal - http://dpwdev.baltimorecity.gov/water/portal/index.aspx#reports
Sorry, yes in the activity manager.
Cool, is there a list of the different reports you can point me to? Also, what role do you want me to give that list of users? Fire-Dept or Non-Fire-Dept. They can only have one
Here is the list of reports - there are issues for each: 1) Hydrant Inspection Detail 2) Inspections by Date Range 3) Inspections by Organization and Date Range
Is the role for Reports handled separately (under DPW Activity Manager)? If so, create Hyd Reports. Not sure what you mean by only having one role and how it relates to the report role. I thought they were separate and we'd have mobile application role: fire dept and non fire dept and one role for Hyd reports.
Yes there will be two roles for the mobile app - Non-Fire-Dept and Fire-Dept. Separately there will be a role to access the reports in the Activity Manager.
For the list of users that you gave me at the top of this issue, do you want these users added to the mobile app, reports, or both? If you want to give them access to the mobile app, I'll need to give them either the Fire-Dept role or the Non-Fire-Dept role.
Give these users fire-dept and report: Regina, Heidi, Joe Murk give these users non-fire dept and report: Marian Batton Amy Purves Give these users only non-fire dept Dave McSpaden
All in the dev environment:
http://dpwdev.baltimorecity.gov/water/adminwebapi/api/roles/check_user?appname=hydrants
which will return a response like this -
{"success":true,"username":"joe.murk","roletype":"fire-dept","fullname":"Joe Murk","title":"GIS Consultant"}
You'll also want to use something like this in the index.aspx.cs file to reject users who don't have access to the app protected void Page_Load(object sender, EventArgs e)
{
string username = User.Identity.Name.ToLower();
if (username.Contains("\\"))
{
string[] userSplit = username.Split('\\');
username = userSplit[1];
}
string curl = System.Configuration.ConfigurationManager.AppSettings["checkrolURL"] + username;
Uri uri = new Uri(curl);
System.Net.HttpWebRequest request = (System.Net.HttpWebRequest)System.Net.WebRequest.Create(uri);
string un = System.Configuration.ConfigurationManager.AppSettings["username"];
string pa = System.Configuration.ConfigurationManager.AppSettings["password"];
request.Credentials = new NetworkCredential(un, pa);
request.Method = WebRequestMethods.Http.Get;
HttpWebResponse response = (System.Net.HttpWebResponse)request.GetResponse();
StreamReader reader = new StreamReader(response.GetResponseStream());
string tmp = reader.ReadToEnd();
if (!tmp.ToLower().Contains("hydrants"))
{
string portalpage = System.Configuration.ConfigurationManager.AppSettings["portalpage"];
Response.Redirect(portalpage);
}
response.Close();
}
Similar to what was done for PST need to add the mobile Hydrant Inspection application to the City's mobile framework. Grant access to the following people so they may access the application: Dave McSpaden Marian Batton Amy Purves Regina Sidlowski Heidi Hammel Joe Murk