Skip to content

Commit f9ff613

Browse files
committed
remove unused code
1 parent a31d441 commit f9ff613

File tree

1 file changed

+0
-42
lines changed

1 file changed

+0
-42
lines changed

src/components/SurveyItem/SurveyItem.vue

Lines changed: 0 additions & 42 deletions
Original file line numberDiff line numberDiff line change
@@ -170,14 +170,6 @@
170170
width: '100%',
171171
};
172172
},
173-
bodyStyle() {
174-
if (this.ui === 'section' || this.ui === 'multipart') {
175-
return {
176-
padding: 0,
177-
};
178-
}
179-
return {};
180-
},
181173
ui() {
182174
/* eslint-disable */
183175
if (this.data['@type'] && this.data['@type'][0] === "http://schema.repronim.org/Activity") {
@@ -229,42 +221,8 @@
229221
fieldData() {
230222
return this.data;
231223
},
232-
findPassOptions() {
233-
if (this.data['http://schema.repronim.org/responseOptions']) {
234-
// when responseOptions is a remote object
235-
if (Object.keys(this.data['http://schema.repronim.org/responseOptions'][0]).indexOf('@id') > -1) {
236-
this.getRequiredVal();
237-
return this.requireVal;
238-
}
239-
// when responseOptions in embedded in item object itself
240-
if (this.data['http://schema.repronim.org/responseOptions'][0]) {
241-
// make sure the requiredValue key is defined
242-
// todo: requiredValue has moved to activity level, so change the code here
243-
if (this.data['http://schema.repronim.org/responseOptions'][0]['http://schema.org/valueRequired']) {
244-
return this.data['http://schema.repronim.org/responseOptions'][0]['http://schema.org/valueRequired'][0]['@value'];
245-
}
246-
}
247-
}
248-
return false;
249-
},
250224
},
251225
methods: {
252-
getRequiredVal() { // todo: this needs to change. requiredValue is in activity level now
253-
jsonld.expand(this.data['http://schema.repronim.org/responseOptions'][0]['@id'])
254-
.then((rsp) => {
255-
this.requireVal = rsp[0]['http://schema.org/valueRequired'][0]['@value'];
256-
// eslint-disable-next-line no-unused-vars
257-
}).catch((e) => {
258-
// console.log(240, 'constraint error', e);
259-
jsonld.expand(`${this.data['http://schema.repronim.org/responseOptions'][0]['@id']}.jsonld`).then((resp) => {
260-
// console.log(250, resp);
261-
this.requireVal = resp[0]['http://schema.org/valueRequired'][0]['@value'];
262-
// eslint-disable-next-line no-unused-vars
263-
}).catch((e1) => {
264-
// console.log(252, e1);
265-
});
266-
});
267-
},
268226
getValueConstraintsData(url) {
269227
jsonld.expand(url).then((rsp) => {
270228
this.valueC = rsp[0];

0 commit comments

Comments
 (0)