mirror of
https://github.com/lacerta-doc/Lacerta.git
synced 2024-11-22 16:03:15 +00:00
適当な日付を表示するようにした
This commit is contained in:
parent
3f58c623f3
commit
af4513212d
|
@ -10,8 +10,10 @@ import one.nem.lacerta.model.document.DocumentMeta;
|
||||||
import one.nem.lacerta.model.document.path.DocumentPath;
|
import one.nem.lacerta.model.document.path.DocumentPath;
|
||||||
import one.nem.lacerta.utils.LacertaLogger;
|
import one.nem.lacerta.utils.LacertaLogger;
|
||||||
|
|
||||||
|
import com.github.javafaker.DateAndTime;
|
||||||
import com.github.javafaker.Faker;
|
import com.github.javafaker.Faker;
|
||||||
|
|
||||||
|
import java.text.DateFormat;
|
||||||
import java.util.ArrayList;
|
import java.util.ArrayList;
|
||||||
import java.util.Objects;
|
import java.util.Objects;
|
||||||
import java.util.UUID;
|
import java.util.UUID;
|
||||||
|
@ -84,14 +86,14 @@ public class LacertaLibraryStubImpl implements LacertaLibrary {
|
||||||
if (itemType == ListItemType.ITEM_TYPE_FOLDER) {
|
if (itemType == ListItemType.ITEM_TYPE_FOLDER) {
|
||||||
ListItem listItem = new ListItem();
|
ListItem listItem = new ListItem();
|
||||||
listItem.setTitle("FakeFolder" + faker.number().digits(3));
|
listItem.setTitle("FakeFolder" + faker.number().digits(3));
|
||||||
listItem.setDescription("Updated at " + faker.date().toString());
|
listItem.setDescription("Updated at " + DateFormat.getDateTimeInstance().format(faker.date().birthday()));
|
||||||
listItem.setItemType(ListItemType.ITEM_TYPE_FOLDER);
|
listItem.setItemType(ListItemType.ITEM_TYPE_FOLDER);
|
||||||
listItem.setItemId(UUID.randomUUID().toString());
|
listItem.setItemId(UUID.randomUUID().toString());
|
||||||
return listItem;
|
return listItem;
|
||||||
} else if (itemType == ListItemType.ITEM_TYPE_DOCUMENT) {
|
} else if (itemType == ListItemType.ITEM_TYPE_DOCUMENT) {
|
||||||
ListItem listItem = new ListItem();
|
ListItem listItem = new ListItem();
|
||||||
listItem.setTitle("FakeDocument" + faker.book().title());
|
listItem.setTitle("FakeDocument" + faker.book().title());
|
||||||
listItem.setDescription("Updated at " + faker.date().toString());
|
listItem.setDescription("Updated at " + DateFormat.getDateTimeInstance().format(faker.date().birthday()));
|
||||||
listItem.setItemType(ListItemType.ITEM_TYPE_DOCUMENT);
|
listItem.setItemType(ListItemType.ITEM_TYPE_DOCUMENT);
|
||||||
listItem.setItemId(UUID.randomUUID().toString());
|
listItem.setItemId(UUID.randomUUID().toString());
|
||||||
return listItem;
|
return listItem;
|
||||||
|
|
Loading…
Reference in New Issue
Block a user