delete console
This commit is contained in:
@@ -39,7 +39,6 @@ export default defineStore('useCytoscapeStore', {
|
|||||||
saveNodePosition(nodeId: string, position: NodePosition) {
|
saveNodePosition(nodeId: string, position: NodePosition) {
|
||||||
// 若是資訊曾經存在這張圖於localStorage中
|
// 若是資訊曾經存在這張圖於localStorage中
|
||||||
if (localStorage.getItem(SAVE_KEY_NAME) && JSON.parse(localStorage.getItem(SAVE_KEY_NAME))[this.currentGraphId]) {
|
if (localStorage.getItem(SAVE_KEY_NAME) && JSON.parse(localStorage.getItem(SAVE_KEY_NAME))[this.currentGraphId]) {
|
||||||
console.log('saveNodePosition ---- this.nodePositions[this.currentGraphId]',this.nodePositions[this.currentGraphId] );
|
|
||||||
const nodeToSave = this.nodePositions[this.currentGraphId].find(node => node.id === nodeId);
|
const nodeToSave = this.nodePositions[this.currentGraphId].find(node => node.id === nodeId);
|
||||||
if(nodeToSave) {
|
if(nodeToSave) {
|
||||||
nodeToSave.position = position;
|
nodeToSave.position = position;
|
||||||
|
|||||||
Reference in New Issue
Block a user