Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 2 additions & 4 deletions dataedit/static/metaedit/metaedit.js
Original file line number Diff line number Diff line change
Expand Up @@ -426,8 +426,7 @@ window.MetaEdit = function (config) {
window.JSONEditor.defaults.callbacks = {
autocomplete: {
search_name: function search(jseditor_editor, input) {
var url =
"https://openenergyplatform.org/api/oeo-search?query=" + input;
var url = "/api/oeo-search?query=" + input;

return new Promise(function (resolve) {
fetch(url, {
Expand Down Expand Up @@ -549,8 +548,7 @@ window.MetaEdit = function (config) {
window.JSONEditor.defaults.callbacks = {
autocomplete: {
search_name: function search(jseditor_editor, input) {
var url =
"https://openenergyplatform.org/api/oeo-search?query=" + input;
var url = "/api/oeo-search?query=" + input;

return new Promise(function (resolve) {
fetch(url, {
Expand Down
2 changes: 1 addition & 1 deletion oeo_ext/templates/oeo_ext/partials/unit_element.html
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@
if (query.length > 0) {
// use static path here to always use the open (data seeded) endpoint for
// all (local, deployed) client executions
fetch(`https://openenergyplatform.org/api/oeo-search?query=${query}`, {
fetch(`/api/oeo-search?query=${query}`, {
mode: "cors",
})
.then((response) => response.json())
Expand Down
3 changes: 3 additions & 0 deletions versions/changelogs/current.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,9 @@ SPDX-License-Identifier: CC0-1.0
- Create tables_sections.html, delete user_partial_tables
[(#2248)](https://github.com/OpenEnergyPlatform/oeplatform/pull/2248)

- Update fetch call for oeo-search api to be relative
[(#2293)](https://github.com/OpenEnergyPlatform/oeplatform/pull/2293)

### Features

- Build search field to search in the user's tables
Expand Down
Loading