Exemple #1
0
        /// <summary>
        /// Creates a TextCell from a record and attaches a Command to select the item
        /// </summary>
        private TextCell CreateCellFromRecord(AbstractRecord record)
        {
            Command selectRecordCommand =
                new Command(async() =>
            {
                this.parentRecord.LinkedRecords.Add(record);
                await this.Navigation.PopAsync();
            });

            var cell = new TextCell
            {
                Text    = record.ToString(),
                Command = selectRecordCommand
            };

            return(cell);
        }