Пример #1
0
    public ActionResult BlobData(Balldata BlobAllData) {
      // 日付検索時にここに来る。

      var loginuser = RDB.db.Users.Where(p => p.idName.Equals(User.Identity.Name)).Single();
      var module = loginuser.Modules.Where(p => p.Name.Equals(BlobAllData.ModuleName)).Single();
      int id = module.id;

      BlobAdd blobdata = GetBlobAllData(id, BlobAllData.date);

      BlobAllData.Type = blobdata.type;

      // 日付範囲内のデータの最新20件を取得
      blobdata.dataaddlist = GetBlobData_Date(blobdata.dataaddlist, BlobAllData.DateStart, BlobAllData.DateEnd);
      BlobAllData.data = GetBlobData_Take(blobdata.dataaddlist, 1);

      BlobAllData.NumData = blobdata.dataaddlist.Count;
      BlobAllData.TakeNum = 1;
      BlobAllData.Id = id;

      return View(BlobAllData);
    }
Пример #2
0
    public ActionResult BlobData(string ModuleName, string date, int takenum, string DateStart, string DateEnd) {

      Balldata BlobAllData = new Balldata();

      var loginuser = RDB.db.Users.Where(p => p.idName.Equals(User.Identity.Name)).Single();
      var module = loginuser.Modules.Where(p => p.Name.Equals(ModuleName)).Single();
      int id = module.id;

      BlobAdd blobdata = GetBlobAllData(id, date);  // Blob内のデータを全取得

      BlobAllData.ModuleName = ModuleName;
      BlobAllData.FileName = blobdata.filename;
      BlobAllData.date = date;
      BlobAllData.Type = blobdata.type;

      blobdata.dataaddlist = GetBlobData_Date(blobdata.dataaddlist, DateStart, DateEnd);  // 日付範囲内のデータを取得
      BlobAllData.data = GetBlobData_Take(blobdata.dataaddlist, takenum); // 日付範囲内のデータの内、次の20件を取得

      BlobAllData.NumData = blobdata.dataaddlist.Count;
      BlobAllData.TakeNum = takenum;
      BlobAllData.Id = id;
      BlobAllData.DateStart = DateStart;
      BlobAllData.DateEnd = DateEnd;

      return View(BlobAllData);
    }