-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathalbum.js
106 lines (106 loc) · 1.93 KB
/
album.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
/*
Evolutility Model for Music Album
https://github.com/evoluteur/evolutility-models
(c) 2022 Olivier Giulieri
*/
module.exports = {
id: "album",
oid: 7,
active: true,
position: 20,
world: "music",
icon: "cd.png",
title: "Albums",
table: "music_album",
name: "album",
namePlural: "albums",
titleField: "name",
defaultViewMany: "cards",
noStats: true,
fields: [
{
id: "title",
type: "text",
label: "Title",
column: "title",
required: true,
width: 62,
inMany: true,
inSearch: true,
},
{
id: "artist",
type: "lov",
label: "Artist",
column: "artist_id",
required: true,
width: 38,
inMany: true,
object: "artist",
lovTable: "music_artist",
lovColumn: "name",
},
{
id: "url",
label: "Amazon",
type: "url",
column: "url",
width: 62,
},
{
id: "length",
type: "text",
label: "Length",
column: "length",
width: 38,
inMany: true,
},
{
id: "description",
column: "description",
type: "textmultiline",
label: "Description",
maxLength: 1000,
width: 100,
height: 8,
inMany: false,
inSearch: true,
},
{
id: "cover",
type: "image",
label: "Cover",
width: 100,
inMany: true,
column: "cover",
},
],
groups: [
{
id: "p-album",
type: "panel",
label: "Album",
width: 70,
fields: ["title", "artist", "url", "length", "description"],
},
{
id: "p-cover",
type: "panel",
label: "Cover",
width: 30,
fields: ["cover"],
},
],
collections: [
{
id: "music_track",
label: "Tracks",
icon: "music.png",
table: "music_track",
column: "album_id",
orderBy: "name",
object: "track",
fields: ["name", "genre", "length"],
},
],
};