mirror of
https://github.com/whyour/qinglong.git
synced 2025-05-23 06:46:09 +08:00
修复依赖安装失败状态变更
This commit is contained in:
parent
6dba8ae72d
commit
81898f9dd7
|
@ -360,7 +360,17 @@ export default class DependenceService {
|
||||||
? DependenceStatus.installFailed
|
? DependenceStatus.installFailed
|
||||||
: DependenceStatus.removeFailed;
|
: DependenceStatus.removeFailed;
|
||||||
}
|
}
|
||||||
await DependenceModel.update({ status }, { where: { id: depIds } });
|
const docs = await DependenceModel.findAll({ where: { id: depIds } });
|
||||||
|
const _docIds = docs
|
||||||
|
.filter((x) => x.status !== DependenceStatus.cancelled)
|
||||||
|
.map((x) => x.id!);
|
||||||
|
|
||||||
|
if (_docIds.length > 0) {
|
||||||
|
await DependenceModel.update(
|
||||||
|
{ status },
|
||||||
|
{ where: { id: _docIds } },
|
||||||
|
);
|
||||||
|
}
|
||||||
|
|
||||||
// 如果删除依赖成功或者强制删除
|
// 如果删除依赖成功或者强制删除
|
||||||
if ((isSucceed || force) && !isInstall) {
|
if ((isSucceed || force) && !isInstall) {
|
||||||
|
|
Loading…
Reference in New Issue
Block a user