Bugfix search page (Band)
This commit is contained in:
@@ -12,9 +12,6 @@ export class AccountRole extends Model {
|
|||||||
@Column
|
@Column
|
||||||
privilegeAdminPanel: boolean
|
privilegeAdminPanel: boolean
|
||||||
|
|
||||||
@Column
|
|
||||||
privilegeFileAccess: boolean
|
|
||||||
|
|
||||||
|
|
||||||
// Relations
|
// Relations
|
||||||
@HasMany(() => Account)
|
@HasMany(() => Account)
|
||||||
|
|||||||
@@ -103,7 +103,7 @@ band.get("/", (req: Request, res: Response) => {
|
|||||||
/**
|
/**
|
||||||
* Get all information about one band
|
* Get all information about one band
|
||||||
*/
|
*/
|
||||||
band.get("/:name", (req: Request, res: Response) => {
|
band.get("/band/:name", (req: Request, res: Response) => {
|
||||||
Band.findOne({
|
Band.findOne({
|
||||||
where: {
|
where: {
|
||||||
name: { [Op.like]: req.params.name }
|
name: { [Op.like]: req.params.name }
|
||||||
@@ -166,6 +166,8 @@ band.get("/:name", (req: Request, res: Response) => {
|
|||||||
*/
|
*/
|
||||||
band.get("/search", async (req: Request, res: Response) => {
|
band.get("/search", async (req: Request, res: Response) => {
|
||||||
// Workaround, because SQLite can't handle stacked queries
|
// Workaround, because SQLite can't handle stacked queries
|
||||||
|
console.log(1)
|
||||||
|
console.log(req.query.value)
|
||||||
let prompts = decodeURI(String(req.query.value)).split(";")
|
let prompts = decodeURI(String(req.query.value)).split(";")
|
||||||
|
|
||||||
// On stacked prompts, execute last prompt
|
// On stacked prompts, execute last prompt
|
||||||
|
|||||||
@@ -679,8 +679,7 @@
|
|||||||
"id": 1,
|
"id": 1,
|
||||||
"name": "User",
|
"name": "User",
|
||||||
"privilegeBuy": true,
|
"privilegeBuy": true,
|
||||||
"privilegeAdminPanel": false,
|
"privilegeAdminPanel": false
|
||||||
"privilegeFileAccess": null
|
|
||||||
},
|
},
|
||||||
"payments": [
|
"payments": [
|
||||||
{
|
{
|
||||||
@@ -759,8 +758,8 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
"example": {
|
"example": {
|
||||||
"username": "artists",
|
"name": "artists",
|
||||||
"password": 41
|
"description": 41
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"file": {
|
"file": {
|
||||||
|
|||||||
1481
misc/database.drawio
1481
misc/database.drawio
File diff suppressed because it is too large
Load Diff
@@ -49,7 +49,7 @@ export const useSearchStore = defineStore("searchStore", {
|
|||||||
|
|
||||||
|
|
||||||
// Check for exercise solution
|
// Check for exercise solution
|
||||||
if (result.data.length != 0) {
|
if (this.searchTerm.toUpperCase().includes("SELECT")) {
|
||||||
// Exercise 2.1
|
// Exercise 2.1
|
||||||
if (result.data[0].type != undefined && result.data[0].type == "table") {
|
if (result.data[0].type != undefined && result.data[0].type == "table") {
|
||||||
exerciseStore.solveExercise(2, 1)
|
exerciseStore.solveExercise(2, 1)
|
||||||
@@ -92,6 +92,7 @@ export const useSearchStore = defineStore("searchStore", {
|
|||||||
}
|
}
|
||||||
|
|
||||||
else {
|
else {
|
||||||
|
// Normal behaviour
|
||||||
this.bands = result.data
|
this.bands = result.data
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
|||||||
Reference in New Issue
Block a user