mirror of
https://github.com/hcengineering/platform.git
synced 2025-04-20 15:20:18 +00:00
SubIssues status another project fix (#2904)
Signed-off-by: Denis Bykhov <bykhov.denis@gmail.com>
This commit is contained in:
parent
934ada1fb8
commit
93bc04843f
@ -34,6 +34,7 @@
|
||||
export let component: Ref<Component> | null = null
|
||||
export let subIssues: IssueDraft[] = []
|
||||
export let shouldSaveDraft: boolean = false
|
||||
let lastProject = project
|
||||
|
||||
let isCollapsed = false
|
||||
let isCreating = $draftsStore[tracker.ids.IssueDraftChild] !== undefined
|
||||
@ -48,6 +49,18 @@
|
||||
}
|
||||
}
|
||||
|
||||
$: onProjectChange(project)
|
||||
|
||||
function onProjectChange (project: Project | undefined) {
|
||||
if (lastProject?._id === project?._id) return
|
||||
lastProject = project
|
||||
if (project === undefined) return
|
||||
subIssues.forEach((p) => {
|
||||
p.status = project.defaultIssueStatus
|
||||
p.space = project._id
|
||||
})
|
||||
}
|
||||
|
||||
const client = getClient()
|
||||
|
||||
export async function save (parents: IssueParentInfo[]) {
|
||||
|
@ -233,3 +233,9 @@
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<style lang="scss">
|
||||
.antiPopup {
|
||||
max-width: 100%;
|
||||
}
|
||||
</style>
|
||||
|
Loading…
Reference in New Issue
Block a user