<?php
			$optionsArray = array(
	'master' => array(
		'sales' => array(
			'preview' => false 
		) 
	),
	'captcha' => array(
		'captcha' => false 
	),
	'fields' => array(
		'gridFields' => array( 
			'item_id',
			'description',
			'uom_code',
			'quantity',
			'unit_price',
			'commercial_discount_rate',
			'commercial_discount_amount',
			'discount_type_id',
			'statutory_discount_rate',
			'statutory_discount_amount',
			'vat_tax_code_id',
			'withholding_tax_code_id',
			'warehouse_id',
			'department_id',
			'cost_center_id',
			'project_id',
			'project_task_id',
			'sales_agent_id',
			'campaign_id',
			'vat_rate_snapshot' 
		),
		'searchRequiredFields' => array( 
			 
		),
		'searchPanelFields' => array( 
			 
		),
		'fieldItems' => array(
			'item_id' => array( 
				'integrated_edit_field3' 
			),
			'description' => array( 
				'integrated_edit_field5' 
			),
			'uom_code' => array( 
				'integrated_edit_field6' 
			),
			'quantity' => array( 
				'integrated_edit_field7' 
			),
			'unit_price' => array( 
				'integrated_edit_field8' 
			),
			'commercial_discount_rate' => array( 
				'integrated_edit_field10' 
			),
			'commercial_discount_amount' => array( 
				'integrated_edit_field11' 
			),
			'discount_type_id' => array( 
				'integrated_edit_field12' 
			),
			'statutory_discount_rate' => array( 
				'integrated_edit_field13' 
			),
			'statutory_discount_amount' => array( 
				'integrated_edit_field14' 
			),
			'vat_tax_code_id' => array( 
				'integrated_edit_field16' 
			),
			'withholding_tax_code_id' => array( 
				'integrated_edit_field22' 
			),
			'warehouse_id' => array( 
				'integrated_edit_field27' 
			),
			'department_id' => array( 
				'integrated_edit_field28' 
			),
			'cost_center_id' => array( 
				'integrated_edit_field29' 
			),
			'project_id' => array( 
				'integrated_edit_field30' 
			),
			'project_task_id' => array( 
				'integrated_edit_field31' 
			),
			'sales_agent_id' => array( 
				'integrated_edit_field32' 
			),
			'campaign_id' => array( 
				'integrated_edit_field33' 
			),
			'vat_rate_snapshot' => array( 
				'integrated_edit_field1' 
			) 
		) 
	),
	'pageLinks' => array(
		'edit' => false,
		'add' => false,
		'view' => false,
		'print' => false 
	),
	'layoutHelper' => array(
		'formItems' => array(
			'formItems' => array(
				'above-grid' => array( 
					'add_message' 
				),
				'below-grid' => array( 
					'add_save',
					'add_reset',
					'add_back_list',
					'add_cancel' 
				),
				'top' => array( 
					'add_header' 
				),
				'grid' => array( 
					'section',
					'section1',
					'section3',
					'section4' 
				),
				'section' => array( 
					'integrated_edit_field3',
					'integrated_edit_field5',
					'integrated_edit_field6' 
				),
				'section1' => array( 
					'integrated_edit_field7',
					'integrated_edit_field8' 
				),
				'section3' => array( 
					'integrated_edit_field16',
					'integrated_edit_field1',
					'integrated_edit_field22' 
				),
				'section4' => array( 
					'integrated_edit_field27',
					'integrated_edit_field28',
					'integrated_edit_field29',
					'integrated_edit_field30',
					'integrated_edit_field31',
					'integrated_edit_field32',
					'integrated_edit_field33',
					'integrated_edit_field10',
					'integrated_edit_field11',
					'integrated_edit_field12',
					'integrated_edit_field13',
					'integrated_edit_field14' 
				) 
			),
			'formXtTags' => array(
				'above-grid' => array( 
					'message_block' 
				) 
			),
			'itemForms' => array(
				'add_message' => 'above-grid',
				'add_save' => 'below-grid',
				'add_reset' => 'below-grid',
				'add_back_list' => 'below-grid',
				'add_cancel' => 'below-grid',
				'add_header' => 'top',
				'section' => 'grid',
				'section1' => 'grid',
				'section3' => 'grid',
				'section4' => 'grid',
				'integrated_edit_field3' => 'section',
				'integrated_edit_field5' => 'section',
				'integrated_edit_field6' => 'section',
				'integrated_edit_field7' => 'section1',
				'integrated_edit_field8' => 'section1',
				'integrated_edit_field16' => 'section3',
				'integrated_edit_field1' => 'section3',
				'integrated_edit_field22' => 'section3',
				'integrated_edit_field27' => 'section4',
				'integrated_edit_field28' => 'section4',
				'integrated_edit_field29' => 'section4',
				'integrated_edit_field30' => 'section4',
				'integrated_edit_field31' => 'section4',
				'integrated_edit_field32' => 'section4',
				'integrated_edit_field33' => 'section4',
				'integrated_edit_field10' => 'section4',
				'integrated_edit_field11' => 'section4',
				'integrated_edit_field12' => 'section4',
				'integrated_edit_field13' => 'section4',
				'integrated_edit_field14' => 'section4' 
			),
			'itemLocations' => array(
				'section' => array(
					'location' => 'grid',
					'cellId' => 'c3' 
				),
				'section1' => array(
					'location' => 'grid',
					'cellId' => 'c3' 
				),
				'section3' => array(
					'location' => 'grid',
					'cellId' => 'c3' 
				),
				'section4' => array(
					'location' => 'grid',
					'cellId' => 'c' 
				),
				'integrated_edit_field3' => array(
					'location' => 'section',
					'cellId' => 'c1' 
				),
				'integrated_edit_field5' => array(
					'location' => 'section',
					'cellId' => 'c1' 
				),
				'integrated_edit_field6' => array(
					'location' => 'section',
					'cellId' => 'c1' 
				),
				'integrated_edit_field7' => array(
					'location' => 'section1',
					'cellId' => 'c1' 
				),
				'integrated_edit_field8' => array(
					'location' => 'section1',
					'cellId' => 'c1' 
				),
				'integrated_edit_field16' => array(
					'location' => 'section3',
					'cellId' => 'c1' 
				),
				'integrated_edit_field1' => array(
					'location' => 'section3',
					'cellId' => 'c1' 
				),
				'integrated_edit_field22' => array(
					'location' => 'section3',
					'cellId' => 'c1' 
				),
				'integrated_edit_field27' => array(
					'location' => 'section4',
					'cellId' => 'c1' 
				),
				'integrated_edit_field28' => array(
					'location' => 'section4',
					'cellId' => 'c1' 
				),
				'integrated_edit_field29' => array(
					'location' => 'section4',
					'cellId' => 'c1' 
				),
				'integrated_edit_field30' => array(
					'location' => 'section4',
					'cellId' => 'c1' 
				),
				'integrated_edit_field31' => array(
					'location' => 'section4',
					'cellId' => 'c1' 
				),
				'integrated_edit_field32' => array(
					'location' => 'section4',
					'cellId' => 'c1' 
				),
				'integrated_edit_field33' => array(
					'location' => 'section4',
					'cellId' => 'c1' 
				),
				'integrated_edit_field10' => array(
					'location' => 'section4',
					'cellId' => 'c1' 
				),
				'integrated_edit_field11' => array(
					'location' => 'section4',
					'cellId' => 'c1' 
				),
				'integrated_edit_field12' => array(
					'location' => 'section4',
					'cellId' => 'c1' 
				),
				'integrated_edit_field13' => array(
					'location' => 'section4',
					'cellId' => 'c1' 
				),
				'integrated_edit_field14' => array(
					'location' => 'section4',
					'cellId' => 'c1' 
				) 
			),
			'itemVisiblity' => array(
				 
			) 
		),
		'itemsByType' => array(
			'add_header' => array( 
				'add_header' 
			),
			'add_back_list' => array( 
				'add_back_list' 
			),
			'add_cancel' => array( 
				'add_cancel' 
			),
			'add_message' => array( 
				'add_message' 
			),
			'add_save' => array( 
				'add_save' 
			),
			'add_reset' => array( 
				'add_reset' 
			),
			'integrated_edit_field' => array( 
				'integrated_edit_field3',
				'integrated_edit_field5',
				'integrated_edit_field6',
				'integrated_edit_field7',
				'integrated_edit_field8',
				'integrated_edit_field10',
				'integrated_edit_field11',
				'integrated_edit_field12',
				'integrated_edit_field13',
				'integrated_edit_field14',
				'integrated_edit_field16',
				'integrated_edit_field22',
				'integrated_edit_field27',
				'integrated_edit_field28',
				'integrated_edit_field29',
				'integrated_edit_field30',
				'integrated_edit_field31',
				'integrated_edit_field32',
				'integrated_edit_field33',
				'integrated_edit_field1' 
			),
			'section' => array( 
				'section',
				'section1',
				'section3',
				'section4' 
			) 
		),
		'cellMaps' => array(
			'grid' => array(
				'cells' => array(
					'c3' => array(
						'cols' => array( 
							0 
						),
						'rows' => array( 
							0 
						),
						'tags' => array( 
							 
						),
						'items' => array( 
							'section',
							'section1',
							'section3' 
						),
						'fixedAtServer' => true,
						'fixedAtClient' => false 
					),
					'c' => array(
						'cols' => array( 
							1 
						),
						'rows' => array( 
							0 
						),
						'tags' => array( 
							 
						),
						'items' => array( 
							'section4' 
						),
						'fixedAtServer' => true,
						'fixedAtClient' => false 
					) 
				),
				'width' => 2,
				'height' => 1 
			),
			'section' => array(
				'cells' => array(
					'c1' => array(
						'cols' => array( 
							0 
						),
						'rows' => array( 
							0 
						),
						'tags' => array( 
							 
						),
						'items' => array( 
							'integrated_edit_field3',
							'integrated_edit_field5',
							'integrated_edit_field6' 
						),
						'fixedAtServer' => true,
						'fixedAtClient' => false 
					) 
				),
				'width' => 1,
				'height' => 1 
			),
			'section1' => array(
				'cells' => array(
					'c1' => array(
						'cols' => array( 
							0 
						),
						'rows' => array( 
							0 
						),
						'tags' => array( 
							 
						),
						'items' => array( 
							'integrated_edit_field7',
							'integrated_edit_field8' 
						),
						'fixedAtServer' => true,
						'fixedAtClient' => false 
					) 
				),
				'width' => 1,
				'height' => 1 
			),
			'section3' => array(
				'cells' => array(
					'c1' => array(
						'cols' => array( 
							0 
						),
						'rows' => array( 
							0 
						),
						'tags' => array( 
							 
						),
						'items' => array( 
							'integrated_edit_field16',
							'integrated_edit_field1',
							'integrated_edit_field22' 
						),
						'fixedAtServer' => true,
						'fixedAtClient' => false 
					) 
				),
				'width' => 1,
				'height' => 1 
			),
			'section4' => array(
				'cells' => array(
					'c1' => array(
						'cols' => array( 
							0 
						),
						'rows' => array( 
							0 
						),
						'tags' => array( 
							 
						),
						'items' => array( 
							'integrated_edit_field27',
							'integrated_edit_field28',
							'integrated_edit_field29',
							'integrated_edit_field30',
							'integrated_edit_field31',
							'integrated_edit_field32',
							'integrated_edit_field33',
							'integrated_edit_field10',
							'integrated_edit_field11',
							'integrated_edit_field12',
							'integrated_edit_field13',
							'integrated_edit_field14' 
						),
						'fixedAtServer' => true,
						'fixedAtClient' => false 
					) 
				),
				'width' => 1,
				'height' => 1 
			) 
		) 
	),
	'loginForm' => array(
		'loginForm' => 3 
	),
	'page' => array(
		'verticalBar' => false,
		'labeledButtons' => array(
			'update_records' => array(
				 
			),
			'print_pages' => array(
				 
			),
			'register_activate_message' => array(
				 
			),
			'details_found' => array(
				 
			) 
		),
		'hasCustomButtons' => false,
		'customButtons' => array( 
			 
		),
		'codeSnippets' => array( 
			 
		),
		'clickHandlerSnippets' => array( 
			 
		),
		'hasNotifications' => false,
		'menus' => array( 
			 
		),
		'calcTotalsFor' => 1,
		'hasCharts' => false 
	),
	'misc' => array(
		'type' => 'add',
		'breadcrumb' => false 
	),
	'events' => array(
		'maps' => array( 
			 
		),
		'mapsData' => array(
			 
		),
		'buttons' => array( 
			 
		) 
	) 
);
			$pageArray = array(
	'id' => 'add',
	'type' => 'add',
	'layoutId' => 'nomenu',
	'disabled' => false,
	'default' => 0,
	'forms' => array(
		'above-grid' => array(
			'modelId' => 'add-above-grid',
			'grid' => array( 
				array(
					'cells' => array( 
						array(
							'cell' => 'c1' 
						) 
					),
					'section' => '' 
				) 
			),
			'cells' => array(
				'c1' => array(
					'model' => 'c1',
					'items' => array( 
						'add_message' 
					) 
				) 
			),
			'deferredItems' => array( 
				 
			),
			'recsPerRow' => 1 
		),
		'below-grid' => array(
			'modelId' => 'add-below-grid',
			'grid' => array( 
				array(
					'cells' => array( 
						array(
							'cell' => 'c1' 
						) 
					),
					'section' => '' 
				) 
			),
			'cells' => array(
				'c1' => array(
					'model' => 'c1',
					'items' => array( 
						'add_save',
						'add_reset',
						'add_back_list',
						'add_cancel' 
					) 
				) 
			),
			'deferredItems' => array( 
				 
			),
			'recsPerRow' => 1 
		),
		'top' => array(
			'modelId' => 'add-header',
			'grid' => array( 
				array(
					'cells' => array( 
						array(
							'cell' => 'c1' 
						) 
					),
					'section' => '' 
				) 
			),
			'cells' => array(
				'c1' => array(
					'model' => 'c1',
					'items' => array( 
						'add_header' 
					) 
				) 
			),
			'deferredItems' => array( 
				 
			),
			'recsPerRow' => 1 
		),
		'grid' => array(
			'modelId' => 'simple-edit',
			'grid' => array( 
				array(
					'cells' => array( 
						array(
							'cell' => 'c3' 
						),
						array(
							'cell' => 'c' 
						) 
					),
					'section' => '' 
				) 
			),
			'cells' => array(
				'c3' => array(
					'model' => 'c3',
					'items' => array( 
						'section',
						'section1',
						'section3' 
					) 
				),
				'c' => array(
					'model' => 'c3',
					'items' => array( 
						'section4' 
					) 
				) 
			),
			'deferredItems' => array( 
				 
			),
			'columnCount' => 1,
			'inlineLabels' => false,
			'separateLabels' => false 
		),
		'section' => array(
			'modelId' => 'simple-edit',
			'grid' => array( 
				array(
					'cells' => array( 
						array(
							'cell' => 'c1' 
						) 
					),
					'section' => '' 
				) 
			),
			'cells' => array(
				'c1' => array(
					'model' => 'c1',
					'items' => array( 
						'integrated_edit_field3',
						'integrated_edit_field5',
						'integrated_edit_field6' 
					) 
				) 
			),
			'deferredItems' => array( 
				 
			),
			'columnCount' => 1,
			'inlineLabels' => false,
			'separateLabels' => false 
		),
		'section1' => array(
			'modelId' => 'simple-edit',
			'grid' => array( 
				array(
					'cells' => array( 
						array(
							'cell' => 'c1' 
						) 
					),
					'section' => '' 
				) 
			),
			'cells' => array(
				'c1' => array(
					'model' => 'c1',
					'items' => array( 
						'integrated_edit_field7',
						'integrated_edit_field8' 
					) 
				) 
			),
			'deferredItems' => array( 
				 
			),
			'columnCount' => 1,
			'inlineLabels' => false,
			'separateLabels' => false 
		),
		'section3' => array(
			'modelId' => 'simple-edit',
			'grid' => array( 
				array(
					'cells' => array( 
						array(
							'cell' => 'c1' 
						) 
					),
					'section' => '' 
				) 
			),
			'cells' => array(
				'c1' => array(
					'model' => 'c1',
					'items' => array( 
						'integrated_edit_field16',
						'integrated_edit_field1',
						'integrated_edit_field22' 
					) 
				) 
			),
			'deferredItems' => array( 
				 
			),
			'columnCount' => 1,
			'inlineLabels' => false,
			'separateLabels' => false 
		),
		'section4' => array(
			'modelId' => 'simple-edit',
			'grid' => array( 
				array(
					'cells' => array( 
						array(
							'cell' => 'c1' 
						) 
					),
					'section' => '' 
				) 
			),
			'cells' => array(
				'c1' => array(
					'model' => 'c1',
					'items' => array( 
						'integrated_edit_field27',
						'integrated_edit_field28',
						'integrated_edit_field29',
						'integrated_edit_field30',
						'integrated_edit_field31',
						'integrated_edit_field32',
						'integrated_edit_field33',
						'integrated_edit_field10',
						'integrated_edit_field11',
						'integrated_edit_field12',
						'integrated_edit_field13',
						'integrated_edit_field14' 
					) 
				) 
			),
			'deferredItems' => array( 
				 
			),
			'columnCount' => 1,
			'inlineLabels' => false,
			'separateLabels' => false 
		) 
	),
	'items' => array(
		'add_header' => array(
			'type' => 'add_header' 
		),
		'add_back_list' => array(
			'type' => 'add_back_list' 
		),
		'add_cancel' => array(
			'type' => 'add_cancel' 
		),
		'add_message' => array(
			'type' => 'add_message' 
		),
		'add_save' => array(
			'type' => 'add_save',
			'icon' => array(
				'style' => 0 
			) 
		),
		'add_reset' => array(
			'type' => 'add_reset' 
		),
		'integrated_edit_field3' => array(
			'field' => 'item_id',
			'type' => 'integrated_edit_field',
			'orientation' => 0,
			'label' => array(
				'field' => 'item_id',
				'table' => 'sales_detail',
				'type' => 3 
			) 
		),
		'integrated_edit_field5' => array(
			'field' => 'description',
			'type' => 'integrated_edit_field',
			'orientation' => 0 
		),
		'integrated_edit_field6' => array(
			'field' => 'uom_code',
			'type' => 'integrated_edit_field',
			'orientation' => 0,
			'label' => array(
				'field' => 'uom_code',
				'table' => 'sales_detail',
				'type' => 3 
			) 
		),
		'integrated_edit_field7' => array(
			'field' => 'quantity',
			'type' => 'integrated_edit_field',
			'orientation' => 0 
		),
		'integrated_edit_field8' => array(
			'field' => 'unit_price',
			'type' => 'integrated_edit_field',
			'orientation' => 0 
		),
		'integrated_edit_field10' => array(
			'field' => 'commercial_discount_rate',
			'type' => 'integrated_edit_field',
			'orientation' => 0,
			'label' => array(
				'field' => 'commercial_discount_rate',
				'table' => 'sales_detail',
				'type' => 3 
			) 
		),
		'integrated_edit_field11' => array(
			'field' => 'commercial_discount_amount',
			'type' => 'integrated_edit_field',
			'orientation' => 0 
		),
		'integrated_edit_field12' => array(
			'field' => 'discount_type_id',
			'type' => 'integrated_edit_field',
			'orientation' => 0,
			'label' => array(
				'field' => 'discount_type_id',
				'table' => 'sales_detail',
				'type' => 3 
			) 
		),
		'integrated_edit_field13' => array(
			'field' => 'statutory_discount_rate',
			'type' => 'integrated_edit_field',
			'orientation' => 0,
			'label' => array(
				'field' => 'statutory_discount_rate',
				'table' => 'sales_detail',
				'type' => 3 
			) 
		),
		'integrated_edit_field14' => array(
			'field' => 'statutory_discount_amount',
			'type' => 'integrated_edit_field',
			'orientation' => 0 
		),
		'integrated_edit_field16' => array(
			'field' => 'vat_tax_code_id',
			'type' => 'integrated_edit_field',
			'orientation' => 0,
			'label' => array(
				'field' => 'vat_tax_code_id',
				'table' => 'sales_detail',
				'type' => 3 
			) 
		),
		'integrated_edit_field22' => array(
			'field' => 'withholding_tax_code_id',
			'type' => 'integrated_edit_field',
			'orientation' => 0,
			'label' => array(
				'field' => 'withholding_tax_code_id',
				'table' => 'sales_detail',
				'type' => 3 
			) 
		),
		'integrated_edit_field27' => array(
			'field' => 'warehouse_id',
			'type' => 'integrated_edit_field',
			'orientation' => 0,
			'label' => array(
				'field' => 'warehouse_id',
				'table' => 'sales_detail',
				'type' => 3 
			) 
		),
		'integrated_edit_field28' => array(
			'field' => 'department_id',
			'type' => 'integrated_edit_field',
			'orientation' => 0,
			'label' => array(
				'field' => 'department_id',
				'table' => 'sales_detail',
				'type' => 3 
			) 
		),
		'integrated_edit_field29' => array(
			'field' => 'cost_center_id',
			'type' => 'integrated_edit_field',
			'orientation' => 0,
			'label' => array(
				'field' => 'cost_center_id',
				'table' => 'sales_detail',
				'type' => 3 
			) 
		),
		'integrated_edit_field30' => array(
			'field' => 'project_id',
			'type' => 'integrated_edit_field',
			'orientation' => 0,
			'label' => array(
				'field' => 'project_id',
				'table' => 'sales_detail',
				'type' => 3 
			) 
		),
		'integrated_edit_field31' => array(
			'field' => 'project_task_id',
			'type' => 'integrated_edit_field',
			'orientation' => 0,
			'label' => array(
				'field' => 'project_task_id',
				'table' => 'sales_detail',
				'type' => 3 
			) 
		),
		'integrated_edit_field32' => array(
			'field' => 'sales_agent_id',
			'type' => 'integrated_edit_field',
			'orientation' => 0,
			'label' => array(
				'field' => 'sales_agent_id',
				'table' => 'sales_detail',
				'type' => 3 
			) 
		),
		'integrated_edit_field33' => array(
			'field' => 'campaign_id',
			'type' => 'integrated_edit_field',
			'orientation' => 0,
			'label' => array(
				'field' => 'campaign_id',
				'table' => 'sales_detail',
				'type' => 3 
			) 
		),
		'section' => array(
			'type' => 'section',
			'title' => array(
				'type' => 0,
				'text' => 'Line Info' 
			),
			'location' => 'section',
			'bsStyle' => 'default',
			'panelType' => 3 
		),
		'section1' => array(
			'type' => 'section',
			'title' => array(
				'type' => 0,
				'text' => 'Quantity and Price' 
			),
			'location' => 'section1',
			'bsStyle' => 'default',
			'panelType' => 3 
		),
		'section3' => array(
			'type' => 'section',
			'title' => array(
				'type' => 0,
				'text' => 'Taxes' 
			),
			'location' => 'section3',
			'bsStyle' => 'default',
			'panelType' => 3 
		),
		'section4' => array(
			'type' => 'section',
			'title' => array(
				'type' => 0,
				'text' => 'Advanced Details' 
			),
			'location' => 'section4',
			'bsStyle' => 'default',
			'panelType' => 3,
			'initiallyClosed' => true 
		),
		'integrated_edit_field1' => array(
			'field' => 'vat_rate_snapshot',
			'type' => 'integrated_edit_field',
			'orientation' => 0 
		) 
	),
	'version' => 13,
	'imageItem' => array(
		'type' => 'page_image' 
	),
	'imageBgColor' => '#f2f2f2',
	'controlsBgColor' => 'transparent',
	'imagePosition' => 'right',
	'listTotals' => 1,
	'title' => array(
		 
	),
	'cardStyle' => array(
		 
	) 
);
		?>