创建一个预先填充数据的MS PowerApps调查问卷。

huangapple go评论73阅读模式
英文:

Creating a MS PowerApps survey pre-populated with data

问题

目标是提供一个用于数据收集的年度调查。过去我们使用第三方基于网页的工具,但现在不允许使用。

我们有SharePoint和PowerApps可供分析师用户(如我)使用。我对访问Dataverse之类的限制并不完全确定。

假设员工艾丽斯和贝蒂在前一年为他们的客户账户完成了调查。艾丽斯为客户A1、A2完成了调查;贝蒂为客户B1、B2和B3完成了调查。

有没有一种方式...通过MS PowerApps环境...可以创建一个预先填写了去年回答的调查,并让艾丽斯和贝蒂在今年更新它?重要的是,艾丽斯和贝蒂不能看到彼此的客户信息。

谢谢 - 我只想知道我是否在走一条死胡同。我看过很多关于如何创建一个空白调查或一个测验的内容,但没有遇到过这些限制。

英文:

The objective is to provide an annual survey for data gathering. In the past we used third party web-based tools but these will not be allowed.

We do have SharePoint and PowerApps available to analyst users like myself. I am not 100% sure about limitations like access to Dataverse.

Assume that employees Alice and Betty have completed surveys in the prior year for their client accounts. Alice completed a survey for clients A1, A2; Betty completed a survey for clients B1, B2 and B3.

IS THERE A WAY...through the MS PowerApps environment...to create a survey pre-populated with last year's responses, and make it available to Alice and Betty for updating this year? It is important that Alice and Betty cannot see each other's client information.

Thanks - I just want to know if I'm going down a blind alley. I've seem plenty of "how to create a blank survey" or a "quiz" but nothing with these constraints.

答案1

得分: 1

一个简单、直接的方法是使用SharePoint列表作为后端:

  1. 您应该在SharePoint中实施行级安全性。将列表的高级设置配置为仅向用户显示他们自己的记录。
  2. 向您的应用程序添加一个表单以记录新的响应到列表中(FormMode = New)。
  3. 在表单屏幕的 .OnVisible 属性中创建一个上下文变量:UpdateContext({ varLastResponse: `Last(SurveyResponsesList) })。如果您在SharePoint上设置了高级设置,这将忽略其他用户的后续响应。
  4. 使用上下文变量来设置表单控件的默认属性。

这将为您提供一个预填充的表单,以提交新的响应。

在您的问题中,您提到了'update'。我几乎可以肯定您是指更新列表,而不是之前的响应,但以防万一:要更新最后的响应而不是创建新的响应,将FormMode设置为'Edit',并在Form.Item属性中使用上面提到的Last(SurveyResponsesList)公式。在这种情况下,无需设置控件的默认属性。

英文:

A simple, direct approach using a SharePoint List backend:

  1. You should implement the row level security in SharePoint. Set the list's advanced settings to display to the users only their own records.
  2. Add a form to your app to record a new response to the list (FormMode = New)
  3. In the form screen's .OnVisible property create a context variable: UpdateContext({ varLastResponse: Last(SurveyResponsesList) }). If you set the advanced settings on SharePoint this will ignore other users' posterior responses.
  4. Use the context variable to set the Default properties of the Form controls.

This will get you a prepopulated form to submit a new response.

In your question you wrote 'update'. I'm almost sure you meant updating the list, not the previous response, but just in case: To update the last response instead of creating a new one, set FormMode to 'Edit' and use the Last(SurveyResponsesList) formula from above in the Form.Item property. In this scenario there's no need to set the Default property for the controls.

huangapple
  • 本文由 发表于 2023年7月27日 19:49:44
  • 转载请务必保留本文链接:https://go.coder-hub.com/76779436.html
匿名

发表评论

匿名网友

:?: :razz: :sad: :evil: :!: :smile: :oops: :grin: :eek: :shock: :???: :cool: :lol: :mad: :twisted: :roll: :wink: :idea: :arrow: :neutral: :cry: :mrgreen:

确定