- Timestamp:
- 05/07/11 18:44:15 (14 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
TabularUnified branches/WebApplication/MVC2/HLWebOKBQueryPlugin/Controllers/ChartController.cs ΒΆ
r6118 r6165 8 8 using HLWebOKBQueryPlugin.OKBQueryService; 9 9 10 namespace HLWebOKBQueryPlugin.Controllers 11 { 12 public class ChartController : Controller 13 { 14 // 15 // GET: /Chart/ 10 namespace HLWebOKBQueryPlugin.Controllers { 11 public class ChartController : Controller { 12 // 13 // GET: /Chart/ 16 14 17 15 18 public ActionResult UpdateBubbleChart(FormCollection collection) 19 { 16 public ActionResult UpdateBubbleChart(FormCollection collection) { 20 17 21 18 22 String selectedAxisX = collection.Get("valuesAxisXCombobox"); 23 String selectedAxisY = collection.Get("valuesAxisYCombobox"); 24 String selectedBubbleSize = collection.Get("bubbleSizeCombobox"); 25 26 27 ChartModel cm = new ChartModel(); 19 String selectedAxisX = collection.Get("valuesAxisXCombobox"); 20 String selectedAxisY = collection.Get("valuesAxisYCombobox"); 21 String selectedBubbleSize = collection.Get("bubbleSizeCombobox"); 28 22 29 // Later, we will get the runs from the session ... 30 QueryServiceClient client = Query.GetClientFactory("okbtester", "okbtester"); 23 Response.Write("axis x => " + selectedAxisX); 24 Response.Write("axis y => " + selectedAxisY); 25 Response.Write("size => " + selectedBubbleSize); 31 26 32 long[] runIds = new long[5]; 33 for (int i = 0; i < 5; i++) 34 { 35 runIds[i] = i; 36 } 37 Run[] runs = client.GetRuns(runIds, false); 27 ChartModel cm = new ChartModel(); 38 28 39 cm.UpdateRunCollection(runs);40 cm.UpdateBubbleChart(selectedAxisY, selectedAxisX, selectedBubbleSize);29 // Later, we will get the runs from the session ... 30 QueryServiceClient client = Query.GetClientFactory("okbtester", "okbtester"); 41 31 42 return View(cm); 43 } 32 long[] runIds = new long[5]; 33 for (int i = 0; i < 5; i++) { 34 runIds[i] = i; 35 } 36 Run[] runs = client.GetRuns(runIds, false); 37 38 cm.UpdateRunCollection(runs); 39 cm.UpdateBubbleChart(selectedAxisY, selectedAxisX, selectedBubbleSize); 40 41 return View("Index",cm); 42 } 44 43 45 44 46 public ActionResult Index() 47 { 48 ChartModel cm = new ChartModel(); 45 public ActionResult Index() { 46 ChartModel cm = new ChartModel(); 49 47 50 51 48 // Later, we will get the runs from the session ... 49 QueryServiceClient client = Query.GetClientFactory("okbtester", "okbtester"); 52 50 53 long[] runIds = new long[5]; 54 for (int i = 0; i < 5; i++) 55 { 56 runIds[i] = i; 57 } 58 Run[] runs = client.GetRuns(runIds, false); 51 long[] runIds = new long[5]; 52 for (int i = 0; i < 5; i++) { 53 runIds[i] = i; 54 } 55 Run[] runs = client.GetRuns(runIds, false); 59 56 60 57 cm.UpdateRunCollection(runs); 61 58 62 59 63 64 60 return View(cm); 61 } 65 62 66 // [ChildActionOnly] 67 public ActionResult BubbleChart() 68 { 69 ChartModel cm = new ChartModel(); 63 // [ChildActionOnly] 64 public ActionResult BubbleChart() { 65 ChartModel cm = new ChartModel(); 70 66 71 return PartialView("BubbleChart",cm); // name of usercontrol72 67 return PartialView("BubbleChart", cm); // name of usercontrol 68 } 73 69 74 70 75 76 77 78 71 //public ActionResult BoxPlot() 72 //{ 73 // return View(); 74 //} 79 75 80 76 } 81 77 }
Note: See TracChangeset
for help on using the changeset viewer.