mirror of
https://github.com/Start9Labs/start-os.git
synced 2026-03-26 18:31:52 +00:00
mocks fixed
This commit is contained in:
committed by
Aiden McClelland
parent
007d9d9d09
commit
aef1569e56
@@ -5,7 +5,7 @@ import { PatchDbService } from 'src/app/services/patch-db/patch-db.service'
|
||||
import { PackageDataEntry, PackageState } from 'src/app/services/patch-db/data-model'
|
||||
import { Subscription } from 'rxjs'
|
||||
import { PkgStatusRendering, renderPkgStatus } from 'src/app/services/pkg-status-rendering.service'
|
||||
import { delay, filter } from 'rxjs/operators'
|
||||
import { filter } from 'rxjs/operators'
|
||||
|
||||
@Component({
|
||||
selector: 'app-list',
|
||||
|
||||
@@ -348,12 +348,11 @@ export class MockApiService extends ApiService {
|
||||
unpacked: 0,
|
||||
'unpack-complete': false,
|
||||
}
|
||||
const installedMock = Mock.Pkgs[params.id]
|
||||
delete installedMock.installed
|
||||
const pkg: PackageDataEntry = {
|
||||
...installedMock,
|
||||
...Mock.Pkgs[params.id],
|
||||
state: PackageState.Installing,
|
||||
'install-progress': initialProgress,
|
||||
installed: undefined,
|
||||
}
|
||||
const patch = [
|
||||
{
|
||||
@@ -560,8 +559,8 @@ export class MockApiService extends ApiService {
|
||||
const patch = [
|
||||
{
|
||||
op: PatchOp.REPLACE,
|
||||
path: `/package-data/${id}/state`,
|
||||
value: PackageState.Installed,
|
||||
path: `/package-data/${id}`,
|
||||
value: Mock.Pkgs[id],
|
||||
},
|
||||
]
|
||||
this.http.rpcRequest<WithRevision<null>>({ method: 'db.patch', params: { patch } })
|
||||
|
||||
Reference in New Issue
Block a user