Revision ff763abe
Added by Andreas Müller over 4 years ago
app-import/src/main/java/eu/etaxonomy/cdm/app/greece/GreeceImageActivator.java | ||
---|---|---|
31 | 31 |
* |
32 | 32 |
* https://dev.e-taxonomy.eu/redmine/issues/7075 |
33 | 33 |
* |
34 |
* How to import: |
|
35 |
* |
|
36 |
* <UL> |
|
37 |
* <LI>In Excel file we should have 3 URI columns for large, medium and small.</LI> |
|
38 |
* If they not exists create cells with something like "=WECHSELN(C2;"large";"medium")" (German Excel version) |
|
39 |
* Label these columns url_size1, url_size2 and url_size3</LI> |
|
40 |
* <LI>If the medium and small versions of the images do not yet exist, create them in an according folder |
|
41 |
* (you may need to ask for access to the server in Greece)</LI> |
|
42 |
* <LI>Copy only the new images into a local folder (use date to |
|
43 |
* determine new images if more images are in the original folder)</LI> |
|
44 |
* <LI>Open IrfanView and open File->BatchConversion/Rename</LI> |
|
45 |
* <LI>Use Advanced options for bulk resize and use the following parameters:</LI> |
|
46 |
* <UL><LI> for small: -> Set one or both sides to width=210 (height=-empty-)</LI> |
|
47 |
* <LI> for medium: -> Set short side to 350</LI> |
|
48 |
* </UL> |
|
49 |
* <LI>Select all images and move them to the "input files"</LI> |
|
50 |
* <LI>Choose correct "Output folder for result files" (repeat for both sizes)</LI> |
|
51 |
* <LI>Upload images in both folders to correct place in remote server</LI> |
|
52 |
* <LI>Update the filename parameter in code below.</LI> |
|
53 |
* <LI>Upload the Excel file to /BGBM-PESIHPC/Greece/images/ (see {@link #greekChecklist()}) below</LI> |
|
54 |
* <LI>Run with localH2 to test if everything works, if yes |
|
55 |
* <LI>Run |
|
56 |
* </UL> |
|
57 |
* |
|
34 | 58 |
* @author a.mueller |
35 | 59 |
* @since 13.12.2016 |
36 | 60 |
*/ |
... | ... | |
39 | 63 |
private static final Logger logger = Logger.getLogger(GreeceImageActivator.class); |
40 | 64 |
|
41 | 65 |
|
42 |
static final ICdmDataSource cdmDestination = CdmDestinations.localH2(); |
|
66 |
|
|
67 |
// static final ICdmDataSource cdmDestination = CdmDestinations.localH2(); |
|
43 | 68 |
// static final ICdmDataSource cdmDestination = CdmDestinations.cdm_test_local_mysql_test(); |
44 |
// static final ICdmDataSource cdmDestination = CdmDestinations.cdm_production_greece_checklist();
|
|
69 |
static final ICdmDataSource cdmDestination = CdmDestinations.cdm_production_greece_checklist(); |
|
45 | 70 |
|
46 | 71 |
// private static final UUID sourceUuid = UUID.fromString("0fd093fe-ffdf-4ace-847b-aad6f0659678"); |
47 | 72 |
private static final UUID sourceUuid = UUID.fromString("9e6a3815-fb8d-46c3-a250-6d8a350d03fc"); |
48 | 73 |
|
49 |
private static final String fileName = "20190507_fog_images.xlsx"; |
|
50 |
// private static final String fileName = "20190124_fog_images.xlsx";
|
|
74 |
// private static final String fileName = "20190507_fog_images.xlsx";
|
|
75 |
private static final String fileName = "20190726_fog_images.xlsx";
|
|
51 | 76 |
|
52 | 77 |
|
53 | 78 |
// NOTE!!: Darauf achten, dass die Header case sensitiv sind und keine Leerzeichen am Ende sein sollten, trim funktioniert seltsamerweise nicht immer |
Also available in: Unified diff
latest version of GreeceImageActivator