Skip to content

Commit

Permalink
Merge pull request #48 from Hub-of-all-Things/v2.6.3
Browse files Browse the repository at this point in the history
V2.6.3 - Sentiment tracker improvements
  • Loading branch information
whiteshadow-gr committed Oct 8, 2018
2 parents 6a7a267 + acdfa92 commit 8a9eaa3
Show file tree
Hide file tree
Showing 5 changed files with 14 additions and 6 deletions.
3 changes: 1 addition & 2 deletions hat/app/org/hatdex/hat/api/controllers/SystemStatus.scala
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,6 @@
package org.hatdex.hat.api.controllers

import javax.inject.Inject

import com.mohiva.play.silhouette.api.Silhouette
import org.hatdex.hat.api.json.HatJsonFormats
import org.hatdex.hat.api.models._
Expand All @@ -39,7 +38,7 @@ import play.api.cache.Cached
import play.api.libs.json._
import play.api.mvc._

import scala.concurrent.ExecutionContext
import scala.concurrent.{ ExecutionContext }

class SystemStatus @Inject() (
components: ControllerComponents,
Expand Down
12 changes: 10 additions & 2 deletions hat/app/org/hatdex/hat/she/service/DataEndpointMapper.scala
Original file line number Diff line number Diff line change
Expand Up @@ -186,15 +186,23 @@ class InsightsMapper extends DataEndpointMapper {
"notables/feed" "Notes taken",
"spotify/feed" "Songs listened to",
"calendar/google/events" "Calendar events recorded",
"monzo/transactions" "Transactions performed")
"monzo/transactions" "Transactions performed",
"she/insights/emotions" -> "Posts analysed for Sentiments",
"she/insights/emotions/positive" -> "Positive",
"she/insights/emotions/negative" -> "Negative",
"she/insights/emotions/neutral" -> "Neutral")

private val sourceMappings = Map(
"twitter/tweets" "twitter",
"facebook/feed" "facebook",
"notables/feed" "notables",
"spotify/feed" "spotify",
"calendar/google/events" "google",
"monzo/transactions" "monzo")
"monzo/transactions" "monzo",
"she/insights/emotions" -> "sentiment",
"she/insights/emotions/positive" -> "sentiment-positive",
"she/insights/emotions/negative" -> "sentiment-negative",
"she/insights/emotions/neutral" -> "sentiment-neutral")

def mapDataRecord(recordId: UUID, content: JsValue): Try[DataFeedItem] = {
for {
Expand Down
2 changes: 1 addition & 1 deletion hat/conf/evolutions/hat-database-schema
1 change: 0 additions & 1 deletion rumpel.version

This file was deleted.

2 changes: 2 additions & 0 deletions version
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
rumpel=3ad0255ae3a87b45765e78d49145f45da7ff86be
hat=2018091001

0 comments on commit 8a9eaa3

Please sign in to comment.