From 7a1aabd86be8111f4d76c52f0a5697afb40fe4b9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=9D=A8=E6=A0=91=E6=98=8E?= <775174143@qq.com> Date: Sat, 7 Mar 2020 00:09:52 +0800 Subject: [PATCH] =?UTF-8?q?=E8=B0=83=E6=95=B4oj?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- public/react/src/redux/actions/ojForUser.js | 3 +-- public/react/src/services/ojService.js | 6 +++--- 2 files changed, 4 insertions(+), 5 deletions(-) diff --git a/public/react/src/redux/actions/ojForUser.js b/public/react/src/redux/actions/ojForUser.js index 87405f43d..bc57ed105 100644 --- a/public/react/src/redux/actions/ojForUser.js +++ b/public/react/src/redux/actions/ojForUser.js @@ -26,7 +26,6 @@ import { notification } from "antd"; export const startProgramQuestion = (id, props) => { return (dispatch, getState) => { const {searchParams} = getState().ojFormReducer; - console.log(searchParams); fetchStartProgram(id).then(res => { const { status, data } = res; if (status === 200) { @@ -50,7 +49,7 @@ export const startProgramQuestion = (id, props) => { // console.log(path); // props.history.push(`/myproblems/${identifier}`); props.history.push({ - pathname: `/myproblems/${identifier}${searchParams}`, + pathname: `/myproblems/${identifier}/${searchParams}`, }); } } diff --git a/public/react/src/services/ojService.js b/public/react/src/services/ojService.js index 806364ef4..53d55f3f2 100644 --- a/public/react/src/services/ojService.js +++ b/public/react/src/services/ojService.js @@ -1,7 +1,7 @@ /* * @Description: 开发者社区接口 * @Author: tangjiang - * @Github: + * @Github: * @Date: 2019-11-20 10:55:38 * @LastEditors : tangjiang * @LastEditTime : 2020-01-07 15:23:19 @@ -34,7 +34,7 @@ export async function fetchPostOjForm (paramsObj) { // if (identifier) { // return axios.post(url, params); // } else { - // return + // return // } return identifier ? axios.put(url, params) : axios.post(url, params); } @@ -136,7 +136,7 @@ export async function fetchUploadImage (file) { export async function fetchUploadImageUrl (id) { const url = `/attachments/${id}`; return axios.get(url); -} +} // 添加笔记 export async function fetchAddNotes (identifier, params) {