<?php
global $runnerTableSettings;
$runnerTableSettings['Food_Pack_SKU_Priority'] = array(
	'name' => 'Food_Pack_SKU_Priority',
	'type' => 1,
	'shortName' => 'item2',
	'pagesByType' => array(
		'list' => array( 
			'list' 
		),
		'masterlist' => array( 
			'masterlist' 
		),
		'masterprint' => array( 
			'masterprint' 
		),
		'search' => array( 
			'search' 
		) 
	),
	'pageTypes' => array(
		'list' => 'list',
		'masterlist' => 'masterlist',
		'masterprint' => 'masterprint',
		'search' => 'search' 
	),
	'defaultPages' => array(
		'list' => 'list',
		'masterlist' => 'masterlist',
		'masterprint' => 'masterprint',
		'search' => 'search' 
	),
	'afterEditDetails' => 'Food_Pack_SKU_Priority',
	'afterAddDetail' => 'Food_Pack_SKU_Priority',
	'detailsBadgeColor' => '6da5c8',
	'strOrderBy' => 'ORDER BY priority ASC',
	'orderInfo' => array( 
		array(
			'index' => 7,
			'dir' => 'ASC',
			'field' => 'priority' 
		) 
	),
	'sql' => 'SELECT
    id,
    sku,
    name,
    description,
    brand,
    parent_item_name,
    priority
FROM item
WHERE subcategory_id = 5
ORDER BY priority ASC',
	'keyFields' => array( 
		'id' 
	),
	'deviceHideFields' => array(
		'1' => array( 
			 
		),
		'5' => array( 
			 
		) 
	),
	'fields' => array(
		'id' => array(
			'name' => 'id',
			'goodName' => 'id',
			'strField' => 'id',
			'index' => 1,
			'type' => 3,
			'autoinc' => true,
			'sqlExpression' => 'id',
			'viewFormats' => array(
				'view' => array(
					 
				) 
			),
			'editFormats' => array(
				'edit' => array(
					 
				) 
			),
			'tableName' => 'item' 
		),
		'name' => array(
			'name' => 'name',
			'goodName' => 'name',
			'strField' => 'name',
			'index' => 3,
			'sqlExpression' => 'name',
			'viewFormats' => array(
				'view' => array(
					 
				) 
			),
			'editFormats' => array(
				'edit' => array(
					 
				) 
			),
			'tableName' => 'item' 
		),
		'description' => array(
			'name' => 'description',
			'goodName' => 'description',
			'strField' => 'description',
			'index' => 4,
			'sqlExpression' => 'description',
			'viewFormats' => array(
				'view' => array(
					 
				) 
			),
			'editFormats' => array(
				'edit' => array(
					'required' => true 
				) 
			),
			'tableName' => 'item' 
		),
		'sku' => array(
			'name' => 'sku',
			'goodName' => 'sku',
			'strField' => 'sku',
			'index' => 2,
			'sqlExpression' => 'sku',
			'viewFormats' => array(
				'view' => array(
					 
				) 
			),
			'editFormats' => array(
				'edit' => array(
					'required' => true 
				) 
			),
			'tableName' => 'item' 
		),
		'brand' => array(
			'name' => 'brand',
			'goodName' => 'brand',
			'strField' => 'brand',
			'index' => 5,
			'sqlExpression' => 'brand',
			'viewFormats' => array(
				'view' => array(
					 
				) 
			),
			'editFormats' => array(
				'edit' => array(
					 
				) 
			),
			'tableName' => 'item' 
		),
		'parent_item_name' => array(
			'name' => 'parent_item_name',
			'goodName' => 'parent_item_name',
			'strField' => 'parent_item_name',
			'index' => 6,
			'sqlExpression' => 'parent_item_name',
			'viewFormats' => array(
				'view' => array(
					 
				) 
			),
			'editFormats' => array(
				'edit' => array(
					'format' => 'Lookup wizard',
					'lookupType' => 2,
					'lookupTable' => 'item',
					'lookupTableConnection' => 'conn',
					'lookupLinkField' => 'description',
					'lookupDisplayField' => 'description',
					'lookupControlType' => 1,
					'lookupFreeInput' => true,
					'lookupAutofillEdit' => true,
					'lookupAutofillFields' => array( 
						array(
							'masterField' => 'parent_item_id',
							'lookupField' => 'id' 
						) 
					) 
				) 
			),
			'tableName' => 'item',
			'viewLinkTable' => 'item',
			'viewLinkLookup' => true 
		),
		'priority' => array(
			'name' => 'priority',
			'goodName' => 'priority',
			'strField' => 'priority',
			'index' => 7,
			'type' => 3,
			'sqlExpression' => 'priority',
			'viewFormats' => array(
				'view' => array(
					 
				) 
			),
			'editFormats' => array(
				'edit' => array(
					 
				) 
			),
			'tableName' => 'item' 
		) 
	),
	'detailsTables' => array( 
		'augmentation_request_allocation' 
	),
	'query' => array(
		'sql' => 'SELECT
    id,
    sku,
    name,
    description,
    brand,
    parent_item_name,
    priority
FROM item
WHERE subcategory_id = 5
ORDER BY priority ASC',
		'parsed' => true,
		'type' => 'SQLQuery',
		'fieldList' => array( 
			array(
				'sql' => 'id',
				'parsed' => true,
				'type' => 'FieldListItem',
				'alias' => '',
				'expression' => array(
					'sql' => '',
					'parsed' => true,
					'type' => 'SQLField',
					'table' => 'item',
					'name' => 'id' 
				),
				'encrypted' => false,
				'columnName' => 'id' 
			),
			array(
				'sql' => 'sku',
				'parsed' => true,
				'type' => 'FieldListItem',
				'alias' => '',
				'expression' => array(
					'sql' => '',
					'parsed' => true,
					'type' => 'SQLField',
					'table' => 'item',
					'name' => 'sku' 
				),
				'encrypted' => false,
				'columnName' => 'sku' 
			),
			array(
				'sql' => 'name',
				'parsed' => true,
				'type' => 'FieldListItem',
				'alias' => '',
				'expression' => array(
					'sql' => '',
					'parsed' => true,
					'type' => 'SQLField',
					'table' => 'item',
					'name' => 'name' 
				),
				'encrypted' => false,
				'columnName' => 'name' 
			),
			array(
				'sql' => 'description',
				'parsed' => true,
				'type' => 'FieldListItem',
				'alias' => '',
				'expression' => array(
					'sql' => '',
					'parsed' => true,
					'type' => 'SQLField',
					'table' => 'item',
					'name' => 'description' 
				),
				'encrypted' => false,
				'columnName' => 'description' 
			),
			array(
				'sql' => 'brand',
				'parsed' => true,
				'type' => 'FieldListItem',
				'alias' => '',
				'expression' => array(
					'sql' => '',
					'parsed' => true,
					'type' => 'SQLField',
					'table' => 'item',
					'name' => 'brand' 
				),
				'encrypted' => false,
				'columnName' => 'brand' 
			),
			array(
				'sql' => 'parent_item_name',
				'parsed' => true,
				'type' => 'FieldListItem',
				'alias' => '',
				'expression' => array(
					'sql' => '',
					'parsed' => true,
					'type' => 'SQLField',
					'table' => 'item',
					'name' => 'parent_item_name' 
				),
				'encrypted' => false,
				'columnName' => 'parent_item_name' 
			),
			array(
				'sql' => 'priority',
				'parsed' => true,
				'type' => 'FieldListItem',
				'alias' => '',
				'expression' => array(
					'sql' => '',
					'parsed' => true,
					'type' => 'SQLField',
					'table' => 'item',
					'name' => 'priority' 
				),
				'encrypted' => false,
				'columnName' => 'priority' 
			) 
		),
		'fromList' => array( 
			array(
				'sql' => 'item',
				'parsed' => true,
				'type' => 'FromListItem',
				'table' => array(
					'sql' => 'item',
					'parsed' => true,
					'type' => 'SQLTable',
					'columns' => array( 
						'id',
						'reference_number',
						'name',
						'description',
						'reorder_level',
						'warranty_period_months',
						'shelf_life_days',
						'createdAt',
						'updatedAt',
						'category_id',
						'subcategory_id',
						'parent_item_id',
						'parent_item_name',
						'procurement_type',
						'brand_id',
						'brand',
						'weight',
						'dimensions',
						'unit_id',
						'sku',
						'item_classification',
						'food_classification_id',
						'priority',
						'status',
						'approved_by',
						'approved_date',
						'approval_remarks' 
					),
					'name' => 'item' 
				),
				'joinOn' => array(
					'sql' => '',
					'parsed' => false,
					'type' => 'LogicalExpression',
					'contained' => array( 
						 
					),
					'unionType' => 0,
					'column' => null 
				),
				'joinList' => array(
					'sql' => '',
					'parsed' => true,
					'type' => 'JoinOn',
					'field1' => array( 
						 
					),
					'field2' => array( 
						 
					) 
				),
				'link' => 0 
			) 
		),
		'where' => array(
			'sql' => 'subcategory_id = 5',
			'parsed' => true,
			'type' => 'LogicalExpression',
			'contained' => array( 
				 
			),
			'unionType' => 0,
			'column' => array(
				'sql' => '',
				'parsed' => true,
				'type' => 'SQLField',
				'table' => 'item',
				'name' => 'subcategory_id' 
			),
			'case' => '= 5',
			'useAlias' => false 
		),
		'groupBy' => array( 
			 
		),
		'having' => array(
			'sql' => '',
			'parsed' => false,
			'type' => 'LogicalExpression',
			'contained' => array( 
				 
			),
			'unionType' => 0,
			'column' => null 
		),
		'orderBy' => array( 
			array(
				'sql' => 'priority ASC',
				'parsed' => true,
				'type' => 'OrderByListItem',
				'column' => array(
					'sql' => '',
					'parsed' => true,
					'type' => 'SQLField',
					'table' => 'item',
					'name' => 'priority' 
				),
				'asc' => true,
				'columnNumber' => 7 
			) 
		),
		'colsIndex' => array( 
			array(
				'fieldIndex' => 0,
				'orderByIndex' => -1,
				'groupByIndex' => -1,
				'whereIndex' => -1,
				'havingIndex' => -1 
			),
			array(
				'fieldIndex' => 1,
				'orderByIndex' => -1,
				'groupByIndex' => -1,
				'whereIndex' => -1,
				'havingIndex' => -1 
			),
			array(
				'fieldIndex' => 2,
				'orderByIndex' => -1,
				'groupByIndex' => -1,
				'whereIndex' => -1,
				'havingIndex' => -1 
			),
			array(
				'fieldIndex' => 3,
				'orderByIndex' => -1,
				'groupByIndex' => -1,
				'whereIndex' => -1,
				'havingIndex' => -1 
			),
			array(
				'fieldIndex' => 4,
				'orderByIndex' => -1,
				'groupByIndex' => -1,
				'whereIndex' => -1,
				'havingIndex' => -1 
			),
			array(
				'fieldIndex' => 5,
				'orderByIndex' => -1,
				'groupByIndex' => -1,
				'whereIndex' => -1,
				'havingIndex' => -1 
			),
			array(
				'fieldIndex' => 6,
				'orderByIndex' => 0,
				'groupByIndex' => -1,
				'whereIndex' => -1,
				'havingIndex' => -1 
			),
			array(
				'fieldIndex' => -1,
				'orderByIndex' => -1,
				'groupByIndex' => -1,
				'whereIndex' => 0,
				'havingIndex' => -1 
			) 
		),
		'headSql' => 'SELECT',
		'fieldListSql' => 'id,
    sku,
    name,
    description,
    brand,
    parent_item_name,
    priority',
		'fromListSql' => 'FROM item',
		'whereSql' => 'subcategory_id = 5',
		'orderBySql' => 'ORDER BY priority ASC',
		'tailSql' => '' 
	),
	'hasEvents' => true,
	'hasJsEvents' => true,
	'originalTable' => 'item',
	'originalPagesByType' => array(
		'list' => array( 
			'list' 
		),
		'masterlist' => array( 
			'masterlist' 
		),
		'masterprint' => array( 
			'masterprint' 
		),
		'search' => array( 
			'search' 
		) 
	),
	'originalPageTypes' => array(
		'list' => 'list',
		'masterlist' => 'masterlist',
		'masterprint' => 'masterprint',
		'search' => 'search' 
	),
	'originalDefaultPages' => array(
		'list' => 'list',
		'masterlist' => 'masterlist',
		'masterprint' => 'masterprint',
		'search' => 'search' 
	),
	'searchSettings' => array(
		'caseSensitiveSearch' => false,
		'searchableFields' => array( 
			'id',
			'name',
			'description',
			'sku',
			'brand',
			'parent_item_name',
			'priority' 
		),
		'searchSuggest' => true,
		'highlightSearchResults' => true,
		'hideDataUntilSearch' => false,
		'hideFilterUntilSearch' => false,
		'googleLikeSearchFields' => array( 
			'id',
			'name',
			'description',
			'sku',
			'brand',
			'parent_item_name',
			'priority' 
		) 
	),
	'connId' => 'conn',
	'clickActions' => array(
		'row' => array(
			'action' => 'noaction' 
		),
		'fields' => array(
			 
		) 
	),
	'geoCoding' => array(
		'enabled' => false,
		'latField' => '',
		'lonField' => '',
		'addressFields' => array( 
			 
		) 
	),
	'whereTabs' => array( 
		 
	),
	'labels' => array(
		 
	),
	'chartSettings' => array(
		 
	),
	'dataSourceOperations' => array(
		 
	),
	'calendarSettings' => array(
		'categoryColors' => array( 
			 
		) 
	),
	'ganttSettings' => array(
		'categoryColors' => array( 
			 
		) 
	) 
);

global $runnerTableLabels;
if( mlang_getcurrentlang() === 'English' ) {
	$runnerTableLabels['Food_Pack_SKU_Priority'] = array(
	'tableCaption' => 'Food Pack SKU Priority',
	'fieldLabels' => array(
		'id' => 'ID',
		'name' => 'Name',
		'description' => 'Description',
		'sku' => 'Stock Keeping Unit (SKU)',
		'brand' => 'Brand',
		'parent_item_name' => 'Parent Item Name',
		'priority' => 'Priority' 
	),
	'fieldTooltips' => array(
		'id' => '',
		'name' => '',
		'description' => '',
		'sku' => '',
		'brand' => '',
		'parent_item_name' => '',
		'priority' => '' 
	),
	'fieldPlaceholders' => array(
		'id' => '',
		'name' => '',
		'description' => '',
		'sku' => '',
		'brand' => '',
		'parent_item_name' => '',
		'priority' => '' 
	),
	'pageTitles' => array(
		 
	) 
);
}
?>