HEX
Server: LiteSpeed
System: Linux s787.bom1.mysecurecloudhost.com 4.18.0-477.13.1.lve.el8.x86_64 #1 SMP Thu Jun 1 16:40:47 EDT 2023 x86_64
User: mobilech (5348)
PHP: 8.1.34
Disabled: NONE
Upload Files
File: //proc/self/cwd/wp-content/plugins/wpforms/src/Pro/Forms/Fields/PaymentSingle/EntriesEdit.php
<?php

namespace WPForms\Pro\Forms\Fields\PaymentSingle;

/**
 * Editing Payment Single Item entries.
 *
 * @since 1.8.4
 */
class EntriesEdit extends \WPForms\Pro\Forms\Fields\Base\EntriesEdit {

	/**
	 * Constructor.
	 *
	 * @since 1.8.4
	 */
	public function __construct() {

		parent::__construct( 'payment-single' );
	}

	/**
	 * Display the field on the Edit Entry page.
	 *
	 * @since 1.8.4
	 *
	 * @param array $entry_field Entry field data.
	 * @param array $field       Field data and settings.
	 * @param array $form_data   Form data and settings.
	 */
	public function field_display( $entry_field, $field, $form_data ) {

		// We need to update the price key to match the field display method.
		$field['price'] = isset( $entry_field['amount_raw'] ) ? $entry_field['amount_raw'] : '';

		$this->field_object->field_display( $field, null, $form_data );
	}
}