Skip to content

Commit

Permalink
Merge branch 'master' of https://github.com/ox-it/moxie-js-client
Browse files Browse the repository at this point in the history
  • Loading branch information
ahaith committed Aug 22, 2016
2 parents 18e77dd + 5342064 commit f47bbdc
Show file tree
Hide file tree
Showing 7 changed files with 74 additions and 24 deletions.
37 changes: 22 additions & 15 deletions app/feedback/templates/feedback.handlebars
Original file line number Diff line number Diff line change
@@ -1,21 +1,28 @@

<div class="card">
<h3>Feedback</h3>
{{#if thanks}}
<p><strong>Thank you for your feedback!</strong></p>
{{else}}
<p>We're a small team based at IT Services as part of Oxford University and we're always interested in hearing what you think and what you'd like to see in Mobile Oxford.</p>
{{/if}}
<h3>Feedback and Support</h3>
<div class="padded-contents">
{{#if thanks}}
<p><strong>Thank you for your feedback!</strong></p>
{{else}}
<p>
Mobile Oxford is maintained and supported by IT Services at the University of Oxford.
</p>
<p>
If you need help or have any suggestions, please drop us a line through this form.
</p>
{{/if}}

<div id="feedback-form">
<div class="feedback-input">
<label for="input-email">Your email (optional):</label>
<input id="input-email" type="email" name="email" placeholder="e.g. example@example.com"/>
<div id="feedback-form">
<div class="feedback-input">
<label for="input-email">Your email (optional):</label>
<input id="input-email" type="email" name="email" placeholder="e.g. example@example.com"/>

<label for="input-message">Your feedback:</label>
<textarea id="input-message" type="text" name="message" rows="8" />
<label for="input-message">Your message:</label>
<textarea id="input-message" type="text" name="message" rows="8" />

<input class="action-button submit" type="submit" value="Send feedback!" id="submit-feedback" />
</div>
<input class="action-button submit" type="submit" value="Send feedback!" id="submit-feedback" />
</div>
</div>
</div>
</div>
</div>
2 changes: 1 addition & 1 deletion app/feedback/views/FeedbackView.js
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ define(['jquery', 'backbone', 'underscore', 'app/moxie.conf', 'app/feedback/mode
template: feedbackTemplate,

beforeRender: function() {
Backbone.trigger('domchange:title', "Feedback");
Backbone.trigger('domchange:title', "Feedback and Support");
},

submitFeedback: function(ev) {
Expand Down
22 changes: 22 additions & 0 deletions app/privacy/templates/privacy.handlebars
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
<div class="card-container">
<div class="card">
<h3>Privacy Policy</h3>
<div class="padded-contents">
<p>
The Mobile Oxford app does not collect personal information. We do use Google Analytics to collect general anonymous information about which screens are used most frequently so that we can improve user experience in the future.
</p>
</div>
</div>
<div class="card">
<h3>Android Permissions</h3>
<div class="padded-content">
<p>
Mobile Oxford requests permissions to read your address book and add/edit your contacts. This is for the Contact Search feature which allows users to write University contacts directly to their personal phonebook. We do not read from your contacts at any point and only use this to add new contacts.
</p>

<p>
Android also has a small quirk where requesting access to READ_CONTACTS automatically adds permissions for "read call log" and "write call log". Mobile Oxford does not access either of these functions.
</p>
</div>
</div>
</div>
13 changes: 13 additions & 0 deletions app/privacy/views/PrivacyView.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
define(['backbone', 'hbs!app/privacy/templates/privacy'], function(Backbone, privacyTemplate) {
var PrivacyView = Backbone.View.extend({

template: privacyTemplate,

beforeRender: function() {
Backbone.trigger('domchange:title', "Mobile Oxford Privacy Prolicy");
},

manage: true
});
return PrivacyView;
});
10 changes: 7 additions & 3 deletions app/router.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
define(["app/app", "app/cordova.help", "backbone", "app/places/router", "app/today/views/IndexView", "app/today/collections/TodayItems", "app/courses/router", "app/library/router", "app/contacts/router", "app/news/router", "app/events/router", "app/feedback/router", "app/notifications/router", "app/favourites/views/FavouritesEditButtonView", "app/favourites/views/FavouritesView", "app/today/views/EditTodayButton", "app/today/views/SaveTodayButton", "app/today/views/EditTodayView", "app/security/router", "app/student-advice-service/views/StaticView", "app/learning-resources/views/StaticView"],
function(app, cordova, Backbone, PlacesRouter, IndexView, TodayItems, CoursesRouter, LibraryRouter, ContactsRouter, NewsRouter, EventsRouter, FeedbackRouter, NotificationsRouter, FavouritesEditButtonView, FavouritesView, EditTodayButton, SaveTodayButton, EditTodayView, SecurityRouter, StudentAdviceView, LearningResourcesView){
define(["app/app", "app/cordova.help", "backbone", "app/places/router", "app/today/views/IndexView", "app/today/collections/TodayItems", "app/courses/router", "app/library/router", "app/contacts/router", "app/news/router", "app/events/router", "app/feedback/router", "app/notifications/router", "app/favourites/views/FavouritesEditButtonView", "app/favourites/views/FavouritesView", "app/today/views/EditTodayButton", "app/today/views/SaveTodayButton", "app/today/views/EditTodayView", "app/security/router", "app/student-advice-service/views/StaticView", "app/learning-resources/views/StaticView", "app/privacy/views/PrivacyView"],
function(app, cordova, Backbone, PlacesRouter, IndexView, TodayItems, CoursesRouter, LibraryRouter, ContactsRouter, NewsRouter, EventsRouter, FeedbackRouter, NotificationsRouter, FavouritesEditButtonView, FavouritesView, EditTodayButton, SaveTodayButton, EditTodayView, SecurityRouter, StudentAdviceView, LearningResourcesView, PrivacyView){
var MoxieRouter = Backbone.Router.extend({
subrouters: {},

Expand All @@ -24,7 +24,8 @@ define(["app/app", "app/cordova.help", "backbone", "app/places/router", "app/tod
"feedback/*subroute": "feedback",
"notifications/*subroute": "notifications",
"student-advice-service/": "studentAdvice",
"learning-resources/": "learningResources"
"learning-resources/": "learningResources",
"privacy/": "privacy"
},

index: function() {
Expand Down Expand Up @@ -97,6 +98,9 @@ define(["app/app", "app/cordova.help", "backbone", "app/places/router", "app/tod
},
learningResources: function(params) {
app.renderView(new LearningResourcesView(), {menu: true});
},
privacy: function(params) {
app.renderView(new PrivacyView(), {menu: false});
}


Expand Down
8 changes: 6 additions & 2 deletions index-dev.html
Original file line number Diff line number Diff line change
Expand Up @@ -42,8 +42,8 @@
<!-- Included CSS Files -->
<link rel="stylesheet" href="css/app.css">

<script src="app/require.config.js"></script>
<script data-main="main" src="app/libs/require.js"></script>
<script data-main="require.config.js" type="text/javascript" src="app/libs/require.js"></script>


<!-- IE Fix for HTML5 Tags -->
<!--[if lt IE 9]>
Expand Down Expand Up @@ -85,4 +85,8 @@
<img src="images/preloader.gif" class="preloader">
</div>
</div>

<script>
require(['app/main']);
</script>
</body>
6 changes: 3 additions & 3 deletions require.config.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
// Sets the require.js configuration for your application.
var require = {
require.config({
// 3rd party script alias names (Easier to type "jquery" than "libs/jquery-1.7.2.min")
// baseUrl: 'app',
baseUrl: '',
paths: {

// Core Libraries
Expand Down Expand Up @@ -94,4 +94,4 @@ var require = {
disableI18n: true,
helperPathCallback: function(name) {return 'app/templates/helpers/' + name;}
}
};
});

0 comments on commit f47bbdc

Please sign in to comment.