mirror of
https://github.com/Part-DB/Part-DB-server.git
synced 2025-06-21 01:25:55 +02:00
Remove -> prefix if no element is selected yet
This commit is contained in:
parent
f6577a8f33
commit
f18c024daa
1 changed files with 6 additions and 0 deletions
|
@ -66,6 +66,9 @@ export default class extends Controller {
|
||||||
//Prepend it to the input
|
//Prepend it to the input
|
||||||
if (current) {
|
if (current) {
|
||||||
data.input = current + " " + data.input;
|
data.input = current + " " + data.input;
|
||||||
|
} else {
|
||||||
|
//If there is no current value, we remove the "->"
|
||||||
|
data.input = data.input.substring(2);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -96,6 +99,9 @@ export default class extends Controller {
|
||||||
//Prepend it to the input
|
//Prepend it to the input
|
||||||
if (current) {
|
if (current) {
|
||||||
input = current + " " + input;
|
input = current + " " + input;
|
||||||
|
} else {
|
||||||
|
//If there is no current value, we remove the "->"
|
||||||
|
input = input.substring(2);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue