コード例 #1
0
        public IActionResult Addcand(cand c)
        {
            vtype vt = new vtype();
            cand  cc = new cand
            {
                Name       = c.Name,
                profession = c.profession,
                vtypeId    = c.vtypeId
            };

            ViewData["vtypeId"] = new SelectList(_context.vtype, "vtypeId", "vtypeId", c.vtypeId);
            icnd.Add(cc);
            return(RedirectToAction("Addcand"));
        }
コード例 #2
0
        public IActionResult addvoter(avoter av)
        {
            vtype vt = new vtype();
            //  await rolemanager.CreateAsync(role);
            avoter a = new avoter
            {
                Name     = av.Name,
                password = av.password,
                vtypeId  = av.vtypeId
            };

            ViewData["vtypeId"] = new SelectList(_context.vtype, "vtypeId", "vtypeId", av.vtypeId);
            ia.Add(a);
            return(RedirectToAction("addvoter"));
        }
コード例 #3
0
        public IActionResult Createv(vtype v)
        {
            //  await rolemanager.CreateAsync(role);
            vtype vt = new vtype
            {
                voting_type = v.voting_type,
                start_date  = v.start_date,
                end_date    = v.end_date,
                no          = v.no
            };

            ic.Add(vt);
            return(View("Createv"));
            //return RedirectToAction("ahome");
        }
コード例 #4
0
 public bluntVar(int Offset, vtype Type, String ObjectType)
 {
     offset     = Offset;
     type       = Type;
     objectType = ObjectType;
 }
コード例 #5
0
ファイル: bluntParam.cs プロジェクト: kevinmiles/rc24
 public bluntParam(vtype t, int constValue)
 {
     ptype         = t;
     constantValue = constValue;
     name          = "";
 }
コード例 #6
0
ファイル: bluntParam.cs プロジェクト: kevinmiles/rc24
 public bluntParam(vtype t)
 {
     ptype = t;
     name  = "";
 }
コード例 #7
0
ファイル: bluntParam.cs プロジェクト: kevinmiles/rc24
 public bluntParam(vtype t, String n)
 {
     ptype = t;
     name  = n;
 }
コード例 #8
0
ファイル: bluntParam.cs プロジェクト: kevinmiles/rc24
 public bluntParam(vtype t, String n, ParamLocation l)
 {
     ptype    = t;
     name     = n;
     location = l;
 }