mirror of
https://github.com/stashapp/stash.git
synced 2025-12-17 04:14:39 +03:00
[Feature] Add fields director and (studio) code to scenes (#3051)
* added schema migration and updated data models * added code and director to UI * new fields are exported and imported * added filters * Add changelog entry
This commit is contained in:
@@ -39,8 +39,10 @@ type TagFinder interface {
|
||||
func ToBasicJSON(ctx context.Context, reader CoverGetter, scene *models.Scene) (*jsonschema.Scene, error) {
|
||||
newSceneJSON := jsonschema.Scene{
|
||||
Title: scene.Title,
|
||||
Code: scene.Code,
|
||||
URL: scene.URL,
|
||||
Details: scene.Details,
|
||||
Director: scene.Director,
|
||||
CreatedAt: json.JSONTime{Time: scene.CreatedAt},
|
||||
UpdatedAt: json.JSONTime{Time: scene.UpdatedAt},
|
||||
}
|
||||
|
||||
@@ -82,7 +82,9 @@ func (i *Importer) sceneJSONToScene(sceneJSON jsonschema.Scene) models.Scene {
|
||||
newScene := models.Scene{
|
||||
// Path: i.Path,
|
||||
Title: sceneJSON.Title,
|
||||
Code: sceneJSON.Code,
|
||||
Details: sceneJSON.Details,
|
||||
Director: sceneJSON.Director,
|
||||
URL: sceneJSON.URL,
|
||||
PerformerIDs: models.NewRelatedIDs([]int{}),
|
||||
TagIDs: models.NewRelatedIDs([]int{}),
|
||||
|
||||
Reference in New Issue
Block a user