| Line 3... |
Line 3... |
| 3 |
*/
|
3 |
*/
|
| 4 |
package in.shop2020.ui.util;
|
4 |
package in.shop2020.ui.util;
|
| 5 |
|
5 |
|
| 6 |
import in.shop2020.metamodel.core.Entity;
|
6 |
import in.shop2020.metamodel.core.Entity;
|
| 7 |
import in.shop2020.metamodel.core.EntityState;
|
7 |
import in.shop2020.metamodel.core.EntityState;
|
| - |
|
8 |
import in.shop2020.metamodel.core.EntityStatus;
|
| 8 |
import in.shop2020.metamodel.core.Media;
|
9 |
import in.shop2020.metamodel.core.Media;
|
| 9 |
import in.shop2020.metamodel.core.Slide;
|
10 |
import in.shop2020.metamodel.core.Slide;
|
| 10 |
import in.shop2020.metamodel.core.SpecialPage;
|
11 |
import in.shop2020.metamodel.core.SpecialPage;
|
| 11 |
import in.shop2020.metamodel.definitions.Catalog;
|
12 |
import in.shop2020.metamodel.definitions.Catalog;
|
| 12 |
import in.shop2020.metamodel.util.CreationUtils;
|
13 |
import in.shop2020.metamodel.util.CreationUtils;
|
| Line 52... |
Line 53... |
| 52 |
}
|
53 |
}
|
| 53 |
|
54 |
|
| 54 |
public static void main(String[] args) throws Exception {
|
55 |
public static void main(String[] args) throws Exception {
|
| 55 |
Date when = new Date(CreationUtils.getLastContentGenerationTime() - 86400 * 10 * 1000);
|
56 |
Date when = new Date(CreationUtils.getLastContentGenerationTime() - 86400 * 10 * 1000);
|
| 56 |
for (Map.Entry<Long, EntityState> es : CreationUtils.getEntitiesState().entrySet()) {
|
57 |
for (Map.Entry<Long, EntityState> es : CreationUtils.getEntitiesState().entrySet()) {
|
| 57 |
if (es.getValue().getMerkedReadyOn().after(when)) {
|
58 |
if ( es.getValue().getStatus().equals(EntityStatus.READY) && es.getValue().getMerkedReadyOn().after(when)) {
|
| 58 |
Entity e = CreationUtils.getEntity(es.getValue().getID());
|
59 |
Entity e = CreationUtils.getEntity(es.getValue().getID());
|
| 59 |
LOG.info("Entity ID - " + e.getID());
|
60 |
LOG.info("Entity ID - " + e.getID());
|
| 60 |
List<Slide> slides = e.getSlides();
|
61 |
List<Slide> slides = e.getSlides();
|
| 61 |
if (slides != null) {
|
62 |
if (slides != null) {
|
| 62 |
for (Slide slide : slides) {
|
63 |
for (Slide slide : slides) {
|