private void ButtonCfBase_OnClick(object sender, RoutedEventArgs e) { var btn = sender as Button; if (btn == null) { return; } CrowData data = btn.DataContext as CrowData; if (data != null) { OnSelectHandle?.Invoke(null, data); } }
private void ButtonCfBase_OnClick(object sender, RoutedEventArgs e) { var btn = sender as Button; if (btn == null) { return; } CrowData data = btn.DataContext as CrowData; if (data != null) { TopDataModel model = new TopDataModel(); model.ImgaeUrl = data.FrontImg; model.SourceId = data.Id; model.SourceType = "众筹"; model.SourceTypeInt = 2; model.Title = data.Title; OnItemSelected?.Invoke(null, model); } }