Evening All,
In my survey table > survey view > survey_Form I have two expressions that enable the branch number ‘buttons’ to show the most recent pin position & background base image for each branch. I can move an existing pin here or drop a new pin - no problem.
The issue:
If I browse to a new floor plan and drop a new pin, the survey_Form remembers the XY position and image from my expression and does not show the new background image for the new floor plan where I dropped the new pin.
This short clip may help?
I think the problem lies in my expression which is not accounting for the new floor plan background image or pin location details?
.
Initial Value formula for column [position] (XY)
IFS(
CONTEXT("View") <> "survey_Form",
"50, 50",
AND(
CONTEXT("View") = "survey_Form",
[survey_type] = "Node"
),
LOOKUP(
MAX(
SELECT(
survey[_ROWNUMBER],
AND(
[_THISROW].[select_asset_type] = [select_asset_type],
[_THISROW].[asset_name] = [asset_name],
[surveyor_email] = USEREMAIL(),
[survey_type] = "Node"
))),
"survey","_ROWNUMBER","position"
),
AND(
CONTEXT("View") = "survey_Form",
[survey_type] = "Cable",
IN(
[survey_branch_number],
[survey_branch_numbers]
)),
LOOKUP(
MAX(
SELECT(
survey[_ROWNUMBER],
AND(
[_THISROW].[survey_branch_number] = [survey_branch_number],
[surveyor_email] = USEREMAIL(),
[survey_type] = "Cable"
))),
"survey","_ROWNUMBER","position"
)
)
BaseImage (Text) expression for Background image for the XY coordinates:
IFS(
CONTEXT("View") <> "survey_Form",
[floorplans_id].[Floorplan_URL],
AND(
CONTEXT("View") = "survey_Form",
[survey_type] = "Node"
),
LOOKUP(
MAX(
SELECT(
survey[_ROWNUMBER],
AND(
[_THISROW].[select_asset_type] = [select_asset_type],
[_THISROW].[asset_name] = [asset_name],
[surveyor_email] = USEREMAIL(),
[survey_type] = "Node"
))),
"survey","_ROWNUMBER","custom_url"
),
AND(
CONTEXT("View") = "survey_Form",
[survey_type] = "Cable",
IN(
[survey_branch_number],
[survey_branch_numbers]
)),
LOOKUP(
MAX(
SELECT(
survey[_ROWNUMBER],
AND(
[_THISROW].[survey_branch_number] = [survey_branch_number],
[surveyor_email] = USEREMAIL(),
[survey_type] = "Cable"
))),
"survey","_ROWNUMBER","custom_url"
)
)
.
I forgot to mention that “custom_url” used in the above lookup is a VC that calls the background image URL using… [floorplans_id].[Floorplan_URL]
Thanks…
Hi @Jake_Naude first of all: your App looks wonderful
I also saw bugs like that. When I open a Map View from a XY map it changes the background image to the one, I recently opened. When I go back and open the Map View again, the right background image appears.
Do you get the right Background Image after reopening the form, or after syncing the App?
@hugheshilton seems to be the right person for that
Hi @Fabian,
Thanks. Yes, occasionally I get exactly the same thing and I find that closing and re-opening the form then shows the right map.
The inter-dependencies in the expressions for my form were getting a little complicated and crazy so I’ve worked around the issue by simplifying the form and letting another view (branches) do the heavy lifting.
Cheers…
User | Count |
---|---|
41 | |
27 | |
26 | |
20 | |
13 |