aboutsummaryrefslogtreecommitdiffstats
path: root/xslt
AgeCommit message (Collapse)Author
2014-12-13Include dive buddies on uddf importGravatar Miika Turkia
Adjust to UDDF 3.2 specification Signed-off-by: Miika Turkia <miika.turkia@gmail.com> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2014-12-13Include dive location on uddf importGravatar Miika Turkia
Adjust to UDDF 3.2 specification Signed-off-by: Miika Turkia <miika.turkia@gmail.com> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2014-12-13Include notes on uddf importGravatar Miika Turkia
Adjust to UDDF 3.2 specification Signed-off-by: Miika Turkia <miika.turkia@gmail.com> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2014-12-13Fix name for temperature sample on UDDF importGravatar Miika Turkia
Signed-off-by: Miika Turkia <miika.turkia@gmail.com> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2014-12-13UDDF import: check following event timeGravatar Miika Turkia
Seems that our UDDF export is adding time after the event name. Thus we need to add reading the following time as well. Signed-off-by: Miika Turkia <miika.turkia@gmail.com> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2014-12-13Include temperatures properly on uddf importGravatar Miika Turkia
Adjust to UDDF 3.2 specification and use proper tag name for air temperature. Signed-off-by: Miika Turkia <miika.turkia@gmail.com> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2014-12-13Include rating and visibility on uddf importGravatar Miika Turkia
Adjust to UDDF 3.2 specification Signed-off-by: Miika Turkia <miika.turkia@gmail.com> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2014-12-13Grab manually added air temperature on UDDF exportGravatar Miika Turkia
Signed-off-by: Miika Turkia <miika.turkia@gmail.com> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2014-12-13Include dive duration on uddf importGravatar Miika Turkia
Adjust to UDDF 3.2 specification Signed-off-by: Miika Turkia <miika.turkia@gmail.com> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2014-12-13Include dive number on uddf importGravatar Miika Turkia
Adjust to UDDF 3.2 specification Signed-off-by: Miika Turkia <miika.turkia@gmail.com> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2014-12-13Fix switchmix references on UDDF exportGravatar Miika Turkia
The switchmix values must be concatenated properly. Signed-off-by: Miika Turkia <miika.turkia@gmail.com> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2014-12-13Fix mix reference on UDDF exportGravatar Miika Turkia
The mix value must be concatenated properly. Signed-off-by: Miika Turkia <miika.turkia@gmail.com> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2014-12-13Export leadquantity only when we have weightsGravatar Miika Turkia
Signed-off-by: Miika Turkia <miika.turkia@gmail.com> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2014-12-13Export only used cylinders to divelogs.deGravatar Miika Turkia
This attempts to export only used cylinders to divelogs.de. The detection is based only on o2 percentage as per our test dives. However, the new cylinder id would be better, but that does not exist on old dives. Fixes #757 Signed-off-by: Miika Turkia <miika.turkia@gmail.com> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2014-12-12Fix bug in tankpressurebegin in UDDF exportGravatar Martin Long
There was a bug when the first sample doesn't contain pressure info. This fixes that by selecting the first with pressure info. Signed-off-by: Martin Long <martin@longhome.co.uk> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2014-12-12Lots of minor UDDF export tweaks.Gravatar Martin Long
The XDS schema for UDDF is very sensitive to ordering of elements so I've rearranged many of them to match. Elements in: - informationbeforedive - waypoint Adjusted namespace of export to correct UDDF namespace. Updated remaining references to mixes it include prefix 'mix' Moved equipment from informationbeforedive to informationafterdive * Change trip ids to generated IDs and updated tripmembership to use the trip id instead of the name * * These constitutes a difference in XSD and the documentation. I will raise these issues with the author. Signed-off-by: Martin Long <martin@longhome.co.uk> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2014-12-12Various minor fixes to UDDF exportGravatar Martin Long
Removed underscore from buddy name elements Added 'mix' prefix to gas ids. Ids must not start with a number. Added mandatory profile data with empty tags. Signed-off-by: Martin Long <martin@longhome.co.uk> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2014-12-12Fix divecomputer part of UDDF exportGravatar Martin Long
XPath was incorrect for parsing divecomputers into the equipment section, meaning they dont get inserted. Signed-off-by: Martin Long <martin@longhome.co.uk> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2014-12-12Use generated Ids for site lookup in UDDF export.Gravatar Martin Long
As with buddies, sites could contain characters which are not valid in Ids. Also, it is very possible to have duplicate site names. This uses an XSL generated id to prevent any issues. Signed-off-by: Martin Long <martin@longhome.co.uk> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2014-12-12Use generated ids for buddies in UDDF export.Gravatar Martin Long
This is instead of using their names, which may contain illegal characters. Signed-off-by: Martin Long <martin@longhome.co.uk> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2014-12-12Update UDDF export <generator> header to include madatory tags.Gravatar Martin Long
Add name at <generator> level, and add additional <homepage> in contact tag. Signed-off-by: Martin Long <martin@longhome.co.uk> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2014-12-10Add 'trip' support to UDDF exportGravatar Martin Long
Currently repetition groups are used to group dives into trips. This is not really correct. Repetition groups should really represent a group of dives where tissue loading needs to be preserved between dives (typically the same day). UDDF has support for trips, using the <divetrip> tags. This is a bidirectional link between the dives and the trips. This patch adds support for these trips. However, it leaves in the repetition groups. Repetition groups may need further consideration. Signed-off-by: Martin Long <martin@longhome.co.uk> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2014-12-10Aggregate multiple weights into UDDF export.Gravatar Martin Long
Sum together all of the weights recored on a dive to use in the <leadquantity> tag in UDDF export. Signed-off-by: Martin Long <martin@longhome.co.uk> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2014-12-10Support buddies with only a first name, no surname.Gravatar Martin Long
The previous patch would not fill the first name field if there was no second name. This rectifies that. Signed-Off-By: Martin Long <martin@longhome.co.uk> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2014-12-10Allow more flexible GPS coordinates for CSV importGravatar Miika Turkia
This theoretically allows one to use format like 1°36'11.711"N 124°46'00.368"E for GPS coordinates. However, in practice this is not allowed without properly parsing this format in C/C++ side. This patch changes the export format to UTF8 and improves the location import by allowing either gps or location attributes to be imported. Signed-off-by: Miika Turkia <miika.turkia@gmail.com> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2014-12-10Fixed airtemperature in UDDF export.Gravatar Martin Long
The XSLT didn't expect the temperature tag to be within the <divecomputer> element in the source, so the selection wasn't finding it. Signed-off-by: Marton Long <martin@longhome.co.uk> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2014-12-10Added <leadquantity> to UDDF export, showing weight used.Gravatar Martin Long
Signed-off-by: Marton Long <martin@longhome.co.uk> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2014-12-10Split last_name and first_name for buddies in UDDF exportGravatar Martin Long
Signed-off-by: Marton Long <martin@longhome.co.uk> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2014-12-10Fix gasdefinitons in UDDF exportGravatar Martin Long
Selection of <cylinder> elements wasn't working where dives are part of a trip. Change the selection so that it will select all cylinders whether or not the dive is part of a trip. Signed-off-by: Marton Long <martin@longhome.co.uk> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2014-12-10Prevent UserID from being 'stuffed' into the start of UDDF export.Gravatar Martin Long
Due to there being no xsl template for the userID, it ended up getting inserted at the start of the output. This adds an empty template to map the <settings> element, preventing this erronious insertion. Signed-off-by: Marton Long <martin@longhome.co.uk> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2014-12-10Update dive site structure in UDDF export to match UDDF 3.2.0 specification.Gravatar Martin Long
The dive site structure in the UDDF export was using an old structure where each site is simply listed as a <dive_site>. The new structure requires a single <divesite> containing at least one <divebase> - a base location where you are diving from, and at least one <site>. As subsurface only tracks sites, I've created a single divebase to be referenced by all of the sites. Note: although profiles in Subsurface can be grouped into trips, these are groupings of profiles, not sites, and the mapping may not be simple. e.g. on different trips the sames sites may be visited but a different base used. Or, different bases may be used on a single trip. Signed-off-by: Marton Long <martin@longhome.co.uk> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2014-12-10Separate out buddies into individual entities when exporting to UDDF.Gravatar Martin Long
Part of a series bringing UDDF export closer to the UDDF standard, as per www.uddf.org. Currently when exporting to UDDF buddy entities are created one-per-unique-combination. This means that a group of buddies on a dive are exported as a single buddy, with the names comma separated. This patch identifies all unique buddies, whether used independently or along with other buddies on a dive. They are then linked independently on each profile. It also uses the UDDF standard <link ref=""> instead of <buddy_ref ref=""> Signed-off-by: Marton Long <martin@longhome.co.uk> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2014-12-07Include some extra information on Shearwater importGravatar Miika Turkia
Signed-off-by: Miika Turkia <miika.turkia@gmail.com> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2014-12-07Samples should be inside divecomputer on Shearwater importGravatar Miika Turkia
Data read from a divecomputer is moved inside the divecomputer tag Signed-off-by: Miika Turkia <miika.turkia@gmail.com> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2014-12-07Add cylinder support for Shearwater XML importGravatar Miika Turkia
This tries to grab the used cylinders when in open circuit mode. Signed-off-by: Miika Turkia <miika.turkia@gmail.com> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2014-12-07Record ppO2 only when on CCR modeGravatar Miika Turkia
Shearwater describes the current mode with tag currentCircuitSetting, thus we should record the ppO2 only when in CCR mode. Signed-off-by: Miika Turkia <miika.turkia@gmail.com> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2014-11-25Allow user to select date format on manual CSV importGravatar Miika Turkia
Signed-off-by: Miika Turkia <miika.turkia@gmail.com> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2014-11-24Default dive number on manual CSV importGravatar Miika Turkia
If manual CSV import does not have any dive number, give a default one so that the dives get import and not silently ignored. Signed-off-by: Miika Turkia <miika.turkia@gmail.com> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2014-11-18Replace other references to hohndel.orgGravatar Dirk Hohndel
The only place where I'm not sure if there are unintended sideeffects of changing over to the new domain is QCoreApplication::setOrganizationDomain Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2014-11-10Support timedepth mode on UDCF importGravatar Miika Turkia
Fixes #756 Signed-off-by: Miika Turkia <miika.turkia@gmail.com> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2014-11-06Include po2 on Shearwater importGravatar Miika Turkia
Signed-off-by: Miika Turkia <miika.turkia@gmail.com> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2014-10-29Use bottom temperature on Suunto SDM importsGravatar Miika Turkia
Signed-off-by: Miika Turkia <miika.turkia@gmail.com> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2014-10-12Export additional tanks to divelogs.deGravatar Miika Turkia
All recorded cylinders are exported to divelogs.de. This potentially includes cylinders that have not been used. The start and end pressure for additional cylinders is taken from the cylinder information. Main tank gets this information from first and last pressure reading or from the cylinder information if samples are not available. This should be ok when there is only one cylinder with pressure sensor, but does not probably work for people having multiple sensors. Signed-off-by: Miika Turkia <miika.turkia@gmail.com> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2014-10-12Support for importing additional tanksGravatar Miika Turkia
This patch adds support for importing additional cylinders from divelogs.de. This also adds support for He on the import. Signed-off-by: Miika Turkia <miika.turkia@gmail.com> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2014-08-28Fix water temperature on Suunto SDM importGravatar Miika Turkia
Seems that Suunto stores temperature value of 0 when there is no temperature reading (I guess). Thus this patch ignores temperature samples that are zero. Otherwise, Subsurface looks into the samples and grabs the lowest number as water temperature. See #720 Signed-off-by: Miika Turkia <miika.turkia@gmail.com> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2014-08-20Import decostop information from UDDF filesGravatar Anton Lundin
Signed-off-by: Anton Lundin <glance@acc.umu.se> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2014-08-20Import NDL form UDDF filesGravatar Anton Lundin
Signed-off-by: Anton Lundin <glance@acc.umu.se> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2014-08-16Hack double tank support for export to divelogsGravatar Miika Turkia
If the cylinder description starts with D%d we test if the size in description matches the cylinder size. If the cylinder size is double compared to size in description, we mark the dive as double tank dive to divelogs.de. Signed-off-by: Miika Turkia <miika.turkia@gmail.com> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2014-08-05Remove wrong unit from CNS in UDDF importGravatar Miika Turkia
Signed-off-by: Miika Turkia <miika.turkia@gmail.com> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
2014-07-28CSV import: add min:sec format supportGravatar Miika Turkia
On CSV import the time can be represented with seconds, min:sec or hour:min:sec. This patch adds support for the min:sec format that was missing. See #662 Signed-off-by: Miika Turkia <miika.turkia@gmail.com> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>