From 5afd0ef4afb261f721b75503e3f49992d57b2112 Mon Sep 17 00:00:00 2001 From: autosubmit Date: Mon, 12 Jun 2023 18:29:21 +0800 Subject: [PATCH] Auto Submit --- 73718.async.js | 8 ++-- color.less | 28 +++++------ js/public.js | 2 +- p__Demo__index.async.js | 8 ++-- ...enges__EditPracticeSetting__index.async.js | 33 +++++++++++-- p__Shixuns__New__ImagePreview__index.async.js | 8 ++-- p__tasks__Jupyter__index.async.js | 8 ++-- p__tasks__index.async.js | 46 ++++++++++++++----- umi.js | 17 ++++--- 9 files changed, 105 insertions(+), 53 deletions(-) diff --git a/73718.async.js b/73718.async.js index fa0cefb45d..298495456c 100644 --- a/73718.async.js +++ b/73718.async.js @@ -180,11 +180,11 @@ function closeWindowsVnc(id, tpi_id) { tpi_id: tpi_id }); } -function commitFiles(id) { - return (0,_utils_fetch__WEBPACK_IMPORTED_MODULE_3__/* .get */ .U2)("tasks/".concat(id, "/commit_files.json")); +function commitFiles(id, params) { + return (0,_utils_fetch__WEBPACK_IMPORTED_MODULE_3__/* .get */ .U2)("tasks/".concat(id, "/commit_files.json"), params); } -function pullFiles(id) { - return (0,_utils_fetch__WEBPACK_IMPORTED_MODULE_3__/* .get */ .U2)("tasks/".concat(id, "/pull_files.json")); +function pullFiles(id, params) { + return (0,_utils_fetch__WEBPACK_IMPORTED_MODULE_3__/* .get */ .U2)("tasks/".concat(id, "/pull_files.json"), params); } function logOutput(id, params) { return (0,_utils_fetch__WEBPACK_IMPORTED_MODULE_3__/* .post */ .v_)("tasks/".concat(id, "/log_output"), params); diff --git a/color.less b/color.less index f3f979102c..ee327e8f17 100644 --- a/color.less +++ b/color.less @@ -563,10 +563,10 @@ a.ant-btn-disabled:active > a:only-child::after {background: transparent;} .ant-comment-actions > li > span {color: @text-color-secondary;} .ant-comment-actions > li > span:hover {color: #595959;} .ant-picker-status-error.ant-picker, .ant-picker-status-error.ant-picker:not([disabled]):hover {background-color: #fff;border-color: @error-color;} -.ant-picker-status-error.ant-picker-focused, .ant-picker-status-error.ant-picker:focus {border-color: color(~`colorPalette("@{error-color}", 5)`);box-shadow: 0 0 0 2px rgba(57, 207, 41, 0.2);border-right-width: 1px;} +.ant-picker-status-error.ant-picker-focused, .ant-picker-status-error.ant-picker:focus {border-color: color(~`colorPalette("@{error-color}", 5)`);box-shadow: 0 0 0 2px rgba(117, 73, 215, 0.2);border-right-width: 1px;} .ant-picker-status-error.ant-picker .ant-picker-active-bar {background: color(~`colorPalette("@{error-color}", 5)`);} .ant-picker-status-warning.ant-picker, .ant-picker-status-warning.ant-picker:not([disabled]):hover {background-color: #fff;border-color: @warning-color;} -.ant-picker-status-warning.ant-picker-focused, .ant-picker-status-warning.ant-picker:focus {border-color: color(~`colorPalette("@{warning-color}", 5)`);box-shadow: 0 0 0 2px rgba(35, 109, 22, 0.2);border-right-width: 1px;} +.ant-picker-status-warning.ant-picker-focused, .ant-picker-status-warning.ant-picker:focus {border-color: color(~`colorPalette("@{warning-color}", 5)`);box-shadow: 0 0 0 2px rgba(204, 159, 136, 0.2);border-right-width: 1px;} .ant-picker-status-warning.ant-picker .ant-picker-active-bar {background: color(~`colorPalette("@{warning-color}", 5)`);} .ant-picker {color: @text-color;background: #fff;border: 1px solid @border-color-base;border-radius: 2px;} .ant-picker:hover, .ant-picker-focused {border-color: color(~`colorPalette("@{primary-color}", 5)`);border-right-width: 1px;} @@ -788,16 +788,16 @@ tr > .ant-picker-cell-in-view.ant-picker-cell-range-hover-start:last-child::afte .anticon.ant-input-clear-icon:hover, .ant-input-clear-icon:hover {color: @text-color-secondary;} .anticon.ant-input-clear-icon:active, .ant-input-clear-icon:active {color: @text-color;} .ant-input-status-error:not(.ant-input-disabled):not(.ant-input-borderless).ant-input, .ant-input-status-error:not(.ant-input-disabled):not(.ant-input-borderless).ant-input:hover {background: #fff;border-color: @error-color;} -.ant-input-status-error:not(.ant-input-disabled):not(.ant-input-borderless).ant-input:focus, .ant-input-status-error:not(.ant-input-disabled):not(.ant-input-borderless).ant-input-focused {border-color: color(~`colorPalette("@{error-color}", 5)`);box-shadow: 0 0 0 2px rgba(57, 207, 41, 0.2);border-right-width: 1px;} +.ant-input-status-error:not(.ant-input-disabled):not(.ant-input-borderless).ant-input:focus, .ant-input-status-error:not(.ant-input-disabled):not(.ant-input-borderless).ant-input-focused {border-color: color(~`colorPalette("@{error-color}", 5)`);box-shadow: 0 0 0 2px rgba(117, 73, 215, 0.2);border-right-width: 1px;} .ant-input-status-error .ant-input-prefix {color: @error-color;} .ant-input-status-warning:not(.ant-input-disabled):not(.ant-input-borderless).ant-input, .ant-input-status-warning:not(.ant-input-disabled):not(.ant-input-borderless).ant-input:hover {background: #fff;border-color: @warning-color;} -.ant-input-status-warning:not(.ant-input-disabled):not(.ant-input-borderless).ant-input:focus, .ant-input-status-warning:not(.ant-input-disabled):not(.ant-input-borderless).ant-input-focused {border-color: color(~`colorPalette("@{warning-color}", 5)`);box-shadow: 0 0 0 2px rgba(35, 109, 22, 0.2);border-right-width: 1px;} +.ant-input-status-warning:not(.ant-input-disabled):not(.ant-input-borderless).ant-input:focus, .ant-input-status-warning:not(.ant-input-disabled):not(.ant-input-borderless).ant-input-focused {border-color: color(~`colorPalette("@{warning-color}", 5)`);box-shadow: 0 0 0 2px rgba(204, 159, 136, 0.2);border-right-width: 1px;} .ant-input-status-warning .ant-input-prefix {color: @warning-color;} .ant-input-affix-wrapper-status-error:not(.ant-input-affix-wrapper-disabled):not(.ant-input-affix-wrapper-borderless).ant-input-affix-wrapper, .ant-input-affix-wrapper-status-error:not(.ant-input-affix-wrapper-disabled):not(.ant-input-affix-wrapper-borderless).ant-input-affix-wrapper:hover {background: #fff;border-color: @error-color;} -.ant-input-affix-wrapper-status-error:not(.ant-input-affix-wrapper-disabled):not(.ant-input-affix-wrapper-borderless).ant-input-affix-wrapper:focus, .ant-input-affix-wrapper-status-error:not(.ant-input-affix-wrapper-disabled):not(.ant-input-affix-wrapper-borderless).ant-input-affix-wrapper-focused {border-color: color(~`colorPalette("@{error-color}", 5)`);box-shadow: 0 0 0 2px rgba(57, 207, 41, 0.2);border-right-width: 1px;} +.ant-input-affix-wrapper-status-error:not(.ant-input-affix-wrapper-disabled):not(.ant-input-affix-wrapper-borderless).ant-input-affix-wrapper:focus, .ant-input-affix-wrapper-status-error:not(.ant-input-affix-wrapper-disabled):not(.ant-input-affix-wrapper-borderless).ant-input-affix-wrapper-focused {border-color: color(~`colorPalette("@{error-color}", 5)`);box-shadow: 0 0 0 2px rgba(117, 73, 215, 0.2);border-right-width: 1px;} .ant-input-affix-wrapper-status-error .ant-input-prefix {color: @error-color;} .ant-input-affix-wrapper-status-warning:not(.ant-input-affix-wrapper-disabled):not(.ant-input-affix-wrapper-borderless).ant-input-affix-wrapper, .ant-input-affix-wrapper-status-warning:not(.ant-input-affix-wrapper-disabled):not(.ant-input-affix-wrapper-borderless).ant-input-affix-wrapper:hover {background: #fff;border-color: @warning-color;} -.ant-input-affix-wrapper-status-warning:not(.ant-input-affix-wrapper-disabled):not(.ant-input-affix-wrapper-borderless).ant-input-affix-wrapper:focus, .ant-input-affix-wrapper-status-warning:not(.ant-input-affix-wrapper-disabled):not(.ant-input-affix-wrapper-borderless).ant-input-affix-wrapper-focused {border-color: color(~`colorPalette("@{warning-color}", 5)`);box-shadow: 0 0 0 2px rgba(35, 109, 22, 0.2);border-right-width: 1px;} +.ant-input-affix-wrapper-status-warning:not(.ant-input-affix-wrapper-disabled):not(.ant-input-affix-wrapper-borderless).ant-input-affix-wrapper:focus, .ant-input-affix-wrapper-status-warning:not(.ant-input-affix-wrapper-disabled):not(.ant-input-affix-wrapper-borderless).ant-input-affix-wrapper-focused {border-color: color(~`colorPalette("@{warning-color}", 5)`);box-shadow: 0 0 0 2px rgba(204, 159, 136, 0.2);border-right-width: 1px;} .ant-input-affix-wrapper-status-warning .ant-input-prefix {color: @warning-color;} .ant-input-group-wrapper-status-error .ant-input-group-addon {color: @error-color;border-color: @error-color;} .ant-input-group-wrapper-status-warning .ant-input-group-addon {color: @warning-color;border-color: @warning-color;} @@ -894,16 +894,16 @@ tr > .ant-picker-cell-in-view.ant-picker-cell-range-hover-start:last-child::afte .ant-input-number-affix-wrapper > div.ant-input-number {border: none;} .ant-input-number-affix-wrapper > div.ant-input-number.ant-input-number-focused {box-shadow: none !important;} .ant-input-number-status-error:not(.ant-input-number-disabled):not(.ant-input-number-borderless).ant-input-number, .ant-input-number-status-error:not(.ant-input-number-disabled):not(.ant-input-number-borderless).ant-input-number:hover {background: #fff;border-color: @error-color;} -.ant-input-number-status-error:not(.ant-input-number-disabled):not(.ant-input-number-borderless).ant-input-number:focus, .ant-input-number-status-error:not(.ant-input-number-disabled):not(.ant-input-number-borderless).ant-input-number-focused {border-color: color(~`colorPalette("@{error-color}", 5)`);box-shadow: 0 0 0 2px rgba(57, 207, 41, 0.2);border-right-width: 1px;} +.ant-input-number-status-error:not(.ant-input-number-disabled):not(.ant-input-number-borderless).ant-input-number:focus, .ant-input-number-status-error:not(.ant-input-number-disabled):not(.ant-input-number-borderless).ant-input-number-focused {border-color: color(~`colorPalette("@{error-color}", 5)`);box-shadow: 0 0 0 2px rgba(117, 73, 215, 0.2);border-right-width: 1px;} .ant-input-number-status-error .ant-input-number-prefix {color: @error-color;} .ant-input-number-status-warning:not(.ant-input-number-disabled):not(.ant-input-number-borderless).ant-input-number, .ant-input-number-status-warning:not(.ant-input-number-disabled):not(.ant-input-number-borderless).ant-input-number:hover {background: #fff;border-color: @warning-color;} -.ant-input-number-status-warning:not(.ant-input-number-disabled):not(.ant-input-number-borderless).ant-input-number:focus, .ant-input-number-status-warning:not(.ant-input-number-disabled):not(.ant-input-number-borderless).ant-input-number-focused {border-color: color(~`colorPalette("@{warning-color}", 5)`);box-shadow: 0 0 0 2px rgba(35, 109, 22, 0.2);border-right-width: 1px;} +.ant-input-number-status-warning:not(.ant-input-number-disabled):not(.ant-input-number-borderless).ant-input-number:focus, .ant-input-number-status-warning:not(.ant-input-number-disabled):not(.ant-input-number-borderless).ant-input-number-focused {border-color: color(~`colorPalette("@{warning-color}", 5)`);box-shadow: 0 0 0 2px rgba(204, 159, 136, 0.2);border-right-width: 1px;} .ant-input-number-status-warning .ant-input-number-prefix {color: @warning-color;} .ant-input-number-affix-wrapper-status-error:not(.ant-input-number-affix-wrapper-disabled):not(.ant-input-number-affix-wrapper-borderless).ant-input-number-affix-wrapper, .ant-input-number-affix-wrapper-status-error:not(.ant-input-number-affix-wrapper-disabled):not(.ant-input-number-affix-wrapper-borderless).ant-input-number-affix-wrapper:hover {background: #fff;border-color: @error-color;} -.ant-input-number-affix-wrapper-status-error:not(.ant-input-number-affix-wrapper-disabled):not(.ant-input-number-affix-wrapper-borderless).ant-input-number-affix-wrapper:focus, .ant-input-number-affix-wrapper-status-error:not(.ant-input-number-affix-wrapper-disabled):not(.ant-input-number-affix-wrapper-borderless).ant-input-number-affix-wrapper-focused {border-color: color(~`colorPalette("@{error-color}", 5)`);box-shadow: 0 0 0 2px rgba(57, 207, 41, 0.2);border-right-width: 1px;} +.ant-input-number-affix-wrapper-status-error:not(.ant-input-number-affix-wrapper-disabled):not(.ant-input-number-affix-wrapper-borderless).ant-input-number-affix-wrapper:focus, .ant-input-number-affix-wrapper-status-error:not(.ant-input-number-affix-wrapper-disabled):not(.ant-input-number-affix-wrapper-borderless).ant-input-number-affix-wrapper-focused {border-color: color(~`colorPalette("@{error-color}", 5)`);box-shadow: 0 0 0 2px rgba(117, 73, 215, 0.2);border-right-width: 1px;} .ant-input-number-affix-wrapper-status-error .ant-input-number-prefix {color: @error-color;} .ant-input-number-affix-wrapper-status-warning:not(.ant-input-number-affix-wrapper-disabled):not(.ant-input-number-affix-wrapper-borderless).ant-input-number-affix-wrapper, .ant-input-number-affix-wrapper-status-warning:not(.ant-input-number-affix-wrapper-disabled):not(.ant-input-number-affix-wrapper-borderless).ant-input-number-affix-wrapper:hover {background: #fff;border-color: @warning-color;} -.ant-input-number-affix-wrapper-status-warning:not(.ant-input-number-affix-wrapper-disabled):not(.ant-input-number-affix-wrapper-borderless).ant-input-number-affix-wrapper:focus, .ant-input-number-affix-wrapper-status-warning:not(.ant-input-number-affix-wrapper-disabled):not(.ant-input-number-affix-wrapper-borderless).ant-input-number-affix-wrapper-focused {border-color: color(~`colorPalette("@{warning-color}", 5)`);box-shadow: 0 0 0 2px rgba(35, 109, 22, 0.2);border-right-width: 1px;} +.ant-input-number-affix-wrapper-status-warning:not(.ant-input-number-affix-wrapper-disabled):not(.ant-input-number-affix-wrapper-borderless).ant-input-number-affix-wrapper:focus, .ant-input-number-affix-wrapper-status-warning:not(.ant-input-number-affix-wrapper-disabled):not(.ant-input-number-affix-wrapper-borderless).ant-input-number-affix-wrapper-focused {border-color: color(~`colorPalette("@{warning-color}", 5)`);box-shadow: 0 0 0 2px rgba(204, 159, 136, 0.2);border-right-width: 1px;} .ant-input-number-affix-wrapper-status-warning .ant-input-number-prefix {color: @warning-color;} .ant-input-number-group-wrapper-status-error .ant-input-number-group-addon {color: @error-color;border-color: @error-color;} .ant-input-number-group-wrapper-status-warning .ant-input-number-group-addon {color: @warning-color;border-color: @warning-color;} @@ -1024,10 +1024,10 @@ tr > .ant-picker-cell-in-view.ant-picker-cell-range-hover-start:last-child::afte .ant-list-grid .ant-col > .ant-list-item {border-bottom: none;} .ant-list-bordered {border: 1px solid @border-color-base;border-radius: 2px;} .ant-mentions-status-error:not(.ant-mentions-disabled):not(.ant-mentions-borderless).ant-mentions, .ant-mentions-status-error:not(.ant-mentions-disabled):not(.ant-mentions-borderless).ant-mentions:hover {background: #fff;border-color: @error-color;} -.ant-mentions-status-error:not(.ant-mentions-disabled):not(.ant-mentions-borderless).ant-mentions:focus, .ant-mentions-status-error:not(.ant-mentions-disabled):not(.ant-mentions-borderless).ant-mentions-focused {border-color: color(~`colorPalette("@{error-color}", 5)`);box-shadow: 0 0 0 2px rgba(57, 207, 41, 0.2);border-right-width: 1px;} +.ant-mentions-status-error:not(.ant-mentions-disabled):not(.ant-mentions-borderless).ant-mentions:focus, .ant-mentions-status-error:not(.ant-mentions-disabled):not(.ant-mentions-borderless).ant-mentions-focused {border-color: color(~`colorPalette("@{error-color}", 5)`);box-shadow: 0 0 0 2px rgba(117, 73, 215, 0.2);border-right-width: 1px;} .ant-mentions-status-error .ant-input-prefix {color: @error-color;} .ant-mentions-status-warning:not(.ant-mentions-disabled):not(.ant-mentions-borderless).ant-mentions, .ant-mentions-status-warning:not(.ant-mentions-disabled):not(.ant-mentions-borderless).ant-mentions:hover {background: #fff;border-color: @warning-color;} -.ant-mentions-status-warning:not(.ant-mentions-disabled):not(.ant-mentions-borderless).ant-mentions:focus, .ant-mentions-status-warning:not(.ant-mentions-disabled):not(.ant-mentions-borderless).ant-mentions-focused {border-color: color(~`colorPalette("@{warning-color}", 5)`);box-shadow: 0 0 0 2px rgba(35, 109, 22, 0.2);border-right-width: 1px;} +.ant-mentions-status-warning:not(.ant-mentions-disabled):not(.ant-mentions-borderless).ant-mentions:focus, .ant-mentions-status-warning:not(.ant-mentions-disabled):not(.ant-mentions-borderless).ant-mentions-focused {border-color: color(~`colorPalette("@{warning-color}", 5)`);box-shadow: 0 0 0 2px rgba(204, 159, 136, 0.2);border-right-width: 1px;} .ant-mentions-status-warning .ant-input-prefix {color: @warning-color;} .ant-mentions {color: @text-color;background-color: #fff;background-image: none;border: 1px solid @border-color-base;border-radius: 2px;} .ant-mentions::placeholder {color: #bfbfbf;} @@ -1360,9 +1360,9 @@ tr > .ant-picker-cell-in-view.ant-picker-cell-range-hover-start:last-child::afte .ant-select-multiple .ant-select-selection-item-remove {color: inherit;color: @text-color-secondary;} .ant-select-multiple .ant-select-selection-item-remove:hover {color: rgba(0, 0, 0, 0.75);} .ant-select-status-error.ant-select:not(.ant-select-disabled):not(.ant-select-customize-input):not(.ant-pagination-size-changer) .ant-select-selector {background-color: #fff;border-color: @error-color !important;} -.ant-select-status-error.ant-select:not(.ant-select-disabled):not(.ant-select-customize-input):not(.ant-pagination-size-changer).ant-select-open .ant-select-selector, .ant-select-status-error.ant-select:not(.ant-select-disabled):not(.ant-select-customize-input):not(.ant-pagination-size-changer).ant-select-focused .ant-select-selector {border-color: color(~`colorPalette("@{error-color}", 5)`);box-shadow: 0 0 0 2px rgba(57, 207, 41, 0.2);border-right-width: 1px;} +.ant-select-status-error.ant-select:not(.ant-select-disabled):not(.ant-select-customize-input):not(.ant-pagination-size-changer).ant-select-open .ant-select-selector, .ant-select-status-error.ant-select:not(.ant-select-disabled):not(.ant-select-customize-input):not(.ant-pagination-size-changer).ant-select-focused .ant-select-selector {border-color: color(~`colorPalette("@{error-color}", 5)`);box-shadow: 0 0 0 2px rgba(117, 73, 215, 0.2);border-right-width: 1px;} .ant-select-status-warning.ant-select:not(.ant-select-disabled):not(.ant-select-customize-input):not(.ant-pagination-size-changer) .ant-select-selector {background-color: #fff;border-color: @warning-color !important;} -.ant-select-status-warning.ant-select:not(.ant-select-disabled):not(.ant-select-customize-input):not(.ant-pagination-size-changer).ant-select-open .ant-select-selector, .ant-select-status-warning.ant-select:not(.ant-select-disabled):not(.ant-select-customize-input):not(.ant-pagination-size-changer).ant-select-focused .ant-select-selector {border-color: color(~`colorPalette("@{warning-color}", 5)`);box-shadow: 0 0 0 2px rgba(35, 109, 22, 0.2);border-right-width: 1px;} +.ant-select-status-warning.ant-select:not(.ant-select-disabled):not(.ant-select-customize-input):not(.ant-pagination-size-changer).ant-select-open .ant-select-selector, .ant-select-status-warning.ant-select:not(.ant-select-disabled):not(.ant-select-customize-input):not(.ant-pagination-size-changer).ant-select-focused .ant-select-selector {border-color: color(~`colorPalette("@{warning-color}", 5)`);box-shadow: 0 0 0 2px rgba(204, 159, 136, 0.2);border-right-width: 1px;} .ant-select {color: @text-color;} .ant-select:not(.ant-select-customize-input) .ant-select-selector {background-color: #fff;border: 1px solid @border-color-base;border-radius: 2px;} .ant-select-focused:not(.ant-select-disabled).ant-select:not(.ant-select-customize-input) .ant-select-selector {border-color: color(~`colorPalette("@{primary-color}", 5)`);box-shadow: 0 0 0 2px fade(@primary-color, 20%);border-right-width: 1px;} diff --git a/js/public.js b/js/public.js index eec9eca61b..b385f22459 100644 --- a/js/public.js +++ b/js/public.js @@ -192,7 +192,7 @@ function showNetworkError(){ try { new PerformanceObserver((entryList) => { entryList.getEntries().forEach((entry) => { - if(entry.transferSize === 0 && entry.initiatorType === "script" && entry.decodedBodySize === 0){ + if(entry.transferSize === 0 && entry.initiatorType === "script" && entry.decodedBodySize === 0 && entry.name.indexOf(".educoder.net") > -1){ showNetworkError() } }) diff --git a/p__Demo__index.async.js b/p__Demo__index.async.js index 6c96a5195f..69a341b631 100644 --- a/p__Demo__index.async.js +++ b/p__Demo__index.async.js @@ -320,11 +320,11 @@ function closeWindowsVnc(id, tpi_id) { tpi_id: tpi_id }); } -function commitFiles(id) { - return (0,_utils_fetch__WEBPACK_IMPORTED_MODULE_3__/* .get */ .U2)("tasks/".concat(id, "/commit_files.json")); +function commitFiles(id, params) { + return (0,_utils_fetch__WEBPACK_IMPORTED_MODULE_3__/* .get */ .U2)("tasks/".concat(id, "/commit_files.json"), params); } -function pullFiles(id) { - return (0,_utils_fetch__WEBPACK_IMPORTED_MODULE_3__/* .get */ .U2)("tasks/".concat(id, "/pull_files.json")); +function pullFiles(id, params) { + return (0,_utils_fetch__WEBPACK_IMPORTED_MODULE_3__/* .get */ .U2)("tasks/".concat(id, "/pull_files.json"), params); } function logOutput(id, params) { return (0,_utils_fetch__WEBPACK_IMPORTED_MODULE_3__/* .post */ .v_)("tasks/".concat(id, "/log_output"), params); diff --git a/p__Shixuns__Edit__body__Level__Challenges__EditPracticeSetting__index.async.js b/p__Shixuns__Edit__body__Level__Challenges__EditPracticeSetting__index.async.js index b4e6dac879..002a9cf112 100644 --- a/p__Shixuns__Edit__body__Level__Challenges__EditPracticeSetting__index.async.js +++ b/p__Shixuns__Edit__body__Level__Challenges__EditPracticeSetting__index.async.js @@ -815,7 +815,7 @@ var PracticeFileType; PracticeFileType["PicturePath"] = "picture_path"; })(PracticeFileType || (PracticeFileType = {})); var EditPracticeSetting = function EditPracticeSetting(_ref) { - var _shixunsDetail$detail, _shixunsDetail$detail2, _shixunsDetail$detail3, _shixunsDetail$detail4, _shixunsDetail$detail5, _shixunsDetail$detail6; + var _shixunsDetail$detail, _shixunsDetail$detail2, _shixunsDetail$detail3, _shixunsDetail$detail4, _shixunsDetail$detail5, _shixunsDetail$detail6, _shixunsDetail$detail7, _shixunsDetail$detail8; var shixunsDetail = _ref.shixunsDetail, dispatch = _ref.dispatch, practiceSetting = _ref.practiceSetting; @@ -865,7 +865,7 @@ var EditPracticeSetting = function EditPracticeSetting(_ref) { isshows = _useState18[0], setisshows = _useState18[1]; var params = (0,_umi_production_exports.useParams)(); - var changeKeys = ["test_set_rules", "go_back_url", "next_challenge", "position", "name", "chooses", "st", "id", "path", "exec_path", "show_type", "original_picture_path", "expect_picture_path", "picture_path", "test_set_rules_expression", "web_route", "test_set_score", "test_set_average", "exec_time", "ignore_space", "with_code_file", "unity_3d", "unity_3d_routes", "unity_3d_result", "has_web_route", "test_sets", 'is_file']; + var changeKeys = ["test_set_rules", "go_back_url", "next_challenge", "position", "name", "chooses", "st", "id", "path", "exec_path", "show_type", "original_picture_path", "expect_picture_path", "picture_path", "test_set_rules_expression", "web_route", "test_set_score", "test_set_average", "exec_time", "ignore_space", "with_code_file", "unity_3d", "unity_3d_routes", "unity_3d_result", "has_web_route", "test_sets", 'is_file', "hide_task_pass"]; (0,react.useEffect)(function () { getPracticeData(); }, []); @@ -1350,7 +1350,32 @@ var EditPracticeSetting = function EditPracticeSetting(_ref) { placeholder: "\u8BF7\u9009\u62E9\u7248\u672C\u5E93\u4E2D\u7684\u4EE3\u7801\u6587\u4EF6\u3002\u4F8B\uFF1A src/step1/HelloWorld.java" }) })] - }), formValue.unity_3d && ((_shixunsDetail$detail5 = shixunsDetail.detail) === null || _shixunsDetail$detail5 === void 0 ? void 0 : _shixunsDetail$detail5.identity) < 3 && /*#__PURE__*/(0,jsx_runtime.jsxs)(react.Fragment, { + }), /*#__PURE__*/(0,jsx_runtime.jsxs)(jsx_runtime.Fragment, { + children: [/*#__PURE__*/(0,jsx_runtime.jsxs)(es_form/* default.Item */.Z.Item, { + label: "\u9690\u85CF\u8FC7\u5173\u4EFB\u52A1:", + children: [/*#__PURE__*/(0,jsx_runtime.jsx)(es_form/* default.Item */.Z.Item, { + name: "hide_task_pass", + noStyle: true, + valuePropName: "checked", + children: /*#__PURE__*/(0,jsx_runtime.jsx)(es_checkbox/* default */.Z, {}) + }), /*#__PURE__*/(0,jsx_runtime.jsx)("span", { + className: "font14 c-light-black", + children: "\uFF08\u52FE\u9009\u540E\u5B66\u5458\u9875\u9762\u5C06\u9690\u85CF\u8FC7\u5173\u4EFB\u52A1\uFF09" + })] + }), formValue.unity_3d && ((_shixunsDetail$detail5 = shixunsDetail.detail) === null || _shixunsDetail$detail5 === void 0 ? void 0 : _shixunsDetail$detail5.identity) < 3 && /*#__PURE__*/(0,jsx_runtime.jsx)(es_form/* default.Item */.Z.Item, { + name: "unity_3d_routes", + label: "\u8DEF\u5F84:", + rules: [{ + required: true, + message: "必填项:不能为空" + }], + children: /*#__PURE__*/(0,jsx_runtime.jsx)(input/* default */.Z, { + bordered: false, + disabled: ((_shixunsDetail$detail6 = shixunsDetail.detail) === null || _shixunsDetail$detail6 === void 0 ? void 0 : _shixunsDetail$detail6.shixun_status) === 2, + placeholder: "\u8BF7\u9009\u62E9\u7248\u672C\u5E93\u4E2D\u7684\u4EE3\u7801\u6587\u4EF6\u3002\u4F8B\uFF1A src/step1/HelloWorld.java" + }) + })] + }), formValue.unity_3d && ((_shixunsDetail$detail7 = shixunsDetail.detail) === null || _shixunsDetail$detail7 === void 0 ? void 0 : _shixunsDetail$detail7.identity) < 3 && /*#__PURE__*/(0,jsx_runtime.jsxs)(react.Fragment, { children: [/*#__PURE__*/(0,jsx_runtime.jsx)(es_form/* default.Item */.Z.Item, { name: "with_code_file", label: "\u662F\u5426\u9700\u8981\u4EE3\u7801\u8BC4\u6D4B:", @@ -2064,7 +2089,7 @@ var EditPracticeSetting = function EditPracticeSetting(_ref) { }, 2), /*#__PURE__*/(0,jsx_runtime.jsx)(Loading/* default */.Z, { loading: loading }), /*#__PURE__*/(0,jsx_runtime.jsx)(UploadFile/* default */.ZP, { - rootIdentifier: shixunsDetail === null || shixunsDetail === void 0 ? void 0 : (_shixunsDetail$detail6 = shixunsDetail.detail) === null || _shixunsDetail$detail6 === void 0 ? void 0 : _shixunsDetail$detail6.root_identifier, + rootIdentifier: shixunsDetail === null || shixunsDetail === void 0 ? void 0 : (_shixunsDetail$detail8 = shixunsDetail.detail) === null || _shixunsDetail$detail8 === void 0 ? void 0 : _shixunsDetail$detail8.root_identifier, visible: showUploadFile, onClose: function onClose() { return setShowUploadFile(false); diff --git a/p__Shixuns__New__ImagePreview__index.async.js b/p__Shixuns__New__ImagePreview__index.async.js index cb07e4cc45..5480dcc5be 100644 --- a/p__Shixuns__New__ImagePreview__index.async.js +++ b/p__Shixuns__New__ImagePreview__index.async.js @@ -180,11 +180,11 @@ function closeWindowsVnc(id, tpi_id) { tpi_id: tpi_id }); } -function commitFiles(id) { - return (0,_utils_fetch__WEBPACK_IMPORTED_MODULE_3__/* .get */ .U2)("tasks/".concat(id, "/commit_files.json")); +function commitFiles(id, params) { + return (0,_utils_fetch__WEBPACK_IMPORTED_MODULE_3__/* .get */ .U2)("tasks/".concat(id, "/commit_files.json"), params); } -function pullFiles(id) { - return (0,_utils_fetch__WEBPACK_IMPORTED_MODULE_3__/* .get */ .U2)("tasks/".concat(id, "/pull_files.json")); +function pullFiles(id, params) { + return (0,_utils_fetch__WEBPACK_IMPORTED_MODULE_3__/* .get */ .U2)("tasks/".concat(id, "/pull_files.json"), params); } function logOutput(id, params) { return (0,_utils_fetch__WEBPACK_IMPORTED_MODULE_3__/* .post */ .v_)("tasks/".concat(id, "/log_output"), params); diff --git a/p__tasks__Jupyter__index.async.js b/p__tasks__Jupyter__index.async.js index c56ba1f53d..9fbfe14e18 100644 --- a/p__tasks__Jupyter__index.async.js +++ b/p__tasks__Jupyter__index.async.js @@ -180,11 +180,11 @@ function closeWindowsVnc(id, tpi_id) { tpi_id: tpi_id }); } -function commitFiles(id) { - return (0,_utils_fetch__WEBPACK_IMPORTED_MODULE_3__/* .get */ .U2)("tasks/".concat(id, "/commit_files.json")); +function commitFiles(id, params) { + return (0,_utils_fetch__WEBPACK_IMPORTED_MODULE_3__/* .get */ .U2)("tasks/".concat(id, "/commit_files.json"), params); } -function pullFiles(id) { - return (0,_utils_fetch__WEBPACK_IMPORTED_MODULE_3__/* .get */ .U2)("tasks/".concat(id, "/pull_files.json")); +function pullFiles(id, params) { + return (0,_utils_fetch__WEBPACK_IMPORTED_MODULE_3__/* .get */ .U2)("tasks/".concat(id, "/pull_files.json"), params); } function logOutput(id, params) { return (0,_utils_fetch__WEBPACK_IMPORTED_MODULE_3__/* .post */ .v_)("tasks/".concat(id, "/log_output"), params); diff --git a/p__tasks__index.async.js b/p__tasks__index.async.js index 56cafb4912..30935f9f69 100644 --- a/p__tasks__index.async.js +++ b/p__tasks__index.async.js @@ -15166,7 +15166,6 @@ var HorizontalTabs = function HorizontalTabs(_ref) { }; }, [scrollbarContent.current]); var handleObserverSize = function handleObserverSize() { - console.log(scrollbarContent.current.clientWidth > scrollbar.current.clientWidth, scrollbarContent.current.clientWidth, scrollbar.current.clientWidth); if (scrollbarContent.current.clientWidth > scrollbar.current.clientWidth) { var _moveElement$current$; var barWidth = scrollbar.current.clientWidth / scrollbarContent.current.clientWidth * scrollbar.current.clientWidth; @@ -16058,7 +16057,7 @@ function code_repository_reducer(state, action) { return function () { document.removeEventListener((0,fullscreen/* fullscreenChange */.gH)(), fullChange); }; - }, []); + }, [taskData]); function onRightFullHandler() { setIsResizeLarge(!isResizeLarge); if ((0,fullscreen/* IsFull */.vp)()) { @@ -16072,13 +16071,17 @@ function code_repository_reducer(state, action) { var taskLeftPanel = document.getElementById('task-left-panel'); var nextElement = taskLeftPanel.nextElementSibling; if ((0,fullscreen/* IsFull */.vp)()) { - taskLeftPanel.classList.add('hide'); - nextElement.classList.add('hide'); setIsResizeLarge(true); + if (!(taskData !== null && taskData !== void 0 && taskData.hideLeftPanel)) { + taskLeftPanel.classList.add('hide'); + nextElement.classList.add('hide'); + } } else { setIsResizeLarge(false); - taskLeftPanel.classList.remove('hide'); - nextElement.classList.remove('hide'); + if (!(taskData !== null && taskData !== void 0 && taskData.hideLeftPanel)) { + taskLeftPanel.classList.remove('hide'); + nextElement.classList.remove('hide'); + } } }; function onCodeChange(value) { @@ -16217,16 +16220,35 @@ function code_repository_reducer(state, action) { }; var handleTabsChange = /*#__PURE__*/function () { var _ref2 = asyncToGenerator_default()( /*#__PURE__*/regeneratorRuntime_default()().mark(function _callee(item) { + var homeworkCommonId; return regeneratorRuntime_default()().wrap(function _callee$(_context) { while (1) switch (_context.prev = _context.next) { case 0: + homeworkCommonId = searchParams.get('homework_common_id'); setTabActiveParams(item); - _context.next = 3; - return (0,service/* commitFiles */.ZH)(game.identifier); - case 3: + if (!homeworkCommonId) { + _context.next = 9; + break; + } _context.next = 5; - return (0,service/* pullFiles */.gn)(game.identifier); + return (0,service/* commitFiles */.ZH)(game.identifier, { + homework_common_id: homeworkCommonId + }); case 5: + _context.next = 7; + return (0,service/* pullFiles */.gn)(game.identifier, { + homework_common_id: homeworkCommonId + }); + case 7: + _context.next = 13; + break; + case 9: + _context.next = 11; + return (0,service/* commitFiles */.ZH)(game.identifier); + case 11: + _context.next = 13; + return (0,service/* pullFiles */.gn)(game.identifier); + case 13: if (item.tab_type === 1) { setShowCaseList(true); } else { @@ -16246,7 +16268,7 @@ function code_repository_reducer(state, action) { onUpdateCode(); setCodeLoading(true); //避免切到loading延迟 } - case 8: + case 16: case "end": return _context.stop(); } @@ -19104,7 +19126,7 @@ function tasks_reducer(state, action) { className: "tasks-body", children: [/*#__PURE__*/(0,jsx_runtime.jsx)("section", { id: "task-left-panel", - className: "left-panel", + className: "left-panel ".concat(taskData !== null && taskData !== void 0 && taskData.hideLeftPanel ? "hide" : "", " "), style: { width: leftPanelWidth, display: moveX === 0.01 ? 'none' : '' diff --git a/umi.js b/umi.js index 27e29540c5..1235315d8e 100644 --- a/umi.js +++ b/umi.js @@ -70684,7 +70684,7 @@ __webpack_require__.d(__webpack_exports__, { ;// CONCATENATED MODULE: ./src/utils/env/dev.ts var DEV = { - PROXY_SERVER: 'https://data.educoder.net', + PROXY_SERVER: 'https://pre-data.educoder.net', API_SERVER: 'http://localhost:8000', REPORT_SERVER: 'http://192.168.1.57:3001', IMG_SERVER: 'https://new-testali-cdn.educoder.net', @@ -71031,6 +71031,12 @@ function request(url, option, flag, ismin) { credentials: 'include', withCredentials: true }; + var userParam = {}; + if (userInfo !== null && userInfo !== void 0 && userInfo.login) { + userParam.zzud = userInfo === null || userInfo === void 0 ? void 0 : userInfo.login; + if (userInfo !== null && userInfo !== void 0 && userInfo.school_id) userParam.zzsud = userInfo === null || userInfo === void 0 ? void 0 : userInfo.school_id; + options.params = _root_workspace_ppte5yg23_SJ5m_develop_node_modules_babel_runtime_helpers_objectSpread2_js__WEBPACK_IMPORTED_MODULE_2___default()(_root_workspace_ppte5yg23_SJ5m_develop_node_modules_babel_runtime_helpers_objectSpread2_js__WEBPACK_IMPORTED_MODULE_2___default()({}, options.params || {}), userParam); + } var newOptions = _root_workspace_ppte5yg23_SJ5m_develop_node_modules_babel_runtime_helpers_objectSpread2_js__WEBPACK_IMPORTED_MODULE_2___default()(_root_workspace_ppte5yg23_SJ5m_develop_node_modules_babel_runtime_helpers_objectSpread2_js__WEBPACK_IMPORTED_MODULE_2___default()({}, defaultOptions), JSON.parse(JSON.stringify(options))); if (newOptions.method === 'POST' || newOptions.method === 'PUT' || newOptions.method === 'PATCH' || newOptions.method === 'DELETE') { if (!flag) { @@ -71045,9 +71051,6 @@ function request(url, option, flag, ismin) { } console.log("newOptions.body:", newOptions.body); } - options.params = options.params || {}; - options.params.zzud = userInfo === null || userInfo === void 0 ? void 0 : userInfo.login; - options.params.zzsud = userInfo === null || userInfo === void 0 ? void 0 : userInfo.school_id; console.log("newOptions:", options); if (newOptions.method == 'GET') { newOptions.headers = _root_workspace_ppte5yg23_SJ5m_develop_node_modules_babel_runtime_helpers_objectSpread2_js__WEBPACK_IMPORTED_MODULE_2___default()({ @@ -71055,6 +71058,8 @@ function request(url, option, flag, ismin) { 'Content-Type': 'application/json; charset=utf-8' }, newOptions.headers); if (options.params && parseParams(options.params)) url += '?' + parseParams(options.params); + } else if (userParam.zzud) { + url += '?' + parseParams(_root_workspace_ppte5yg23_SJ5m_develop_node_modules_babel_runtime_helpers_objectSpread2_js__WEBPACK_IMPORTED_MODULE_2___default()({}, userParam)); } // newOptions.headers.Authorization = // 'Bearer 09cb06de7874a0cfae0608ba5126b3b30dcb5d2a' @@ -73561,7 +73566,7 @@ var parseParamsStr = function parseParamsStr(v, method) { } } }); - return arr.join("&"); + return arr.join("&").trim(); }; var educationList = [{ name: '博士研究生', @@ -73600,7 +73605,7 @@ var setHeader = function setHeader(newOptions, url) { newOptions.headers["X-EDU-Timestamp"] = timenow; newOptions.headers["X-EDU-Signature"] = md5__WEBPACK_IMPORTED_MODULE_17___default()(stringToSign); if (document.domain.indexOf("educoder.net") > -1) { - console.log("stringToSign:", stringToSign, timenow); + console.log("stringToSign:", stringToSign, url); } return newOptions; };