Ignore:
Timestamp:
04/15/17 12:32:05 (7 years ago)
Author:
István Váradi <ivaradi@…>
Branch:
default
hg-Phase:
(<MercurialRepository 1 'hg:/home/ivaradi/mlx/hg' '/'>, 'public')
Message:

All data is displayed and is editable in the PIREP editor (re #307)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/mlx/pirep.py

    r829 r833  
    202202        self.delayCodes = pirepData["timeComment"]
    203203        if self.delayCodes=="UTC":
    204             self.delayCodes = ""
     204            self.delayCodes = []
     205        else:
     206            self.delayCodes = self.delayCodes.split(", ")
    205207
    206208        flightDate = pirepData["flightDate"] + " "
     
    371373        attrs["ratingText"] = self.getRatingText()
    372374        attrs["rating"] = max(0.0, self.rating)
    373         attrs["flownDistance"] = self.flownDistance
     375        attrs["flownDistance"] = "%.2f" % (self.flownDistance,)
    374376        # FIXME: it should be stored in the PIREP when it is sent later
    375377        attrs["performDate"] = datetime.date.today().strftime("%Y-%m-%d")
Note: See TracChangeset for help on using the changeset viewer.