mirror of
https://github.com/whyour/qinglong.git
synced 2025-05-22 22:36:06 +08:00
增加批量重新安装依赖
This commit is contained in:
parent
144b543091
commit
a2f2306430
|
@ -4,6 +4,8 @@ dir_shell=/ql/shell
|
|||
. $dir_shell/share.sh
|
||||
link_shell
|
||||
|
||||
export isFirstStartServer=true
|
||||
|
||||
echo -e "======================1. 检测配置文件========================\n"
|
||||
make_dir /etc/nginx/conf.d
|
||||
make_dir /run/nginx
|
||||
|
|
|
@ -246,6 +246,8 @@ usage() {
|
|||
update_qinglong() {
|
||||
patch_version
|
||||
|
||||
export isFirstStartServer=false
|
||||
|
||||
local no_restart="$1"
|
||||
local all_branch=$(git branch -a)
|
||||
local primary_branch="master"
|
||||
|
|
|
@ -320,6 +320,30 @@ const Dependence = ({ headerStyle, isPhone, socketMessage }: any) => {
|
|||
});
|
||||
};
|
||||
|
||||
const handlereInstallDependencies = () => {
|
||||
Modal.confirm({
|
||||
title: '确认重新安装',
|
||||
content: <>确认重新安装选中的依赖吗</>,
|
||||
onOk() {
|
||||
request
|
||||
.put(`${config.apiPrefix}dependencies/reinstall`, {
|
||||
data: selectedRowIds,
|
||||
})
|
||||
.then((data: any) => {
|
||||
if (data.code === 200) {
|
||||
setSelectedRowIds([]);
|
||||
getDependencies();
|
||||
} else {
|
||||
message.error(data);
|
||||
}
|
||||
});
|
||||
},
|
||||
onCancel() {
|
||||
console.log('Cancel');
|
||||
},
|
||||
});
|
||||
};
|
||||
|
||||
const getDependenceDetail = (dependence: any) => {
|
||||
request
|
||||
.get(`${config.apiPrefix}dependencies/${dependence.id}`)
|
||||
|
@ -403,6 +427,13 @@ const Dependence = ({ headerStyle, isPhone, socketMessage }: any) => {
|
|||
<>
|
||||
{selectedRowIds.length > 0 && (
|
||||
<div style={{ marginBottom: 16 }}>
|
||||
<Button
|
||||
type="primary"
|
||||
style={{ marginBottom: 5, marginLeft: 8 }}
|
||||
onClick={() => handlereInstallDependencies()}
|
||||
>
|
||||
批量安装
|
||||
</Button>
|
||||
<Button
|
||||
type="primary"
|
||||
style={{ marginBottom: 5, marginLeft: 8 }}
|
||||
|
|
Loading…
Reference in New Issue
Block a user