DiscipleTools / DiscipleTools/disciple-tools-theme

Strategist Role should be able to run queries (and see totals)

Open
#1,745 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
PHP
Stars
48
Forks
66
PR merge metrics
No merged PRs in 30d

Description

**Is your feature request related to a problem? Please describe.**
As a User with a Strategist Role, I would like to run queries AND only receive `total` counts (without any contact PII/info)

**Describe the solution you'd like**
On a List Query, instead of returning counts AND post/record details:

```
{
"posts": [
...redacted record info
],
"total": 2
}
```

Only return the aggregate counts/total:

```
{
"total": 2
}
```

**Describe alternatives you've considered**
I attempted creating a Custom Role, but the options are not granular enough. Current approach is to use at least Dispatcher Role, but some partners have questioned why this level of access is required for reporting metrics.

**Additional context**
Current response with Strategist Role to the following query:

```
{{url}}/wp-json/dt-posts/v2/contacts?quick_button_meeting_complete[operator]=>&quick_button_meeting_complete[number]=5
```

```
{
"code": "search_viewable_post",
"message": "You do not have access to these",
"data": {
"status": 403
}
}
```

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.