-
Notifications
You must be signed in to change notification settings - Fork 0
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Disable red pin for Viewer Work Order Details page #104
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
knack/iframeMapMessenger.js
Outdated
@@ -34,7 +34,7 @@ | |||
// Add React app as iframe if iframe doesn't already exist | |||
if ($(myView + " #mapIFrame").length === 0) { | |||
$( | |||
'<iframe src="https://atd-geo-knack-ui.netlify.com/" frameborder="0" scrolling="yes" id="mapIFrame" \ | |||
'<iframe src="https://localhost:9001/" frameborder="0" scrolling="yes" id="mapIFrame" \ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't think we want this referencing localhost in prod right @mddilley?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Right now in the knack js code (index.js), it references the "https://dnb4pix4gcpf6.cloudfront.net/atd-knack-signs-markings/98_marker_render/iframeMapMessenger.js". Do we need to update that?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good catch! Just changed and pushed. I'll update the Knack JS in builder with the latest from master after merging this branch.
@@ -368,6 +369,10 @@ export default class SelectLocation extends Component { | |||
|
|||
switch (data.message) { | |||
case "SIGNS_API_REQUEST": | |||
// Use workOrderDetailsViewable state to disable red pin and pulse if user is Viewer role | |||
if (data.view === "view_2619") { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice, this is pretty clever. Kinda of a hard-coded hack but let's count our wins and never talk about this again.
Closes #103