using System; using System.Collections.Generic; using System.Data; using System.Linq; using System.Text; namespace lyfzAttendance.Controller { class AttendanceController : LYFZ.DAL.BaseDataOperate { #region 属性和字段 private Model.AttendanceRecord model = new Model.AttendanceRecord(); public Model.AttendanceRecord CurrentModel { get { return model; } set { model = value; } } public override object ObjModel { get { return this.CurrentModel; } } public override string TableName { get; set; } = "lonindata"; public override string TableFieldNameString { get; set; } = ""; #endregion #region 查询数据 public Model.AttendanceRecord DataRowToModel(DataRow row) { return DataRowToModelObject(row) as Model.AttendanceRecord; } #endregion public bool Add(string overlookFieldList = "ID") { try { return base.Add(CurrentModel, overlookFieldList); } catch(Exception ex) { LogHelper.LogFatal(typeof(AttendanceController), "上传服务器失败", ex); } return false; } } }