2020-05-01 13:11:02 +02:00
|
|
|
package entity
|
|
|
|
|
|
|
|
import "time"
|
|
|
|
|
|
|
|
var date = time.Date(2050, 3, 6, 2, 6, 51, 0, time.UTC)
|
|
|
|
|
2020-05-10 19:43:49 +02:00
|
|
|
type LinkMap map[string]Link
|
|
|
|
|
|
|
|
var LinkFixtures = LinkMap{
|
2020-05-01 13:11:02 +02:00
|
|
|
"1jxf3jfn2k": {
|
2021-07-23 13:25:28 +02:00
|
|
|
LinkUID: "sqn2xpryd1ob7gtf",
|
|
|
|
ShareUID: "at9lxuqxpogaaba8",
|
|
|
|
ShareSlug: "holiday-2030",
|
2020-06-28 14:52:26 +02:00
|
|
|
LinkToken: "1jxf3jfn2k",
|
|
|
|
LinkExpires: 0,
|
2021-07-23 13:25:28 +02:00
|
|
|
LinkViews: 12,
|
|
|
|
MaxViews: 0,
|
|
|
|
HasPassword: false,
|
2020-06-28 14:52:26 +02:00
|
|
|
CanComment: true,
|
|
|
|
CanEdit: false,
|
|
|
|
CreatedAt: time.Date(2020, 3, 6, 2, 6, 51, 0, time.UTC),
|
2021-07-25 23:48:34 +02:00
|
|
|
ModifiedAt: time.Date(2020, 3, 6, 2, 6, 51, 0, time.UTC),
|
2020-05-01 13:11:02 +02:00
|
|
|
},
|
2020-07-08 17:06:23 +02:00
|
|
|
"4jxf3jfn2k": {
|
2021-07-23 13:25:28 +02:00
|
|
|
LinkUID: "sqn2xpryd1ob8gtf",
|
|
|
|
ShareUID: "at9lxuqxpogaaba7",
|
|
|
|
ShareSlug: "christmas-2030",
|
2020-07-08 17:06:23 +02:00
|
|
|
LinkToken: "4jxf3jfn2k",
|
|
|
|
LinkExpires: 0,
|
2021-07-23 13:25:28 +02:00
|
|
|
LinkViews: 0,
|
|
|
|
MaxViews: 0,
|
|
|
|
HasPassword: false,
|
2020-07-08 17:06:23 +02:00
|
|
|
CanComment: true,
|
|
|
|
CanEdit: false,
|
|
|
|
CreatedAt: time.Date(2020, 3, 6, 2, 6, 51, 0, time.UTC),
|
2021-07-25 23:48:34 +02:00
|
|
|
ModifiedAt: time.Date(2020, 3, 6, 2, 6, 51, 0, time.UTC),
|
2020-07-08 17:06:23 +02:00
|
|
|
},
|
2020-07-09 11:27:44 +02:00
|
|
|
"5jxf3jfn2k": {
|
2021-07-23 13:25:28 +02:00
|
|
|
LinkUID: "sqn9xpryd1ob9gtf",
|
2020-07-09 11:27:44 +02:00
|
|
|
ShareUID: "ft2es39w45bnlqdw",
|
|
|
|
ShareSlug: "ft2es39w45bnlqdw",
|
2021-07-23 13:25:28 +02:00
|
|
|
LinkToken: "5jxf3jfn2k",
|
|
|
|
LinkExpires: 0,
|
|
|
|
LinkViews: 0,
|
|
|
|
MaxViews: 0,
|
|
|
|
HasPassword: false,
|
2020-07-09 11:27:44 +02:00
|
|
|
CanComment: true,
|
|
|
|
CanEdit: false,
|
|
|
|
CreatedAt: time.Date(2020, 3, 6, 2, 6, 51, 0, time.UTC),
|
2021-07-25 23:48:34 +02:00
|
|
|
ModifiedAt: time.Date(2020, 3, 6, 2, 6, 51, 0, time.UTC),
|
2020-07-09 11:27:44 +02:00
|
|
|
},
|
2020-07-09 15:37:16 +02:00
|
|
|
"6jxf3jfn2k": {
|
2021-07-23 13:25:28 +02:00
|
|
|
LinkUID: "sqn1xpryd1ob1gtf",
|
|
|
|
ShareUID: "lt9k3pw1wowuy3c3",
|
|
|
|
ShareSlug: "lt9k3pw1wowuy3c3",
|
2020-07-09 15:37:16 +02:00
|
|
|
LinkToken: "6jxf3jfn2k",
|
|
|
|
LinkExpires: 0,
|
2021-07-23 13:25:28 +02:00
|
|
|
LinkViews: 0,
|
|
|
|
MaxViews: 0,
|
|
|
|
HasPassword: false,
|
2020-07-09 15:37:16 +02:00
|
|
|
CanComment: true,
|
|
|
|
CanEdit: false,
|
|
|
|
CreatedAt: time.Date(2020, 3, 6, 2, 6, 51, 0, time.UTC),
|
2021-07-25 23:48:34 +02:00
|
|
|
ModifiedAt: time.Date(2020, 3, 6, 2, 6, 51, 0, time.UTC),
|
2020-07-09 15:37:16 +02:00
|
|
|
},
|
2020-07-10 17:27:06 +02:00
|
|
|
"7jxf3jfn2k": {
|
2021-07-23 13:25:28 +02:00
|
|
|
LinkUID: "sqn2xpryd1ob2gtf",
|
|
|
|
ShareUID: "pt9k3pw1wowuy3c3",
|
|
|
|
ShareSlug: "pt9k3pw1wowuy3c3",
|
2020-07-10 17:27:06 +02:00
|
|
|
LinkToken: "7jxf3jfn2k",
|
|
|
|
LinkExpires: 0,
|
2021-07-23 13:25:28 +02:00
|
|
|
LinkViews: 0,
|
|
|
|
MaxViews: 0,
|
|
|
|
HasPassword: false,
|
2020-07-10 17:27:06 +02:00
|
|
|
CanComment: true,
|
|
|
|
CanEdit: false,
|
|
|
|
CreatedAt: time.Date(2020, 3, 6, 2, 6, 51, 0, time.UTC),
|
2021-07-25 23:48:34 +02:00
|
|
|
ModifiedAt: time.Date(2020, 3, 6, 2, 6, 51, 0, time.UTC),
|
2020-07-10 17:27:06 +02:00
|
|
|
},
|
2020-05-01 13:11:02 +02:00
|
|
|
}
|
|
|
|
|
|
|
|
// CreateLinkFixtures inserts known entities into the database for testing.
|
|
|
|
func CreateLinkFixtures() {
|
|
|
|
for _, entity := range LinkFixtures {
|
|
|
|
Db().Create(&entity)
|
|
|
|
}
|
|
|
|
}
|