Skip to content

Commit

Permalink
Merge pull request #326 from ReproNim/fix/static
Browse files Browse the repository at this point in the history
fix: temporary fix for static
  • Loading branch information
satra authored Jun 12, 2024
2 parents 05096f0 + 9087f45 commit 364eb4f
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 10 deletions.
2 changes: 1 addition & 1 deletion src/App.vue
Original file line number Diff line number Diff line change
Expand Up @@ -454,7 +454,7 @@ export default {
}
},
async computeVisibilityCondition(cond, index) {
console.log('computeVisibilityCondition', cond, index);
// console.log('computeVisibilityCondition', cond, index);
if (_.isObject(cond)) {
const request = {
method: cond.method,
Expand Down
7 changes: 5 additions & 2 deletions src/components/InputSelector/InputSelector.vue
Original file line number Diff line number Diff line change
Expand Up @@ -196,6 +196,7 @@
:constraints="valueConstraints"
:selected_language="selected_language"
:result="true"
:input="title"
:init="init" v-on:valueChanged="sendData"/>
</div>

Expand All @@ -215,12 +216,14 @@
:init="init" v-on:valueChanged="sendData"/>
</div>

<!--
<div v-else-if="inputType === 'static'">
<Static
:constraints="valueConstraints"
:selected_language="selected_language"
:init="init" v-on:valueChanged="sendData"/>
</div>
-->

<!-- if we don't have a component built for this type, then show an error -->
<div v-else>
Expand Down Expand Up @@ -261,7 +264,7 @@ import SelectInput from '../Inputs/SelectInput';
import StaticReadOnly from '../Inputs/StaticReadOnly';
import SaveData from '../Inputs/SaveData/SaveData';
import StudySign from '../StudySign/StudySign';
import Static from '../Inputs/Static';
// import Static from '../Inputs/Static';
import EmailInput from '../Inputs/EmailInput';
import ParticipantId from '../Inputs/ParticipantId/ParticipantId';
Expand Down Expand Up @@ -325,7 +328,7 @@ export default {
TimeRange,
SelectInput,
StaticReadOnly,
Static,
// Static,
},
data() {
return {
Expand Down
10 changes: 3 additions & 7 deletions src/components/Inputs/StaticReadOnly/StaticReadOnly.vue
Original file line number Diff line number Diff line change
@@ -1,9 +1,7 @@
<template>
<div class="staticReadOnly">
<div v-if="input">
<h4> {{ input }}</h4>
<br>
<b-btn @click="onSubmit"> Done </b-btn>
<div v-if="true">
<b-btn @click="onSubmit"> Done reading </b-btn>
</div>
<div v-else>
<b-alert show>
Expand All @@ -24,9 +22,7 @@ export default {
methods: {
onSubmit(e) {
e.preventDefault();
if (this.input) {
this.$emit('valueChanged', this.input);
}
this.$emit('valueChanged', this.input);
},
},
data() {
Expand Down

0 comments on commit 364eb4f

Please sign in to comment.