재개 버튼을 클릭하면 사용자가 마지막으로 방문한 페이지로 이동하게하고 싶습니다. ID를 컨트롤러로 전달하고 있습니다.마지막 방문 페이지로 세션 재개
<input type="button" value="Resume" onclick="window.location.href='/wizard/submission/resume/${submission.id}'" />
컨트롤러 로직은
def resume = {
def id = params.id
def test = (getDomainObjectType() as Class).get(id)
session[getSessionObjectName()] = test;
LOG.debug("resuming ${test}")
redirect(action: "wizard");
}
다음과 같이하고 마법사의 논리는 다음과 같습니다 : (그 너무 오래 현재로서는)
nextView = (int) postProcessedValues.next;
if (nextView == null) {
redirect(action: "index");
//nextView = 0; //question is what to do here. Maybe redirect back to the index page instead...
}
것은 여기에 로직을 구현 도와주세요 . 당신이 Grails의 웹 플로우 지원을 사용하여 조사 할 수 있습니다처럼
다른 코드가 필요하면 알려주십시오. – Techie