diff src/nabble/view/naml/change_app_type.naml @ 0:7ecd1a4ef557

add content
author Franklin Schmidt <fschmidt@gmail.com>
date Thu, 21 Mar 2019 19:15:52 -0600
parents
children
line wrap: on
line diff
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/src/nabble/view/naml/change_app_type.naml	Thu Mar 21 19:15:52 2019 -0600
@@ -0,0 +1,57 @@
+<macro name="change_app_type" requires="servlet">
+	<n.node_page.>
+		<n.if.not.visitor.can_edit.page_node>
+			<then>
+				<n.login.><t>Only authorized users can proceed in this area.</t></n.login.>
+			</then>
+		</n.if.not.visitor.can_edit.page_node>
+		<n.if.not.is_submitted_form>
+			<then>
+				<n.type_field.set_value value="[n.page_node.type/]" />
+			</then>
+			<else>
+				<n.catch_exception. id="save-block">
+					<n.edit_page_node.>
+						<n.set_type type="[n.type_field.value/]" />
+						<n.save_node/>
+					</n.edit_page_node.>
+					<n.redirect_to.page_node.path/>
+				</n.catch_exception.>
+			</else>
+		</n.if.not.is_submitted_form>
+		<n.html>
+			<head>
+				<META NAME="robots" CONTENT="noindex,nofollow"/>
+				<n.title.><t>Change Application Type</t></n.title.>
+			</head>
+			<body>
+				<n.edit_header first_text="[t]Change Application Type[/t]" second_text="[n.page_node.get_app_node.subject/]" />
+
+				<n.form.>
+					<n.type_option option_value="forum" text="[t]Forum[/t]" description="[t]Page with topics and discussions.[/t]"/>
+					<n.type_option option_value="mixed" text="[t]Mixed[/t]" description="[t]Page with topics grouped by sub-applications. If no sub-apps exist, a normal list of topics is displayed.[/t]"/>
+					<n.type_option option_value="category" text="[t]Category[/t]" description="[t]Page with a simple list of sub-applications and discussions.[/t]"/>
+					<n.type_option option_value="board" text="[t]Board[/t]" description="[t]Page that groups sub-applications and discussions.[/t]"/>
+					<n.type_option option_value="gallery" text="[t]Gallery[/t]" description="[t]Photo and image gallery.[/t]"/>
+					<n.type_option option_value="blog" text="[t]Blog[/t]" description="[t]Page with full messages and related comments.[/t]"/>
+					<n.type_option option_value="news" text="[t]News[/t]" description="[t]Page with headlines and posts.[/t]"/>
+
+					<div style="margin-top:1.4em">
+						<input type="submit" class="toolbar action-button" value="[t]Save Changes[/t]" />
+						<t>or</t> <a href="[n.page_node.path/]"><t>Cancel</t></a>
+					</div>
+				</n.form.>
+			</body>
+		</n.html>
+	</n.node_page.>
+</macro>
+
+<macro name="type_option" parameters="option_value,text,description">
+	<div class="second-font field-title" style="margin-top:1em">
+		<n.type_field.radio id="[n.option_value/]" option_value="[n.option_value/]"/>
+		<label for="[n.option_value/]"><n.text/></label>
+	</div>
+	<div class="weak-color" style="margin-left:1.9em">
+		<n.description/>
+	</div>
+</macro>
\ No newline at end of file