You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cmda.apache.org by xi...@apache.org on 2015/09/05 02:20:15 UTC

[11/50] [abbrv] incubator-cmda git commit: Remove sensor home page

Remove sensor home page

Project: http://git-wip-us.apache.org/repos/asf/incubator-cmda/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-cmda/commit/cabc2e67
Tree: http://git-wip-us.apache.org/repos/asf/incubator-cmda/tree/cabc2e67
Diff: http://git-wip-us.apache.org/repos/asf/incubator-cmda/diff/cabc2e67

Branch: refs/heads/master
Commit: cabc2e67fb9ee6970804dd64a10cf19572e4dfdf
Parents: 253db35
Author: mingqi830 <mq...@andrew.cmu.edu>
Authored: Wed Sep 2 16:44:49 2015 -0700
Committer: mingqi830 <mq...@andrew.cmu.edu>
Committed: Wed Sep 2 16:44:49 2015 -0700

----------------------------------------------------------------------
 app/controllers/Secured.java      | 43 ---------------
 app/views/bugReporting.scala.html | 51 ------------------
 app/views/bugs.scala.html         | 76 --------------------------
 app/views/header.scala.html       | 38 -------------
 app/views/index.scala.html        | 75 ++------------------------
 app/views/login.scala.html        | 34 ------------
 app/views/main.scala.html         | 98 ++++------------------------------
 app/views/sayHello.scala.html     |  4 --
 8 files changed, 15 insertions(+), 404 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-cmda/blob/cabc2e67/app/controllers/Secured.java
----------------------------------------------------------------------
diff --git a/app/controllers/Secured.java b/app/controllers/Secured.java
deleted file mode 100644
index 9be6c60..0000000
--- a/app/controllers/Secured.java
+++ /dev/null
@@ -1,43 +0,0 @@
-/*
- * Copyright (c) 2013 Carnegie Mellon University Silicon Valley. 
- * All rights reserved. 
- * 
- * This program and the accompanying materials are made available
- * under the terms of dual licensing(GPL V2 for Research/Education
- * purposes). GNU Public License v2.0 which accompanies this distribution
- * is available at http://www.gnu.org/licenses/old-licenses/gpl-2.0.html
- * This program is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. 
- * 
- * Please contact http://www.cmu.edu/silicon-valley/ if you have any 
- * questions.
- * 
- * */
-package controllers;
-
-import play.mvc.*;
-import play.mvc.Http.*;
-
-
-public class Secured extends Security.Authenticator {
-    
-    @Override
-    public String getUsername(Context ctx) {
-        return ctx.session().get("email");
-    }
-    
-    @Override
-    public Result onUnauthorized(Context ctx) {
-        return redirect(routes.Application.login());
-    }
-
-    // Access rights
-//    public static boolean isLoggedIn() {
-//    	if(Context.current().request().username().equals("admin@admin.com"))
-//    		return true;
-//    	else
-//    		return false;
-//    }
-    
-}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/incubator-cmda/blob/cabc2e67/app/views/bugReporting.scala.html
----------------------------------------------------------------------
diff --git a/app/views/bugReporting.scala.html b/app/views/bugReporting.scala.html
deleted file mode 100644
index f893144..0000000
--- a/app/views/bugReporting.scala.html
+++ /dev/null
@@ -1,51 +0,0 @@
-@(bugReportForm: play.data.Form[BugReport])
-
-@import helper._
-@import helper.twitterBootstrap._
-
-@main("Bug Report") {
-    
-    @flash_message()
-        
-    @helper.form(action = routes.BugReportController.newReport) {
-        
-        <fieldset>
-            <legend>Bug Report</legend>
-            
-            @inputText(
-                bugReportForm("name"), 
-                '_label -> "Your name",                 
-                '_error -> bugReportForm.globalError                                
-            )
-            @inputText(
-                bugReportForm("title"), 
-                '_label -> "Bug Title",                 
-                '_error -> bugReportForm.globalError                                
-            )
-            @inputText(
-                bugReportForm("email"), 
-                '_label -> "Email",
-                '_helper -> "You must be a registered user to report a bug",                 
-                '_error -> bugReportForm.globalError                                
-            )
-            @inputText(
-                bugReportForm("organization"), 
-                '_label -> "Organization",                 
-                '_error -> bugReportForm.globalError                                
-            )
-            @textarea(
-                bugReportForm("description"), 
-                '_label -> "Description", 'cols -> 65, 'rows -> 7                                               
-            )
-           
-        </fieldset>
-        
-      
-        <div class="actions">
-            <input type="submit" class="btn primary" value="Submit">
-            <a href="@routes.Application.index" class="btn">Cancel</a>
-        </div>
-        
-    }
-    
-}

http://git-wip-us.apache.org/repos/asf/incubator-cmda/blob/cabc2e67/app/views/bugs.scala.html
----------------------------------------------------------------------
diff --git a/app/views/bugs.scala.html b/app/views/bugs.scala.html
deleted file mode 100644
index 3c6d574..0000000
--- a/app/views/bugs.scala.html
+++ /dev/null
@@ -1,76 +0,0 @@
-
-@(bugReports: LinkedList[BugReport])
-
-@import helper._
-
-@main("Bug Reports") {
-    
-    @flash_message()
-        
-    <h1> Bug Reports(s)</h1>
-		<table class="table table-striped table-bordered ">
-			<thead ">
-			<tr>
-	    	  <td>Solved</td>
-	    	  <td>Report Title</td>
-	    	  <td>Reporter Name</td>
-	    	  <td>Reporter's email</td>
-	    	  <td>Reporter's organization</td>
-	    	  <td>Bug content</td>
-	    	  <td>Operation</td>
-	        </tr>
-			</thead>
-			
-			<tbody>
-            <tr>
-               @for(bugReport <- bugReports) {
-                    <tr>
-                    	<td>
-                    		@{if(bugReport.getSolved()==1){"Yes"}
-                    			else{"No"}
-                    		}
-                    			
-                    	</td>
-                        <td>
-                            @bugReport.getTitle()
-                        </td>
-                        <td> 
-                            @bugReport.getName()
-                        </td>
-                        <td> 
-                            @bugReport.getEmail()
-                        </td>
-                        <td> 
-                            @bugReport.getOrganization()
-                        </td>
-                        <td> 
-                            @bugReport.getDescription()
-                        </td>
-                        
-                        
-                        <td>
-                        <div class="input-group input-group-sm">
-                        <span>
-						@form(routes.BugReportController.solveReport()){
-               		 		<input name="idHolder" type="hidden" value="@bugReport.getId()">
-        					<input type="submit"  class="btn btn-success" value="Solve" onclick="return confirm('Are you sure you want to solve this issue?')">
-        				}	
-        				</span>
-                        <span>
-						@form(routes.BugReportController.deleteReport()){
-               		 		<input name="idHolder" type="hidden" value="@bugReport.getId()">
-        					<input type="submit"  class="btn btn-danger" value="Delete" onclick="return confirm('Are you sure you want to delete this issue?')">
-        				}	
-        				</span>
-        				</div>
-           				
-						
-						</td>
-                    </tr>
-                }
-            </tr>
-            </tbody>
-
-    </table>
-    
-}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/incubator-cmda/blob/cabc2e67/app/views/header.scala.html
----------------------------------------------------------------------
diff --git a/app/views/header.scala.html b/app/views/header.scala.html
deleted file mode 100644
index 798a72e..0000000
--- a/app/views/header.scala.html
+++ /dev/null
@@ -1,38 +0,0 @@
-
-@()
-	<div class="navbar navbar-default navbar-fixed-top" role="navigation">
-		<div class="container">
-			<div class="navbar-header">
-				<button type="button" class="navbar-toggle" data-toggle="collapse"
-					data-target=".navbar-collapse">
-					<span class="sr-only">Toggle navigation</span> <span
-						class="icon-bar"></span> <span class="icon-bar"></span> <span
-						class="icon-bar"></span>
-				</button>
-				<a class="navbar-brand" style="padding-bottom: 0;" href="/"><img
-					src='@routes.Assets.at("images/NASA_JPL_logo.png")' style="height: 30px; width: 180px;">&nbsp&nbsp<img
-					src='@routes.Assets.at("images/logo.png")' style="height: 15px; width: 200px;"></a>
-			</div>
-			<div class="navbar-collapse collapse" style="height:">
-				<ul class="nav navbar-nav navbar-right">
-
-					<li><a href="@routes.Application.index()">Home</a></li>				
-											
-					<li><a href="@routes.AboutusController.aboutus()">About Us</a></li>
-
-					@if(!session.get("email")){
-					
-						<form class="navbar-form navbar-right" action="@routes.Application.login()">
-							<button type="submit" class="btn btn-success">Sign in</button>
-						</form>
-					}else{
-						<form class="navbar-form navbar-right" action="@routes.Application.logout()">
-							<button type="submit" class="btn btn-success">Log out</button>
-						</form>
-					}
-					
-				</ul>
-			</div>
-			<!--/.nav-collapse -->
-		</div>
-	</div>

http://git-wip-us.apache.org/repos/asf/incubator-cmda/blob/cabc2e67/app/views/index.scala.html
----------------------------------------------------------------------
diff --git a/app/views/index.scala.html b/app/views/index.scala.html
index f7dd2e9..adb4b31 100644
--- a/app/views/index.scala.html
+++ b/app/views/index.scala.html
@@ -1,74 +1,7 @@
+@(message: String)
 
-@import helper._ 
+@main("Welcome to Play") {
 
-@main("Carnegie Mellon University Sensor Data Storage"){
+    @play20.welcome(message, style = "Java")
 
-	<div class="jumbotron">
-		<div class="row">
-			<div class="col-lg-6">
-
-				<img src='@routes.Assets.at("images/fireimp_small.jpg")' style="padding-bottom: 0;">
-
-			</div>
-			<div class="col-lg-6">
-				<h1>Internet of Things Data Service Platform</h1>
-				<p>A federated cloud platform for mobile data-centric service
-					development and sharing.</p>
-				<p>
-					<a class="btn btn-lg btn-default"
-						href="https://drive.google.com/file/d/0B9nWqnYxEA3HSEo3Zkx2QWJEVlE/edit?usp=sharing">Getting Started &raquo;</a>
-				</p>
-			</div>
-		</div>
-	</div>
-
-	<!-- Content -->
-	<div class="row">
-		<div class="col-lg-4">
-			<h2>Tutorial</h2>
-			<p>
-			Here is a simple guide on <a 
-				href="https://drive.google.com/file/d/0B0uwbnoOCGhEWGVuZjMtcDljcFE/edit?usp=sharing"
-				>how to use the platform</a>.
-			</p>
-		</div>
-		<div class="col-lg-4">
-			<h2>Visualization</h2>
-			<p>
-				A <a href="http://sensorserviceplatform.github.io/Visualization/">visualization</a> of the sensor network.
-			</p>
-		</div>
-		<div class="col-lg-4">
-			<h2>Virtual Sensor</h2>
-			<p>
-				A <a href="http://sensorserviceplatform.github.io/VirtualSensorEditor/">virtual sensor</a> tour.
-			</p>
-		</div>
-	</div>
-	<div class="row">
-		<div class="col-lg-4">
-			<h2>Open Source</h2>
-			<p>
-				All the code is currently hosted on Github. Feel free to contribute
-				to this <a href="https://github.com/cmusv-sc">community</a>.
-			</p>
-		</div>
-		<div class="col-lg-4">
-			<h2>To Dos</h2>
-			<p>
-				Check the open <a
-					href="https://github.com/cmusv-sc/ArchF2013-Project3-FT/issues?page=1&state=open">issues</a>
-				on Github.
-			</p>
-		</div>
-		<div class="col-lg-4">
-			<h2>More information</h2>
-			<p>
-				For more information about this project, and a good general
-				overview, see the <a
-					href="https://docs.google.com/open?id=0B6VEjpK6RPgVN2Q1aDhRRjJid0U">slide
-					deck</a> covering relevant features.
-			</p>
-		</div>
-	</div>
-}
+}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/incubator-cmda/blob/cabc2e67/app/views/login.scala.html
----------------------------------------------------------------------
diff --git a/app/views/login.scala.html b/app/views/login.scala.html
deleted file mode 100644
index d5a58a4..0000000
--- a/app/views/login.scala.html
+++ /dev/null
@@ -1,34 +0,0 @@
-@(form: Form[Application.Login])
-
-@main("Login") {  
-    
-    @helper.form(routes.Application.authenticate) {
-        
-        <h1>Sign in</h1>
-        
-        @if(form.hasGlobalErrors) { 
-            <p class="error">
-                @form.globalError.message
-            </p>
-        }
-        
-        @if(flash.contains("success")) {
-            <p class="success">
-                @flash.get("success")
-            </p>
-        }
-        
-        <p>
-            <input type="email" name="email" placeholder="Email" value="@form("email").value">
-        </p>
-
-        <p>
-            <input type="password" name="password" placeholder="Password">
-        </p>
-        <p>
-            <button type="submit" class="btn btn-primary">Login</button>
-        </p>
-        }
-}
-    
-

http://git-wip-us.apache.org/repos/asf/incubator-cmda/blob/cabc2e67/app/views/main.scala.html
----------------------------------------------------------------------
diff --git a/app/views/main.scala.html b/app/views/main.scala.html
index a7e43d3..e919a4c 100644
--- a/app/views/main.scala.html
+++ b/app/views/main.scala.html
@@ -1,91 +1,15 @@
-@(title: String, moreScripts: Html = Html(""))(content: Html) 
-
+@(title: String)(content: Html)
 
 <!DOCTYPE html>
 
 <html>
-<head>
-
-<title>@title</title>
-<meta charset="utf-8">
-<meta http-equiv="X-UA-Compatible" content="IE=edge">
-<meta name="viewport" content="width=device-width, initial-scale=1.0">
-
-<link rel="stylesheet"
-	href='@routes.Assets.at("stylesheets/bootstrap.css")'>
-<link rel="stylesheet"
-	href='@routes.Assets.at("stylesheets/navbar-fixed-top.css")'>
-<link rel="stylesheet"
-	href='@routes.Assets.at("stylesheets/custom.css")'>
-<link rel="stylesheet" media="screen"
-	href='@routes.Assets.at("stylesheets/main.css")'>
-<link rel="shortcut icon" type="image/png"
-	href='@routes.Assets.at("images/favicon.png")'>
-
-
-
-<link
-	href='@routes.Assets.at("stylesheets/bootstrap-editable.css")'
-	rel="stylesheet" />
-<!--[if (!IE)|(gte IE 8)]><!-->
-  <link href='@routes.Assets.at("stylesheets/visualsearch-datauri.css")' media="screen" rel="stylesheet" type="text/css" />
-<!--<![endif]-->
-<!--[if lte IE 7]><!-->
-  <link href='@routes.Assets.at("stylesheets/visualsearch.css")' media="screen" rel="stylesheet" type="text/css" />
-<!--<![endif]-->
-
-<script src='@routes.Assets.at("javascripts/jquery-1.9.0.min.js")'
-	type="text/javascript"></script>
-<script src='@routes.Assets.at("javascripts/jquery-ui-1.10.4.min.js")'
-	type="text/javascript"></script>
-	
-<script src='@routes.Assets.at("javascripts/bootstrap.min.js")'
-	type="text/javascript"></script>
-<script src='@routes.Assets.at("javascripts/bootstrap-editable.min.js")' 
-	type="text/javascript"></script>
-	
-<script src='@routes.Assets.at("javascripts/underscore-1.5.2.js")' 
-	type="text/javascript"></script>
-<script src='@routes.Assets.at("javascripts/backbone-1.1.0.js")' 
-	type="text/javascript"></script>
-<script src='@routes.Assets.at("javascripts/visualsearch.js")' 
-	type="text/javascript"></script>
-@moreScripts
-</head>
-
-<body>
-	@header()
-	<div class="container">
-
-		@content
-
-		<!-- Footer -->
-		<div class="footer">
-			<div class="row">
-				<div class="col-md-4">
-					<div class="row">
-						<p class="text-muted" style="text-align: left;"https://github.com/sdscmusv">
-							<img src='@routes.Assets.at("images/github.png")'
-								style="width: 32px;"></a> Follow and contribute to this
-							project on <a href="https://github.com/cmusv-sc/ArchF2013-Project3-FT">Github</a>
-						</p>
-					</div>
-					<div class="row">
-						<p class="text-muted" style="text-align: left;"@routes.BugReportController.reports()">
-							<img src='@routes.Assets.at("images/bug.png")'
-								style="width: 32px;"></a> Any issues? Please report bugs <a
-								href="@routes.BugReportController.reports()">here</a>
-						</p>
-					</div>
-				</div>
-				<div class="col-lg-6 col-lg-offset-3">
-					<p class="text-muted" style="text-align: right; font-size: 14px;">&copy;
-						Carnegie Mellon University - Silicon Valley ; NASA Jet Propulsion Laboratory 2015</p>
-				</div>
-			</div>
-		</div>
-
-	</div>
-
-</body>
-</html>
+    <head>
+        <title>@title</title>
+        <link rel="stylesheet" media="screen" href="@routes.Assets.at("stylesheets/main.css")">
+        <link rel="shortcut icon" type="image/png" href="@routes.Assets.at("images/favicon.png")">
+        <script src="@routes.Assets.at("javascripts/hello.js")" type="text/javascript"></script>
+    </head>
+    <body>
+        @content
+    </body>
+</html>
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/incubator-cmda/blob/cabc2e67/app/views/sayHello.scala.html
----------------------------------------------------------------------
diff --git a/app/views/sayHello.scala.html b/app/views/sayHello.scala.html
deleted file mode 100644
index a1ff218..0000000
--- a/app/views/sayHello.scala.html
+++ /dev/null
@@ -1,4 +0,0 @@
-@(name: String)
-@main("Say Hello"){
-	<p>Welcome  --> @{name}</p>
-}
\ No newline at end of file