pkd
12/8/2014 - 9:03 AM

bootstrap3_collapsible_element.xml

tt_content.gridelements_pi1.20.10.setup.uebb_bootstrap_collapsible_element {

  # Build: <div class="panel-heading">|</div>
	innerWrap.cObject = COA
	innerWrap.cObject {
		wrap = <div class="panel-heading">|</div>

		10 < lib.stdheader
		10.3.headerClass.cObject.928374 = TEXT
		10.3.headerClass.cObject.928374 {
			value = panel-title
			noTrimWrap = | | |
		}
		10.10.setCurrent.typolink {
			parameter >
			parameter = #collapse-{field: uid}
			parameter.insertData = 1
			ATagParams = class="accordion-toggle" data-toggle="collapse" data-parent="#collapsible-{field: parentgrid_uid}"
			ATagParams.insertData = 1
		}
	}

	# Build: <div class="panel panel-[default,primary,success,...]">|</div>
	outerWrap = <div class="panel {field: flexform_style}">|</div>
	outerWrap.insertData = 1

	# Build: <div id="collapse-[panel-uid]" class="panel-collapse collapse [in]">|</div>
	columns.0 {
		renderObj = < tt_content

		wrap.cObject = COA
		wrap.cObject {

			10 = COA
			10 {
				10 = TEXT
				10.wrap = <div id="collapse-|"
				10.field = uid

				20 = TEXT
				20.value = class="panel-collapse collapse
				20.noTrimWrap = | ||

				30 = TEXT
				30.value = in
				30.noTrimWrap = | ||
				30.if {
					value = 1
					equals.field = flexform_active
				}

				40 = TEXT
				40.value = ">
			}

			20 = TEXT
			20.value = <div class="panel-body">|</div></div>
		}

	}
}

tt_content.gridelements_pi1.20.10.setup.uebb_bootstrap_collapsible_container {
	# Wrap collapsible
	# Build: <div class="panel-group" id="collapsible-[container-uid]">|</div>
	outerWrap = <div class="panel-group" id="collapsible-{field: uid}">|</div>
	outerWrap.insertData = 1

	# Direct rendering of the collapsible elements, prevents "csc-default"-wrap
	columns.0 {
		renderObj < tt_content.gridelements_pi1
	}

}
# Collapsible Container
tx_gridelements.setup.uebb_bootstrap_collapsible_container {
  title = Collapsible Container
	description = Ein Element das mehrere Collapsible enthält

	config {
		colCount = 1
		rowCount = 1

		rows {
			1 {
				columns {
					1 {
						name = Collapsible Container
						colPos = 0
						allowed = gridelements_pi1
					}
				}
			}
		}
	}
}

# Collapsible Element
tx_gridelements.setup.uebb_bootstrap_collapsible_element {
  title = Collapsible Element
	description = Ein Element für einen Collapsible-Container
	flexformDS = FILE:fileadmin/templates/gridelements/bootstrap3_collapse/bootstrap3_collapsible_element.xml

	config {
		colCount = 1
		rowCount = 1

		rows {
			1 {
				columns {
					1 {
						name = Collapsible Element
						colPos = 0
					}
				}
			}
		}
	}
}
<?xml version="1.0" encoding="utf-8" standalone="yes" ?>
<T3DataStructure>
  <meta type="array">
		<langDisable>1</langDisable>
	</meta>
	<sheets>
		<general>
			<ROOT type="array">
				<TCEforms>
					<sheetTitle>Einstellungen</sheetTitle>
				</TCEforms>
				<el type="array">
					<active type="array">
						<TCEforms type="array">
							<label>Aktiv</label>
							<config type="array">
								<type>check</type>
							</config>
						</TCEforms>
					</active>
					<style type="array">
						<TCEforms type="array">
							<label>Aussehen</label>
							<config type="array">
								<type>select</type>
								<items type="array">
									<numIndex index="0" type="array"><numIndex index="0">Standard</numIndex><numIndex index="1">panel-default</numIndex></numIndex>
									<numIndex index="1" type="array"><numIndex index="0">Wichtig (primary)</numIndex><numIndex index="1">panel-primary</numIndex></numIndex>
									<numIndex index="2" type="array"><numIndex index="0">Erfolgreich (success)</numIndex><numIndex index="1">panel-success</numIndex></numIndex>
									<numIndex index="3" type="array"><numIndex index="0">Information (info)</numIndex><numIndex index="1">panel-info</numIndex></numIndex>
									<numIndex index="4" type="array"><numIndex index="0">Warnung (warning)</numIndex><numIndex index="1">panel-warning</numIndex></numIndex>
									<numIndex index="5" type="array"><numIndex index="0">Vorsicht (danger)</numIndex><numIndex index="1">panel-danger</numIndex></numIndex>
								</items>
								<default>panel-default</default>
							</config>
						</TCEforms>
					</style>
				</el>
			</ROOT>
		</general>
	</sheets>
</T3DataStructure>