修复添加定时任务插入顺序

ql repo拉取失败自动删除目录重新拉取一次
This commit is contained in:
hanhh 2021-08-12 00:00:39 +08:00
parent 8be71b129a
commit d06fccd0d1
10 changed files with 50 additions and 200 deletions

View File

@ -68,10 +68,10 @@
"react": "17.x",
"react-codemirror2": "^7.2.1",
"react-diff-viewer": "^3.1.1",
"react-split-pane": "^0.1.92",
"react-dnd": "^14.0.2",
"react-dnd-html5-backend": "^14.0.0",
"react-dom": "17.x",
"react-split-pane": "^2.0.3",
"ts-node": "^9.0.0",
"typescript": "^4.1.2",
"umi": "^3.3.9",

View File

@ -43,7 +43,7 @@ specifiers:
react-dnd: ^14.0.2
react-dnd-html5-backend: ^14.0.0
react-dom: 17.x
react-split-pane: ^2.0.3
react-split-pane: ^0.1.92
reflect-metadata: ^0.1.13
ts-node: ^9.0.0
typedi: ^0.8.0
@ -103,7 +103,7 @@ devDependencies:
react-dnd: 14.0.2_695545ed68ea337339babea285839fc0
react-dnd-html5-backend: 14.0.0
react-dom: 17.0.2_react@17.0.2
react-split-pane: 2.0.3
react-split-pane: 0.1.92_react-dom@17.0.2+react@17.0.2
ts-node: 9.1.1_typescript@4.2.4
typescript: 4.2.4
umi: 3.4.20
@ -2163,10 +2163,6 @@ packages:
type-is: 1.6.18
dev: false
/bowser/1.9.4:
resolution: {integrity: sha512-9IdMmj2KjigRq6oWhmwv1W36pDuA4STQZ8q6YO9um+x07xgYNCD3Oou+WP/3L1HNz7iqythGet3/p4wvc8AAwQ==}
dev: true
/boxen/4.2.0:
resolution: {integrity: sha512-eB4uT9RGzg2odpER62bBwSLvUeGC+WbRjjyyFhGsKnc8wp/m0+hQsMUvUe3H2V0D5vw0nBdO1hCJoZo5mKeuIQ==}
engines: {node: '>=8'}
@ -2211,10 +2207,6 @@ packages:
fill-range: 7.0.1
dev: true
/brcast/3.0.2:
resolution: {integrity: sha512-f5XwwFCCuvgqP2nMH/hJ74FqnGmb4X3D+NC//HphxJzzhsZvSZa+Hk/syB7j3ZHpPDLMoYU8oBgviRWfNvEfKA==}
dev: true
/brorand/1.1.0:
resolution: {integrity: sha1-EsJe/kCkXjwyPrhnWgoM5XsiNx8=}
dev: true
@ -2316,13 +2308,6 @@ packages:
isarray: 1.0.0
dev: true
/buffer/5.7.1:
resolution: {integrity: sha512-EHcyIPBQ4BSGlvjB16k5KgAJ27CIsHY/2JBmCRReo48y9rQ3MaUzWX3KVlBa4U7MyX02HdVj0K7C3WaB3ju7FQ==}
dependencies:
base64-js: 1.5.1
ieee754: 1.2.1
dev: true
/builtin-status-codes/3.0.0:
resolution: {integrity: sha1-hZgoeOIbmOHGZCXgPQF0eI9Wnug=}
dev: true
@ -2423,10 +2408,6 @@ packages:
engines: {node: '>=10'}
dev: true
/camelize/1.0.0:
resolution: {integrity: sha1-FkpUg+Yw+kMh5a8HAg5TGDGyYJs=}
dev: true
/caniuse-lite/1.0.30001228:
resolution: {integrity: sha512-QQmLOGJ3DEgokHbMSA8cj2a+geXqmnpyOFT0lhQV6P3/YOJvGDEwoedcwxEQ30gJIwIIunHIicunJ2rzK5gB2A==}
dev: true
@ -2953,11 +2934,6 @@ packages:
postcss: 7.0.32
dev: true
/css-color-keywords/1.0.0:
resolution: {integrity: sha1-/qJhbcZ2spYmhrOvjb2+GAskTgU=}
engines: {node: '>=4'}
dev: true
/css-has-pseudo/0.10.0:
resolution: {integrity: sha512-Z8hnfsZu4o/kt+AuFzeGpLVhFOGO9mluyHBaA2bA8aCGTwah5sT3WV/fTHH8UNZUytOIImuGPrl/prlb4oX4qQ==}
engines: {node: '>=6.0.0'}
@ -2967,13 +2943,6 @@ packages:
postcss-selector-parser: 5.0.0
dev: true
/css-in-js-utils/2.0.1:
resolution: {integrity: sha512-PJF0SpJT+WdbVVt0AOYp9C8GnuruRlL/UFW7932nLWmFLQTaWEzTBQEx7/hn4BuV+WON75iAViSUJLiU3PKbpA==}
dependencies:
hyphenate-style-name: 1.0.4
isobject: 3.0.1
dev: true
/css-prefers-color-scheme/3.1.1:
resolution: {integrity: sha512-MTu6+tMs9S3EUqzmqLXEcgNRbNkkD/TGFvowpeoWJn5Vfq7FMgsmRQs9X5NXAURiOBmOxm/lLjsDNXDE6k9bhg==}
engines: {node: '>=6.0.0'}
@ -2982,14 +2951,6 @@ packages:
postcss: 7.0.32
dev: true
/css-to-react-native/2.3.2:
resolution: {integrity: sha512-VOFaeZA053BqvvvqIA8c9n0+9vFppVBAHCp6JgFTtTMU3Mzi+XnelJ9XC9ul3BqFzZyQ5N+H0SnwsWT2Ebchxw==}
dependencies:
camelize: 1.0.0
css-color-keywords: 1.0.0
postcss-value-parser: 3.3.1
dev: true
/cssdb/4.4.0:
resolution: {integrity: sha512-LsTAR1JPEM9TpGhl/0p3nQecC2LJ0kD8X5YARu1hk/9I1gril5vDtMZyNxcEpxxDj34YNck/ucjuoUd66K03oQ==}
dev: true
@ -3687,10 +3648,6 @@ packages:
resolution: {integrity: sha1-PYpcZog6FqMMqGQ+hR8Zuqd5eRc=}
dev: true
/fast-memoize/2.5.2:
resolution: {integrity: sha512-Ue0LwpDYErFbmNnZSF0UH6eImUwDmogUO1jyE+JbN2gsQz/jICm1Ve7t9QT0rNSsfJt+Hs4/S3GnsDVjL4HVrw==}
dev: true
/fast-safe-stringify/2.0.7:
resolution: {integrity: sha512-Utm6CdzT+6xsDk2m8S6uL8VHxNwI6Jub+e9NYTcAms28T84pTa25GJQV9j0CY0N1rM8hK4x6grpF2BQf+2qwVA==}
dev: false
@ -3939,32 +3896,6 @@ packages:
assert-plus: 1.0.0
dev: true
/glamor/2.20.40:
resolution: {integrity: sha512-DNXCd+c14N9QF8aAKrfl4xakPk5FdcFwmH7sD0qnC0Pr7xoZ5W9yovhUrY/dJc3psfGGXC58vqQyRtuskyUJxA==}
dependencies:
fbjs: 0.8.17
inline-style-prefixer: 3.0.8
object-assign: 4.1.1
prop-types: 15.7.2
through: 2.3.8
dev: true
/glamorous/4.13.1_glamor@2.20.40:
resolution: {integrity: sha512-x9yCGlRrPEkHF63m+WoZXHnpSet5ipS/fxczx5ic0ZKPPd2mMDyCZ0iEhse49OFlag0yxbJTc7k/L0g1GCmCYQ==}
peerDependencies:
glamor: '>=2'
dependencies:
brcast: 3.0.2
csstype: 2.6.17
fast-memoize: 2.5.2
glamor: 2.20.40
html-tag-names: 1.1.5
is-function: 1.0.2
is-plain-object: 2.0.4
react-html-attributes: 1.4.6
svg-tag-names: 1.1.2
dev: true
/glob-parent/5.1.2:
resolution: {integrity: sha512-AOIgSQCepiJYwP3ARnGx+5VnTu2HBYdzbGP45eLw1vr3zB3vZLeyed1sC9hnbcOc9/SrMyM5RPQrkGz4aS9Zow==}
engines: {node: '>= 6'}
@ -4047,11 +3978,6 @@ packages:
resolution: {integrity: sha512-LSBS2LjbNBTf6287JEbEzvJgftkF5qFkmCo9hDRpAzKhUOlJ+hx8dd4USs00SgsUNwc4617J9ki5YtEClM2ffA==}
dev: true
/has-flag/1.0.0:
resolution: {integrity: sha1-nZ55MWXOAXoA8AQYxD+UKnsdEfo=}
engines: {node: '>=0.10.0'}
dev: true
/has-flag/3.0.0:
resolution: {integrity: sha1-tdRU3CGZriJWmfNGfloH87lVuv0=}
engines: {node: '>=4'}
@ -4155,10 +4081,6 @@ packages:
minimalistic-crypto-utils: 1.0.1
dev: true
/hoist-non-react-statics/1.2.0:
resolution: {integrity: sha1-qkSM8JhtVcxAdzsXF0t90GbLfPs=}
dev: true
/hoist-non-react-statics/3.3.2:
resolution: {integrity: sha512-/gGivxi8JPKWNm/W0jSmzcMPpfpPLc3dY/6GxhX2hQ9iGj3aDfklV4ET7NjKpSinLpJ5vafa9iiGIEZg10SfBw==}
dependencies:
@ -4169,10 +4091,6 @@ packages:
resolution: {integrity: sha512-mxIDAb9Lsm6DoOJ7xH+5+X4y1LU/4Hi50L9C5sIswK3JzULS4bwk1FvjdBgvYR4bzT4tuUQiC15FE2f5HbLvYw==}
dev: true
/html-element-attributes/1.3.1:
resolution: {integrity: sha512-UrRKgp5sQmRnDy4TEwAUsu14XBUlzKB8U3hjIYDjcZ3Hbp86Jtftzxfgrv6E/ii/h78tsaZwAnAE8HwnHr0dPA==}
dev: true
/html-encoding-sniffer/1.0.2:
resolution: {integrity: sha512-71lZziiDnsuabfdYiUeWdCVyKuqwWi23L8YeIgV9jSSZHCtb6wB1BKWooH7L3tn4/FuZJMVWyNaIDr4RGmaSYw==}
dependencies:
@ -4190,10 +4108,6 @@ packages:
resolution: {integrity: sha512-H2iMtd0I4Mt5eYiapRdIDjp+XzelXQ0tFE4JS7YFwFevXXMmOp9myNrUvCg0D6ws8iqkRPBfKHgbwig1SmlLfg==}
dev: true
/html-tag-names/1.1.5:
resolution: {integrity: sha512-aI5tKwNTBzOZApHIynaAwecLBv8TlZTEy/P4Sj2SzzAhBrGuI8yGZ0UIXVPQzOHGS+to2mjb04iy6VWt/8+d8A==}
dev: true
/http-cache-semantics/4.1.0:
resolution: {integrity: sha512-carPklcUh7ROWRK7Cv27RPtdhYhUsela/ue5/jKzjegVvXDqM2ILE9Q2BGn9JZJh1g87cp56su/FgQSzcWS8cQ==}
dev: true
@ -4238,10 +4152,6 @@ packages:
engines: {node: '>=8.12.0'}
dev: true
/hyphenate-style-name/1.0.4:
resolution: {integrity: sha512-ygGZLjmXfPHj+ZWh6LwbC37l43MhfztxetbFCoYTM2VjkIUpeHgSNn7QIyVFj7YQ1Wl9Cbw5sholVJPzWvC2MQ==}
dev: true
/iconv-lite/0.4.24:
resolution: {integrity: sha512-v3MXnZAcvnywkTUEZomIActle7RXXeedOR31wwl7VlyoXO4Qi9arvSenNQWne1TcRwhCL1HwLI21bEqdpj8/rA==}
engines: {node: '>=0.10.0'}
@ -4361,20 +4271,6 @@ packages:
resolution: {integrity: sha512-JV/yugV2uzW5iMRSiZAyDtQd+nxtUnjeLt0acNdw98kKLrvuRVyB80tsREOE7yvGVgalhZ6RNXCmEHkUKBKxew==}
dev: true
/inline-style-prefixer/3.0.8:
resolution: {integrity: sha1-hVG45bTVcyROZqNLBPfTIHaitTQ=}
dependencies:
bowser: 1.9.4
css-in-js-utils: 2.0.1
dev: true
/inline-style-prefixer/4.0.2:
resolution: {integrity: sha512-N8nVhwfYga9MiV9jWlwfdj1UDIaZlBFu4cJSJkIr7tZX7sHpHhGR5su1qdpW+7KPL8ISTvCIkcaFi/JdBknvPg==}
dependencies:
bowser: 1.9.4
css-in-js-utils: 2.0.1
dev: true
/invariant/2.2.4:
resolution: {integrity: sha512-phJfQVBuaJM5raOpJjSfkiD6BpbCE4Ns//LaXl6wGYtUBY83nWS6Rf9tXm2e8VaK60JEjYldbPif/A2B1C2gNA==}
dependencies:
@ -4530,10 +4426,6 @@ packages:
engines: {node: '>=8'}
dev: true
/is-function/1.0.2:
resolution: {integrity: sha512-lw7DUp0aWXYg+CBCN+JKkcE0Q2RayZnSvnZBlwgxHBQhqt5pZNVy4Ri7H9GmmXkdu7LUthszM+Tor1u/2iBcpQ==}
dev: true
/is-generator-fn/2.1.0:
resolution: {integrity: sha512-cTIB4yPYL/Grw0EaSzASzg6bBy9gqCofvWN8okThAYIxKJZC+udlRAmGbM0XLeniEJSs8uEgHPGuHSe1XsOLSQ==}
engines: {node: '>=6'}
@ -6869,10 +6761,6 @@ packages:
util-deprecate: 1.0.2
dev: true
/postcss-value-parser/3.3.1:
resolution: {integrity: sha512-pISE66AbVkp4fDQ7VHBwRNXzAAKJjw4Vw7nWI/+Q3vuly7SNfgYXvm6i5IgFylHGK5sP/xHAbB7N49OS4gWNyQ==}
dev: true
/postcss-value-parser/4.1.0:
resolution: {integrity: sha512-97DXOFbQJhk71ne5/Mt6cOu6yxsSfM0QGQyl0L25Gca4yGWEGJaig7l7gbCX623VqTBNGLRLaVUCnNkcedlRSQ==}
dev: true
@ -7811,12 +7699,6 @@ packages:
scheduler: 0.20.2
dev: true
/react-html-attributes/1.4.6:
resolution: {integrity: sha512-uS3MmThNKFH2EZUQQw4k5pIcU7XIr208UE5dktrj/GOH1CMagqxDl4DCLpt3o2l9x+IB5nVYBeN3Cr4IutBXAg==}
dependencies:
html-element-attributes: 1.3.1
dev: true
/react-is/16.13.1:
resolution: {integrity: sha512-24e6ynE2H+OKt4kqsOvNd8kBpV65zoxbA4BVsEOB3ARVWQki/DHzaUoC5KuON/BiccDaCCTZBuOcfZs70kR8bQ==}
dev: true
@ -7887,17 +7769,23 @@ packages:
tiny-warning: 1.0.3
dev: true
/react-split-pane/2.0.3:
resolution: {integrity: sha512-1rW+EMSJTkS7eYMYethCaNFOjiAVDm/B2LlxJXLr1Uu8ddLrV9pfc5P/fngRBkTGC/0tvxRkW1dLxGY7zvHVkA==}
/react-split-pane/0.1.92_react-dom@17.0.2+react@17.0.2:
resolution: {integrity: sha512-GfXP1xSzLMcLJI5BM36Vh7GgZBpy+U/X0no+VM3fxayv+p1Jly5HpMofZJraeaMl73b3hvlr+N9zJKvLB/uz9w==}
peerDependencies:
react: ^16.0.0-0
react-dom: ^16.0.0-0
dependencies:
prop-types: 15.7.2
react: 17.0.2
react-dom: 17.0.2_react@17.0.2
react-lifecycles-compat: 3.0.4
react-style-proptype: 3.2.2
dev: true
/react-style-proptype/3.2.2:
resolution: {integrity: sha512-ywYLSjNkxKHiZOqNlso9PZByNEY+FTyh3C+7uuziK0xFXu9xzdyfHwg4S9iyiRRoPCR4k2LqaBBsWVmSBwCWYQ==}
dependencies:
glamor: 2.20.40
glamorous: 4.13.1_glamor@2.20.40
inline-style-prefixer: 4.0.2
normalize.css: 7.0.0
prop-types: 15.7.2
react: 16.14.0
react-dom: 16.14.0_react@16.14.0
styled-components: 2.4.1_react@16.14.0
dev: true
/react-tween-state/0.1.5:
@ -8913,33 +8801,6 @@ packages:
engines: {node: '>=0.10.0'}
dev: true
/styled-components/2.4.1_react@16.14.0:
resolution: {integrity: sha1-ZjvQSF1LarRvlGIQ3APSOY0a3nQ=}
peerDependencies:
react: '>= 0.14.0 < 17.0.0-0'
dependencies:
buffer: 5.7.1
css-to-react-native: 2.3.2
fbjs: 0.8.17
hoist-non-react-statics: 1.2.0
is-plain-object: 2.0.4
prop-types: 15.7.2
react: 16.14.0
stylis: 3.5.4
supports-color: 3.2.3
dev: true
/stylis/3.5.4:
resolution: {integrity: sha512-8/3pSmthWM7lsPBKv7NXkzn2Uc9W7NotcwGNpJaa3k7WMM1XDCA4MgT5k/8BIexd5ydZdboXtU90XH9Ec4Bv/Q==}
dev: true
/supports-color/3.2.3:
resolution: {integrity: sha1-ZawFBLOVQXHYpklGsq48u4pfVPY=}
engines: {node: '>=0.8.0'}
dependencies:
has-flag: 1.0.0
dev: true
/supports-color/5.5.0:
resolution: {integrity: sha512-QjVjwdXIt408MIiAqCX4oUKsgU2EqAGzs2Ppkm4aQYbjm+ZEWEcW4SfFNTr4uMNZma0ey4f5lgLrkB0aX0QMow==}
engines: {node: '>=4'}
@ -8969,10 +8830,6 @@ packages:
supports-color: 7.2.0
dev: true
/svg-tag-names/1.1.2:
resolution: {integrity: sha512-LIDOy8NRLGfJegTEnpizWA/ofg3Gyx58JgPEEjvATFciUJW9dHZ2aPTYY0Mn2rQYCeUGZElpHfu91OcWK0IMIw==}
dev: true
/swr/0.5.6_react@17.0.2:
resolution: {integrity: sha512-Bmx3L4geMZjYT5S2Z6EE6/5Cx6v1Ka0LhqZKq8d6WL2eu9y6gHWz3dUzfIK/ymZVHVfwT/EweFXiYGgfifei3w==}
peerDependencies:

View File

@ -164,7 +164,15 @@ update_repo() {
echo -e "\n更新${repo_path}成功...\n"
diff_scripts "$repo_path" "$author" "$path" "$blackword" "$dependence"
else
echo -e "\n更新${repo_path}失败,请检查原因...\n"
echo -e "\n更新${repo_path}失败,重新下载全新仓库...\n"
rm -rf ${repo_path}
git_clone_scripts "${formatUrl}" ${repo_path} "${branch}"
if [[ $exit_status -eq 0 ]]; then
echo -e "\n更新${repo_path}成功...\n"
diff_scripts "$repo_path" "$author" "$path" "$blackword" "$dependence"
else
echo -e "\n更新${repo_path}失败,请检查网络...\n"
fi
fi
}

View File

@ -131,6 +131,25 @@ input:-webkit-autofill:active {
-webkit-transition: color 99999s ease-out, background-color 99999s ease-out;
}
.ant-pro-page-container.ql-container-wrapper {
display: flex;
flex-direction: column;
height: calc(100vh - 48px);
.ant-pro-grid-content.wide {
flex: 1;
.ant-pro-grid-content-children {
height: calc(100% - 48px);
> div,
.ant-pro-page-container-children-content,
.log-container,
.react-codemirror2,
.CodeMirror {
height: 100%;
}
}
}
}
@media (max-width: 768px) {
.ant-pro-grid-content.wide {
.ant-pro-page-container-children-content {
@ -148,20 +167,10 @@ input:-webkit-autofill:active {
height: calc(100vh - 184px);
height: calc(100vh - var(--vh-offset, 0px) - 184px);
}
.monaco-editor:not(.rename-box),
.CodeMirror {
height: calc(100vh - 216px) !important;
height: calc(100vh - var(--vh-offset, 0px) - 216px) !important;
}
.CodeMirror {
width: calc(100vw - 80px);
}
}
.monaco-editor:not(.rename-box),
.CodeMirror {
height: calc(100vh - 176px) !important;
height: calc(100vh - var(--vh-offset, 0px) - 176px) !important;
}
}
.ant-tooltip {

View File

@ -432,7 +432,7 @@ const Crontab = () => {
const index = value.findIndex((x) => x._id === cron._id);
const result = [...value];
if (index === -1) {
result.push(cron);
result.unshift(cron);
} else {
result.splice(index, 1, {
...cron,

View File

@ -21,15 +21,3 @@
.log-container {
display: flex;
}
:global {
.log-wrapper {
.ant-pro-grid-content.wide .ant-pro-page-container-children-content {
background-color: #f8f8f8;
}
.CodeMirror {
width: calc(100% - 32px - @tree-width);
}
}
}

View File

@ -131,7 +131,7 @@ const Log = () => {
style: headerStyle,
}}
>
<div className={`${styles['log-container']}`}>
<div className={`${styles['log-container']} log-container`}>
{!isPhone && (
<div className={styles['left-tree-container']}>
<Input.Search

View File

@ -21,15 +21,3 @@
.log-container {
display: flex;
}
:global {
.log-wrapper {
.ant-pro-grid-content.wide .ant-pro-page-container-children-content {
background-color: #f8f8f8;
}
.CodeMirror {
width: calc(100% - 32px - @tree-width);
}
}
}

View File

@ -120,7 +120,7 @@ const Script = () => {
style: headerStyle,
}}
>
<div className={`${styles['log-container']}`}>
<div className={`${styles['log-container']} log-container`}>
{!isPhone && (
<div className={styles['left-tree-container']}>
<Input.Search

View File

@ -10,7 +10,7 @@ export const useCtx = () => {
useEffect(() => {
const { platform } = browserType();
if (platform === 'mobile') {
if (platform === 'mobile' || document.body.offsetWidth < 768) {
setWidth('auto');
setMarginLeft(0);
setMarginTop(0);