Added created / updated timestamp to exported JSON

This commit is contained in:
Stash Dev
2019-03-27 12:53:15 -07:00
parent 763424bc40
commit 4f7266f0ed
8 changed files with 103 additions and 58 deletions

View File

@@ -3,13 +3,16 @@ package jsonschema
import (
"encoding/json"
"fmt"
"github.com/stashapp/stash/pkg/models"
"os"
)
type Studio struct {
Name string `json:"name,omitempty"`
URL string `json:"url,omitempty"`
Image string `json:"image,omitempty"`
Name string `json:"name,omitempty"`
URL string `json:"url,omitempty"`
Image string `json:"image,omitempty"`
CreatedAt models.JSONTime `json:"created_at,omitempty"`
UpdatedAt models.JSONTime `json:"updated_at,omitempty"`
}
func LoadStudioFile(filePath string) (*Studio, error) {