
	/** 
	 * =======================================================================================================
	 * Perform SQL SAVE request to the table RECORD_POS_SALE_LIST. Returns DataSet.
	 *
	 * @param VAR_PARAMETER_ARRAY Array with Request ParameterSet.
	 * @param CALLBACK_ADDRESS(bool, String) A callback method when the server response is received.
	 * =======================================================================================================
	 */
	JSCUS_SQL._RECORD._POS_SALE_LIST.CUS_PURCHASE = function
	(
		VAR_PARAMETER_ARRAY,
		CALLBACK_ADDRESS
	)
	{
		// Parameter Validation
		// _______________________________________________________________________
		JSVC_AV.VAR_VALIDATE_ARGUMENT_TYPE(VAR_PARAMETER_ARRAY, 'VAR_PARAMETER_ARRAY', 'ARRAY');
		
		// Process SQL Request
		// _______________________________________________________________________
		var PARAM_SET = "";	
		var ARRAY_INDEX = 0;
		
		if(JSVC_VAR.VAR_IS_ARRAY(VAR_PARAMETER_ARRAY[0]) == true)
		{
			// Check limits per request 
			if(VAR_PARAMETER_ARRAY.length >= CUSTOM_SITE_ARRAY_REQUEST_LIMIT)
			{
				throw "HTTP request is too large for single request. Limit : " + CUSTOM_SITE_ARRAY_REQUEST_LIMIT;
			}
			
			// Populate Array Items
			while(VAR_PARAMETER_ARRAY.length > 0 && ARRAY_INDEX < CUSTOM_SITE_ARRAY_REQUEST_LIMIT)
			{
				PARAM_SET = JSRC_HTTP.REF_ADD(PARAM_SET, 'PARAM_REC_POSSALE_REC_CLIENT_ID[]', VAR_PARAMETER_ARRAY[0]["PARAM_REC_POSSALE_REC_CLIENT_ID"]);
				PARAM_SET = JSRC_HTTP.REF_ADD(PARAM_SET, 'PARAM_REC_POSSALE_REC_LOYALTY_ID[]', VAR_PARAMETER_ARRAY[0]["PARAM_REC_POSSALE_REC_LOYALTY_ID"]);
				PARAM_SET = JSRC_HTTP.REF_ADD(PARAM_SET, 'PARAM_REC_POSSALE_CODE[]', VAR_PARAMETER_ARRAY[0]["PARAM_REC_POSSALE_CODE"]);
				PARAM_SET = JSRC_HTTP.REF_ADD(PARAM_SET, 'PARAM_REC_POSSALE_DATE_DUE[]', VAR_PARAMETER_ARRAY[0]["PARAM_REC_POSSALE_DATE_DUE"]);
				PARAM_SET = JSRC_HTTP.REF_ADD(PARAM_SET, 'PARAM_REC_POSSALE_REMARKS[]', VAR_PARAMETER_ARRAY[0]["PARAM_REC_POSSALE_REMARKS"]);
				PARAM_SET = JSRC_HTTP.REF_ADD(PARAM_SET, 'PARAM_REC_POSSALE_ACC_ACCOUNT_ID[]', VAR_PARAMETER_ARRAY[0]["PARAM_REC_POSSALE_ACC_ACCOUNT_ID"]);
				PARAM_SET = JSRC_HTTP.REF_ADD(PARAM_SET, 'PARAM_REC_POSSALE_DATE_TRANSACT[]', VAR_PARAMETER_ARRAY[0]["PARAM_REC_POSSALE_DATE_TRANSACT"]);
				PARAM_SET = JSRC_HTTP.REF_ADD(PARAM_SET, 'PARAM_REC_POSSALE_STATUS[]', VAR_PARAMETER_ARRAY[0]["PARAM_REC_POSSALE_STATUS"]);
				
				// ~~~~~
				
				PARAM_SET = JSRC_HTTP.REF_ADD(PARAM_SET, 'PARAM_REC_POSSALE_LIST_CAT_PRODUCT_ID[]', VAR_PARAMETER_ARRAY[0]["PARAM_REC_POSSALE_LIST_CAT_PRODUCT_ID"]);
				PARAM_SET = JSRC_HTTP.REF_ADD(PARAM_SET, 'PARAM_REC_POSSALE_LIST_CAT_UOM_ID[]', VAR_PARAMETER_ARRAY[0]["PARAM_REC_POSSALE_LIST_CAT_UOM_ID"]);
				PARAM_SET = JSRC_HTTP.REF_ADD(PARAM_SET, 'PARAM_REC_POSSALE_LIST_AMOUNT_PRICE[]', VAR_PARAMETER_ARRAY[0]["PARAM_REC_POSSALE_LIST_AMOUNT_PRICE"]);
				PARAM_SET = JSRC_HTTP.REF_ADD(PARAM_SET, 'PARAM_REC_POSSALE_LIST_AMOUNT_VAT[]', VAR_PARAMETER_ARRAY[0]["PARAM_REC_POSSALE_LIST_AMOUNT_VAT"]);
				PARAM_SET = JSRC_HTTP.REF_ADD(PARAM_SET, 'PARAM_REC_POSSALE_LIST_QUANTITY[]', VAR_PARAMETER_ARRAY[0]["PARAM_REC_POSSALE_LIST_QUANTITY"]);
				PARAM_SET = JSRC_HTTP.REF_ADD(PARAM_SET, 'PARAM_REC_POSSALE_LIST_QUANTITY_PCS[]', VAR_PARAMETER_ARRAY[0]["PARAM_REC_POSSALE_LIST_QUANTITY_PCS"]);
				
				PARAM_SET = JSRC_HTTP.REF_ADD(PARAM_SET, 'PARAM_REC_POSSALE_LIST_CAT_DISCOUNT_ID[]', VAR_PARAMETER_ARRAY[0]["PARAM_REC_POSSALE_LIST_CAT_DISCOUNT_ID"]);
				PARAM_SET = JSRC_HTTP.REF_ADD(PARAM_SET, 'PARAM_REC_POSSALE_LIST_TOPAY_SUBTOTAL[]', VAR_PARAMETER_ARRAY[0]["PARAM_REC_POSSALE_LIST_TOPAY_SUBTOTAL"]);
				PARAM_SET = JSRC_HTTP.REF_ADD(PARAM_SET, 'PARAM_REC_POSSALE_LIST_TOPAY_DISCOUNT[]', VAR_PARAMETER_ARRAY[0]["PARAM_REC_POSSALE_LIST_TOPAY_DISCOUNT"]);
				PARAM_SET = JSRC_HTTP.REF_ADD(PARAM_SET, 'PARAM_REC_POSSALE_LIST_TOPAY_VATABLE[]', VAR_PARAMETER_ARRAY[0]["PARAM_REC_POSSALE_LIST_TOPAY_VATABLE"]);
				PARAM_SET = JSRC_HTTP.REF_ADD(PARAM_SET, 'PARAM_REC_POSSALE_LIST_TOPAY_VATEXEMPT[]', VAR_PARAMETER_ARRAY[0]["PARAM_REC_POSSALE_LIST_TOPAY_VATEXEMPT"]);
				PARAM_SET = JSRC_HTTP.REF_ADD(PARAM_SET, 'PARAM_REC_POSSALE_LIST_TOPAY_NONVAT[]', VAR_PARAMETER_ARRAY[0]["PARAM_REC_POSSALE_LIST_TOPAY_NONVAT"]);
				PARAM_SET = JSRC_HTTP.REF_ADD(PARAM_SET, 'PARAM_REC_POSSALE_LIST_TOPAY_ZERORATED[]', VAR_PARAMETER_ARRAY[0]["PARAM_REC_POSSALE_LIST_TOPAY_ZERORATED"]);
				PARAM_SET = JSRC_HTTP.REF_ADD(PARAM_SET, 'PARAM_REC_POSSALE_LIST_TOPAY_VATOTHER[]', VAR_PARAMETER_ARRAY[0]["PARAM_REC_POSSALE_LIST_TOPAY_VATOTHER"]);
				PARAM_SET = JSRC_HTTP.REF_ADD(PARAM_SET, 'PARAM_REC_POSSALE_LIST_TOPAY_VAT[]', VAR_PARAMETER_ARRAY[0]["PARAM_REC_POSSALE_LIST_TOPAY_VAT"]);
				PARAM_SET = JSRC_HTTP.REF_ADD(PARAM_SET, 'PARAM_REC_POSSALE_LIST_TOPAY_VAT_LESS[]', VAR_PARAMETER_ARRAY[0]["PARAM_REC_POSSALE_LIST_TOPAY_VAT_LESS"]);
				PARAM_SET = JSRC_HTTP.REF_ADD(PARAM_SET, 'PARAM_REC_POSSALE_LIST_POINTS[]', VAR_PARAMETER_ARRAY[0]["PARAM_REC_POSSALE_LIST_POINTS"]);			
					
				// ~~~~~
				
				PARAM_SET = JSRC_HTTP.REF_ADD(PARAM_SET, 'PARAM_REC_POSPAY_CAT_PAYTYPE_ID[]',  VAR_PARAMETER_ARRAY[0]["PARAM_REC_POSPAY_CAT_PAYTYPE_ID"]);
				PARAM_SET = JSRC_HTTP.REF_ADD(PARAM_SET, 'PARAM_REC_POSPAY_AMOUNT_PAID[]',  VAR_PARAMETER_ARRAY[0]["PARAM_REC_POSPAY_AMOUNT_PAID"]);
				PARAM_SET = JSRC_HTTP.REF_ADD(PARAM_SET, 'PARAM_REC_POSPAY_CHANGE[]',  VAR_PARAMETER_ARRAY[0]["PARAM_REC_POSPAY_CHANGE"]);
				PARAM_SET = JSRC_HTTP.REF_ADD(PARAM_SET, 'PARAM_REC_POSPAY_NUMBER[]',  VAR_PARAMETER_ARRAY[0]["PARAM_REC_POSPAY_NUMBER"]);
				PARAM_SET = JSRC_HTTP.REF_ADD(PARAM_SET, 'PARAM_REC_POSPAY_PAYEE[]',  VAR_PARAMETER_ARRAY[0]["PARAM_REC_POSPAY_PAYEE"]);
				PARAM_SET = JSRC_HTTP.REF_ADD(PARAM_SET, 'PARAM_REC_POSPAY_CAT_BANK_ID[]',  VAR_PARAMETER_ARRAY[0]["PARAM_REC_POSPAY_CAT_BANK_ID"]);
				PARAM_SET = JSRC_HTTP.REF_ADD(PARAM_SET, 'PARAM_REC_POSPAY_CAT_CARDTYPE_ID[]',  VAR_PARAMETER_ARRAY[0]["PARAM_REC_POSPAY_CAT_CARDTYPE_ID"]);
				PARAM_SET = JSRC_HTTP.REF_ADD(PARAM_SET, 'PARAM_REC_POSPAY_REC_LOYALTY_ID[]',  VAR_PARAMETER_ARRAY[0]["PARAM_REC_POSPAY_REC_LOYALTY_ID"]);
				PARAM_SET = JSRC_HTTP.REF_ADD(PARAM_SET, 'PARAM_REC_POSPAY_REC_VOUCHER_ID[]',  VAR_PARAMETER_ARRAY[0]["PARAM_REC_POSPAY_REC_VOUCHER_ID"]);
				PARAM_SET = JSRC_HTTP.REF_ADD(PARAM_SET, 'PARAM_REC_POSPAY_CHECK_DATE[]',  VAR_PARAMETER_ARRAY[0]["PARAM_REC_POSPAY_CHECK_DATE"]);
				PARAM_SET = JSRC_HTTP.REF_ADD(PARAM_SET, 'PARAM_REC_POSPAY_REMARKS[]',  VAR_PARAMETER_ARRAY[0]["PARAM_REC_POSPAY_REMARKS"]);
				PARAM_SET = JSRC_HTTP.REF_ADD(PARAM_SET, 'PARAM_REC_POSPAY_ACC_ACCOUNT_ID[]',  VAR_PARAMETER_ARRAY[0]["PARAM_REC_POSPAY_ACC_ACCOUNT_ID"]);
				PARAM_SET = JSRC_HTTP.REF_ADD(PARAM_SET, 'PARAM_REC_POSPAY_DATE_PROCESSED[]',  VAR_PARAMETER_ARRAY[0]["PARAM_REC_POSPAY_DATE_PROCESSED"]);
				PARAM_SET = JSRC_HTTP.REF_ADD(PARAM_SET, 'PARAM_REC_POSPAY_IS_INITIAL_PAY[]',  VAR_PARAMETER_ARRAY[0]["PARAM_REC_POSPAY_IS_INITIAL_PAY"]);
				
				// ~~~~~
				
				if(ARRAY_INDEX == 0)
				{
					PARAM_SET = JSRC_HTTP.REF_ADD(PARAM_SET, 'PARAM_REQUEST_UNIQUE_VALUE',  VAR_PARAMETER_ARRAY[0]["PARAM_REQUEST_UNIQUE_VALUE"]);
				}
				
				VAR_PARAMETER_ARRAY.shift();
				ARRAY_INDEX ++;
			}					
		}
		else
		{
			PARAM_SET = JSRC_HTTP.REF_ADD(PARAM_SET, 'PARAM_REC_POSSALE_REC_CLIENT_ID[]', VAR_PARAMETER_ARRAY["PARAM_REC_POSSALE_REC_CLIENT_ID"]);
			PARAM_SET = JSRC_HTTP.REF_ADD(PARAM_SET, 'PARAM_REC_POSSALE_REC_LOYALTY_ID[]', VAR_PARAMETER_ARRAY["PARAM_REC_POSSALE_REC_LOYALTY_ID"]);
			PARAM_SET = JSRC_HTTP.REF_ADD(PARAM_SET, 'PARAM_REC_POSSALE_CODE[]', VAR_PARAMETER_ARRAY["PARAM_REC_POSSALE_CODE"]);
			PARAM_SET = JSRC_HTTP.REF_ADD(PARAM_SET, 'PARAM_REC_POSSALE_DATE_DUE[]', VAR_PARAMETER_ARRAY["PARAM_REC_POSSALE_DATE_DUE"]);
			PARAM_SET = JSRC_HTTP.REF_ADD(PARAM_SET, 'PARAM_REC_POSSALE_REMARKS[]', VAR_PARAMETER_ARRAY["PARAM_REC_POSSALE_REMARKS"]);
			PARAM_SET = JSRC_HTTP.REF_ADD(PARAM_SET, 'PARAM_REC_POSSALE_ACC_ACCOUNT_ID[]', VAR_PARAMETER_ARRAY["PARAM_REC_POSSALE_ACC_ACCOUNT_ID"]);
			PARAM_SET = JSRC_HTTP.REF_ADD(PARAM_SET, 'PARAM_REC_POSSALE_DATE_TRANSACT[]', VAR_PARAMETER_ARRAY["PARAM_REC_POSSALE_DATE_TRANSACT"]);
			PARAM_SET = JSRC_HTTP.REF_ADD(PARAM_SET, 'PARAM_REC_POSSALE_STATUS[]', VAR_PARAMETER_ARRAY["PARAM_REC_POSSALE_STATUS"]);
			
			// ~~~~~
			
			PARAM_SET = JSRC_HTTP.REF_ADD(PARAM_SET, 'PARAM_REC_POSSALE_LIST_CAT_PRODUCT_ID[]', VAR_PARAMETER_ARRAY["PARAM_REC_POSSALE_LIST_CAT_PRODUCT_ID"]);
			PARAM_SET = JSRC_HTTP.REF_ADD(PARAM_SET, 'PARAM_REC_POSSALE_LIST_CAT_UOM_ID[]', VAR_PARAMETER_ARRAY["PARAM_REC_POSSALE_LIST_CAT_UOM_ID"]);
			PARAM_SET = JSRC_HTTP.REF_ADD(PARAM_SET, 'PARAM_REC_POSSALE_LIST_AMOUNT_PRICE[]', VAR_PARAMETER_ARRAY["PARAM_REC_POSSALE_LIST_AMOUNT_PRICE"]);
			PARAM_SET = JSRC_HTTP.REF_ADD(PARAM_SET, 'PARAM_REC_POSSALE_LIST_AMOUNT_VAT[]', VAR_PARAMETER_ARRAY["PARAM_REC_POSSALE_LIST_AMOUNT_VAT"]);
			PARAM_SET = JSRC_HTTP.REF_ADD(PARAM_SET, 'PARAM_REC_POSSALE_LIST_QUANTITY[]', VAR_PARAMETER_ARRAY["PARAM_REC_POSSALE_LIST_QUANTITY"]);
			PARAM_SET = JSRC_HTTP.REF_ADD(PARAM_SET, 'PARAM_REC_POSSALE_LIST_QUANTITY_PCS[]', VAR_PARAMETER_ARRAY["PARAM_REC_POSSALE_LIST_QUANTITY_PCS"]);
			
			PARAM_SET = JSRC_HTTP.REF_ADD(PARAM_SET, 'PARAM_REC_POSSALE_LIST_CAT_DISCOUNT_ID[]', VAR_PARAMETER_ARRAY["PARAM_REC_POSSALE_LIST_CAT_DISCOUNT_ID"]);
			PARAM_SET = JSRC_HTTP.REF_ADD(PARAM_SET, 'PARAM_REC_POSSALE_LIST_TOPAY_SUBTOTAL[]', VAR_PARAMETER_ARRAY["PARAM_REC_POSSALE_LIST_TOPAY_SUBTOTAL"]);
			PARAM_SET = JSRC_HTTP.REF_ADD(PARAM_SET, 'PARAM_REC_POSSALE_LIST_TOPAY_DISCOUNT[]', VAR_PARAMETER_ARRAY["PARAM_REC_POSSALE_LIST_TOPAY_DISCOUNT"]);
			PARAM_SET = JSRC_HTTP.REF_ADD(PARAM_SET, 'PARAM_REC_POSSALE_LIST_TOPAY_VATABLE[]', VAR_PARAMETER_ARRAY["PARAM_REC_POSSALE_LIST_TOPAY_VATABLE"]);
			PARAM_SET = JSRC_HTTP.REF_ADD(PARAM_SET, 'PARAM_REC_POSSALE_LIST_TOPAY_VATEXEMPT[]', VAR_PARAMETER_ARRAY["PARAM_REC_POSSALE_LIST_TOPAY_VATEXEMPT"]);
			PARAM_SET = JSRC_HTTP.REF_ADD(PARAM_SET, 'PARAM_REC_POSSALE_LIST_TOPAY_NONVAT[]', VAR_PARAMETER_ARRAY["PARAM_REC_POSSALE_LIST_TOPAY_NONVAT"]);
			PARAM_SET = JSRC_HTTP.REF_ADD(PARAM_SET, 'PARAM_REC_POSSALE_LIST_TOPAY_ZERORATED[]', VAR_PARAMETER_ARRAY["PARAM_REC_POSSALE_LIST_TOPAY_ZERORATED"]);
			PARAM_SET = JSRC_HTTP.REF_ADD(PARAM_SET, 'PARAM_REC_POSSALE_LIST_TOPAY_VATOTHER[]', VAR_PARAMETER_ARRAY["PARAM_REC_POSSALE_LIST_TOPAY_VATOTHER"]);
			PARAM_SET = JSRC_HTTP.REF_ADD(PARAM_SET, 'PARAM_REC_POSSALE_LIST_TOPAY_VAT[]', VAR_PARAMETER_ARRAY["PARAM_REC_POSSALE_LIST_TOPAY_VAT"]);
			PARAM_SET = JSRC_HTTP.REF_ADD(PARAM_SET, 'PARAM_REC_POSSALE_LIST_TOPAY_VAT_LESS[]', VAR_PARAMETER_ARRAY["PARAM_REC_POSSALE_LIST_TOPAY_VAT_LESS"]);
			PARAM_SET = JSRC_HTTP.REF_ADD(PARAM_SET, 'PARAM_REC_POSSALE_LIST_POINTS[]', VAR_PARAMETER_ARRAY["PARAM_REC_POSSALE_LIST_POINTS"]);
			
			// ~~~~~
			
			PARAM_SET = JSRC_HTTP.REF_ADD(PARAM_SET, 'PARAM_REC_POSPAY_CAT_PAYTYPE_ID[]',  VAR_PARAMETER_ARRAY["PARAM_REC_POSPAY_CAT_PAYTYPE_ID"]);
			PARAM_SET = JSRC_HTTP.REF_ADD(PARAM_SET, 'PARAM_REC_POSPAY_AMOUNT_PAID[]',  VAR_PARAMETER_ARRAY["PARAM_REC_POSPAY_AMOUNT_PAID"]);
			PARAM_SET = JSRC_HTTP.REF_ADD(PARAM_SET, 'PARAM_REC_POSPAY_CHANGE[]',  VAR_PARAMETER_ARRAY["PARAM_REC_POSPAY_CHANGE"]);
			PARAM_SET = JSRC_HTTP.REF_ADD(PARAM_SET, 'PARAM_REC_POSPAY_NUMBER[]',  VAR_PARAMETER_ARRAY["PARAM_REC_POSPAY_NUMBER"]);
			PARAM_SET = JSRC_HTTP.REF_ADD(PARAM_SET, 'PARAM_REC_POSPAY_PAYEE[]',  VAR_PARAMETER_ARRAY["PARAM_REC_POSPAY_PAYEE"]);
			PARAM_SET = JSRC_HTTP.REF_ADD(PARAM_SET, 'PARAM_REC_POSPAY_CAT_BANK_ID[]',  VAR_PARAMETER_ARRAY["PARAM_REC_POSPAY_CAT_BANK_ID"]);
			PARAM_SET = JSRC_HTTP.REF_ADD(PARAM_SET, 'PARAM_REC_POSPAY_CAT_CARDTYPE_ID[]',  VAR_PARAMETER_ARRAY["PARAM_REC_POSPAY_CAT_CARDTYPE_ID"]);
			PARAM_SET = JSRC_HTTP.REF_ADD(PARAM_SET, 'PARAM_REC_POSPAY_REC_LOYALTY_ID[]',  VAR_PARAMETER_ARRAY["PARAM_REC_POSPAY_REC_LOYALTY_ID"]);
			PARAM_SET = JSRC_HTTP.REF_ADD(PARAM_SET, 'PARAM_REC_POSPAY_REC_VOUCHER_ID[]',  VAR_PARAMETER_ARRAY["PARAM_REC_POSPAY_REC_VOUCHER_ID"]);
			PARAM_SET = JSRC_HTTP.REF_ADD(PARAM_SET, 'PARAM_REC_POSPAY_CHECK_DATE[]',  VAR_PARAMETER_ARRAY["PARAM_REC_POSPAY_CHECK_DATE"]);
			PARAM_SET = JSRC_HTTP.REF_ADD(PARAM_SET, 'PARAM_REC_POSPAY_REMARKS[]',  VAR_PARAMETER_ARRAY["PARAM_REC_POSPAY_REMARKS"]);
			PARAM_SET = JSRC_HTTP.REF_ADD(PARAM_SET, 'PARAM_REC_POSPAY_ACC_ACCOUNT_ID[]',  VAR_PARAMETER_ARRAY["PARAM_REC_POSPAY_ACC_ACCOUNT_ID"]);
			PARAM_SET = JSRC_HTTP.REF_ADD(PARAM_SET, 'PARAM_REC_POSPAY_DATE_PROCESSED[]',  VAR_PARAMETER_ARRAY["PARAM_REC_POSPAY_DATE_PROCESSED"]);
			PARAM_SET = JSRC_HTTP.REF_ADD(PARAM_SET, 'PARAM_REC_POSPAY_IS_INITIAL_PAY[]',  VAR_PARAMETER_ARRAY["PARAM_REC_POSPAY_IS_INITIAL_PAY"]);
			
			// ~~~~~
			
			PARAM_SET = JSRC_HTTP.REF_ADD(PARAM_SET, 'PARAM_REQUEST_UNIQUE_VALUE',  VAR_PARAMETER_ARRAY["PARAM_REQUEST_UNIQUE_VALUE"]);
		}

		// Send SQL Request
		// _______________________________________________________________________		
		CUS_SEND_REQUEST
		(
			CALLBACK_ADDRESS,
			JSCUS_CACHE.SERVER_URL + '/Record/pos_sale/purchase',
			JSCUS_CACHE.SERVER_URL + '/System/nonce/get',
			PARAM_SET
		);	
	}
	
	/** 
	 * =======================================================================================================
	 * Populate SP-SAVE request parameters with default value.
	 * =======================================================================================================
	 */
	JSCUS_SQL._RECORD._POS_SALE_LIST.CUS_PREPARE_MAPPED_ARRAY_FOR_PURCHASE = function()
	{
		// Initialize
		var RESULT_MAPARRAY = [];		
		
		RESULT_MAPARRAY["PARAM_REC_POSSALE_REC_CLIENT_ID"] = FLAG_BIGINT_NULL;		// When charged to account
		RESULT_MAPARRAY["PARAM_REC_POSSALE_REC_LOYALTY_ID"] = FLAG_BIGINT_NULL;		// Loyalty card used
		RESULT_MAPARRAY["PARAM_REC_POSSALE_CODE"] = FLAG_NVARCHAR_NULL;				// Receipt Number
		RESULT_MAPARRAY["PARAM_REC_POSSALE_DATE_DUE"] = FLAG_DATETIME_NULL;			// Charged nto account, payment due date
		RESULT_MAPARRAY["PARAM_REC_POSSALE_REMARKS"] = FLAG_NVARCHAR_NULL;
		RESULT_MAPARRAY["PARAM_REC_POSSALE_ACC_ACCOUNT_ID"] = FLAG_BIGINT_NULL;		// Cachier's ID (You can get from `me` request.)
		RESULT_MAPARRAY["PARAM_REC_POSSALE_DATE_TRANSACT"] = FLAG_DATETIME_NULL;
		RESULT_MAPARRAY["PARAM_REC_POSSALE_STATUS"] = FLAG_TINYINT_NULL;
		
		// ~~~~~
		
		RESULT_MAPARRAY["PARAM_REC_POSSALE_LIST_CAT_PRODUCT_ID"] = FLAG_BIGINT_NULL;
		RESULT_MAPARRAY["PARAM_REC_POSSALE_LIST_CAT_UOM_ID"] = FLAG_BIGINT_NULL;
		RESULT_MAPARRAY["PARAM_REC_POSSALE_LIST_AMOUNT_PRICE"] = FLAG_DECIMAL_NULL;
		RESULT_MAPARRAY["PARAM_REC_POSSALE_LIST_AMOUNT_VAT"] = FLAG_DECIMAL_NULL;
		RESULT_MAPARRAY["PARAM_REC_POSSALE_LIST_QUANTITY"] = FLAG_DECIMAL_NULL;
		RESULT_MAPARRAY["PARAM_REC_POSSALE_LIST_QUANTITY_PCS"] = FLAG_DECIMAL_NULL;

		RESULT_MAPARRAY["PARAM_REC_POSSALE_LIST_CAT_DISCOUNT_ID"] = FLAG_BIGINT_NULL;	// Applied Discount
		RESULT_MAPARRAY["PARAM_REC_POSSALE_LIST_TOPAY_SUBTOTAL"] = FLAG_DECIMAL_NULL;
		RESULT_MAPARRAY["PARAM_REC_POSSALE_LIST_TOPAY_DISCOUNT"] = FLAG_DECIMAL_NULL;
		RESULT_MAPARRAY["PARAM_REC_POSSALE_LIST_TOPAY_VATABLE"] = FLAG_DECIMAL_NULL;
		RESULT_MAPARRAY["PARAM_REC_POSSALE_LIST_TOPAY_VATEXEMPT"] = FLAG_DECIMAL_NULL;
		RESULT_MAPARRAY["PARAM_REC_POSSALE_LIST_TOPAY_NONVAT"] = FLAG_DECIMAL_NULL;
		RESULT_MAPARRAY["PARAM_REC_POSSALE_LIST_TOPAY_ZERORATED"] = FLAG_DECIMAL_NULL;
		RESULT_MAPARRAY["PARAM_REC_POSSALE_LIST_TOPAY_VATOTHER"] = FLAG_DECIMAL_NULL;
		RESULT_MAPARRAY["PARAM_REC_POSSALE_LIST_TOPAY_VAT"] = FLAG_DECIMAL_NULL;
		RESULT_MAPARRAY["PARAM_REC_POSSALE_LIST_TOPAY_VAT_LESS"] = FLAG_DECIMAL_NULL;
		RESULT_MAPARRAY["PARAM_REC_POSSALE_LIST_POINTS"] = FLAG_DECIMAL_NULL;
		
		// ~~~~~
		
		RESULT_MAPARRAY["PARAM_REC_POSPAY_CAT_PAYTYPE_ID"] = FLAG_BIGINT_NULL;
		RESULT_MAPARRAY["PARAM_REC_POSPAY_AMOUNT_PAID"] = FLAG_DECIMAL_NULL;
		RESULT_MAPARRAY["PARAM_REC_POSPAY_CHANGE"] = FLAG_DECIMAL_NULL;
		RESULT_MAPARRAY["PARAM_REC_POSPAY_NUMBER"] = FLAG_NVARCHAR_NULL;
		RESULT_MAPARRAY["PARAM_REC_POSPAY_PAYEE"] = FLAG_NVARCHAR_NULL;
		RESULT_MAPARRAY["PARAM_REC_POSPAY_CAT_BANK_ID"] = FLAG_BIGINT_NULL;
		RESULT_MAPARRAY["PARAM_REC_POSPAY_CAT_CARDTYPE_ID"] = FLAG_BIGINT_NULL;
		RESULT_MAPARRAY["PARAM_REC_POSPAY_REC_LOYALTY_ID"] = FLAG_BIGINT_NULL;
		RESULT_MAPARRAY["PARAM_REC_POSPAY_REC_VOUCHER_ID"] = FLAG_BIGINT_NULL;
		RESULT_MAPARRAY["PARAM_REC_POSPAY_CHECK_DATE"] = FLAG_DATETIME_NULL;
		RESULT_MAPARRAY["PARAM_REC_POSPAY_REMARKS"] = FLAG_NVARCHAR_NULL;
		RESULT_MAPARRAY["PARAM_REC_POSPAY_ACC_ACCOUNT_ID"] = FLAG_BIGINT_NULL;
		RESULT_MAPARRAY["PARAM_REC_POSPAY_ACC_ACCOUNT_SERVER_ID"] = FLAG_BIGINT_NULL;
		RESULT_MAPARRAY["PARAM_REC_POSPAY_DATE_PROCESSED"] = FLAG_DATETIME_NULL;
		RESULT_MAPARRAY["PARAM_REC_POSPAY_IS_INITIAL_PAY"] = FLAG_TINYINT_NULL;
		
		// ~~~~~
		
		RESULT_MAPARRAY["PARAM_REQUEST_UNIQUE_VALUE"] = '';
		
		// Return prepared MapArray
		return RESULT_MAPARRAY;		
	}
	
	/** 
	 * =======================================================================================================
	 * Add SP-GET request for multiple record save request.
	 * =======================================================================================================
	 */	
	JSCUS_SQL._RECORD._POS_SALE_LIST.CUS_ADD_MAPPED_ARRAY_FOR_PURCHASE = function
	(
		VAR_GROUPED_PARAMETER_ARRAY,
		VAR_ADD_PARAMETER_ARRAY
	)
	{
		// Parameter Validation
		// _______________________________________________________________________
		JSVC_AV.VAR_VALIDATE_ARGUMENT_TYPE(VAR_GROUPED_PARAMETER_ARRAY, 'VAR_GROUPED_PARAMETER_ARRAY', 'ARRAY');
		JSVC_AV.VAR_VALIDATE_ARGUMENT_TYPE(VAR_ADD_PARAMETER_ARRAY, 'VAR_ADD_PARAMETER_ARRAY', 'ARRAY');
		
		// Push ParameterSet
		// _______________________________________________________________________
		VAR_GROUPED_PARAMETER_ARRAY.push(VAR_ADD_PARAMETER_ARRAY);
		return VAR_GROUPED_PARAMETER_ARRAY;
	}
