From 29b7a55270f0091250c7ee54425048218fd96cba Mon Sep 17 00:00:00 2001 From: duguoqing Date: Wed, 9 Nov 2022 15:00:04 +0800 Subject: [PATCH] =?UTF-8?q?=E6=96=87=E5=8C=96=E5=9F=BA=E7=A1=80=E8=AF=BE?= =?UTF-8?q?=E6=88=90=E7=BB=A9=E6=95=B0=E6=8D=AE=E8=A1=A8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../Controllers/ods_wfjckcjsjController.cs | 117 +++++++++++++ .../Views/ods_wfjckcjsj/Form.cshtml | 55 ++++++ .../Views/ods_wfjckcjsj/Form.js | 51 ++++++ .../Views/ods_wfjckcjsj/Index.cshtml | 26 +++ .../Views/ods_wfjckcjsj/Index.js | 105 ++++++++++++ .../Learun.Application.Web.csproj | 5 + .../Changyang_zhdn/ODS_WFJCKCJSJMap.cs | 29 ++++ .../Learun.Application.Mapping.csproj | 1 + .../ods_wfjckcjsj/ODS_WFJCKCJSJEntity.cs | 105 ++++++++++++ .../ods_wfjckcjsj/ods_wfjckcjsjBLL.cs | 125 ++++++++++++++ .../ods_wfjckcjsj/ods_wfjckcjsjIBLL.cs | 48 ++++++ .../ods_wfjckcjsj/ods_wfjckcjsjService.cs | 156 ++++++++++++++++++ .../Learun.Application.TwoDevelopment.csproj | 4 + 13 files changed, 827 insertions(+) create mode 100644 Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/Changyang_zhdn/Controllers/ods_wfjckcjsjController.cs create mode 100644 Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/Changyang_zhdn/Views/ods_wfjckcjsj/Form.cshtml create mode 100644 Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/Changyang_zhdn/Views/ods_wfjckcjsj/Form.js create mode 100644 Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/Changyang_zhdn/Views/ods_wfjckcjsj/Index.cshtml create mode 100644 Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/Changyang_zhdn/Views/ods_wfjckcjsj/Index.js create mode 100644 Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.Mapping/Changyang_zhdn/ODS_WFJCKCJSJMap.cs create mode 100644 Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/Changyang_zhdn/ods_wfjckcjsj/ODS_WFJCKCJSJEntity.cs create mode 100644 Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/Changyang_zhdn/ods_wfjckcjsj/ods_wfjckcjsjBLL.cs create mode 100644 Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/Changyang_zhdn/ods_wfjckcjsj/ods_wfjckcjsjIBLL.cs create mode 100644 Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/Changyang_zhdn/ods_wfjckcjsj/ods_wfjckcjsjService.cs diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/Changyang_zhdn/Controllers/ods_wfjckcjsjController.cs b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/Changyang_zhdn/Controllers/ods_wfjckcjsjController.cs new file mode 100644 index 000000000..eaf1063c3 --- /dev/null +++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/Changyang_zhdn/Controllers/ods_wfjckcjsjController.cs @@ -0,0 +1,117 @@ +using Learun.Util; +using System.Data; +using Learun.Application.TwoDevelopment.Changyang_zhdn; +using System.Web.Mvc; +using System.Collections.Generic; + +namespace Learun.Application.Web.Areas.Changyang_zhdn.Controllers +{ + /// + /// 版 本 Learun-ADMS V7.0.6 力软敏捷开发框架 + /// Copyright (c) 2013-2020 力软信息技术(苏州)有限公司 + /// 创 建:超级管理员 + /// 日 期:2022-11-09 14:59 + /// 描 述:文化基础课成绩数据表 + /// + public class ods_wfjckcjsjController : MvcControllerBase + { + private ods_wfjckcjsjIBLL ods_wfjckcjsjIBLL = new ods_wfjckcjsjBLL(); + + #region 视图功能 + + /// + /// 主页面 + /// + /// + [HttpGet] + public ActionResult Index() + { + return View(); + } + /// + /// 表单页 + /// + /// + [HttpGet] + public ActionResult Form() + { + return View(); + } + #endregion + + #region 获取数据 + + /// + /// 获取页面显示列表数据 + /// + /// 分页参数 + /// 查询参数 + /// + [HttpGet] + [AjaxOnly] + public ActionResult GetPageList(string pagination, string queryJson) + { + Pagination paginationobj = pagination.ToObject(); + var data = ods_wfjckcjsjIBLL.GetPageList(paginationobj, queryJson); + var jsonData = new + { + rows = data, + total = paginationobj.total, + page = paginationobj.page, + records = paginationobj.records + }; + return Success(jsonData); + } + /// + /// 获取表单数据 + /// + /// 主键 + /// + [HttpGet] + [AjaxOnly] + public ActionResult GetFormData(string keyValue) + { + var ODS_WFJCKCJSJData = ods_wfjckcjsjIBLL.GetODS_WFJCKCJSJEntity( keyValue ); + var jsonData = new { + ODS_WFJCKCJSJ = ODS_WFJCKCJSJData, + }; + return Success(jsonData); + } + #endregion + + #region 提交数据 + + /// + /// 删除实体数据 + /// + /// 主键 + /// + [HttpPost] + [AjaxOnly] + public ActionResult DeleteForm(string keyValue) + { + ods_wfjckcjsjIBLL.DeleteEntity(keyValue); + return Success("删除成功!"); + } + /// + /// 保存实体数据(新增、修改) + /// + /// 主键 + /// 实体 + /// + [HttpPost] + [ValidateAntiForgeryToken] + [AjaxOnly] + public ActionResult SaveForm(string keyValue, string strEntity) + { + ODS_WFJCKCJSJEntity entity = strEntity.ToObject(); + ods_wfjckcjsjIBLL.SaveEntity(keyValue,entity); + if (string.IsNullOrEmpty(keyValue)) + { + } + return Success("保存成功!"); + } + #endregion + + } +} diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/Changyang_zhdn/Views/ods_wfjckcjsj/Form.cshtml b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/Changyang_zhdn/Views/ods_wfjckcjsj/Form.cshtml new file mode 100644 index 000000000..e51f965c7 --- /dev/null +++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/Changyang_zhdn/Views/ods_wfjckcjsj/Form.cshtml @@ -0,0 +1,55 @@ +@{ + ViewBag.Title = "文化基础课成绩数据表"; + Layout = "~/Views/Shared/_Form.cshtml"; +} +
+
+
学校机构代码
+ +
+
+
学校机构名称
+ +
+
+
学年
+ +
+
+
学期
+ +
+
+
年级
+ +
+
+
班级
+ +
+
+
专业名称
+ +
+
+
课程名称
+ +
+
+
课程分类
+
+
+
+
任课教师
+ +
+
+
课程成绩
+ +
+
+
数据采集时间
+ +
+
+@Html.AppendJsFile("/Areas/Changyang_zhdn/Views/ods_wfjckcjsj/Form.js") diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/Changyang_zhdn/Views/ods_wfjckcjsj/Form.js b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/Changyang_zhdn/Views/ods_wfjckcjsj/Form.js new file mode 100644 index 000000000..c9720ce35 --- /dev/null +++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/Changyang_zhdn/Views/ods_wfjckcjsj/Form.js @@ -0,0 +1,51 @@ +/* * 版 本 Learun-ADMS V7.0.6 力软敏捷开发框架(http://www.learun.cn) + * Copyright (c) 2013-2020 力软信息技术(苏州)有限公司 + * 创建人:超级管理员 + * 日 期:2022-11-09 14:59 + * 描 述:文化基础课成绩数据表 + */ +var acceptClick; +var keyValue = request('keyValue'); +var bootstrap = function ($, learun) { + "use strict"; + var page = { + init: function () { + $('.lr-form-wrap').lrscroll(); + page.bind(); + page.initData(); + }, + bind: function () { + $('#KCFL').lrDataSourceSelect({ code: 'CdLessonType',value: 'lessontypecode',text: 'lessontypename' }); + }, + initData: function () { + if (!!keyValue) { + $.lrSetForm(top.$.rootUrl + '/Changyang_zhdn/ods_wfjckcjsj/GetFormData?keyValue=' + keyValue, function (data) { + for (var id in data) { + if (!!data[id].length && data[id].length > 0) { + $('#' + id ).jfGridSet('refreshdata', data[id]); + } + else { + $('[data-table="' + id + '"]').lrSetFormData(data[id]); + } + } + }); + } + } + }; + // 保存数据 + acceptClick = function (callBack) { + if (!$('body').lrValidform()) { + return false; + } + var postData = { + strEntity: JSON.stringify($('body').lrGetFormData()) + }; + $.lrSaveForm(top.$.rootUrl + '/Changyang_zhdn/ods_wfjckcjsj/SaveForm?keyValue=' + keyValue, postData, function (res) { + // 保存成功后才回调 + if (!!callBack) { + callBack(); + } + }); + }; + page.init(); +} diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/Changyang_zhdn/Views/ods_wfjckcjsj/Index.cshtml b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/Changyang_zhdn/Views/ods_wfjckcjsj/Index.cshtml new file mode 100644 index 000000000..279323434 --- /dev/null +++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/Changyang_zhdn/Views/ods_wfjckcjsj/Index.cshtml @@ -0,0 +1,26 @@ +@{ + ViewBag.Title = "文化基础课成绩数据表"; + Layout = "~/Views/Shared/_Index.cshtml"; +} +
+
+
+
+
+
+
+
+ +
+ +
+
+
+
+
+
+@Html.AppendJsFile("/Areas/Changyang_zhdn/Views/ods_wfjckcjsj/Index.js") diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/Changyang_zhdn/Views/ods_wfjckcjsj/Index.js b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/Changyang_zhdn/Views/ods_wfjckcjsj/Index.js new file mode 100644 index 000000000..50d7a92ff --- /dev/null +++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/Changyang_zhdn/Views/ods_wfjckcjsj/Index.js @@ -0,0 +1,105 @@ +/* * 版 本 Learun-ADMS V7.0.6 力软敏捷开发框架(http://www.learun.cn) + * Copyright (c) 2013-2020 力软信息技术(苏州)有限公司 + * 创建人:超级管理员 + * 日 期:2022-11-09 14:59 + * 描 述:文化基础课成绩数据表 + */ +var refreshGirdData; +var bootstrap = function ($, learun) { + "use strict"; + var page = { + init: function () { + page.initGird(); + page.bind(); + }, + bind: function () { + // 刷新 + $('#lr_refresh').on('click', function () { + location.reload(); + }); + // 新增 + $('#lr_add').on('click', function () { + learun.layerForm({ + id: 'form', + title: '新增', + url: top.$.rootUrl + '/Changyang_zhdn/ods_wfjckcjsj/Form', + width: 600, + height: 400, + callBack: function (id) { + return top[id].acceptClick(refreshGirdData); + } + }); + }); + // 编辑 + $('#lr_edit').on('click', function () { + var keyValue = $('#gridtable').jfGridValue('GZZYQKSJID'); + if (learun.checkrow(keyValue)) { + learun.layerForm({ + id: 'form', + title: '编辑', + url: top.$.rootUrl + '/Changyang_zhdn/ods_wfjckcjsj/Form?keyValue=' + keyValue, + width: 600, + height: 400, + callBack: function (id) { + return top[id].acceptClick(refreshGirdData); + } + }); + } + }); + // 删除 + $('#lr_delete').on('click', function () { + var keyValue = $('#gridtable').jfGridValue('GZZYQKSJID'); + if (learun.checkrow(keyValue)) { + learun.layerConfirm('是否确认删除该项!', function (res) { + if (res) { + learun.deleteForm(top.$.rootUrl + '/Changyang_zhdn/ods_wfjckcjsj/DeleteForm', { keyValue: keyValue}, function () { + refreshGirdData(); + }); + } + }); + } + }); + }, + // 初始化列表 + initGird: function () { + $('#gridtable').lrAuthorizeJfGrid({ + url: top.$.rootUrl + '/Changyang_zhdn/ods_wfjckcjsj/GetPageList', + headData: [ + { label: "学校机构代码", name: "XXJGDM", width: 100, align: "left"}, + { label: "学校机构名称", name: "XXJGMC", width: 100, align: "left"}, + { label: "学年", name: "XN", width: 100, align: "left"}, + { label: "学期", name: "XQ", width: 100, align: "left"}, + { label: "年级", name: "NJ", width: 100, align: "left"}, + { label: "班级", name: "BJ", width: 100, align: "left"}, + { label: "专业名称", name: "ZYMC", width: 100, align: "left"}, + { label: "课程名称", name: "KCMC", width: 100, align: "left"}, + { label: "课程分类", name: "KCFL", width: 100, align: "left", + formatterAsync: function (callback, value, row, op,$cell) { + learun.clientdata.getAsync('custmerData', { + url: '/LR_SystemModule/DataSource/GetDataTable?code=' + 'CdLessonType', + key: value, + keyId: 'lessontypecode', + callback: function (_data) { + callback(_data['lessontypename']); + } + }); + }}, + { label: "任课教师", name: "RKJS", width: 100, align: "left"}, + { label: "课程成绩", name: "KCCJ", width: 100, align: "left"}, + { label: "数据采集时间", name: "SJCJSJ", width: 100, align: "left"}, + ], + mainId:'GZZYQKSJID', + isPage: true + }); + page.search(); + }, + search: function (param) { + param = param || {}; + $('#gridtable').jfGridSet('reload',{ queryJson: JSON.stringify(param) }); + } + }; + refreshGirdData = function () { + $('#gridtable').jfGridSet('reload'); + }; + page.init(); +} diff --git a/Learun.Framework.Ultimate V7/Learun.Application.Web/Learun.Application.Web.csproj b/Learun.Framework.Ultimate V7/Learun.Application.Web/Learun.Application.Web.csproj index f0aac45f6..7dee47db4 100644 --- a/Learun.Framework.Ultimate V7/Learun.Application.Web/Learun.Application.Web.csproj +++ b/Learun.Framework.Ultimate V7/Learun.Application.Web/Learun.Application.Web.csproj @@ -878,6 +878,7 @@ + @@ -6949,6 +6950,10 @@ + + + + diff --git a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.Mapping/Changyang_zhdn/ODS_WFJCKCJSJMap.cs b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.Mapping/Changyang_zhdn/ODS_WFJCKCJSJMap.cs new file mode 100644 index 000000000..81b9276b3 --- /dev/null +++ b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.Mapping/Changyang_zhdn/ODS_WFJCKCJSJMap.cs @@ -0,0 +1,29 @@ +using Learun.Application.TwoDevelopment.Changyang_zhdn; +using System.Data.Entity.ModelConfiguration; + +namespace Learun.Application.Mapping +{ + /// + /// 版 本 Learun-ADMS V7.0.6 力软敏捷开发框架 + /// Copyright (c) 2013-2020 力软信息技术(苏州)有限公司 + /// 创 建:超级管理员 + /// 日 期:2022-11-09 14:59 + /// 描 述:文化基础课成绩数据表 + /// + public class ODS_WFJCKCJSJMap : EntityTypeConfiguration + { + public ODS_WFJCKCJSJMap() + { + #region 表、主键 + //表 + this.ToTable("ODS_WFJCKCJSJ"); + //主键 + this.HasKey(t => t.GZZYQKSJID); + #endregion + + #region 配置关系 + #endregion + } + } +} + diff --git a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.Mapping/Learun.Application.Mapping.csproj b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.Mapping/Learun.Application.Mapping.csproj index ea2470d85..b5d12c852 100644 --- a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.Mapping/Learun.Application.Mapping.csproj +++ b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.Mapping/Learun.Application.Mapping.csproj @@ -637,6 +637,7 @@ + diff --git a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/Changyang_zhdn/ods_wfjckcjsj/ODS_WFJCKCJSJEntity.cs b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/Changyang_zhdn/ods_wfjckcjsj/ODS_WFJCKCJSJEntity.cs new file mode 100644 index 000000000..b5df08c65 --- /dev/null +++ b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/Changyang_zhdn/ods_wfjckcjsj/ODS_WFJCKCJSJEntity.cs @@ -0,0 +1,105 @@ +using Learun.Util; +using System; +using System.ComponentModel.DataAnnotations.Schema; + +namespace Learun.Application.TwoDevelopment.Changyang_zhdn +{ + /// + /// 版 本 Learun-ADMS V7.0.6 力软敏捷开发框架 + /// Copyright (c) 2013-2020 力软信息技术(苏州)有限公司 + /// 创 建:超级管理员 + /// 日 期:2022-11-09 14:59 + /// 描 述:文化基础课成绩数据表 + /// + public class ODS_WFJCKCJSJEntity + { + #region 实体成员 + /// + /// GZZYQKSJID + /// + [Column("GZZYQKSJID")] + public string GZZYQKSJID { get; set; } + /// + /// XXJGDM + /// + [Column("XXJGDM")] + public string XXJGDM { get; set; } + /// + /// XXJGMC + /// + [Column("XXJGMC")] + public string XXJGMC { get; set; } + /// + /// XN + /// + [Column("XN")] + public int? XN { get; set; } + /// + /// XQ + /// + [Column("XQ")] + public int? XQ { get; set; } + /// + /// NJ + /// + [Column("NJ")] + public string NJ { get; set; } + /// + /// BJ + /// + [Column("BJ")] + public string BJ { get; set; } + /// + /// ZYMC + /// + [Column("ZYMC")] + public string ZYMC { get; set; } + /// + /// KCMC + /// + [Column("KCMC")] + public string KCMC { get; set; } + /// + /// KCFL + /// + [Column("KCFL")] + public string KCFL { get; set; } + /// + /// RKJS + /// + [Column("RKJS")] + public string RKJS { get; set; } + /// + /// KCCJ + /// + [Column("KCCJ")] + public string KCCJ { get; set; } + /// + /// SJCJSJ + /// + [Column("SJCJSJ")] + public string SJCJSJ { get; set; } + #endregion + + #region 扩展操作 + /// + /// 新增调用 + /// + public void Create() + { + this.GZZYQKSJID = Guid.NewGuid().ToString(); + } + /// + /// 编辑调用 + /// + /// + public void Modify(string keyValue) + { + this.GZZYQKSJID = keyValue; + } + #endregion + #region 扩展字段 + #endregion + } +} + diff --git a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/Changyang_zhdn/ods_wfjckcjsj/ods_wfjckcjsjBLL.cs b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/Changyang_zhdn/ods_wfjckcjsj/ods_wfjckcjsjBLL.cs new file mode 100644 index 000000000..1715d1de0 --- /dev/null +++ b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/Changyang_zhdn/ods_wfjckcjsj/ods_wfjckcjsjBLL.cs @@ -0,0 +1,125 @@ +using Learun.Util; +using System; +using System.Data; +using System.Collections.Generic; + +namespace Learun.Application.TwoDevelopment.Changyang_zhdn +{ + /// + /// 版 本 Learun-ADMS V7.0.6 力软敏捷开发框架 + /// Copyright (c) 2013-2020 力软信息技术(苏州)有限公司 + /// 创 建:超级管理员 + /// 日 期:2022-11-09 14:59 + /// 描 述:文化基础课成绩数据表 + /// + public class ods_wfjckcjsjBLL : ods_wfjckcjsjIBLL + { + private ods_wfjckcjsjService ods_wfjckcjsjService = new ods_wfjckcjsjService(); + + #region 获取数据 + + /// + /// 获取页面显示列表数据 + /// + /// 分页参数 + /// 查询参数 + /// + public IEnumerable GetPageList(Pagination pagination, string queryJson) + { + try + { + return ods_wfjckcjsjService.GetPageList(pagination, queryJson); + } + catch (Exception ex) + { + if (ex is ExceptionEx) + { + throw; + } + else + { + throw ExceptionEx.ThrowBusinessException(ex); + } + } + } + + /// + /// 获取ODS_WFJCKCJSJ表实体数据 + /// + /// 主键 + /// + public ODS_WFJCKCJSJEntity GetODS_WFJCKCJSJEntity(string keyValue) + { + try + { + return ods_wfjckcjsjService.GetODS_WFJCKCJSJEntity(keyValue); + } + catch (Exception ex) + { + if (ex is ExceptionEx) + { + throw; + } + else + { + throw ExceptionEx.ThrowBusinessException(ex); + } + } + } + + #endregion + + #region 提交数据 + + /// + /// 删除实体数据 + /// + /// 主键 + public void DeleteEntity(string keyValue) + { + try + { + ods_wfjckcjsjService.DeleteEntity(keyValue); + } + catch (Exception ex) + { + if (ex is ExceptionEx) + { + throw; + } + else + { + throw ExceptionEx.ThrowBusinessException(ex); + } + } + } + + /// + /// 保存实体数据(新增、修改) + /// + /// 主键 + /// 实体 + /// + public void SaveEntity(string keyValue, ODS_WFJCKCJSJEntity entity) + { + try + { + ods_wfjckcjsjService.SaveEntity(keyValue, entity); + } + catch (Exception ex) + { + if (ex is ExceptionEx) + { + throw; + } + else + { + throw ExceptionEx.ThrowBusinessException(ex); + } + } + } + + #endregion + + } +} diff --git a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/Changyang_zhdn/ods_wfjckcjsj/ods_wfjckcjsjIBLL.cs b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/Changyang_zhdn/ods_wfjckcjsj/ods_wfjckcjsjIBLL.cs new file mode 100644 index 000000000..5574cfa41 --- /dev/null +++ b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/Changyang_zhdn/ods_wfjckcjsj/ods_wfjckcjsjIBLL.cs @@ -0,0 +1,48 @@ +using Learun.Util; +using System.Data; +using System.Collections.Generic; + +namespace Learun.Application.TwoDevelopment.Changyang_zhdn +{ + /// + /// 版 本 Learun-ADMS V7.0.6 力软敏捷开发框架 + /// Copyright (c) 2013-2020 力软信息技术(苏州)有限公司 + /// 创 建:超级管理员 + /// 日 期:2022-11-09 14:59 + /// 描 述:文化基础课成绩数据表 + /// + public interface ods_wfjckcjsjIBLL + { + #region 获取数据 + + /// + /// 获取页面显示列表数据 + /// + /// 查询参数 + /// + IEnumerable GetPageList(Pagination pagination, string queryJson); + /// + /// 获取ODS_WFJCKCJSJ表实体数据 + /// + /// 主键 + /// + ODS_WFJCKCJSJEntity GetODS_WFJCKCJSJEntity(string keyValue); + #endregion + + #region 提交数据 + + /// + /// 删除实体数据 + /// + /// 主键 + void DeleteEntity(string keyValue); + /// + /// 保存实体数据(新增、修改) + /// + /// 主键 + /// 实体 + void SaveEntity(string keyValue, ODS_WFJCKCJSJEntity entity); + #endregion + + } +} diff --git a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/Changyang_zhdn/ods_wfjckcjsj/ods_wfjckcjsjService.cs b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/Changyang_zhdn/ods_wfjckcjsj/ods_wfjckcjsjService.cs new file mode 100644 index 000000000..6be8fb2ee --- /dev/null +++ b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/Changyang_zhdn/ods_wfjckcjsj/ods_wfjckcjsjService.cs @@ -0,0 +1,156 @@ +using Dapper; +using Learun.DataBase.Repository; +using Learun.Util; +using System; +using System.Collections.Generic; +using System.Data; +using System.Text; + +namespace Learun.Application.TwoDevelopment.Changyang_zhdn +{ + /// + /// 版 本 Learun-ADMS V7.0.6 力软敏捷开发框架 + /// Copyright (c) 2013-2020 力软信息技术(苏州)有限公司 + /// 创 建:超级管理员 + /// 日 期:2022-11-09 14:59 + /// 描 述:文化基础课成绩数据表 + /// + public class ods_wfjckcjsjService : RepositoryFactory + { + #region 获取数据 + + /// + /// 获取页面显示列表数据 + /// + /// 查询参数 + /// 查询参数 + /// + public IEnumerable GetPageList(Pagination pagination, string queryJson) + { + try + { + var strSql = new StringBuilder(); + strSql.Append("SELECT "); + strSql.Append(@" + t.GZZYQKSJID, + t.XXJGDM, + t.XXJGMC, + t.XN, + t.XQ, + t.NJ, + t.BJ, + t.ZYMC, + t.KCMC, + t.KCFL, + t.RKJS, + t.KCCJ, + t.SJCJSJ + "); + strSql.Append(" FROM ODS_WFJCKCJSJ t "); + strSql.Append(" WHERE 1=1 "); + var queryParam = queryJson.ToJObject(); + // 虚拟参数 + var dp = new DynamicParameters(new { }); + return this.BaseRepository("changyang").FindList(strSql.ToString(),dp, pagination); + } + catch (Exception ex) + { + if (ex is ExceptionEx) + { + throw; + } + else + { + throw ExceptionEx.ThrowServiceException(ex); + } + } + } + + /// + /// 获取ODS_WFJCKCJSJ表实体数据 + /// + /// 主键 + /// + public ODS_WFJCKCJSJEntity GetODS_WFJCKCJSJEntity(string keyValue) + { + try + { + return this.BaseRepository("changyang").FindEntity(keyValue); + } + catch (Exception ex) + { + if (ex is ExceptionEx) + { + throw; + } + else + { + throw ExceptionEx.ThrowServiceException(ex); + } + } + } + + #endregion + + #region 提交数据 + + /// + /// 删除实体数据 + /// + /// 主键 + public void DeleteEntity(string keyValue) + { + try + { + this.BaseRepository("changyang").Delete(t=>t.GZZYQKSJID == keyValue); + } + catch (Exception ex) + { + if (ex is ExceptionEx) + { + throw; + } + else + { + throw ExceptionEx.ThrowServiceException(ex); + } + } + } + + /// + /// 保存实体数据(新增、修改) + /// + /// 主键 + /// 实体 + public void SaveEntity(string keyValue, ODS_WFJCKCJSJEntity entity) + { + try + { + if (!string.IsNullOrEmpty(keyValue)) + { + entity.Modify(keyValue); + this.BaseRepository("changyang").Update(entity); + } + else + { + entity.Create(); + this.BaseRepository("changyang").Insert(entity); + } + } + catch (Exception ex) + { + if (ex is ExceptionEx) + { + throw; + } + else + { + throw ExceptionEx.ThrowServiceException(ex); + } + } + } + + #endregion + + } +} diff --git a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/Learun.Application.TwoDevelopment.csproj b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/Learun.Application.TwoDevelopment.csproj index f0ce790ea..3c5a38a7c 100644 --- a/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/Learun.Application.TwoDevelopment.csproj +++ b/Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/Learun.Application.TwoDevelopment.csproj @@ -1971,6 +1971,10 @@ + + + +