专家管理  前台申请专家   ,后台审批专家   ,评审品目为下拉多选框
项目录入 专家替换字符:'(组长)','(组长)',',','(评审组长)','(评审组长)',';','评审组长:','组长:'

供应商行业分类维护

考勤规则 修改

项目录入重复判断
17个文件已修改
5个文件已添加
2229 ■■■■■ 已修改文件
zhengcaioa/CommonToolsCore/AutoMapperConfigs.cs 7 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
zhengcaioa/DTO/AdmAttendanceRuleDTO.cs 57 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
zhengcaioa/DTO/ExpertDTO.cs 7 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
zhengcaioa/IServices/IAdmAttendanceRuleService.cs 23 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
zhengcaioa/Model/AdmAskLeaveOff.cs 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
zhengcaioa/Model/AdmAttendanceRulesDtl.cs 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
zhengcaioa/Model/zhengcaioaContext.cs 29 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
zhengcaioa/Services/AdmAttendanceRuleService.cs 238 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
zhengcaioa/Services/ExpertService.cs 85 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
zhengcaioa/Services/ProjectService.cs 10 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
zhengcaioa/zhengcaioa/Controllers/AdmManagement/SigninController.cs 85 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
zhengcaioa/zhengcaioa/Controllers/Expert/ExpertController.cs 13 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
zhengcaioa/zhengcaioa/Controllers/Expert/ExpertsApplyController.cs 160 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
zhengcaioa/zhengcaioa/Controllers/ProjectController.cs 4 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
zhengcaioa/zhengcaioa/Startup.cs 3 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
zhengcaioa/zhengcaioa/Views/CooperatecustomCustomer/Edit.cshtml 2 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
zhengcaioa/zhengcaioa/Views/Expert/Edit.cshtml 53 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
zhengcaioa/zhengcaioa/Views/Expert/Index.cshtml 9 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
zhengcaioa/zhengcaioa/Views/ExpertsApply/ExpertsApply.cshtml 927 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
zhengcaioa/zhengcaioa/Views/ExpertsApply/Index.cshtml 124 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
zhengcaioa/zhengcaioa/Views/Project/Add.cshtml 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
zhengcaioa/zhengcaioa/Views/Signin/AttendanceRule.cshtml 385 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
zhengcaioa/CommonToolsCore/AutoMapperConfigs.cs
@@ -140,8 +140,11 @@
            CreateMap<AdmMemoBookDTO, AdmMemoBook>();
 
            CreateMap<AdmAttendanceRulesDtl, AdmAttendanceRulesDtlDTO>();
            CreateMap<AdmAttendanceRulesDtlDTO, AdmAttendanceRule>();
            CreateMap<AdmAttendanceRulesDtlDTO, AdmAttendanceRulesDtl>();
            CreateMap<AdmAttendanceRule, AdmAttendanceRuleDTO>();
            CreateMap<AdmAttendanceRuleDTO, AdmAttendanceRule>();
            CreateMap<AdmBreakPrecedent, AdmBreakPrecedentDTO>();
            CreateMap<AdmBreakPrecedentDTO, AdmBreakPrecedent>();
zhengcaioa/DTO/AdmAttendanceRuleDTO.cs
@@ -8,14 +8,46 @@
    public partial class AdmAttendanceRuleDTO
    {
        public string Id { get; set; }
        public string Code { get; set; }
        public string Name { get; set; }
        public string Remark { get; set; }
        public int WeekStart { get; set; }
        public int WeekEnd { get; set; }
        public string WorkingStart { get; set; }
        public string WorkingEnd { get; set; }
        public string OffworkStart { get; set; }
        public string OffworkEnd { get; set; }
        public decimal FullAttendance { get; set; }
        public decimal LatePayment1 { get; set; }
        public decimal LatePayment2 { get; set; }
        public decimal LatePayment3 { get; set; }
        public decimal LatePayment4 { get; set; }
        public decimal Absenteeism { get; set; }
        public decimal AbsenteeismPayment1 { get; set; }
        public decimal AbsenteeismPayment2 { get; set; }
        public decimal PersonalPayment1 { get; set; }
        public decimal PersonalPayment2 { get; set; }
        public decimal PersonalPayment3 { get; set; }
        public decimal PersonalPayment4 { get; set; }
        public decimal SickPayment1 { get; set; }
        public decimal SickPayment2 { get; set; }
        public decimal SickPayment3 { get; set; }
        public decimal SickPayment4 { get; set; }
        public string Holiday { get; set; }
        public string Rest { get; set; }
        public int Gala { get; set; }
        public int Weekend1 { get; set; }
        public int Usually { get; set; }
        public string RecStatus { get; set; }
        public string Creater { get; set; }
        public DateTime Createtime { get; set; }
        public string Modifier { get; set; }
        public DateTime Modifytime { get; set; }
        public string[] holiday_s { get; set; }
        public string[] holiday_e { get; set; }
        public string[] rest_s { get; set; }
        public string[] rest_e { get; set; }
        public List<AdmAttendanceRulesDtlDTO> admAttendanceRulesDtlDTOs { get; set; }
    }
@@ -23,16 +55,17 @@
    /// 明细
    /// </summary>
    public partial class AdmAttendanceRulesDtlDTO
    {
    {
        public string Id { get; set; }
        public string Pid { get; set; }
        public string Value1 { get; set; }
        public string Value2 { get; set; }
        public string Value3 { get; set; }
        public string Value4 { get; set; }
        public string Value5 { get; set; }
        public string Value6 { get; set; }
        public string RecStatus { get; set; }
        public string ValueStart { get; set; }
        public string ValueEnd { get; set; }
        public string Name { get; set; }
        public string RecStatus { get; set; }
        public string Creater { get; set; }
        public DateTime Createtime { get; set; }
        public string Modifier { get; set; }
        public DateTime Modifytime { get; set; }
    }
}
zhengcaioa/DTO/ExpertDTO.cs
@@ -19,11 +19,15 @@
        public string Postal { get; set; }
        public string ExpertType { get; set; }
        public string Level { get; set; }
        public string LevelName { get; set; }
        public string Phone1 { get; set; }
        public string Phone2 { get; set; }
        public string Qq { get; set; }
        public string Wechat { get; set; }
        public string ReviewItem { get; set; }
        public string ReviewItemSelect { get; set; }
        public string CertiNumber { get; set; }
        public string CertiFont { get; set; }
        public string CertiBack { get; set; }
@@ -36,6 +40,7 @@
        public string Modifier { get; set; }
        public DateTime Modifytime { get; set; }
        public string TitileCerti1 { get; set; }
        public string ShenheStatus { get; set; }
        public string TitileCerti2 { get; set; }
        public string TitileCerti3 { get; set; }
        public string TitileCerti4 { get; set; }
@@ -61,6 +66,8 @@
        public string CertiNumber { get; set; }
        public string Phone1 { get; set; }
        public int JoinCount { get; set; }
        public string ShenheStatus { get; set; }
    }
    #endregion
zhengcaioa/IServices/IAdmAttendanceRuleService.cs
New file
@@ -0,0 +1,23 @@
using DTO;
using Microsoft.AspNetCore.Mvc.Rendering;
using System;
using System.Collections.Generic;
using System.Text;
using zhengcaioa.Models;
namespace IServices
{
    public interface IAdmAttendanceRuleService
    {
        ResultEntity save(AdmAttendanceRuleDTO dto);
        AdmAttendanceRuleDTO Get(string id);
        ResultEntity saveDtl(AdmAttendanceRulesDtlDTO dto);
        AdmAttendanceRulesDtlDTO GetDtl(string id);
        List<AdmAttendanceRulesDtlDTO> GetDtlList(string pid);
        ResultEntity RemoveDtlList(string pid);
    }
}
zhengcaioa/Model/AdmAskLeaveOff.cs
@@ -12,12 +12,12 @@
        public string Lavetype { get; set; }
        public DateTime? StratTime { get; set; }
        public DateTime? EndTime { get; set; }
        public string Remark { get; set; }
        public string MedicalRecord { get; set; }
        public string RecStatus { get; set; }
        public string Creater { get; set; }
        public DateTime Createtime { get; set; }
        public string Modifier { get; set; }
        public DateTime Modifytime { get; set; }
        public string Remark { get; set; }
    }
}
zhengcaioa/Model/AdmAttendanceRulesDtl.cs
@@ -9,8 +9,8 @@
    {
        public string Id { get; set; }
        public string Pid { get; set; }
        public DateTime ValueStart { get; set; }
        public DateTime ValueEnd { get; set; }
        public string ValueStart { get; set; }
        public string ValueEnd { get; set; }
        public string Name { get; set; }
        public string RecStatus { get; set; }
        public string Creater { get; set; }
zhengcaioa/Model/zhengcaioaContext.cs
@@ -210,9 +210,9 @@
            modelBuilder.Entity<AdmAttendanceRule>(entity =>
            {
                entity.HasNoKey();
                entity.ToTable("ADM_AttendanceRules");
                entity.Property(e => e.Id).HasMaxLength(50);
                entity.Property(e => e.Absenteeism)
                    .HasColumnType("decimal(18, 2)")
@@ -247,10 +247,6 @@
                    .IsRequired()
                    .HasMaxLength(50)
                    .HasColumnName("holiday");
                entity.Property(e => e.Id)
                    .IsRequired()
                    .HasMaxLength(50);
                entity.Property(e => e.LatePayment1)
                    .HasColumnType("decimal(18, 2)")
@@ -340,21 +336,19 @@
                entity.Property(e => e.Weekend1).HasColumnName("weekend");
                entity.Property(e => e.WorkingEnd)
                    .IsRequired()
                    .HasMaxLength(50)
                    .HasColumnName("working_end");
                entity.Property(e => e.WorkingStart)
                    .IsRequired()
                    .HasMaxLength(50)
                    .HasColumnName("working_start");
            });
            modelBuilder.Entity<AdmAttendanceRulesDtl>(entity =>
            {
                entity.HasNoKey();
                entity.ToTable("ADM_AttendanceRules_dtl");
                entity.Property(e => e.Id).HasMaxLength(50);
                entity.Property(e => e.Creater)
                    .IsRequired()
@@ -366,10 +360,6 @@
                    .HasColumnType("datetime")
                    .HasColumnName("createtime")
                    .HasDefaultValueSql("(getdate())");
                entity.Property(e => e.Id)
                    .IsRequired()
                    .HasMaxLength(50);
                entity.Property(e => e.Modifier)
                    .IsRequired()
@@ -385,7 +375,6 @@
                entity.Property(e => e.Name).HasMaxLength(200);
                entity.Property(e => e.Pid)
                    .IsRequired()
                    .HasMaxLength(50)
                    .HasColumnName("pid");
@@ -396,14 +385,12 @@
                    .HasDefaultValueSql("('A')");
                entity.Property(e => e.ValueEnd)
                    .HasColumnType("date")
                    .HasColumnName("value_end")
                    .HasDefaultValueSql("(getdate())");
                    .HasMaxLength(50)
                    .HasColumnName("value_end");
                entity.Property(e => e.ValueStart)
                    .HasColumnType("date")
                    .HasColumnName("value_start")
                    .HasDefaultValueSql("(getdate())");
                    .HasMaxLength(50)
                    .HasColumnName("value_start");
            });
            modelBuilder.Entity<AdmBreakPrecedent>(entity =>
zhengcaioa/Services/AdmAttendanceRuleService.cs
New file
@@ -0,0 +1,238 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using AutoMapper;
using DTO;
using IServices;
using Microsoft.AspNetCore.Mvc.Rendering;
using Microsoft.EntityFrameworkCore;
using zhengcaioa.Models;
namespace Services
{
   public class AdmAttendanceRuleService:IAdmAttendanceRuleService
    {
        private readonly zhengcaioaContext _context;
        private readonly IMapper _mapper;
        public AdmAttendanceRuleService(zhengcaioaContext context, IMapper mapper)
        {
            _context = context;
            _mapper = mapper;
        }
        public ResultEntity save(AdmAttendanceRuleDTO dto)
        {
            ResultEntity resultEntity = new ResultEntity();
            try
            {
                var entity = _mapper.Map<AdmAttendanceRule>(dto);
                if (String.IsNullOrEmpty(entity.Id))
                {
                    entity.Id = Guid.NewGuid().ToString();
                    dto.Id = entity.Id;
                    _context.AdmAttendanceRules.Add(entity);
                }
                else
                {
                    var updateproject = _context.AdmAttendanceRules.Find(entity.Id);
                    updateproject.WeekStart = entity.WeekStart;
                    updateproject.WeekEnd = entity.WeekEnd;
                    updateproject.WorkingStart = entity.WorkingStart;
                    updateproject.WorkingEnd = entity.WorkingEnd;
                    updateproject.OffworkStart = entity.OffworkStart;
                    updateproject.OffworkEnd = entity.OffworkEnd;
                    updateproject.FullAttendance = entity.FullAttendance;
                    updateproject.LatePayment1 = entity.LatePayment1;
                    updateproject.LatePayment2 = entity.LatePayment2;
                    updateproject.LatePayment3 = entity.LatePayment3;
                    updateproject.LatePayment4 = entity.LatePayment4;
                    updateproject.Absenteeism = entity.Absenteeism;
                    updateproject.AbsenteeismPayment1 = entity.AbsenteeismPayment1;
                    updateproject.AbsenteeismPayment2 = entity.AbsenteeismPayment2;
                    updateproject.PersonalPayment1 = entity.PersonalPayment1;
                    updateproject.PersonalPayment2 = entity.PersonalPayment2;
                    updateproject.PersonalPayment3 = entity.PersonalPayment3;
                    updateproject.PersonalPayment4 = entity.PersonalPayment4;
                    updateproject.SickPayment1 = entity.SickPayment1;
                    updateproject.SickPayment2 = entity.SickPayment2;
                    updateproject.SickPayment3 = entity.SickPayment3;
                    updateproject.SickPayment4 = entity.SickPayment4;
                    updateproject.Holiday = entity.Holiday;
                    updateproject.Rest = entity.Rest;
                    updateproject.Gala = entity.Gala;
                    updateproject.Weekend1 = entity.Weekend1;
                    updateproject.Usually = entity.Usually;
                    updateproject.RecStatus = entity.RecStatus;
                    updateproject.Modifier = entity.Modifier;
                    updateproject.Modifytime = entity.Modifytime;
                }
                _context.SaveChanges();
                resultEntity.ReturnID = entity.Id;
                resultEntity.Result = true;
            }
            catch (Exception ex)
            {
                resultEntity.Result = false;
                resultEntity.Message = "保存失败,请联系管理员";
            }
            return resultEntity;
        }
        public AdmAttendanceRuleDTO Get(string id)
        {
            var entity = new AdmAttendanceRule();
            if(string.IsNullOrEmpty(id))
                entity = _context.AdmAttendanceRules.FirstOrDefault();
            else
                entity = _context.AdmAttendanceRules.Find(id);
            if (entity == null)
            {
                entity = new AdmAttendanceRule();
            }
            var result = _mapper.Map<AdmAttendanceRuleDTO>(entity);
            return result;
        }
        public ResultEntity saveDtl(AdmAttendanceRulesDtlDTO dto)
        {
            ResultEntity resultEntity = new ResultEntity();
            try
            {
                var entity = _mapper.Map<AdmAttendanceRulesDtl>(dto);
                if (String.IsNullOrEmpty(entity.Id))
                {
                    entity.Id = Guid.NewGuid().ToString();
                    _context.AdmAttendanceRulesDtls.Add(entity);
                }
                else
                {
                    var updateproject = _context.AdmAttendanceRulesDtls.Find(entity.Id);
                    updateproject.Pid = entity.Pid;
                    updateproject.ValueStart = entity.ValueStart;
                    updateproject.ValueEnd = entity.ValueEnd;
                    updateproject.Name = entity.Name;
                    updateproject.RecStatus = entity.RecStatus;
                    updateproject.Modifier = entity.Modifier;
                    updateproject.Modifytime = entity.Modifytime;
                }
                _context.SaveChanges();
                resultEntity.ReturnID = entity.Id;
                resultEntity.Result = true;
            }
            catch (Exception ex)
            {
                resultEntity.Result = false;
                resultEntity.Message = "保存失败,请联系管理员";
            }
            return resultEntity;
        }
        public AdmAttendanceRulesDtlDTO GetDtl(string id)
        {
            var entity = new AdmAttendanceRulesDtl();
            if (string.IsNullOrEmpty(id))
                entity = _context.AdmAttendanceRulesDtls.FirstOrDefault();
            else
                entity = _context.AdmAttendanceRulesDtls.Find(id);
            if (entity == null)
            {
                entity = new AdmAttendanceRulesDtl();
            }
            var result = _mapper.Map<AdmAttendanceRulesDtlDTO>(entity);
            return result;
        }
        public List<AdmAttendanceRulesDtlDTO> GetDtlList(string pid)
        {
            var entity     = _context.AdmAttendanceRulesDtls.ToList();
            if (!string.IsNullOrEmpty(pid))
                entity = entity.Where(x => x.Pid == pid).ToList();
            var result = _mapper.Map<List<AdmAttendanceRulesDtlDTO>>(entity);
            return result;
        }
        public ResultEntity RemoveDtlList(string pid)
        {
            ResultEntity resultEntity = new ResultEntity();
            try
            {
              var admAttendanceRulesDtls =  _context.AdmAttendanceRulesDtls.Where(x => x.Pid == pid).ToList();
                foreach(var admAttendanceRulesDtl in admAttendanceRulesDtls)
                {
                    _context.AdmAttendanceRulesDtls.Remove(admAttendanceRulesDtl);
                }
                _context.SaveChanges();
                resultEntity.ReturnID = pid;
                resultEntity.Result = true;
            }
            catch (Exception ex)
            {
                resultEntity.Result = false;
                resultEntity.Message = "保存失败,请联系管理员";
            }
            return resultEntity;
        }
    }
}
zhengcaioa/Services/ExpertService.cs
@@ -72,6 +72,7 @@
                    updateplExpert.TitileCerti8 = expert.TitileCerti8;
                    updateplExpert.TitileCerti9 = expert.TitileCerti9;
                    updateplExpert.TitileCerti10 = expert.TitileCerti10;
                    updateplExpert.ShenheStatus = expert.ShenheStatus;
                }
                _context.SaveChanges();
@@ -100,6 +101,26 @@
        public ResultDataEntity<ExpertDTO> SearchByPaging(ExpertDTOSearch searchEntity) 
        {
            var listCode = (from a in _context.SysCodeDtls
                            join b in _context.SysCodes
                            on a.CodeId equals b.Id
                            where a.RecStatus == "A"
                                          && b.RecStatus == "A"
                            select new CodeDataEntity()
                            {
                                CodeId = b.Id,
                                CodeTable = b.CodeTable,
                                CodeField = b.CodeField,
                                CodeSn = a.CodeSn,
                                Comments = a.Comments,
                                Contents = a.Contents,
                                RecStatus = a.RecStatus,
                                Sort = a.Sort
                            }
                      );
            ResultDataEntity<ExpertDTO> data = new ResultDataEntity<ExpertDTO>();
            List<ExpertDTO> list = new List<ExpertDTO>();
            //筛选
@@ -108,18 +129,72 @@
                         {
                             ExpertId = q.Key.ExpertId,
                             JoinCount = q.Count(),
                         }
                          )
                         })
                       on a.Id equals h.ExpertId
                      into hsss
                         from hhh in hsss.DefaultIfEmpty()
                         join c in listCode.Where(x => x.CodeTable == "experts" && x.CodeField == "level")
                        on a.Level equals c.CodeSn
                        into csss
                         from ccc in csss.DefaultIfEmpty()
                         where a.RecStatus == "A"
                          && (searchEntity.JoinCount<=0 || hhh.JoinCount >= searchEntity.JoinCount)
                         select a).ToList();
                         select new ExpertDTO
                         {
                             Id = a.Id,
                             Name = a.Name,
                             Sex = a.Sex,
                             InfoSource = a.InfoSource,
                             IdCard = a.IdCard,
                             Province = a.Province,
                             AreaId = a.AreaId,
                             City = a.City,
                             Address = a.Address,
                             Postal = a.Postal,
                             ExpertType = a.ExpertType,
                             Level = a.Level,
                             LevelName = ccc.Comments,
                             Phone1 = a.Phone1,
                             Phone2 = a.Phone2,
                             Qq = a.Qq,
                             Remark = a.Remark,
                             Creater = a.Creater,
                             Createtime = a.Createtime,
                             RecStatus = a.RecStatus,
                             Modifier = a.Modifier,
                             Modifytime = a.Modifytime,
                             Wechat = a.Wechat,
                             ReviewItem = a.ReviewItem,
                             CertiNumber = a.CertiNumber,
                             CertiFont = a.CertiFont,
                             CertiBack = a.CertiBack,
                             TitileCerti = a.TitileCerti,
                             Sort = a.Sort,
                             ShenheStatus = a.ShenheStatus,
                         }).ToList();
            if (!string.IsNullOrEmpty(searchEntity.Name))
            {
                query = query.Where(m => m.Name.Contains(searchEntity.Name)).ToList();
            }
            if (!string.IsNullOrEmpty(searchEntity.ShenheStatus))
            {
                query = query.Where(m => m.ShenheStatus == searchEntity.ShenheStatus).ToList();
            }
            if (!string.IsNullOrEmpty(searchEntity.ExpertType))
            {
@@ -167,9 +242,9 @@
            if (searchEntity.totalrows == 0)
                searchEntity.totalrows = query.Count();
            var expertlist = query.Skip((searchEntity.page - 1) * searchEntity.rows).Take(searchEntity.rows).ToList();
            list = _mapper.Map<List<ExpertDTO>>(expertlist);
            //list = _mapper.Map<List<ExpertDTO>>(expertlist);
            data.LoadData(searchEntity, list);
            data.LoadData(searchEntity, expertlist);
            return data;
        
        }
zhengcaioa/Services/ProjectService.cs
@@ -27,6 +27,16 @@
            ResultEntity resultEntity = new ResultEntity();
            try
            {
                var checkUserSn = _context.Projects.Where(x => x.Name == projectDTO.Name && x.RecStatus == "A" && x.Id != projectDTO.Id).FirstOrDefault();
                if (checkUserSn != null && (string.IsNullOrWhiteSpace(projectDTO.Id) || (!string.IsNullOrWhiteSpace(projectDTO.Id) && checkUserSn.Id != projectDTO.Id)))
                {
                    resultEntity.Result = false;
                    resultEntity.Message = "项目重复";
                    return resultEntity;
                }
                var project = _mapper.Map<Project>(projectDTO);
                // var ZhuanjiaList = projectDTO.ZhuanjiaList;
                //if(ZhuanjiaList!=null&& ZhuanjiaList.Length > 0)
zhengcaioa/zhengcaioa/Controllers/AdmManagement/SigninController.cs
@@ -10,6 +10,7 @@
using zhengcaioa.Models;
using Microsoft.AspNetCore.Http;
using Newtonsoft.Json.Linq;
using System.Transactions;
namespace zhengcaioa.Controllers.AdmManagement
{
@@ -18,12 +19,15 @@
        private readonly ILogger<SigninController> _logger;
        private readonly IAdmSigninService _signinService;
        private readonly ISysAttachmentService _sysAttachmentService;
        private readonly IAdmAttendanceRuleService _attendanceRuleService;
        [CheckLogin]
        public SigninController(ILogger<SigninController> logger, IAdmSigninService signinService, ISysAttachmentService sysAttachmentService)
        public SigninController(ILogger<SigninController> logger, IAdmSigninService signinService, ISysAttachmentService sysAttachmentService
            , IAdmAttendanceRuleService attendanceRuleService)
        {
            _logger = logger;
            _signinService = signinService;
            _sysAttachmentService = sysAttachmentService;
            _attendanceRuleService = attendanceRuleService;
        }
        #region 考勤签到打卡
@@ -236,25 +240,80 @@
        #region 考勤规则
        public IActionResult AttendanceRule()
        {
            AdmAttendanceRuleDTO admAttendanceRuleDTO =  _attendanceRuleService.Get("");
            admAttendanceRuleDTO.admAttendanceRulesDtlDTOs = _attendanceRuleService.GetDtlList("");
            ViewData.Model = admAttendanceRuleDTO;
            return View();
        }
        public string SaveAttendanceRule(object leaveOff)
        public string SaveAttendanceRule(AdmAttendanceRuleDTO dto)
        {
            ResultEntity resultEntity = new ResultEntity();
            dto.Holiday = "1";
            dto.Rest = "1";
            resultEntity.Result = false;
            var curentuser = JsonConvert.DeserializeObject<PltUser>(HttpContext.Session.GetString("User"));
            ViewData["curentuser"] = curentuser;
            //leaveOff.RecStatus = "A";
            //if (String.IsNullOrEmpty(leaveOff.Id))
            //{
            //    leaveOff.Creater = curentuser.Id;
            //    leaveOff.Createtime = DateTime.Now;
            //}
            //leaveOff.Modifier = curentuser.Id;
            //leaveOff.Modifytime = DateTime.Now;
            using (TransactionScope scope = new TransactionScope())
            {
                dto.RecStatus = "A";
                if (String.IsNullOrEmpty(dto.Id))
                {
                    dto.Creater = curentuser.Id;
                    dto.Createtime = DateTime.Now;
                }
                dto.Modifier = curentuser.Id;
                dto.Modifytime = DateTime.Now;
            //ResultEntity resultEntity = _signinService.SaveAskLeaveOff(leaveOff);
            var ss = leaveOff;
            return JsonConvert.SerializeObject(null);
                resultEntity = _attendanceRuleService.save(dto);
                _attendanceRuleService.RemoveDtlList(dto.Id);
                for (int i = 0; i < dto.holiday_s.Length; i++)
                {
                    if(!String.IsNullOrEmpty(dto.holiday_s[i]) && !String.IsNullOrEmpty(dto.holiday_e[i]))
                    {
                        AdmAttendanceRulesDtlDTO admAttendanceRulesDtlDTO = new AdmAttendanceRulesDtlDTO();
                        admAttendanceRulesDtlDTO.Pid = dto.Id;
                        admAttendanceRulesDtlDTO.ValueStart = dto.holiday_s[i];
                        admAttendanceRulesDtlDTO.ValueEnd = dto.holiday_e[i];
                        admAttendanceRulesDtlDTO.Name = "jiejiari";
                        admAttendanceRulesDtlDTO.RecStatus = "A";
                        admAttendanceRulesDtlDTO.Creater = curentuser.Id;
                        admAttendanceRulesDtlDTO.Createtime = DateTime.Now;
                        admAttendanceRulesDtlDTO.Modifier = admAttendanceRulesDtlDTO.Creater;
                        admAttendanceRulesDtlDTO.Modifytime = admAttendanceRulesDtlDTO.Createtime;
                        resultEntity = _attendanceRuleService.saveDtl(admAttendanceRulesDtlDTO);
                    }
                }
                for (int i = 0; i < dto.rest_s.Length; i++)
                {
                    if (!String.IsNullOrEmpty(dto.rest_s[i]) && !String.IsNullOrEmpty(dto.rest_e[i]))
                    {
                        AdmAttendanceRulesDtlDTO admAttendanceRulesDtlDTO = new AdmAttendanceRulesDtlDTO();
                        admAttendanceRulesDtlDTO.Pid = dto.Id;
                        admAttendanceRulesDtlDTO.ValueStart = dto.rest_s[i];
                        admAttendanceRulesDtlDTO.ValueEnd = dto.rest_e[i];
                        admAttendanceRulesDtlDTO.Name = "tiaoxiuri";
                        admAttendanceRulesDtlDTO.RecStatus = "A";
                        admAttendanceRulesDtlDTO.Creater = curentuser.Id;
                        admAttendanceRulesDtlDTO.Createtime = DateTime.Now;
                        admAttendanceRulesDtlDTO.Modifier = admAttendanceRulesDtlDTO.Creater;
                        admAttendanceRulesDtlDTO.Modifytime = admAttendanceRulesDtlDTO.Createtime;
                        resultEntity = _attendanceRuleService.saveDtl(admAttendanceRulesDtlDTO);
                    }
                }
                scope.Complete();
            }
            //  var ss = leaveOff;
            return JsonConvert.SerializeObject(resultEntity);
        }
        #endregion
    }
zhengcaioa/zhengcaioa/Controllers/Expert/ExpertController.cs
@@ -55,7 +55,7 @@
            ViewBag.level = _liaotianService.GetSYScode("experts", "level").Select(x => new { code = x.CodeSn, label = x.Comments }).ToList();
            ViewBag.Province = _projectService.Getsheng().Select(x => new { code = x.CodeId, label = x.Name }).ToList();
            //  ViewBag.City = _projectService.Getshi( ).Select(x => new { code = x.CodeId, label = x.Name }).ToList();
            ViewBag.level = _liaotianService.GetSYScode("experts", "level").Select(x => new { code = x.CodeSn, label = x.Comments }).ToList();
            ViewBag.ReviewItem = _liaotianService.GetSYScode("experts", "ReviewItem").Select(x => new { code = x.CodeSn, label = x.Comments }).ToList();
            return View();
        }
@@ -64,6 +64,7 @@
        public string GetList(ExpertDTOSearch search)
        {
            var curentuser = JsonConvert.DeserializeObject<PltUser>(HttpContext.Session.GetString("User"));
            search.ShenheStatus = "A";
            ViewData["curentuser"] = curentuser;
            return JsonConvert.SerializeObject(_expertService.SearchByPaging(search));
        }
@@ -105,7 +106,7 @@
            ViewBag.sex = _liaotianService.GetSYScode("plt_user", "sex");//.Select(x => new { code = x.CodeSn, label = x.Comments }).ToList();
            ViewBag.expertType = _liaotianService.GetSYScode("experts", "expertType");//.Select(x => new { code = x.CodeSn, label = x.Comments }).ToList();
            ViewBag.level = _liaotianService.GetSYScode("experts", "level");//.Select(x => new { code = x.CodeSn, label = x.Comments }).ToList();
            ViewBag.ReviewItem = _liaotianService.GetSYScode("experts", "ReviewItem");//.Select(x => new { code = x.CodeSn, label = x.Comments }).ToList();
            ViewBag.Province = _projectService.Getsheng();//.Select(x => new { code = x.CodeId, label = x.Name }).ToList();             
@@ -180,6 +181,8 @@
        {
            var curentuser = JsonConvert.DeserializeObject<PltUser>(HttpContext.Session.GetString("User"));
            ViewData["curentuser"] = curentuser;
            data.ShenheStatus = "A";
            data.ReviewItem = data.ReviewItemSelect;
            data.RecStatus = "A";
            if (String.IsNullOrEmpty(data.Id))
            {
@@ -346,5 +349,11 @@
        }
        #endregion
    }
}
zhengcaioa/zhengcaioa/Controllers/Expert/ExpertsApplyController.cs
New file
@@ -0,0 +1,160 @@
using Microsoft.AspNetCore.Mvc;
using System;
using System.Collections.Generic;
using System.Linq;
using Microsoft.Extensions.Logging;
using IServices;
using DTO;
using Newtonsoft.Json;
using zhengcaioa.Models;
using Microsoft.AspNetCore.Http;
using zhengcaioa.IService;
using System.IO;
using Microsoft.Extensions.Configuration;
namespace zhengcaioa.Controllers.Expert
{
    public class ExpertsApplyController : Controller
    {
        private readonly ILogger<ExpertsApplyController> _logger;
        private readonly IExpertService _expertService;
        private readonly ILiaotianService _liaotianService;
        private readonly IProjectService _projectService;
        private readonly IUserService _userService;
        public ExpertsApplyController(ILogger<ExpertsApplyController> logger, IExpertService expertService, IProjectService projectService, ILiaotianService liaotianService, IUserService userService)
        {
            _logger = logger;
            _expertService = expertService;
            _projectService = projectService;
            _liaotianService = liaotianService;
            _userService = userService;
        }
        #region 专家申请,评审
        public ActionResult ExpertsApply(string id = null)
        {
            var curentuser = JsonConvert.DeserializeObject<PltUser>(HttpContext.Session.GetString("User"));
            ViewData["curentuser"] = curentuser;
            List<ActionEntity> actionlist = new List<ActionEntity>();
            ActionEntity actionEntity = new ActionEntity();
            actionEntity.OpenType = 0;
            actionEntity.ActionUrl = "";
            actionEntity.ActionFun = "Save";
            actionEntity.PageIco = "glyphicon glyphicon-ok";
            actionEntity.ActionName = "保存";
            actionlist.Add(actionEntity);
            ViewData["ActionInfo"] = actionlist;
            ExpertDTO expertDTO = new ExpertDTO();
            if (!string.IsNullOrEmpty(id))
            {
                expertDTO = _expertService.Get(id);
            }
            else
            {
                expertDTO.Province = "510000";
                expertDTO.City = "510100";
            }
            // var sheng = _projectService.Getsheng();
            // ViewBag.InfoSource = _liaotianService.GetSYScode("CooperatecustomCustomer", "khly");//.Select(x => new { code = x.CodeSn, label = x.Comments }).ToList();
            ViewBag.sex = _liaotianService.GetSYScode("plt_user", "sex");//.Select(x => new { code = x.CodeSn, label = x.Comments }).ToList();
                                                                         // ViewBag.expertType = _liaotianService.GetSYScode("experts", "expertType");//.Select(x => new { code = x.CodeSn, label = x.Comments }).ToList();
                                                                         //  ViewBag.level = _liaotianService.GetSYScode("experts", "level");//.Select(x => new { code = x.CodeSn, label = x.Comments }).ToList();
            ViewBag.ReviewItem = _liaotianService.GetSYScode("experts", "ReviewItem");//.Select(x => new { code = x.CodeSn, label = x.Comments }).ToList();
            ViewBag.Province = _projectService.Getsheng();//.Select(x => new { code = x.CodeId, label = x.Name }).ToList();
            ViewBag.City = _projectService.Getshi(expertDTO.Province);//.Select(x => new { code = x.CodeId, label = x.Name }).ToList();
            ViewData.Model = expertDTO;
            return View();
        }
        //public string Get(string id = null)
        //{
        //    ExpertDTO expertDTO = new ExpertDTO();
        //    if (!String.IsNullOrEmpty(id))
        //    {
        //        expertDTO = _expertService.Get(id);
        //    }
        //    return JsonConvert.SerializeObject(expertDTO);
        //}
        /// <summary>
        /// 保存
        /// </summary>
        /// <param name="data">岗位实体类对象</param>
        /// <returns></returns>
        [HttpPost]
        public string ExpertsApplySave(ExpertDTO data)
        {
            var curentuser = JsonConvert.DeserializeObject<PltUser>(HttpContext.Session.GetString("User"));
            ViewData["curentuser"] = curentuser;
            data.ReviewItem = data.ReviewItemSelect;
            data.InfoSource = "00";
            data.ExpertType = "0";
            data.Level = "0";
            data.RecStatus = "A";
            data.ShenheStatus = "D";
            if (String.IsNullOrEmpty(data.Id))
            {
                data.Creater = curentuser.Id;
                data.Createtime = DateTime.Now;
            }
            data.Modifier = curentuser.Id;
            data.Modifytime = DateTime.Now;
            ResultEntity resultEntity = _expertService.save(data);
            return JsonConvert.SerializeObject(resultEntity);
        }
        #endregion
        public IActionResult Index()
        {
            var curentuser = JsonConvert.DeserializeObject<PltUser>(HttpContext.Session.GetString("User"));
            ViewData["curentuser"] = curentuser;
            List<ActionEntity> actionlist = new List<ActionEntity>();
            ActionEntity actionEntity = new ActionEntity();
            actionEntity.OpenType = 0;
            actionEntity.ActionUrl = "";
            actionEntity.ActionFun = "Search";
            actionEntity.PageIco = "fa fa-search";
            actionEntity.ActionName = "查询";
            actionlist.Add(actionEntity);
            ViewData["ActionInfo"] = actionlist;
            ViewBag.expertType = _liaotianService.GetSYScode("experts", "expertType").Select(x => new { code = x.CodeSn, label = x.Comments }).ToList();
            ViewBag.level = _liaotianService.GetSYScode("experts", "level").Select(x => new { code = x.CodeSn, label = x.Comments }).ToList();
            ViewBag.Province = _projectService.Getsheng().Select(x => new { code = x.CodeId, label = x.Name }).ToList();
            //  ViewBag.City = _projectService.Getshi( ).Select(x => new { code = x.CodeId, label = x.Name }).ToList();
            ViewBag.ReviewItem = _liaotianService.GetSYScode("experts", "ReviewItem").Select(x => new { code = x.CodeSn, label = x.Comments }).ToList();
            return View();
        }
        #region 查询
        [CheckLogin]
        public string GetList(ExpertDTOSearch search)
        {
            var curentuser = JsonConvert.DeserializeObject<PltUser>(HttpContext.Session.GetString("User"));
            search.ShenheStatus = "D";
            ViewData["curentuser"] = curentuser;
            return JsonConvert.SerializeObject(_expertService.SearchByPaging(search));
        }
        #endregion
    }
}
zhengcaioa/zhengcaioa/Controllers/ProjectController.cs
@@ -450,7 +450,9 @@
                                var td1 = table[i + 1].QuerySelector("td");
                                if (td1 != null)
                                {
                                    projectDTO.Zhuanjia = table[i + 1].QuerySelector("td").TextContent.Trim();//OuterHtml
                                    string ssss = table[i + 1].QuerySelector("td").TextContent.Trim();
                                    ssss =  ssss.Replace("(组长)", "").Replace("(组长)", "").Replace(",", "、").Replace("(评审组长)", "").Replace("(评审组长)", "").Replace(";", "、").Replace("评审组长:", "").Replace("组长:", "").Replace("组员:","");
                                    projectDTO.Zhuanjia = ssss;//OuterHtml
                                }
                            }
zhengcaioa/zhengcaioa/Startup.cs
@@ -110,6 +110,9 @@
            services.AddScoped(typeof(IFiMemberService), typeof(FiMemberService));
            services.AddScoped(typeof(IFiBookService), typeof(FiBookService));
            services.AddScoped(typeof(IAdmAttendanceRuleService), typeof(AdmAttendanceRuleService));
            services.AddAutoMapper(typeof(AutoMapperConfigs));
            services.AddUEditorService("ueditor.json", true, "wwwroot");
            services.AddMvc(options =>{
zhengcaioa/zhengcaioa/Views/CooperatecustomCustomer/Edit.cshtml
@@ -473,6 +473,8 @@
        };
        $("#Ywjl").chosen();
        $("#Hyfl").chosen();
        var id = '@Model.Id';
        var bUpload = false;
zhengcaioa/zhengcaioa/Views/Expert/Edit.cshtml
@@ -8,9 +8,11 @@
    List<SysCodeDtl> InfoSource = ViewData["InfoSource"] as List<SysCodeDtl>; //客户来源
    List<SysCodeDtl> expertType = ViewData["expertType"] as List<SysCodeDtl>; //专家类型
    List<SysCodeDtl> level = ViewData["level"] as List<SysCodeDtl>; //专家等级
    List<SysCodeDtl> ReviewItem = ViewData["ReviewItem"] as List<SysCodeDtl>; //评审品目
}
@{
    Layout = null;
            Layout = null;
}
<!DOCTYPE html>
@@ -233,7 +235,7 @@
                                                }
                                            }
                                            }
                                        </select>
@@ -252,7 +254,31 @@
                                    <label grouptype="Vdata" class="text-right col-sm-1 col-md-1 control-label">评审品目<i class="red">*</i></label>
                                    <div class="col-sm-2 col-md-2" grouptype="Vdata">
                                        <input class="form-control" label="评审品目" name="ReviewItem" id="ReviewItem" labtype="txt" addvisible="true" editvisible="true" maxlength="500" reg="" ismust="true" type="text" value="@Model.ReviewItem" autocomplete="off">
                                        <select id="ReviewItem" class="form-control" name="ReviewItem"  multiple   data-placeholder="选择 序列 ...">
                                            <option value="" hassubinfo="true">请选择</option>
                                            @foreach (var item in ReviewItem)
                                            {
                                                @if (Model.ReviewItem !=null && Model.ReviewItem.Split(',').Contains(item.CodeSn))
                                                {
                                                    <option value="@item.CodeSn" hassubinfo="true" selected="selected">
                                                        @item.Comments
                                                    </option>
                                                }
                                                else
                                                {
                                                    <option value="@item.CodeSn" hassubinfo="true" >
                                                        @item.Comments
                                                    </option>
                                                }
                                            }
                                        </select>
                                    </div>
                                </div>
@@ -265,7 +291,7 @@
                                    <label grouptype="Vdata" class="text-right col-sm-1 col-md-1 control-label">所属区域</label>
                                    <div class="col-sm-2 col-md-2">
                                        <div style="width:120px;float:left;">
                                        <div style="width:110px;float:left;">
                                            <select id="Province" class="form-control" name="Province" data-placeholder="选择 序列 ..." style="font-weight:normal;">
                                                <option value="" hassubinfo="true">请选择</option>
                                                @foreach (var item in Province)
@@ -288,7 +314,7 @@
                                            </select>
                                        </div>
                                        <div style="width:120px;float:left;">
                                        <div style="width:110px;float:left;">
                                            <select id="City" class="form-control" name="City" data-placeholder="选择 序列 ..." style="font-weight:normal;">
                                                <option value="" hassubinfo="true">请选择</option>
                                                @foreach (var item in City)
@@ -323,14 +349,14 @@
                                </div>
                                <div class="clearfix layer-area" style="padding-bottom:15px;">
                                    <label class="text-right col-sm-1 col-md-1 control-label">联系电话</label>
                                    <label class="text-right col-sm-1 col-md-1 control-label">联系电话1</label>
                                    <div class="col-sm-2 col-md-2">
                                        <input class="form-control" label="联系电话" name="Phone1" id="Phone1" labtype="txt" addvisible="true" editvisible="true" maxlength="500" reg="" ismust="true" type="text" value="@Model.Phone1" autocomplete="off">
                                        <input class="form-control" label="联系电话1" name="Phone1" id="Phone1" labtype="txt" addvisible="true" editvisible="true" maxlength="500" reg="" ismust="true" type="text" value="@Model.Phone1" autocomplete="off">
                                    </div>
                                    <label class="text-right col-sm-1 col-md-1 control-label">联系电话</label>
                                    <label class="text-right col-sm-1 col-md-1 control-label">联系电话2</label>
                                    <div class="col-sm-2 col-md-2">
                                        <input class="form-control" label="联系电话" name="Phone2" id="Phone2" labtype="txt" addvisible="true" editvisible="true" maxlength="500" reg="" ismust="true" type="text" value="@Model.Phone2" autocomplete="off">
                                        <input class="form-control" label="联系电话2" name="Phone2" id="Phone2" labtype="txt" addvisible="true" editvisible="true" maxlength="500" reg="" ismust="true" type="text" value="@Model.Phone2" autocomplete="off">
                                    </div>
                                    <label class="text-right col-sm-1 col-md-1 control-label">QQ</label>
@@ -728,7 +754,14 @@
                });
            }
        $("#ReviewItem").chosen({
                search_contains: true,
                disable_search_threshold: 5
            });
        });
@@ -841,7 +874,7 @@
            //var data = { id: $("#Id").val(), StartTime:$("#StartTime").val(), Sheng: $("#Sheng").val(), job_level: $("#Job_level").val().toString(), ExistsAttachment: fileId != "" }
            $.ajax({
                type: "POST",
                url: "/Expert/Save",
                url: "/Expert/Save?ReviewItemSelect=" + $("#ReviewItem").val(),
                dataType: "json",
                global: false,
                data: $('form').serializeArray(),
zhengcaioa/zhengcaioa/Views/Expert/Index.cshtml
@@ -9,6 +9,7 @@
        var expertType = '@Html.Raw(Newtonsoft.Json.JsonConvert.SerializeObject(ViewBag.expertType))';
        var Province = '@Html.Raw(Newtonsoft.Json.JsonConvert.SerializeObject(ViewBag.Province))';
        var level = '@Html.Raw(Newtonsoft.Json.JsonConvert.SerializeObject(ViewBag.level))';
         var ReviewItem = '@Html.Raw(Newtonsoft.Json.JsonConvert.SerializeObject(ViewBag.ReviewItem))';
        dataCol = [
            { label: 'id', name: 'Id', labtype: 'txt', hidden: true },
@@ -20,8 +21,8 @@
                }
            },
            { label: '专家证号', name: 'CertiNumber', labtype: 'txt', hidden: false },
            { label: '主要评审品目', name: 'ReviewItem', labtype: 'txt', hidden: false },
            { label: '专家等级', name: 'Level', labtype: 'txt', hidden: false },
            { label: '主要评审品目', name: 'ReviewItem', labtype: 'txt', hidden: true },
            { label: '专家等级', name: 'LevelName', labtype: 'txt', hidden: false },
            { label: '联系电话', name: 'Phone1', labtype: 'txt', hidden: false },
            { label: '合作次数', name: 'Level', labtype: 'txt', hidden: true },
            {
@@ -62,7 +63,7 @@
            { label: '市', name: 'City', labtype: 'combox', hidden: false, data: JSON.parse('[]'), cwidth: '1%', cccwidth: '7%' },
            { label: '专家姓名', name: 'Name', labtype: 'txt', hidden: false },
            { label: '专家类型', name: 'ExpertType', labtype: 'combox', hidden: false, data: JSON.parse(expertType)/*,cwidth: '5%', cccwidth: '28%' */ },
            { label: '评审品目', name: 'ReviewItem', labtype: 'txt', hidden: false },
            { label: '评审品目', name: 'ReviewItem', labtype: 'combox', hidden: false, data: JSON.parse(ReviewItem) },
            { label: '专家级别', name: 'Level', labtype: 'combox', hidden: false, data: JSON.parse(level) },
            { label: '专家证号', name: 'CertiNumber', labtype: 'txt', hidden: false },
            { label: '联系电话', name: 'Phone1', labtype: 'txt', hidden: false },
@@ -112,7 +113,7 @@
                    global: false,
                    data: "",
                    success: function (data) {
                        var city = $("#PBSCity");
                        city.find('option').remove();
                        var aaa = '<option value="" hassubinfo="true">请选择</option>';
zhengcaioa/zhengcaioa/Views/ExpertsApply/ExpertsApply.cshtml
New file
@@ -0,0 +1,927 @@
@model DTO.ExpertDTO
@using DTO;
@using zhengcaioa.Models;
@{
    List<Area> Province = ViewData["Province"] as List<Area>; //省
    List<Area> City = ViewData["City"] as List<Area>; //市
    List<SysCodeDtl> Sex = ViewData["sex"] as List<SysCodeDtl>; //客户类型
                                                                //List<SysCodeDtl> InfoSource = ViewData["InfoSource"] as List<SysCodeDtl>; //客户来源
                                                                //List<SysCodeDtl> expertType = ViewData["expertType"] as List<SysCodeDtl>; //专家类型
                                                                //List<SysCodeDtl> level = ViewData["level"] as List<SysCodeDtl>; //专家等级
    List<SysCodeDtl> ReviewItem = ViewData["ReviewItem"] as List<SysCodeDtl>; //评审品目
}
@{
    Layout = null;
}
<!DOCTYPE html>
<html>
<head>
    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0">
    <meta name="description" content="">
    <meta name="author" content="ThemeBucket">
    <title>@(SiteConfig.SiteName)</title>
    <link href="~/css/bootstrap.min.css" rel="stylesheet">
    <link href="~/css/font-awesome.min.css" rel="stylesheet">
    <link href="~/css/animate.min.css" rel="stylesheet">
    @*<link href="~/css/plugins/iCheck/custom.css" rel="stylesheet">*@
    <link href="~/css/style.min.css" rel="stylesheet">
    <link href="~/css/plugins/chosen/chosen.css" rel="stylesheet">
    @*<link href="~/js/plugins/layer/skin/layer.css" rel="stylesheet">*@
    @*<link href="~/css/plugins/datapicker/datepicker3.css" rel="stylesheet">*@
    <link href="~/css/style.min.css" rel="stylesheet">
    <link href="~/css/plugins/toastr/toastr.min.css" rel="stylesheet" />
    <link href="~/css/plugins/webuploader/webuploader.css" rel="stylesheet" />
    <style type="text/css">
        .webuploader-pick {
            position: relative;
            display: inline-block;
            cursor: pointer;
            background: #00b7ee;
            padding: 8px 14px 7px 14px;
            color: #fff;
            text-align: center;
            border-radius: 3px;
            overflow: hidden;
        }
        div.clearfix > label {
            padding-top: 8px;
        }
        .chosen-container {
            border-radius: 1px;
            border: 1px solid #e5e6e7;
        }
        .col-md-1.control-label {
            padding-right: 0px;
            font-weight: 400;
        }
        .img-box {
            height: 120px;
            width: 120px;
            float: left;
            padding-left: 0px !important;
            padding-right: 20px;
            /*border:1px solid #c3cbe5;*/
        }
            .img-box img {
                height: 80px;
                width: 80px;
            }
            .img-box p {
                width: 80px;
                text-align: center;
            }
        .img-row {
            height: 80px !important;
            padding-right: 2px !important;
        }
            .img-row label {
                height: 30px;
                line-height: 80px;
            }
    </style>
    <!-- jqgrid-->
    <script language="javascript" src="~/js/jquery.min.js" type="text/javascript"></script>
    <script src="~/js/bootstrap.min.js"></script>
    <!--容器-->
    @*<script language="javascript" src="~/js/datehelper.js" type="text/javascript"></script>*@
    @*<script language="javascript" src="~/js/plugins/query/jquery.query-object.js" type="text/javascript"></script>*@
    @*<script language="javascript" src="~/js/plugins/iCheck/icheck.min.js" type="text/javascript"></script>*@
    <script language="javascript" src="~/js/plugins/chosen/chosen.jquery.js" type="text/javascript"></script>
    @*<script language="javascript" src="~/js/plugins/datapicker/bootstrap-datepicker.js" type="text/javascript"></script>*@
    <script language="javascript" src="~/js/plugins/layer/layer.js" type="text/javascript"></script>
    @*<script src="~/js/plugins/jqgrid/jquery.jqGrid.min.js" type="text/javascript"></script>*@
    @*<script src="~/js/plugins/jqgrid/i18n/grid.locale-cn.js" type="text/javascript"></script>*@
    <script src="~/js/plugins/toastr/toastr.min.js" type="text/javascript"></script>
    <script src="~/js/plugins/webuploader/webuploader.min.js"></script>
    <script language="javascript" src="~/js/common-layout.js" type="text/javascript"></script>
    <script src="~/js/plugins/layer/laydate/laydate.js" type="text/javascript"></script>
    <script src="~/js/imgUpload.js"></script>
    @*<script src="~/js/plugins/iTexbox/itextbox.js" type="text/javascript"></script>*@
    @*<script src="~/js/plugins/iuploader/iuploader.js"></script>*@
    <script src="~/js/TUJS.js"></script>
</head>
<body class="gray-bg" style="overflow:auto">
    <form id="formtest">
        <div class="wrapper wrapper-content" id="ibox-content" style="padding:15px;">
            <div class="row">
                <div class="col-sm-12">
                    <div class="ibox float-e-margins">
                        <div class="ibox-title">
                            <h5>                            <i class="fa fa-list"></i>&nbsp;新增专家</h5>
                        </div>
                        <div id="div_content" class="ibox-content" style="background-color:white;">
                            <div class="row">
                                <div class="clearfix layer-area" style="padding-bottom:15px;">
                                    @*<label class="text-right col-sm-1 col-md-1 control-label">信息来源<i class="red">*</i></label>
                                        <div class="col-sm-2 col-md-2">
                                            <select id="InfoSource" class="form-control" name="InfoSource" data-placeholder="选择 序列 ..." style="font-weight:normal;">
                                                <option value="" hassubinfo="true">请选择</option>
                                                @foreach (var item in InfoSource)
                                                {
                                                    @if (!item.CodeSn.Equals(Model.InfoSource))
                                                    {
                                                        <option value="@item.CodeSn" hassubinfo="true">
                                                            @item.Comments
                                                        </option>
                                                    }
                                                    else
                                                    {
                                                        <option value="@item.CodeSn" hassubinfo="true" selected="selected">
                                                            @item.Comments
                                                        </option>
                                                    }
                                                }
                                                }
                                            </select>
                                            <input type="hidden" id="Id" name="Id" value="@Model.Id" />
                                        </div>*@
                                    @*<label grouptype="Vdata" class="text-right col-sm-1 col-md-1 control-label">专家类型<i class="red">*</i></label>
                                        <div class="col-sm-2 col-md-2" grouptype="Vdata">
                                            <select id="ExpertType" class="form-control" name="expertType" data-placeholder="选择 序列 ...">
                                                <option value="" hassubinfo="true">请选择</option>
                                                @foreach (var item in expertType)
                                                {
                                                    @if (!item.CodeSn.Equals(Model.ExpertType))
                                                    {
                                                        <option value="@item.CodeSn" hassubinfo="true">
                                                            @item.Comments
                                                        </option>
                                                    }
                                                    else
                                                    {
                                                        <option value="@item.CodeSn" hassubinfo="true" selected="selected">
                                                            @item.Comments
                                                        </option>
                                                    }
                                                }
                                                }
                                            </select>
                                        </div>*@
                                    <label class="text-right col-sm-1 col-md-1 control-label">专家姓名<i class="red">*</i></label>
                                    <div class="col-sm-2 col-md-2">
                                        <input class="form-control" label="详细地址" name="Name" id="Name" labtype="txt" addvisible="true" editvisible="true" maxlength="500" reg="" ismust="true" type="text" value="@Model.Name" autocomplete="off">
                                    </div>
                                    <label class="text-right col-sm-1 col-md-1 control-label">性别<i class="red">*</i></label>
                                    <div class="col-sm-2 col-sm-2" grouptype="Vdata">
                                        <select id="Sex" class="form-control" name="Sex" data-placeholder="选择 序列 ..." style="font-weight:normal;">
                                            <option value="" hassubinfo="true">请选择</option>
                                            @foreach (var item in Sex)
                                            {
                                                @if (!item.CodeId.Equals(Model.Sex))
                                                {
                                                    <option value="@item.CodeId" hassubinfo="true">
                                                        @item.Comments
                                                    </option>
                                                }
                                                else
                                                {
                                                    <option value="@item.CodeId" hassubinfo="true" selected="selected">
                                                        @item.Comments
                                                    </option>
                                                }
                                            }
                                            }
                                        </select>
                                    </div>
                                </div>
                                <div class="clearfix layer-area" style="padding-bottom:15px;">
                                    @*<label grouptype="Vdata" class="text-right col-sm-1 col-md-1 control-label">专家级别<i class="red">*</i></label>
                                        <div class="col-sm-2 col-md-2" grouptype="Vdata">
                                            <select id="Level" class="form-control" name="Level" data-placeholder="选择 序列 ...">
                                                <option value="" hassubinfo="true">请选择</option>
                                                @foreach (var item in level)
                                                {
                                                    @if (!item.CodeSn.Equals(Model.Level))
                                                    {
                                                        <option value="@item.CodeSn" hassubinfo="true">
                                                            @item.Comments
                                                        </option>
                                                    }
                                                    else
                                                    {
                                                        <option value="@item.CodeSn" hassubinfo="true" selected="selected">
                                                            @item.Comments
                                                        </option>
                                                    }
                                                }
                                            </select>
                                        </div>*@
                                    <label class="text-right col-sm-1 col-md-1 control-label">身份证号</label>
                                    <div class="col-sm-2 col-md-2" grouptype="Vdata">
                                        <input class="form-control" label="身份证号" name="IdCard" id="IdCard" labtype="txt" addvisible="true" editvisible="true" maxlength="500" reg="" ismust="true" type="text" value="@Model.IdCard" autocomplete="off">
                                    </div>
                                    <label class="text-right col-sm-1 col-md-1 control-label">专家证号</label>
                                    <div class="col-sm-2 col-md-2" grouptype="Vdata">
                                        <input class="form-control" label="专家证号" name="CertiNumber" id="CertiNumber" labtype="txt" addvisible="true" editvisible="true" maxlength="500" reg="" ismust="true" type="text" value="@Model.CertiNumber">
                                    </div>
                                    <label grouptype="Vdata" class="text-right col-sm-1 col-md-1 control-label">评审品目<i class="red">*</i></label>
                                    <div class="col-sm-2 col-md-2" grouptype="Vdata">
                                        <select id="ReviewItem" class="form-control" name="ReviewItem" multiple data-placeholder="选择 序列 ...">
                                            <option value="" hassubinfo="true">请选择</option>
                                            @foreach (var item in ReviewItem)
                                            {
                                                @if (Model.ReviewItem != null && Model.ReviewItem.Split(',').Contains(item.CodeSn))
                                                {
                                                    <option value="@item.CodeSn" hassubinfo="true" selected="selected">
                                                        @item.Comments
                                                    </option>
                                                }
                                                else
                                                {
                                                    <option value="@item.CodeSn" hassubinfo="true">
                                                        @item.Comments
                                                    </option>
                                                }
                                            }
                                        </select>
                                    </div>
                                </div>
                                <div class="clearfix layer-area" style="padding-bottom:15px;">
                                    <label class="text-right col-sm-1 col-md-1 control-label">通信地址</label>
                                    <div class="col-sm-5 col-md-5">
                                        <input class="form-control" label="通信地址" name="Address" id="Address" labtype="txt" addvisible="true" editvisible="true" maxlength="500" reg="" ismust="true" type="text" value="@Model.Address" autocomplete="off">
                                    </div>
                                    <label grouptype="Vdata" class="text-right col-sm-1 col-md-1 control-label">所属区域</label>
                                    <div class="col-sm-2 col-md-2">
                                        <div style="width:110px;float:left;">
                                            <select id="Province" class="form-control" name="Province" data-placeholder="选择 序列 ..." style="font-weight:normal;">
                                                <option value="" hassubinfo="true">请选择</option>
                                                @foreach (var item in Province)
                                                {
                                                    @if (!item.CodeId.Equals(Model.Province))
                                                    {
                                                        <option value="@item.CodeId" hassubinfo="true">
                                                            @item.Name
                                                        </option>
                                                    }
                                                    else
                                                    {
                                                        <option value="@item.CodeId" hassubinfo="true" selected="selected">
                                                            @item.Name
                                                        </option>
                                                    }
                                                }
                                            </select>
                                        </div>
                                        <div style="width:110px;float:left;">
                                            <select id="City" class="form-control" name="City" data-placeholder="选择 序列 ..." style="font-weight:normal;">
                                                <option value="" hassubinfo="true">请选择</option>
                                                @foreach (var item in City)
                                                {
                                                    @if (!item.CodeId.Equals(Model.City))
                                                    {
                                                        <option value="@item.CodeId" hassubinfo="true">
                                                            @item.Name
                                                        </option>
                                                    }
                                                    else
                                                    {
                                                        <option value="@item.CodeId" hassubinfo="true" selected="selected">
                                                            @item.Name
                                                        </option>
                                                    }
                                                }
                                            </select>
                                        </div>
                                    </div>
                                    <label class="text-right col-sm-1 col-md-1 control-label">邮政编码</label>
                                    <div class="col-sm-2 col-md-2">
                                        <input class="form-control" label="邮政编码" name="Postal" id="Postal" labtype="txt" addvisible="true" editvisible="true" maxlength="500" reg="" ismust="true" type="text" value="@Model.Postal" autocomplete="off">
                                    </div>
                                </div>
                                <div class="clearfix layer-area" style="padding-bottom:15px;">
                                    <label class="text-right col-sm-1 col-md-1 control-label">联系电话1</label>
                                    <div class="col-sm-2 col-md-2">
                                        <input class="form-control" label="联系电话1" name="Phone1" id="Phone1" labtype="txt" addvisible="true" editvisible="true" maxlength="500" reg="" ismust="true" type="text" value="@Model.Phone1" autocomplete="off">
                                    </div>
                                    <label class="text-right col-sm-1 col-md-1 control-label">联系电话2</label>
                                    <div class="col-sm-2 col-md-2">
                                        <input class="form-control" label="联系电话2" name="Phone2" id="Phone2" labtype="txt" addvisible="true" editvisible="true" maxlength="500" reg="" ismust="true" type="text" value="@Model.Phone2" autocomplete="off">
                                    </div>
                                    <label class="text-right col-sm-1 col-md-1 control-label">QQ</label>
                                    <div class="col-sm-2 col-md-2">
                                        <input class="form-control" label="QQ号" name="Qq" id="Qq" labtype="txt" addvisible="true" editvisible="true" maxlength="500" reg="" ismust="true" type="text" value="@Model.Qq" autocomplete="off">
                                    </div>
                                    <label class="text-right col-sm-1 col-md-1 control-label">微信</label>
                                    <div class="col-sm-2 col-md-2">
                                        <input class="form-control" label="微信" name="Wechat" id="Wechat" labtype="txt" addvisible="true" editvisible="true" maxlength="500" reg="" ismust="true" type="text" value="@Model.Wechat" autocomplete="off">
                                    </div>
                                </div>
                                @*<div class="ibox-title">
                                        <h5>  <i class="fa fa-list"></i>&nbsp;客户资料</h5>
                                    </div>*@
                                <style>
                                    .divImg {
                                        height: 80px;
                                        width: 80px;
                                    }
                                </style>
                                <div class="clearfix layer-area" style="padding-bottom:15px;">
                                    <div class="col-sm-1 col-md-1 img-row">
                                        <label class="text-right  control-label">专家证书</label>
                                    </div>
                                    <div class="col-sm-6 col-md-6">
                                        <div class="col-sm-2 col-md-2 img-box">
                                            <div id="frontImg" class="frontImg"></div>
                                            <input type="hidden" id="CertiFont" name="CertiFont" value="@Model.CertiFont" />
                                            <p>上传正面</p>
                                        </div>
                                        <div class="col-sm-2 col-md-2 img-box">
                                            <div id="BackImg" class="BackImg"></div>
                                            <input type="hidden" id="CertiBack" name="CertiBack" value="@Model.CertiBack" />
                                            <p>上传背面</p>
                                        </div>
                                    </div>
                                </div>
                                <div class="clearfix layer-area" style="padding-bottom:15px;">
                                    <div class="col-sm-1 col-md-1 img-row">
                                        <label class="text-right   control-label">职称证书</label>
                                    </div>
                                    <div class="col-sm-2 col-md-2 img-box">
                                        <div id="TitileImg" class="TitileImg"></div>
                                        <input type="hidden" id="TitileCerti" name="TitileCerti" value="@Model.TitileCerti" />
                                        <p>上传职称证书</p>
                                    </div>
                                    <div class="col-sm-2 col-md-2 img-box">
                                        <div id="TitileImg1" class="TitileImg1"></div>
                                        <input type="hidden" id="TitileCerti1" name="TitileCerti1" value="@Model.TitileCerti1" />
                                        <p>上传职称证书</p>
                                    </div>
                                    <div class="col-sm-2 col-md-2 img-box">
                                        <div id="TitileImg2" class="TitileImg2"></div>
                                        <input type="hidden" id="TitileCerti2" name="TitileCerti2" value="@Model.TitileCerti2" />
                                        <p>上传职称证书</p>
                                    </div>
                                    <div class="col-sm-2 col-md-2 img-box">
                                        <div id="TitileImg3" class="TitileImg3"></div>
                                        <input type="hidden" id="TitileCerti3" name="TitileCerti3" value="@Model.TitileCerti3" />
                                        <p>上传职称证书</p>
                                    </div>
                                    <div class="col-sm-2 col-md-2 img-box">
                                        <div id="TitileImg4" class="TitileImg4"></div>
                                        <input type="hidden" id="TitileCerti4" name="TitileCerti4" value="@Model.TitileCerti4" />
                                        <p>上传职称证书</p>
                                    </div>
                                    @*</div>
                                        <div class="clearfix layer-area" style="padding-bottom:15px;">
                                            <div class="col-sm-1 col-md-1 img-row">
                                            </div>*@
                                    <div class="col-sm-2 col-md-2 img-box">
                                        <div id="TitileImg5" class="TitileImg5"></div>
                                        <input type="hidden" id="TitileCerti5" name="TitileCerti5" value="@Model.TitileCerti5" />
                                        <p>上传职称证书</p>
                                    </div>
                                    <div class="col-sm-2 col-md-2 img-box">
                                        <div id="TitileImg6" class="TitileImg6"></div>
                                        <input type="hidden" id="TitileCerti6" name="TitileCerti6" value="@Model.TitileCerti6" />
                                        <p>上传职称证书</p>
                                    </div>
                                    <div class="col-sm-2 col-md-2 img-box">
                                        <div id="TitileImg7" class="TitileImg7"></div>
                                        <input type="hidden" id="TitileCerti7" name="TitileCerti7" value="@Model.TitileCerti7" />
                                        <p>上传职称证书</p>
                                    </div>
                                    <div class="col-sm-2 col-md-2 img-box">
                                        <div id="TitileImg8" class="TitileImg8"></div>
                                        <input type="hidden" id="TitileCerti8" name="TitileCerti8" value="@Model.TitileCerti8" />
                                        <p>上传职称证书</p>
                                    </div>
                                    <div class="col-sm-2 col-md-2 img-box">
                                        <div id="TitileImg9" class="TitileImg9"></div>
                                        <input type="hidden" id="TitileCerti9" name="TitileCerti9" value="@Model.TitileCerti9" />
                                        <p>上传职称证书</p>
                                    </div>
                                    <div class="col-sm-2 col-md-2 img-box">
                                        <div id="TitileImg10" class="TitileImg10"></div>
                                        <input type="hidden" id="TitileCerti10" name="TitileCerti10" value="@Model.TitileCerti10" />
                                        <p>上传职称证书</p>
                                    </div>
                                </div>
                                <div class="clearfix layer-area" style="padding-bottom:15px;">
                                    <label class="text-right col-sm-1 col-md-1 control-label">备注</label>
                                    <div class="col-sm-6 col-md-6">
                                        <textarea id="Remark" name="Remark" style="overflow-y:hidden" cols="100" rows="10">@Model.Remark </textarea>
                                    </div>
                                </div>
                            </div>
                        </div>
                    </div>
                </div>
            </div>
        </div>
        <div class="wrapper wrapper-content" style="margin-top:0px"></div>
        <div class="ibox-content" id="top" style="z-index:100; position:fixed; height:50px; width:100%;bottom:0; text-align: right; padding-top:8px ">
            <div class="" style="float:right;" data-bootstro-width="500px" data-bootstro-content="功能按钮:“保存”,“删除”">
                <a class="btn btn-success" href="javascript:void(0)" onclick="saveExpert();" style="margin-left:4px; border-radius:4px;">
                    <i class="glyphicon glyphicon-ok"></i>&nbsp;&nbsp;<span class="bold">提交</span>
                </a>
            </div>
        </div>
    </form>
    <script type="text/javascript">
        var hh = document.body.clientHeight - $('.ibox-title').height() - $("#top").height() * 2 - 95;
        $("#div_content").height(hh);
        toastr.options = {
            "closeButton": true,
            "debug": false,
            "progressBar": true,
            "positionClass": "toast-bottom-right",
            "onclick": null,
            "showDuration": "300",
            "hideDuration": "600",
            "timeOut": "4500",
            "extendedTimeOut": "600",
            "showEasing": "swing",
            "hideEasing": "linear",
            "showMethod": "fadeIn",
            "hideMethod": "fadeOut"
        };
        var imgs = {
            BackImg: '',
            BackImg: '',
            TitileImg: '',
            TitileImg1: '',
            TitileImg2: '',
            TitileImg3: '',
            TitileImg4: '',
            TitileImg5: '',
            TitileImg6: '',
            TitileImg7: '',
            TitileImg8: '',
            TitileImg9: '',
            TitileImg10: '',
        }
        var imgPath = "@Url.Content("~/UploadFile/")";
        //初始化图片上传div
        new DragImgUpload("#frontImg", {
            callback: function (files) {
                imgs.frontImg = imgUploadCallback(files);
                if (imgs.frontImg !== "") {
                    $("#CertiFont").val(imgPath + imgs.frontImg);
                }
            }
        });
        new DragImgUpload("#BackImg", {
            callback: function (files) {
                imgs.BackImg = imgUploadCallback(files);
                if (imgs.BackImg !== "") {
                    $("#CertiBack").val(imgPath + imgs.BackImg);
                }
            }
        });
        new DragImgUpload("#TitileImg", {
            callback: function (files) {
                imgs.TitileImg = imgUploadCallback(files);
                if (imgs.TitileImg !== "") {
                    $("#TitileCerti").val(imgPath + imgs.TitileImg);
                }
            }
        });
        new DragImgUpload("#TitileImg1", {
            callback: function (files) {
                imgs.TitileImg1 = imgUploadCallback(files);
                if (imgs.TitileImg1!== "") {
                    $("#TitileCerti1").val(imgPath + imgs.TitileImg1);
                }
            }
        });
        new DragImgUpload("#TitileImg2", {
            callback: function (files) {
                imgs.TitileImg2 = imgUploadCallback(files);
                if (imgs.TitileImg2 !== "") {
                    $("#TitileCerti2").val(imgPath + imgs.TitileImg2);
                }
            }
        });
        new DragImgUpload("#TitileImg3", {
            callback: function (files) {
                imgs.TitileImg3 = imgUploadCallback(files);
                if (imgs.TitileImg3 !== "") {
                    $("#TitileCerti3").val(imgPath + imgs.TitileImg3);
                }
            }
        });
        new DragImgUpload("#TitileImg4", {
            callback: function (files) {
                imgs.TitileImg4 = imgUploadCallback(files);
                if (imgs.TitileImg4 !== "") {
                    $("#TitileCerti4").val(imgPath + imgs.TitileImg4);
                }
            }
        });
        new DragImgUpload("#TitileImg5", {
            callback: function (files) {
                imgs.TitileImg5 = imgUploadCallback(files);
                if (imgs.TitileImg5 !== "") {
                    $("#TitileCerti5").val(imgPath + imgs.TitileImg5);
                }
            }
        });
        new DragImgUpload("#TitileImg6", {
            callback: function (files) {
                imgs.TitileImg6 = imgUploadCallback(files);
                if (imgs.TitileImg6 !== "") {
                    $("#TitileCerti6").val(imgPath + imgs.TitileImg6);
                }
            }
        });
        new DragImgUpload("#TitileImg7", {
            callback: function (files) {
                imgs.TitileImg7 = imgUploadCallback(files);
                if (imgs.TitileImg7 !== "") {
                    $("#TitileCerti7").val(imgPath + imgs.TitileImg7);
                }
            }
        });
        new DragImgUpload("#TitileImg8", {
            callback: function (files) {
                imgs.TitileImg8 = imgUploadCallback(files);
                if (imgs.TitileImg8 !== "") {
                    $("#TitileCerti8").val(imgPath + imgs.TitileImg8);
                }
            }
        });
        new DragImgUpload("#TitileImg9", {
            callback: function (files) {
                imgs.TitileImg9 = imgUploadCallback(files);
                if (imgs.TitileImg9 !== "") {
                    $("#TitileCerti9").val(imgPath + imgs.TitileImg9);
                }
            }
        });
        new DragImgUpload("#TitileImg10", {
            callback: function (files) {
                imgs.TitileImg10 = imgUploadCallback(files);
                if (imgs.TitileImg10 !== "") {
                    $("#TitileCerti10").val(imgPath + imgs.TitileImg10);
                }
            }
        });
        $(function () {
            imgs.frontImg = $.trim( $("#CertiFont").val() );
            imgs.BackImg = $.trim( $("#CertiBack").val());
            imgs.TitileImg = $.trim($("#TitileCerti").val());
            imgs.TitileImg1 = $.trim($("#TitileCerti1").val());
            imgs.TitileImg2 = $.trim($("#TitileCerti2").val());
            imgs.TitileImg3 = $.trim($("#TitileCerti3").val());
            imgs.TitileImg4 = $.trim($("#TitileCerti4").val());
            imgs.TitileImg5 = $.trim($("#TitileCerti5").val());
            imgs.TitileImg6 = $.trim($("#TitileCerti6").val());
            imgs.TitileImg7 = $.trim($("#TitileCerti7").val());
            imgs.TitileImg8 = $.trim($("#TitileCerti8").val());
            imgs.TitileImg9 = $.trim($("#TitileCerti9").val());
            imgs.TitileImg10 = $.trim($("#TitileCerti10").val());
            if (imgs.frontImg !== "") {
                $("#frontImg img").each(function (i) {
                    $(this).attr("src", imgs.frontImg);
                });
            }
            if (imgs.BackImg !== "") {
                $("#BackImg img").each(function (i) {
                    $(this).attr("src", imgs.BackImg);
                });
            }
            if (imgs.TitileImg !== "") {
                $("#TitileImg img").each(function (i) {
                    $(this).attr("src", imgs.TitileImg);
                });
            }
            if (imgs.TitileImg1 !== "") {
                $("#TitileImg1 img").each(function (i) {
                    $(this).attr("src", imgs.TitileImg1);
                });
            }
            if (imgs.TitileImg2 !== "") {
                $("#TitileImg2 img").each(function (i) {
                    $(this).attr("src", imgs.TitileImg2);
                });
            }
            if (imgs.TitileImg3 !== "") {
                $("#TitileImg3 img").each(function (i) {
                    $(this).attr("src", imgs.TitileImg3);
                });
            }
            if (imgs.TitileImg4 !== "") {
                $("#TitileImg4 img").each(function (i) {
                    $(this).attr("src", imgs.TitileImg4);
                });
            }
            if (imgs.TitileImg5 !== "") {
                $("#TitileImg5 img").each(function (i) {
                    $(this).attr("src", imgs.TitileImg5);
                });
            }
            if (imgs.TitileImg6 !== "") {
                $("#TitileImg6 img").each(function (i) {
                    $(this).attr("src", imgs.TitileImg6);
                });
            }
            if (imgs.TitileImg7 !== "") {
                $("#TitileImg7 img").each(function (i) {
                    $(this).attr("src", imgs.TitileImg7);
                });
            }
            if (imgs.TitileImg8 !== "") {
                $("#TitileImg8 img").each(function (i) {
                    $(this).attr("src", imgs.TitileImg8);
                });
            }
            if (imgs.TitileImg9 !== "") {
                $("#TitileImg9 img").each(function (i) {
                    $(this).attr("src", imgs.TitileImg9);
                });
            }
            if (imgs.TitileImg10 !== "") {
                $("#TitileImg10 img").each(function (i) {
                    $(this).attr("src", imgs.TitileImg10);
                });
            }
        $("#ReviewItem").chosen({
                search_contains: true,
                disable_search_threshold: 5
            });
        });
        function imgUploadCallback(files) {
                var fileName = "";
                var file = files[0];
                var sendData = new FormData();
                sendData.append('img', files[0]);
                $.ajax({
                    type: "post",
                    url: "@Url.Content("~/Expert/UploadImage")",
                    data: sendData,
                    async:false,
                    contentType: false,
                    processData: false,
                    success: function (res) {
                        fileName = res;// FilePath + file.name;
                         //parent.layer.msg("修改成功!");
                     },
                     error: function (data) {
                         fileName = "";
                     }
            });
            return fileName;
        };
        var id = '@Model.Id';
        var bUpload = false;
        var bAdd = false; // 新增操作
        var fileId = ""; // 上传文件生成的Id
        var bEditFile = false; // 编辑时,是否关联了附件
        var bDeleteFile = false; // 删除操作
        var attachment_id = 0; // 附件id
        var imgLoad = new Object();
        // 保存岗位信息
        var saveExpert = function () {
            if ($("#Name").val() == '') {
                toastr.warning("专家姓名不能为空");
                return;
            };
            if (Verify.isNull($("#Province").val()) || Verify.isNull($("#City").val()) ) {
                toastr.warning("区域不能为空");
                return;
            }
            if ($("#IdCard").val() == '') {
                toastr.warning("身份证号不能为空");
                return;
            }
            if ($.trim($("#ReviewItem").val()) == '') {
                toastr.warning("评审项目不能为空");
                return;
            }
            //var data = { id: $("#Id").val(), StartTime:$("#StartTime").val(), Sheng: $("#Sheng").val(), job_level: $("#Job_level").val().toString(), ExistsAttachment: fileId != "" }
            $.ajax({
                type: "POST",
                url: "/ExpertsApply/ExpertsApplySave?ReviewItemSelect=" + $("#ReviewItem").val(),
                dataType: "json",
                global: false,
                data: $('form').serializeArray(),
                success: function (data) {
                        if (data.Result) {
                            //  parent._afterSave(true);
                            parent.layer.msg('成功保存', { icon: 6 });
                            //window.location = "/Project/add?id=" + data.ReturnID;
                            try {
                                _pageAutoClose();//自动关闭页面方法
                            }
                            catch (err) {
                                parent._CloseTab1("/ExpertsApply/ExpertsApply");
                            }
                        }
                        else {
                            // toastr.error("失败");
                            parent.layer.msg(data.Message, { icon: 5 });
                        }
                },
                error: function () {
                    parent.layer.msg('失败', { icon: 5 });
                }
            });
        }
        $("#Province").change(function () {
            var sheng = $("#Province").val();
            $.ajax({
                type: "GET",
                url: "/Project/getCity?shengid=" + sheng,
                dataType: "json",
                global: false,
                data: "",
                success: function (data) {
                    var city = $("#City");
                    city.find('option').remove();
                    var aaa = '<option value="" hassubinfo="true">请选择</option>';
                    city.append(aaa);
                    if (data.length > 0) {
                        for (var i = 0; i < data.length; i++) {
                            var o = '<option value="' + data[i].CodeId + '" hassubinfo="true">' + data[i].Name + '</option>';
                            city.append(o);
                        }
                    }
                },
                error: function () {
                    parent.layer.msg('失败', { icon: 5 });
                }
            });
        });
        function addresschushi() {
            var sheng = $.trim($("#Province").find("option:selected").text());
            var city = $.trim($("#City").find("option:selected").text());
            var Address = $("#Address");
            Address.val(sheng + city + AreaId.replace("请选择", ""));
        }
        if ($("#Id").val() == '') {
            addresschushi();
        }
        function _pageAutoClose() {
            parent.window._reloadPageData();
            var index = parent.layer.getFrameIndex(window.name);
            parent.layer.isRefresh = true;
            parent.layer.closeAll('loading');
            parent.layer.close(index);
            return false;
        }
    </script>
</body>
</html>
zhengcaioa/zhengcaioa/Views/ExpertsApply/Index.cshtml
New file
@@ -0,0 +1,124 @@
@{
    ViewBag.Title = "Expert";
    Layout = "~/Views/Shared/_Layout_Search.cshtml";
}
@section headerStyle{
    <script type="text/javascript">
        @*var expertType = '@Html.Raw(Newtonsoft.Json.JsonConvert.SerializeObject(ViewBag.expertType))';*@
        var Province = '@Html.Raw(Newtonsoft.Json.JsonConvert.SerializeObject(ViewBag.Province))';
        var ReviewItem = '@Html.Raw(Newtonsoft.Json.JsonConvert.SerializeObject(ViewBag.ReviewItem))';
        dataCol = [
            { label: 'id', name: 'Id', labtype: 'txt', hidden: true },
            {
                label: '姓名', name: 'Name', labtype: 'txt', hidden: false
            },
            { label: '专家证号', name: 'CertiNumber', labtype: 'txt', hidden: false },
            { label: '主要评审品目', name: 'ReviewItem', labtype: 'txt', hidden: true },
            { label: '专家等级', name: 'LevelName', labtype: 'txt', hidden: true },
            { label: '联系电话', name: 'Phone1', labtype: 'txt', hidden: false },
            { label: '合作次数', name: 'Level', labtype: 'txt', hidden: true },
            {
                label: '专家证', name: 'CertiFont', align: "center", sortable: false, editable: true,// labtype: 'txt', hidden: false
                formatter: function (cellvalue, options, rowObject)  {
                    return '<img src="' + rowObject.CertiFont + '"  style="width:50px;height:30px;" />' +
                           '<img src="' + rowObject.CertiBack + '"  style="width:50px;height:30px;" />';
                }
            },
            {
                label: '职称证', name: 'TitileCerti', align: "center", sortable: false, editable: true, //labtype: 'txt', hidden: false,
                formatter: function (cellvalue, options, rowObject) {
                    // return '<img src="' + cellvalue + '"  style="width:50px;height:30px;" />';
                    return '<img src="' + rowObject.TitileCerti + '"  style="width:50px;height:30px;" />';
                }
            },
            {
                label: '审核', name: '', labtype: 'txt', hidden: false,
                formatter: function (cellvalue, options, rowObject) {
                    return "<a onclick=\"OpenWindow('专家审核','98%','100%', '/expert/Edit?id=" + rowObject.Id + "')\"  >审核</a>";
                }
            },
            { label: '状态', name: 'RecStatus', labtype: 'txt', hidden: true },
            { label: '创建人', name: 'Creater', labtype: 'txt', hidden: true },
            { label: '创建时间', name: 'Createtime', labtype: 'txt', hidden: true },
            { label: '修改人', name: 'Modifier', labtype: 'txt', hidden: true },
            { label: '修改时间', name: 'Modifytime', labtype: 'txt', hidden: true }
        ];
        dataUrl = "/ExpertsApply/GetList";
        searchCol = [
            { label: '录入时间', name: 'Createtime', labtype: 'datearea', hidden: false },
            { label: '省', name: 'Province', labtype: 'combox', hidden: false, data: JSON.parse(Province), cwidth: '5%', cccwidth: '6.5%' },
            { label: '市', name: 'City', labtype: 'combox', hidden: false, data: JSON.parse('[]'), cwidth: '1%', cccwidth: '7%' },
            { label: '专家姓名', name: 'Name', labtype: 'txt', hidden: false },
            //{ label: '专家类型', name: 'ExpertType', labtype: 'combox', hidden: false, data: JSON.parse(expertType)/*,cwidth: '5%', cccwidth: '28%' */ },
            { label: '评审品目', name: 'ReviewItem', labtype: 'combox', hidden: false, data: JSON.parse(ReviewItem)},
            //{ label: '专家级别', name: 'Level', labtype: 'combox', hidden: false, data: JSON.parse(level) },
            { label: '专家证号', name: 'CertiNumber', labtype: 'txt', hidden: false },
            { label: '联系电话', name: 'Phone1', labtype: 'txt', hidden: false },
            //{ label: '合作次数>=', name: 'JoinCount', labtype: 'txt', hidden: false }
        ];
        var _afterSave = function (result) {
            if (result) {
                toastr.success("保存成功");
            } else {
                toastr.error("保存失败");
            }
        }
        var _afterDel = function (result) {
            if (result) {
                toastr.success("删除成功");
            } else {
                /**/
                toastr.error("删除成功");
                /**/
            }
        }
        $(function () {
            $("#PBSProvince").change(function () {
                let Province = $("#PBSProvince").val();
                $.ajax({
                    type: "GET",
                    url: "/Project/getCity?shengid=" + Province,
                    dataType: "json",
                    global: false,
                    data: "",
                    success: function (data) {
                        var city = $("#PBSCity");
                        city.find('option').remove();
                        var aaa = '<option value="" hassubinfo="true">请选择</option>';
                        city.append(aaa);
                        if (data.length > 0) {
                            for (var i = 0; i < data.length; i++) {
                                var o = '<option value="' + data[i].CodeId + '" hassubinfo="true">' + data[i].Name + '</option>';
                                city.append(o);
                            }
                        }
                        $("#PBSCity").trigger('chosen:updated');//更新选项
                    },
                    error: function () { }
                });
            });
        });
    </script>
}
zhengcaioa/zhengcaioa/Views/Project/Add.cshtml
@@ -723,7 +723,7 @@
                        }
                        else {
                            // toastr.error("失败");
                            parent.layer.msg('失败', { icon: 5 });
                            parent.layer.msg(data.Message, { icon: 5 });
                        }
                },
zhengcaioa/zhengcaioa/Views/Signin/AttendanceRule.cshtml
@@ -1,5 +1,15 @@
@{
@model DTO.AdmAttendanceRuleDTO
@using DTO;
@using zhengcaioa.Models;
@{
    Layout = null;
    List< AdmAttendanceRulesDtlDTO >  admAttendanceRulesDtlDTOs =  Model.admAttendanceRulesDtlDTOs;
    var jiejiari =  admAttendanceRulesDtlDTOs.Where(x=>x.Name=="jiejiari").ToList();
    var tiaoxiuri = admAttendanceRulesDtlDTOs.Where(x => x.Name == "tiaoxiuri").ToList();
}
<!DOCTYPE html>
<html>
@@ -55,8 +65,8 @@
            padding-bottom: 15px !important;
        }
        .addBtn{
            top:10px;
        .addBtn {
            top: 10px;
        }
    </style>
@@ -99,8 +109,9 @@
                                <h5 style="color:cornflowerblue;">工作日:</h5>
                                <div class="clearfix layer-area" style="padding-bottom:15px;">
                                    <div class="col-sm-6 col-md-6">
                                        周 &nbsp;<input type="number" value="1" name="WeekStart" id="WeekStart" style="width:100px;">&nbsp;-
                                        周 &nbsp;<input type="number" value="5" name="WeekEnd" id="WeekEnd" style="width:100px;">
                                        周 &nbsp;<input type="number" value="@Model.WeekStart" name="WeekStart" id="WeekStart" style="width:100px;" oninput="if(value.length>8)value=value.slice(0,18)" onkeyup="value=value.toString().match(/^\d+(?:\.\d{0,2})?/)" >&nbsp;-
                                        周 &nbsp;<input type="number" value="@Model.WeekEnd" name="WeekEnd" id="WeekEnd" style="width:100px;" oninput="if(value.length>8)value=value.slice(0,18)" onkeyup="value=value.toString().match(/^\d+(?:\.\d{0,2})?/)" >
                                        <input type="hidden" value="@Model.Id"    id="Id" name="Id" >
                                    </div>
                                </div>
@@ -108,8 +119,8 @@
                                <h5 style="color:cornflowerblue;">上班时间:</h5>
                                <div class="clearfix layer-area" style="padding-bottom:15px;">
                                    <div class="col-sm-6 col-md-6">
                                        <span>上午:</span><input class="layui-input  layer-date  ldate form-control" type="text" value="09:00" name="WorkingStart" id="WorkingStart" placeholder="HH:mm:ss" style="width:100px;">-
                                        <input type="text" value="12:00" class="layui-input  layer-date  ldate form-control" name="WorkingEnd" id="WorkingEnd" placeholder="HH:mm:ss" style="width:100px;">
                                        <span>上午:</span><input   type="number" value="@Model.WorkingStart" name="WorkingStart" id="WorkingStart"style="width:100px;" oninput="if(value.length>8)value=value.slice(0,18)"  onkeyup="value=value.toString().match(/^\d+(?:\.\d{0,2})?/)">-
                                        <input type="number" value="@Model.WorkingEnd"   name="WorkingEnd" id="WorkingEnd"   style="width:100px;" oninput="if(value.length>8)value=value.slice(0,18)"  onkeyup="value=value.toString().match(/^\d+(?:\.\d{0,2})?/)">
                                    </div>
                                </div>
@@ -117,8 +128,8 @@
                                <div class="clearfix layer-area" style="padding-bottom:15px;">
                                    <div class="col-sm-6 col-md-6">
                                        <span>下午:</span><input type="text" class="layui-input  layer-date  ldate form-control" value="13:00" name="OffworkStart" id="OffworkStart" style="width:100px;">-
                                        <input type="text" class="layui-input  layer-date  ldate form-control" value="18:00" name="OffworkEnd" id="OffworkEnd" style="width:100px;">
                                        <span>下午:</span><input type="number"  value="@Model.OffworkStart" name="OffworkStart" id="OffworkStart" style="width:100px;" oninput="if(value.length>8)value=value.slice(0,18)" onkeyup="value=value.toString().match(/^\d+(?:\.\d{0,2})?/)">-
                                        <input type="number"  value="@Model.OffworkEnd" name="OffworkEnd" id="OffworkEnd" style="width:100px;" oninput="if(value.length>8)value=value.slice(0,18)" onkeyup="value=value.toString().match(/^\d+(?:\.\d{0,2})?/)">
                                    </div>
                                </div>
@@ -126,17 +137,17 @@
                                <div class="clearfix layer-area" style="padding-bottom:15px;">
                                    <div class="col-sm-6 col-md-6">
                                        <span>全勤奖</span>
                                        <input type="number" value="200.00" name="FullAttendance" id="FullAttendance" style="width:150px">元
                                        <input type="number" value="@Model.FullAttendance" name="FullAttendance" id="FullAttendance" style="width:150px" oninput="if(value.length>8)value=value.slice(0,18)" onkeyup="value=value.toString().match(/^\d+(?:\.\d{0,2})?/)">元
                                    </div>
                                </div>
                                <h5 style="color:cornflowerblue;">迟到扣款:</h5>
                                <div class="clearfix layer-area" style="padding-bottom:15px;">
                                    <div class="col-sm-8 col-md-8">
                                        <span>15分钟</span><input style="width:150px" type="number" min="0.01" step="0.01" max="999999" value="10.00" name="LatePayment1">元
                                        <span>30分钟</span><input style="width:150px" type="number" min="0.01" step="0.01" max="999999" value="10.00" name="LatePayment2">元
                                        <span>1小时</span><input style="width:150px" type="number" min="0.01" step="0.01" max="999999" value="50.00" name="LatePayment3">元
                                        <span>2小时</span><input style="width:150px" type="number" min="0.01" step="0.01" max="999999" value="100.00" name="LatePayment4">元
                                        <span>15分钟</span><input style="width:150px" type="number" min="0.01" step="0.01" max="999999" value="@Model.LatePayment1" name="LatePayment1" oninput="if(value.length>8)value=value.slice(0,18)" onkeyup="value=value.toString().match(/^\d+(?:\.\d{0,2})?/)">元
                                        <span>30分钟</span><input style="width:150px" type="number" min="0.01" step="0.01" max="999999" value="@Model.LatePayment2" name="LatePayment2" oninput="if(value.length>8)value=value.slice(0,18)" onkeyup="value=value.toString().match(/^\d+(?:\.\d{0,2})?/)">元
                                        <span>1小时</span><input style="width:150px" type="number" min="0.01" step="0.01" max="999999" value="@Model.LatePayment3" name="LatePayment3" oninput="if(value.length>8)value=value.slice(0,18)" onkeyup="value=value.toString().match(/^\d+(?:\.\d{0,2})?/)">元
                                        <span>2小时</span><input style="width:150px" type="number" min="0.01" step="0.01" max="999999" value="@Model.LatePayment4" name="LatePayment4" oninput="if(value.length>8)value=value.slice(0,18)" onkeyup="value=value.toString().match(/^\d+(?:\.\d{0,2})?/)">元
                                    </div>
                                </div>
@@ -144,51 +155,107 @@
                                <h5 style="color:cornflowerblue;">旷工扣款:</h5>
                                <div class="clearfix layer-area" style="padding-bottom:15px;">
                                    <div class="col-sm-6 col-md-6">
                                        <span>迟到</span><input style="width:150px" type="number" min="0" step="1" max="999999" value="120" name="Absenteeism">分钟记为旷工
                                        <span>半天</span><input style="width:150px" type="number" min="0.01" step="0.01" max="999999" value="50.00" name="AbsenteeismPayment1">元
                                        <span>1天</span><input style="width:150px" type="number" min="0.01" step="0.01" max="999999" value="200.00" name="AbsenteeismPayment2">元
                                        <span>迟到</span><input style="width:150px" type="number" min="0" step="1" max="999999" value="@Model.Absenteeism" name="Absenteeism" oninput="if(value.length>8)value=value.slice(0,18)" onkeyup="value=value.toString().match(/^\d+(?:\.\d{0,2})?/)">分钟记为旷工
                                        <span>半天</span><input style="width:150px" type="number" min="0.01" step="0.01" max="999999" value="@Model.AbsenteeismPayment1" name="AbsenteeismPayment1" oninput="if(value.length>8)value=value.slice(0,18)" onkeyup="value=value.toString().match(/^\d+(?:\.\d{0,2})?/)">元
                                        <span>1天</span><input style="width:150px" type="number" min="0.01" step="0.01" max="999999" value="@Model.AbsenteeismPayment2" name="AbsenteeismPayment2" oninput="if(value.length>8)value=value.slice(0,18)" onkeyup="value=value.toString().match(/^\d+(?:\.\d{0,2})?/)">元
                                    </div>
                                </div>
                                <h5 style="color:cornflowerblue;">事假扣款:</h5>
                                <div class="clearfix layer-area" style="padding-bottom:15px;">
                                    <div class="col-sm-8 col-md-8">
                                        <span>1小时</span><input style="width:150px" type="number" min="0.01" step="0.01" max="999999" value="10.00" name="PersonalPayment1">元
                                        <span>2小时</span><input style="width:150px" type="number" min="0.01" step="0.01" max="999999" value="10.00" name="PersonalPayment2">元
                                        <span>半天</span><input style="width:150px" type="number" min="0.01" step="0.01" max="999999" value="10.00"  name="PersonalPayment3">元
                                        <span>1天</span><input style="width:150px" type="number" min="0.01" step="0.01" max="999999" value="50.00"   name="PersonalPayment4">元
                                        <span>1小时</span><input style="width:150px" type="number" min="0.01" step="0.01" max="999999" value="@Model.PersonalPayment1" name="PersonalPayment1" oninput="if(value.length>8)value=value.slice(0,18)" onkeyup="value=value.toString().match(/^\d+(?:\.\d{0,2})?/)">元
                                        <span>2小时</span><input style="width:150px" type="number" min="0.01" step="0.01" max="999999" value="@Model.PersonalPayment2" name="PersonalPayment2" oninput="if(value.length>8)value=value.slice(0,18)" onkeyup="value=value.toString().match(/^\d+(?:\.\d{0,2})?/)"> 元
                                        <span>半天</span><input style="width:150px" type="number" min="0.01" step="0.01" max="999999" value="@Model.PersonalPayment3" name="PersonalPayment3" oninput="if(value.length>8)value=value.slice(0,18)" onkeyup="value=value.toString().match(/^\d+(?:\.\d{0,2})?/)">元
                                        <span>1天</span><input style="width:150px" type="number" min="0.01" step="0.01" max="999999" value="@Model.PersonalPayment4" name="PersonalPayment4" oninput="if(value.length>8)value=value.slice(0,18)" onkeyup="value=value.toString().match(/^\d+(?:\.\d{0,2})?/)">元
                                    </div>
                                </div>
                                <h5 style="color:cornflowerblue;">病假扣款:</h5>
                                <div class="clearfix layer-area" style="padding-bottom:15px;">
                                    <div class="col-sm-8 col-md-8">
                                        <span>1小时</span><input style="width:150px" type="number" min="0.01" step="0.01" max="999999" value="10.00" name="SickPayment1">元
                                        <span>2小时</span><input style="width:150px" type="number" min="0.01" step="0.01" max="999999" value="10.00" name="SickPayment2">元
                                        <span>半天</span><input style="width:150px" type="number" min="0.01" step="0.01" max="999999" value="10.00"  name="SickPayment3">元
                                        <span>1天</span><input style="width:150px" type="number" min="0.01" step="0.01" max="999999" value="100.00"  name="SickPayment4">元
                                        <span>1小时</span><input style="width:150px" type="number" min="0.01" step="0.01" max="999999" value="@Model.SickPayment1" name="SickPayment1" oninput="if(value.length>8)value=value.slice(0,18)" onkeyup="value=value.toString().match(/^\d+(?:\.\d{0,2})?/)">元
                                        <span>2小时</span><input style="width:150px" type="number" min="0.01" step="0.01" max="999999" value="@Model.SickPayment2" name="SickPayment2" oninput="if(value.length>8)value=value.slice(0,18)" onkeyup="value=value.toString().match(/^\d+(?:\.\d{0,2})?/)">元
                                        <span>半天</span><input style="width:150px" type="number" min="0.01" step="0.01" max="999999" value="@Model.SickPayment3" name="SickPayment3" oninput="if(value.length>8)value=value.slice(0,18)" onkeyup="value=value.toString().match(/^\d+(?:\.\d{0,2})?/)">元
                                        <span>1天</span><input style="width:150px" type="number" min="0.01" step="0.01" max="999999" value="@Model.SickPayment4" name="SickPayment4" oninput="if(value.length>8)value=value.slice(0,18)" onkeyup="value=value.toString().match(/^\d+(?:\.\d{0,2})?/)">元
                                    </div>
                                </div>
                                <h5 style="color:red;">节假日:</h5>
                                <div class="clearfix layer-area" style="padding-bottom:15px;">
                                    <div class="col-sm-3 col-md-3">
                                        <div class="setSelect">
                                            <input type="text" value="" class="layui-input  layer-date  ldate form-control " id="holiday_s1" name="holiday_s" style="width:150px;"> -
                                            <input type="text" value="" class="layui-input  layer-date  ldate form-control" id="holiday_e1" name="holiday_e" style="width:150px;">
                                            <button type="button" class="addBtn" style="padding-bottom:10px;" onclick="addBtn(this)" data-type="1">+</button>
                                        </div>
                                        @if (jiejiari == null || jiejiari.Count == 0)
                                        {
                                            <div class="setSelect">
                                                <input type="text" value="" class="layui-input  layer-date  ldate form-control   holiday_s" id="holiday_s1" name="holiday_s" style="width:150px;" onfocus='laydate({elem:"#holiday_s1",format:"YYYY-MM-DD",theme:"#fdd5004"})' /> -
                                                <input type="text" value="" class="layui-input  layer-date  ldate form-control   holiday_e" id="holiday_e1" name="holiday_e" style="width:150px;" onfocus='laydate({elem:"#holiday_e1",format:"YYYY-MM-DD",theme:"#fdd5004"})' />
                                                <button type="button" class="addBtn" style="padding-bottom:10px;" onclick="addBtn(this)" data-type="1">+</button>
                                            </div>
                                        }
                                        else
                                        {
                                            for (int i = 0; i < jiejiari.Count; i++)
                                            {
                                                if (i == 0)
                                                {
                                                    <div class="setSelect">
                                                        <input type="text" value="@jiejiari[i].ValueStart" class="layui-input  layer-date  ldate form-control   holiday_s" id="@("holiday_s"+(i+1))" name="holiday_s" style="width:150px;" onfocus='laydate({elem:"#holiday_s1",format:"YYYY-MM-DD",theme:"#fdd5004"})' /> -
                                                        <input type="text" value="@jiejiari[i].ValueEnd" class="layui-input  layer-date  ldate form-control   holiday_e" id="@("holiday_e"+(i+1))" name="holiday_e" style="width:150px;" onfocus='laydate({elem:"#holiday_e1",format:"YYYY-MM-DD",theme:"#fdd5004"})' />
                                                        <button type="button" class="addBtn" style="padding-bottom:10px;" onclick="addBtn(this)" data-type="1">+</button>
                                                    </div>
                                                }
                                                else
                                                {
                                    <div class="setSelect">
                                        <input type="text" value="@jiejiari[i].ValueStart" class="layui-input  layer-date  ldate form-control   holiday_s" id="@("holiday_s"+(i+1))" name="holiday_s" style="width:150px;" onfocus='laydate({elem:"#holiday_s1",format:"YYYY-MM-DD",theme:"#fdd5004"})' /> -
                                        <input type="text" value="@jiejiari[i].ValueEnd" class="layui-input  layer-date  ldate form-control   holiday_e" id="@("holiday_e"+(i+1))" name="holiday_e" style="width:150px;" onfocus='laydate({elem:"#holiday_e1",format:"YYYY-MM-DD",theme:"#fdd5004"})' />
                                        <button type="button" class="addBtn" onclick="delBtn(this,0,'holiday')" data-type="1">-</button>
                                    </div>
                                                }
                                            }
                                        }
                                    </div>
                                </div>
                                <h5 style="color:red;">调休日:</h5>
                                <div class="clearfix layer-area" style="padding-bottom:15px;">
                                    <div class="col-sm-3 col-md-3">
                                        <div class="setSelect">
                                            <input type="text" value="" class="layui-input  layer-date  ldate form-control " id="rest_s1" name="rest_s" style="width:150px;"> -
                                            <input type="text" value="" class="layui-input  layer-date  ldate form-control " id="rest_e1"  name="rest_e" style="width:150px;">
                                            <button type="button" class="addBtn" style="padding-bottom:10px;" onclick="addRestBtn(this)" data-type="1">+</button>
                                        </div>
                                        @if (tiaoxiuri == null || tiaoxiuri.Count == 0)
                                        {
                                            <div class="setSelect">
                                                <input type="text" value="" class="layui-input  layer-date  ldate form-control rest_s" id="rest_s1" name="rest_s" style="width:150px;" onfocus='laydate({elem:"#rest_s1",format:"YYYY-MM-DD",theme:"#fdd5004"})' /> -
                                                <input type="text" value="" class="layui-input  layer-date  ldate form-control rest_e" id="rest_e1" name="rest_e" style="width:150px;" onfocus='laydate({elem:"#rest_e1",format:"YYYY-MM-DD",theme:"#fdd5004"})' />
                                                <button type="button" class="addBtn" style="padding-bottom:10px;" onclick="addRestBtn(this)" data-type="1">+</button>
                                            </div>
                                        }
                                        else
                                        {
                                            for (int i = 0; i < tiaoxiuri.Count; i++)
                                            {
                                                if (i == 0)
                                                {
                                                    <div class="setSelect">
                                                        <input type="text" value="@tiaoxiuri[i].ValueStart" class="layui-input  layer-date  ldate form-control rest_s" id="@("rest_s"+(i+1))" name="rest_s" style="width:150px;" onfocus='laydate({elem:"#rest_s1",format:"YYYY-MM-DD",theme:"#fdd5004"})' /> -
                                                        <input type="text" value="@tiaoxiuri[i].ValueEnd" class="layui-input  layer-date  ldate form-control rest_e" id="@("rest_e"+(i+1))" name="rest_e" style="width:150px;" onfocus='laydate({elem:"#rest_e1",format:"YYYY-MM-DD",theme:"#fdd5004"})' />
                                                        <button type="button" class="addBtn" style="padding-bottom:10px;" onclick="addRestBtn(this)" data-type="1">+</button>
                                                    </div>
                                                }
                                                else
                                                {
                                    <div class="setSelect">
                                        <input type="text" value="@tiaoxiuri[i].ValueStart" class="layui-input  layer-date  ldate form-control rest_s" id="@("rest_s"+(i+1))" name="rest_s" style="width:150px;" onfocus='laydate({elem:"#rest_s1",format:"YYYY-MM-DD",theme:"#fdd5004"})' /> -
                                        <input type="text" value="@tiaoxiuri[i].ValueEnd" class="layui-input  layer-date  ldate form-control rest_e" id="@("rest_e"+(i+1))" name="rest_e" style="width:150px;" onfocus='laydate({elem:"#rest_e1",format:"YYYY-MM-DD",theme:"#fdd5004"})' />
                                        <button type="button" class="addBtn" onclick="delBtn(this,0,'rest')" data-type="1">-</button>
                                    </div>
                                                }
                                            }
                                        }
                                    </div>
                                </div>
@@ -198,17 +265,42 @@
                                        <span>节假日</span>
                                        <label>
                                            1倍
                                            <input name="Gala" type="radio" checked="" value="1" class="type_b">
                                            @if (Model.Gala == 1)
                                            {
                                                <input name="Gala" type="radio"   value="1" class="type_b" checked="checked">
                                            }
                                            else
                                            {
                                                <input name="Gala" type="radio"   value="1" class="type_b" >
                                            }
                                        </label>
                                        &nbsp;&nbsp;&nbsp;&nbsp;
                                        <label>
                                            2倍
                                            <input name="Gala" type="radio" value="2" class="type_b">
                                            @if (Model.Gala == 2)
                                            {
                                                <input name="Gala" type="radio" value="2" class="type_b" checked="checked">
                                            }
                                            else
                                            {
                                                <input name="Gala" type="radio" value="2" class="type_b">
                                            }
                                        </label>
                                        &nbsp;&nbsp;&nbsp;&nbsp;
                                        <label>
                                            3倍
                                            <input name="Gala" type="radio" value="3" class="type_b">
                                            @if (Model.Gala == 3)
                                            {
                                                <input name="Gala" type="radio" value="3" class="type_b" checked="checked">
                                            }
                                            else
                                            {
                                                <input name="Gala" type="radio" value="3" class="type_b">
                                            }
                                        </label>
                                    </div>
@@ -216,10 +308,34 @@
                                <div class="clearfix layer-area" style="padding-bottom:15px; height:45px;">
                                    <div class="col-sm-6 col-md-6">
                                        <span>周末</span>
                                        <label>1倍 <input name="Weekend1" type="radio" checked="" value="1" class="type_b"></label>
                                        <label>
                                            1倍
                                            @if (Model.Weekend1 == 1)
                                            {
                                                <input name="Weekend1" type="radio" checked="checked" value="1" class="type_b">
                                            }
                                            else
                                            {
                                                <input name="Weekend1" type="radio" value="1" class="type_b">
                                            }
                                        </label>
                                        &nbsp;&nbsp;&nbsp;&nbsp;
                                        <label>2倍<input name="Weekend1" type="radio" value="2" class="type_b"></label>
                                        <label>
                                            2倍
                                            @if (Model.Weekend1 == 2)
                                            {
                                            <input name="Weekend1" type="radio" checked="checked" value="2" class="type_b">
                                            }
                                            else
                                            {
                                            <input name="Weekend1" type="radio" value="2" class="type_b">
                                            }
                                        </label>
                                    </div>
                                </div>
@@ -227,16 +343,38 @@
                                <div class="clearfix layer-area" style="padding-bottom:15px;height:45px;">
                                    <div class="col-sm-6 col-md-6">
                                        <span>平时</span>
                                        <label for="p1">1倍/小时<input id="p1" name="usually" type="radio" checked="" value="1" class="type_b"></label>
                                        <label for="p1">
                                            1倍/小时
                                            @if (Model.Usually == 1)
                                            {
                                                <input name="Usually" type="radio" checked="checked" value="1" class="type_b">
                                            }
                                            else
                                            {
                                                <input name="Usually" type="radio" value="1" class="type_b">
                                            }
                                        </label>
                                        &nbsp;&nbsp;&nbsp;&nbsp;
                                        <label for="p2">2倍/小时<input id="p2" name="usually" type="radio" value="2" class="type_b"></label>
                                        <label for="Usually">
                                            2倍/小时
                                            @if (Model.Usually == 2)
                                            {
                                                <input name="Usually" type="radio" checked="checked" value="2" class="type_b">
                                            }
                                            else
                                            {
                                                <input name="Usually" type="radio" value="2" class="type_b">
                                            }
                                        </label>
                                    </div>
                                </div>
                                <div class="clearfix layer-area" style="padding-bottom:15px;height:45px;">
                                    <div class="col-sm-6 col-md-6">
                                        <span></span>
                                        <input name="holiday" value="" type="hidden" id="holiday">
                                        <input name="rest" value="" type="hidden" id="rest">
                                        @*<input name="holiday" value="" type="hidden" id="holiday">
                                        <input name="rest" value="" type="hidden" id="rest">*@
                                    </div>
                                </div>
                            </div>
@@ -248,7 +386,7 @@
        <div class="wrapper wrapper-content" style="margin-top:0px"></div>
        <div class="ibox-content" id="top" style="z-index:100; position:fixed; height:50px; width:100%;bottom:0; text-align: right; padding-top:8px ">
            <div class="" style="float:right;" data-bootstro-width="500px" data-bootstro-content="功能按钮:“保存”,“删除”">
                <a class="btn btn-success" href="javascript:void(0)" onclick="SaveAttendanceRule();" style="margin-left:4px; border-radius:4px;">
                    <i class="glyphicon glyphicon-ok"></i>&nbsp;&nbsp;<span class="bold">提交</span>
                </a>
@@ -318,11 +456,11 @@
            //});
            laydate({ elem: "#holiday_e1", format: 'YYYY/MM/DD', istime: true, event: "focus" });
            laydate({ elem: "#holiday_s1", format: 'YYYY/MM/DD', istime: true, event: "focus" });
            laydate({ elem: "#rest_s1", format: 'YYYY/MM/DD', istime: true, event: "focus" });
            laydate({ elem: "#rest_e1", format: 'YYYY/MM/DD', istime: true, event: "focus" });
            //laydate({ elem: "#holiday_e1", format: 'YYYY/MM/DD', istime: true, event: "focus" });
            //laydate({ elem: "#holiday_s1", format: 'YYYY/MM/DD', istime: true, event: "focus" });
            //laydate({ elem: "#rest_s1", format: 'YYYY/MM/DD', istime: true, event: "focus" });
            //laydate({ elem: "#rest_e1", format: 'YYYY/MM/DD', istime: true, event: "focus" });
        });
        var _SigninList = function () {
@@ -330,14 +468,14 @@
        }
        // 保存打卡信息
        function SaveAttendanceRule(signinType) {
            $.ajax({
                type: "POST",
                url: "/Signin/SaveAttendanceRule",
                dataType: "json",
                global: false,
                data:  $('form').serializeArray(),
                data: $('form').serializeArray(),
                success: function (data) {
                    toastr.success("保存成功");
                },
@@ -358,88 +496,105 @@
        //提交请求
        $('#searchBtn').on('click', function () {
            var holiday = '';
            $('.holiday_s').each(function () {
                var holiday_s = $(this).val();
                var holiday_e = $(this).next('.holiday_e').val();
                if (holiday_s != '' && holiday_e != '') {
                    holiday += ',' + holiday_s + '+' + holiday_e;
                }
            })
            holiday = holiday.substring(1)
            if (holiday) {
                $('#holiday').val(holiday);
            }
            var rest = '';
            $('.rest_s').each(function () {
                var rest_s = $(this).val();
                var rest_e = $(this).next('.rest_e').val();
                if (rest_s != '' && rest_e != '') {
                    rest += ',' + rest_s + '+' + rest_e;
                }
            })
            rest = rest.substring(1)
            if (rest) {
                $('#rest').val(rest);
            }
            formFile = new FormData($('#form')[0]);
        var SaveAttendanceRule =    function () {
            $.ajax({
                url: "/index.php/home/index/attendance.html",
                type: 'POST',
                data: formFile,
                async: true,
                cache: false,
                contentType: false,
                processData: false,
                // traditional:true,
                // dataType:'json',
                success: function (res) {
                    console.log(res);
                    if (res.status == 1) {
                        layer.alert(res.msg)
                    } else {
                        layer.alert(res.msg)
                type: "POST",
                url: "/Signin/SaveAttendanceRule",
                dataType: "json",
                global: false,
                data: $('form').serializeArray(),
                success: function (data) {
                    if (data.Result) {
                        //  parent._afterSave(true);
                        parent.layer.msg('成功保存', { icon: 6 });
                        window.location = "/Signin/AttendanceRule";
                        //try {
                        //    _pageAutoClose();//自动关闭页面方法
                        //}
                        //catch (err) {
                        //    parent._CloseTab1("/Signin/SaveAttendanceRule/");
                        //}
                    }
                    else {
                        // toastr.error("失败");
                        parent.layer.msg(data.Message, { icon: 5 });
                    }
                },
                error: function () {
                    parent.layer.msg('失败', { icon: 5 });
                }
            })
        });
            });
        } ;
        //本月节假日设置
        function addBtn(obj) {
            var int = $('.holiday_s').length - 1;
            var id = $('.holiday_s').eq(int).attr('id');
            var holiday_ss = parseInt(id.replace("holiday_s", "")) + 1;
            var int1 = $('.holiday_e').length - 1
            var id1 = $('.holiday_e').eq(int1).attr('id');
            var holiday_es = parseInt(id1.replace("holiday_e", "")) + 1;
            var html = ' <div class="setSelect">\n' +
                '                <span></span>\n' +
                '                <input type="text" value="" class="layui-input  layer-date  ldate form-control" name="holiday_s[]" class="Wdate holiday_s" style="width:150px;"> -\n' +
                '                <input type="text" value="" class="layui-input  layer-date  ldate form-control" name="holiday_e[]" class="Wdate holiday_e" style="width:150px;">\n' +
                '                <input type="text" value="" class="layui-input  layer-date  ldate form-control   holiday_s" id="holiday_s' + holiday_ss + '" name="holiday_s"  style="width:150px;"   onfocus=\'laydate({elem:"#holiday_s' + holiday_ss + '",format:"YYYY-MM-DD",theme:"#fdd5004"})\'  /> -\n' +
                '                <input type="text" value="" class="layui-input  layer-date  ldate form-control   holiday_e" id="holiday_e' + holiday_es + '" name="holiday_e"   style="width:150px;"   onfocus=\'laydate({elem:"#holiday_e' + holiday_es + '",format:"YYYY-MM-DD",theme:"#fdd5004"})\'  />\n' +
                '                <button type="button" class="addBtn" onclick="delBtn(this,0,\'holida\')" data-type="1">-</button>\n' +
                '            </div>'
            $(obj).parent('div').after(html);
            $(obj).parent('div').parent('div').append(html);
        }
        };
        function addRestBtn(obj) {
            var int = $('.rest_s').length - 1;
            var id = $('.rest_s').eq(int).attr('id');
            var rest_ss = parseInt(id.replace("rest_s", "")) + 1;
            var int1 = $('.rest_e').length - 1
            var id1 = $('.rest_e').eq(int1).attr('id');
            var rest_ee = parseInt(id1.replace("rest_e", "")) + 1;
            var html = ' <div class="setSelect">\n' +
                '                <span></span>\n' +
                '                <input type="text" value="" class="layui-input  layer-date  ldate form-control" name="rest_s[]" class="Wdate rest_s" style="width:150px;"> -\n' +
                '                <input type="text" value=""  class="layui-input  layer-date  ldate form-control" name="rest_e[]" class="Wdate rest_e" style="width:150px;">\n' +
                '                <input type="text" value="" class="layui-input  layer-date  ldate form-control rest_s"  id="rest_s' + rest_ss + '" name="rest_s" style="width:150px;" onfocus=\'laydate({elem:"#rest_s' + rest_ss + '",format:"YYYY-MM-DD",theme:"#fdd5004"})\' /> -\n' +
                '                <input type="text" value=""  class="layui-input  layer-date  ldate form-control rest_e"  id="rest_e' + rest_ee + '" name="rest_e"   style="width:150px;" onfocus=\'laydate({elem:"#rest_e' + rest_ee + '",format:"YYYY-MM-DD",theme:"#fdd5004"})\' />\n' +
                '                <button type="button" class="addBtn" onclick="delBtn(this,0,\'rest\')" data-type="1">-</button>\n' +
                '            </div>'
            $(obj).parent('div').after(html);
        }
            $(obj).parent('div').parent('div').append(html);
        };
        function delBtn(obj, id, tb) {
            if (id > 0) {
                var url = "/index.php/home/white/del.html"
                $.post(url, { id: id, tb: tb }, function (res) {
                    if (res.status == 1) {
                        $(obj).parent().remove();
                    } else {
                        layer.alert(res.msg)
                    }
                })
            }
            //if (id > 0) {
            //    var url = "/index.php/home/white/del.html"
            //    $.post(url, { id: id, tb: tb }, function (res) {
            //        if (res.status == 1) {
            //            $(obj).parent().remove();
            //        } else {
            //            layer.alert(res.msg)
            //        }
            //    })
            //}
            $(obj).parent().remove();
        }