* [bug#58621] fix create step link from params of thinkstepmenu.

This commit is contained in:
zhangyu
2024-12-31 11:18:53 +08:00
committed by 孙浩
parent f13ed69f47
commit 9084557c3d
+2 -1
View File
@@ -105,6 +105,7 @@ window.addQuestion = function(stepID, parentID, type, questionType = '')
const className = parent == parentID ? '' : 'mt-2';
const $title = `<li class="tree-item tree-item-uncreated ${className}"><div class="listitem item-inner tree-item-inner selected text-primary font-bold" ${style}>${untitledLangs[type]}</div></li>`;
const marketID = $('.think-node-menu').data('marketID');
const from = $('.think-node-menu').data('from');
/* 当父节点为收起状态时,展开子节点。 */
/* When the parent node is in a collapsed state, expand the child nodes. */
@@ -114,7 +115,7 @@ window.addQuestion = function(stepID, parentID, type, questionType = '')
{
if($element.next('.tree').length == 0) $element.after(`<menu class="tree" level="${level}" data-type=${type} data-level="${level}"></menu>`);
$(`div[data-id='${stepID}']`).next('.tree').append($title);
loadPartial($.createLink('thinkstep', 'create', `marketID=${marketID}&wizardID=${wizard}&parent=${parentID}&type=${type}&questionType=${questionType}&currentParent=${parent}&currentOrder=${order}`), '.think-step');
loadPartial($.createLink('thinkstep', 'create', `marketID=${marketID}&wizardID=${wizard}&parent=${parentID}&type=${type}&questionType=${questionType}&currentParent=${parent}&currentOrder=${order}&from=${from}`), '.think-step');
/* 去掉节点收起状态。*/
/* Remove the node's collapsed state. */
localStorage.removeItem('thinkTreeInfo');