0
0
Fork 1
Spiegel von https://github.com/paviliondev/discourse-custom-wizard.git synchronisiert 2024-11-09 20:02:54 +01:00

FIX: Resolve linting issues

Dieser Commit ist enthalten in:
Keegan George 2021-09-01 12:46:39 -07:00
Ursprung 622ab1b2ce
Commit 7b13605c7b
4 geänderte Dateien mit 10 neuen und 12 gelöschten Zeilen

Datei anzeigen

@ -64,21 +64,21 @@ export default Component.extend({
submittedUsers(value) {
const isUserSelector = this.get("isUserSelector");
const users = [];
if (isUserSelector) {
const userData = value.value;
const usernames = [];
if (userData.indexOf(',')) {
if (userData.indexOf(',')) {
usernames.push(...userData.split(','));
usernames.forEach(u => {
const user = {
username: u,
url: `/u/${u}`
}
};
users.push(user);
})
});
}
}
return users;
@ -87,7 +87,6 @@ export default Component.extend({
@discourseComputed('value')
userProfileUrl(value) {
const isUser = this.get("isUser");
const isUserSelector = this.get("isUserSelector");
if (isUser) {
return `/u/${value.username}`;

Datei anzeigen

@ -2,7 +2,7 @@ import Controller from "@ember/controller";
import ModalFunctionality from "discourse/mixins/modal-functionality";
export default Controller.extend(ModalFunctionality, {
actions: {
save() {
this.send("closeModal");

Datei anzeigen

@ -27,8 +27,8 @@ export default Controller.extend({
this.set("loadingMore", false);
});
},
@discourseComputed('submissions', 'fields.@each.enabled')
displaySubmissions(submissions, fields) {
let result = [];
@ -56,7 +56,7 @@ export default Controller.extend({
},
showEditColumnsModal() {
const controller = showModal("admin-wizards-submissions-columns", {
return showModal("admin-wizards-submissions-columns", {
model: {
fields: this.get('fields'),
submissions: this.get('submissions')

Datei anzeigen

@ -224,7 +224,6 @@ CustomWizard.reopenClass({
})
.then((result) => {
if (result.wizard) {
console.log(result);
let fields = [{ id: "username", label: "User"}];
let submissions = [];
let wizard = result.wizard;
@ -248,8 +247,8 @@ CustomWizard.reopenClass({
let submittedAt = {
id: "submitted_at",
label: "Submitted At"
}
};
fields.push(submittedAt);
return {