restore code

dev_tpm_ui
tangjiang 5 years ago
parent 41c8a04ad8
commit cb075d0f17

@ -511,7 +511,7 @@ class MessagSub extends Component {
return window.open(`/courses/${item.belong_container_id}/group_homeworks/${item.parent_container_id}`); return window.open(`/courses/${item.belong_container_id}/group_homeworks/${item.parent_container_id}`);
} }
case 'Hack': case 'Hack':
if (item.extra) { if (item.extra && item.parent_container_type !== 'HackDelete') {
return window.open(`/problems/${item.extra}/edit`); return window.open(`/problems/${item.extra}/edit`);
} }
default : default :

@ -4,7 +4,7 @@
* @Github: * @Github:
* @Date: 2019-11-27 13:41:48 * @Date: 2019-11-27 13:41:48
* @LastEditors : tangjiang * @LastEditors : tangjiang
* @LastEditTime : 2019-12-27 19:56:06 * @LastEditTime : 2019-12-27 20:59:00
*/ */
import types from "../actions/actionTypes"; import types from "../actions/actionTypes";
import { Base64 } from 'js-base64'; import { Base64 } from 'js-base64';
@ -138,7 +138,8 @@ const ojForUserReducer = (state = initialState, action) => {
console.log(curHack); console.log(curHack);
return { return {
...state, ...state,
hack: Object.assign({}, state.hack, curHack) hack: Object.assign({}, state.hack, curHack),
editor_code: curHack['code']
} }
case types.SAVE_HACK_IDENTIFIER: case types.SAVE_HACK_IDENTIFIER:
return { return {

Loading…
Cancel
Save