use FHC_JS_DATA_STORAGE_OBJECT for apiurl

This commit is contained in:
cgfhtw
2022-10-24 16:01:02 +02:00
parent a3722273e9
commit a65d297997
2 changed files with 10 additions and 7 deletions
+9 -6
View File
@@ -4,17 +4,21 @@ import CachedWidgetLoader from "../../composables/Dashboard/CachedWidgetLoader.j
import ObjectUtils from "../../composables/ObjectUtils.js";
export default {
components: {
DashboardSection,
DashboardWidgetPicker
},
props: [
"dashboard",
"apiurl"
"dashboard"
],
data: () => ({
sections: [],
widgets: null
}),
components: {
DashboardSection,
DashboardWidgetPicker
computed: {
apiurl() {
return FHC_JS_DATA_STORAGE_OBJECT.app_root + FHC_JS_DATA_STORAGE_OBJECT.ci_router + '/dashboard';
}
},
methods: {
widgetAdd(section_name, widget) {
@@ -117,7 +121,6 @@ export default {
}
},
created() {
CachedWidgetLoader.setPath(this.apiurl + '/Widget');
axios.get(this.apiurl + '/Config', {params:{
db: this.dashboard
}}).then(res => {
@@ -1,6 +1,6 @@
let __widgets = {};
let __widgetsStarted = {};
let __path = '';
let __path = FHC_JS_DATA_STORAGE_OBJECT.app_root + FHC_JS_DATA_STORAGE_OBJECT.ci_router + '/dashboard/Widget';
export default {
getWidget(id) {