mirror of
https://github.com/shumaiOne/shumai.git
synced 2026-11-24 10:46:52 +00:00
fix(core): inherit sortIndex when creating version stack container
This commit is contained in:
@@ -58,6 +58,9 @@ export class VersionStackService {
|
||||
throw new Error('parent not found')
|
||||
}
|
||||
|
||||
const firstFile = files[0]
|
||||
const sortIndex = firstFile?.sortIndex || null
|
||||
|
||||
const stack = await tx.asset.create({
|
||||
data: {
|
||||
type: AssetType.version_stack,
|
||||
@@ -67,6 +70,7 @@ export class VersionStackService {
|
||||
projectId: projectId,
|
||||
creatorId: creatorId,
|
||||
parentId: parentId,
|
||||
sortIndex: sortIndex,
|
||||
},
|
||||
})
|
||||
|
||||
|
||||
Reference in New Issue
Block a user