Example #1
0
        public SysUserViewModels getUserView(string userCode, SysUserViewModels model)
        {
            SysUserViewModels temp = model;
            temp.userInfo = this.GetUserByUserCode(userCode);

            MstIndexTypeDAO mstIndexTypeDAO = new MstIndexTypeDAO(this.mapper);
            temp.indexTypeList = mstIndexTypeDAO.GetIndexTypeList(null, Constants.Status.Active);

            MstIndexTypeUserDAO mstIndexTypeUserDAO = new MstIndexTypeUserDAO(this.mapper);
            temp.indexTypeUserList = mstIndexTypeUserDAO.GetIndexTypeUserList(null, userCode, Constants.Flag.HasRight);

            MstAccessPackageDAO accessPackageDAO = new MstAccessPackageDAO(this.mapper);
            temp.packageList = accessPackageDAO.GetAccessPackageList(null, null, -1, Constants.Status.Active);

            temp.userCode = userCode;
            return temp;
        }
Example #2
0
        public ActionResult SearchMaster(MstIndexSearchModels model)
        {
            MstIndexTypeDAO indexTypeDAO = new MstIndexTypeDAO(this.mapper);
            model.indexTypeList = indexTypeDAO.GetIndexTypeList(null, Constants.Status.Active);
            MstIndexTypeModels allType = new MstIndexTypeModels();
            model.indexTypeList.Insert(0, allType);

            //if (model.isPublic)
            //{
            //    model.securityType = Constants.Type.Public;
            //}
            //else
            //{
            //    model.securityType = Constants.Type.Authority;
            //}

            if (model.isActive)
            {
                model.indexStatus = Constants.Status.Active;
            }
            else
            {
                model.indexStatus = Constants.Status.Inactive;
            }
            MstIndexDAO indexDAO = new MstIndexDAO(this.mapper);
            model = indexDAO.searchIndex(model, Constants.Term.ShortTerm);
            return View("IndexMaster", model);
        }
Example #3
0
 public ActionResult IndexManagement(IndexManagementModels model)
 {
     MstIndexTypeDAO indexTypeDAO = new MstIndexTypeDAO(this.mapper);
     model.indexTypeList = indexTypeDAO.GetIndexTypeList(null, Constants.Status.Active);
     MstIndexTypeModels allType = new MstIndexTypeModels();
     model.indexTypeList.Insert(0, allType);
     IdxIndexDAO indexDAO = new IdxIndexDAO(this.mapper);
     indexDAO.DeleteIndex(model.indexTypeCode, model.indexCode, model.fromTime, model.toTime, model.term);
     model.infoMessage = PsMModel.Resource.MsgSuccess;
     return View(model);
 }
Example #4
0
        public ActionResult IndexMaster()
        {
            MstIndexSearchModels model = new MstIndexSearchModels();
            MstIndexDAO indexDAO = new MstIndexDAO(this.mapper);
            model.pageIndex = 1;
            model.securityType = Constants.Type.Public;
            model.securityType = Constants.Status.Active;
            model.isPublic = true;
            model.isActive = true;
            //model = indexDAO.searchIndex(model);

            MstIndexTypeDAO indexTypeDAO = new MstIndexTypeDAO(this.mapper);
            model.indexTypeList = indexTypeDAO.GetIndexTypeList(null, Constants.Status.Active);
            MstIndexTypeModels allType = new MstIndexTypeModels();
            model.indexTypeList.Insert(0, allType);
            return View(model);
        }
Example #5
0
 public ActionResult IndexManagement()
 {
     IndexManagementModels model = new IndexManagementModels();
     MstIndexTypeDAO indexTypeDAO = new MstIndexTypeDAO(this.mapper);
     model.indexTypeList = indexTypeDAO.GetIndexTypeList(null, Constants.Status.Active);
     MstIndexTypeModels allType = new MstIndexTypeModels();
     model.indexTypeList.Insert(0, allType);
     return View(model);
 }