mirror of
https://github.com/arc53/DocsGPT.git
synced 2025-11-30 00:53:14 +00:00
New switcher
This commit is contained in:
@@ -20,7 +20,9 @@ if (el) {
|
||||
'Content-Type': 'application/json',
|
||||
},
|
||||
|
||||
body: JSON.stringify({question: message, api_key: localStorage.getItem('apiKey')}),
|
||||
body: JSON.stringify({question: message,
|
||||
api_key: localStorage.getItem('apiKey'),
|
||||
active_docs: localStorage.getItem('activeDocs'),}),
|
||||
})
|
||||
.then(response => response.json())
|
||||
.then(data => {
|
||||
|
||||
3
application/static/src/choiceChange.js
Normal file
3
application/static/src/choiceChange.js
Normal file
@@ -0,0 +1,3 @@
|
||||
document.getElementById("select-docs").addEventListener("change", function() {
|
||||
localStorage.setItem('activeDocs', this.value)
|
||||
});
|
||||
Reference in New Issue
Block a user