MCPcopy
hub / github.com/Comfy-Org/ComfyUI-Manager / loadData

Method loadData

comfyui_manager/js/model-manager.js:635–661  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

633 // ===========================================================================================
634
635 async loadData() {
636
637 this.showLoading();
638
639 this.showStatus(`Loading external model list ...`);
640
641 const mode = manager_instance.datasrc_combo.value;
642
643 const res = await fetchData(`/v2/externalmodel/getlist?mode=${mode}`);
644 if (res.error) {
645 this.showError("Failed to get external model list.");
646 this.hideLoading();
647 return
648 }
649
650 const { models } = res.data;
651
652 this.modelList = this.getModelList(models);
653 // console.log("models", this.modelList);
654
655 this.updateFilter();
656
657 this.renderGrid();
658
659 this.hideLoading();
660
661 }
662
663 // ===========================================================================================
664

Callers 1

showMethod · 0.95

Calls 8

showLoadingMethod · 0.95
showStatusMethod · 0.95
showErrorMethod · 0.95
hideLoadingMethod · 0.95
getModelListMethod · 0.95
updateFilterMethod · 0.95
renderGridMethod · 0.95
fetchDataFunction · 0.90

Tested by

no test coverage detected