In MVC and want create dynamic DropDown which is depending upon Date Filed. How Can I Write Code for Json and use same in View
I write following Json Code
- public JsonResult GetAttnList(string ProductionDate)
- {
- Response.CacheControl = "no-cache";
- LPDBContext DB = new LPDBContext();
- List
AtnList = db.Attens.Where(x => x.ATTNDATE.ToShortDateString().Equals(ProductionDate)).ToList(); - return Json(AtnList, JsonRequestBehavior.AllowGet);
- }
- $("#PRDate").change(function () {
- $.get("/Dailyproduction/GetAttnList", { ProductionDate: $("#PRDate").val() }, function (data) {
- $("#ATTNSYSID").empty();
- $.each(data, function (index, row) {
- $("#ATTNSYSID").append("")
- });


Catcher WongRank #286 · 8.8K reputationPosted Jul 27, 2017, 6:26 AM EDT
Raju FodseRank #5,917 · 282 reputationPosted Jul 27, 2017, 8:15 PM EDT
Add Daily Production
Catcher WongRank #286 · 8.8K reputationPosted Jul 27, 2017, 11:05 PM EDT