Web   ·   Wiki   ·   Activities   ·   Blog   ·   Lists   ·   Chat   ·   Meeting   ·   Bugs   ·   Git   ·   Translate   ·   Archive   ·   People   ·   Donate
summaryrefslogtreecommitdiffstats
path: root/serialize.py
diff options
context:
space:
mode:
authorerikb <erikb@574bc980-5f2d-0410-acbc-c8f9f0eb14e0>2007-11-15 03:51:16 (GMT)
committer erikb <erikb@574bc980-5f2d-0410-acbc-c8f9f0eb14e0>2007-11-15 03:51:16 (GMT)
commite6dc6339ce3568fe5fc6cf25bb803c0cb5feda8b (patch)
tree6ee1911b4f0239d3f112e93d0f8d7e3b8df2d729 /serialize.py
parent25395014e74856ac77750b85ce220606e7f7b3af (diff)
v40 changes
git-svn-id: http://mediamods.com/public-svn/camera-activity/Record.activity@900 574bc980-5f2d-0410-acbc-c8f9f0eb14e0
Diffstat (limited to 'serialize.py')
-rw-r--r--serialize.py6
1 files changed, 4 insertions, 2 deletions
diff --git a/serialize.py b/serialize.py
index ec51f63..95b507e 100644
--- a/serialize.py
+++ b/serialize.py
@@ -151,7 +151,7 @@ def fillRecdFromNode( recd, el ):
bt = el.getAttributeNode(Constants.recdBase64Thumb)
if (bt != None):
try:
- thumbPath = os.path.join(Instance.tmpPath, "datastoreThumb.jpg")
+ thumbPath = os.path.join(Instance.instancePath, "datastoreThumb.jpg")
thumbPath = utils.getUniqueFilepath( thumbPath, 0 )
thumbImg = utils.getPixbufFromString( bt.nodeValue )
thumbImg.save(thumbPath, "jpeg", {"quality":"85"} )
@@ -163,7 +163,7 @@ def fillRecdFromNode( recd, el ):
ai = el.getAttributeNode(Constants.recdAudioImage)
if (not ai == None):
try:
- audioImagePath = os.path.join(Instance.tmpPath, "audioImage.png")
+ audioImagePath = os.path.join(Instance.instancePath, "audioImage.png")
audioImagePath = utils.getUniqueFilepath( audioImagePath, 0 )
audioImage = utils.getPixbufFromString( ai.nodeValue )
audioImage.save(audioImagePath, "png", {} )
@@ -312,11 +312,13 @@ def _saveMediaToDatastore( el, recd ):
mtype = Constants.mediaTypes[recd.type]
mime = mtype[Constants.keyMime]
+ record.Record.log.debug("mime_type:" + str(mime))
mediaObject.metadata['mime_type'] = mime
mediaObject.metadata['activity'] = Constants.activityId
mediaFile = recd.getMediaFilepath()
+ record.Record.log.debug("mediaFile:" + str(mediaFile))
mediaObject.file_path = mediaFile
mediaObject.transfer_ownership = True