示例#1
0
        public void CreateNewNoteButton(string noteText)
        {
            if (!String.IsNullOrEmpty(noteText))
            {
                var fragment = fragmentManager.FindFragmentById(containerId) as CommonTabFragment;

                if (fragment != null)
                {
                    var groupName = actionBar.SelectedTab.Text;

                    if (CheckEnteredNoteName(noteText))
                    {
                        textField.Text = String.Empty;
                        fragment.CreateNewNoteButton(noteText);
                        noteService.Add(new Note()
                        {
                            GroupName = groupName, Name = noteText
                        });
                    }
                }
            }
        }
示例#2
0
 public IActionResult Post(T input)
 {
     service.Add(input);
     return(CreatedAtRoute(new { input.Id }, input));
 }