Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit 73720f4

Browse files
author
Lionel Bijaoui
committed
Fix codacy errors
1 parent adea60c commit 73720f4

File tree

1 file changed

+11
-15
lines changed

1 file changed

+11
-15
lines changed

‎projects/custom/app.vue

Lines changed: 11 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -182,25 +182,21 @@ https://google.com/
182182
183183
methods: {
184184
testClick(helpText, event) {
185-
console.log(helpText, event);
185+
//console.log(helpText, event);
186186
},
187187
getIcon(field, getValueFromOption) {
188188
let fieldType = getValueFromOption(field, "type");
189189
let fieldOptions = getValueFromOption(field, "fieldOptions");
190-
191-
if (fieldType === "input") {
192-
switch (fieldOptions.inputType) {
193-
case "email":
194-
return "at";
195-
case "number":
196-
return "calculator";
197-
case "date":
198-
return "calendar-alt";
199-
case "color":
200-
return "palette";
201-
default:
202-
return "file-alt";
203-
}
190+
let icons = {
191+
email: "at",
192+
number: "calculator",
193+
date: "calendar-alt",
194+
color: "palette"
195+
};
196+
if (fieldType === "input" && typeof icons[fieldOptions.inputType] !== undefined) {
197+
return icons[fieldOptions.inputType];
198+
} else {
199+
return "file-alt";
204200
}
205201
}
206202
},

0 commit comments

Comments
(0)

AltStyle によって変換されたページ (->オリジナル) /