Link fix
This commit is contained in:
@@ -117,13 +117,13 @@ feature -- Access: router
|
|||||||
configure_web (a_api: CMS_API; a_node_api: CMS_NODE_API; a_router: WSF_ROUTER)
|
configure_web (a_api: CMS_API; a_node_api: CMS_NODE_API; a_router: WSF_ROUTER)
|
||||||
local
|
local
|
||||||
l_blog_handler: BLOG_HANDLER
|
l_blog_handler: BLOG_HANDLER
|
||||||
|
l_node_handler: NODE_HANDLER
|
||||||
l_uri_mapping: WSF_URI_MAPPING
|
l_uri_mapping: WSF_URI_MAPPING
|
||||||
do
|
do
|
||||||
-- TODO: for now, focused only on web interface, add REST api later. [2015-May-18]
|
-- TODO: for now, focused only on web interface, add REST api later. [2015-May-18]
|
||||||
create l_blog_handler.make (a_api, a_node_api)
|
create l_blog_handler.make (a_api, a_node_api)
|
||||||
create l_uri_mapping.make_trailing_slash_ignored ("/blogs", l_blog_handler)
|
create l_uri_mapping.make_trailing_slash_ignored ("/blogs", l_blog_handler)
|
||||||
a_router.map_with_request_methods (l_uri_mapping, a_router.methods_get)
|
a_router.map_with_request_methods (l_uri_mapping, a_router.methods_get)
|
||||||
--a_router.handle_with_request_methods ("/node/{id}", l_node_handler, a_router.methods_get)
|
|
||||||
end
|
end
|
||||||
|
|
||||||
feature -- Hooks
|
feature -- Hooks
|
||||||
|
|||||||
@@ -47,7 +47,7 @@ feature -- HTTP Methods
|
|||||||
lnk := node_api.node_link (n)
|
lnk := node_api.node_link (n)
|
||||||
s.append ("<li class=%"cms_type_"+ n.content_type +"%">")
|
s.append ("<li class=%"cms_type_"+ n.content_type +"%">")
|
||||||
s.append (l_page.link (lnk.title, lnk.location, Void))
|
s.append (l_page.link (lnk.title, lnk.location, Void))
|
||||||
-- s.append (l_page.link (n.title + " (#" + n.id.out + ")", node_api.node_path (n), Void))
|
--s.append (l_page.link (n.title + " (#" + n.id.out + ")", node_api.node_path (n), Void))
|
||||||
s.append ("</li>%N")
|
s.append ("</li>%N")
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|||||||
@@ -273,7 +273,7 @@ feature -- Path aliases
|
|||||||
do
|
do
|
||||||
Result := a_source
|
Result := a_source
|
||||||
if attached storage.path_alias (Result) as l_path then
|
if attached storage.path_alias (Result) as l_path then
|
||||||
Result := l_path
|
Result := "/" + l_path
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user