mirror of
https://github.com/discourse/discourse.git
synced 2025-03-24 11:35:46 +08:00
DEV: adds tag to core fabricators (#28480)
This commit is contained in:
parent
c91dcd0447
commit
905b4f900e
@ -36,6 +36,16 @@ export default class CoreFabricators {
|
|||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
tag(args = {}) {
|
||||||
|
return this.store.createRecord("tag", {
|
||||||
|
id: args.id || incrementSequence(),
|
||||||
|
name: args.name ?? getLoadedFaker().faker.word.noun(),
|
||||||
|
description: args.description ?? getLoadedFaker().faker.lorem.sentence(),
|
||||||
|
count: args.count ?? 0,
|
||||||
|
pm_count: args.pm_count ?? 0,
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
topic(args = {}) {
|
topic(args = {}) {
|
||||||
return this.store.createRecord("topic", {
|
return this.store.createRecord("topic", {
|
||||||
id: args.id || incrementSequence(),
|
id: args.id || incrementSequence(),
|
||||||
|
Loading…
x
Reference in New Issue
Block a user