1 2012-11-13 Murray Cumming <murrayc@murrayc.com>
3 Do not use client.GWT for shared code.
5 * src/main/java/org/glom/web/shared/libglom/layout/Formatting.java:
6 Import shared.GWT instead of client.GWT, which seems to be appropriate.
8 2012-11-12 Murray Cumming <murrayc@murrayc.com>
10 Use image data when recreating databases for testing.
12 * src/main/java/org/glom/web/shared/DataItem.java: Add get/setImageData(),
13 for use locally (not acrosss the network) when recreating databases
15 getValue(): Use it here instead of getImageDataUrl(), noting that
16 this method is only for use when recreating databases.
17 * src/main/java/org/glom/web/server/libglom/Document.java:
18 getNodeTextChildAsValue(): Use it instead of setImageDataUrl().
20 2012-11-09 Murray Cumming <murrayc@murrayc.com>
22 OnlineGlomImages: Detect the mime-type (content type).
24 * src/main/java/org/glom/web/server/OnlineGlomImages.java:
25 doGet(): Instead of hard-coding image/png.
27 2012-11-09 Murray Cumming <murrayc@murrayc.com>
29 Eclipse project files: Use JDK 1.7 instead of JDK 1.6.
32 * .settings/org.eclipse.jdt.core.prefs: By changing the Eclipse
33 Java Compiler and Java Build path settings in the UI.
35 2012-11-09 Murray Cumming <murrayc@murrayc.com>
37 Use the latest (now stable) version of GWT.
39 * pom.xml: And the latest version of the gwt-maven-plugin.
41 2012-11-08 Murray Cumming <murrayc@murrayc.com>
43 Added an Indonesian translation.
45 * src/main/java/org/glom/web/OnlineGlom.gwt.xml:
46 * src/main/resources/org/glom/web/client/ui/OnlineGlomConstants_id.properties:
47 This is from the new translation in Glom.
49 2012-07-23 Murray Cumming <murrayc@murrayc.com>
53 * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java:
55 * src/main/java/org/glom/web/server/ConfiguredDocumentSet.java:
57 * src/main/java/org/glom/web/server/OnlineGlomImages.java: A new servlet just
58 for serving image data.
59 * src/main/webapp/WEB-INF/web.xml: Mention the new servlet.
61 * src/main/java/org/glom/web/shared/DataItem.java: Added get/setImageDataUrl().
62 * src/main/java/org/glom/web/client/ui/details/DetailsCell.java:
63 setData(): For image field types, add a GWT Image widget,
64 with the URL that was set in the DataItem.
66 * pom.xml: Depend on org.apache.httpcomponents for UriBuilder.
67 * src/main/java/org/glom/web/server/database/DBAccess.java:
68 convertResultSetToDTO(): Set the URL for image data, so the client browser
69 can retrieve the image from our new servlet. This uses UriBuilder.
70 Move getPrimaryKeyField to:
71 * src/main/java/org/glom/web/server/libglom/Document.java:
72 Added getTablePrimaryKeyField().
74 * src/main/java/org/glom/web/server/database/DetailsDBAccess.java:
75 * src/main/java/org/glom/web/server/database/ListDBAccess.java:
76 * src/main/java/org/glom/web/server/database/RelatedListNavigation.java:
79 2012-07-22 Murray Cumming <murrayc@murrayc.com>
83 * src/main/java/org/glom/web/OnlineGlom.gwt.xml:
84 * src/main/java/org/glom/web/client/OnlineGlomService.java:
85 * src/main/webapp/WEB-INF/web.xml: Change the servlet-name from libGlom
86 to gwtGlom, which is more appropriate.
87 This servlet name does not seem to be visible to the client side anyway.
89 2012-07-22 Murray Cumming <murrayc@murrayc.com>
91 Tests: Make the imports of assert*() consistent.
93 * src/test/java/org/glom/web/client/GwtTestOnlineGlom.java:
94 * src/test/java/org/glom/web/client/place/DetailsPlaceTest.java:
95 * src/test/java/org/glom/web/client/place/ListPlaceTest.java:
96 * src/test/java/org/glom/web/server/ConfiguredDocumentTest.java:
97 * src/test/java/org/glom/web/server/SelfHostConfiguredDocumentTest.java:
98 * src/test/java/org/glom/web/server/SelfHostExampleTest.java:
99 * src/test/java/org/glom/web/server/libglom/DocumentTest.java:
100 * src/test/java/org/glom/web/server/libglom/LayoutItemFieldTest.java:
101 * src/test/java/org/glom/web/server/libglom/LayoutItemPortalDeepCloneTest.java:
102 * src/test/java/org/glom/web/shared/DataItemTest.java:
104 import static org.junit.Assert.*;
105 which seems fairly common.
109 2012-07-21 Murray Cumming <murrayc@murrayc.com>
111 tests: Move a test that needs a database connection.
113 * src/test/java/org/glom/web/server/ConfiguredDocumentTest.java:
114 Move testGetListViewLayoutGroup() to
115 * src/test/java/org/glom/web/server/SelfHostConfiguredDocumentTest.java:
116 because it needs a database connection.
118 2012-07-21 Murray Cumming <murrayc@murrayc.com>
120 tests: Use @BeforeClass on tearDown().
122 * src/test/java/org/glom/web/server/OnlineGlomPropertiesTest.java:
123 * src/test/java/org/glom/web/server/SelfHostExampleTest.java:
124 This avoids leaking a postgres process in SelfHostExampleTest.
126 2012-07-21 Murray Cumming <murrayc@murrayc.com>
128 tests: Test translations more.
130 * src/test/java/org/glom/web/server/ConfiguredDocumentTest.java:
131 * src/test/java/org/glom/web/server/SelfHostConfiguredDocumentTest.java:
132 Test titles in the non-default locale.
134 2012-07-21 Murray Cumming <murrayc@murrayc.com>
136 tests: Add SelfHostConfiguredDocumentTest
138 * src/test/java/org/glom/web/server/SelfHoster.java: Add getters for the
139 username and password, for use by ConfiguredDocument.
140 * src/test/java/org/glom/web/server/SelfHostConfiguredDocumentTest.java:
141 This tests some of the ConfiguredDocument API that requires a database connection.
143 2012-07-21 Murray Cumming <murrayc@murrayc.com>
145 Document: Load title translations and test them.
147 * src/main/java/org/glom/web/server/libglom/Document.java: Load the translations
148 of titles. I am surprised that we do not do this yet.
149 * src/test/java/org/glom/web/server/ConfiguredDocumentTest.java:
150 * src/test/java/org/glom/web/server/libglom/DocumentTest.java:
151 Test translations more.
153 2012-07-20 Murray Cumming <murrayc@murrayc.com>
157 * src/main/java/org/glom/web/server/ConfiguredDocument.java:
158 * src/main/java/org/glom/web/server/database/ListDBAccess.java:
159 Set the timeout here too.
161 2012-07-20 Murray Cumming <murrayc@murrayc.com>
163 tests: ConfiguredDocumentTest: Make this pass.
165 * src/test/java/org/glom/web/server/ConfiguredDocumentTest.java:
166 Disable tests that need a database connection.
168 2012-07-20 Murray Cumming <murrayc@murrayc.com>
170 Use Java 1.7 instead of Java 1.6.
172 * pom.xml: Specify the 1.7 JDK, though I don't like how we seem to need
173 to do this twice, at least for Eclipse.
174 This seems OK because it is the current version.
176 2012-07-20 Murray Cumming <murrayc@murrayc.com>
180 * src/main/java/org/glom/web/server/Log.java: Avoid using null strings.
181 * src/main/java/org/glom/web/server/database/ListDBAccess.java:
182 Avoid using a null Connection.
184 2012-07-20 Murray Cumming <murrayc@murrayc.com>
186 tests: Add a ConfiguredDocument test.
188 * src/test/java/org/glom/web/server/ConfiguredDocumentTest.java:
191 2012-07-20 Murray Cumming <murrayc@murrayc.com>
193 LayoutItemFIeld: getName(): Use the Field if it is set.
195 * src/main/java/org/glom/web/shared/libglom/layout/LayoutItemField.java:
196 getName(): If the full field details have been set, return its name, so that
197 callers do not need to set the name separately.
198 * src/test/java/org/glom/web/server/SelfHostExampleTest.java:
199 testExampleMusiccollectionData): Do not use a TYPE_FORWARD_ONLY statement,
200 so we can count the rows.
202 2012-07-20 Murray Cumming <murrayc@murrayc.com>
204 tests: SelfHoster: Test SqlUtils too.
206 * src/test/java/org/glom/web/server/SelfHostExampleTest.java:
207 Retrieve some data and check it too, as in the regular Glom
208 test_selfhosting_new_from_example.cc test.
209 * src/test/java/org/glom/web/server/SelfHoster.java:
210 createConnection(): Make this public.
212 2012-07-20 Murray Cumming <murrayc@murrayc.com>
214 tests: SelfHoster: createConnection(): Do not warn about expected failures.
216 Let the caller say if the connection is expected to fail, to avoid
217 irrelevant error output.
219 2012-07-20 Murray Cumming <murrayc@murrayc.com>
221 tests: SelfHoster: createAndSelfHostNewEmpty(): Sleep after starting server.
223 * src/test/java/org/glom/web/server/SelfHoster.java:
224 createAndSelfHostNewEmpty(): Sleep initially, to avoid distracting errors
225 due to the inevitable need to retry the connection while the database server
228 2012-07-20 Murray Cumming <murrayc@murray.com>
230 tests: SelfHoster: createConnection(): Set a timeout.
232 * src/test/java/org/glom/web/server/SelfHoster.java:
233 createConnection(): Use setLoginTimeout() because it otherwise seems to take
234 ages to actually return when it fails.
236 2012-07-20 Murray Cumming <murrayc@murrayc.com>
238 tests: SelfHoster: selfHost(): Close the test connection.
240 * src/test/java/org/glom/web/server/SelfHoster.java: selfHost():
241 When we check that the connection works, close the connection. This seems
242 to not be closed automatically otherwise.
244 2012-07-20 Murray Cumming <murrayc@murrayc.com>
246 Use slf4j-simple to see JDBC errors.
248 * pom.xml: Depend on slf4j-simple so we can see errors from JDBC.
250 2012-07-19 Murray Cumming <murrayc@murrayc.com>
252 SelfHoster.discoverFirstFreePort(): Close the socket.
254 * src/test/java/org/glom/web/server/SelfHoster.java:
255 discoverFirstFreePort(): Close the socket. Eclipse Juno warns about this.
257 2012-07-19 Murray Cumming <murrayc@murrayc.com>
259 Avoid another code warning in Eclipse Juno.
261 * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java:
262 Do instanceof checks on the FileUtils.listFiles() result and its
265 2012-07-13 Murray Cumming <murrayc@murrayc.com>
267 Avoid some code warnings in Eclipse Juno
269 * src/main/java/org/glom/web/server/libglom/Document.java:
270 getNodeTextChildAsValue(), setNodeTextChildAsValue(): Handle the invalid type.
271 * src/test/java/org/glom/web/server/SelfHoster.java
272 createTextFile(): Make sure that the FileOutputStream is closed.
274 2012-06-22 Murray Cumming <murrayc@murrayc.com>
276 Added OnlineGlomPropertiesTest.
278 * src/main/java/org/glom/web/server/OnlineGlomProperties.java:
279 Make sure we never return a null string.
280 * src/test/java/org/glom/web/server/OnlineGlomPropertiesTest.java:
281 Added tests of the OnlineGlomProperties API, using our sample file.
283 2012-06-20 Murray Cumming <murrayc@murrayc.com>
285 Make OnlineGlomProperties be a normal class.
287 * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java:
288 Move OnlineGlomProperties into its own file to be a regular class:
289 * src/main/java/org/glom/web/server/OnlineGlomProperties.java:
290 This makes testing simpler.
292 2012-06-15 Murray Cumming <murrayc@murrayc.com>
294 OnlineGlomServiceImpl.init(): Move some code into a new method.
296 * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java:
297 Create addDocument().
299 2012-06-15 Murray Cumming <murrayc@murrayc.com>
301 OnlineGlomServiceImpl.OnlineGlomProperties: Improve getKey().
303 * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java:
304 OnlineGlomProperties.getKey(): Make this more robust by moving the
305 check for *.*.filename to here.
307 2012-06-15 Murray Cumming <murrayc@murrayc.com>
309 OnlineGlomServiceImpl: Improve the OnlineGlomProperties class.
311 * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java
312 init(): Move knowledge of the config file format into the
313 OnlineGlomProperties inner class.
315 2012-06-15 Murray Cumming <murrayc@murrayc.com>
317 SelfHostExampleTest: Make sure we cleanup on failure.
319 * src/test/java/org/glom/web/server/SelfHostExampleTest.java: Move
320 the use of cleanup() to a tearDown() JUnit method.
324 2012-06-12 Murray Cumming <murrayc@murrayc.com>
326 ConfiguredDocument: Add a primary key to portals at least once.
328 * src/main/java/org/glom/web/server/ConfiguredDocument.java
329 updatePortalsExtras): Fix a typo so that we add the primary key
330 column at least once.
331 This is a fix for the previous commit:
332 ConfiguredDocument: Do not add a primary key to portals each time.
334 2012-06-08 Murray Cumming <murrayc@murrayc.com>
336 SelfHoster: Avoid some compiler warnings.
338 * src/test/java/org/glom/web/server/SelfHoster.java
339 executeCommandLineAndWait():
340 executeCommandLineAndWaitUntilSecondCommandReturnsSuccess(): Comment out
341 the now-unused streams for stdout and stderr from the command Processes.
342 These are not used because readln() hangs while waiting for a new line,
343 where there may be no next line. The commented out code is still there
344 to help us figure out how to do this properly.
346 2012-06-08 Murray Cumming <murrayc@murrayc.com>
348 LayoutItemPortalDeepCloneTest: Test something to avoid warnings.
350 * src/test/java/org/glom/web/server/libglom/LayoutItemPortalDeepCloneTest.java:
351 Make this actually test the cloning again, though it is not very useful
352 now that we do not use the part that had a problem with cloning before.
354 2012-06-08 Murray Cumming <murrayc@murrayc.com>
356 SelfHoster: Keep trying pg_ctl after starting postgres.
358 * src/test/java/org/glom/web/server/SelfHoster.java
359 executeCommandLineAndWaitUntilSecondCommandReturnsSuccess():
360 Try pg_ctl repeatedly (for ever) until it succeeds, as we do in
361 regular Glom. This seems mad but it seems to work because the first
362 command would fail if pg_ctl would eventually fail.
364 2012-06-08 Murray Cumming <murrayc@murrayc.com>
366 SelfHoster: Wait until the server is really ready.
368 * src/test/java/org/glom/web/server/SelfHoster.java
369 selfHost(): Attempt the connection after starting the server, retrying
370 a few times if necessary, so that the server is really ready already when
371 we return from this method.
372 The regular Glom code does this too because pg_ctl reports success too soon.
374 2012-06-08 Murray Cumming <murrayc@murrayc.com>
376 ConfiguredDocument: Do not add a primary key to portals each time.
378 * src/main/java/org/glom/web/server/ConfiguredDocument.java
379 updatePortalsExtras(): Only add an extra primary key field if there is
380 none, to avoid adding one each time we retrieve the details layout from the
382 This should fix bug #676986 (Ben Konrath)
384 2012-05-25 Murray Cumming <murrayc@murrayc.com>
386 Document.load(): Support version 7 documents.
388 * src/main/java/org/glom/web/server/libglom/Document.java: Load the
389 database_title attribute if the title attribute is not there.
392 2012-05-24 Ben Konrath <ben@bagu.org>
394 Add configuration for auto-generating mvn:i18n from with Eclipse.
396 * pom.xml: Add PluginExecution configuration for gwt-maven-plugin.
398 2012-05-24 Murray Cumming <murrayc@murrayc.com>
400 Update translations, adding French.
402 * src/main/java/org/glom/web/OnlineGlom.gwt.xml:
403 * src/main/resources/org/glom/web/client/ui/OnlineGlomConstants_fr.properties:
404 Add a French translation, using the translation from Glom.
406 * src/main/resources/org/glom/web/client/ui/OnlineGlomConstants_cs.properties:
407 * src/main/resources/org/glom/web/client/ui/OnlineGlomConstants_es.properties:
408 * src/main/resources/org/glom/web/client/ui/OnlineGlomConstants_sl.properties:
409 Update these based on the translations from Glom.
411 2012-05-24 Murray Cumming <murrayc@murrayc.com>
413 SelfHoster: Add some debug println messages to help when things fail.
415 * src/test/java/org/glom/web/server/SelfHoster.java: Add several
416 System.out.println() lines.
418 2012-05-23 Murray Cumming <murrayc@murrayc.com>
420 Tests: SelfHoster: Check other paths for PostgreSQL command-line tools.
422 * src/test/java/org/glom/web/server/SelfHoster.java:
423 getPathToPostgresExecutable(): Try some common paths (as on Ubuntu, for
424 instance) instead of just /usr/bin (as on Fedora). Check the result when
427 2012-05-23 Murray Cumming <murrayc@murrayc.com>
429 Remove LayoutItemPortal.get/setNavigationTable().
431 * src/main/java/org/glom/web/shared/libglom/layout/LayoutItemPortal.java:
432 Remove get/setNavigationTable(), which is only a cache, because it is not
433 used, and does not need to be used, because that decision should be made on
435 * src/main/java/org/glom/web/server/ConfiguredDocument.java:
436 updatePortalsExtras():
437 * src/main/java/org/glom/web/server/database/RelatedListNavigation.java:
438 getNavigationRecord():
439 * src/test/java/org/glom/web/server/libglom/LayoutItemPortalDeepCloneTest.java:
442 2012-05-21 Murray Cumming <murrayc@murrayc.com>
444 Initial self-hosting for tests.
446 * pom.xml: Change the scope for log4j, to hopefully make it
447 available to the test code which uses it indirectly via jOOQ.
448 * src/main/java/org/glom/web/server/ConfiguredDocument.java: Allow
449 self-hosting, though we only use it for testing.
451 * src/main/java/org/glom/web/server/libglom/Document.java:
452 example rows: Use a map instead of a list for each row of values,
453 so we know what field they are for, instead of relying on the sequence
454 being correct. This is not very efficient, but it does not really need
456 * src/test/java/org/glom/web/server/libglom/DocumentTest.java
457 testReadTableExampleRows(): Adapted.
459 * src/main/java/org/glom/web/shared/DataItem.java: Added getValue()
460 that returns an Object, for generic use. Note that Object seems to be
461 the implicit base even of double.
462 * src/main/java/org/glom/web/shared/libglom/Field.java: Add getSqlType(),
463 for use in CREATE TABLE SQL queries.
464 * src/test/java/org/glom/web/server/SelfHoster.java: Add this class
465 to do self-hosting of PostgreSQL databases via its command-line
466 utilities, based on Glom's C++ code in test_selfhosting_utils.cc and
467 backends/postgres_self.cc. This is incomplete - it needs more
468 warnings about failures and it needs to clean up properly when things
470 * src/test/java/org/glom/web/server/SelfHostExampleTest.java: A simple
471 test of this new class.
473 2012-05-21 Murray Cumming <murrayc@murrayc.com>
475 Document: loading example data: Handle exceptions.
477 * src/main/java/org/glom/web/server/libglom/Document.java:
478 DateFormat.parse() and Double.valueOf() can throw exceptions, though
479 Eclipse did not warn about that.
481 2012-05-20 Murray Cumming <murrayc@murrayc.com>
483 Document: load(), save(): Handle the example rows.
485 * src/main/java/org/glom/web/shared/DataItem.java: Add get/setDate()
487 * src/main/java/org/glom/web/server/libglom/Document.java:
488 load(), save(): Load and save the example rows, though the date, time
489 and image types are not handled properly yet.
490 * src/test/java/org/glom/web/server/libglom/DocumentTest.java:
491 Add testReadTableExampleRows() just to check that something is read.
493 2012-05-20 Murray Cumming <murrayc@murrayc.com>
495 Document: Add save().
497 * src/main/java/org/glom/web/shared/libglom/Translatable.java:
498 Added getTranslationsMap() for use while saving.
499 * src/main/java/org/glom/web/shared/libglom/layout/LayoutItemField.java:
500 Adedd getUseDefaultFormatting() for use while saving.
501 * src/main/java/org/glom/web/server/libglom/Document.java: Added save()
502 and several private methods that it uses.
504 This will be useful while testing via self-hosting.
505 It is not complete, but should be complete enough for testing.
507 2012-05-17 Murray Cumming <murrayc@murrayc.com>
509 OnlineGlomService: Simplify the getList/RelatedViewData() methods.
511 * src/main/java/org/glom/web/client/OnlineGlomService.java
512 * src/main/java/org/glom/web/client/OnlineGlomServiceAsync.java
513 * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java
514 Remove getSortedListViewData() and getSortedRelatedListData(), adding
515 the sort column index and ascending bool to the regular method.
516 Instead, a sort column index of -1 now means no sort.
517 This is less explicit, but it's fairly simple, reduces the amount of
518 code, and makes the OnlineGlomService API slightly smaller.
519 * src/main/java/org/glom/web/client/ui/details/RelatedListTable.java:
520 * src/main/java/org/glom/web/client/ui/list/ListViewTable.java:
522 * src/main/java/org/glom/web/server/ConfiguredDocument.java:
523 getListViewData(), getRelatedListData():
524 * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java:
525 getListViewData(), getRelatedListData():
526 * src/main/java/org/glom/web/server/database/ListDBAccess.java:
528 * src/main/java/org/glom/web/server/database/ListViewDBAccess.java:
530 * src/main/java/org/glom/web/server/database/RelatedListDBAccess.java:
535 2012-05-16 Murray Cumming <murrayc@murrayc.com>
537 Use translations for top-level groups too.
539 * src/main/java/org/glom/web/server/ConfiguredDocument.java:
540 updateTitlesForLocale(): Use the translation for the group
541 as well as for child items.
545 Just recompiled to fix a problem in the released .tar.gz file.
549 2012-05-15 Murray Cumming <murrayc@murrayc.com>
551 Corrections to navigation to related records.
553 * src/main/java/org/glom/web/client/OnlineGlomService.java:
554 * src/main/java/org/glom/web/client/OnlineGlomServiceAsync.java:
555 * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java:
556 getRelatedListData(), getSortedRelatedListData)(), getRelatedListRowCount(),
557 getSuitableRecordToViewDetails(): Take a LayoutItemPortal instead of a
558 relationship name, because the relationship name is not necessarily unique
560 TOOD: This is inefficient, because it passes the whole list of
561 child field items back to the server, but it is more correct, and happens
562 to fix a bug with the primary key being lost after a few navigations.
563 There is probably a chance to make this more efficient anyway in some
566 * src/main/java/org/glom/web/client/activity/DetailsActivity.java
567 * src/main/java/org/glom/web/client/ui/details/RelatedListTable.jav
568 * src/main/java/org/glom/web/server/ConfiguredDocument.java
569 * src/main/java/org/glom/web/server/database/DBAccess.java
570 * src/main/java/org/glom/web/server/database/RelatedListDBAccess.java:
571 * src/main/java/org/glom/web/server/database/RelatedListNavigation.java:
574 2012-05-15 Murray Cumming <murrayc@murrayc.com>
576 Fix the use of translations.
578 * src/main/java/org/glom/web/server/ConfiguredDocument.java:
579 Add updateTitlesForLocale().
580 getValidListViewLayoutGroup(), getDetailsLayoutGroup():
581 Call it to discard unwanted translations and to make getTitle() return
582 the wanted translation wihout the need for the client code to specify a locale.
583 * src/main/java/org/glom/web/shared/libglom/Translatable.java:
584 getTitle(): Fallback to the original title, as libglom does.
586 2012-05-15 Murray Cumming <murrayc@murrayc.com>
588 Document: Correctly report the number of available translation locales.
590 * src/main/java/org/glom/web/server/libglom/Document.java: Fill
591 the available locale IDs list.
592 * src/test/java/org/glom/web/server/libglom/DocumentTest.java:
593 testLocales: Test this.
595 2012-05-15 Murray Cumming <murrayc@murrayc.com>
597 SqlUtils: Use camelCase.
599 * src/main/java/org/glom/web/server/SqlUtils.java: Use camelCase.
600 * src/main/java/org/glom/web/server/database/DetailsDBAccess.java:
601 * src/main/java/org/glom/web/server/database/ListViewDBAccess.java:
602 * src/main/java/org/glom/web/server/database/RelatedListDBAccess.java:
603 * src/main/java/org/glom/web/server/database/RelatedListNavigation.java:
604 * src/main/java/org/glom/web/server/ReportGenerator.java: Adapt.
606 2012-05-15 Murray Cumming <murrayc@murrayc.com>
608 Use jOOQ's tableByName() and fieldByName.
610 * pom.xml: Use jOOQ 2.3.1 to get the new API.
611 * src/main/java/org/glom/web/server/SqlUtils.java:
612 build_sql_select_step_with_where_clause(), .createField(),
613 builder_add_join(): Use Factory.tableByName() and Factory.fieldByName()
614 so we can get correct quoting and escaping. Thanks to Lukas Eder for
615 adding this, and other things, to jOOQ.
617 2012-05-15 Murray Cumming <murrayc@murrayc.com>
619 SqlUtils: Remove the Connection parameters.
621 * src/main/java/org/glom/web/server/SqlUtils.java:
622 build_sql_select_with_key(), build_sql_select_with_where_clause(),
623 createSelect(), build_sql_select_step_with_where_clause(),
624 build_sql_count_select_with_where_clause(),
625 build_sql_select_count_rows(): Remove the Connection parameter because
626 jOOQ does not actually need a connectionwhen it is just used to build
628 https://groups.google.com/forum/#!topic/jooq-user/tIwobFOR2iM
630 * src/main/java/org/glom/web/server/ReportGenerator.java:
632 * src/main/java/org/glom/web/server/database/DetailsDBAccess.java:
634 * src/main/java/org/glom/web/server/database/ListDBAccess.java:
635 Constructor, getListData(), getResultSizeOfSQLQuery():
636 * src/main/java/org/glom/web/server/database/ListViewDBAccess.java:
637 getSelectQuery(), getCountQuery():
638 * src/main/java/org/glom/web/server/database/RelatedListDBAccess.java:
639 getSelectQuery(), getCountQuery():
640 * src/main/java/org/glom/web/server/database/RelatedListNavigation.java:
641 getNavigationRecord(): Adapted.
643 2012-05-14 Murray Cumming <murrayc@murrayc.com>
647 * src/main/java/org/glom/web/server/SqlUtils.java:
648 get_find_where_clause_quick(): Use a comparison of
649 lowercase values, instead of a simple equals. Regular Glom
650 uses the PostgreSQL ILIKE operator but jOOQ does not
651 support that just yet, though it will soon.
653 2012-05-14 Murray Cumming <murrayc@murrayc.com>
655 TableToViewDetails: Use a real serialization ID.
657 * src/main/java/org/glom/web/shared/libglom/layout/TableToViewDetails.java:
658 Though this does not fix the serialization problem.
660 2012-05-12 Murray Cumming <murrayc@murrayc.com>
662 Added LayoutItemPortalDeepCloneTest.
664 2012-05-11 Murray Cumming <murrayc@murrayc.com>
666 Make navigation work again.
668 * src/main/java/org/glom/web/server/libglom/Document.java:
669 Add getLayoutItemFieldShouldHaveNavigation().
670 * src/main/java/org/glom/web/shared/libglom/layout/LayoutItemField.java:
671 Replace get/setAddNavigation() with the partly-existing
672 get/setNavigationTableName(), with an empty string being no navigation,
673 because this is simpler. Use the new
674 Document.getLayoutItemFieldShouldHaveNavigation() method to set this.
676 * src/main/java/org/glom/web/server/ConfiguredDocument.java:
677 Add updateFieldsExtras() and call setNavigationTableName in it.
678 getDetailsLayoutGroup(),
679 * src/main/java/org/glom/web/client/activity/DetailsActivity.java
680 createLayout(): Adapted.
681 * src/main/java/org/glom/web/client/ui/details/DetailsCell.java
682 Constructor: Adapted.
684 * src/main/java/org/glom/web/shared/libglom/layout/LayoutItemPortal.java:
685 Replace get/setAddNavigation() with get/setNavigation(), returning a
686 TableToViewDetails class with both the table name and UsesRelationship,
687 because both are need. The previous code used java-libglom's output
688 variable (strangely, via sharedptr) to return both, but we cannot really
690 * src/main/java/org/glom/web/server/database/RelatedListNavigation.java:
691 getNavigationRecord(): Adapt. However, we cannot actually use the cache
692 here because it somehow gets set to null during deepCopy(). I must test this.
693 * src/test/java/org/glom/web/server/libglom/DocumentTest.java
694 testGetSuitableTableToViewDetails(): Adapted.
696 TODO: Find out why deepClone() is not quite working.
698 2012-05-11 Murray Cumming <murrayc@murrayc.com>
700 DBAccess: Simplify the retrievel of full field details.
702 * src/main/java/org/glom/web/server/database/DBAccess.java
703 getFieldsToShowForSQLQueryAddGroup(). This might be unnecessary anyway,
704 because the Document loading should have done this.
706 2012-05-11 Murray Cumming <murrayc@murrayc.com>
708 Document: Correct loading of doubly-related layout fields.
710 * src/main/java/org/glom/web/server/libglom/Document.java:
711 loadUsesRelationship(): Actually set the related relationship, instead
712 of only setting it if it's not found.
714 2012-05-09 Murray Cumming <murrayc@murrayc.com>
716 Replace all appearances of Colour with color.
718 Because US English is dominant.
720 2012-05-09 Murray Cumming <murrayc@murrayc.com>
722 Use colors in HTML format, solving a warning about an unused function.
724 * src/main/java/org/glom/web/shared/libglom/NumericFormat.java
725 * src/main/java/org/glom/web/shared/libglom/layout/Formatting.java:
726 Add *asHTMLColor() versions of methods.
727 TODO: However, we should create and cache the results on the server.
728 * src/main/java/org/glom/web/client/ui/details/DetailsCell.java
729 * src/main/java/org/glom/web/client/ui/list/ListTable.java
730 * src/main/java/org/glom/web/server/ConfiguredDocument.java
731 * src/test/java/org/glom/web/server/libglom/DocumentTest.java:
732 Use the asHTMLcolor() versions.
734 2012-05-09 Murray Cumming <murrayc@murrayc.com>
736 ListViewTable: Constructor: Take the table name as a parameter.
738 * src/main/java/org/glom/web/client/ui/list/ListViewTable.java:
739 Constructor: Take the tableName, and set the member variable, because
741 * src/main/java/org/glom/web/client/ui/ListViewImpl.java:
742 setCellTable(): Pass the table name.
743 This makes navigation to non-default tables work again. I don't know
744 why it worked before in the master branch.
746 2012-05-07 Murray Cumming <murrayc@murrayc.com>
748 ConfiguredDocument: Restore correct addition of hidden primary key items.
750 * src/main/java/org/glom/web/client/ui/list/ListTable.java
751 (ListTable.createCellTable): Uncomment out the check for the hidden
753 * src/main/java/org/glom/web/server/ConfiguredDocument.java: Only
754 add primary key items for top-level lists and portals, as before,
755 instead of adding them to each group.
756 * src/main/java/org/glom/web/shared/libglom/layout/LayoutGroup.java:
757 Actually implement the extra methods such as setHiddenPrimaryKey() and
758 comment that these are used only for top-level list groups and in portals.
759 This strangeness suggests even more that this should not be squeezed
760 into the LayoutGroup class.
762 2012-05-07 Murray Cumming <murrayc@murrayc.com>
764 Fix Formatting loading.
766 * src/main/java/org/glom/web/shared/libglom/layout/LayoutItemField.java:
767 getFormattingUsed(): Remove the duplicate Formatting member variable
768 in favour of the one from the base class.
769 * src/main/java/org/glom/web/shared/libglom/layout/LayoutItemWithFormatting.java:
770 Initialize a new Formatting instead of using null by default, so we
771 have some defaults, instead of having to initialize one later just to
772 get the same defaults. This also makes loading of formatting from the
773 document work, because that expected a non-null.
775 2012-05-07 Murray Cumming <murrayc@murrayc.com>
777 RelatedListTable: Make sure that the tableName is set.
779 * src/main/java/org/glom/web/client/ui/details/RelatedListTable.java:
780 Constructor: Take the tableName so it is available later. Otherwise,
781 the server assumes that we mean the default table and cannot find the
783 * src/main/java/org/glom/web/client/activity/DetailsActivity.java
784 setData(): Pass the tableName to the RelatedListTable constructor.
786 2012-05-07 Murray Cumming <murrayc@murrayc.com>
790 * src/main/java/org/glom/web/client/activity/DetailsActivity.java:
791 RelatedListNavigationButtonCell.onEnterKeyDown(), setData():
792 * src/main/java/org/glom/web/client/ui/details/RelatedListTable.java:
794 * src/main/java/org/glom/web/client/ui/list/ListTable.java:
796 * src/main/java/org/glom/web/server/database/DBAccess.java:
797 convertResultSetToDTO(), getPortal():
798 * src/main/java/org/glom/web/server/database/ListDBAccess.java
800 * src/main/java/org/glom/web/server/database/RelatedListDBAccess.java:
801 Add checks for null objects and out of range access, with log messages to
802 give hints so we can fix these properly.
804 2012-05-07 Murray Cumming <murrayc@murrayc.com>
806 Portals: some corrections.
808 * src/main/java/org/glom/web/client/activity/DetailsActivity.java
810 * src/main/java/org/glom/web/client/ui/details/RelatedListTable.java:
811 constructor: Use getRelationshipNameUsed() instead of getName(), because
812 that is what is meant.
813 * src/main/java/org/glom/web/shared/libglom/layout/LayoutItemPortal.java:
814 getFromField(): Fix a typo, to get the field name, not the table name.
815 * src/main/java/org/glom/web/server/database/DBAccess.java:
816 getPortal(): Fix a typo that stopped this from working.
818 2012-05-07 Murray Cumming <murrayc@murrayc.com>
820 LayoutItemPortal: Also override getTitleOriginal().
822 * src/main/java/org/glom/web/shared/libglom/layout/LayoutItemPortal.java:
823 This lets the base getTitle() with no parameters work.
824 TODO: Test this properly.
826 2012-05-06 Murray Cumming <murrayc@murrayc.com>
828 LayoutItemPortal: getTitle*(): Use the relationship title.
830 2012-05-06 Murray Cumming <murrayc@murrayc.com>
832 LayoutItemField: Fix loading of custom titles.
834 * src/main/java/org/glom/web/server/libglom/Document.java
835 loadDataLayoutItemField(): The title, if any, instead of the field
836 title, is stored in a title_custom node. Load it from there.
837 * src/main/java/org/glom/web/shared/libglom/CustomTitle.java: Add this
839 * src/main/java/org/glom/web/shared/libglom/layout/LayoutItemField:
840 Add getCustomTitle() and use it, instead of super.getTitle*(), in the
841 getTitle*() overrides.
842 * src/test/java/org/glom/web/server/libglom/LayoutItemFieldTest.java:
845 2012-05-06 Murray Cumming <murrayc@murrayc.com>
847 LayoutItemField: Fall back to field titles, so some are really shown.
849 * src/main/java/org/glom/web/shared/libglom/layout/LayoutItemField.java:
850 Override getTitleOriginal() and getTitle(), as in java-libglom.
851 * src/test/java/org/glom/web/server/libglom/LayoutItemFieldTest.java:
854 2012-05-06 Murray Cumming <murrayc@murrayc.com>
856 Correct use of setExpectedResultSize().
858 * src/main/java/org/glom/web/server/ConfiguredDocument.java
859 getValidListViewLayoutGroup(), getDetailsLayoutGroup():
860 Use setExpectedResultSize only on top-level groups (for instance, the
861 list layout) or on child portals (in details views).
862 Use the correct table name for portals to avoid SQL errors.
863 Update the expected counts when returning cached layouts.
865 2012-05-06 Murray Cumming <murrayc@murrayc.com>
867 Document: Interpret no group column count as 1.
869 * src/main/java/org/glom/web/server/libglom/Document.java: Use a sane
870 default, though we now check for this in the UI code anyway.
872 2012-05-06 Murray Cumming <murrayc@murrayc.com>
876 2012-05-06 Murray Cumming <murrayc@murrayc.com>
878 Translatable: Use Hashmap instead of Treemap because GWT supports it.
880 * src/main/java/org/glom/web/shared/libglom/Translatable.java:
881 The use of Treemap lead to this error from async methods, with no
883 "The response could not be deserialized"
885 2012-05-06 Murray Cumming <murrayc@murrayc.com>
887 OnlineGlom.gwt.xml: Add exludes to fix explicit gwt compilation in Eclipse.
889 * src/main/java/org/glom/web/OnlineGlom.gwt.xml: This is necessary
890 when using the Google -> GWT Compile, or
891 g toolbar button -> GWT Compile Project... feature in Eclipse.
893 2012-05-06 Murray Cumming <murrayc@murrayc.com>
895 ListTable.addColumn(): Protect against a null Formatting.
897 * src/main/java/org/glom/web/client/ui/list/ListTable.java: addColumn():
898 Create a default Formatting if it is null, because that is the simplest
901 2012-05-06 Murray Cumming <murrayc@murrayc.com>
903 ConfiguredDocument.updateLayoutGroup(): Protect against a null dereference.
905 * src/main/java/org/glom/web/server/ConfiguredDocument.java
906 updateLayoutGroup(): Check that the field is not null.
908 2012-05-06 Murray Cumming <murrayc@murrayc.com>
910 ListViewImpl: Protected against a bad cast error.
912 * src/main/java/org/glom/web/client/ui/ListViewImpl.java:
913 onEnterKeyDown(): Do not cast without an instanceof check.
915 2012-05-06 Murray Cumming <murrayc@murrayc.com>
917 ListTable: Protect against an out of range error.
919 * src/main/java/org/glom/web/client/ui/list/ListTable.java
920 createCellTable(): This is unlikely, but can happen while debugging.
922 2012-05-06 Murray Cumming <murrayc@murrayc.com>
924 AsyncMessage onFailure() callbacks: Log the exception message.
926 * src/main/java/org/glom/web/client/activity/DetailsActivity.java
927 * src/main/java/org/glom/web/client/activity/DocumentSelectionActivity.java:
928 * src/main/java/org/glom/web/client/activity/ListActivity.java:
929 * src/main/java/org/glom/web/client/activity/ReportActivity.java:
930 * src/main/java/org/glom/web/client/activity/TableSelectionActivity:
931 * src/main/java/org/glom/web/client/ui/details/RelatedListTable.java:
932 * src/main/java/org/glom/web/client/ui/list/ListViewTable.java:
933 These are useful clues when something is wrong.
935 2012-05-06 Murray Cumming <murrayc@murrayc.com>
937 ConfiguredDocument: Avoid a null dereference.
939 * src/main/java/org/glom/web/server/ConfiguredDocument.java
940 TableLayoutsForLocale.getMapWithAdd(): Make sure that the list and
941 details maps are created.
943 2012-05-06 Murray Cumming <murrayc@murrayc.com>
945 Document: Correct the port number parsing.
947 * src/main/java/org/glom/web/server/libglom/Document.java:
948 This lets us actually connect to the database and show the document.
950 2012-05-05 Murray Cumming <murrayc@murrayc.com>
954 * pom.xml: Use htmlunit mode for gwt:test, because the default demands
955 user-interaction, asking us to load a temporary URL in a browser.s
956 * src/main/java/org/glom/web/OnlineGlom.gwt.xml: Add a servlet node,
957 which is apparently necessary for testing the service. See the comment.
958 * src/test/java/org/glom/web/client/GwtTestOnlineGlomService.java:
959 Show the exception, if any. This is how I saw the 404 in the HTML in
962 2012-05-05 Murray Cumming <murrayc@murrayc.com>
964 DocumentTest: Move the .glom files into the resources directory.
966 * src/test/java/org/glom/web/server/libglom/DocumentTest: And get the
967 URI via getResource().
969 2012-05-05 Murray Cumming <murrayc@murrayc.com>
971 Document: Remove the FieldIdentifies inner class.
973 * src/main/java/org/glom/web/server/libglom/Document.java: We only
974 use the Relationship (though the same function in libglom is maybe
975 used in other ways) and so this removes a compiler warning.
977 2012-05-05 Murray Cumming <murrayc@murrayc.com>
979 Document.load() Remove the error code parameter.
981 * src/main/java/org/glom/web/server/libglom/Document.java: load():
982 Remove the parameter. We do not set it yet and it could never have
983 worked as an output parameter (though maybe it did in java-libglom).
984 We could use an exception if we really want the failure reason.
985 * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java:
987 * src/test/java/org/glom/web/server/libglom/DocumentTest.java:
988 setUp(), testGetSuitableTableToViewDetails(): Adapt.
990 2012-05-05 Murray Cumming <murrayc@murrayc.com>
992 Make some inner classes static.
994 * src/main/java/org/glom/web/server/ConfiguredDocument.java
995 * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java
996 * src/main/java/org/glom/web/server/ReportGenerator.java
997 * src/main/java/org/glom/web/server/libglom/Document.java
998 Make all inner classes static that can be static.
1000 2012-05-05 Murray Cumming <murrayc@murrayc.com>
1002 OnlineGlomServiceImpl: Do not load and check for java-libglom.
1004 * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java
1005 init(): We do not use java-libglom any more.
1007 2012-05-05 Murray Cumming <murrayc@murrayc.com>
1009 Remove mentions of java-libglom.
1011 * README: Remove mention of java-libglom, because it no longer needed.
1012 * utils/build-onlineglom-war.sh:
1013 * utils/check-and-recover-tomcat.py:
1014 * utils/install-onlineglom-war.sh: Remove these as they are no longer
1015 useful. Building is now far easier, with no need for jhbuild.
1017 2012-05-05 Murray Cumming <murrayc@murrayc.com>
1019 Fix the build (mvn package)
1021 * src/main/java/org/glom/web/shared/libglom/layout/LayoutGroup.java
1022 (LayoutGroup): Make the LayoutItemList inner class static and protected.
1023 Otherwise the GWT Java->Javascript compilation fails with just this
1024 error, during mvn package or when attempting to view in a browser,
1025 in the GWT developer mode in Eclipse.
1027 [INFO] --- gwt-maven-plugin:2.4.0:compile (default) @ gwt-glom ---
1028 [INFO] auto discovered modules [org.glom.web.OnlineGlom]
1029 [INFO] Compiling module org.glom.web.OnlineGlom
1030 [INFO] [ERROR] Errors in 'file:/home/murrayc/checkouts/gnome/gwt-glom/src/main/java/org/glom/web/client/OnlineGlomServiceAsync.java'
1031 [INFO] [ERROR] Line 46: Failed to resolve 'org.glom.web.client.OnlineGlomService' via deferred binding
1032 [INFO] Scanning for additional dependencies: file:/home/murrayc/checkouts/gnome/gwt-glom/src/main/java/org/glom/web/client/ui/details/DetailsCell.java
1033 [INFO] [WARN] For the following type(s), generated source was never committed (did you forget to call commit()?)
1034 [INFO] [WARN] org.glom.web.client.OnlineGlomService_Proxy
1035 [INFO] [ERROR] Cannot proceed due to previous errors
1037 It has taken me 2 days to find out what was causing that. After reducing
1038 the code, the compiler eventually showed me the full error message.
1040 2012-05-04 Murray Cumming <murrayc@murrayc.com>
1042 ConfiguredDocument: Cache the cloned and stripped layouts.
1044 * src/main/java/org/glom/web/server/ConfiguredDocument.java:
1045 getValidListViewLayoutGroup(), .getDetailsLayoutGroup(): Store the cloned
1046 layout in a map, so we can retrieve it again without rebuilding it.
1048 2012-05-04 Murray Cumming <murrayc@murrayc.com>
1050 UsesRelationshipImpl: Complete the relationshipEquals() implementation.
1052 2012-05-04 Murray Cumming <murrayc@murrayc.com>
1054 libglom classes: Implement some auto-generated emthods.
1056 2012-05-04 Murray Cumming <murrayc@murrayc.com>
1058 Add GwtTestOnlineGlomService.
1060 * src/test/java/org/glom/web/client/GwtTestOnlineGlomService.java:
1061 However, this (and the other GwtTest*) does not seem to run during
1064 2012-05-04 Murray Cumming <murrayc@murrayc.com>
1066 Remove use of unsupported features from client code.
1068 * src/main/java/org/glom/web/client/StringUtils.java: Add equals().
1069 * src/main/java/org/glom/web/shared/libglom/layout/UsesRelationshipImpl.java:
1070 * src/main/java/org/glom/web/shared/libglom/layout/reportparts/LayoutItemGroupBy.java:
1071 Use our client version of StringUtils instead of the apache commons one.
1073 However, the GWT Javascript compliation still fails.
1075 2012-04-25 Murray Cumming <murrayc@murrayc.com>
1077 Add a Field class and implement some loading of it in Document.
1079 2012-04-25 Murray Cumming <murrayc@murrayc.com>
1081 Initial Document loading implementation, instead of libglom.
1083 * src/test/java/org/glom/web/shared/libglom/: Add Document, Report,
1084 and Translatable classes, and adapt the rest of the code to use them.
1085 However, this is still missing Layout and Field classes and loading.
1087 2012-04-24 Murray Cumming <murrayc@murrayc.com>
1089 Use of jOOQ: Move Field creation into a utility method.
1091 * src/main/java/org/glom/web/server/SqlUtils.java:
1092 This lets us improve it more easily.
1094 2012-04-24 Murray Cumming <murrayc@murrayc.com>
1096 Use of jOOQ: Improve the code to COUNT a sub-select.
1098 * src/main/java/org/glom/web/server/SqlUtils.java:
1099 Move initial query creation into
1100 build_sql_select_step_with_where_clause().
1101 build_sql_select_count_rows(): Use the jOOQ API instead of
1102 concatentating text, because a jOOQ Select*Step is a TableLike,
1103 which is what from() takes.
1105 2012-04-23 Murray Cumming <murrayc@murrayc.com>
1107 Use jOOQ instead of Glom.build_sql*(), to avoid native calls.
1109 * pom.xml: Depend on jooq.
1110 * src/main/java/org/glom/web/server/SqlUtils.java: Reimplement the
1111 methods with jOOQ, based on the C++ implementations in libglom,
1112 with some changes to the logic required by jooQ.
1113 Take a jOOQ Condition rather than a Glom.SqlExpr (GdaSqlExpr) for the
1115 * src/main/java/org/glom/web/client/ui/TableSelectionViewImpl.java:
1116 * src/main/java/org/glom/web/server/ReportGenerator.java:
1117 * src/main/java/org/glom/web/server/SqlUtils.java:
1118 * src/main/java/org/glom/web/server/database/DetailsDBAccess.java:
1119 * src/main/java/org/glom/web/server/database/ListDBAccess.java:
1120 * src/main/java/org/glom/web/server/database/ListViewDBAccess.java:
1121 * src/main/java/org/glom/web/server/database/RelatedListDBAccess.java:
1122 * src/main/java/org/glom/web/server/database/RelatedListNavigation:
1123 Adapt. In particular, the SqlUtils methods now need to take a Connection,
1124 because jOOQ needs that, though it seems unnecessary.
1126 This is not quite finished. Ideally jOOQ would help us to build
1127 table_name.field_name names, quoting and escaping them properly.
1128 See http://stackoverflow.com/questions/10264001/instantiating-a-jooq-field-by-name
1130 2012-04-21 Murray Cumming <murrayc@murrayc.com>
1132 Move use of Glom.build_sql*() into a new SqlUtils class.
1134 * src/main/java/org/glom/web/server/SqlUtils.java: Add static methods
1135 to wrap Glom.build_sql*(). The parameter types are still Glom one,
1136 but this will make it easier to start using something other than
1137 libglom or SqlBuilder.
1139 2012-04-21 Murray Cumming <murrayc@murrayc.com>
1141 Update the project URL.
1143 * pom.xml: Use an OnlineGlom-specific URL for the project URL.
1145 2012-04-21 Murray Cumming <murrayc@murrayc.com>
1147 Main layout: Use a FlowTable instead of absolute positioning.
1149 * src/main/java/org/glom/web/client/OnlineGlom.java: onModuleLoad():
1150 The RootLayoutPanel is a (extends) AbsolutePanel, so each of its
1151 child panels/widgets must have an absolute position. But that is annoying, so
1152 this adds a FlowTable and puts the child panels in there.
1154 2012-04-21 Murray Cumming <murrayc@murrayc.com>
1156 GwtTestOnlineGlom: Comment out unused code.
1158 * src/test/java/org/glom/web/client/GwtTestOnlineGlom.java:
1159 Eclipse has started to say that some code is unused.
1161 2012-04-21 Murray Cumming <murrayc@murrayc.com>
1163 Update to the latest versions of dependencies.
1165 * pom.xml: Update version numbers of dependencies to the latest
1167 * src/main/java/org/glom/web/server/ConfiguredDocument.java:
1168 * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java:
1169 * src/main/java/org/glom/web/server/ReportGenerator.java:
1170 * src/main/java/org/glom/web/server/database/ListViewDBAccess.java:
1171 * src/main/java/org/glom/web/server/database/RelatedListDBAccess.java:
1172 * src/main/java/org/glom/web/server/database/RelatedListNavigation.
1174 * src/test/java/org/glom/web/client/GwtTestOnlineGlom.java:
1175 Modify the imports where necessary.
1177 2012-04-17 Murray Cumming <murrayc@murrayc.com>
1179 Style: Remove overflow:hidden from searchbox
1181 * src/main/webapp/style.css: Because this pushes the Back To Link
1182 label/link on to the next row, which is then hidden due to the
1183 hard-coded (in ems) height.
1185 2012-04-20 Murray Cumming <murrayc@murrayc.com>
1187 Remove some duplicate code.
1189 * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java
1190 getDocumentInfo(): This must have been duplicated during the merge from the
1195 2012-04-19 Murray Cumming <murrayc@murrayc.com>
1197 Reports: Localize the waiting for report message.
1199 * src/main/java/org/glom/web/client/activity/ReportActivity.java
1200 start(): Get the message from the contants.
1201 * src/main/resources/org/glom/web/client/ui/OnlineGlomConstants.properties:
1202 Add the string here.
1203 * src/main/resources/org/glom/web/client/ui/OnlineGlomConstants_cs.properties:
1204 * src/main/resources/org/glom/web/client/ui/OnlineGlomConstants_de.properties:
1205 * src/main/resources/org/glom/web/client/ui/OnlineGlomConstants_es.properties:
1206 * src/main/resources/org/glom/web/client/ui/OnlineGlomConstants_sl.properties:
1207 * src/main/resources/org/glom/web/client/ui/OnlineGlomConstants_zh_CN.properties:
1208 Update these files with the English text for newer strings for now.
1210 2012-04-19 Murray Cumming <murrayc@murrayc.com>
1212 Reports: Show a message while waiting for the report.
1214 * src/main/java/org/glom/web/client/ui/ReportView.java
1215 * src/main/java/org/glom/web/client/ui/ReportViewImpl.java:
1216 Add setWaitingText(), to show a message saying that we are
1217 waiting for the report to be ready.
1218 * src/main/java/org/glom/web/client/activity/ReportActivity.java
1219 start(): Call setWaitingText() before calling the async
1222 2012-04-19 Murray Cumming <murrayc@murrayc.com>
1224 ReportGenerator: Specify date and time formats.
1226 * src/main/java/org/glom/web/server/ReportGenerator.java:
1227 createFieldValueElement(): Use the default (and localized)
1228 short formats, though we still need a way to show 4-digit
1229 years without providing the format for every locale.
1230 * src/main/java/org/glom/web/server/database/DBAccess.java:
1231 convertResultSetToDTO(): Use the short formats here too.
1233 2012-04-18 Murray Cumming <murrayc@murrayc.com>
1235 ReportGenerator: Use the correct numeric formatting.
1237 * src/main/java/org/glom/web/server/ReportGenerator.java
1238 createFieldExpression(), createFieldValueElement(): Take the
1239 whole LayoutItem_Field instead of just the field name, so
1240 we have access to the formatting.
1241 createFieldValueElement(): Use JRTextField.setPattern() to
1242 specify the numeric formatting, with the help of a
1243 regular DecimalFormat.
1245 2012-04-18 Murray Cumming <murrayc@murrayc.com>
1247 ReportGenerator: Avoid showing null for group by titles.
1249 * src/main/java/org/glom/web/server/ReportGenerator.java
1250 generateReport(): Use setBlankWhenNull() on the field title
1251 style too, because this is used for values in group by
1254 2012-04-18 Murray Cumming <murrayc@murrayc.com>
1256 ReportGenerator: Add a colon to titles in vertical groups.
1258 * src/main/java/org/glom/web/server/ReportGenerator.java
1259 addFieldToDetailBandVertical(): Pass true for the withColon
1262 2012-04-18 Murray Cumming <murrayc@murrayc.com>
1264 ReportGenerator: Simplify the code by using Position more.
1266 2012-04-18 Murray Cumming <murrayc@murrayc.com>
1268 Reports: Support vertical groups, roughly.
1270 * src/main/java/org/glom/web/server/ReportGenerator.java:
1271 addToReport(): Rename to addGroupToReport() and, if necessary,
1272 call the new addVerticalGroupToReport() method.
1273 createFieldValueElement(): Let the caller specify the Y position
1276 2012-04-17 Murray Cumming <murrayc@murrayc.com>
1278 Reports: Allow a second report to be shown.
1280 * src/main/java/org/glom/web/client/ui/ReportViewImpl.java:
1281 clear(): Do not remove the HTML widget, which broke the whole layout.
1283 2012-04-17 Murray Cumming <murrayc@murrayc.com>
1285 Locales drop-down: Show that we use English by default.
1287 * src/main/java/org/glom/web/client/activity/TableSelectionActivity.java:
1288 fillView(): When we use English, just because that is the default, when
1289 no locale is specified, show that in the Locales drop-down instead of
1290 just showing the first item.
1292 2012-04-17 Murray Cumming <murrayc@murrayc.com>
1294 Unselect the Report/Locale/Table combo item when appropriate.
1296 * src/main/java/org/glom/web/client/activity/TableSelectionActivity.java:
1297 setPlace(): clear reportName if this is not a ReportPlace.
1298 * src/main/java/org/glom/web/client/ui/TableSelectionViewImpl.java:
1299 setSelectedTableName(), setSelectedLocale(), setSelectedReport():
1300 When the provided name is empty, unselect all items, so that none are
1301 indicated. This uses a for loop because I cannot find a single method
1304 2012-04-17 Murray Cumming <murrayc@murrayc.com>
1306 Report: Give the user a way to get back to the list.
1308 * src/main/java/org/glom/web/client/activity/TableSelectionActivity.java:
1309 start(), setPlace(): Show the Back To List link on reports, and also
1310 interpret selecting the empty report item as back to list.
1312 2012-04-13 Murray Cumming <murrayc@murrayc.com>
1314 Really show the selected Report name.
1316 * src/main/java/org/glom/web/client/activity/TableSelectionActivity:
1317 setPlace(): Store the reportName here, if it is that kind of Place.
1318 fillView(): Set the selected Report after filling the list of reports.
1319 * src/main/java/org/glom/web/client/ui/TableSelectionViewImpl.java:
1320 setSelectedLocale(), setSelectedReport(): Avoid possible uses of
1321 null Strings, though we need some way to unselect all ListBox items
1324 2012-04-13 Murray Cumming <murrayc@murrayc.com>
1326 ReportGenerator: Try to avoid some problems.
1328 * src/main/java/org/glom/web/server/ReportGenerator.java
1329 addField(): Try to avoid duplicates, and avoid using a null
1332 2012-04-13 Murray Cumming <murrayc@murrayc.com>
1334 Reports: Use quickFind.
1336 * src/main/java/org/glom/web/client/OnlineGlomService.java;
1337 * src/main/java/org/glom/web/client/OnlineGlomServiceAsync.java:
1338 * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java:
1339 getReportHTML(): Add a quickFind parameter.
1340 * src/main/java/org/glom/web/client/activity/ReportActivity.java
1341 start(): Pass the quickFind parameter.
1342 * src/main/java/org/glom/web/server/ReportGenerator.java
1343 generateReport(): Take a quickFind parameter.
1345 2012-04-13 Murray Cumming <murrayc@murrayc.com>
1347 ReportPlace: Actually use the report name.
1349 * src/main/java/org/glom/web/client/place/ReportPlace.java
1350 getPlace(): Do not assign the report name to the quickfind.
1352 2012-04-13 Murray Cumming <murrayc@murrayc.com>
1354 Show java.library.path when complaining.
1356 * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java
1357 init(): When telling us to check java.library.path, show the
1360 2012-03-06 Murray Cumming <murrayc@murrayc.com>
1362 ReportGenerator: Do not show nulls.
1364 2012-03-06 Murray Cumming <murrayc@murrayc.com>
1366 ReportGenerator: Make the title font larger.
1368 2012-03-06 Murray Cumming <murrayc@murrayc.com>
1370 ReportGenerator: Put field titles inside groups, if there are groups.
1372 2012-03-06 Murray Cumming <murrayc@murrayc.com>
1374 ReportGenerator: Take the Report itself instead of the name and group.
1376 * src/main/java/org/glom/web/server/ConfiguredDocument.java
1377 Remove getReportLayoutGroup().
1378 * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java
1379 getReportHTML(): Pass the report instead
1380 of its name and layout group.
1381 * src/main/java/org/glom/web/server/ReportGenerator.java
1382 generateReport(): Use the report object to use the title
1383 instead of the name.
1385 2012-03-06 Murray Cumming <murrayc@murrayc.com>
1387 ReportGenerator: Remove designBand parameters.
1389 * src/main/java/org/glom/web/server/ReportGenerator.java:
1390 Make designBand a class member instead of passing it to all
1393 2012-03-06 Murray Cumming <murrayc@murrayc.com>
1395 ReportGenerator: Add lines, a bit like in the desktop version.
1397 * src/main/java/org/glom/web/server/ReportGenerator.java
1398 addToReport(): Use JRDesignLine.
1400 2012-03-06 Murray Cumming <murrayc@murrayc.com>
1402 ReportGenerator: Correct the title positions and use some bold style.
1404 * src/main/java/org/glom/web/server/ReportGenerator.java:
1405 Break the code up into reusable functions, correct the placement of
1406 titles, and use normal/bold styles as in the reports in the desktop
1409 2012-03-06 Murray Cumming <murrayc@murrayc.com>
1411 ReportGenerator: Add a header band to show the field titles.
1413 * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java
1414 getReportHTML(): Pass the localeId to the ReportGenerator
1416 * src/main/java/org/glom/web/server/ReportGenerator.java
1417 constructor: Take the localeID so we can get translated field
1419 generateReport(), addToReport(), addFieldToBand(): Add field
1420 titles in a column header band.
1422 2012-03-05 Murray Cumming <murrayc@murrayc.com>
1424 Reports drop-down list: Some improvement.
1426 * src/main/java/org/glom/web/client/ui/TableSelectionView.java
1427 * src/main/java/org/glom/web/client/ui/TableSelectionViewImpl.java:
1428 Adedd setSelectedReport(),
1429 setReportList(): Add a blank line so that the user can select the
1431 * src/main/java/org/glom/web/client/activity/ReportActivity.java
1432 start(): Show the current report by calling setSelectedReport().
1433 This does not seem to work yet.
1435 2012-03-05 Murray Cumming <murrayc@murrayc.com>
1437 DetailsActivity, ListActivity: Move some variables into a base class.
1439 * src/main/java/org/glom/web/client/activity/DetailsActivity.java:
1440 * src/main/java/org/glom/web/client/activity/HasTableActivity.java:
1441 * src/main/java/org/glom/web/client/activity/ListActivity.java: Move
1442 the clientFactory, documentID, tableName and authenticationPopup into
1443 a base class, to avoid duplication.
1445 2012-03-05 Murray Cumming <murrayc@murrayc.com>
1447 Translate the Reports label.
1449 * src/main/java/org/glom/web/client/ui/TableSelectionViewImpl.java
1450 Get the "Reports" label string from the constants.
1451 * src/main/resources/org/glom/web/client/ui/OnlineGlomConstants.pro
1452 perties: Add Reports to the constants.
1454 2012-03-05 Murray Cumming <murrayc@murrayc.com>
1456 Reports: Implement grouping.
1458 * src/main/java/org/glom/web/server/ReportGenerator.java:
1459 Handle LayoutItem_GroupBy items and try to do the right thing
1460 with JRDesignGroup. It seems to work.
1462 2012-03-04 Murray Cumming <murrayc@murrayc.com>
1464 Actually show some data with JasperReports.
1466 * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java:
1467 getReportHTML(): Move most code into a ReportGenerator class.
1468 * src/main/java/org/glom/web/server/ReportGenerator.java:
1469 Recurse into sub-groups, adding fields to the JasperDesign's details
1470 band. Note that we must set an arbitrary width and height, or it just
1471 will not show any data.
1473 2012-03-04 Murray Cumming <murrayc@murrayc.com>
1475 Reports Chooser: Show the titles, not the names.
1477 * src/main/java/org/glom/web/client/ui/TableSelectionViewImpl.java
1478 (TableSelectionViewImpl.setReportList): Show the titles in the UI,
1479 and the names as the values.
1480 * src/main/java/org/glom/web/server/ConfiguredDocument.java
1481 (ConfiguredDocument.getReportLayoutGroup): Do not return a default
1482 group now that we provide the report name, so it should always
1485 2012-02-15 Murray Cumming <murrayc@murrayc.com>
1487 Depend on jasperreports.
1489 * pom.xml: Add the dependency. My plan is to use this on the
1492 2012-01-31 Murray Cumming <murrayc@murrayc.com>
1494 Implement navigation to report places.
1496 * src/main/java/org/glom/web/client/activity/ReportActivity.java
1497 start(): Do not bother to handle all events here.
1498 * src/main/java/org/glom/web/client/ui/TableSelectionView.java
1499 * src/main/java/org/glom/web/client/ui/TableSelectionViewImpl.java:
1500 Added getSelectedReport().
1501 * src/main/java/org/glom/web/client/activity/TableSelectionActivity
1502 .java: start(): When handling a change to the reports chooser,
1503 call getSelectedReport() and goTo() its ReportPlace.
1504 * src/main/java/org/glom/web/client/ui/ReportView.java
1505 * src/main/java/org/glom/web/client/ui/ReportViewImpl.java:
1506 Added setReportHTML() which puts the html in a gwt HTML widget.
1507 * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java
1508 getReportHTML(): Return "TODO" just to show that this works.
1510 2012-01-31 Murray Cumming <murrayc@murrayc.com>
1512 Make ReportPlace usable.
1514 * src/main/java/org/glom/web/client/mvp/AppPlaceHistoryMapper.java:
1515 Mention ReportPlace.
1516 * src/main/java/org/glom/web/client/place/ReportPlace.java:
1517 Correct the @prefix annotation.
1519 2012-01-31 Murray Cumming <murrayc@murrayc.com>
1521 OnlineGlomService: Return report HTML rather than the LayoutGroup.
1523 * src/main/java/org/glom/web/client/OnlineGlomService.java:
1524 * src/main/java/org/glom/web/client/OnlineGlomServiceAsync.java:
1525 * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java:
1526 Change getReportLayout() to getReportHMTL() because we will not need to
1527 parse or render the report layout on the client side.
1528 * src/main/java/org/glom/web/server/ConfiguredDocument.java:
1529 getReportLayout(): Return the libglom LayoutGroup type because we will
1530 not need to convert to a shared type, because this will not be used on
1532 * src/main/java/org/glom/web/client/activity/ReportActivity.java:
1535 Note that there is still no implementation for this.
1538 2012-01-27 Murray Cumming <murrayc@murrayc.com>
1540 Add a (empty) Report Place, View, and Activity.
1542 * src/main/java/org/glom/web/client/place/HasSelectableTablePlace.java:
1544 * src/main/java/org/glom/web/client/place/HasTablePlace.java
1545 * src/main/java/org/glom/web/client/place/ListPlace.java: Move some of
1546 this into a superclass:
1547 * src/main/java/org/glom/web/client/place/HasRecordsPlace.java
1548 and also use it as the base of this new ReportPlace:
1549 * src/main/java/org/glom/web/client/place/ReportPlace.java
1551 * src/main/java/org/glom/web/client/ui/ReportView.java
1552 * src/main/java/org/glom/web/client/ui/ReportViewImpl.java
1553 * src/main/java/org/glom/web/client/activity/ReportActivity.java:
1554 Add these, containing mostly boiler-plate for now.
1556 * src/main/java/org/glom/web/client/OnlineGlomService.java
1557 * src/main/java/org/glom/web/client/OnlineGlomServiceAsync.java
1558 * src/main/java/org/glom/web/server/ConfiguredDocument.java
1559 * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java:
1560 Add API to get the LayoutGroup for the report.
1562 2012-01-23 Murray Cumming <murrayc@murrayc.com>
1564 Add and fill a Reports drop-down list box.
1566 * src/main/java/org/glom/web/server/ConfiguredDocument.java:
1568 * src/main/java/org/glom/web/client/OnlineGlomService.java:
1569 * src/main/java/org/glom/web/client/OnlineGlomServiceAsync.java:
1570 * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java:
1571 Added getReports(document, table, localeID), calling
1572 ConfiguredDocument.getReports().
1573 * src/main/java/org/glom/web/client/ui/TableSelectionView.java:
1574 * src/main/java/org/glom/web/client/ui/TableSelectionViewImpl.java:
1575 Added setReportsList() and a list widget.
1576 * src/main/java/org/glom/web/client/activity/TableSelectionActivity
1577 .java (TableSelectionActivity.fillView(): Fill the view's reports list.
1582 2012-04-12 Murray Cumming <murrayc@murrayc.com>
1584 Translations: Add Esperanto.
1586 * src/main/java/org/glom/web/OnlineGlom.gwt.xml
1587 * src/main/resources/org/glom/web/client/ui/OnlineGlomConstants_eo.
1588 properties: Add this translation because someone took the time to make it.
1590 2012-03-15 Murray Cumming <murrayc@murrayc.com>
1592 Adapt to the java-libglom 1.21.7 API.
1594 * src/main/java/org/glom/web/server/ReportGenerator.java:
1595 addToReport(): get_group_secondary_fields() is now
1596 get_secondary_fields().
1599 2012-03-15 Murray Cumming <murrayc@murrayc.com>
1601 Use the latest java-libglom version.
1603 * pom.xml: Use java-libglom 1.21.7.
1605 2012-03-03 Ben Konrath <ben@bagu.org>
1607 Display date and time in details view.
1609 https://bugzilla.gnome.org/show_bug.cgi?id=671257
1611 * src/main/java/org/glom/web/client/ui/details/DetailsCell.java:
1613 2012-03-05 Murray Cumming <murrayc@murrayc.com>
1615 Require the latest java-libglom.
1617 * pom.xml: java-libglom 1.21.5 has LayoutItem_GroupBy.
1619 2012-03-04 Murray Cumming <murrayc@murrayc.com>
1621 ListViewDbAccess.getSelectQuery(): Avoid using empty quickfind strings.
1623 * src/main/java/org/glom/web/server/database/ListViewDBAccess.java
1624 ListViewDBAccess.getSelectQuery(): Do not create a where clause for
1625 an empty quickfind string. I also corrected libglom to create only
1626 empty where clauses for empty quickfind strings, but this avoids the
1629 2012-02-24 Ben Konrath <ben@bagu.org>
1631 Improve the tabs in the Notebook widget.
1635 2012-01-30 Murray Cumming <murrayc@murrayc.com>
1637 Translations: Try to translate the strings.
1639 * src/main/resources/org/glom/web/client/ui/OnlineGlomConstants_cs.properties:
1640 * src/main/resources/org/glom/web/client/ui/OnlineGlomConstants_de.properties:
1641 * src/main/resources/org/glom/web/client/ui/OnlineGlomConstants_es.properties:
1642 * src/main/resources/org/glom/web/client/ui/OnlineGlomConstants_sl.properties:
1643 * src/main/resources/org/glom/web/client/ui/OnlineGlomConstants_zh_CN.properties:
1644 Take the Open translation from GTK+'s .po files.
1645 Take the Details translation from Glom's po files.
1646 I have added the other strings to Glom so we can get translations that way:
1647 http://git.gnome.org/browse/glom/commit/?id=c3cefe607428a84bdf8de1b04e8bef6f70b04564
1649 2012-01-27 Murray Cumming <murrayc@murrayc.com>
1651 TableSelectionViewImpl: Put the search label and entry in a div.
1653 * src/main/java/org/glom/web/client/ui/TableSelectionViewImpl.java:
1654 Put the search widgets in a FlowTable so that the CSS can be used to
1655 style them while keeping them together.
1656 * src/main/webapp/style.css: Mention the new div.
1658 2012-01-27 Murray Cumming <murrayc@murrayc.com>
1660 Translate more strings in more locales.
1662 * src/main/resources/org/glom/web/client/ui/OnlineGlomConstants.properties:
1663 * src/main/java/org/glom/web/client/ui/details/DetailsCell.java:
1664 * src/main/java/org/glom/web/client/ui/details/RelatedListTable.java:
1665 * src/main/java/org/glom/web/client/ui/list/ListViewTable.java:
1666 Translate the "Details" and "Open" string too.
1668 * src/main/java/org/glom/web/OnlineGlom.gwt.xml:
1669 * src/main/resources/org/glom/web/client/ui/OnlineGlomConstants.properties:
1670 * src/main/resources/org/glom/web/client/ui/OnlineGlomConstants_cs.properties:
1671 * src/main/resources/org/glom/web/client/ui/OnlineGlomConstants_es.properties:
1672 * src/main/resources/org/glom/web/client/ui/OnlineGlomConstants_sl.properties:
1673 * src/main/resources/org/glom/web/client/ui/OnlineGlomConstants_zh_CN.properties:
1674 Add these new locales as placeholders though they currently contain English.
1676 2012-01-27 Murray Cumming <murrayc@murrayc.com>
1678 OnlineGlomServiceImpl: Avoid (unlikely) null object dereferences.
1680 * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java: get*():
1681 Check the ConfiguredDocument* for null before using it.
1683 2012-01-26 Murray Cumming <murrayc@murrayc.com>
1685 Tell Eclipse about the generated java files.
1687 * .classpath: This lets it find OnlineGlomConstants.java.
1688 It would be nice if Eclipse just used the maven build files.
1690 2012-01-26 Murray Cumming <murrayc@murrayc.com>
1692 Prevent a crash when no locale is specified in the URL.
1694 * src/main/java/org/glom/web/client/Utils.java: getCurrentLocaleID():
1695 Avoid returning a null string, obtained from
1696 Window.Location.getParameter(). This caused a crash when it was
1697 later passed to libglom's API.
1698 * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java:
1699 init(), getDocumentInfo(), getListViewLayout(), getDocuments(),
1700 getDetailsLayoutAndData(): Use StringUtils.defaultString() to
1701 guard against future null strings.
1703 2012-01-26 Murray Cumming <murrayc@murrayc.com>
1705 Use the ?locale= query param instead of the &lang= token param.
1707 * src/main/java/org/glom/web/client/place/ListPlace.java
1708 * src/main/java/org/glom/web/client/place/DetailsPlace.java
1709 * src/main/java/org/glom/web/client/place/HasSelectableTablePlace.java
1710 Remove the lang token key and value.
1712 * src/main/java/org/glom/web/client/ui/TableSelectionView.java
1713 * src/main/java/org/glom/web/client/ui/TableSelectionViewImpl.java:
1714 When the user selects a different locale from the chooser, use
1715 Window.Location.assign() to change the URL, which then causes a reload.
1717 * src/main/java/org/glom/web/client/Utils.java: Added getCurrentLocaleID().
1718 * src/main/java/org/glom/web/client/activity/DetailsActivity.java
1719 * src/main/java/org/glom/web/client/activity/DocumentSelectionActivity.java
1720 * src/main/java/org/glom/web/client/activity/ListActivity.java
1721 * src/main/java/org/glom/web/client/activity/TableSelectionActivity
1722 * src/main/java/org/glom/web/client/ui/DocumentSelectionView.java
1723 * src/main/java/org/glom/web/client/ui/DocumentSelectionViewImpl.java:
1724 * src/main/java/org/glom/web/client/ui/ListView.java:
1725 * src/main/java/org/glom/web/client/ui/ListViewImpl.java:
1727 Remove localeID member variables and method/constructor parameters, instead
1728 using Utils.getCurrentLocaleID() when we need a localID to pass to
1731 2012-01-26 Murray Cumming <murrayc@murrayc.com>
1733 Internationalize the UI strings.
1735 * pom.xml: gwt-maven-plugin: Add the i18n goal and specify a
1736 <i18nConstantsBundle>, removing the unused <i18nMessagesBundle>.
1737 * src/main/resources/org/glom/web/client/Messages.properties: Remove this
1738 because it is unused. Messages are apparently strings that can have
1739 parameters, but we do not need that yet, so Contants will be enough for now.
1740 * src/main/java/org/glom/web/OnlineGlom.gwt.xml: Add extend-property lines
1741 to say that we support the en and de locales.
1742 * src/main/resources/org/glom/web/client/ui/OnlineGlomConstants.properties:
1743 The original English strings.
1744 * src/main/resources/org/glom/web/client/ui/OnlineGlomConstants_de.properties:
1745 Some German translations of the English strings.
1746 The i18n goal then uses the .properties file to generate an
1747 OnlineGlomConstants.java file in target/ and somehow GWT.create() magically
1748 returns an implementation that returns the translated strings.
1749 The documentation suggests putting these in src/java/*/client/, but it seems
1750 best to put it in src/resources/*/client/.
1751 * src/main/java/org/glom/web/client/ui/TableSelectionViewImpl.java:
1752 Instantiate OnlineGlomConstants via GWT.create() and use it to get the strings
1753 instead of hard-coding them.
1754 Note that we cannot import OnlineGlomConstants because it does not exist yet,
1755 but that does not seem to stop the build, though it confuses Eclipse.
1757 You can see the translated string by adding ?locale=de to the URL, like so:
1758 http://127.0.0.1:8888/OnlineGlom.html?gwt.codesvr=127.0.0.1:9997?locale=de#list:document=film_manager
1760 2012-01-24 Murray Cumming <murrayc@murrayc.com>
1762 Improve null/empty String checks.
1764 * pom.xml: Add a dependency on commons-lang, to use
1765 org.apache.commons.lang.StringUtils.
1766 * src/main/java/org/glom/web/server/ConfiguredDocument.java
1767 * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java
1768 * src/main/java/org/glom/web/server/database/RelatedListDBAccess.java
1769 * src/main/java/org/glom/web/server/database/RelatedListNavigation.java:
1770 Use StringUtils.isEmpty().
1772 * src/main/java/org/glom/web/client/StringUtils.java: Add a tiny
1773 StringUtils class with a static isEmpty() function because we
1774 cannot use org.apache.commons.lang.StringUtils in client-side
1775 GWT code because it (apparently) cannot be compiled to javascript.
1776 * src/main/java/org/glom/web/client/activity/DetailsActivity.java
1777 * src/main/java/org/glom/web/client/activity/ListActivity.java
1778 * src/main/java/org/glom/web/client/activity/TableSelectionActivity.java
1779 * src/main/java/org/glom/web/client/place/DetailsPlace.java
1780 * src/main/java/org/glom/web/client/place/HasSelectableTablePlace.java
1781 * src/main/java/org/glom/web/client/place/ListPlace.java
1782 * src/main/java/org/glom/web/client/ui/cell/NumericCell.java
1783 * src/main/java/org/glom/web/client/ui/cell/TextCell.java
1784 * src/main/java/org/glom/web/client/ui/details/DetailsCell.java
1785 * src/main/java/org/glom/web/client/ui/details/Group.java
1786 * src/main/java/org/glom/web/client/ui/details/Notebook.java: Use
1787 our StringUtils.isEmpty() function.
1789 2012-01-24 Murray Cumming <murrayc@murrayc.com>
1791 Update to the latest java-libglom API.
1793 * pom.xml: Require java-libglom 1.21.4.
1794 * src/main/java/org/glom/web/server/ConfiguredDocument.java
1795 getDocumentInfo(), getListViewLayoutGroup():
1796 * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java
1798 * src/main/java/org/glom/web/server/database/DBAccess.java
1799 getFieldsToShowForSQLQueryAddGroup(),
1800 getPrimaryKeyLayoutItemField(): Replace get_database_title()
1801 with either get_database_title_original() or
1802 get_database_title(localeID).
1804 2012-01-24 Murray Cumming <murrayc@murrayc.com>
1806 ConfiguredDocument: Avoid a null pointer exception.
1808 * src/main/java/org/glom/web/server/ConfiguredDocument.java
1809 Initialize localeID to "" to avoid returning a null String which
1810 causes a crash in java-libglom's swing-generated code.
1812 2012-01-23 Murray Cumming <murrayc@murrayc.com>
1814 Some simple renaming.
1816 * src/main/java/org/glom/web/client/ui/TableSelectionViewImpl.java
1817 * src/main/webapp/style.css: Rename, tableChooser to tablesChooser. Likewise
1818 for localeChooser. This seems more appropriate and is less ambiguous
1819 particularly in the .css file.
1821 2012-01-23 Murray Cumming <murrayc@murrayc.com>
1823 ConfiguredDocument: Rename the localedID private member variable.
1825 2012-01-23 Murray Cumming <murrayc@murrayc.com>
1827 Adapt to the latest java-libglom API from git master.
1829 * src/main/java/org/glom/web/server/database/ListDBAccess.java:
1830 libglom now uses only Vector instead of List, which uses add() instead of
1833 2012-01-22 Murray Cumming <murrayc@murrayc.com>
1835 ConfiguredDocument: Rename the localedID private member variable.
1837 2012-01-20 Murray Cumming <murrayc@murrayc.com>
1839 Build a source tarball with mvn assembly:single
1841 * assembly.xml: Add this file.
1842 * pom.xml: Use the maven-assembly-plugin and tell it to use
1843 our assembly.xml file.
1845 2012-01-19 Murray Cumming <murrayc@murrayc.com>
1847 OnlineGlomServiceImpl: Get .glom files recursively.
1849 * pom.xml: Depend on commons-io from org.apache.commons.
1850 * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java
1851 init(): Use org.apache.commons.io.FileUtils.listFiles() to get the
1852 files recursively, and with the easier filter for the extension.
1853 Use org.apache.commons.io.FilenameUtils.removeExtension() to
1854 simplify that code too.
1856 2012-01-19 Murray Cumming <murrayc@murrayc.com>
1858 README: Mention that you must install java-libglom packages separately.
1860 But then it works, because java-libglom is now in the central maven
1863 2012-01-18 Murray Cumming <murrayc@murrayc.com>
1865 locales drop-down: Show the correct selected locale when the URL changes.
1867 * src/main/java/org/glom/web/client/activity/TableSelectionActivity
1868 .java: setPlace(): Move some code into fillView().
1870 2012-01-18 Murray Cumming <murrayc@murrayc.com>
1872 locales drop-down: Do not lose the primary key.
1874 * src/main/java/org/glom/web/client/activity/DetailsActivity.java
1875 start(): onLocaleChange(): Pass the current primary key value,
1876 instead of an empty value.
1878 2012-01-18 Murray Cumming <murrayc@murrayc.com>
1880 locales drop-down: Do not lose the drop-down selection.
1882 * src/main/java/org/glom/web/client/activity/TableSelectionActivity
1883 .java (TableSelectionActivity.fillView): Set the selected locale
1884 after changing the drop-down items (though we do not really need
1885 to change them just because the locale changes.)
1887 2012-01-18 Murray Cumming <murrayc@murrayc.com>
1889 locales drop-down: Change the tables list when this changes.
1891 * src/main/java/org/glom/web/client/activity/TableSelectionActivity
1892 .java: TableSelectionActivity.start(): Move the async table titles
1893 retrieval into a private fillView() method and also call this when
1894 the chosen locale changes.
1895 Note that the document title is not actually translatable yet, but
1896 that is a problem that I should fix soon in libglom.
1898 2012-01-18 Murray Cumming <murrayc@murrayc.com>
1900 Improve the placement of the locales drop-down.
1902 * src/main/java/org/glom/web/client/ui/TableSelectionViewImpl.java
1903 Put the title and locales drop-down in a div (gwt.FlowTable).
1904 * src/main/webapp/style.css: Add magic css properties to make this work.
1905 Also remove the left margin from the title so that it lines up with the
1908 2012-01-18 Murray Cumming <murrayc@murrayc.com>
1910 locales selector: Show human-readable locale titles.
1912 * src/main/java/org/glom/web/server/ConfiguredDocument.java
1913 getDocumentInfo(): Use java.util.Locale to show a real title of
1914 each locale, in the locale's own language.
1916 2012-01-17 Murray Cumming <murrayc@murrayc.com>
1918 Add a language/locale selector drop-down.
1920 * src/main/java/org/glom/web/shared/DocumentInfo.java:
1921 Add getLocaleIDs(), setLocaleIDs(), getLocaleTitles(), setLocaleTitles().
1922 * /src/main/java/org/glom/web/server/ConfiguredDocument.java:
1923 getDocumentInfo(): Store the available Locales in the DocumentInfo.
1924 * src/main/java/org/glom/web/client/ui/TableSelectionView.java:
1925 * src/main/java/org/glom/web/client/ui/TableSelectionViewImpl.java:
1926 Add a ListBox to show the available locales. Add getLocaleSelector(),
1927 setLocaleList(), getSelectedLocale(), setSelectedLocale().
1928 * src/main/java/org/glom/web/client/event/LocaleChangeEvent.java
1929 * src/main/java/org/glom/web/client/event/LocaleChangeEventHandler.
1930 java: Add these classes.
1931 * src/main/java/org/glom/web/client/activity/TableSelectionActivity.java:
1932 start(): Fill the locales ListBox. Handle its change event, firing a
1934 setPlace(): Show the selected locale as specified by the URL token.
1935 * src/main/java/org/glom/web/client/activity/DetailsActivity.java:
1936 * src/main/java/org/glom/web/client/activity/ListActivity.java:
1937 Handle LocaleChangeEvent, going to a new *Place with that locale.
1939 The placement of the ListBox is not pretty, and it currently uses the ID
1940 as a title, instead of "English", "Deutsch", "Espanola", etc, but it
1944 2012-01-17 Murray Cumming <murrayc@murrayc.com>
1946 Search box: Show the search text from the URL token.
1948 * src/main/java/org/glom/web/client/ui/TableSelectionView.java:
1949 * src/main/java/org/glom/web/client/ui/TableSelectionViewImpl.java:
1950 Add setQuickFindText().
1951 * src/main/java/org/glom/web/client/activity/TableSelectionActivity
1952 .java: setPlace(): Store the queryText if the place is a ListPlace,
1953 and call TableSelectionView.setQuickFindText().
1955 2012-01-17 Murray Cumming <murrayc@murrayc.com>
1957 Allow use of translations via, for instance, &lang=de in the URL.
1959 * pom.xml: Use the unstable java-libglom 1.21 version.
1961 * src/main/java/org/glom/web/client/OnlineGlomService.java:
1962 * src/main/java/org/glom/web/client/OnlineGlomServiceAsync.java
1963 * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java:
1964 init(): Instead of calling TranslatableItem.set_current_locale()
1965 (now removed), call ConfiguredDocument.setDefaultLocaleID().
1966 However, this is only for default locales, which are not needed to
1967 change the locale in the URL.
1968 getDocumentInfo(), getListViewLayout(), getSortedListViewData(),
1969 getDetailsData(), getDetailsLayoutAndData(), getRelatedListData(),
1970 getSortedRelatedListData(): Add a localeID parameter, so we can get the
1971 layout for a particular locale.
1972 * src/main/java/org/glom/web/server/ConfiguredDocument.java:
1973 Add get/setDefaultLocaleID().
1974 getDocumentInfo(), getListViewData(), getRelatedListData(),
1975 getDetailsLayoutGroup(), getListViewLayoutGroup(),
1976 createLayoutItemPortalDTO(), convertToGWTGlomLayoutItemField(): Add a
1977 localeID parameter, so we can get the layout for a particular locale.
1979 * src/main/java/org/glom/web/client/place/HasSelectableTablePlace.java:
1980 * src/main/java/org/glom/web/client/place/DetailsPlace.java:
1981 * src/main/java/org/glom/web/client/place/ListPlace.java:
1982 Parse and construct a lang parameter too.
1984 * src/main/java/org/glom/web/client/activity/DocumentSelectionActivity.java:
1985 start(): Pass the defaultLocaleID to addDocumentLink(). It is then
1986 passed to subsequent methods and constructors.
1987 * src/main/java/org/glom/web/client/activity/DetailsActivity.java:
1988 * src/main/java/org/glom/web/client/activity/ListActivity.java:
1989 Store the localeID from the *Place and pass it to other constructors
1990 and methods, such as OnlineGlomServiceAsync.getDetailsLayoutAndData().
1992 * src/main/java/org/glom/web/client/ui/DocumentSelectionView.java:
1993 * src/main/java/org/glom/web/client/ui/DocumentSelectionViewImpl.java:
1994 * src/main/java/org/glom/web/client/ui/TableSelectionView.java
1995 * src/main/java/org/glom/web/client/ui/TableSelectionViewImpl.java
1996 * src/main/java/org/glom/web/client/ui/ListView.java:
1997 * src/main/java/org/glom/web/client/ui/ListViewImpl.java:
1998 Take localeID parameters and pass them to subsequent constructors and
1999 methods, so that the layout is always retrieved for that locale.
2001 This is rather repetitive.
2003 Note that "" means the original (default) locale of the Glom document,
2004 which is usually English.
2006 2012-01-17 Murray Cumming <murrayc@murrayc.com>
2008 Documents: Remove final keyword to fix startup configuration.
2010 * src/main/java/org/glom/web/shared/Documents.java: Remove the
2011 final keywords on the private member variables because that breaks
2012 the startup, apparently (there are warnings) because it stops them
2013 from being serialized. I added these in the previous commit.
2015 2012-01-13 Murray Cumming <murrayc@murrayc.com>
2017 Documents: Add some final keywords.
2019 * src/main/java/org/glom/web/shared/Documents.java: Eclipse suggested
2022 2012-01-13 Murray Cumming <murrayc@murrayc.com>
2024 OnlineGlomServiceImpl: Add to overview comments.
2026 * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java:
2027 Note that this is where all the document are loaded. They are not
2028 loaded freshly for each page.
2030 2012-01-12 Murray Cumming <murrayc@murrayc.com>
2034 * src/main/java/org/glom/web/client/ui/TableSelectionViewImpl.java:
2035 Add a TextBox for the text of a quick find.
2036 Add getQuickFindBox(), to get the widget, and getQuickFindText() to
2038 setBackLink(): Add a String quickFind parameter.
2039 * src/main/java/org/glom/web/client/ui/TableSelectionView.java
2040 (TableSelectionView): Add getQuickFindBox() and getQuickFindText()
2041 to the base interface, because that is how TableSelectionViewImpl is used.
2042 * src/main/webapp/style.css: Add style for the search box and its label.
2044 * src/main/java/org/glom/web/client/event/QuickFindChangeEvent.java:
2045 * src/main/java/org/glom/web/client/event/QuickFindChangeEventHandler.java:
2046 Add these files, based on the existing TableChangeEvent and
2047 TableChangeEventHandlers.
2048 * src/main/java/org/glom/web/client/activity/DetailsActivity.java
2049 start(): Handle QuickFindChangeEvent, passing its quickFind text to
2050 a ListPlace() that the user should be taken to.
2051 * src/main/java/org/glom/web/client/activity/ListActivity.java
2052 start(): Handle it here too and adapt the TableChangeEvent handler to
2053 pass the extra "" quickFind parameter to ListPlace.
2054 * src/main/java/org/glom/web/client/place/ListPlace.java:
2055 Constructor: Take an extra String quickFind parameter and store it,
2056 returning it from a new getQuickFind() method.
2057 getToken(): Put the quickFind text in the URL token.
2058 getPlace(): Parse the quickFind text from the URL token.
2059 * src/main/java/org/glom/web/client/ui/DocumentSelectionViewImpl.ja
2060 va: addDocumentLink(): Pass an extra "" quickFind parameter to the
2061 ListPlace constructor.
2062 * src/main/java/org/glom/web/client/activity/TableSelectionActivity
2063 .java: start(): Add a Change handler for the TableSelectionView's
2064 TextBox (via its base HasChangeHandlers interface), firing the new
2065 QuickFindChangeEvent.
2066 setPlace(): Adapt the call to TableSelectionView.setbackLink(), to
2067 pass the extra "" quickFind parameter.
2069 * src/main/java/org/glom/web/client/ui/ListViewImpl.java:
2070 setCellTable(): Add a String quickFind parameter and pass it to
2071 the ListViewTable() constructor.
2072 * src/main/java/org/glom/web/client/ui/ListView.java: Change
2073 setCellTable() in the base interface, because that is how ListViewImpl
2076 * src/main/java/org/glom/web/client/ui/list/ListTable.java:
2077 Add a String quickFind member variable.
2078 * src/main/java/org/glom/web/client/ui/list/ListViewTable.java:
2079 Constructor: Add a String quickFind parameter, storing it in the
2080 base ListTable's member variable.
2081 onRangeChanged(): Pass quickFind to the
2082 OnlineGlomServiceAsync.getSortedListViewData() and
2083 OnlineGlomServiceAsync.getListViewData() methods.
2085 * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java:
2086 getListViewData(), getSortedListViewData(): Add a String quickFind
2087 parameter, passing it to ConfiguredDocument.getListViewData().
2088 * src/main/java/org/glom/web/client/OnlineGlomService.java:
2089 Change getListViewData(), getSortedListViewData() in the base interface,
2090 because that is how OnlineGlomServiceImpl is used, via this:
2091 * src/main/java/org/glom/web/client/OnlineGlomServiceAsync.java:
2092 Change getListViewData(), getSortedListViewData() here too.
2093 This class can apparently be used to asynchronously call methods on
2094 OnlineGlomService, and GWT seems to implement that after recognizing
2095 just the *Async name convention and the extra AsyncCallback parameters.
2097 * src/main/java/org/glom/web/server/ConfiguredDocument.java
2098 getListViewData(): Add a String quickFind parameter, and pass it to
2099 ListViewDBAccess.getData().
2100 * src/main/java/org/glom/web/server/database/ListDBAccess.java
2101 getListData(): Add a String quickFind parameter and pass it to
2103 getSelectQuery(): Add a String quickFind parameter.
2104 * src/main/java/org/glom/web/server/database/ListViewDBAccess.java
2105 getSelectQuery(): Add a String quickFind parameter and use it with
2106 Glom.get_find_where_clause_quick() to pass a where_clause to
2107 Glom.build_sql_select_with_where_clause(), to actually filter the
2109 getData(): Add a String quickFind parameter, passing it to getListData().
2110 * src/main/java/org/glom/web/server/database/RelatedListDBAccess.ja
2111 va: getData(): Pass an empty string to getListData() for the
2112 quickFind parameter.
2114 2012-01-12 Murray Cumming <murrayc@murrayc.com>
2116 ListTable: Minor change.
2118 * src/main/java/org/glom/web/client/ui/list/ListTable.java
2119 createCellTable(): Make this protected instead of public.
2121 2012-01-12 Murray Cumming <murrayc@murrayc.com>
2123 Many files: Use final for the parameters and use the @override attribute.
2125 2012-01-22 Ben Konrath <ben@bagu.org>
2127 Add anchor links for single line text that starts with http, ftp and www.
2131 2012-01-22 Ben Konrath <ben@bagu.org>
2133 Add ellipsis to single line text in details view.
2137 2012-01-04 Murray Cumming <murrayc@murrayc.com>
2139 Remove all javadoc author tags.
2141 Because they are awkward and meaningless when many people touch
2143 See https://gitorious.org/online-glom/gwt-glom/commit/7628b732cb90cbc6d5635420a75568504e8b3655#comment_81164
2145 2012-01-04 Murray Cumming <murrayc@murrayc.com>
2147 Revert the COPYING.LESSER to COPYING rename.
2149 Apparently both should be there if it is LGPL.
2151 2012-01-03 Murray Cumming <murrayc@murrayc.com>
2153 *View: Remove unused imports.
2155 * src/main/java/org/glom/web/client/ui/DetailsView.java:
2156 * src/main/java/org/glom/web/client/ui/DocumentSelectionView.java
2157 * src/main/java/org/glom/web/client/ui/ListView.java:
2158 * src/main/java/org/glom/web/client/ui/TableSelectionView.java:
2159 Remove unused imports, as suggested by Eclipse.
2161 2012-01-02 Murray Cumming <murrayc@murrayc.com>
2163 Move the *View::Presenter types, and some API into one base View.
2165 * src/main/java/org/glom/web/client/ui/DetailsView.java:
2166 * src/main/java/org/glom/web/client/ui/DocumentSelectionView.java:
2167 * src/main/java/org/glom/web/client/ui/ListView.java:
2168 * src/main/java/org/glom/web/client/ui/TableSelectionView.java: Move
2169 Presenter, setPresenter() and clear() into a shared base interface,
2170 to avoid the unnecessary duplicate Presenter types and to more clearly
2171 show how the *Views share the same structure, even if they are not
2172 used polymorphically.
2174 * src/main/java/org/glom/web/client/ui/DetailsViewImpl.java:
2175 * src/main/java/org/glom/web/client/ui/DocumentSelectionViewImpl.ja
2177 * src/main/java/org/glom/web/client/activity/DetailsActivity.java:
2178 * src/main/java/org/glom/web/client/activity/ListActivity.java:
2179 * src/main/java/org/glom/web/client/activity/DocumentSelectionActiv
2181 * src/main/java/org/glom/web/client/activity/TableSelectionActivity
2184 Feel free to revert this if there is a good reason for the duplicate
2187 2012-01-02 Murray Cumming <murrayc@murrayc.com>
2189 OnlineGlom: Make clientFactory a (protected) member, and test it a bit.
2191 * src/main/java/org/glom/web/client/OnlineGlom.java: Make clientFactory
2192 a class member instead of a local variable in the method.
2193 This lets us use it to get the view instances, for use in tests.
2194 * src/test/java/org/glom/web/client/GwtTestOnlineGlom.java:
2195 beforeOnlineGlom(): Test some more details of the initial view.
2196 Again, this is not very useful.
2198 To really test gwt-glom we will need to start a local postgresql
2199 instance with local data, like the Glom tests in C++.
2201 2012-01-02 Murray Cumming <murrayc@murrayc.com>
2203 pom.xml: Mention the LGPL license.
2205 * pom.xml: Add a licenses section.
2206 * COPYING.LESSER: Move this to COPYING, which
2207 previously contained the GPL. But gwt-glom is all LGPL.
2209 2012-01-02 Murray Cumming <murrayc@murrayc.com>
2211 Add project information to README and pom.xml.
2213 * README: Add a brief description and mention some mvn
2215 * pom.xml: This extra information shows up in mvn site
2218 2011-01-02 Murray Cumming <murrayc@murrayc.com>
2220 Use the latest java-libglom version.
2222 * pom.xml: Use java-libglom 1.19.2 instead of 1.19.1.
2224 2012-01-01 Murray Cumming <murrayc@murrayc.com>
2226 GwtTestOnlineGlom: Test a little more.
2228 * src/main/java/org/glom/web/client/OnlineGlom.java: Make the panels
2229 protected rather than private, as suggested by the gwt-test-utils
2231 http://stackoverflow.com/questions/7931724/gwt-testcase-simulating-clicking-a-button-on-my-page
2232 * src/test/java/org/glom/web/client/GwtTestOnlineGlom.java
2233 Test the initial visibility of the panels.
2235 However, this is not a very useful test.
2236 And I wonder how we should generally test using this idea for an
2237 activity/places app like ours where the real changes happen implicitly
2238 based on the history token/URL.
2240 2012-01-01 Murray Cumming <murrayc@murrayc.com>
2242 Slight modification to *Mapper comments.
2244 * src/main/java/org/glom/web/client/mvp/DataActivityMapper.java
2245 (DataActivityMapper)
2246 * src/main/java/org/glom/web/client/mvp/DocumentSelectionActivityMa
2248 * src/main/java/org/glom/web/client/mvp/TableSelectionActivityMappe
2250 Remove comments mentioning GIN because they are just copied from
2251 the example code and are apparently not helpful:
2252 http://groups.google.com/group/google-web-toolkit/msg/82f0098b20669a73
2253 Also change the mention of a class that is only in the example code.
2255 2012-01-01 Murray Cumming <murrayc@murrayc.com>
2257 GwtTestOnlineGlom test: Minor changes.
2259 * src/test/java/org/glom/web/client/GwtTestOnlineGlom.java:
2260 Avoid the long qualified class name and modify the comment
2261 because it is now obvious to me that the mocked class is the only
2262 custom one created via GWT.create().
2264 2012-01-01 Murray Cumming <murrayc@murrayc.com>
2266 Tests: Added the beginnings of a test using gwt-test-utils.
2268 * pom.xml: Add dependencies on gwt-test-utils and easymock.
2269 * src/test/resources/META-INF/gwt-test-utils.properties: Add this file
2270 which tells gwt-test-utils what class will be tested.
2271 * src/test/java/org/glom/web/client/GwtTestOnlineGlom.java:
2272 Add a simple (but empty) test case. One class, used by the OnlineGlom
2273 class, is mocked so that it can be created. However, I am not sure
2274 why only this class needs to be mocked.
2276 Note that mockito seems more popular, and clearer, than easymock,
2277 but I have not got that working yet. It might be a matter of the
2280 This test is run during mvn integration-test.
2282 2011-12-31 Murray Cumming <murrayc@murrayc.com>
2284 Tests: Use junit4-style syntax instead of junit3-style.
2286 * src/test/java/org/glom/web/client/place/DetailsPlaceTest.java:
2287 * src/test/java/org/glom/web/client/place/ListPlaceTest.java:
2288 * src/test/java/org/glom/web/shared/DataItemTest.java:
2289 Use the @Test annotation rather than relying on the test*() prefix.
2290 Also no longer implement TestCase, to avoid triggering support for
2291 the junit3-way, which stops the annotations from working.
2292 Change the imports from import junit.framework.* to
2293 import org.junit.*, which is apparently the new way.
2295 2011-12-31 Murray Cumming <murrayc@murrayc.com>
2297 Added a test for ListPlace token parsing and creation.
2299 * src/test/java/org/glom/web/client/place/ListPlaceTest.java:
2300 This is much the same as DetailsPlaceTest.
2302 I wonder how we could test the other parts of the *Place API.
2304 2011-12-30 Murray Cumming <murrayc@murrayc.com>
2306 DetailsPlace test: Also test getToken() and recreation via getPlace().
2308 * src/test/java/org/glom/web/client/place/DetailsPlaceTest.java:
2309 testGetPlaceParameters(): Get the tokens from the DetailsPlace and
2310 recreate it, testing the recreated DetailsPlace for the same parameter
2313 2011-12-30 Murray Cumming <murrayc@murrayc.com>
2315 Use the surefire-report plugin.
2317 * pom.xml: This generates a HTML report about the tests in
2318 target/site/surefire-report.html
2319 when you do mvn surefire-report:report. It seems to be popular/normal.
2321 2011-12-30 Murray Cumming <murrayc@murrayc.com>
2323 Added a test for DetailsPlace.
2325 * src/test/java/org/glom/web/client/place/DetailsPlaceTest.java:
2326 Test the getPlace() token parsing.
2328 2011-12-30 Murray Cumming <murrayc@murrayc.com>
2330 Added a first unit test.
2332 * pom.xml: Add a test goal, and a dependency on junit in that scope.
2333 * src/test/java/org/glom/web/shared/DataItemTest.java:
2334 This is a silly test but it is just to get things started. Note that
2335 maven/junit finds the test because it looks in src/test by default.
2337 2011-12-22 Ben Konrath <ben@bagu.org>
2339 Change charsetName to "UTF-8" when replacing line breaks.
2341 JavaScript requires the charsetName to be "UTF-8". CharsetName values
2342 that work in Java (such as "UTF8") will not work when compiled to
2345 This fixes a problem with multi-line details view fields that have hard
2346 line breaks. The "License Text" field on this page demonstrates the
2349 http://onlineglom.openismus.com/OnlineGlom/#details:document=debian_repository_analyzer&table=licenses&value=197
2351 * src/main/java/org/glom/web/client/ui/details/DetailsCell.java:
2353 2011-12-22 Ben Konrath <ben@bagu.org>
2355 Fix another bug with related list navigation.
2357 I've tested all the navigation buttons in all of the related lists
2358 so things should be good now.
2360 * src/main/java/org/glom/web/server/ConfiguredDocument.java:
2362 2011-12-22 Ben Konrath <ben@bagu.org>
2364 Fix a crasher when refreshing the list view with the default table.
2366 This crash will also happen when loading the list view with the default
2367 table from a link or bookmark.
2369 * src/main/java/org/glom/web/client/activity/DetailsActivity.java: Go
2370 to the main document selection page when the document id hasn't been
2372 * src/main/java/org/glom/web/client/activity/ListActivity.java: Go to
2373 the main document selection page when the document id hasn't been
2375 * src/main/java/org/glom/web/client/place/DetailsPlace.java: Use empty
2376 values for the details place when the document id hasn't been set.
2377 * src/main/java/org/glom/web/client/place/ListPlace.java: Use empty
2378 values for the list place when the document id hasn't been set.
2380 2011-12-21 Ben Konrath <ben@bagu.org>
2382 Protect against NPE when glom.document.locale is not in config.
2384 This patch protects against an NPE when glom.document.locale is not in
2385 the config file. This NPE will also happen if glom.document.locale is
2388 The patch also updates the error message to display the class name when
2389 the getMessage() returns null. This was happening when the NPE was
2390 thrown and I had "Configuration Error: null". If an NPE is encountered
2391 with this patch, "Configuration Error: NullPointerException " will be
2394 This commit closes this bug:
2396 https://bugzilla.gnome.org/show_bug.cgi?id=666669
2398 * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java:
2400 2011-12-20 Murray Cumming <murrayc@murrayc.com>
2402 Rename onlineglom.properties to onlineglom.properties.sample.
2404 * src/main/resources/onlineglom.properties: Rename to:
2405 * src/main/resources/onlineglom.properties.sample:
2406 * src/main/resources/README: And add this file explaining that people
2407 should rename it back when deploying.
2409 2011-12-20 Murray Cumming <murrayc@murrayc.com>
2411 Allow choosing the translation in the .properties file.
2413 * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java
2414 init(): Read a glom.document.locale value from the configuration file
2415 and call Glom's TransatableItem::set_current_locale() method.
2416 * src/main/resources/onlineglom.properties: Add a commented-out
2417 example of this new setting.
2419 It would be better to add &lang=de_DE to the URL, but the current
2420 libglom API does not allow us to do this easily. I am working on that.
2422 2011-12-19 Murray Cumming <murrayc@murrayc.com>
2424 Avoid a crash in parsing of token parameters.
2426 * src/main/java/org/glom/web/client/place/HasSelectableTablePlace.j
2427 ava: getTokenParams(): Do not crash if a parameter has a key but no
2428 value, and ignore parameters with neither.
2430 2011-12-17 Murray Cumming <murrayc@murayc.com>
2432 History token building/handling: Improve use of token parameters.
2434 * src/main/java/org/glom/web/client/place/HasSelectableTablePlace.java
2435 (HasSelectableTablePlace.Tokenizer): Add getTokenParams(String)
2436 and buildParamsToken(HashMap), for use by derived classes.
2437 Make the separator private because it is no longer be needed.
2438 * src/main/java/org/glom/web/client/place/DetailsPlace.java
2439 (DetailsPlace.Tokenizer.getToken): Use buildParamsToken()
2440 instead of manual string concatenation.
2441 (DetailsPlace.Tokenizer.getPlace): Use getTokenParams() instead
2442 of hardcoded indices and awkward splitting code.
2443 * src/main/java/org/glom/web/client/place/ListPlace.java
2444 (ListPlace.Tokenizer.getToken): Use buildParamsToken()
2445 instead of manual string concatenation.
2446 (ListPlace.Tokenizer.getPlace): Use getTokenParams() instead
2447 of hardcoded indices and awkward splitting code.
2448 This should fix bug #666420
2450 2011-12-16 Murray Cumming <murrayc@murrayc.com>
2452 Fix a Navgiation->Navigation typo in the code.
2454 * src/main/java/org/glom/web/client/activity/DetailsActivity.java
2455 Rename processNavgiation() to processNavigation().
2457 2011-12-16 Murray Cumming <murrayc@murrayc.com>
2459 Fix a seperator->separator typo in the code.
2461 * src/main/java/org/glom/web/client/place/DetailsPlace.java
2462 * src/main/java/org/glom/web/client/place/HasSelectableTablePlace.java
2463 * src/main/java/org/glom/web/client/place/ListPlace.java: Just a
2466 2011-12-15 Ben Konrath <ben@bagu.org>
2468 Cleanup some comments.
2470 * src/main/java/org/glom/web/server/OnlineGlomServiceImpl.java:
2472 2011-12-14 Ben Konrath <ben@bagu.org>
2474 Replace \n with <br/> for multiline text in the details view.
2476 Vertical scrollbars are added when needed as well.
2478 * src/main/java/org/glom/web/client/ui/details/DetailsCell.java:
2480 2011-12-14 Ben Konrath <ben@bagu.org>
2482 Specify the font for document selection links.
2484 * src/main/webapp/style.css:
2486 2011-12-14 Ben Konrath <ben@bagu.org>
2488 Fix bouncy CellTable while paging.
2490 This doesn't currently work with related list tables in unselected
2493 * src/main/java/org/glom/web/client/ui/list/ListTable.java
2495 2011-12-14 Ben Konrath <ben@bagu.org>
2497 Revamp the appearance of the document selection page.
2499 * src/main/java/org/glom/web/client/ui/DocumentSelectionViewImpl.java:
2500 * src/main/java/org/glom/web/client/ui/DocumentSelectionViewImpl.ui.xml:
2501 * src/main/webapp/style.css:
2503 2011-12-13 Ben Konrath <ben@bagu.org>
2505 Set navigation button column to the smallest size possible.
2507 * src/main/java/org/glom/web/client/ui/list/ListTable.java:
2509 2011-12-13 Ben Konrath <ben@bagu.org>
2511 Change OpenButton nomenclature to NavigationButton.
2513 Using NavigtionButton makes things more generic. Classes, methods and
2514 variables have been changed.
2516 This is a rename-only refactor.
2518 * src/main/java/org/glom/web/client/activity/DetailsActivity.java:
2519 * src/main/java/org/glom/web/client/ui/ListViewImpl.java:
2520 * src/main/java/org/glom/web/client/ui/cell/NavigationButtonCell.java:
2521 Renamed from OpenButtonCell.
2522 * src/main/java/org/glom/web/client/ui/details/RelatedListTable.java:
2523 * src/main/java/org/glom/web/client/ui/list/ListTable.java:
2524 * src/main/java/org/glom/web/client/ui/list/ListViewTable.java:
2526 2011-12-12 Ben Konrath <ben@bagu.org>
2528 Remove unnecessary String argument in RelatedListTable and ListViewTable.
2530 * src/main/java/org/glom/web/client/activity/DetailsActivity.java:
2531 * src/main/java/org/glom/web/client/ui/ListViewImpl.java:
2532 * src/main/java/org/glom/web/client/ui/details/RelatedListTable.java:
2533 * src/main/java/org/glom/web/client/ui/list/ListViewTable.java:
2535 2011-12-12 Ben Konrath <ben@bagu.org>
2537 Update variable names and comments.
2539 * src/main/java/org/glom/web/client/ui/details/RelatedListTable.java:
2540 * src/main/java/org/glom/web/client/ui/list/ListViewTable.java:
2542 2011-12-12 Ben Konrath <ben@bagu.org>
2544 Properly initialize numNonEmptyRows variable to zero.
2546 * src/main/java/org/glom/web/client/ui/details/RelatedListTable.java:
2547 * src/main/java/org/glom/web/client/ui/list/ListViewTable.java:
2549 2011-12-05 Ben Konrath <ben@bagu.org>
2551 Add latest mockup with HTML tables.
2553 Features of this mockup:
2555 -> HTML table for flowtable
2556 -> HTML table for flowtable column
2557 -> Example of how related lists would look
2558 -> Not using text entries for data items
2560 The current version of Online Glom doesn't use HTML tables for the
2563 This mockup has been sent to the glom-devel mailing list but it's good
2564 to have it here as well.
2566 * mockups/details-view-html-tables.html:
2568 2011-12-05 Ben Konrath <ben@bagu.org>
2570 Remove unnecessary getPrimaryKeyField() method.
2572 getPrimaryKeyFieldForTable(String) has been renamed to
2573 getPrimaryKeyField(String).
2575 * src/main/java/org/glom/web/server/database/DBAccess.java:
2576 * src/main/java/org/glom/web/server/database/DetailsDBAccess.java:
2577 * src/main/java/org/glom/web/server/database/RelatedListNavigation.java:
2579 2011-12-05 Ben Konrath <ben@bagu.org>
2581 Add string representation of TypedDataItem value to conversion error message.
2583 * src/main/java/org/glom/web/server/Utils.java: Logging the error
2584 message was extracted into its own method to avoid duplication.
2586 2011-12-05 Ben Konrath <ben@bagu.org>
2588 Add type checking to navigation primary key value creation.
2590 Create navigation primary key only if the expected type from the Glom
2591 document matches the type returned by the SQL query.
2593 * src/main/java/org/glom/web/server/database/RelatedListNavigation.java:
2595 2011-12-05 Ben Konrath <ben@bagu.org>
2597 Rename a couple of variables in RelatedListNavigation.
2599 This is a rename-only refactor.
2601 * src/main/java/org/glom/web/server/database/RelatedListNavigation.java:
2603 2011-12-05 Ben Konrath <ben@bagu.org>
2605 Move getListLayoutGroup() into getListViewLayoutGroup().
2607 This removes getListLayoutGroup(). It was only being called by
2608 getListViewLayoutGroup().
2610 * src/main/java/org/glom/web/server/ConfiguredDocument.java:
2612 2011-12-05 Ben Konrath <ben@bagu.org>
2614 Remove check for LayoutItem_Portal in list table method.
2616 This check is no longer necessary because the method isn't being used
2617 to create the LayoutItemPortal DTO.
2619 * src/main/java/org/glom/web/server/ConfiguredDocument.java:
2621 2011-12-05 Ben Konrath <ben@bagu.org>
2623 Properly support related list navigation.
2625 Navigation from the "Repository Analyzer -> Package Scans ->
2626 Dependencies" related table wasn't working because the primary key for
2627 related tables wasn't being set properly. This commit fixes the
2630 * src/main/java/org/glom/web/server/ConfiguredDocument.java: Don't use
2631 getListLayoutGroup() to create the LayoutItemPortal DTO. This method
2632 doesn't set the primary key properly for related list tables.
2633 * src/main/java/org/glom/web/server/database/DBAccess.java: Add table
2634 name parameter to getPrimaryKeyLayoutItemField(). This makes the method
2635 useful for getting the primary key for list view tables and for related
2637 * src/main/java/org/glom/web/server/database/ListDBAccess.java:
2638 * src/main/java/org/glom/web/server/database/ListViewDBAccess.java:
2639 Move code to set the primary key for the table from the abstract
2640 ListDBAccess class to ListViewDBAccess as it's only correct for list
2642 * src/main/java/org/glom/web/server/database/RelatedListDBAccess.java:
2643 Properly add primary key to related list tables.
2645 2011-12-02 Ben Konrath <ben@bagu.org>
2647 Properly set the horizontal alignment of fields.
2649 This fix is for both the list tables and the details view.
2651 * src/main/java/org/glom/web/server/ConfiguredDocument.java: Use
2652 LayoutItem_WithFormatting.get_formatting_used_horizontal_alignment(boolean)
2653 to set the horizontal alignment of fields.
2655 2011-12-02 Ben Konrath <ben@bagu.org>
2657 Display currency codes in the details view.
2659 * src/main/java/org/glom/web/client/ui/details/DetailsCell.java:
2661 2011-12-02 Ben Konrath <ben@bagu.org>
2663 Avoid duplicate JNI call.
2665 JNI is not as efficient as pure Java and this is an easy (and small)
2668 * src/main/java/org/glom/web/server/database/RelatedListDBAccess.java:
2669 Use previously retrieved value for whereClauseToTableName instead of
2672 2011-12-02 Ben Konrath <ben@bagu.org>
2674 Rename a couple of variables in RelatedListNavigation.
2676 This is a rename-only refactor.
2678 * src/main/java/org/glom/web/server/database/RelatedListNavigation.java:
2680 2011-12-02 Ben Konrath <ben@bagu.org>
2682 Indicate clearly that a mismatched primary key type is a bug.
2684 * src/main/java/org/glom/web/server/Utils.java: Change log level from
2685 warning to error. Add 'This is a bug.' to message.
2687 2011-12-02 Ben Konrath <ben@bagu.org>
2689 Update / fix some comments.
2691 * src/main/java/org/glom/web/client/OnlineGlomService.java: Remove old
2693 * src/main/java/org/glom/web/client/ui/details/DetailsCell.java: Fix
2695 * src/main/java/org/glom/web/server/database/RelatedListDBAccess.java:
2696 Fix comments. Add some TODOs.
2698 2011-12-02 Ben Konrath <ben@bagu.org>
2700 Enable navigation to details view with string primary key from related list.
2702 * src/main/java/org/glom/web/server/database/RelatedListNavigation.java:
2703 Create a text primary key value when return type of result is
2704 java.sql.Types.VARCHAR.
2706 2011-12-02 Ben Konrath <ben@bagu.org>
2708 Use checkboxes for booleans in the details view.
2710 * src/main/java/org/glom/web/client/ui/details/DetailsCell.java:
2712 2011-12-01 Ben Konrath <ben@bagu.org>
2714 Improve performance of related list height calculation.
2716 * src/main/java/org/glom/web/client/ui/details/RelatedListTable.java:
2717 Put code to calculate the expected height in a static initializer so
2718 that that it's only called once.
2720 2011-12-01 Ben Konrath <ben@bagu.org>
2722 Show related list tables in notebooks (again).
2724 Calculate the height of the related list tables so the Notebook can be
2725 set the correct height. The height of the related list table is also needed by
2726 FlowTable to be able decide how to create the layout.
2728 * src/main/java/org/glom/web/client/ui/details/Portal.java: Calculate
2729 and set the Portal height based on the height of the related list
2730 table and the Portal container.
2731 * src/main/java/org/glom/web/client/ui/details/RelatedListTable.java:
2732 Add method to calculate the height of the related list tables.
2733 * src/main/java/org/glom/web/client/ui/list/ListTable.java:
2734 * src/main/webapp/style.css: Add css class for Pager. This is needed to
2735 calculate the height of the Pager widget.
2737 2011-12-01 Ben Konrath <ben@bagu.org>
2739 Use CellTable API for table property instead of setting style on Element.
2741 * src/main/java/org/glom/web/client/ui/details/RelatedListTable.java:
2743 2011-12-01 Ben Konrath <ben@bagu.org>
2745 Make ListViewTable and RelatedListTable a consistent height.
2747 The tables are now a consistent height regardless of the contents of
2748 the table. A hidden button is added to empty rows to ensure that the
2749 height of these rows will match the height of rows with data.
2751 A navigation button column is now added to every table. The width of
2752 the navigation column is set to 0px when a RelatedListTable shouldn't
2753 have navigation buttons. This maintains the a consistent row height in
2754 tables that don't show the navigation buttons.
2756 * src/main/java/org/glom/web/client/activity/DetailsActivity.java: Hide
2757 navigation column when not needed.
2758 * src/main/java/org/glom/web/client/ui/ListViewImpl.java: Move method
2759 arguments for navigation button to constructor of ListViewTable.
2760 * src/main/java/org/glom/web/client/ui/cell/OpenButtonCell.java: Render
2761 hidden button for empty data rows.
2762 * src/main/java/org/glom/web/client/ui/details/RelatedListTable.java: Add method
2763 arguments for navigation button to constructor.
2764 * src/main/java/org/glom/web/client/ui/list/ListTable.java: Always
2765 create navigation buttons. Add hideNavigationButtons() method.
2766 * src/main/java/org/glom/web/client/ui/list/ListViewTable.java: Add method
2767 arguments for navigation button to constructor.
2769 2011-12-01 Ben Konrath <ben@bagu.org>
2771 Use 'visibility: hidden' in Utils.getWidgetHeight().
2773 This is better choice because hidden elements are invisible, don't
2774 respond to events and are not part of the tab order. They will,