bklLiudl
2024-07-23 675b8bcc4a3630d95e3d0b97d933e63442075ecb
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
using Lib;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.Mvc;
using BLL;
using Common;
 
using Model;
namespace wms.Areas.SyetemSet.Controllers
{
    public class DepartMentController : MasterPage
    {
        // GET: SyetemSet/DepartMent
        [LoginFilter]
        public ActionResult Index()
        {
            ViewBag.Title = "部门管理";
            return View();
        }
 
        [LoginFilter]
        public ActionResult AddDepartMent()
        {
            string ResNum = Request.QueryString.Get("DepartNum");
            string AccessCode = Request.QueryString.Get("AccessCode");
            if (ResNum.IsEmpty())
            {
                ViewBag.AccessCode = LocalHelper.GetDictionaryCodeHtml("Access");
                ViewBag.Depart = new DepartMent();
            }
            else
            {
                IDALDepartMent provider = new DALDepartMent();
                DepartMent entity = provider.GetModel(ResNum);
                entity = entity == null ? new DepartMent() : entity;
                ViewBag.Depart = LocalHelper.GetDepartList(entity.DepartNum);
                ViewBag.AccessCode = LocalHelper.GetDictionaryCodeHtml("Access", entity.AccessCode);
                ViewBag.Depart = entity;
 
            }
            return View();
        }
 
    }
}