Переглянути джерело

Adjusting tecant to run in parallel with other crf implementations of CRF -> renamed web directory to crfTecant, changed redirect landing page to crf_tecant, relabeled module as crf_tecant in config.module.xml, renamed all webparts to avoid clash with other CRF named web parts

Andrej Studen 2 роки тому
батько
коміт
44e8b67b0a

+ 2 - 2
config/module.xml

@@ -4,8 +4,8 @@
        xmlns:util="http://www.springframework.org/schema/util"
        xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-2.0.xsd">
     <bean id="moduleBean" class="org.labkey.api.module.SimpleModule">
-        <property name="name" value="CRF-TECANT"/>
-	    <!--<property name="version" value="0.1"/>-->
+        <property name="name" value="CRF_TECANT"/>
+	    <property name="version" value="0.1"/>
         <property name="requiredServerVersion" value="0.0"/>
         <property name="moduleDependencies" value=""/>
 	    <!--<property name="svnRevision" value="0"/>-->

+ 2 - 2
views/approvedPortal.view.xml

@@ -1,6 +1,6 @@
-<view xmlns="http://labkey.org/data/xml/view" title="Approved CRF Portal">
+<view xmlns="http://labkey.org/data/xml/view" title="Approved CRF Portal (Tecant)">
 	<dependencies>
-			<dependency path="crf/formPortal.js"/>
+			<dependency path="crfTecant/formPortal.js"/>
 		</dependencies>
 	<permissions>
 		<permission name="login"/>

+ 1 - 1
views/approvedPortal.webpart.xml

@@ -1,4 +1,4 @@
 <webpart xlmns="http://labkey.org/data/xml/webpart"
-	title="CRF Manager Portal">
+	title="CRF Manager Portal (Tecant)">
 	<view name="approvedPortal"/>
 </webpart>

+ 2 - 2
views/completedPortal.view.xml

@@ -1,6 +1,6 @@
-<view xmlns="http://labkey.org/data/xml/view" title="Completed CRF Portal">
+<view xmlns="http://labkey.org/data/xml/view" title="Completed CRF Portal (Tecant)">
 	<dependencies>
-			<dependency path="crf/formPortal.js"/>
+			<dependency path="crfTecant/formPortal.js"/>
 		</dependencies>
 	<permissions>
 		<permission name="login"/>

+ 1 - 1
views/completedPortal.webpart.xml

@@ -1,4 +1,4 @@
 <webpart xlmns="http://labkey.org/data/xml/webpart"
-	title="CRF Completed Portal">
+	title="CRF Completed Portal (Tecant)">
 	<view name="completedPortal"/>
 </webpart>

+ 3 - 3
views/crfManager.view.xml

@@ -1,8 +1,8 @@
 <view xmlns="http://labkey.org/data/xml/view" title="CRF Management" frame="portal">
 	<dependencies>
-		<dependency path="crf/crfManager.js"/>
-		<dependency path="crf/pdfkit.standalone.js" />
-		<dependency path="crf/blob-stream.js"/>
+		<dependency path="crfTecant/crfManager.js"/>
+		<dependency path="crfTecant/pdfkit.standalone.js" />
+		<dependency path="crfTecant/blob-stream.js"/>
 	</dependencies>
 	<permissions>
 		<permission name="login"/>

+ 1 - 1
views/crfManager.webpart.xml

@@ -1,4 +1,4 @@
 <webpart xlmns="http://labkey.org/data/xml/webpart"
-	title="CRF Manager">
+	title="CRF Manager (Tecant)">
 	<view name="crfManager"/>
 </webpart>

+ 2 - 2
views/formPortal.view.xml

@@ -1,6 +1,6 @@
-<view xmlns="http://labkey.org/data/xml/view" title="FORM Portal" frame="portal">
+<view xmlns="http://labkey.org/data/xml/view" title="FORM Portal (Tecant)" frame="portal">
 	<dependencies>
-		<dependency path="crf/formPortal.js"/>
+		<dependency path="crfTecant/formPortal.js"/>
 	</dependencies>
 	<permissions>
 		<permission name="login"/>

+ 1 - 1
views/formPortal.webpart.xml

@@ -1,4 +1,4 @@
 <webpart xlmns="http://labkey.org/data/xml/webpart"
-	title="CRF Portal">
+	title="CRF Portal (Tecant)">
 	<view name="formPortal"/>
 </webpart>

+ 2 - 2
views/reviewPortal.view.xml

@@ -1,6 +1,6 @@
-<view xmlns="http://labkey.org/data/xml/view" title="Review Portal">
+<view xmlns="http://labkey.org/data/xml/view" title="Review Portal (Tecant)">
 	<dependencies>
-			<dependency path="crf/formPortal.js"/>
+			<dependency path="crfTecant/formPortal.js"/>
 		</dependencies>
 	<permissions>
 		<permission name="login"/>

+ 1 - 1
views/reviewPortal.webpart.xml

@@ -1,4 +1,4 @@
 <webpart xlmns="http://labkey.org/data/xml/webpart"
-	title="CRF Review Portal">
+	title="CRF Review Portal (Tecant)">
 	<view name="reviewPortal"/>
 </webpart>

+ 7 - 7
views/visit.view.xml

@@ -1,15 +1,15 @@
-<view xmlns="http://labkey.org/data/xml/view" title="CRF Form">
+<view xmlns="http://labkey.org/data/xml/view" title="CRF Form (Tecant)">
 	<dependencies>
-      <dependency path="crf/runQuery.js"/>
-      <dependency path="crf/participantIdManager.js"/>
-      <dependency path="crf/crfVisit.js"/>
-		<dependency path="crf/crfReview.js"/>
+      <dependency path="crfTecant/runQuery.js"/>
+      <dependency path="crfTecant/participantIdManager.js"/>
+      <dependency path="crfTecant/crfVisit.js"/>
+		<dependency path="crfTecant/crfReview.js"/>
 		<!--local copy of pdfkit, version 0.10.0-->
 		<!--https://github.com/devongovett/pdfkit/releases/download/v0.10.0/pdfkit.standalone.js-->
-		<dependency path="crf/pdfkit.standalone.js" />
+		<dependency path="crfTecant/pdfkit.standalone.js" />
 		<!--local copy of blob-stream, version 0.1.3-->
 		<!--https://github.com/devongovett/blob-stream/releases/download/v0.1.3/blob-stream.js-->
-		<dependency path="crf/blob-stream.js"/>
+		<dependency path="crfTecant/blob-stream.js"/>
 
  </dependencies>
 </view>

+ 0 - 0
web/crf/blob-stream.js → web/crfTecant/blob-stream.js


+ 0 - 0
web/crf/blob-stream.js.license → web/crfTecant/blob-stream.js.license


+ 0 - 0
web/crf/crfManager.js → web/crfTecant/crfManager.js


+ 0 - 0
web/crf/crfParticipant.js → web/crfTecant/crfParticipant.js


+ 0 - 0
web/crf/crfReview.js → web/crfTecant/crfReview.js


+ 3 - 0
web/crf/crfVisit.js → web/crfTecant/crfVisit.js

@@ -3125,6 +3125,8 @@ function collectData(){
 }
 
 function addStudyData(){
+   let fName='addStudyData';
+   print(fName);
 	let queryArray=new Array();
 	
    let targetObject=config.formConfig;
@@ -3147,6 +3149,7 @@ function addStudyData(){
 	e.columns=columnModel;
 
    //also collect ids already in study
+   //registrationQuery should be a dataset
    let demoQuery=config.formConfig.settings['registrationQuery'];
 
    queryArray.push(makeQuery(targetObject,'data',demoQuery,'registrationData',[]));

+ 1 - 1
web/crf/formPortal.js → web/crfTecant/formPortal.js

@@ -484,7 +484,7 @@ function openForm(crfEntry){
 	let containerPath= LABKEY.ActionURL.getContainer();
    // This changes the page after building the URL. 
 	//Note that the wiki page destination name is set in params.
-   var wikiURL = LABKEY.ActionURL.buildURL("crf", formUrl , containerPath, params);
+   var wikiURL = LABKEY.ActionURL.buildURL("crf_tecant", formUrl , containerPath, params);
    print("Redirecting to "+wikiURL);
 
 		 

+ 0 - 0
web/crf/participantIdManager.js → web/crfTecant/participantIdManager.js


+ 0 - 0
web/crf/pdfkit.standalone.js → web/crfTecant/pdfkit.standalone.js


+ 0 - 0
web/crf/pdfkit.standalone.js.license → web/crfTecant/pdfkit.standalone.js.license


+ 6 - 5
web/crf/runQuery.js → web/crfTecant/runQuery.js

@@ -35,11 +35,12 @@ function afterQuery(data,id,queryArray,cb){
 	//it should be called with id -1.
 	//
 	//targetObject.print('afterQuery1['+id+'/'+queryArray.length+']: ');
+   let fName='[afterQuery]';
 
 	if (id>-1){
 	   let e1=queryArray[id];
 		let fieldName=e1.fieldName;
-		e1.targetObject.print('afterQuery['+fieldName+']: '+data.rows.length);
+		e1.targetObject.print(fName+' ['+fieldName+']: '+data.rows.length);
 		e1.targetObject[fieldName]=data;
 	}
 	id+=1;
@@ -54,12 +55,12 @@ function afterQuery(data,id,queryArray,cb){
 	qconfig.containerPath=e.targetObject.getContainer(e.containerName);
 	qconfig.schemaName="lists";
 	if ("schemaName" in e){
-		e.targetObject.print('afterQuery: schemaName='+e.schemaName);
+		e.targetObject.print(fName+' schemaName='+e.schemaName);
 		qconfig.schemaName=e.schemaName;
 	}
 
 	if ("columns" in e){
-		e.targetObject.print('afterQuery: columns='+e.columns);
+		e.targetObject.print(fName+' columns='+e.columns);
 		qconfig.columns=e.columns;
 	}
 	qconfig.queryName=e.queryName;
@@ -71,12 +72,12 @@ function afterQuery(data,id,queryArray,cb){
 	
 	//qconfig.filterArray=[LABKEY.Filter.create('formStatus',1)]
 	qconfig.success=function(data){afterQuery(data,id,queryArray,cb);};
-	qconfig.failure=function(errorInfo,responseObj){onFailure(e.targetObject,errorInfo,responseObj);};
+	qconfig.failure=function(errorInfo,responseObj){onTAFailure(e.targetObject,errorInfo,responseObj);};
 	LABKEY.Query.selectRows(qconfig);
 
 }
 
-function onFailure(targetObj, errorInfo, responseObj){
+function onTAFailure(targetObj, errorInfo, responseObj){
    //don't have configObject to rely to
    targetObj.print('[afterQuery]: Failure: '+errorInfo.exception);