summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorFélix Sipma <felix.sipma@no-log.org>2014-12-06 16:07:58 +0100
committerFélix Sipma <felix.sipma@no-log.org>2014-12-06 16:12:17 +0100
commit2550bf8d6757c4ac0d41a937793c1451585fcd16 (patch)
treedda6fbff922c0f663ec94e55f838968f2c55b544
parentb8bfaebf1bb4e5e4d959e1880a0e6a8267c8e519 (diff)
move Shop.Place.Types to Model.Point
-rw-r--r--Handler/PlaceList.hs2
-rw-r--r--Model.hs4
-rw-r--r--Model/Point.hs (renamed from Shop/Place/Types.hs)2
-rw-r--r--Settings.hs2
-rw-r--r--Shop/Place/Fields.hs2
-rw-r--r--Shop/Place/Functions.hs6
-rw-r--r--mokupona.cabal2
7 files changed, 10 insertions, 10 deletions
diff --git a/Handler/PlaceList.hs b/Handler/PlaceList.hs
index de57d11..5d78c31 100644
--- a/Handler/PlaceList.hs
+++ b/Handler/PlaceList.hs
@@ -1,7 +1,7 @@
module Handler.PlaceList where
import Import
-import Shop.Place.Types (Point (..))
+import Model.Point (Point (..))
import Shop.Place.Functions (toLeaflet)
import Shop.Place.Fields (pointField)
diff --git a/Model.hs b/Model.hs
index 729c95c..0339c59 100644
--- a/Model.hs
+++ b/Model.hs
@@ -3,10 +3,10 @@ module Model where
import ClassyPrelude.Yesod
import Database.Persist.Quasi
-import Model.Unit (Unit)
import Model.Amount (Amount)
+import Model.Point (Point (..))
import Model.Quantity (Quantity)
-import Shop.Place.Types (Point (..))
+import Model.Unit (Unit)
import Data.Aeson ((.:?))
-- You can define all of your database entities in the entities file.
diff --git a/Shop/Place/Types.hs b/Model/Point.hs
index 0ebede1..a291933 100644
--- a/Shop/Place/Types.hs
+++ b/Model/Point.hs
@@ -1,4 +1,4 @@
-module Shop.Place.Types where
+module Model.Point where
import Prelude
import Database.Persist.TH (derivePersistField)
diff --git a/Settings.hs b/Settings.hs
index 7cc9fc1..f5cb088 100644
--- a/Settings.hs
+++ b/Settings.hs
@@ -18,7 +18,7 @@ import Yesod.Default.Config2 (applyEnvValue, configSettingsYml)
import Yesod.Default.Util (WidgetFileSettings, widgetFileNoReload,
widgetFileReload)
import Data.Time (NominalDiffTime)
-import Shop.Place.Types (Point (..))
+import Model.Point (Point (..))
-- | Runtime settings to configure this application. These settings can be
-- loaded from various sources: defaults, environment variables, config files,
diff --git a/Shop/Place/Fields.hs b/Shop/Place/Fields.hs
index 017a17b..c1c7881 100644
--- a/Shop/Place/Fields.hs
+++ b/Shop/Place/Fields.hs
@@ -3,7 +3,7 @@ module Shop.Place.Fields where
import Import hiding ((<|>), try)
import Prelude (read)
-import Shop.Place.Types (Point (..))
+import Model.Point (Point (..))
import Shop.Place.Functions (toLeaflet)
import Text.Julius (rawJS)
import Text.Parsec
diff --git a/Shop/Place/Functions.hs b/Shop/Place/Functions.hs
index 1c908ec..2829bec 100644
--- a/Shop/Place/Functions.hs
+++ b/Shop/Place/Functions.hs
@@ -1,9 +1,9 @@
module Shop.Place.Functions where
import Prelude
-import Shop.Place.Types (Point (..))
-import Data.Text (pack)
-import Text.Julius (rawJS, RawJavascript)
+import Model.Point (Point (..))
+import Data.Text (pack)
+import Text.Julius (rawJS, RawJavascript)
toLeaflet :: Point -> RawJavascript
toLeaflet p = rawJS $ pack $ "[" ++ show (pntLat p) ++ "," ++ show (pntLon p) ++ "]"
diff --git a/mokupona.cabal b/mokupona.cabal
index 26d6a34..b580ffa 100644
--- a/mokupona.cabal
+++ b/mokupona.cabal
@@ -19,6 +19,7 @@ library
Settings
Settings.StaticFiles
Model.Amount
+ Model.Point
Model.Quantity
Model.Unit
Widget.Navbar
@@ -45,7 +46,6 @@ library
Shop.Image.Fields
Shop.Amount.Fields
Shop.Quantity.Fields
- Shop.Place.Types
Shop.Place.Functions
Shop.Place.Fields