Jump to content

[CMS App] Database Record Downloads


Recommended Posts

I've found the database app an interesting tool to build on.  Oddly, there is no ability to download records.  I thought about why this might be and looked at the database.  Is it because the cms_custom_database_n tables use the custom database field id in the column names instead of using the custom database field's field_key value?

This block in applications/cms/sources/Fields/Fields.php would need to be updated to replace hyphens with underscores:

			if ( \is_array( $values['field_title'] ) )
			{
				/* We need to make sure the internal pointer on the array is on the first element */
				reset( $values['field_title'] );
				$values['field_key'] = \IPS\Http\Url\Friendly::seoTitle( $values['field_title'][ key( $values['field_title'] ) ] );
			}
			else
			{
				$values['field_key'] = \IPS\Http\Url\Friendly::seoTitle( $values['field_title'] );
			}

 

Edited by Steven W.
Link to comment
Share on other sites

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...