Skip to content

[Behavioural_QC] Incomplete Forms Data Entry Type #9745

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

Open
wants to merge 2 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 12 additions & 0 deletions modules/behavioural_qc/jsx/tabs_content/incompleteForms.js
Original file line number Diff line number Diff line change
Expand Up @@ -172,6 +172,18 @@ class IncompleteForms extends Component {
),
},
},
{
label: 'Data Entry Type',
show: true,
filter: {
name: 'Data Entry Type',
type: 'select',
options: {
'FDE': 'First Data Entry (FDE)',
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think "SDE" has been the more common term in LORIS for the single data entry? Maybe add something to the LORIS meeting?

'DDE': 'Double Data Entry (DDE)',
},
},
},
{
label: 'DCCID',
show: true,
Expand Down
32 changes: 20 additions & 12 deletions modules/behavioural_qc/php/models/incompletedto.class.inc
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,13 @@ class IncompleteDTO implements \LORIS\Data\DataInstance,
*/
private $_instrument = '';

/**
* Data Entry Type (FDE or DDE)
*
* @var string
*/
private $_data_entry_type = '';

/**
* The candID
*
Expand Down Expand Up @@ -134,18 +141,19 @@ class IncompleteDTO implements \LORIS\Data\DataInstance,
public function jsonSerialize() : array
{
return [
'instrument' => $this->_instrument,
'candID' => $this->_candID,
'pscID' => $this->_pscID,
'visit' => $this->_visit,
'project' => $this->_project,
'cohort' => $this->_cohort,
'site' => $this->_site,
'id' => $this->_id,
'sessionID' => $this->_sessionID,
'test_name' => $this->_test_name,
'data_entry' => $this->_data_entry,
'commentID' => $this->_commentID,
'instrument' => $this->_instrument,
'data_entry_type' => $this->_data_entry_type,
'candID' => $this->_candID,
'pscID' => $this->_pscID,
'visit' => $this->_visit,
'project' => $this->_project,
'cohort' => $this->_cohort,
'site' => $this->_site,
'id' => $this->_id,
'sessionID' => $this->_sessionID,
'test_name' => $this->_test_name,
'data_entry' => $this->_data_entry,
'commentID' => $this->_commentID,
];
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,10 @@ class IncompleteProvisioner extends \LORIS\Data\Provisioners\DBObjectProvisioner
"
SELECT DISTINCT
t.Full_name AS _instrument,
CASE
WHEN f.commentid LIKE 'DDE_%' THEN 'DDE'
ELSE 'FDE'
END AS _data_entry_type,
c.CandID AS _candID,
c.PSCID AS _pscID,
s.visit_label AS _visit,
Expand Down
2 changes: 1 addition & 1 deletion modules/behavioural_qc/test/behavioural_qcTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,7 @@ public function testlinks(): void
$bodyText = $this->safeFindElement(
WebDriverBy::cssSelector(
" #dynamictable >".
" tbody > tr:nth-child(1) > td:nth-child(3) > a"
" tbody > tr:nth-child(1) > td:nth-child(4) > a"
)
)->getAttribute('href');
// check Instrument link
Expand Down
Loading