Travis Odom avatar Travis Odom committed 91ccd65 Draft

Formatting fixes, design tweaks

Comments (0)

Files changed (6)

priv/static/css/date.css

     display:block;
     width:20px;
     height:20px;
-    background:transparent url(/media/img/dateinput/prev.gif) no-repeat scroll center center;
+    background:transparent url(/static/images/prev.gif) no-repeat scroll center center;
     float:left;
     cursor:pointer;
 }
 
 #calnext {
-    background-image:url(/media/img/dateinput/next.gif);
+    background-image:url(/static/images/next.gif);
     float:right;
 }
 
Add a comment to this file

priv/static/images/next.gif

Added
New image
Add a comment to this file

priv/static/images/prev.gif

Added
New image

src/controller/lsdg_site_main_controller.erl

 editannounce('POST', [], AdminUser) ->
 	Incoming = Req:post_param("ann_text"),
 	T = io_lib:format("~p-~2..0B-~2..0B", tuple_to_list(date())),
-	NewAnn = announcement:new(id, Incoming, lists:flatten(T), now()),
+	NewAnn = announcement:new(id, lists:flatten(Incoming), lists:flatten(T), now()),
 	{ok, SavedAnn} = NewAnn:save(),
 	{redirect, [{action, "editannounce"}]};
 
 	DateIn = Req:post_param("event_date"),
 	DescIn = Req:post_param("event_description"),
 	Make = Req:post_param("makeannounce"),
-	NewEvent = event:new(id, NameIn, DateIn, DescIn),
+	NewEvent = event:new(id, NameIn, DateIn, lists:flatten(DescIn)),
 	{ok, SavedEvent} = NewEvent:save(),
 	if Make =:= "make" ->
 		T = io_lib:format("~p-~2..0B-~2..0B", tuple_to_list(date())),
-		AnnText = lists:flatten(io_lib:format("Event: ~p - ~p: ~p", [DateIn, NameIn, DescIn])),
+		AnnText = lists:flatten(io_lib:format("Event: ~s - ~s: ~s", [DateIn, NameIn, DescIn])),
 		Strip = lists:filter(fun(X) -> case X of 34 -> false; _ -> true end end, AnnText),
-		NewAnn = announcement:new(id, Strip, lists:flatten(T), now()),
+		NewAnn = announcement:new(id, AnnText, lists:flatten(T), now()),
 		{ok, SavedAnn} = NewAnn:save();
 		true -> ok
 	end,

src/view/main/eventdetail.html

 {% block content %}
 <h2>Event Detail</h2><br>
 	{% if selected %}
-	<table style="max-width: 650px;">
+	<table style="max-width: 650px; margin-bottom: 15px;">
 		<tr>
 			<td class="fields">Name: </td>
 			<td>{{ selected.name }}</td>

src/view/main/listevent.html

 {% block content %}
 <h2>All Events</h2>
 <ul style="list-style: none;">
-{% for item in events %}
+{% for item in listevents %}
 <li style="clear: both;">
-	<table style="max-width: 650px;">
+	<table style="max-width: 600px;">
 		<tr>
 			<td class="fields">Name: </td>
 			<td>{{ item.name }}</td>
Tip: Filter by directory path e.g. /media app.js to search for public/media/app.js.
Tip: Use camelCasing e.g. ProjME to search for ProjectModifiedEvent.java.
Tip: Filter by extension type e.g. /repo .js to search for all .js files in the /repo directory.
Tip: Separate your search with spaces e.g. /ssh pom.xml to search for src/ssh/pom.xml.
Tip: Use ↑ and ↓ arrow keys to navigate and return to view the file.
Tip: You can also navigate files with Ctrl+j (next) and Ctrl+k (previous) and view the file with Ctrl+o.
Tip: You can also navigate files with Alt+j (next) and Alt+k (previous) and view the file with Alt+o.