mirror of
https://github.com/ACSPRI/queXS
synced 2024-04-02 12:12:16 +00:00
merged from master
This commit is contained in:
@@ -79,6 +79,9 @@ $js_foot = array(
|
|||||||
);
|
);
|
||||||
global $db;
|
global $db;
|
||||||
|
|
||||||
|
$error = "";
|
||||||
|
|
||||||
|
|
||||||
if (isset($_GET['questionnaire_id']) && isset($_GET['sample']) && isset($_GET['call_max']) && isset($_GET['call_attempt_max']))
|
if (isset($_GET['questionnaire_id']) && isset($_GET['sample']) && isset($_GET['call_max']) && isset($_GET['call_attempt_max']))
|
||||||
{
|
{
|
||||||
//need to add sample to questionnaire
|
//need to add sample to questionnaire
|
||||||
@@ -103,51 +106,46 @@ if (isset($_GET['questionnaire_id']) && isset($_GET['sample']) && isset($_GET['
|
|||||||
|
|
||||||
if (isset($_GET['generatecases']))
|
if (isset($_GET['generatecases']))
|
||||||
{
|
{
|
||||||
include_once("../functions/functions.operator.php");
|
|
||||||
|
|
||||||
//TODO: check here if attributes available for assigning sample variables
|
|
||||||
//if not - fail
|
|
||||||
|
|
||||||
$db->StartTrans();
|
//find the number of sample variables required
|
||||||
|
$sql = "SELECT count(*)
|
||||||
$lime_sid = $db->GetOne("SELECT lime_sid FROM questionnaire WHERE questionnaire_id = '$questionnaire_id'");
|
FROM sample_import_var_restrict
|
||||||
$testing = $db->GetOne("SELECT testing FROM questionnaire WHERE questionnaire_id = '$questionnaire_id'");
|
|
||||||
|
|
||||||
//add limesurvey attribute for each sample var record
|
|
||||||
$sql = "SELECT var,type
|
|
||||||
FROM sample_import_var_restrict
|
|
||||||
WHERE sample_import_id = '$sid'
|
WHERE sample_import_id = '$sid'
|
||||||
ORDER BY var_id ASC";
|
AND type = 1";
|
||||||
|
|
||||||
$rs = $db->GetAll($sql);
|
$varsrequired = $db->GetOne($sql);
|
||||||
|
|
||||||
$i = 1;
|
$addsample = false;
|
||||||
|
|
||||||
$fields = array();
|
if ($varsrequired > 0) {
|
||||||
$fieldcontents='';
|
$addsample = true;
|
||||||
foreach($rs as $r)
|
}
|
||||||
{
|
|
||||||
$fields[]=array('attribute_'.$i,'C','255');
|
|
||||||
$fieldcontents.='attribute_'.$i.'='.$r['var']."\n";
|
|
||||||
$i++;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
include_once("../functions/functions.operator.php");
|
||||||
|
|
||||||
|
$db->StartTrans();
|
||||||
|
|
||||||
|
$lime_sid = $db->GetOne("SELECT lime_sid FROM questionnaire WHERE questionnaire_id = '$questionnaire_id'");
|
||||||
|
$testing = $db->GetOne("SELECT testing FROM questionnaire WHERE questionnaire_id = '$questionnaire_id'");
|
||||||
|
|
||||||
//generate one case for each sample record and set outcome to 41
|
//generate one case for each sample record and set outcome to 41
|
||||||
$sql = "SELECT sample_id
|
$sql = "SELECT sample_id
|
||||||
FROM sample
|
FROM sample
|
||||||
WHERE import_id = '$sid'";
|
WHERE import_id = '$sid'";
|
||||||
|
|
||||||
$rs = $db->GetAll($sql);
|
$rs = $db->GetAll($sql);
|
||||||
|
|
||||||
foreach($rs as $r)
|
foreach($rs as $r)
|
||||||
{
|
{
|
||||||
set_time_limit(30);
|
set_time_limit(30);
|
||||||
//TODO : update add_case function to include attributes based on var_id ASC
|
if (add_case($r['sample_id'],$questionnaire_id,"NULL",$testing,41, $addsample) === false) {
|
||||||
add_case($r['sample_id'],$questionnaire_id,"NULL",$testing,41, true);
|
$error = "Could not add case - please ensure there enough additional attributes available in your Limesurvey participant table";
|
||||||
}
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
$db->CompleteTrans();
|
$db->CompleteTrans();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (isset($_POST['edit']))
|
if (isset($_POST['edit']))
|
||||||
@@ -312,8 +310,11 @@ print "</div>";
|
|||||||
|
|
||||||
if ($questionnaire_id != false)
|
if ($questionnaire_id != false)
|
||||||
{
|
{
|
||||||
|
if ($error != "") {
|
||||||
print "<div class='panel-body'>
|
print "<div class='alert text-danger'>$error</div>";
|
||||||
|
}
|
||||||
|
|
||||||
|
print "<div class='panel-body'>
|
||||||
<h3 class=''><i class='fa fa-list-ul text-primary'></i> ". T_("Samples assigned to questionnaire") ." <span class='text-primary'>" . $db->GetOne("SELECT description from questionnaire WHERE questionnaire_id = $questionnaire_id") . "</span></h3>";
|
<h3 class=''><i class='fa fa-list-ul text-primary'></i> ". T_("Samples assigned to questionnaire") ." <span class='text-primary'>" . $db->GetOne("SELECT description from questionnaire WHERE questionnaire_id = $questionnaire_id") . "</span></h3>";
|
||||||
|
|
||||||
$sql = "SELECT q.sort_order, si.description as description,si.sample_import_id,
|
$sql = "SELECT q.sort_order, si.description as description,si.sample_import_id,
|
||||||
@@ -400,13 +401,10 @@ if ($questionnaire_id != false)
|
|||||||
<div class="col-sm-1"><input type="checkbox" id = "allownew" name="allownew" checked="checked" class="col-sm-1" data-toggle="toggle" data-size="small" data-on="<?php echo T_("Yes");?>" data-off="<?php echo T_("No");?>" data-width="85"/></div>
|
<div class="col-sm-1"><input type="checkbox" id = "allownew" name="allownew" checked="checked" class="col-sm-1" data-toggle="toggle" data-size="small" data-on="<?php echo T_("Yes");?>" data-off="<?php echo T_("No");?>" data-width="85"/></div>
|
||||||
<label class="control-label text-info"><?php ;?></label><br/><br/><br/>
|
<label class="control-label text-info"><?php ;?></label><br/><br/><br/>
|
||||||
|
|
||||||
<?php $self_complete = $db->GetOne("SELECT self_complete FROM questionnaire WHERE questionnaire_id = '$questionnaire_id'");
|
|
||||||
if ($self_complete) {?>
|
|
||||||
<label for="generatecases" class="control-label col-lg-4"><?php echo T_("Generate cases for all sample records and set outcome to 'Self completion email invitation sent'?");?></label>
|
<label for="generatecases" class="control-label col-lg-4"><?php echo T_("Generate cases for all sample records and set outcome to 'Self completion email invitation sent'?");?></label>
|
||||||
<div class="col-sm-1"><input type="checkbox" id = "generatecases" name="generatecases" class="col-sm-1" data-toggle="toggle" data-size="small" data-on="<?php echo T_("Yes");?>" data-off="<?php echo T_("No");?>" data-width="85"/></div>
|
<div class="col-sm-1"><input type="checkbox" id = "generatecases" name="generatecases" class="col-sm-1" data-toggle="toggle" data-size="small" data-on="<?php echo T_("Yes");?>" data-off="<?php echo T_("No");?>" data-width="85"/></div>
|
||||||
<em class="control-label"> * <?php echo T_("Ideal if you intend to send an email invitation to sample members before attempting to call using queXS");?></em>
|
<em class="control-label"> * <?php echo T_("Ideal if you intend to send an email invitation to sample members before attempting to call using queXS") . " " . T_("Please ensure there are sufficient additional attribute fields in your Limesurvey questionnaire so that sample records can be inserted."); ?></em>
|
||||||
<div class='clearfix '></div></br>
|
<div class='clearfix '></div></br>
|
||||||
<?php }?>
|
|
||||||
|
|
||||||
<input type="hidden" name="questionnaire_id" value="<?php print($questionnaire_id);?>"/>
|
<input type="hidden" name="questionnaire_id" value="<?php print($questionnaire_id);?>"/>
|
||||||
|
|
||||||
|
|||||||
@@ -65,8 +65,8 @@ if (isset($_POST['import_file']))
|
|||||||
if (isset($_POST['ras'])) $ras = 1;
|
if (isset($_POST['ras'])) $ras = 1;
|
||||||
if (isset($_POST['rws'])) $rws = 1;
|
if (isset($_POST['rws'])) $rws = 1;
|
||||||
if (isset($_POST['testing'])) $testing = 1;
|
if (isset($_POST['testing'])) $testing = 1;
|
||||||
|
if (isset($_POST['referral'])) $referral = 1;
|
||||||
if (isset($_POST['respsc'])) $respsc = 1;
|
if (isset($_POST['respsc'])) $respsc = 1;
|
||||||
if (isset($_POST['referral'])) $respsc = 1;
|
|
||||||
if ($_POST['selectrs'] != "none") $rs = 1;
|
if ($_POST['selectrs'] != "none") $rs = 1;
|
||||||
|
|
||||||
$name = $db->qstr($_POST['description']);
|
$name = $db->qstr($_POST['description']);
|
||||||
@@ -221,7 +221,14 @@ if (!empty($surveys)){?>
|
|||||||
<input name="referral" type="checkbox" data-toggle="toggle" data-on="<?php echo T_("Yes"); ?>" data-off="<?php echo T_("No"); ?>" data-width="80"/>
|
<input name="referral" type="checkbox" data-toggle="toggle" data-on="<?php echo T_("Yes"); ?>" data-off="<?php echo T_("No"); ?>" data-width="80"/>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
<div class="form-group">
|
||||||
|
<label class="col-sm-4 control-label" ><?php echo T_("Allow for respondent self completion via email invitation?"); ?></label>
|
||||||
|
<div class="col-sm-4"style="height: 30px;">
|
||||||
|
<input name="respsc" type="checkbox" data-toggle="toggle" data-on="<?php echo T_("Yes"); ?>" data-off="<?php echo T_("No"); ?>" data-width="80"/>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
<?php
|
<?php
|
||||||
/* CKEditor */
|
/* CKEditor */
|
||||||
|
|
||||||
|
|||||||
@@ -296,7 +296,7 @@ if (isset($_POST['update']) && isset($_GET['modify']))
|
|||||||
$rs_project_end = $db->qstr(html_entity_decode($_POST['rs_project_end'],ENT_QUOTES,'UTF-8'));
|
$rs_project_end = $db->qstr(html_entity_decode($_POST['rs_project_end'],ENT_QUOTES,'UTF-8'));
|
||||||
|
|
||||||
$sql = "UPDATE questionnaire
|
$sql = "UPDATE questionnaire
|
||||||
SET description = $name, info = $info, rs_project_end = $rs_project_end, restrict_appointments_shifts = '$ras', restrict_work_shifts = '$rws', self_complete = $respsc, referral = $referral
|
SET description = $name, info = $info, rs_project_end = $rs_project_end, restrict_appointments_shifts = '$ras', restrict_work_shifts = '$rws', referral = $referral, self_complete = $respsc
|
||||||
WHERE questionnaire_id = '$questionnaire_id'";
|
WHERE questionnaire_id = '$questionnaire_id'";
|
||||||
|
|
||||||
$db->Execute($sql);
|
$db->Execute($sql);
|
||||||
@@ -321,7 +321,6 @@ if (isset($_GET['modify']))
|
|||||||
$rs = $db->GetRow($sql);
|
$rs = $db->GetRow($sql);
|
||||||
|
|
||||||
$referral = $testing = $rws = $ras = $rsc = "checked=\"checked\"";
|
$referral = $testing = $rws = $ras = $rsc = "checked=\"checked\"";
|
||||||
$rscd = "";
|
|
||||||
|
|
||||||
$aio = $qbq = $gat = "";
|
$aio = $qbq = $gat = "";
|
||||||
if ($rs['lime_mode'] == "survey") $aio = "selected=\"selected\"";
|
if ($rs['lime_mode'] == "survey") $aio = "selected=\"selected\"";
|
||||||
@@ -335,7 +334,6 @@ if (isset($_GET['modify']))
|
|||||||
if ($rs['self_complete'] == 0)
|
if ($rs['self_complete'] == 0)
|
||||||
{
|
{
|
||||||
$rsc = "";
|
$rsc = "";
|
||||||
$rscd = "style='display:none;'";
|
|
||||||
}
|
}
|
||||||
|
|
||||||
xhtml_head(T_("Modify Questionnaire "),true,$css,$js_head, false, false, false, "  <span class=' text-uppercase'>" . "$rs[description]" . "</span>");
|
xhtml_head(T_("Modify Questionnaire "),true,$css,$js_head, false, false, false, "  <span class=' text-uppercase'>" . "$rs[description]" . "</span>");
|
||||||
@@ -390,53 +388,7 @@ if (isset($_GET['modify']))
|
|||||||
</div>
|
</div>
|
||||||
<div class="form-group">
|
<div class="form-group">
|
||||||
<label class="col-sm-4 control-label" ><?php echo T_("Allow for respondent self completion via email invitation?"); ?> </label>
|
<label class="col-sm-4 control-label" ><?php echo T_("Allow for respondent self completion via email invitation?"); ?> </label>
|
||||||
<div class="col-sm-4" style="height: 30px;"><input name="respsc" id="respsc" type="checkbox" <?php echo $rsc ?> onchange="if(this.checked==true) {show(this,'limesc'); $('#url').attr('required','required');} else{ hide(this,'limesc'); $('#url').removeAttr('required');}" data-toggle="toggle" data-on="<?php echo T_("Yes"); ?>" data-off="<?php echo T_("No"); ?>" data-width="80"/></div>
|
<div class="col-sm-4" style="height: 30px;"><input name="respsc" id="respsc" type="checkbox" <?php echo $rsc ?> data-toggle="toggle" data-on="<?php echo T_("Yes"); ?>" data-off="<?php echo T_("No"); ?>" data-width="80"/></div>
|
||||||
</div>
|
|
||||||
<div id="limesc" <?php echo $rscd; ?> >
|
|
||||||
<div class="form-group">
|
|
||||||
<label class="col-sm-4 control-label" ><?php echo T_("Questionnaire display mode for respondent");?>: </label>
|
|
||||||
<div class="col-sm-4">
|
|
||||||
<select class="form-control" name="lime_mode">
|
|
||||||
<option <?php echo $aio;?> value="survey"><?php echo T_("All in one"); ?></option>
|
|
||||||
<option <?php echo $qbq;?> value="question"><?php echo T_("Question by question"); ?></option>
|
|
||||||
<option <?php echo $gat;?> value="group"><?php echo T_("Group at a time"); ?></option>
|
|
||||||
</select>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
<div class="form-group">
|
|
||||||
<label class="col-sm-4 control-label" ><?php echo T_("Limesurvey template for respondent");?>: </label>
|
|
||||||
<div class="col-sm-4">
|
|
||||||
<select class="form-control" name="lime_template">
|
|
||||||
<?php
|
|
||||||
if ($handle = opendir(dirname(__FILE__)."/../include/limesurvey/templates")) {
|
|
||||||
while (false !== ($entry = readdir($handle))) {
|
|
||||||
if ($entry != "." && $entry != ".." && is_dir(dirname(__FILE__)."/../include/limesurvey/templates/" . $entry)){
|
|
||||||
echo "<option value=\"$entry\" ";
|
|
||||||
if ($rs['lime_template'] == $entry) echo " selected=\"selected\" ";
|
|
||||||
echo ">$entry</option>";
|
|
||||||
}
|
|
||||||
}
|
|
||||||
closedir($handle);
|
|
||||||
}
|
|
||||||
if ($handle = opendir(dirname(__FILE__)."/../include/limesurvey/upload/templates")) {
|
|
||||||
while (false !== ($entry = readdir($handle))) {
|
|
||||||
if ($entry != "." && $entry != ".." && is_dir(dirname(__FILE__)."/../include/limesurvey/upload/templates/" . $entry)){
|
|
||||||
echo "<option value=\"$entry\" ";
|
|
||||||
if ($rs['lime_template'] == $entry) echo " selected=\"selected\" ";
|
|
||||||
echo ">$entry</option>";
|
|
||||||
}
|
|
||||||
}
|
|
||||||
closedir($handle);
|
|
||||||
}
|
|
||||||
?>
|
|
||||||
</select>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
<div class="form-group">
|
|
||||||
<label class="col-sm-4 control-label text-danger" ><?php echo T_("URL to forward respondents on self completion (required)");?>: </label>
|
|
||||||
<div class="col-sm-4">
|
|
||||||
<input class="form-control" name="lime_endurl" id="url" type="url" value="<?php echo $rs['lime_endurl']; ?>"/>
|
|
||||||
</div>
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<?php
|
<?php
|
||||||
|
|||||||
@@ -493,7 +493,8 @@ if ($case_id != false)
|
|||||||
$sid = get_lime_sid($case_id);
|
$sid = get_lime_sid($case_id);
|
||||||
$id = get_lime_id($case_id);
|
$id = get_lime_id($case_id);
|
||||||
$url = get_lime_url($case_id);
|
$url = get_lime_url($case_id);
|
||||||
print "<div class='panel-body'>";
|
|
||||||
|
print "<div class='panel-body'>";
|
||||||
if ($id)
|
if ($id)
|
||||||
print "<h4><a href='" . $url . "/admin/dataentry/sa/editdata/subaction/edit/surveyid/$sid/id/$id' class='btn btn-default btn-lime'><i class='fa fa-lemon-o fa-lg'></i> " . T_("Modify responses for this case") . "</a></h4>";
|
print "<h4><a href='" . $url . "/admin/dataentry/sa/editdata/subaction/edit/surveyid/$sid/id/$id' class='btn btn-default btn-lime'><i class='fa fa-lemon-o fa-lg'></i> " . T_("Modify responses for this case") . "</a></h4>";
|
||||||
else
|
else
|
||||||
|
|||||||
@@ -1,13 +1,13 @@
|
|||||||
-- phpMyAdmin SQL Dump
|
-- phpMyAdmin SQL Dump
|
||||||
-- version 3.4.10.1deb1
|
-- version 4.0.10deb1
|
||||||
-- http://www.phpmyadmin.net
|
-- http://www.phpmyadmin.net
|
||||||
--
|
--
|
||||||
-- Host: localhost
|
-- Host: localhost
|
||||||
-- Generation Time: Aug 03, 2015 at 12:47 PM
|
-- Generation Time: Feb 09, 2017 at 02:02 PM
|
||||||
-- Server version: 5.5.44
|
-- Server version: 5.5.54-0ubuntu0.14.04.1-log
|
||||||
-- PHP Version: 5.3.10-1ubuntu3.19
|
-- PHP Version: 5.5.9-1ubuntu4.20
|
||||||
|
|
||||||
SET SQL_MODE="NO_AUTO_VALUE_ON_ZERO";
|
SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
|
||||||
SET time_zone = "+00:00";
|
SET time_zone = "+00:00";
|
||||||
|
|
||||||
|
|
||||||
@@ -17,7 +17,7 @@ SET time_zone = "+00:00";
|
|||||||
/*!40101 SET NAMES utf8 */;
|
/*!40101 SET NAMES utf8 */;
|
||||||
|
|
||||||
--
|
--
|
||||||
-- Database: `quexs`
|
-- Database: `quexs-remotelime`
|
||||||
--
|
--
|
||||||
|
|
||||||
-- --------------------------------------------------------
|
-- --------------------------------------------------------
|
||||||
@@ -123,7 +123,7 @@ CREATE TABLE `call` (
|
|||||||
KEY `call_attempt_id` (`call_attempt_id`),
|
KEY `call_attempt_id` (`call_attempt_id`),
|
||||||
KEY `contact_phone_id` (`contact_phone_id`),
|
KEY `contact_phone_id` (`contact_phone_id`),
|
||||||
KEY `start` (`start`)
|
KEY `start` (`start`)
|
||||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
|
||||||
|
|
||||||
-- --------------------------------------------------------
|
-- --------------------------------------------------------
|
||||||
|
|
||||||
@@ -142,7 +142,7 @@ CREATE TABLE `call_attempt` (
|
|||||||
KEY `case_id` (`case_id`),
|
KEY `case_id` (`case_id`),
|
||||||
KEY `end` (`end`),
|
KEY `end` (`end`),
|
||||||
KEY `respondent_id` (`respondent_id`)
|
KEY `respondent_id` (`respondent_id`)
|
||||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
|
||||||
|
|
||||||
-- --------------------------------------------------------
|
-- --------------------------------------------------------
|
||||||
|
|
||||||
@@ -233,7 +233,7 @@ CREATE TABLE `case` (
|
|||||||
KEY `questionnaire_id` (`questionnaire_id`),
|
KEY `questionnaire_id` (`questionnaire_id`),
|
||||||
KEY `sortorder` (`sortorder`),
|
KEY `sortorder` (`sortorder`),
|
||||||
KEY `last_call_id` (`last_call_id`)
|
KEY `last_call_id` (`last_call_id`)
|
||||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
|
||||||
|
|
||||||
-- --------------------------------------------------------
|
-- --------------------------------------------------------
|
||||||
|
|
||||||
@@ -262,7 +262,7 @@ CREATE TABLE `case_note` (
|
|||||||
PRIMARY KEY (`case_note_id`),
|
PRIMARY KEY (`case_note_id`),
|
||||||
KEY `case_id` (`case_id`),
|
KEY `case_id` (`case_id`),
|
||||||
KEY `operator_id` (`operator_id`)
|
KEY `operator_id` (`operator_id`)
|
||||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
|
||||||
|
|
||||||
-- --------------------------------------------------------
|
-- --------------------------------------------------------
|
||||||
|
|
||||||
@@ -322,7 +322,7 @@ CREATE TABLE `contact_phone` (
|
|||||||
`description` varchar(255) COLLATE utf8_unicode_ci NOT NULL,
|
`description` varchar(255) COLLATE utf8_unicode_ci NOT NULL,
|
||||||
PRIMARY KEY (`contact_phone_id`),
|
PRIMARY KEY (`contact_phone_id`),
|
||||||
KEY `case_id` (`case_id`)
|
KEY `case_id` (`case_id`)
|
||||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
|
||||||
|
|
||||||
-- --------------------------------------------------------
|
-- --------------------------------------------------------
|
||||||
|
|
||||||
@@ -367,39 +367,16 @@ CREATE TABLE `extension` (
|
|||||||
-- --------------------------------------------------------
|
-- --------------------------------------------------------
|
||||||
|
|
||||||
--
|
--
|
||||||
-- Table structure for table `lime_users`
|
-- Table structure for table `failed_login_attempts`
|
||||||
--
|
--
|
||||||
|
|
||||||
CREATE TABLE `lime_users` (
|
CREATE TABLE `failed_login_attempts` (
|
||||||
`uid` int(11) NOT NULL AUTO_INCREMENT,
|
`id` int(11) NOT NULL AUTO_INCREMENT,
|
||||||
`users_name` varchar(64) COLLATE utf8_unicode_ci NOT NULL DEFAULT '',
|
`ip` varchar(37) COLLATE utf8_unicode_ci NOT NULL,
|
||||||
`password` blob NOT NULL,
|
`last_attempt` varchar(20) COLLATE utf8_unicode_ci NOT NULL,
|
||||||
`full_name` varchar(50) COLLATE utf8_unicode_ci NOT NULL,
|
`number_attempts` int(11) NOT NULL,
|
||||||
`parent_id` int(11) NOT NULL,
|
PRIMARY KEY (`id`)
|
||||||
`lang` varchar(20) COLLATE utf8_unicode_ci DEFAULT NULL,
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
|
||||||
`email` varchar(320) COLLATE utf8_unicode_ci DEFAULT NULL,
|
|
||||||
`create_survey` tinyint(1) NOT NULL DEFAULT '0',
|
|
||||||
`create_user` tinyint(1) NOT NULL DEFAULT '0',
|
|
||||||
`participant_panel` tinyint(1) NOT NULL DEFAULT '0',
|
|
||||||
`delete_user` tinyint(1) NOT NULL DEFAULT '0',
|
|
||||||
`superadmin` tinyint(1) NOT NULL DEFAULT '0',
|
|
||||||
`configurator` tinyint(1) NOT NULL DEFAULT '0',
|
|
||||||
`manage_template` tinyint(1) NOT NULL DEFAULT '0',
|
|
||||||
`manage_label` tinyint(1) NOT NULL DEFAULT '0',
|
|
||||||
`htmleditormode` varchar(7) COLLATE utf8_unicode_ci DEFAULT 'default',
|
|
||||||
`templateeditormode` varchar(7) COLLATE utf8_unicode_ci DEFAULT 'default',
|
|
||||||
`questionselectormode` varchar(7) COLLATE utf8_unicode_ci DEFAULT 'default',
|
|
||||||
`one_time_pw` blob,
|
|
||||||
`dateformat` int(11) NOT NULL DEFAULT '1',
|
|
||||||
PRIMARY KEY (`uid`),
|
|
||||||
UNIQUE KEY `users_name` (`users_name`)
|
|
||||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
|
|
||||||
|
|
||||||
--
|
|
||||||
-- Dumping data for table `lime_users`
|
|
||||||
--
|
|
||||||
|
|
||||||
INSERT INTO `lime_users` (`uid`, `users_name`, `password`, `full_name`, `parent_id`, `lang`, `email`, `create_survey`, `create_user`, `participant_panel`, `delete_user`, `superadmin`, `configurator`, `manage_template`, `manage_label`, `htmleditormode`, `templateeditormode`, `questionselectormode`, `one_time_pw`, `dateformat`) VALUES(1, 'admin', 0x35653838343839386461323830343731353164306535366638646336323932373733363033643064366161626264643632613131656637323164313534326438, 'Your Name', 0, 'auto', 'your-email@example.net', 1, 1, 0, 1, 1, 1, 1, 1, 'default', 'default', 'default', NULL, 1);
|
|
||||||
|
|
||||||
-- --------------------------------------------------------
|
-- --------------------------------------------------------
|
||||||
|
|
||||||
@@ -421,12 +398,15 @@ CREATE TABLE `operator` (
|
|||||||
`chat_password` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL,
|
`chat_password` varchar(255) COLLATE utf8_unicode_ci DEFAULT NULL,
|
||||||
PRIMARY KEY (`operator_id`),
|
PRIMARY KEY (`operator_id`),
|
||||||
UNIQUE KEY `username` (`username`)
|
UNIQUE KEY `username` (`username`)
|
||||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
|
||||||
|
|
||||||
|
--
|
||||||
|
-- Dumping data for table `operator`
|
||||||
|
--
|
||||||
|
|
||||||
|
INSERT INTO `operator` (`operator_id`, `username`, `firstName`, `lastName`, `Time_zone_name`, `enabled`, `voip`, `next_case_id`, `chat_enable`, `chat_user`, `chat_password`) VALUES(1, 'admin', 'CATI', 'Admin', 'Australia/Victoria', 1, 0, NULL, 0, '', '');
|
||||||
|
|
||||||
-- --------------------------------------------------------
|
-- --------------------------------------------------------
|
||||||
INSERT INTO `operator` (`operator_id`, `username`, `firstName`, `lastName`, `Time_zone_name`, `enabled`, `voip`, `next_case_id`, `chat_enable`, `chat_user`, `chat_password`) VALUES
|
|
||||||
(1, 'admin', 'CATI', 'Admin', 'Australia/Victoria', 1, 0, NULL, 0, '', '');
|
|
||||||
|
|
||||||
|
|
||||||
--
|
--
|
||||||
-- Table structure for table `operator_questionnaire`
|
-- Table structure for table `operator_questionnaire`
|
||||||
@@ -450,11 +430,14 @@ CREATE TABLE `operator_skill` (
|
|||||||
PRIMARY KEY (`operator_id`,`outcome_type_id`)
|
PRIMARY KEY (`operator_id`,`outcome_type_id`)
|
||||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
|
||||||
|
|
||||||
-- --------------------------------------------------------
|
--
|
||||||
|
-- Dumping data for table `operator_skill`
|
||||||
|
--
|
||||||
|
|
||||||
INSERT INTO `operator_skill` (`operator_id`, `outcome_type_id`) VALUES
|
INSERT INTO `operator_skill` (`operator_id`, `outcome_type_id`) VALUES(1, 1);
|
||||||
(1, 1),
|
INSERT INTO `operator_skill` (`operator_id`, `outcome_type_id`) VALUES(1, 5);
|
||||||
(1, 5);
|
|
||||||
|
-- --------------------------------------------------------
|
||||||
|
|
||||||
--
|
--
|
||||||
-- Table structure for table `outcome`
|
-- Table structure for table `outcome`
|
||||||
@@ -472,60 +455,61 @@ CREATE TABLE `outcome` (
|
|||||||
`eligible` tinyint(1) NOT NULL DEFAULT '1' COMMENT 'If the respondent is eligible to participate',
|
`eligible` tinyint(1) NOT NULL DEFAULT '1' COMMENT 'If the respondent is eligible to participate',
|
||||||
`require_note` tinyint(1) NOT NULL DEFAULT '0' COMMENT 'Whether to require a note to be entered',
|
`require_note` tinyint(1) NOT NULL DEFAULT '0' COMMENT 'Whether to require a note to be entered',
|
||||||
`calc` char(2) COLLATE utf8_unicode_ci NOT NULL,
|
`calc` char(2) COLLATE utf8_unicode_ci NOT NULL,
|
||||||
`default` TINYINT(1) UNSIGNED NOT NULL DEFAULT '1' COMMENT 'Used as default for questionnaire outcomes',
|
`default` tinyint(1) unsigned NOT NULL DEFAULT '1' COMMENT 'Used as default for questionnaire outcomes',
|
||||||
`permanent` TINYINT(1) UNSIGNED NOT NULL COMMENT 'Permanent outcome, used for all questionnaires, not possible to de-select',
|
`permanent` tinyint(1) unsigned NOT NULL COMMENT 'Permanent outcome, used for all questionnaires, not possible to de-select',
|
||||||
PRIMARY KEY (`outcome_id`),
|
PRIMARY KEY (`outcome_id`),
|
||||||
KEY `calc` (`calc`)
|
KEY `calc` (`calc`)
|
||||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci AUTO_INCREMENT=100;
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
|
||||||
|
|
||||||
--
|
--
|
||||||
-- Dumping data for table `outcome`
|
-- Dumping data for table `outcome`
|
||||||
--
|
--
|
||||||
|
|
||||||
INSERT INTO `outcome` (`outcome_id`, `aapor_id`, `description`, `default_delay_minutes`, `outcome_type_id`, `tryanother`, `contacted`, `tryagain`, `eligible`, `require_note`, `calc`, `default`, `permanent`) VALUES (1,'3.11','Not attempted or worked',0,1,1,0,1,0,0,'UH',1,1);
|
INSERT INTO `outcome` (`outcome_id`, `aapor_id`, `description`, `default_delay_minutes`, `outcome_type_id`, `tryanother`, `contacted`, `tryagain`, `eligible`, `require_note`, `calc`, `default`, `permanent`) VALUES(1, '3.11', 'Not attempted or worked', 0, 1, 1, 0, 1, 0, 0, 'UH', 1, 1);
|
||||||
INSERT INTO `outcome` (`outcome_id`, `aapor_id`, `description`, `default_delay_minutes`, `outcome_type_id`, `tryanother`, `contacted`, `tryagain`, `eligible`, `require_note`, `calc`, `default`, `permanent`) VALUES (2,'3.13','No answer',180,1,1,0,1,1,0,'UH',1,1);
|
INSERT INTO `outcome` (`outcome_id`, `aapor_id`, `description`, `default_delay_minutes`, `outcome_type_id`, `tryanother`, `contacted`, `tryagain`, `eligible`, `require_note`, `calc`, `default`, `permanent`) VALUES(2, '3.13', 'No answer', 180, 1, 1, 0, 1, 1, 0, 'UH', 1, 1);
|
||||||
INSERT INTO `outcome` (`outcome_id`, `aapor_id`, `description`, `default_delay_minutes`, `outcome_type_id`, `tryanother`, `contacted`, `tryagain`, `eligible`, `require_note`, `calc`, `default`, `permanent`) VALUES (3,'3.16','Technical phone problems',180,1,1,0,1,0,0,'UH',1,1);
|
INSERT INTO `outcome` (`outcome_id`, `aapor_id`, `description`, `default_delay_minutes`, `outcome_type_id`, `tryanother`, `contacted`, `tryagain`, `eligible`, `require_note`, `calc`, `default`, `permanent`) VALUES(3, '3.16', 'Technical phone problems', 180, 1, 1, 0, 1, 0, 0, 'UH', 1, 1);
|
||||||
INSERT INTO `outcome` (`outcome_id`, `aapor_id`, `description`, `default_delay_minutes`, `outcome_type_id`, `tryanother`, `contacted`, `tryagain`, `eligible`, `require_note`, `calc`, `default`, `permanent`) VALUES (4,'2.34','Other, Referred to Supervisor (Eligible)',0,2,0,1,1,1,1,'O',1,0);
|
INSERT INTO `outcome` (`outcome_id`, `aapor_id`, `description`, `default_delay_minutes`, `outcome_type_id`, `tryanother`, `contacted`, `tryagain`, `eligible`, `require_note`, `calc`, `default`, `permanent`) VALUES(4, '2.34', 'Other, Referred to Supervisor (Eligible)', 0, 2, 0, 1, 1, 1, 1, 'O', 1, 0);
|
||||||
INSERT INTO `outcome` (`outcome_id`, `aapor_id`, `description`, `default_delay_minutes`, `outcome_type_id`, `tryanother`, `contacted`, `tryagain`, `eligible`, `require_note`, `calc`, `default`, `permanent`) VALUES (5,'3.91','Other, Referred to Supervisor (Unknown eligibility)',0,2,0,0,1,0,1,'UO',1,0);
|
INSERT INTO `outcome` (`outcome_id`, `aapor_id`, `description`, `default_delay_minutes`, `outcome_type_id`, `tryanother`, `contacted`, `tryagain`, `eligible`, `require_note`, `calc`, `default`, `permanent`) VALUES(5, '3.91', 'Other, Referred to Supervisor (Unknown eligibility)', 0, 2, 0, 0, 1, 0, 1, 'UO', 1, 0);
|
||||||
INSERT INTO `outcome` (`outcome_id`, `aapor_id`, `description`, `default_delay_minutes`, `outcome_type_id`, `tryanother`, `contacted`, `tryagain`, `eligible`, `require_note`, `calc`, `default`, `permanent`) VALUES (6,'2.111a','Soft Refusal, Other',10080,3,0,1,1,1,1,'R',1,0);
|
INSERT INTO `outcome` (`outcome_id`, `aapor_id`, `description`, `default_delay_minutes`, `outcome_type_id`, `tryanother`, `contacted`, `tryagain`, `eligible`, `require_note`, `calc`, `default`, `permanent`) VALUES(6, '2.111a', 'Soft Refusal, Other', 10080, 3, 0, 1, 1, 1, 1, 'R', 1, 0);
|
||||||
INSERT INTO `outcome` (`outcome_id`, `aapor_id`, `description`, `default_delay_minutes`, `outcome_type_id`, `tryanother`, `contacted`, `tryagain`, `eligible`, `require_note`, `calc`, `default`, `permanent`) VALUES (7,'2.111b','Hard Refusal, Other',10080,3,0,1,1,1,1,'R',1,1);
|
INSERT INTO `outcome` (`outcome_id`, `aapor_id`, `description`, `default_delay_minutes`, `outcome_type_id`, `tryanother`, `contacted`, `tryagain`, `eligible`, `require_note`, `calc`, `default`, `permanent`) VALUES(7, '2.111b', 'Hard Refusal, Other', 10080, 3, 0, 1, 1, 1, 1, 'R', 1, 1);
|
||||||
INSERT INTO `outcome` (`outcome_id`, `aapor_id`, `description`, `default_delay_minutes`, `outcome_type_id`, `tryanother`, `contacted`, `tryagain`, `eligible`, `require_note`, `calc`, `default`, `permanent`) VALUES (8,'2.112a','Soft Refusal, Respondent',10080,3,0,1,1,1,1,'R',1,0);
|
INSERT INTO `outcome` (`outcome_id`, `aapor_id`, `description`, `default_delay_minutes`, `outcome_type_id`, `tryanother`, `contacted`, `tryagain`, `eligible`, `require_note`, `calc`, `default`, `permanent`) VALUES(8, '2.112a', 'Soft Refusal, Respondent', 10080, 3, 0, 1, 1, 1, 1, 'R', 1, 0);
|
||||||
INSERT INTO `outcome` (`outcome_id`, `aapor_id`, `description`, `default_delay_minutes`, `outcome_type_id`, `tryanother`, `contacted`, `tryagain`, `eligible`, `require_note`, `calc`, `default`, `permanent`) VALUES (9,'2.112b','Hard Refusal, Respondent',10080,3,0,1,1,1,1,'R',1,1);
|
INSERT INTO `outcome` (`outcome_id`, `aapor_id`, `description`, `default_delay_minutes`, `outcome_type_id`, `tryanother`, `contacted`, `tryagain`, `eligible`, `require_note`, `calc`, `default`, `permanent`) VALUES(9, '2.112b', 'Hard Refusal, Respondent', 10080, 3, 0, 1, 1, 1, 1, 'R', 1, 1);
|
||||||
INSERT INTO `outcome` (`outcome_id`, `aapor_id`, `description`, `default_delay_minutes`, `outcome_type_id`, `tryanother`, `contacted`, `tryagain`, `eligible`, `require_note`, `calc`, `default`, `permanent`) VALUES (10,'1.1','Complete',0,4,0,1,1,1,0,'I',1,1);
|
INSERT INTO `outcome` (`outcome_id`, `aapor_id`, `description`, `default_delay_minutes`, `outcome_type_id`, `tryanother`, `contacted`, `tryagain`, `eligible`, `require_note`, `calc`, `default`, `permanent`) VALUES(10, '1.1', 'Complete', 0, 4, 0, 1, 1, 1, 0, 'I', 1, 1);
|
||||||
INSERT INTO `outcome` (`outcome_id`, `aapor_id`, `description`, `default_delay_minutes`, `outcome_type_id`, `tryanother`, `contacted`, `tryagain`, `eligible`, `require_note`, `calc`, `default`, `permanent`) VALUES (11,'2.112','Known respondent refusal',0,4,0,1,1,1,0,'R',1,0);
|
INSERT INTO `outcome` (`outcome_id`, `aapor_id`, `description`, `default_delay_minutes`, `outcome_type_id`, `tryanother`, `contacted`, `tryagain`, `eligible`, `require_note`, `calc`, `default`, `permanent`) VALUES(11, '2.112', 'Known respondent refusal', 0, 4, 0, 1, 1, 1, 0, 'R', 1, 0);
|
||||||
INSERT INTO `outcome` (`outcome_id`, `aapor_id`, `description`, `default_delay_minutes`, `outcome_type_id`, `tryanother`, `contacted`, `tryagain`, `eligible`, `require_note`, `calc`, `default`, `permanent`) VALUES (12,'2.111','Household-level refusal',0,4,0,1,1,1,0,'R',1,0);
|
INSERT INTO `outcome` (`outcome_id`, `aapor_id`, `description`, `default_delay_minutes`, `outcome_type_id`, `tryanother`, `contacted`, `tryagain`, `eligible`, `require_note`, `calc`, `default`, `permanent`) VALUES(12, '2.111', 'Household-level refusal', 0, 4, 0, 1, 1, 1, 0, 'R', 1, 0);
|
||||||
INSERT INTO `outcome` (`outcome_id`, `aapor_id`, `description`, `default_delay_minutes`, `outcome_type_id`, `tryanother`, `contacted`, `tryagain`, `eligible`, `require_note`, `calc`, `default`, `permanent`) VALUES (13,'2.112c','Broken appointment (Implicit refusal)',10080,3,1,0,1,1,0,'R',1,0);
|
INSERT INTO `outcome` (`outcome_id`, `aapor_id`, `description`, `default_delay_minutes`, `outcome_type_id`, `tryanother`, `contacted`, `tryagain`, `eligible`, `require_note`, `calc`, `default`, `permanent`) VALUES(13, '2.112c', 'Broken appointment (Implicit refusal)', 10080, 3, 1, 0, 1, 1, 0, 'R', 1, 0);
|
||||||
INSERT INTO `outcome` (`outcome_id`, `aapor_id`, `description`, `default_delay_minutes`, `outcome_type_id`, `tryanother`, `contacted`, `tryagain`, `eligible`, `require_note`, `calc`, `default`, `permanent`) VALUES (14,'4.32','Disconnected number',0,4,1,0,0,0,0,'',1,1);
|
INSERT INTO `outcome` (`outcome_id`, `aapor_id`, `description`, `default_delay_minutes`, `outcome_type_id`, `tryanother`, `contacted`, `tryagain`, `eligible`, `require_note`, `calc`, `default`, `permanent`) VALUES(14, '4.32', 'Disconnected number', 0, 4, 1, 0, 0, 0, 0, '', 1, 1);
|
||||||
INSERT INTO `outcome` (`outcome_id`, `aapor_id`, `description`, `default_delay_minutes`, `outcome_type_id`, `tryanother`, `contacted`, `tryagain`, `eligible`, `require_note`, `calc`, `default`, `permanent`) VALUES (15,'4.20','Fax/data line',0,4,1,1,0,0,0,'',1,0);
|
INSERT INTO `outcome` (`outcome_id`, `aapor_id`, `description`, `default_delay_minutes`, `outcome_type_id`, `tryanother`, `contacted`, `tryagain`, `eligible`, `require_note`, `calc`, `default`, `permanent`) VALUES(15, '4.20', 'Fax/data line', 0, 4, 1, 1, 0, 0, 0, '', 1, 0);
|
||||||
INSERT INTO `outcome` (`outcome_id`, `aapor_id`, `description`, `default_delay_minutes`, `outcome_type_id`, `tryanother`, `contacted`, `tryagain`, `eligible`, `require_note`, `calc`, `default`, `permanent`) VALUES (16,'4.51','Business, government office, other organization',0,4,1,1,0,0,0,'',1,0);
|
INSERT INTO `outcome` (`outcome_id`, `aapor_id`, `description`, `default_delay_minutes`, `outcome_type_id`, `tryanother`, `contacted`, `tryagain`, `eligible`, `require_note`, `calc`, `default`, `permanent`) VALUES(16, '4.51', 'Business, government office, other organization', 0, 4, 1, 1, 0, 0, 0, '', 1, 0);
|
||||||
INSERT INTO `outcome` (`outcome_id`, `aapor_id`, `description`, `default_delay_minutes`, `outcome_type_id`, `tryanother`, `contacted`, `tryagain`, `eligible`, `require_note`, `calc`, `default`, `permanent`) VALUES (17,'4.70','No eligible respondent',0,4,1,1,0,0,0,'',1,1);
|
INSERT INTO `outcome` (`outcome_id`, `aapor_id`, `description`, `default_delay_minutes`, `outcome_type_id`, `tryanother`, `contacted`, `tryagain`, `eligible`, `require_note`, `calc`, `default`, `permanent`) VALUES(17, '4.70', 'No eligible respondent', 0, 4, 1, 1, 0, 0, 0, '', 1, 1);
|
||||||
INSERT INTO `outcome` (`outcome_id`, `aapor_id`, `description`, `default_delay_minutes`, `outcome_type_id`, `tryanother`, `contacted`, `tryagain`, `eligible`, `require_note`, `calc`, `default`, `permanent`) VALUES (18,'2.35a','Accidental hang up or temporary phone problem',0,1,1,1,1,1,0,'O',1,1);
|
INSERT INTO `outcome` (`outcome_id`, `aapor_id`, `description`, `default_delay_minutes`, `outcome_type_id`, `tryanother`, `contacted`, `tryagain`, `eligible`, `require_note`, `calc`, `default`, `permanent`) VALUES(18, '2.35a', 'Accidental hang up or temporary phone problem', 0, 1, 1, 1, 1, 1, 0, 'O', 1, 1);
|
||||||
INSERT INTO `outcome` (`outcome_id`, `aapor_id`, `description`, `default_delay_minutes`, `outcome_type_id`, `tryanother`, `contacted`, `tryagain`, `eligible`, `require_note`, `calc`, `default`, `permanent`) VALUES (19,'2.12a','Definite Appointment - Respondent',0,5,0,1,1,1,0,'R',1,1);
|
INSERT INTO `outcome` (`outcome_id`, `aapor_id`, `description`, `default_delay_minutes`, `outcome_type_id`, `tryanother`, `contacted`, `tryagain`, `eligible`, `require_note`, `calc`, `default`, `permanent`) VALUES(19, '2.12a', 'Definite Appointment - Respondent', 0, 5, 0, 1, 1, 1, 0, 'R', 1, 1);
|
||||||
INSERT INTO `outcome` (`outcome_id`, `aapor_id`, `description`, `default_delay_minutes`, `outcome_type_id`, `tryanother`, `contacted`, `tryagain`, `eligible`, `require_note`, `calc`, `default`, `permanent`) VALUES (20,'2.12b','Definite Appointment - Other',0,5,0,1,1,1,0,'R',1,0);
|
INSERT INTO `outcome` (`outcome_id`, `aapor_id`, `description`, `default_delay_minutes`, `outcome_type_id`, `tryanother`, `contacted`, `tryagain`, `eligible`, `require_note`, `calc`, `default`, `permanent`) VALUES(20, '2.12b', 'Definite Appointment - Other', 0, 5, 0, 1, 1, 1, 0, 'R', 1, 0);
|
||||||
INSERT INTO `outcome` (`outcome_id`, `aapor_id`, `description`, `default_delay_minutes`, `outcome_type_id`, `tryanother`, `contacted`, `tryagain`, `eligible`, `require_note`, `calc`, `default`, `permanent`) VALUES (21,'2.13a','Unspecified Appointment - Respondent',0,5,0,1,1,1,0,'R',1,0);
|
INSERT INTO `outcome` (`outcome_id`, `aapor_id`, `description`, `default_delay_minutes`, `outcome_type_id`, `tryanother`, `contacted`, `tryagain`, `eligible`, `require_note`, `calc`, `default`, `permanent`) VALUES(21, '2.13a', 'Unspecified Appointment - Respondent', 0, 5, 0, 1, 1, 1, 0, 'R', 1, 0);
|
||||||
INSERT INTO `outcome` (`outcome_id`, `aapor_id`, `description`, `default_delay_minutes`, `outcome_type_id`, `tryanother`, `contacted`, `tryagain`, `eligible`, `require_note`, `calc`, `default`, `permanent`) VALUES (22,'2.13b','Unspecified Appointment - Other',0,5,0,1,1,1,0,'R',1,0);
|
INSERT INTO `outcome` (`outcome_id`, `aapor_id`, `description`, `default_delay_minutes`, `outcome_type_id`, `tryanother`, `contacted`, `tryagain`, `eligible`, `require_note`, `calc`, `default`, `permanent`) VALUES(22, '2.13b', 'Unspecified Appointment - Other', 0, 5, 0, 1, 1, 1, 0, 'R', 1, 0);
|
||||||
INSERT INTO `outcome` (`outcome_id`, `aapor_id`, `description`, `default_delay_minutes`, `outcome_type_id`, `tryanother`, `contacted`, `tryagain`, `eligible`, `require_note`, `calc`, `default`, `permanent`) VALUES (23,'2.221','Household answering machine - Message left',180,1,1,1,1,1,0,'NC',1,0);
|
INSERT INTO `outcome` (`outcome_id`, `aapor_id`, `description`, `default_delay_minutes`, `outcome_type_id`, `tryanother`, `contacted`, `tryagain`, `eligible`, `require_note`, `calc`, `default`, `permanent`) VALUES(23, '2.221', 'Household answering machine - Message left', 180, 1, 1, 1, 1, 1, 0, 'NC', 1, 0);
|
||||||
INSERT INTO `outcome` (`outcome_id`, `aapor_id`, `description`, `default_delay_minutes`, `outcome_type_id`, `tryanother`, `contacted`, `tryagain`, `eligible`, `require_note`, `calc`, `default`, `permanent`) VALUES (24,'2.222','Household answering machine - No message left',180,1,1,1,1,1,0,'NC',1,0);
|
INSERT INTO `outcome` (`outcome_id`, `aapor_id`, `description`, `default_delay_minutes`, `outcome_type_id`, `tryanother`, `contacted`, `tryagain`, `eligible`, `require_note`, `calc`, `default`, `permanent`) VALUES(24, '2.222', 'Household answering machine - No message left', 180, 1, 1, 1, 1, 1, 0, 'NC', 1, 0);
|
||||||
INSERT INTO `outcome` (`outcome_id`, `aapor_id`, `description`, `default_delay_minutes`, `outcome_type_id`, `tryanother`, `contacted`, `tryagain`, `eligible`, `require_note`, `calc`, `default`, `permanent`) VALUES (25,'2.31','Respondent Dead',0,4,0,1,0,1,0,'O',1,0);
|
INSERT INTO `outcome` (`outcome_id`, `aapor_id`, `description`, `default_delay_minutes`, `outcome_type_id`, `tryanother`, `contacted`, `tryagain`, `eligible`, `require_note`, `calc`, `default`, `permanent`) VALUES(25, '2.31', 'Respondent Dead', 0, 4, 0, 1, 0, 1, 0, 'O', 1, 0);
|
||||||
INSERT INTO `outcome` (`outcome_id`, `aapor_id`, `description`, `default_delay_minutes`, `outcome_type_id`, `tryanother`, `contacted`, `tryagain`, `eligible`, `require_note`, `calc`, `default`, `permanent`) VALUES (26,'2.32','Physically or mentally unable/incompetent',0,4,0,1,0,1,0,'O',1,0);
|
INSERT INTO `outcome` (`outcome_id`, `aapor_id`, `description`, `default_delay_minutes`, `outcome_type_id`, `tryanother`, `contacted`, `tryagain`, `eligible`, `require_note`, `calc`, `default`, `permanent`) VALUES(26, '2.32', 'Physically or mentally unable/incompetent', 0, 4, 0, 1, 0, 1, 0, 'O', 1, 0);
|
||||||
INSERT INTO `outcome` (`outcome_id`, `aapor_id`, `description`, `default_delay_minutes`, `outcome_type_id`, `tryanother`, `contacted`, `tryagain`, `eligible`, `require_note`, `calc`, `default`, `permanent`) VALUES (27,'2.331','Household level language problem',0,4,1,1,0,1,0,'O',1,0);
|
INSERT INTO `outcome` (`outcome_id`, `aapor_id`, `description`, `default_delay_minutes`, `outcome_type_id`, `tryanother`, `contacted`, `tryagain`, `eligible`, `require_note`, `calc`, `default`, `permanent`) VALUES(27, '2.331', 'Household level language problem', 0, 4, 1, 1, 0, 1, 0, 'O', 1, 0);
|
||||||
INSERT INTO `outcome` (`outcome_id`, `aapor_id`, `description`, `default_delay_minutes`, `outcome_type_id`, `tryanother`, `contacted`, `tryagain`, `eligible`, `require_note`, `calc`, `default`, `permanent`) VALUES (28,'2.332','Respondent language problem',0,4,0,1,0,1,0,'O',1,0);
|
INSERT INTO `outcome` (`outcome_id`, `aapor_id`, `description`, `default_delay_minutes`, `outcome_type_id`, `tryanother`, `contacted`, `tryagain`, `eligible`, `require_note`, `calc`, `default`, `permanent`) VALUES(28, '2.332', 'Respondent language problem', 0, 4, 0, 1, 0, 1, 0, 'O', 1, 0);
|
||||||
INSERT INTO `outcome` (`outcome_id`, `aapor_id`, `description`, `default_delay_minutes`, `outcome_type_id`, `tryanother`, `contacted`, `tryagain`, `eligible`, `require_note`, `calc`, `default`, `permanent`) VALUES (29,'3.14','Answering machine - Not a household',0,4,1,1,0,0,0,'UH',1,0);
|
INSERT INTO `outcome` (`outcome_id`, `aapor_id`, `description`, `default_delay_minutes`, `outcome_type_id`, `tryanother`, `contacted`, `tryagain`, `eligible`, `require_note`, `calc`, `default`, `permanent`) VALUES(29, '3.14', 'Answering machine - Not a household', 0, 4, 1, 1, 0, 0, 0, 'UH', 1, 0);
|
||||||
INSERT INTO `outcome` (`outcome_id`, `aapor_id`, `description`, `default_delay_minutes`, `outcome_type_id`, `tryanother`, `contacted`, `tryagain`, `eligible`, `require_note`, `calc`, `default`, `permanent`) VALUES (30,'4.10','Out of sample',0,4,0,1,0,0,0,'',1,0);
|
INSERT INTO `outcome` (`outcome_id`, `aapor_id`, `description`, `default_delay_minutes`, `outcome_type_id`, `tryanother`, `contacted`, `tryagain`, `eligible`, `require_note`, `calc`, `default`, `permanent`) VALUES(30, '4.10', 'Out of sample', 0, 4, 0, 1, 0, 0, 0, '', 1, 0);
|
||||||
INSERT INTO `outcome` (`outcome_id`, `aapor_id`, `description`, `default_delay_minutes`, `outcome_type_id`, `tryanother`, `contacted`, `tryagain`, `eligible`, `require_note`, `calc`, `default`, `permanent`) VALUES (31,'2.20','Non contact',180,1,1,1,1,1,0,'NC',1,0);
|
INSERT INTO `outcome` (`outcome_id`, `aapor_id`, `description`, `default_delay_minutes`, `outcome_type_id`, `tryanother`, `contacted`, `tryagain`, `eligible`, `require_note`, `calc`, `default`, `permanent`) VALUES(31, '2.20', 'Non contact', 180, 1, 1, 1, 1, 1, 0, 'NC', 1, 0);
|
||||||
INSERT INTO `outcome` (`outcome_id`, `aapor_id`, `description`, `default_delay_minutes`, `outcome_type_id`, `tryanother`, `contacted`, `tryagain`, `eligible`, `require_note`, `calc`, `default`, `permanent`) VALUES (32,'4.80','Quota filled',0,4,0,1,0,0,0,'',1,0);
|
INSERT INTO `outcome` (`outcome_id`, `aapor_id`, `description`, `default_delay_minutes`, `outcome_type_id`, `tryanother`, `contacted`, `tryagain`, `eligible`, `require_note`, `calc`, `default`, `permanent`) VALUES(32, '4.80', 'Quota filled', 0, 4, 0, 1, 0, 0, 0, '', 1, 0);
|
||||||
INSERT INTO `outcome` (`outcome_id`, `aapor_id`, `description`, `default_delay_minutes`, `outcome_type_id`, `tryanother`, `contacted`, `tryagain`, `eligible`, `require_note`, `calc`, `default`, `permanent`) VALUES (33,'2.36','Miscellaneous - Unavailable for a week',10080,1,0,1,1,1,0,'O',1,0);
|
INSERT INTO `outcome` (`outcome_id`, `aapor_id`, `description`, `default_delay_minutes`, `outcome_type_id`, `tryanother`, `contacted`, `tryagain`, `eligible`, `require_note`, `calc`, `default`, `permanent`) VALUES(33, '2.36', 'Miscellaneous - Unavailable for a week', 10080, 1, 0, 1, 1, 1, 0, 'O', 1, 0);
|
||||||
INSERT INTO `outcome` (`outcome_id`, `aapor_id`, `description`, `default_delay_minutes`, `outcome_type_id`, `tryanother`, `contacted`, `tryagain`, `eligible`, `require_note`, `calc`, `default`, `permanent`) VALUES (40,'1.1','Self completed online',0,4,0,1,1,1,0,'I',1,0);
|
INSERT INTO `outcome` (`outcome_id`, `aapor_id`, `description`, `default_delay_minutes`, `outcome_type_id`, `tryanother`, `contacted`, `tryagain`, `eligible`, `require_note`, `calc`, `default`, `permanent`) VALUES(40, '1.1', 'Self completed online', 0, 4, 0, 1, 1, 1, 0, 'I', 1, 0);
|
||||||
INSERT INTO `outcome` (`outcome_id`, `aapor_id`, `description`, `default_delay_minutes`, `outcome_type_id`, `tryanother`, `contacted`, `tryagain`, `eligible`, `require_note`, `calc`, `default`, `permanent`) VALUES (41,'2.36','Self completion email invitation sent',10080,1,0,1,1,1,0,'O',1,0);
|
INSERT INTO `outcome` (`outcome_id`, `aapor_id`, `description`, `default_delay_minutes`, `outcome_type_id`, `tryanother`, `contacted`, `tryagain`, `eligible`, `require_note`, `calc`, `default`, `permanent`) VALUES(41, '2.36', 'Self completion email invitation sent', 10080, 1, 0, 1, 1, 1, 0, 'O', 1, 0);
|
||||||
INSERT INTO `outcome` (`outcome_id`, `aapor_id`, `description`, `default_delay_minutes`, `outcome_type_id`, `tryanother`, `contacted`, `tryagain`, `eligible`, `require_note`, `calc`, `default`, `permanent`) VALUES (42,'3.90','Max call attempts reached (Unknown eligibility)',0,1,0,1,1,0,0,'UH',1,0);
|
INSERT INTO `outcome` (`outcome_id`, `aapor_id`, `description`, `default_delay_minutes`, `outcome_type_id`, `tryanother`, `contacted`, `tryagain`, `eligible`, `require_note`, `calc`, `default`, `permanent`) VALUES(42, '3.90', 'Max call attempts reached (Unknown eligibility)', 0, 1, 0, 1, 1, 0, 0, 'UH', 1, 0);
|
||||||
INSERT INTO `outcome` (`outcome_id`, `aapor_id`, `description`, `default_delay_minutes`, `outcome_type_id`, `tryanother`, `contacted`, `tryagain`, `eligible`, `require_note`, `calc`, `default`, `permanent`) VALUES (43,'3.90','Max calls reached (Unknown eligibility)',0,1,0,1,1,0,0,'UH',1,0);
|
INSERT INTO `outcome` (`outcome_id`, `aapor_id`, `description`, `default_delay_minutes`, `outcome_type_id`, `tryanother`, `contacted`, `tryagain`, `eligible`, `require_note`, `calc`, `default`, `permanent`) VALUES(43, '3.90', 'Max calls reached (Unknown eligibility)', 0, 1, 0, 1, 1, 0, 0, 'UH', 1, 0);
|
||||||
INSERT INTO `outcome` (`outcome_id`, `aapor_id`, `description`, `default_delay_minutes`, `outcome_type_id`, `tryanother`, `contacted`, `tryagain`, `eligible`, `require_note`, `calc`, `default`, `permanent`) VALUES (44,'2.30','Max call attempts reached (Eligible)',0,1,0,1,1,1,0,'O',1,0);
|
INSERT INTO `outcome` (`outcome_id`, `aapor_id`, `description`, `default_delay_minutes`, `outcome_type_id`, `tryanother`, `contacted`, `tryagain`, `eligible`, `require_note`, `calc`, `default`, `permanent`) VALUES(44, '2.30', 'Max call attempts reached (Eligible)', 0, 1, 0, 1, 1, 1, 0, 'O', 1, 0);
|
||||||
INSERT INTO `outcome` (`outcome_id`, `aapor_id`, `description`, `default_delay_minutes`, `outcome_type_id`, `tryanother`, `contacted`, `tryagain`, `eligible`, `require_note`, `calc`, `default`, `permanent`) VALUES (45,'2.30','Max calls reached (Eligible)',0,1,0,1,1,1,0,'O',1,0);
|
INSERT INTO `outcome` (`outcome_id`, `aapor_id`, `description`, `default_delay_minutes`, `outcome_type_id`, `tryanother`, `contacted`, `tryagain`, `eligible`, `require_note`, `calc`, `default`, `permanent`) VALUES(45, '2.30', 'Max calls reached (Eligible)', 0, 1, 0, 1, 1, 1, 0, 'O', 1, 0);
|
||||||
|
|
||||||
-- Auto increment start from 100 for manual entries
|
-- Auto increment start from 100 for manual entries
|
||||||
|
|
||||||
ALTER TABLE `outcome` AUTO_INCREMENT = 100;
|
ALTER TABLE `outcome` AUTO_INCREMENT = 100;
|
||||||
|
|
||||||
|
|
||||||
-- --------------------------------------------------------
|
-- --------------------------------------------------------
|
||||||
|
|
||||||
--
|
--
|
||||||
@@ -562,7 +546,7 @@ CREATE TABLE `process` (
|
|||||||
`kill` tinyint(1) NOT NULL DEFAULT '0',
|
`kill` tinyint(1) NOT NULL DEFAULT '0',
|
||||||
`data` longtext COLLATE utf8_unicode_ci NOT NULL,
|
`data` longtext COLLATE utf8_unicode_ci NOT NULL,
|
||||||
PRIMARY KEY (`process_id`)
|
PRIMARY KEY (`process_id`)
|
||||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
|
||||||
|
|
||||||
-- --------------------------------------------------------
|
-- --------------------------------------------------------
|
||||||
|
|
||||||
@@ -577,7 +561,7 @@ CREATE TABLE `process_log` (
|
|||||||
`data` text COLLATE utf8_unicode_ci NOT NULL,
|
`data` text COLLATE utf8_unicode_ci NOT NULL,
|
||||||
PRIMARY KEY (`process_log_id`),
|
PRIMARY KEY (`process_log_id`),
|
||||||
KEY `process_id` (`process_id`)
|
KEY `process_id` (`process_id`)
|
||||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
|
||||||
|
|
||||||
-- --------------------------------------------------------
|
-- --------------------------------------------------------
|
||||||
|
|
||||||
@@ -594,7 +578,7 @@ CREATE TABLE `qsqr_question` (
|
|||||||
`description` text COLLATE utf8_unicode_ci NOT NULL,
|
`description` text COLLATE utf8_unicode_ci NOT NULL,
|
||||||
PRIMARY KEY (`qsqr_question_id`),
|
PRIMARY KEY (`qsqr_question_id`),
|
||||||
KEY `questionnaire_sample_quota_row_id` (`questionnaire_sample_quota_row_id`)
|
KEY `questionnaire_sample_quota_row_id` (`questionnaire_sample_quota_row_id`)
|
||||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
|
||||||
|
|
||||||
-- --------------------------------------------------------
|
-- --------------------------------------------------------
|
||||||
|
|
||||||
@@ -642,11 +626,11 @@ CREATE TABLE `questionnaire` (
|
|||||||
`lime_template` varchar(128) COLLATE utf8_unicode_ci DEFAULT NULL COMMENT 'Limesurvey template for respondent self completion',
|
`lime_template` varchar(128) COLLATE utf8_unicode_ci DEFAULT NULL COMMENT 'Limesurvey template for respondent self completion',
|
||||||
`lime_endurl` varchar(256) COLLATE utf8_unicode_ci DEFAULT NULL COMMENT 'Forwarding end URL for respondent self completion',
|
`lime_endurl` varchar(256) COLLATE utf8_unicode_ci DEFAULT NULL COMMENT 'Forwarding end URL for respondent self completion',
|
||||||
`enabled` tinyint(1) NOT NULL DEFAULT '1',
|
`enabled` tinyint(1) NOT NULL DEFAULT '1',
|
||||||
`outcomes` varchar(256) COLLATE utf8_unicode_ci NULL DEFAULT '1,2,3,7,9,10,14,17,18,19' COMMENT 'Comma-separated string of outcomes defined for the questionnaire',
|
`outcomes` varchar(256) COLLATE utf8_unicode_ci DEFAULT '1,2,3,7,9,10,14,17,18,19' COMMENT 'Comma-separated string of outcomes defined for the questionnaire',
|
||||||
`remote_id` int(11) NOT NULL,
|
`remote_id` int(11) NOT NULL,
|
||||||
PRIMARY KEY (`questionnaire_id`),
|
PRIMARY KEY (`questionnaire_id`),
|
||||||
KEY `remote_id` (`remote_id`)
|
KEY `remote_id` (`remote_id`)
|
||||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
|
||||||
|
|
||||||
-- --------------------------------------------------------
|
-- --------------------------------------------------------
|
||||||
|
|
||||||
@@ -673,7 +657,7 @@ CREATE TABLE `questionnaire_prefill` (
|
|||||||
`value` varchar(2048) COLLATE utf8_unicode_ci NOT NULL,
|
`value` varchar(2048) COLLATE utf8_unicode_ci NOT NULL,
|
||||||
PRIMARY KEY (`questionnaire_prefill_id`),
|
PRIMARY KEY (`questionnaire_prefill_id`),
|
||||||
KEY `questionnaire_id` (`questionnaire_id`)
|
KEY `questionnaire_id` (`questionnaire_id`)
|
||||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
|
||||||
|
|
||||||
-- --------------------------------------------------------
|
-- --------------------------------------------------------
|
||||||
|
|
||||||
@@ -728,7 +712,7 @@ CREATE TABLE `questionnaire_sample_quota` (
|
|||||||
`completions` int(11) NOT NULL,
|
`completions` int(11) NOT NULL,
|
||||||
`quota_reached` tinyint(1) NOT NULL DEFAULT '0',
|
`quota_reached` tinyint(1) NOT NULL DEFAULT '0',
|
||||||
PRIMARY KEY (`questionnaire_sample_quota_id`)
|
PRIMARY KEY (`questionnaire_sample_quota_id`)
|
||||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
|
||||||
|
|
||||||
-- --------------------------------------------------------
|
-- --------------------------------------------------------
|
||||||
|
|
||||||
@@ -749,7 +733,7 @@ CREATE TABLE `questionnaire_sample_quota_row` (
|
|||||||
PRIMARY KEY (`questionnaire_sample_quota_row_id`),
|
PRIMARY KEY (`questionnaire_sample_quota_row_id`),
|
||||||
KEY `questionnaire_id` (`questionnaire_id`),
|
KEY `questionnaire_id` (`questionnaire_id`),
|
||||||
KEY `sample_import_id` (`sample_import_id`)
|
KEY `sample_import_id` (`sample_import_id`)
|
||||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
|
||||||
|
|
||||||
-- --------------------------------------------------------
|
-- --------------------------------------------------------
|
||||||
|
|
||||||
@@ -793,6 +777,23 @@ CREATE TABLE `questionnaire_timeslot` (
|
|||||||
|
|
||||||
-- --------------------------------------------------------
|
-- --------------------------------------------------------
|
||||||
|
|
||||||
|
--
|
||||||
|
-- Table structure for table `remote`
|
||||||
|
--
|
||||||
|
|
||||||
|
CREATE TABLE `remote` (
|
||||||
|
`id` int(11) NOT NULL AUTO_INCREMENT,
|
||||||
|
`description` text COLLATE utf8_unicode_ci NOT NULL,
|
||||||
|
`rpc_url` text COLLATE utf8_unicode_ci NOT NULL,
|
||||||
|
`username` text COLLATE utf8_unicode_ci NOT NULL,
|
||||||
|
`password` text COLLATE utf8_unicode_ci NOT NULL,
|
||||||
|
`type` varchar(16) COLLATE utf8_unicode_ci NOT NULL DEFAULT 'limesurvey' COMMENT 'type of host',
|
||||||
|
`entry_url` text COLLATE utf8_unicode_ci NOT NULL COMMENT 'entry url for interviewers',
|
||||||
|
PRIMARY KEY (`id`)
|
||||||
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
|
||||||
|
|
||||||
|
-- --------------------------------------------------------
|
||||||
|
|
||||||
--
|
--
|
||||||
-- Table structure for table `respondent`
|
-- Table structure for table `respondent`
|
||||||
--
|
--
|
||||||
@@ -805,7 +806,7 @@ CREATE TABLE `respondent` (
|
|||||||
`Time_zone_name` char(64) COLLATE utf8_unicode_ci NOT NULL,
|
`Time_zone_name` char(64) COLLATE utf8_unicode_ci NOT NULL,
|
||||||
PRIMARY KEY (`respondent_id`),
|
PRIMARY KEY (`respondent_id`),
|
||||||
KEY `case_id` (`case_id`)
|
KEY `case_id` (`case_id`)
|
||||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
|
||||||
|
|
||||||
-- --------------------------------------------------------
|
-- --------------------------------------------------------
|
||||||
|
|
||||||
@@ -835,7 +836,7 @@ CREATE TABLE `sample` (
|
|||||||
`phone` char(30) COLLATE utf8_unicode_ci NOT NULL,
|
`phone` char(30) COLLATE utf8_unicode_ci NOT NULL,
|
||||||
PRIMARY KEY (`sample_id`),
|
PRIMARY KEY (`sample_id`),
|
||||||
KEY `import_id` (`import_id`)
|
KEY `import_id` (`import_id`)
|
||||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
|
||||||
|
|
||||||
-- --------------------------------------------------------
|
-- --------------------------------------------------------
|
||||||
|
|
||||||
@@ -850,7 +851,7 @@ CREATE TABLE `sample_import` (
|
|||||||
`refusal_conversion` tinyint(1) NOT NULL DEFAULT '1',
|
`refusal_conversion` tinyint(1) NOT NULL DEFAULT '1',
|
||||||
`enabled` tinyint(1) NOT NULL DEFAULT '1',
|
`enabled` tinyint(1) NOT NULL DEFAULT '1',
|
||||||
PRIMARY KEY (`sample_import_id`)
|
PRIMARY KEY (`sample_import_id`)
|
||||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
|
||||||
|
|
||||||
-- --------------------------------------------------------
|
-- --------------------------------------------------------
|
||||||
|
|
||||||
@@ -865,7 +866,7 @@ CREATE TABLE `sample_import_var_restrict` (
|
|||||||
`type` smallint(10) unsigned NOT NULL,
|
`type` smallint(10) unsigned NOT NULL,
|
||||||
`restrict` tinyint(1) NOT NULL DEFAULT '0',
|
`restrict` tinyint(1) NOT NULL DEFAULT '0',
|
||||||
PRIMARY KEY (`var_id`)
|
PRIMARY KEY (`var_id`)
|
||||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
|
||||||
|
|
||||||
-- --------------------------------------------------------
|
-- --------------------------------------------------------
|
||||||
|
|
||||||
@@ -1031,6 +1032,29 @@ CREATE TABLE `timezone_template` (
|
|||||||
PRIMARY KEY (`Time_zone_name`)
|
PRIMARY KEY (`Time_zone_name`)
|
||||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
|
||||||
|
|
||||||
|
-- --------------------------------------------------------
|
||||||
|
|
||||||
|
--
|
||||||
|
-- Table structure for table `users`
|
||||||
|
--
|
||||||
|
|
||||||
|
CREATE TABLE `users` (
|
||||||
|
`uid` int(11) NOT NULL AUTO_INCREMENT,
|
||||||
|
`users_name` varchar(64) COLLATE utf8_unicode_ci NOT NULL DEFAULT '',
|
||||||
|
`password` blob NOT NULL,
|
||||||
|
`full_name` varchar(50) COLLATE utf8_unicode_ci NOT NULL,
|
||||||
|
`email` varchar(320) COLLATE utf8_unicode_ci DEFAULT NULL,
|
||||||
|
`superadmin` tinyint(1) NOT NULL DEFAULT '0',
|
||||||
|
PRIMARY KEY (`uid`),
|
||||||
|
UNIQUE KEY `users_name` (`users_name`)
|
||||||
|
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci;
|
||||||
|
|
||||||
|
--
|
||||||
|
-- Dumping data for table `users`
|
||||||
|
--
|
||||||
|
|
||||||
|
INSERT INTO `users` (`uid`, `users_name`, `password`, `full_name`, `email`, `superadmin`) VALUES(1, 'admin', 0x35653838343839386461323830343731353164306535366638646336323932373733363033643064366161626264643632613131656637323164313534326438, 'Your Name', 'your-email@example.net', 1);
|
||||||
|
|
||||||
/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
|
/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
|
||||||
/*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
|
/*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
|
||||||
/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
|
/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
|
||||||
|
|||||||
19
email.php
19
email.php
@@ -81,24 +81,15 @@ if (isset($_POST['email']) && ((isset($_POST['firstname']) && !empty($_POST['fir
|
|||||||
$lime_sid = get_lime_sid($case_id);
|
$lime_sid = get_lime_sid($case_id);
|
||||||
$ca = get_call_attempt($operator_id);
|
$ca = get_call_attempt($operator_id);
|
||||||
$token = get_token($case_id);
|
$token = get_token($case_id);
|
||||||
$email = $db->qstr($_POST['email']);
|
$email = ($_POST['email']);
|
||||||
$firstname = $db->qstr($_POST['firstname']);
|
$firstname = ($_POST['firstname']);
|
||||||
$lastname = $db->qstr($_POST['lastname']);
|
$lastname = ($_POST['lastname']);
|
||||||
|
|
||||||
|
|
||||||
//set in Limesurvey
|
$ret = lime_send_email($case_id,$email,$firstname,$lastname);
|
||||||
//set_participant_properties($sSessionKey, $lime_sid, array['token' => $token], array['email' => $email, 'firstname' => $firstname, 'lastname' => $lastname, 'emailstatus' => 'OK']);
|
|
||||||
|
|
||||||
|
if ($ret) //if mail sent
|
||||||
if (0) //if mail sent - disable temporarily TODO: update properties in limesurvey
|
|
||||||
{
|
{
|
||||||
// Put call attempt id in to sent in Limesurvey
|
|
||||||
$sql = "UPDATE ". LIME_PREFIX . "tokens_{$lime_sid}
|
|
||||||
SET sent='$ca'
|
|
||||||
WHERE token='$token'";
|
|
||||||
|
|
||||||
//$db->Execute($sql);
|
|
||||||
|
|
||||||
//Add a note that sent
|
//Add a note that sent
|
||||||
|
|
||||||
$sql = "INSERT INTO `case_note` (case_id,operator_id,note,datetime)
|
$sql = "INSERT INTO `case_note` (case_id,operator_id,note,datetime)
|
||||||
|
|||||||
@@ -150,13 +150,49 @@ function lime_list_answeroptions($qid,$qcode)
|
|||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/** Get completed responses as an array based on the case_id
|
function lime_send_email($case_id,$email,$firstname,$lastname)
|
||||||
*/
|
|
||||||
function lime_get_responses_by_case($case_id,$fields)
|
|
||||||
{
|
{
|
||||||
global $db;
|
global $db;
|
||||||
global $limeRPC;
|
global $limeRPC;
|
||||||
global $limeKey;
|
global $limeKey;
|
||||||
|
|
||||||
|
$sql = "SELECT c.token,c.questionnaire_id
|
||||||
|
FROM `case` as c
|
||||||
|
WHERE c.case_id = '$case_id'";
|
||||||
|
|
||||||
|
$rs = $db->GetRow($sql);
|
||||||
|
|
||||||
|
$token = $rs['token'];
|
||||||
|
$qid = $rs['questionnaire_id'];
|
||||||
|
|
||||||
|
$lime_id = limerpc_init_qid($qid);
|
||||||
|
|
||||||
|
$ret = false;
|
||||||
|
|
||||||
|
if ($lime_id !== false) {
|
||||||
|
$q = $limeRPC->set_participant_properties($limeKey,$lime_id,array('token' => $token),array('firstname' => $firstname, 'email' => $email, 'lastname' => $lastname));
|
||||||
|
if (!isset($q['status'])) {
|
||||||
|
//send email
|
||||||
|
$q2 = $limeRPC->invite_participants($limeKey, $lime_id, array($q['tid']));
|
||||||
|
if (!isset($q['status'])) {
|
||||||
|
$ret = true;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
limerpc_close();
|
||||||
|
|
||||||
|
return $ret;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/** Get completed responses as an array based on the case_id
|
||||||
|
*/
|
||||||
|
function lime_get_responses_by_case($case_id,$fields = null)
|
||||||
|
{
|
||||||
|
global $db;
|
||||||
|
global $limeRPC;
|
||||||
|
global $limeKey;
|
||||||
|
|
||||||
$sql = "SELECT c.token,c.questionnaire_id
|
$sql = "SELECT c.token,c.questionnaire_id
|
||||||
FROM `case` as c
|
FROM `case` as c
|
||||||
@@ -165,7 +201,7 @@ function lime_get_responses_by_case($case_id,$fields)
|
|||||||
$rs = $db->GetRow($sql);
|
$rs = $db->GetRow($sql);
|
||||||
|
|
||||||
$token = $rs['token'];
|
$token = $rs['token'];
|
||||||
$qid = $rs['qid'];
|
$qid = $rs['questionnaire_id'];
|
||||||
|
|
||||||
$lime_id = limerpc_init_qid($qid);
|
$lime_id = limerpc_init_qid($qid);
|
||||||
|
|
||||||
@@ -175,12 +211,10 @@ function lime_get_responses_by_case($case_id,$fields)
|
|||||||
$q = $limeRPC->export_responses_by_token($limeKey,$lime_id,'json',$token,null,'complete','code','short',$fields);
|
$q = $limeRPC->export_responses_by_token($limeKey,$lime_id,'json',$token,null,'complete','code','short',$fields);
|
||||||
if (!isset($q['status'])) {
|
if (!isset($q['status'])) {
|
||||||
$ret = json_decode(base64_decode($q));
|
$ret = json_decode(base64_decode($q));
|
||||||
//TODO: check how this returns
|
|
||||||
var_dump($ret); die();
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
limerpc_close();
|
limerpc_close();
|
||||||
|
|
||||||
return $ret;
|
return $ret;
|
||||||
|
|
||||||
@@ -190,7 +224,7 @@ function lime_get_responses_by_case($case_id,$fields)
|
|||||||
/** Get completd responses as an array based on the questionnaire
|
/** Get completd responses as an array based on the questionnaire
|
||||||
* indexed by token
|
* indexed by token
|
||||||
*/
|
*/
|
||||||
function lime_get_responses_by_questionnaire($qid,$fields)
|
function lime_get_responses_by_questionnaire($qid,$fields = null)
|
||||||
{
|
{
|
||||||
global $limeRPC;
|
global $limeRPC;
|
||||||
global $limeKey;
|
global $limeKey;
|
||||||
@@ -203,8 +237,6 @@ function lime_get_responses_by_questionnaire($qid,$fields)
|
|||||||
$q = $limeRPC->export_responses($limeKey,$lime_id,'json',null,'complete','code','short',null,null,$fields);
|
$q = $limeRPC->export_responses($limeKey,$lime_id,'json',null,'complete','code','short',null,null,$fields);
|
||||||
if (!isset($q['status'])) {
|
if (!isset($q['status'])) {
|
||||||
$ret = json_decode(base64_decode($q));
|
$ret = json_decode(base64_decode($q));
|
||||||
//TODO: check how this returns
|
|
||||||
var_dump($ret); die();
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -234,7 +266,6 @@ function lime_add_token($qid,$params)
|
|||||||
return $ret;
|
return $ret;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
function get_token_value($questionnaire_id,$token, $value = 'sent')
|
function get_token_value($questionnaire_id,$token, $value = 'sent')
|
||||||
{
|
{
|
||||||
global $limeKey;
|
global $limeKey;
|
||||||
@@ -301,7 +332,6 @@ function get_survey_list ()
|
|||||||
* @param mixed $email
|
* @param mixed $email
|
||||||
* @param resource $replace Optional, defaults to ''.
|
* @param resource $replace Optional, defaults to ''.
|
||||||
*
|
*
|
||||||
* @return TODO
|
|
||||||
* @author Adam Zammit <adam.zammit@acspri.org.au>
|
* @author Adam Zammit <adam.zammit@acspri.org.au>
|
||||||
* @since 2013-02-26
|
* @since 2013-02-26
|
||||||
*/
|
*/
|
||||||
@@ -525,6 +555,25 @@ function validate_email($email){
|
|||||||
return TRUE;
|
return TRUE;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
function lime_compare($val1,$operator,$val2)
|
||||||
|
{
|
||||||
|
$val1 = trim($val1);
|
||||||
|
$val2 = trim($val2);
|
||||||
|
if ($operator == "<")
|
||||||
|
return ($val1 < $val2);
|
||||||
|
else if ($operator == ">")
|
||||||
|
return ($val1 > $val2);
|
||||||
|
else if ($operator == "<=")
|
||||||
|
return ($val1 <= $val2);
|
||||||
|
else if ($operator == ">=")
|
||||||
|
return ($val1 >= $val2);
|
||||||
|
else if ($operator == "NOT LIKE" || $operator == "!=")
|
||||||
|
return ($val1 != $val2);
|
||||||
|
else
|
||||||
|
return ($val1 == $val2);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Return the number of completions for a given
|
* Return the number of completions for a given
|
||||||
* questionnaire, where the given question has
|
* questionnaire, where the given question has
|
||||||
@@ -543,25 +592,32 @@ function limesurvey_quota_completions($lime_sgqa,$lime_sid,$questionnaire_id,$sa
|
|||||||
{
|
{
|
||||||
global $db;
|
global $db;
|
||||||
|
|
||||||
$resp = lime_get_responses_by_questionnaire($questionnaire_id,array($lime_sgqa));
|
$resp = lime_get_responses_by_questionnaire($questionnaire_id);
|
||||||
|
|
||||||
$completions = false;
|
$completions = false;
|
||||||
|
|
||||||
if ($resp !== false) {
|
if ($resp !== false) {
|
||||||
$sql = "SELECT c.token
|
$sql = "SELECT c.token,c.token as tok
|
||||||
FROM `case` as c
|
FROM `case` as c
|
||||||
JOIN `sample` as sam ON (c.sample_id = sam.sample_id AND sam.import_id = '$sample_import_id')
|
JOIN `sample` as sam ON (c.sample_id = sam.sample_id AND sam.import_id = '$sample_import_id')
|
||||||
WHERE c.questionnaire_id = '$questionnaire_id'";
|
WHERE c.questionnaire_id = '$questionnaire_id'";
|
||||||
|
|
||||||
$rs = $db->GetAssoc($sql);
|
$rs = $db->GetAssoc($sql);
|
||||||
|
|
||||||
$completions = 0;
|
$completions = 0;
|
||||||
|
foreach($resp as $r) {
|
||||||
foreach($resp as $r) {
|
foreach($r as $r1) {
|
||||||
|
foreach($r1 as $rl) {
|
||||||
|
if (isset($rl->token) && isset($rs[$rl->token])) {
|
||||||
|
//match to a case in the sample
|
||||||
|
if (isset($rl->$lime_sgqa)) {
|
||||||
|
$completions += lime_compare($rl->$lime_sgqa, $comparison, $value);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
return $completions;
|
return $completions;
|
||||||
}
|
}
|
||||||
@@ -710,7 +766,7 @@ function limesurvey_percent_complete($case_id)
|
|||||||
global $db;
|
global $db;
|
||||||
|
|
||||||
|
|
||||||
//TODO: use export_responses_by_token and check the lastpage variable
|
//TODO: use export_responses_by_token and check the lastpage variable?
|
||||||
//
|
//
|
||||||
|
|
||||||
return false;
|
return false;
|
||||||
|
|||||||
@@ -436,19 +436,24 @@ function add_case($sample_id,$questionnaire_id,$operator_id = "NULL",$testing =
|
|||||||
$llastname = "";
|
$llastname = "";
|
||||||
$lemail = "";
|
$lemail = "";
|
||||||
|
|
||||||
$lfirstname = ($db->GetOne("SELECT sv.val
|
$params = array('firstname' => "",
|
||||||
|
'lastname' => "",
|
||||||
|
'email' => "",
|
||||||
|
'token' => $token);
|
||||||
|
|
||||||
|
$params['firstname'] = ($db->GetOne("SELECT sv.val
|
||||||
FROM sample_var as sv, sample_import_var_restrict as s
|
FROM sample_var as sv, sample_import_var_restrict as s
|
||||||
WHERE sv.var_id = s.var_id
|
WHERE sv.var_id = s.var_id
|
||||||
AND sv.sample_id = '$sample_id'
|
AND sv.sample_id = '$sample_id'
|
||||||
AND s.type = '6'"));
|
AND s.type = '6'"));
|
||||||
|
|
||||||
$llastname = ($db->GetOne("SELECT sv.val
|
$params['lastname'] = ($db->GetOne("SELECT sv.val
|
||||||
FROM sample_var as sv, sample_import_var_restrict as s
|
FROM sample_var as sv, sample_import_var_restrict as s
|
||||||
WHERE sv.var_id = s.var_id
|
WHERE sv.var_id = s.var_id
|
||||||
AND sv.sample_id = '$sample_id'
|
AND sv.sample_id = '$sample_id'
|
||||||
AND s.type = '7'"));
|
AND s.type = '7'"));
|
||||||
|
|
||||||
$lemail = ($db->GetOne("SELECT sv.val
|
$params['email'] = ($db->GetOne("SELECT sv.val
|
||||||
FROM sample_var as sv, sample_import_var_restrict as s
|
FROM sample_var as sv, sample_import_var_restrict as s
|
||||||
WHERE sv.var_id = s.var_id
|
WHERE sv.var_id = s.var_id
|
||||||
AND sv.sample_id = '$sample_id'
|
AND sv.sample_id = '$sample_id'
|
||||||
@@ -457,19 +462,32 @@ function add_case($sample_id,$questionnaire_id,$operator_id = "NULL",$testing =
|
|||||||
//include limesurvey functions
|
//include limesurvey functions
|
||||||
include_once(dirname(__FILE__).'/functions.limesurvey.php');
|
include_once(dirname(__FILE__).'/functions.limesurvey.php');
|
||||||
|
|
||||||
$ret = lime_add_token($questionnaire_id,array( 'firstname' => $lfirstname,
|
if ($addlimeattributes)
|
||||||
'lastname' => $llastname,
|
|
||||||
'email' => $lemail,
|
|
||||||
'token' => $token));
|
|
||||||
|
|
||||||
//fail to create case if can't add remote token
|
|
||||||
if ($ret === false)
|
|
||||||
$db->FailTrans();
|
|
||||||
|
|
||||||
if ($addlimeattributes)
|
|
||||||
{
|
{
|
||||||
//TODO: Add attributes from sample
|
$sql = "SELECT sv.val
|
||||||
|
FROM sample_var as sv, sample_import_var_restrict as s
|
||||||
|
WHERE sv.var_id = s.var_id
|
||||||
|
AND sv.sample_id = '$sample_id'
|
||||||
|
AND s.type = '1'
|
||||||
|
ORDER BY s.var_id ASC";
|
||||||
|
|
||||||
|
$vars = $db->GetAll($sql);
|
||||||
|
|
||||||
|
$att = 1;
|
||||||
|
|
||||||
|
foreach($vars as $v) {
|
||||||
|
$params['attribute_' . $att] = $v['val'];
|
||||||
|
$att++;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
$ret = lime_add_token($questionnaire_id,$params);
|
||||||
|
|
||||||
|
//fail to create case if can't add remote token
|
||||||
|
if ($ret === false) {
|
||||||
|
$db->FailTrans();
|
||||||
|
$case_id = false;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -1776,13 +1794,16 @@ function update_single_row_quota($qsqri,$case_id = false)
|
|||||||
//get response data from Limesurvey
|
//get response data from Limesurvey
|
||||||
$resp = lime_get_responses_by_case($case_id);
|
$resp = lime_get_responses_by_case($case_id);
|
||||||
|
|
||||||
|
//get the result from the current response
|
||||||
|
$resp = current(current(current($resp)));
|
||||||
|
|
||||||
foreach($qev as $ev)
|
foreach($qev as $ev)
|
||||||
{
|
{
|
||||||
$sql2 .= " AND '" . $resp[$ev['lime_sgqa']] . " ' {$ev['comparison']} '{$ev['value']}' ";
|
$sql2 .= " AND '" . trim($resp->$ev['lime_sgqa']) . "' {$ev['comparison']} '{$ev['value']}' ";
|
||||||
}
|
}
|
||||||
|
|
||||||
$match = $db->GetOne($sql2);
|
$match = $db->GetOne($sql2);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
if ($match == 1)
|
if ($match == 1)
|
||||||
@@ -1823,24 +1844,40 @@ function update_single_row_quota($qsqri,$case_id = false)
|
|||||||
else
|
else
|
||||||
{
|
{
|
||||||
//find all completions from cases with matching limesurvey records
|
//find all completions from cases with matching limesurvey records
|
||||||
$sql2 = "SELECT token
|
|
||||||
FROM `case` as c
|
|
||||||
WHERE c.questionnaire_id = '$questionnaire_id'";
|
|
||||||
|
|
||||||
//get all completed responses from limesurvey, indexed by token
|
|
||||||
|
|
||||||
include_once(dirname(__FILE__).'/functions.limesurvey.php');
|
include_once(dirname(__FILE__).'/functions.limesurvey.php');
|
||||||
$resp = lime_get_responses_by_questionnaire($questionnaire_id);
|
$resp = lime_get_responses_by_questionnaire($questionnaire_id);
|
||||||
|
|
||||||
foreach($qev as $ev)
|
if ($resp !== false) {
|
||||||
{
|
|
||||||
//TODO: Exclude responses from the $resp array where there isn't a match
|
$sql2 = "SELECT c.token,c.token as tok
|
||||||
//based on the comparisons
|
FROM `case` as c
|
||||||
$sql2 .= " AND s.`{$ev['lime_sgqa']}` {$ev['comparison']} '{$ev['value']}' ";
|
JOIN `sample` as sam ON (c.sample_id = sam.sample_id AND sam.import_id = '$sample_import_id')
|
||||||
|
WHERE c.questionnaire_id = '$questionnaire_id'";
|
||||||
|
|
||||||
|
$rs = $db->GetAssoc($sql2);
|
||||||
|
|
||||||
|
foreach($resp as $r) {
|
||||||
|
foreach($r as $r1) {
|
||||||
|
foreach($r1 as $rl) {
|
||||||
|
if (isset($rl->token) && isset($rs[$rl->token])) {
|
||||||
|
//match to a case in the sample
|
||||||
|
$tmp = 0;
|
||||||
|
foreach($qev as $ev) {
|
||||||
|
if (isset($rl->$ev['lime_sgqa'])) {
|
||||||
|
$tmp = lime_compare($rl->$ev['lime_sgqa'], $ev['comparison'], $ev['value']);
|
||||||
|
if ($tmp != 1) {
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
$completions += $tmp;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
$completions = count($resp);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
$updatequota = true;
|
$updatequota = true;
|
||||||
@@ -2465,11 +2502,8 @@ function get_limesurvey_id($operator_id,$rs = false)
|
|||||||
else
|
else
|
||||||
$sql = "SELECT q.lime_sid as sid";
|
$sql = "SELECT q.lime_sid as sid";
|
||||||
|
|
||||||
$sql .= " FROM `case` as c, questionnaire_sample as qs, sample as s, questionnaire as q
|
$sql .= " FROM `case` as c, questionnaire as q
|
||||||
WHERE c.current_operator_id = '$operator_id'
|
WHERE c.current_operator_id = '$operator_id'
|
||||||
AND c.sample_id = s.sample_id
|
|
||||||
AND s.import_id = qs.sample_import_id
|
|
||||||
AND q.questionnaire_id = qs.questionnaire_id
|
|
||||||
AND c.questionnaire_id = q.questionnaire_id";
|
AND c.questionnaire_id = q.questionnaire_id";
|
||||||
|
|
||||||
$rs = $db->GetRow($sql);
|
$rs = $db->GetRow($sql);
|
||||||
|
|||||||
Reference in New Issue
Block a user