【发布时间】:2022-01-13 08:10:32
【问题描述】:
我有一个包含 3 个步骤的步骤表单,它在提交前在第三步停止。 在调试时发现方法不允许异常。 我的代码如下
if(this.step == 39){
console.log(this.readinessAssessment);
console.log(this.jobSeekerId);
this.showLoader = false;
axios.post('/save-competencies', {readinessAssessment: this.readinessAssessment, jobSeekerId: this.jobSeekerId})
.then(response => {
console.log(response);
if(response.data.success){
this.competenciesPart = false;
this.applicationAccepted = true;
setTimeout(() => {
this.step = 100;
}, 1000);
this.hideProgressBar = false;
this.hideProcess = false;
}
this.showLoader = false;
}).catch(error => {
this.showLoader = false;
console.log(error);
});
}
我的路线是
Route::post('/save-competencies', [FrontendController::class, 'saveCompetencies'])->name('saveCompetencies');
【问题讨论】:
-
请正确提及错误以及您的期望?
-
在步骤表单中的最后一个单选按钮之后单击提交时卡住了这是人们回答和提交的问题。在控制台中检查时显示 500。
-
在点击此链接时说此路线不支持 get 方法。允许的方法是张贴
-
我的数据是一个18个元素的数组
-
Array(18) 0: {question: 'some question', answer: 'Occasional', weightedScore: '0.5', 能力: '适应性'} 1: {question: 'Isome question',答案:'偶尔',weightedScore:'0.5',能力:'适应性'} 2:{问题:'一些问题',答案:'否',weightedScore:'0.25',能力:'协作'} ....