Explorar el Código

增加多语言管理;调整界面风格的样式;

大厂分支
dyy hace 4 años
padre
commit
91077d1da4
Se han modificado 48 ficheros con 1829 adiciones y 2368 borrados
  1. +106
    -229
      Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/LR_LGManager/Controllers/LGMapController.cs
  2. +51
    -34
      Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/LR_LGManager/Controllers/LGTypeController.cs
  3. +3
    -6
      Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/LR_LGManager/Views/LGMap/AddForm.cshtml
  4. +42
    -35
      Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/LR_LGManager/Views/LGMap/AddForm.js
  5. +2
    -5
      Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/LR_LGManager/Views/LGMap/DataItemLG.cshtml
  6. +111
    -113
      Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/LR_LGManager/Views/LGMap/DataItemLG.js
  7. +1
    -2
      Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/LR_LGManager/Views/LGMap/Form.cshtml
  8. +85
    -70
      Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/LR_LGManager/Views/LGMap/Form.js
  9. +7
    -10
      Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/LR_LGManager/Views/LGMap/Index.cshtml
  10. +89
    -94
      Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/LR_LGManager/Views/LGMap/Index.js
  11. +6
    -7
      Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/LR_LGManager/Views/LGMap/SystemModuleLG.cshtml
  12. +194
    -200
      Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/LR_LGManager/Views/LGMap/SystemModuleLG.js
  13. +7
    -11
      Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/LR_LGManager/Views/LGType/Form.cshtml
  14. +37
    -25
      Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/LR_LGManager/Views/LGType/Form.js
  15. +10
    -9
      Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/LR_LGManager/Views/LGType/Index.cshtml
  16. +69
    -56
      Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/LR_LGManager/Views/LGType/Index.js
  17. +9
    -0
      Learun.Framework.Ultimate V7/Learun.Application.Web/Controllers/UserCenterController.cs
  18. +8
    -0
      Learun.Framework.Ultimate V7/Learun.Application.Web/Learun.Application.Web.csproj
  19. +7
    -1
      Learun.Framework.Ultimate V7/Learun.Application.Web/Views/Home/AdminAccordion.cshtml
  20. +195
    -135
      Learun.Framework.Ultimate V7/Learun.Application.Web/Views/Home/AdminAccordion/Index.css
  21. +5
    -2
      Learun.Framework.Ultimate V7/Learun.Application.Web/Views/Home/AdminDefault.cshtml
  22. +16
    -1
      Learun.Framework.Ultimate V7/Learun.Application.Web/Views/Home/AdminDefault/index.css
  23. +4
    -0
      Learun.Framework.Ultimate V7/Learun.Application.Web/Views/Home/AdminDefaultForDC.cshtml
  24. +7
    -4
      Learun.Framework.Ultimate V7/Learun.Application.Web/Views/Home/AdminNavigation.cshtml
  25. +4
    -0
      Learun.Framework.Ultimate V7/Learun.Application.Web/Views/Home/AdminTop.cshtml
  26. +186
    -125
      Learun.Framework.Ultimate V7/Learun.Application.Web/Views/Home/AdminTop/Index.css
  27. +4
    -2
      Learun.Framework.Ultimate V7/Learun.Application.Web/Views/Home/AdminWindos.cshtml
  28. +218
    -155
      Learun.Framework.Ultimate V7/Learun.Application.Web/Views/Home/AdminWindos/Index.css
  29. +1
    -1
      Learun.Framework.Ultimate V7/Learun.Application.Web/Views/LR_Content/plugin/scroll/scroll.js
  30. +139
    -0
      Learun.Framework.Ultimate V7/Learun.Application.Web/Views/LR_Content/script/lr-language - 副本.js
  31. +119
    -117
      Learun.Framework.Ultimate V7/Learun.Application.Web/Views/LR_Content/script/lr-language.js
  32. +2
    -2
      Learun.Framework.Ultimate V7/Learun.Application.Web/Views/Login/Default/Index.js
  33. +10
    -0
      Learun.Framework.Ultimate V7/Learun.Application.Web/Views/UserCenter/Index.cshtml
  34. +13
    -0
      Learun.Framework.Ultimate V7/Learun.Application.Web/Views/UserCenter/LanguageForm.cshtml
  35. +19
    -0
      Learun.Framework.Ultimate V7/Learun.Application.Web/Views/UserCenter/LanguageForm.css
  36. +35
    -0
      Learun.Framework.Ultimate V7/Learun.Application.Web/Views/UserCenter/LanguageForm.js
  37. +2
    -2
      Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.Mapping/LR_LGManager/LR_Lg_MapMap.cs
  38. +2
    -2
      Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.Mapping/LR_LGManager/LR_Lg_TypeMap.cs
  39. +4
    -0
      Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.Mapping/Learun.Application.Mapping.csproj
  40. +0
    -143
      Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/LR_LGManager/LGMap/LGMapBLL.cs
  41. +0
    -50
      Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/LR_LGManager/LGMap/LGMapIBLL.cs
  42. +0
    -216
      Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/LR_LGManager/LGMap/LGMapService.cs
  43. +0
    -60
      Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/LR_LGManager/LGMap/LR_Lg_MapEntity.cs
  44. +0
    -144
      Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/LR_LGManager/LGType/LGTypeBLL.cs
  45. +0
    -50
      Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/LR_LGManager/LGType/LGTypeIBLL.cs
  46. +0
    -182
      Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/LR_LGManager/LGType/LGTypeService.cs
  47. +0
    -60
      Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/LR_LGManager/LGType/LR_Lg_TypeEntity.cs
  48. +0
    -8
      Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/Learun.Application.TwoDevelopment.csproj

+ 106
- 229
Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/LR_LGManager/Controllers/LGMapController.cs Ver fichero

@@ -1,26 +1,21 @@
using Learun.Application.TwoDevelopment.LR_LGManager;
using Learun.Application.Language;
using Learun.Util;
using Newtonsoft.Json.Linq;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Web.Mvc;

namespace Learun.Application.Web.Areas.LR_LGManager.Controllers
{
/// <summary>
/// 版 本 Learun-ADMS-Ultimate V7.0.0 数字化智慧校园
/// Copyright (c) 2013-2018 北京泉江科技有限公司
/// 版 本 Learun-ADMS V7.0.3 力软敏捷开发框架
/// Copyright (c) 2013-2018 上海力软信息技术有限公司
/// 创 建:超级管理员
/// 日 期:2018-09-29 14:51
/// 描 述:语言映
/// 日 期:2018-04-10 15:00
/// 描 述:语言映
/// </summary>
public class LGMapController : MvcControllerBase
{
private LGMapIBLL lGMapIBLL = new LGMapBLL();

#region 视图功能
#region 视图功能

/// <summary>
/// 主页面
@@ -40,63 +35,68 @@ namespace Learun.Application.Web.Areas.LR_LGManager.Controllers
{
return View();
}

public ActionResult AddForm(string keyValue)
/// <summary>
/// 数据字典语言
/// <summary>
/// <returns></returns>
[HttpGet]
public ActionResult DataItemLG()
{
return View();
}

/// <summary>
/// 字典翻译
/// </summary>
/// <returns>ActionResult.</returns>
public ActionResult DataItemLG()
/// 系统功能语言
/// <summary>
/// <returns></returns>
[HttpGet]
public ActionResult SystemModuleLG()
{
return View();
}

/// <summary>
/// Systems the module lg. 系统模块翻译
/// </summary>
/// <returns>ActionResult.</returns>
public ActionResult SystemModuleLG()
/// 新增
/// <summary>
/// <returns></returns>
[HttpGet]
public ActionResult AddForm()
{
return View();
}
#endregion

#region 获取数据

#region 获取数据
/// <summary>
/// 获取页面显示列表数据
/// 获取列表数据
/// <param name="TypeCode">编码</param>
/// <summary>
/// <returns></returns>
public ActionResult GetListByTypeCode(string TypeCode)
{
var data = lGMapIBLL.GetListByTypeCode(TypeCode);
return Success(data);
}
/// <summary>
/// 获取列表数据
/// <summary>
/// <returns></returns>
[HttpGet]
[AjaxOnly]
public ActionResult GetList(string queryJson)
{
var data = lGMapIBLL.GetList(queryJson);
return Success(data);
}
/// <summary>
/// 获取列表分页数据
/// <param name="pagination">分页参数</param>
/// <summary>
/// <param name="queryJson">查询参数</param>
/// <returns></returns>
[HttpGet]
[AjaxOnly]
public ActionResult GetPageList(string pagination, string queryJson, string typeList)
{
//节后再说吧
//这里很复杂的写法呢
Pagination paginationobj = pagination.ToObject<Pagination>();
var data = lGMapIBLL.GetPageList(paginationobj, queryJson, typeList);
//var lrltMapEntities = data as LR_Lg_MapEntity[] ?? data.ToArray();
//var datagroup = lrltMapEntities.GroupBy(p => p.F_TypeCode);
//List<object> facade= new List<object>();

//foreach (IGrouping<string, LR_Lg_MapEntity> lgMapEntities in datagroup)
//{
// var newlist= typeList.Split(',');
// Dictionary<string,string> newobject = new Dictionary<string, string>();
// foreach (var s in newlist)
// {
// newobject.Add(s, lgMapEntities.First(p => p.F_TypeCode==s).F_Name);
// }
// newobject.Add("f_code", lgMapEntities.Key);
// newobject.Add("rownum", lgMapEntities.Key);


//}
var jsonData = new
{
rows = data,
@@ -105,225 +105,102 @@ namespace Learun.Application.Web.Areas.LR_LGManager.Controllers
records = paginationobj.records
};
return Success(jsonData);
// return null;
}
/// <summary>
/// 获取表单数据
/// <param name="keyValue">主键</param>
/// <summary>
/// <returns></returns>
[HttpGet]
[AjaxOnly]
public ActionResult GetFormData(string keyValue)
{
var LR_Lg_MapData = lGMapIBLL.GetLR_Lg_MapEntity(keyValue);
var jsonData = new
{
LR_Lg_Map = LR_Lg_MapData,
};
return Success(jsonData);
var data = lGMapIBLL.GetEntity(keyValue);
return Success(data);
}
#endregion

#region 提交数据

/// <summary>
/// 删除实体数据
/// <param name="keyValue">主键</param>
/// 根据名称获取列表
/// <param name="keyValue">F_Name</param>
/// <summary>
/// <returns></returns>
[HttpPost]
[HttpGet]
[AjaxOnly]
public ActionResult DeleteForm(string keyValue)
public ActionResult GetListByName(string keyValue)
{
lGMapIBLL.DeleteEntity(keyValue);
return Success("删除成功!");
var data = lGMapIBLL.GetListByName(keyValue);
return Success(data);
}
/// <summary>
/// 保存实体数据(新增、修改)
/// <param name="keyValue">主键</param>
/// 根据名称与类型获取列表
/// <param name="keyValue">F_Name</param>
/// <param name="typeCode">typeCode</param>
/// <summary>
/// <returns></returns>


#endregion

#region 扩展

[HttpGet]
[AjaxOnly]
public ActionResult GetListByNameAndType(string keyValue, string typeCode)
{
var qu = new
{
F_TypeCode = typeCode,
F_Name = keyValue
};

var tcList = lGMapIBLL.GetList(qu.ToJson());
return Success(tcList);
var data = lGMapIBLL.GetListByNameAndType(keyValue, typeCode);
return Success(data);
}

public ActionResult GetLanguageByCode(string typeCode, bool isMain, string ver)
{
var qu = new
/// <summary>
/// 根据语言类型编码获取语言包
/// </summary>
/// <param name="typeCode">语言类型编码</param>
/// <param name="ver">版本号</param>
/// <returns></returns>
[HttpGet]
[AjaxOnly]
public ActionResult GetLanguageByCode(string typeCode,string ver,bool isMain) {
var data = lGMapIBLL.GetMap(typeCode, isMain);
string md5 = Md5Helper.Encrypt(data.ToJson(), 32);
if (md5 == ver)
{
F_TypeCode = typeCode,
F_isMain = isMain
};

var tcList = lGMapIBLL.GetList(qu.ToJson());

Dictionary<string, string> keyValuePairs = new Dictionary<string, string>();
foreach (var item in tcList)
return Success("no update");
}
else
{
try
{
if (isMain)
{
keyValuePairs.Add(item.F_Name, item.F_Code);

}
else
{
keyValuePairs.Add(item.F_Code, item.F_Name);
}
}
catch (Exception)
var jsondata = new
{

//throw;
}


data = data,
ver = md5
};
return Success(jsondata);
}
var resData = new { data = keyValuePairs };
return Success(resData);
}

public ActionResult GetList(string queryJson)
{
IEnumerable<LgMapEntity> modellist = lGMapIBLL.GetList(queryJson);
return Success(modellist);
}
#endregion

#region 提交数据

/// <summary>
/// Saves the muti lg form.
/// </summary>
/// <param name="nameList">The name list.</param>
/// <param name="newNameList">The new name list.</param>
/// <param name="code">The code.</param>
/// <returns>ActionResult.</returns>
/// 删除实体数据
/// <param name="keyValue">主键</param>
/// <summary>
/// <returns></returns>
[HttpPost]
[ValidateAntiForgeryToken]
[AjaxOnly]
public ActionResult SaveForm(string nameList, string newNameList, string code)
{
try
{
if (string.IsNullOrEmpty(code))
{
string mycode = Guid.NewGuid().ToString();
var mydict = newNameList.ToObject<Dictionary<string, string>>();
foreach (var kvalue in mydict)
{

LgMapEntity lrltMap = new LgMapEntity();
lrltMap.F_TypeCode = kvalue.Key;
lrltMap.F_Code = mycode;
lrltMap.F_Name = kvalue.Value;
lGMapIBLL.SaveEntity("", lrltMap);
}
}
else
{
var list = lGMapIBLL.GetList(new { F_Code = code }.ToJson());
var mydict = newNameList.ToObject<Dictionary<string, string>>();
if (mydict.Count != list.Count())
{
foreach (var mydictKey in mydict.Keys)
{
if (list.Count(p => p.F_TypeCode.ToLower() == mydictKey.ToLower()) == 0)
{
LgMapEntity lge = new LgMapEntity();
lge.F_TypeCode = mydictKey;
lge.F_Code = code;
lge.F_Name = mydict[mydictKey];
lGMapIBLL.SaveEntity("", lge);

}
}
}
foreach (LgMapEntity mapEntity in list)
{
var objNewName = newNameList.ToObject<JObject>();

if (objNewName.ContainsKey(mapEntity.F_TypeCode))
{
mapEntity.F_Name = objNewName[mapEntity.F_TypeCode].ToString();
lGMapIBLL.SaveEntity(mapEntity.F_Id, mapEntity);
}
}
}
}
catch (Exception e)
{
return Fail("保存异常!");

}
return Success("保存成功");
}


public ActionResult InitLG()
public ActionResult DeleteForm(string keyValue)
{
var allfiles = System.IO.Directory.GetFiles("D:\\dataitem\\", "*.txt");
foreach (string file in allfiles)
{
string jsonData = System.IO.File.ReadAllText(file, Encoding.Default);

var mydata = jsonData.ToObject<ReqParameter<FacadeNameListForm>>();

foreach (var d in mydata.data.rows)
{
try
{
lGMapIBLL.SaveEntity("", new LgMapEntity()
{
F_Code = d.f_code,
F_Id = d.f_id,
F_TypeCode = d.f_typecode,
F_Name = d.f_name
});
}
catch (Exception e)
{


}

}

}

return Success("成了啊");
lGMapIBLL.DeleteEntity(keyValue);
return Success("删除成功!");
}

public class FacadeNameListForm
/// <summary>
/// 保存实体数据(新增、修改)
/// <param name="nameList">原列表</param>
/// <param name="newNameList">新列表</param>
/// <param name="code">F_Code</param>
/// <summary>
/// <returns></returns>
[HttpPost]
[ValidateAntiForgeryToken]
[AjaxOnly]
public ActionResult SaveForm(string nameList, string newNameList, string code)
{
public List<MyRow> rows { get; set; }
lGMapIBLL.SaveEntity(nameList, newNameList, code);
return Success("保存成功!");
}
#endregion

public class MyRow
{
public string f_code { get; set; }
public string f_id { get; set; }
public string f_name { get; set; }
public string f_typecode { get; set; }

}
}

#endregion
}


}

+ 51
- 34
Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/LR_LGManager/Controllers/LGTypeController.cs Ver fichero

@@ -1,23 +1,21 @@
using Learun.Util;
using System.Data;
using Learun.Application.TwoDevelopment.LR_LGManager;
using Learun.Application.Language;
using Learun.Util;
using System.Web.Mvc;
using System.Collections.Generic;

namespace Learun.Application.Web.Areas.LR_LGManager.Controllers
{
/// <summary>
/// 版 本 Learun-ADMS-Ultimate V7.0.0 数字化智慧校园
/// Copyright (c) 2013-2018 北京泉江科技有限公司
/// 版 本 Learun-ADMS V7.0.3 力软敏捷开发框架
/// Copyright (c) 2013-2018 上海力软信息技术有限公司
/// 创 建:超级管理员
/// 日 期:2018-09-29 15:01
/// 描 述:多语言映射
/// 日 期:2018-04-10 15:08
/// 描 述:语言类型
/// </summary>
public class LGTypeController : MvcControllerBase
{
private LGTypeIBLL lGTypeIBLL = new LGTypeBLL();

#region 视图功能
#region 视图功能

/// <summary>
/// 主页面
@@ -26,7 +24,7 @@ namespace Learun.Application.Web.Areas.LR_LGManager.Controllers
[HttpGet]
public ActionResult Index()
{
return View();
return View();
}
/// <summary>
/// 表单页
@@ -35,16 +33,27 @@ namespace Learun.Application.Web.Areas.LR_LGManager.Controllers
[HttpGet]
public ActionResult Form()
{
return View();
return View();
}
#endregion

#region 获取数据
#region 获取数据

/// <summary>
/// 获取页面显示列表数据
/// 获取列表数据
/// <summary>
/// <returns></returns>
[HttpGet]
[AjaxOnly]
public ActionResult GetList(string queryJson)
{
var data = lGTypeIBLL.GetList(queryJson);
return Success(data);
}
/// <summary>
/// 获取列表分页数据
/// <param name="pagination">分页参数</param>
/// <summary>
/// <param name="queryJson">查询参数</param>
/// <returns></returns>
[HttpGet]
[AjaxOnly]
@@ -62,34 +71,32 @@ namespace Learun.Application.Web.Areas.LR_LGManager.Controllers
return Success(jsonData);
}
/// <summary>
/// 获取语言类
/// </summary>
/// <param name="queryJson">The query josn.</param>
/// <returns>ActionResult.</returns>
/// 获取表单数据
/// <param name="keyValue">主键</param>
/// <summary>
/// <returns></returns>
[HttpGet]
[AjaxOnly]
public ActionResult GetList(string queryJson)
public ActionResult GetFormData(string keyValue)
{
var modellist= lGTypeIBLL.GetList(queryJson);
return Success(modellist);
var data = lGTypeIBLL.GetEntity(keyValue);
return Success(data);
}
/// <summary>
/// 获取表单数据
/// 获取实体数据
/// <param name="keyValue">主键</param>
/// <summary>
/// <returns></returns>
[HttpGet]
[AjaxOnly]
public ActionResult GetFormData(string keyValue)
public ActionResult GetEntityByCode(string keyValue)
{
var LR_Lg_TypeData = lGTypeIBLL.GetLR_Lg_TypeEntity( keyValue );
var jsonData = new {
LR_Lg_Type = LR_Lg_TypeData,
};
return Success(jsonData);
var data = lGTypeIBLL.GetEntityByCode(keyValue);
return Success(data);
}
#endregion

#region 提交数据
#region 提交数据

/// <summary>
/// 删除实体数据
@@ -111,13 +118,23 @@ namespace Learun.Application.Web.Areas.LR_LGManager.Controllers
[HttpPost]
[ValidateAntiForgeryToken]
[AjaxOnly]
public ActionResult SaveForm(string keyValue, string strEntity)
public ActionResult SaveForm(string keyValue, LGTypeEntity entity)
{
lGTypeIBLL.SaveEntity(keyValue, entity);
return Success("保存成功!");
}
/// <summary>
/// 设为主语言
/// <param name="keyValue">主键</param>
/// <summary>
/// <returns></returns>
[HttpPost]
[AjaxOnly]
public ActionResult SetMainLG(string keyValue)
{
LgTypeEntity entity = strEntity.ToObject<LgTypeEntity>();
lGTypeIBLL.SaveEntity(keyValue,entity);
lGTypeIBLL.SetMainLG(keyValue);
return Success("保存成功!");
}
#endregion

}
}
}

+ 3
- 6
Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/LR_LGManager/Views/LGMap/AddForm.cshtml Ver fichero

@@ -1,12 +1,9 @@

@{
ViewBag.Title = "AddForm";
@{
ViewBag.Title = "语言映照";
Layout = "~/Views/Shared/_Form.cshtml";
}

<div class="lr-form-wrap" id="form">
<div class="col-xs-12 lr-form-item">
</div>
</div>

@Html.AppendJsFile("/Areas/LR_LGManager/Views/LGMap/AddForm.js");
@Html.AppendJsFile("/Areas/LR_LGManager/Views/LGMap/AddForm.js")

+ 42
- 35
Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/LR_LGManager/Views/LGMap/AddForm.js Ver fichero

@@ -1,53 +1,60 @@
var acceptClick;
var keyValue = request("keyValue");
/* * 版 本 Learun-ADMS V7.0.3 力软敏捷开发框架(http://www.learun.cn)
* Copyright (c) 2013-2018 上海力软信息技术有限公司
* 创建人:超级管理员
* 日 期:2018-04-10 15:00
* 描 述:语言映照
*/
var acceptClick;
var keyValue = request('keyValue');
var bootstrap = function ($, learun) {
"use strict";
var selectedRow = learun.frameTab.currentIframe().selectedRow;
var page = {
init: function () {
page.bind();
},
bind: function () {
var e = [];
learun.httpAsyncGet(top.$.rootUrl + "/LR_LGManager/LGType/GetList",
function (res) {
if (res.data) {
for (var g = 0; g < res.data.length; g++) {
var f = '<div class="col-xs-12 lr-form-item"> <div class="lr-form-item-title">' +
res.data[g].F_Name +
'<font face="宋体">*</font></div> <input id="' +
res.data[g].F_Code +
'" type="text" class="form-control" isvalid="yes" checkexpession="NotNull" /> </div>';
e.push(f);
}
$("#form .lr-form-item:last").parent().append(e);
$("#form .lr-form-item:first").remove();
var data = [];
//获取语言类型
learun.httpAsyncGet(top.$.rootUrl + '/LR_LGManager/LGType/GetList', function (res) {
if (res.data) {
for (var i = 0; i < res.data.length; i++) {
var html = '<div class="col-xs-12 lr-form-item"> <div class="lr-form-item-title">' + res.data[i].F_Name + '<font face="宋体">*</font></div> <input id="' + res.data[i].F_Code + '" type="text" class="form-control" isvalid="yes" checkexpession="NotNull" /> </div>';
data.push(html);
}
if (!!selectedRow) {
$("#form").lrSetFormData(d);
}
$("#" + keyValue).attr("disabled", "disabled");
});
//根据类型添加表单
$('#form .lr-form-item:last').parent().append(data);
$('#form .lr-form-item:first').remove();
}
if (!!selectedRow) {
$('#form').lrSetFormData(selectedRow);
}

$('#' + keyValue).attr('disabled', 'disabled');
});
}
};
// 保存数据
acceptClick = function (callBack) {
if (!$("#form").lrValidform()) {
if (!$('#form').lrValidform()) {
return false;
}
var g = "";
var f = "";
var nameList = "";
var code = "";
if (!!selectedRow) {
f = selectedRow.F_Code;
//原始值
code = selectedRow["F_Code"];
delete selectedRow.F_Code;
g = JSON.stringify(d);
nameList = JSON.stringify(selectedRow);
}
var h = JSON.stringify($("#form").lrGetFormData());
$.lrSaveForm(top.$.rootUrl + "/LR_LGManager/LGMap/SaveForm?nameList=" + g + "&newNameList=" + h + "&code=" + f,
{},
function (i) {
if (!!callBack) {
callBack();
}
});
//表单值
var newNameList = JSON.stringify($('#form').lrGetFormData());
$.lrSaveForm(top.$.rootUrl + '/LR_LGManager/LGMap/SaveForm?nameList=' + nameList + "&newNameList=" + newNameList + "&code=" + code, {}, function (res) {
// 保存成功后才回调
if (!!callBack) {
callBack();
}
});
};
page.init();
};
}

+ 2
- 5
Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/LR_LGManager/Views/LGMap/DataItemLG.cshtml Ver fichero

@@ -1,10 +1,7 @@

@{
@{
ViewBag.Title = "数据字典";
Layout = "~/Views/Shared/_Index.cshtml";
}


<div class="lr-layout lr-layout-left-center" id="lr_layout">
<div class="lr-layout-left">
<div class="lr-layout-wrap">
@@ -33,5 +30,5 @@
</div>
</div>
</div>

@Html.AppendJsFile("/Areas/LR_LGManager/Views/LGMap/DataItemLG.js")


+ 111
- 113
Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/LR_LGManager/Views/LGMap/DataItemLG.js Ver fichero

@@ -1,139 +1,137 @@
var refreshGirdData;
/*
* 版 本 Learun-ADMS V7.0.3 力软敏捷开发框架(http://www.learun.cn)
* Copyright (c) 2013-2018 上海力软信息技术有限公司
* 创建人:力软-前端开发组
* 日 期:2017.03.22
* 描 述:功能模块
*/
var refreshGirdData; // 更新数据
var selectedRow;
var formHeight;
var keyValue;
var bootstrap = function ($, learun) {
var classify_itemCode = "";
"use strict";
var classify_itemCode = '';
var page = {
init: function () {
page.inittree();
page.initGrid();
page.bind();
}, bind: function () {
$("#btn_Search").on("click", function () {
var keyword = $("#txt_Keyword").val();
page.search({
keyword: keyword
});
},
bind: function () {
// 查询
$('#btn_Search').on('click', function () {
var keyword = $('#txt_Keyword').val();
page.search({ keyword: keyword });
});
$("#lr_refresh").on("click", function () {
// 刷新
$('#lr_refresh').on('click', function () {
location.reload();
});
$("#lr_edit").on("click",
function () {
selectedRow = $("#gridtable").jfGridGet("rowdata");
if (learun.checkrow(selectedRow)) {
learun.layerForm({
id: "form",
title: "编辑",
url: top.$.rootUrl + "/LR_LGManager/LGMap/AddForm?keyValue=" + keyValue,
width: 400,
height: formHeight,
callBack: function (e) {
return top[e].acceptClick(page.search);
}
});
}
});
}, inittree: function () {


$("#lr_left_tree").lrtree({
url: top.$.rootUrl + "/LR_SystemModule/DataItem/GetClassifyTree",
nodeClick: function (e) {
classify_itemCode = e.value;
$("#titleinfo").text(e.text + "(" + classify_itemCode + ")");
// 编辑
$('#lr_edit').on('click', function () {
selectedRow = $('#gridtable').jfGridGet('rowdata');
if (learun.checkrow(selectedRow)) {
learun.layerForm({
id: 'form',
title: '编辑',
url: top.$.rootUrl + '/LR_LGManager/LGMap/AddForm?keyValue=' + keyValue,
width: 400,
height: formHeight,
callBack: function (id) {
return top[id].acceptClick(page.search);
}
});
}
});
},
inittree: function () {
$('#lr_left_tree').lrtree({
url: top.$.rootUrl + '/LR_SystemModule/DataItem/GetClassifyTree',
nodeClick: function (item) {
classify_itemCode = item.value;
$('#titleinfo').text(item.text + '(' + classify_itemCode + ')');
page.search();
}
});




}, initGrid: function () {
var e = [];
learun.httpAsyncGet(top.$.rootUrl + "/LR_LGManager/LGType/GetList",
function (h) {
if (h.data) {
e.push({
label: "项目值",
name: h.data[0].F_Code,
width: 200,
align: "left"
});
keyValue = h.data[0].F_Code;
for (var f = 1; f < h.data.length; f++) {
var g = {
label: h.data[f].F_Name,
name: h.data[f].F_Code,
width: 200,
align: "left"
};
e.push(g);
}
$("#gridtable").jfGrid({
headData: e,
dblclick: function (i) {
if (learun.checkrow(i)) {
selectedRow = i;
i.F_Code = keyValue;
learun.layerForm({
id: "form",
title: "编辑",
url: top.$.rootUrl + "/LR_LGManager/LGMap/AddForm?keyValue=" + keyValue,
width: 400,
height: formHeight,
callBack: function (j) {
return top[j].acceptClick(page.search);
}
});
}
},
initGrid: function () {
var data = [];
//获取语言类型
learun.httpAsyncGet(top.$.rootUrl + '/LR_LGManager/LGType/GetList', function (res) {
if (res.data) {
data.push({ label: "项目值", name: res.data[0].F_Code, width: 200, align: "left" });
keyValue = res.data[0].F_Code;//主语言
for (var i = 1; i < res.data.length; i++) {
var obj = { label: res.data[i].F_Name, name: res.data[i].F_Code, width: 200, align: "left" };
data.push(obj);
}
$('#gridtable').jfGrid({
headData: data,
dblclick: function (row) {
if (learun.checkrow(row)) {
selectedRow = row;
learun.layerForm({
id: 'form',
title: '编辑',
url: top.$.rootUrl + '/LR_LGManager/LGMap/AddForm?keyValue=' + keyValue,
width: 400,
height: formHeight,
callBack: function (id) {
return top[id].acceptClick(page.search);
}
});
}
});
page.search();
if (h.data.length <= 3) {
formHeight = 230;
} else {
formHeight = 230 + (h.data.length - 3) * 40;
}
});
page.search();
if (res.data.length <= 3) {
formHeight = 230;
}
});
}, search: function (f) {
var g = [];
var e = {};
learun.httpAsyncGet(top.$.rootUrl + "/LR_SystemModule/DataItem/GetDetailList?itemCode=" + classify_itemCode,
function (h) {
learun.httpAsyncGet(top.$.rootUrl + "/LR_LGManager/LGMap/GetList",
function (n) {
if (h.data && n.data) {
for (var k = 0; k < h.data.length; k++) {
var o = n.data.find(function (i) {
return i.F_Name == h.data[k].F_ItemName;
});
if (typeof o != "undefined") {
var m = n.data.filter(function (i) {
return i.F_Code == o.F_Code;
});
for (var l = 0; l < m.length; l++) {
e[m[l].F_TypeCode] = m[l].F_Name;
e.F_Code = m[l].F_Code;
}
} else {
e[keyValue] = h.data[k].F_ItemName;
e.F_Code = "";
}
g.push(e);
e = {}
else {
formHeight = 230 + (res.data.length - 3) * 40;
}
}
});
},
search: function (param) {
//获取表数据并赋值
var rowData = [];
var obj = {};
learun.httpAsyncGet(top.$.rootUrl + '/LR_SystemModule/DataItem/GetDetailList?itemCode=' + classify_itemCode, function (res) {
learun.httpAsyncGet(top.$.rootUrl + '/LR_LGManager/LGMap/GetList', function (mapRes) {
if (res.data && mapRes.data) {
for (var i = 0; i < res.data.length; i++) {
var val = mapRes.data.find(function (element) {
return element.F_Name == res.data[i].F_ItemName;
});
if (typeof val != 'undefined') {
var list = mapRes.data.filter(function (element) {
return element.F_Code == val.F_Code;
});
for (var j = 0; j < list.length; j++) {
obj[list[j].F_TypeCode] = list[j].F_Name;
obj.F_Code = list[j].F_Code;//每一行数据的F_Code
}
$("#gridtable").jfGridSet("refreshdata", g);
g = [];
}
});
else {
obj[keyValue] = res.data[i].F_ItemName;
obj.F_Code = "";
}
rowData.push(obj);
obj = {};
}
$('#gridtable').jfGridSet('refreshdata', rowData);
rowData = [];
}
});
});
}
};
// 保存数据后回调刷新
refreshGirdData = function () {
page.search();
};
}

page.init();
};
}

+ 1
- 2
Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/LR_LGManager/Views/LGMap/Form.cshtml Ver fichero

@@ -1,10 +1,9 @@
@{
ViewBag.Title = "语言映";
ViewBag.Title = "语言映";
Layout = "~/Views/Shared/_Form.cshtml";
}
<div class="lr-form-wrap" id="form">
<div class="col-xs-12 lr-form-item">
</div>
</div>

@Html.AppendJsFile("/Areas/LR_LGManager/Views/LGMap/Form.js")

+ 85
- 70
Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/LR_LGManager/Views/LGMap/Form.js Ver fichero

@@ -1,84 +1,99 @@
var acceptClick;
/* * 版 本 Learun-ADMS V7.0.3 力软敏捷开发框架(http://www.learun.cn)
* Copyright (c) 2013-2018 上海力软信息技术有限公司
* 创建人:超级管理员
* 日 期:2018-04-10 15:00
* 描 述:语言映照
*/
var acceptClick;
var mainType;
var keyValue = request("keyValue");
var bootstrap = function (a, b) {
var d = b.frameTab.currentIframe().selectedRow;
var c = {
var keyValue = request('keyValue');
var bootstrap = function ($, learun) {
"use strict";
var selectedRow = learun.frameTab.currentIframe().selectedRow;
var page = {
init: function () {
c.bind()
page.bind();
},
bind: function () {
var e = [];
b.httpAsyncGet(top.$.rootUrl + "/LR_LGManager/LGType/GetList",
function (h) {
if (h.data) {
for (var g = 0; g < h.data.length; g++) {
var f = '<div class="col-xs-12 lr-form-item"> <div class="lr-form-item-title">' + h.data[g].F_Name + '<font face="宋体">*</font></div> <input id="' + h.data[g].F_Code.toLowerCase() + '" type="text" class="form-control" isvalid="yes" checkexpession="NotNull" /> </div>';
e.push(f)
}
mainType = h.data[0].F_Code.toLowerCase();
a("#form .lr-form-item:last").parent().append(e);
a("#form .lr-form-item:first").remove()
}
if (!!d) {
a("#form").lrSetFormData(d)
var data = [];
//获取语言类型
learun.httpAsyncGet(top.$.rootUrl + '/LR_LGManager/LGType/GetList', function (res) {
if (res.data) {
for (var i = 0; i < res.data.length; i++) {
var html = '<div class="col-xs-12 lr-form-item"> <div class="lr-form-item-title">' + res.data[i].F_Name + '<font face="宋体">*</font></div> <input id="' + res.data[i].F_Code.toLowerCase() + '" type="text" class="form-control" isvalid="yes" checkexpession="NotNull" /> </div>';
data.push(html);
}
})
mainType = res.data[0].F_Code.toLowerCase();
//根据类型添加表单
$('#form .lr-form-item:last').parent().append(data);
$('#form .lr-form-item:first').remove();
}
if (!!selectedRow) {
$('#form').lrSetFormData(selectedRow);
}
});
}
};
acceptClick = function (e) {
if (!a("#form").lrValidform()) {
return false
// 保存数据
acceptClick = function (callBack) {
if (!$('#form').lrValidform()) {
return false;
}
var h = "";
var f = "";
if (!!d) {
f = d.f_code;
delete d.f_code;
h = JSON.stringify(d)
var nameList = "";
var code = "";
if (!!selectedRow) {
//原始值
code = selectedRow["f_code"];
delete selectedRow.f_code;
nameList = JSON.stringify(selectedRow);
}
var g = a("#form").lrGetFormData();
var i = JSON.stringify(g);
//表单值
var formData = $('#form').lrGetFormData();
var newNameList = JSON.stringify(formData);
if (!keyValue) {
b.httpAsyncGet(top.$.rootUrl + "/LR_LGManager/LGMap/GetListByNameAndType?keyValue=" + g[mainType] + "&typeCode=" + mainType,
function (j) {
if (j.data.length != 0) {
b.alert.warning("主语言项不能重复!");
return false
} else {
a.lrSaveForm(top.$.rootUrl + "/LR_LGManager/LGMap/SaveForm?nameList=" + h + "&newNameList=" + i + "&code=" + f, {},
function (k) {
if (!!e) {
e()
}
})
}
})
} else {
if (g[mainType] != d[mainType]) {
b.httpAsyncGet(top.$.rootUrl + "/LR_LGManager/LGMap/GetListByNameAndType?keyValue=" + g[mainType] + "&typeCode=" + mainType,
function (j) {
if (j.data.length != 0) {
b.alert.warning("主语言项不能重复!");
return false
} else {
a.lrSaveForm(top.$.rootUrl + "/LR_LGManager/LGMap/SaveForm?nameList=" + h + "&newNameList=" + i + "&code=" + f, {},
function (k) {
if (!!e) {
e()
}
})
//判断主语言是否重复
learun.httpAsyncGet(top.$.rootUrl + '/LR_LGManager/LGMap/GetListByNameAndType?keyValue=' + formData[mainType] + '&typeCode=' + mainType, function (res) {
if (res.data.length != 0) {
learun.alert.warning("主语言项不能重复!");
return false;
}
else {
$.lrSaveForm(top.$.rootUrl + '/LR_LGManager/LGMap/SaveForm?nameList=' + nameList + "&newNameList=" + newNameList + "&code=" + code, {}, function (res) {
// 保存成功后才回调
if (!!callBack) {
callBack();
}
})
} else {
a.lrSaveForm(top.$.rootUrl + "/LR_LGManager/LGMap/SaveForm?nameList=" + h + "&newNameList=" + i + "&code=" + f, {},
function (j) {
if (!!e) {
e()
}
})
});
}
});
}
else {
if (formData[mainType] != selectedRow[mainType]) {
//判断主语言是否重复
learun.httpAsyncGet(top.$.rootUrl + '/LR_LGManager/LGMap/GetListByNameAndType?keyValue=' + formData[mainType] + '&typeCode=' + mainType, function (res) {
if (res.data.length != 0) {
learun.alert.warning("主语言项不能重复!");
return false;
}
else {
$.lrSaveForm(top.$.rootUrl + '/LR_LGManager/LGMap/SaveForm?nameList=' + nameList + "&newNameList=" + newNameList + "&code=" + code, {}, function (res) {
// 保存成功后才回调
if (!!callBack) {
callBack();
}
});
}
});
}
else {
$.lrSaveForm(top.$.rootUrl + '/LR_LGManager/LGMap/SaveForm?nameList=' + nameList + "&newNameList=" + newNameList + "&code=" + code, {}, function (res) {
// 保存成功后才回调
if (!!callBack) {
callBack();
}
});
}
}
};
c.init()
};
page.init();
}

+ 7
- 10
Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/LR_LGManager/Views/LGMap/Index.cshtml Ver fichero

@@ -1,9 +1,7 @@

@{
ViewBag.Title = "数据字典";
@{
ViewBag.Title = "语言映照";
Layout = "~/Views/Shared/_Index.cshtml";
}

<div class="lr-layout" id="lr_layout">
<div class="lr-layout-center">
<div class="lr-layout-wrap lr-layout-wrap-notitle">
@@ -13,7 +11,7 @@
<input id="txt_Keyword" type="text" class="form-control" placeholder="请输入要查询主语言" />
</div>
<div class="lr-layout-tool-item">
<a id="btn_Search" class="btn btn-primary btn-sm"><i class="fa fa-search"></i>&nbsp;<span class="lrlt">查询</span></a>
<a id="btn_Search" class="btn btn-primary btn-sm"><i class="fa fa-search"></i>&nbsp;<span class="lrlg">查询</span></a>
</div>
</div>
<div class="lr-layout-tool-right">
@@ -21,9 +19,9 @@
<a id="lr_refresh" class="btn btn-default"><i class="fa fa-refresh"></i></a>
</div>
<div class=" btn-group btn-group-sm" learun-authorize="yes">
<a id="lr_add" class="btn btn-default"><i class="fa fa-plus"></i>&nbsp;<span class="lrlt">录入</span></a>
<a id="lr_edit" class="btn btn-default"><i class="fa fa-pencil-square-o"></i>&nbsp;<span class="lrlt">修改</span></a>
<a id="lr_delete" class="btn btn-default"><i class="fa fa-trash-o"></i>&nbsp;<span class="lrlt">删除</span></a>
<a id="lr_add" class="btn btn-default"><i class="fa fa-plus"></i>&nbsp;<span class="lrlg">新增</span></a>
<a id="lr_edit" class="btn btn-default"><i class="fa fa-pencil-square-o"></i>&nbsp;<span class="lrlg">编辑</span></a>
<a id="lr_delete" class="btn btn-default"><i class="fa fa-trash-o"></i>&nbsp;<span class="lrlg">删除</span></a>
</div>
</div>
</div>
@@ -31,5 +29,4 @@
</div>
</div>
</div>

@Html.AppendJsFile("/Areas/LR_LGManager/Views/LGMap/Index.js");
@Html.AppendJsFile("/Areas/LR_LGManager/Views/LGMap/Index.js")

+ 89
- 94
Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/LR_LGManager/Views/LGMap/Index.js Ver fichero

@@ -1,111 +1,106 @@
var selectedRow;
/* * 版 本 Learun-ADMS V7.0.3 力软敏捷开发框架(http://www.learun.cn)
* Copyright (c) 2013-2018 上海力软信息技术有限公司
* 创建人:超级管理员
* 日 期:2018-04-10 15:00
* 描 述:语言映照
*/
var selectedRow;
var refreshGirdData;
var formHeight;
var bootstrap = function (a, b) {
var c = {
var bootstrap = function ($, learun) {
"use strict";
var page = {
init: function () {
c.initGrid();
c.bind()
page.initGrid();
page.bind();
},
bind: function () {
a("#btn_Search").on("click",
function () {
var d = a("#txt_Keyword").val();
c.search({
keyword: d
})
});
a("#lr_refresh").on("click",
function () {
location.reload()
// 查询
$('#btn_Search').on('click', function () {
var keyword = $('#txt_Keyword').val();
page.search({ keyword: keyword });
});
// 刷新
$('#lr_refresh').on('click', function () {
location.reload();
});
// 新增
$('#lr_add').on('click', function () {
selectedRow = null;
learun.layerForm({
id: 'form',
title: '新增',
url: top.$.rootUrl + '/LR_LGManager/LGMap/Form',
width: 400,
height: formHeight,
callBack: function (id) {
return top[id].acceptClick(page.search);
}
});
a("#lr_add").on("click",
function () {
selectedRow = null;
b.layerForm({
id: "form",
title: "新增",
url: top.$.rootUrl + "/LR_LGManager/LGMap/Form",
});
// 编辑
$('#lr_edit').on('click', function () {
selectedRow = $('#gridtable').jfGridGet('rowdata');
if (learun.checkrow(selectedRow)) {
learun.layerForm({
id: 'form',
title: '编辑',
url: top.$.rootUrl + '/LR_LGManager/LGMap/Form?keyValue=' + selectedRow.f_code,
width: 400,
height: formHeight,
callBack: function (d) {
return top[d].acceptClick(c.search)
callBack: function (id) {
return top[id].acceptClick(page.search);
}
})
});
a("#lr_edit").on("click",
function () {
selectedRow = a("#gridtable").jfGridGet("rowdata");
if (b.checkrow(selectedRow)) {
b.layerForm({
id: "form",
title: "编辑",
url: top.$.rootUrl + "/LR_LGManager/LGMap/Form?keyValue=" + selectedRow.f_code,
width: 400,
height: formHeight,
callBack: function (d) {
return top[d].acceptClick(c.search)
}
})
}
});
a("#lr_delete").on("click",
function () {
selectedRow = a("#gridtable").jfGridGet("rowdata");
if (b.checkrow(selectedRow)) {
b.layerConfirm("是否确认删除该项!",
function (d) {
if (d) {
b.deleteForm(top.$.rootUrl + "/LR_LGManager/LGMap/DeleteForm", {
keyValue: selectedRow.f_code
},
function () {
c.search()
})
}
})
}
})
});
}
});
// 删除
$('#lr_delete').on('click', function () {
selectedRow = $('#gridtable').jfGridGet('rowdata');
if (learun.checkrow(selectedRow)) {
learun.layerConfirm('是否确认删除该项!', function (res) {
if (res) {
learun.deleteForm(top.$.rootUrl + '/LR_LGManager/LGMap/DeleteForm', { keyValue: selectedRow["f_code"] }, function () {
page.search()
});
}
});
}
});
},
initGrid: function () {
var d = [];
b.httpAsyncGet(top.$.rootUrl + "/LR_LGManager/LGType/GetList",
function (g) {
if (g.data) {
var h = [];
for (var e = 0; e < g.data.length; e++) {
var f = {
label: g.data[e].F_Name,
name: g.data[e].F_Code.toLowerCase(),
width: 200,
align: "left"
};
d.push(f);
h.push(g.data[e].F_Code)
}
a("#gridtable").jfGrid({
url: top.$.rootUrl + "/LR_LGManager/LGMap/GetPageList?typeList=" + h,
headData: d,
isPage: true,
});
c.search();
if (g.data.length <= 3) {
formHeight = 230
} else {
formHeight = 230 + (g.data.length - 3) * 40
}
var data = [];
//获取语言类型
learun.httpAsyncGet(top.$.rootUrl + '/LR_LGManager/LGType/GetList', function (res) {
if (res.data) {
var typeList = [];
for (var i = 0; i < res.data.length; i++) {
var obj = { label: res.data[i].F_Name, name: res.data[i].F_Code.toLowerCase(), width: 200, align: "left" };
data.push(obj);
typeList.push(res.data[i].F_Code);
}
$('#gridtable').jfGrid({
url: top.$.rootUrl + '/LR_LGManager/LGMap/GetPageList?typeList=' + typeList,
headData: data,
isPage: true,
});
page.search();
if (res.data.length <= 3) {
formHeight = 230;
}
else {
formHeight = 230 + (res.data.length - 3) * 40;
}
})
}
});
},
search: function (d) {
d = d || {};
a("#gridtable").jfGridSet("reload", {
queryJson: JSON.stringify(d)
})
search: function (param) {
param = param || {};
$('#gridtable').jfGridSet('reload', { queryJson: JSON.stringify(param) } );
}
};
refreshGirdData = function () {
c.search()
$('#gridtable').jfGridSet('reload');
};
c.init()
};
page.init();
}

+ 6
- 7
Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/LR_LGManager/Views/LGMap/SystemModuleLG.cshtml Ver fichero

@@ -1,9 +1,9 @@

@{
ViewBag.Title = "系统模块翻译";
Layout = "~/Views/Shared/_Index.cshtml";
}
@{
/**/

ViewBag.Title = "系统功能";
Layout = "~/Views/Shared/_Index.cshtml";
}
<div class="lr-layout lr-layout-left-center" id="lr_layout">
<div class="lr-layout-left">
<div class="lr-layout-wrap">
@@ -31,6 +31,5 @@
</div>
</div>
</div>


@Html.AppendJsFile("/Areas/LR_LGManager/Views/LGMap/SystemModuleLG.js")


+ 194
- 200
Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/LR_LGManager/Views/LGMap/SystemModuleLG.js Ver fichero

@@ -1,226 +1,220 @@
var refreshGirdData;
/*
* 版 本 Learun-ADMS V7.0.3 力软敏捷开发框架(http://www.learun.cn)
* Copyright (c) 2013-2018 上海力软信息技术有限公司
* 创建人:力软-前端开发组
* 日 期:2017.03.22
* 描 述:功能模块
*/
var refreshGirdData; // 更新数据
var selectedRow;
var formHeight;
var keyValue;
var moduleType = true;
var bootstrap = function (a, b) {
var c = "0";
var d = {
var bootstrap = function ($, learun) {
"use strict";
var moduleId = '0';
var page = {
init: function () {
d.inittree();
d.initGrid();
d.bind()
page.inittree();
page.initGrid();
page.bind();
},
bind: function () {
a("#btn_Search").on("click",
function () {
var e = a("#txt_Keyword").val();
d.search({
parentId: c,
keyword: e
})
});
a("#lr_refresh").on("click",
function () {
location.reload()
});
a("#lr_edit").on("click",
function () {
selectedRow = a("#gridtable").jfGridGet("rowdata");
if (b.checkrow(selectedRow)) {
b.layerForm({
id: "form",
title: "编辑",
url: top.$.rootUrl + "/LR_LGManager/LGMap/AddForm?keyValue=" + keyValue,
width: 400,
height: formHeight,
callBack: function (e) {
return top[e].acceptClick(function () {
d.search({
parentId: c
})
})
}
})
}
})
// 查询
$('#btn_Search').on('click', function () {
var keyword = $('#txt_Keyword').val();
page.search({ parentId: moduleId, keyword: keyword });
});
// 刷新
$('#lr_refresh').on('click', function () {
location.reload();
});
// 编辑
$('#lr_edit').on('click', function () {
selectedRow = $('#gridtable').jfGridGet('rowdata');
if (learun.checkrow(selectedRow)) {
learun.layerForm({
id: 'form',
title: '编辑',
url: top.$.rootUrl + '/LR_LGManager/LGMap/AddForm?keyValue=' + keyValue,
width: 400,
height: formHeight,
callBack: function (id) {
return top[id].acceptClick(function(){
page.search({ parentId: moduleId });
});
}
});
}
});
},
inittree: function () {
a("#module_tree").lrtree({
url: top.$.rootUrl + "/LR_SystemModule/Module/GetModuleTree",
nodeClick: d.treeNodeClick
})
$('#module_tree').lrtree({
url: top.$.rootUrl + '/LR_SystemModule/Module/GetModuleTree',
nodeClick: page.treeNodeClick
});
},
treeNodeClick: function (e) {
c = e.id;
moduleType = e.hasChildren;
a("#titleinfo").text(e.text);
d.search({
parentId: c
})
treeNodeClick: function (item) {
moduleId = item.id;
moduleType = item.hasChildren
$('#titleinfo').text(item.text);
page.search({ parentId: moduleId });
},
initGrid: function () {
var e = [];
b.httpAsyncGet(top.$.rootUrl + "/LR_LGManager/LGType/GetList",
function (h) {
if (h.data) {
e.push({
label: "名称",
name: h.data[0].F_Code,
width: 200,
align: "left"
});
keyValue = h.data[0].F_Code;
for (var f = 1; f < h.data.length; f++) {
var g = {
label: h.data[f].F_Name,
name: h.data[f].F_Code,
width: 200,
align: "left"
};
e.push(g)
}
a("#gridtable").jfGrid({
headData: e,
dblclick: function (i) {
if (b.checkrow(i)) {
selectedRow = i;
b.layerForm({
id: "form",
title: "编辑",
url: top.$.rootUrl + "/LR_LGManager/LGMap/AddForm?keyValue=" + keyValue,
width: 400,
height: formHeight,
callBack: function (j) {
return top[j].acceptClick(function () {
d.search({
parentId: c
})
})
}
})
}
var data = [];
//获取语言类型
learun.httpAsyncGet(top.$.rootUrl + '/LR_LGManager/LGType/GetList', function (res) {
if (res.data) {
data.push({ label: "名称", name: res.data[0].F_Code, width: 200, align: "left" });
keyValue = res.data[0].F_Code;//主语言
for (var i = 1; i < res.data.length; i++) {
var obj = { label: res.data[i].F_Name, name: res.data[i].F_Code, width: 200, align: "left" };
data.push(obj);
}
$('#gridtable').jfGrid({
headData: data,
dblclick: function (row) {
if (learun.checkrow(row)) {
selectedRow = row;
learun.layerForm({
id: 'form',
title: '编辑',
url: top.$.rootUrl + '/LR_LGManager/LGMap/AddForm?keyValue=' + keyValue,
width: 400,
height: formHeight,
callBack: function (id) {
return top[id].acceptClick(function () {
page.search({ parentId: moduleId });
});
}
});
}
});
d.search({
parentId: c
});
if (h.data.length <= 3) {
formHeight = 230
} else {
formHeight = 230 + (h.data.length - 3) * 40
}
});
page.search({ parentId: moduleId });
if (res.data.length <= 3) {
formHeight = 230;
}
})
else {
formHeight = 230 + (res.data.length - 3) * 40;
}
}
});
},
search: function (f) {
var g = [];
var e = {};
if (moduleType) {
b.httpAsyncGet(top.$.rootUrl + "/LR_SystemModule/Module/GetModuleListByParentId?parentId=" + f.parentId,
function (h) {
b.httpAsyncGet(top.$.rootUrl + "/LR_LGManager/LGMap/GetList",
function (n) {
if (h.data && n.data) {
for (var k = 0; k < h.data.length; k++) {
var o = n.data.find(function (i) {
return i.F_Name == h.data[k].F_FullName
});
if (typeof o != "undefined") {
var m = n.data.filter(function (i) {
return i.F_Code == o.F_Code
});
for (var l = 0; l < m.length; l++) {
e[m[l].F_TypeCode] = m[l].F_Name;
e.F_Code = m[l].F_Code
}
} else {
e[keyValue] = h.data[k].F_FullName;
e.F_Code = ""
}
g.push(e);
e = {}
search: function (param) {
//获取表数据并赋值
var rowData = [];
var obj = {};
if (moduleType) {//判断是否有下级
learun.httpAsyncGet(top.$.rootUrl + '/LR_SystemModule/Module/GetModuleListByParentId?parentId=' + param.parentId, function (res) {
learun.httpAsyncGet(top.$.rootUrl + '/LR_LGManager/LGMap/GetList', function (mapRes) {
if (res.data && mapRes.data) {
for (var i = 0; i < res.data.length; i++) {
var val = mapRes.data.find(function (element) {
return element.F_Name == res.data[i].F_FullName;
});
if (typeof val != 'undefined') {
var list = mapRes.data.filter(function (element) {
return element.F_Code == val.F_Code;
});
for (var j = 0; j < list.length; j++) {
obj[list[j].F_TypeCode] = list[j].F_Name;
obj.F_Code = list[j].F_Code;//每一行数据的F_Code
}
a("#gridtable").jfGridSet("refreshdata", g);
g = []
}
})
})
} else {
b.httpAsyncGet(top.$.rootUrl + "/LR_SystemModule/Module/GetFormData?keyValue=" + f.parentId,
function (h) {
b.httpAsyncGet(top.$.rootUrl + "/LR_LGManager/LGMap/GetList",
function (n) {
if (h.data && n.data) {
for (var k = 0; k < h.data.moduleButtons.length; k++) {
var o = n.data.find(function (i) {
return i.F_Name == h.data.moduleButtons[k].F_FullName
});
if (typeof o != "undefined") {
var m = n.data.filter(function (i) {
return i.F_Code == o.F_Code
});
for (var l = 0; l < m.length; l++) {
e[m[l].F_TypeCode] = m[l].F_Name;
e.F_Code = m[l].F_Code
}
} else {
e[keyValue] = h.data.moduleButtons[k].F_FullName;
e.F_Code = ""
}
g.push(e);
e = {}
else {
obj[keyValue] = res.data[i].F_FullName;
obj.F_Code = "";
}
rowData.push(obj);
obj = {};
}
$('#gridtable').jfGridSet('refreshdata', rowData);
rowData = [];
}
});
});
}
else {//展示按钮与列
learun.httpAsyncGet(top.$.rootUrl + '/LR_SystemModule/Module/GetFormData?keyValue=' + param.parentId, function (res) {
learun.httpAsyncGet(top.$.rootUrl + '/LR_LGManager/LGMap/GetList', function (mapRes) {
if (res.data && mapRes.data) {
// 按钮信息
for (var i = 0; i < res.data.moduleButtons.length; i++) {
var val = mapRes.data.find(function (element) {
return element.F_Name == res.data.moduleButtons[i].F_FullName;
});
if (typeof val != 'undefined') {
var list = mapRes.data.filter(function (element) {
return element.F_Code == val.F_Code;
});
for (var j = 0; j < list.length; j++) {
obj[list[j].F_TypeCode] = list[j].F_Name;
obj.F_Code = list[j].F_Code;//每一行数据的F_Code
}
for (var k = 0; k < h.data.moduleColumns.length; k++) {
var o = n.data.find(function (i) {
return i.F_Name == h.data.moduleColumns[k].F_FullName
});
if (typeof o != "undefined") {
var m = n.data.filter(function (i) {
return i.F_Code == o.F_Code
});
for (var l = 0; l < m.length; l++) {
e[m[l].F_TypeCode] = m[l].F_Name;
e.F_Code = m[l].F_Code
}
} else {
e[keyValue] = h.data.moduleColumns[k].F_FullName;
e.F_Code = ""
}
g.push(e);
e = {}
}
else {
obj[keyValue] = res.data.moduleButtons[i].F_FullName;
obj.F_Code = "";
}
rowData.push(obj);
obj = {};
}
// 列表信息
for (var i = 0; i < res.data.moduleColumns.length; i++) {
var val = mapRes.data.find(function (element) {
return element.F_Name == res.data.moduleColumns[i].F_FullName;
});
if (typeof val != 'undefined') {
var list = mapRes.data.filter(function (element) {
return element.F_Code == val.F_Code;
});
for (var j = 0; j < list.length; j++) {
obj[list[j].F_TypeCode] = list[j].F_Name;
obj.F_Code = list[j].F_Code;//每一行数据的F_Code
}
for (var k = 0; k < h.data.moduleFields.length; k++) {
var o = n.data.find(function (i) {
return i.F_Name == h.data.moduleFields[k].F_FullName
});
if (typeof o != "undefined") {
var m = n.data.filter(function (i) {
return i.F_Code == o.F_Code
});
for (var l = 0; l < m.length; l++) {
e[m[l].F_TypeCode] = m[l].F_Name;
e.F_Code = m[l].F_Code
}
} else {
e[keyValue] = h.data.moduleFields[k].F_FullName;
e.F_Code = ""
}
g.push(e);
e = {}
}
else {
obj[keyValue] = res.data.moduleColumns[i].F_FullName;
obj.F_Code = "";
}
rowData.push(obj);
obj = {};
}
// 表单字段
for (var i = 0; i < res.data.moduleFields.length; i++) {
var val = mapRes.data.find(function (element) {
return element.F_Name == res.data.moduleFields[i].F_FullName;
});
if (typeof val != 'undefined') {
var list = mapRes.data.filter(function (element) {
return element.F_Code == val.F_Code;
});
for (var j = 0; j < list.length; j++) {
obj[list[j].F_TypeCode] = list[j].F_Name;
obj.F_Code = list[j].F_Code;//每一行数据的F_Code
}
a("#gridtable").jfGridSet("refreshdata", g);
g = []
}
})
})
else {
obj[keyValue] = res.data.moduleFields[i].F_FullName;
obj.F_Code = "";
}
rowData.push(obj);
obj = {};
}

$('#gridtable').jfGridSet('refreshdata', rowData);
rowData = [];
}
});
});
}
}
};
// 保存数据后回调刷新
refreshGirdData = function () {
d.search({
parentId: c
})
};
d.init()
};
page.search({ parentId: moduleId });
}

page.init();
}

+ 7
- 11
Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/LR_LGManager/Views/LGType/Form.cshtml Ver fichero

@@ -1,19 +1,15 @@
@{
ViewBag.Title = "多语言映射";
ViewBag.Title = "语言类型";
Layout = "~/Views/Shared/_Form.cshtml";
}
<div class="lr-form-wrap">
<div class="col-xs-12 lr-form-item" data-table="LR_Lg_Type" >
<div class="lr-form-item-title">名称<font face="宋体">*</font></div>
<div class="lr-form-wrap" id="form">
<div class="col-xs-12 lr-form-item" style="padding-left:60px;">
<div class="lr-form-item-title" style="width:60px;" >名称<font face="宋体">*</font></div>
<input id="F_Name" type="text" class="form-control" isvalid="yes" checkexpession="NotNull" />
</div>
<div class="col-xs-12 lr-form-item" data-table="LR_Lg_Type" >
<div class="lr-form-item-title">编码<font face="宋体">*</font></div>
<input id="F_Code" type="text" class="form-control" isvalid="yes" checkexpession="NotNull" />
<div class="col-xs-12 lr-form-item" style="padding-left:60px;">
<div class="lr-form-item-title" style="width:60px;">编码<font face="宋体">*</font></div>
<input id="F_Code" type="text" class="form-control" isvalid="yes" checkexpession="NotNull" />
</div>
@*<div class="col-xs-12 lr-form-item" data-table="LR_Lg_Type" >
<div class="lr-form-item-title">是否主语言</div>
<input id="F_IsMain" type="text" class="form-control" />
</div>*@
</div>
@Html.AppendJsFile("/Areas/LR_LGManager/Views/LGType/Form.js")

+ 37
- 25
Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/LR_LGManager/Views/LGType/Form.js Ver fichero

@@ -1,48 +1,60 @@
/* * 版 本 Learun-ADMS-Ultimate V7.0.0 数字化智慧校园(http://www.learun.cn)
* Copyright (c) 2013-2018 北京泉江科技有限公司
/* * 版 本 Learun-ADMS V7.0.3 力软敏捷开发框架(http://www.learun.cn)
* Copyright (c) 2013-2018 上海力软信息技术有限公司
* 创建人:超级管理员
* 日 期:2018-09-29 15:01
* 描 述:多语言映射
* 日 期:2018-04-10 15:08
* 描 述:语言类型
*/
var acceptClick;
var keyValue = request('keyValue');
var bootstrap = function ($, learun) {
"use strict";
var selectedRow = learun.frameTab.currentIframe().selectedRow;
var page = {
init: function () {
$('.lr-form-wrap').lrscroll();
page.bind();
page.initData();
},
bind: function () {
},
initData: function () {
if (!!keyValue) {
$.lrSetForm(top.$.rootUrl + '/LR_LGManager/LGType/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]);
}
}
});
if (!!selectedRow) {
$('#form').lrSetFormData(selectedRow);
}
}
};
// 保存数据
acceptClick = function (callBack) {
if (!$('body').lrValidform()) {
if (!$('#form').lrValidform()) {
return false;
}
var postData = {
strEntity: JSON.stringify($('body').lrGetFormData())
};
$.lrSaveForm(top.$.rootUrl + '/LR_LGManager/LGType/SaveForm?keyValue=' + keyValue, postData, function (res) {
// 保存成功后才回调
if (!!callBack) {
callBack();
var postData = $('#form').lrGetFormData();
postData.F_Code = postData.F_Code.toLowerCase();
postData.F_IsMain = 0;
postData['__RequestVerificationToken'] = $.lrToken;
learun.httpAsyncGet(top.$.rootUrl + '/LR_LGManager/LGType/GetEntityByCode?keyValue=' + postData.F_Code, function (res) {
//判断编辑是否更改编码
if (res.data) {
learun.alert.warning("编码已存在");
return false;
}
else {
if (!(selectedRow && selectedRow.F_Code === postData.F_Code) && keyValue) {
selectedRow.F_Code = postData.F_Code;
selectedRow.F_Name = postData.F_Name;
$.lrSaveForm(top.$.rootUrl + '/LR_LGManager/LGType/SaveForm?keyValue=' + keyValue, selectedRow, function (res) {
// 保存成功后才回调
if (!!callBack) {
callBack();
}
});
}
else if (!keyValue) {
$.lrSaveForm(top.$.rootUrl + '/LR_LGManager/LGType/SaveForm?keyValue=' + keyValue, postData, function (res) {
// 保存成功后才回调
if (!!callBack) {
callBack();
}
});
}
}
});
};


+ 10
- 9
Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/LR_LGManager/Views/LGType/Index.cshtml Ver fichero

@@ -1,29 +1,30 @@
@{
ViewBag.Title = "多语言映射";
ViewBag.Title = "语言类型";
Layout = "~/Views/Shared/_Index.cshtml";
}
<div class="lr-layout ">
<div class="lr-layout" id="lr_layout">
<div class="lr-layout-center">
<div class="lr-layout-wrap lr-layout-wrap-notitle ">
<div class="lr-layout-wrap lr-layout-wrap-notitle">
<div class="lr-layout-tool">
<div class="lr-layout-tool-left">
<div class="lr-layout-tool-item">
<input id="txt_Keyword" type="text" class="form-control" placeholder="请输入要查询名称" />
</div>
<div class="lr-layout-tool-item">
<a id="btn_Search" class="btn btn-primary btn-sm"><i class="fa fa-search"></i>&nbsp;<span class="lrlt">查询</span></a>
<a id="btn_Search" class="btn btn-primary btn-sm"><i class="fa fa-search"></i>&nbsp;<span class="lrlg">查询</span></a>
</div>

</div>
<div class="lr-layout-tool-right">
<div class=" btn-group btn-group-sm">
<a id="lr_refresh" class="btn btn-default"><i class="fa fa-refresh"></i></a>
</div>
<div class=" btn-group btn-group-sm" learun-authorize="yes">
<a id="lr_add" class="btn btn-default"><i class="fa fa-plus"></i>&nbsp;录入</a>
<a id="lr_edit" class="btn btn-default"><i class="fa fa-pencil-square-o"></i>&nbsp;修改</a>
<a id="lr_delete" class="btn btn-default"><i class="fa fa-trash-o"></i>&nbsp;删除</a>
<a id="lr_print" class="btn btn-default"><i class="fa fa-print"></i>&nbsp;打印</a>
<a id="lr_add" class="btn btn-default"><i class="fa fa-plus"></i>&nbsp;<span class="lrlg">新增</span></a>
<a id="lr_edit" class="btn btn-default"><i class="fa fa-pencil-square-o"></i>&nbsp;<span class="lrlg">编辑</span></a>
<a id="lr_delete" class="btn btn-default"><i class="fa fa-trash-o"></i>&nbsp;<span class="lrlg">删除</span></a>
</div>
<div class=" btn-group btn-group-sm" learun-authorize="yes">
<a id="lr_mainlg" class="btn btn-default"><i class="fa fa-pencil-square-o"></i>&nbsp;<span class="lrlg">设为主语言</span></a>
</div>
</div>
</div>


+ 69
- 56
Learun.Framework.Ultimate V7/Learun.Application.Web/Areas/LR_LGManager/Views/LGType/Index.js Ver fichero

@@ -1,26 +1,23 @@
/* * 版 本 Learun-ADMS-Ultimate V7.0.0 数字化智慧校园(http://www.learun.cn)
* Copyright (c) 2013-2018 北京泉江科技有限公司
/* * 版 本 Learun-ADMS V7.0.3 力软敏捷开发框架(http://www.learun.cn)
* Copyright (c) 2013-2018 上海力软信息技术有限公司
* 创建人:超级管理员
* 日 期:2018-09-29 15:01
* 描 述:多语言映射
* 日 期:2018-04-10 15:08
* 描 述:语言类型
*/
var refreshGirdData;
var selectedRow;
var refreshGirdData;
var bootstrap = function ($, learun) {
"use strict";
var page = {
init: function () {
page.initGird();
page.initGrid();
page.bind();
},
bind: function () {


$("#btn_Search").on("click", function () {
var keyword = $("#txt_Keyword").val();
page.search({
keyword: keyword
});
// 查询
$('#btn_Search').on('click', function () {
var keyword = $('#txt_Keyword').val();
page.search({ keyword: keyword });
});
// 刷新
$('#lr_refresh').on('click', function () {
@@ -30,9 +27,9 @@ var bootstrap = function ($, learun) {
$('#lr_add').on('click', function () {
selectedRow = null;
learun.layerForm({
id: "form",
title: "新增",
url: top.$.rootUrl + "/LR_LGManager/LGType/Form",
id: 'form',
title: '新增',
url: top.$.rootUrl + '/LR_LGManager/LGType/Form',
width: 300,
height: 180,
callBack: function (id) {
@@ -43,11 +40,12 @@ var bootstrap = function ($, learun) {
// 编辑
$('#lr_edit').on('click', function () {
var keyValue = $('#gridtable').jfGridValue('F_Id');
selectedRow = $('#gridtable').jfGridGet('rowdata');
if (learun.checkrow(keyValue)) {
learun.layerForm({
id: "form",
title: "编辑",
url: top.$.rootUrl + "/LR_LGManager/LGType/Form?keyValue=" + keyValue,
id: 'form',
title: '编辑',
url: top.$.rootUrl + '/LR_LGManager/LGType/Form?keyValue=' + keyValue,
width: 300,
height: 180,
callBack: function (id) {
@@ -59,65 +57,80 @@ var bootstrap = function ($, learun) {
// 删除
$('#lr_delete').on('click', function () {
var keyValue = $('#gridtable').jfGridValue('F_Id');
selectedRow = $('#gridtable').jfGridGet('rowdata');
if (learun.checkrow(keyValue)) {
selectedRow = $("#gridtable").jfGridGet("rowdata");
if (selectedRow.F_IsMain === 1) {
learun.alert.warning("主语言不能删除!");
return false;
}
learun.layerConfirm('是否确认删除该项!', function (res) {
if (res) {
learun.deleteForm(top.$.rootUrl + '/LR_LGManager/LGType/DeleteForm', { keyValue: keyValue}, function () {
refreshGirdData();
learun.httpAsyncGet(top.$.rootUrl + '/LR_LGManager/LGMap/GetListByTypeCode?TypeCode=' + selectedRow.F_Code, function (res) {
if (res.data.length != 0) {
learun.alert.warning("请先删除编码对应数据!");
return false;
}
else {
learun.layerConfirm('是否确认删除该项!', function (res) {
if (res) {
learun.deleteForm(top.$.rootUrl + '/LR_LGManager/LGType/DeleteForm', { keyValue: keyValue }, function () {
refreshGirdData();
});
}
});
}
});
}
});
// 打印
$('#lr_print').on('click', function () {
$('#gridtable').jqprintTable();
$('#lr_mainlg').on('click', function () {
var keyValue = $('#gridtable').jfGridValue('F_Id');
if (learun.checkrow(keyValue)) {
learun.layerConfirm('是否确认设为主语言!', function (res, index) {
if (res) {
learun.loading(true, '正在设置主语言');
learun.httpAsyncPost(top.$.rootUrl + '/LR_LGManager/LGType/SetMainLG', { keyValue: keyValue }, function (res) {
learun.loading(false);
if (res.code == learun.httpCode.success) {
learun.alert.success(res.info);
refreshGirdData();
}
else {
learun.alert.error(res.info);
learun.httpErrorLog(res.info);
}
top.layer.close(index)
});
}
})
}
});
},
// 初始化列表
initGird: function () {
initGrid: function () {
$('#gridtable').lrAuthorizeJfGrid({
url: top.$.rootUrl + '/LR_LGManager/LGType/GetPageList',
headData: [{
label: "名称",
name: "F_Name",
width: 200,
align: "left"
}, {
label: "编码",
name: "F_Code",
width: 300,
align: "left"
}, {
label: "主语言",
name: "F_IsMain",
width: 80,
align: "left",
formatter: function (d) {
if (d == 1) {
return '<span class="label label-info" style="cursor: pointer;">是</span>';
} else {
return '<span class="label label-danger" style="cursor: pointer;">否</span>';
url: top.$.rootUrl + '/LR_LGManager/LGType/GetList',
headData: [
{ label: '名称', name: 'F_Name', width: 200, align: "left" },
{ label: '编码', name: 'F_Code', width: 300, align: "left" },
{
label: '主语言', name: 'F_IsMain', width: 80, align: "left",
formatter: function (cellvalue) {
if (cellvalue == 1) {
return '<span class=\"label label-info\" style=\"cursor: pointer;\">是</span>';
}
else return '<span class=\"label label-danger\" style=\"cursor: pointer;\">否</span>';
}
}
}],
mainId:'F_Id',
isPage: true
},
],
mainId: 'F_Id',
reloadSelected: true,
});
page.search();
},
search: function (param) {
param = param || {};
$('#gridtable').jfGridSet('reload',{ queryJson: JSON.stringify(param) });
$('#gridtable').jfGridSet('reload', { queryJson: JSON.stringify(param) });
}
};
refreshGirdData = function () {
page.search();
$('#gridtable').jfGridSet('reload');
};
page.init();
}

+ 9
- 0
Learun.Framework.Ultimate V7/Learun.Application.Web/Controllers/UserCenterController.cs Ver fichero

@@ -163,6 +163,15 @@ namespace Learun.Application.Web.Controllers
ViewBag.isCheck = checkMark;
return View();
}
/// <summary>
/// 个人中心-语言设置
/// </summary>
/// <returns></returns>
[HttpGet]
public ActionResult LanguageForm()
{
return View();
}
#endregion

#region 获取数据


+ 8
- 0
Learun.Framework.Ultimate V7/Learun.Application.Web/Learun.Application.Web.csproj Ver fichero

@@ -3805,6 +3805,7 @@
<Content Include="Views\LR_Content\script\lr-iframe-index.js" />
<Content Include="Views\LR_Content\script\lr-bootstrap.js" />
<Content Include="Views\LR_Content\script\lr-im.js" />
<Content Include="Views\LR_Content\script\lr-language - 副本.js" />
<Content Include="Views\LR_Content\script\lr-language.js" />
<Content Include="Views\LR_Content\script\lr-tabs.js" />
<Content Include="Views\LR_Content\script\lr-validator.js" />
@@ -4858,6 +4859,8 @@
<Content Include="Views\UserCenter\IndexInTeacher.js" />
<Content Include="Views\UserCenter\Index.css" />
<Content Include="Views\UserCenter\Index.js" />
<Content Include="Views\UserCenter\LanguageForm.css" />
<Content Include="Views\UserCenter\LanguageForm.js" />
<Content Include="Views\UserCenter\LogIndex.css" />
<Content Include="Views\UserCenter\LogIndex.js" />
<Content Include="Views\UserCenter\PassWordForm.css" />
@@ -6132,6 +6135,10 @@
<Project>{DB34DFC9-7227-41FA-88AA-832DBF247811}</Project>
<Name>Learun.Application.IM</Name>
</ProjectReference>
<ProjectReference Include="..\Learun.Framework.Module\Learun.Application.Module\Learun.Application.Language\Learun.Application.Language.csproj">
<Project>{36083FBB-CE7F-4EE0-8459-C4B60A2DD070}</Project>
<Name>Learun.Application.Language</Name>
</ProjectReference>
<ProjectReference Include="..\Learun.Framework.Module\Learun.Application.Module\Learun.Application.Mapping\Learun.Application.Mapping.csproj">
<Project>{79f8e2f1-08e7-4336-93e0-512b39f9dd54}</Project>
<Name>Learun.Application.Mapping</Name>
@@ -6852,6 +6859,7 @@
<Content Include="Views\Shared\_AllIndex.cshtml" />
<Content Include="Views\Shared\_jqGrid.cshtml" />
<Content Include="Views\Shared\_ReportForm.cshtml" />
<Content Include="Views\UserCenter\LanguageForm.cshtml" />
</ItemGroup>
<ItemGroup>
<WCFMetadata Include="Connected Services\" />


+ 7
- 1
Learun.Framework.Ultimate V7/Learun.Application.Web/Views/Home/AdminAccordion.cshtml Ver fichero

@@ -4,10 +4,16 @@
}
@Html.AppendCssFile("/Views/Home/AdminAccordion/index.css")
<div class="lr-frame-top">
<a class="lr-logo-title"><img src="~/LR_SystemModule/LogoImg/GetImg?code=accordion"></a>
</div>
<div class="lr-frame-menu-btn" id="lr_frame_menu_btn"><i class="fa fa-fw fa-dedent"></i></div>

<div class="lr-lg-setting" id="lr_lg_setting">
<a href="javascript:void(0);" class="dropdown-toggle" data-toggle="dropdown" aria-expanded="false">[<span></span>]</a>
<ul class="dropdown-menu"></ul>
</div>

<div class="lr-im-bell" title="消息中心">
<span class="point" style="display:none;"></span>
<i class="fa fa-bell"></i>


+ 195
- 135
Learun.Framework.Ultimate V7/Learun.Application.Web/Views/Home/AdminAccordion/Index.css Ver fichero

@@ -1,4 +1,11 @@
.lr-logo-title {
/*
* 版 本 Learun-ADMS V7.0.3 力软敏捷开发框架(http://www.learun.cn)
* Copyright (c) 2013-2018 上海力软信息技术有限公司
* 创建人:力软-前端开发组
* 日 期:2017.03.16
* 描 述:手风琴风格皮肤样式表
*/
.lr-logo-title {
display: block;
position: absolute;
top: 0;
@@ -9,18 +16,18 @@
white-space: nowrap;
left: 10px;
line-height: 55px;
color: #fff !important
color: #fff !important;
}

.lr-logo-title img {
width: 320px
width: 320px;
}
/*顶部*/
.lr-frame-top {
height: 60px;
background: #1d1d1d
background: #1d1d1d;
}
/*菜单*/
.lr-frame-menu {
top: 0;
width: 200px;
@@ -28,15 +35,15 @@
z-index: 1;
background: #282828;
box-shadow: 1px 0 20px rgba(0,0,0,0.08);
padding: 90px 0 35px 0
padding: 90px 0 35px 0;
}

.lr-frame-menu .lr-menu-item {
height: 36px;
line-height: 36px;
padding: 0 15px;
padding: 0px 15px;
color: #fff;
font-size: 13px
font-size: 13px;
}

.lr-first-menu-list > li > .lr-menu-item:hover {
@@ -44,60 +51,73 @@
}

.lr-first-menu-list > li > .lr-menu-item.open {
background: #156edb
background: #156edb;
}


.lr-frame-menu .lr-menu-item-icon {
font-size: 14px;
opacity: .9;
opacity: 0.9;
filter: alpha(opacity=90);
width: 17px;
margin-right: 8px;
vertical-align: middle;
margin-bottom: 1px
margin-bottom: 1px;
}

.lr-frame-menu .lr-menu-item-arrow {
position: absolute;
right: 10px;
line-height: 36px
line-height: 36px;
}

.lr-second-menu-list, .lr-three-menu-list, .lr-fourth-menu-list {



.lr-second-menu-list,
.lr-three-menu-list {
position: relative;
width: 100%;
background-color: #1d1d1d
background-color: #1d1d1d;
}

.lr-second-menu-list .lr-menu-item {
padding-left: 40px;
padding-right: 15px
padding-right: 15px;
}

.lr-second-menu-list .lr-menu-item:hover {
background-color: #393939
background-color: #393939;
}

.lr-three-menu-list .lr-menu-item {
padding-left: 60px
padding-left: 60px;
}

.lr-four-menu-list {
display: none;
}

.lr-four-menu-list .lr-menu-item {
padding-left: 80px;
}

.lr-menu-item.open > .lr-menu-item-arrow > i {
-webkit-transform: rotate(-90deg);
-ms-transform: rotate(-90deg);
-o-transform: rotate(-90deg);
transform: rotate(-90deg)
transform: rotate(-90deg);
}
/*tabs条*/
.lr-frame-tabs {
top: 0;
height: 60px;
z-index: 2;
padding: 0 60px 0 405px
padding: 0px 60px 0px 405px;
}

.lr-frame-tabItem:first-child {
border-left: 1px solid #2a2f32
border-left: 1px solid #2a2f32;
}

.lr-frame-tabItem {
@@ -106,23 +126,23 @@
font-size: 14px;
border-right: 1px solid #2a2f32;
color: #fff;
margin-left: 0
margin-left: 0px;
}

.lr-frame-tabItem.active {
background: #444
background: #444;
}

.lr-frame-tabItem .reomve {
top: 24px;
right: 4px
right: 4px;
}
/*功能窗口*/
.lr-frame-main {
padding: 60px 0 0 200px;
background: #eaedf1
padding: 60px 0px 0px 200px;
background: #eaedf1;
}
/*个人设置和头像*/
.lr-frame-personCenter {
bottom: 0;
left: 0;
@@ -130,14 +150,14 @@
width: 200px;
line-height: 35px;
padding: 0 10px;
background: #282828
background: #282828;
}

.lr-frame-personCenter > .dropdown-toggle {
height: 100%;
line-height: 35px;
border-top: 1px solid rgba(248,248,248,0.2);
color: #fff
color: #fff;
}

.lr-frame-personCenter > .dropdown-toggle > img {
@@ -146,7 +166,7 @@
height: 18px;
border: 2px solid #fff;
border-radius: 50%;
margin: 8px 10px 0 0
margin: 8px 10px 0 0;
}

.lr-frame-personCenter .dropdown-menu {
@@ -154,24 +174,25 @@
position: absolute;
left: 10px;
top: -172px;
background: #282828
background: #282828;
}

.lr-frame-personCenter .dropdown-menu > li > a {
padding: 10px 15px;
color: #fff;
font-size: 12px
font-size: 12px;
}

.lr-frame-personCenter .dropdown-menu > li > a:hover {
background: #393939;
color: #fff
color: #fff;
}

.lr-frame-personCenter .divider {
background-color: #63656B
background-color: #63656B;
}

/*风尚版独有-菜单缩进按钮*/
.lr-frame-menu-btn {
position: absolute;
left: 0;
@@ -184,18 +205,19 @@
cursor: pointer;
color: #aeb9c2;
background-color: #4A5064;
z-index: 2
z-index: 2;
}

.lr-frame-menu-btn:hover {
background-color: #4A5064;
color: #fff
color: #fff;
}

.lr-frame-menu-btn i {
opacity: .5
opacity: .5;
}

/*全屏*/
.lr_frame_fullscreen {
top: 0;
right: 0;
@@ -203,37 +225,44 @@
width: 30px;
line-height: 60px;
text-align: center;
z-index: 3
z-index: 3;
}

.lr_frame_fullscreen a {
font-size: 14px;
color: #c1c3c9
color: #c1c3c9;
}

.lr_frame_fullscreen a:hover {
color: #fff
color: #fff;
}

/*菜单关闭后显示样式*/
.lr-menu-closed .lr-frame-menu {
width: 50px
width: 50px;
}

.lr-menu-closed .lr-frame-menu-wrap span, .lr-menu-closed .lr-frame-menu-wrap .lr-menu-item-arrow, .lr-menu-closed .lr-meun-had > a {
display: none
.lr-menu-closed .lr-frame-menu-wrap .lr-three-menu-list {
display: block;
}

.lr-menu-closed .lr-frame-menu-wrap a {
padding: 0;
text-align: center
.lr-menu-closed .lr-frame-menu-wrap .lr-four-menu-list {
display: block;
}

.lr-menu-closed .lr-frame-menu-wrap .lr-three-menu-list {
display: block
.lr-menu-closed .lr-frame-menu-wrap span,
.lr-menu-closed .lr-frame-menu-wrap .lr-menu-item-arrow,
.lr-menu-closed .lr-meun-had > a {
display: none;
}

.lr-menu-closed .lr-frame-menu-wrap a {
padding: 0px;
text-align: center;
}

.lr-menu-closed .lr-frame-menu-wrap .lr-menu-item-icon {
margin: 0
margin: 0px;
}

.lr-menu-closed .lr-frame-menu-btn {
@@ -241,37 +270,39 @@
-ms-transform: rotate(-180deg);
-o-transform: rotate(-180deg);
transform: rotate(-180deg);
width: 50px
width: 50px;
}

.lr-menu-closed .lr-frame-personCenter {
width: 50px;
padding: 0
padding: 0px;
}

.lr-menu-closed .lr-frame-personCenter .dropdown-menu {
padding: 0
padding: 0px;
}

.lr-menu-closed .lr-frame-personCenter > .dropdown-toggle {
line-height: 50px;
text-align: center
text-align: center;
}

.lr-menu-closed .lr-frame-personCenter > .dropdown-toggle > img {
float: initial;
margin: 0
margin: 0;
}

.lr-menu-closed .lr-frame-personCenter > .dropdown-toggle > span {
display: none
display: none;
}

.lr-menu-closed .lr-frame-main {
padding: 60px 0 0 50px
padding: 60px 0px 0px 50px;
}


/*即时通讯*/

.lr-im-bell {
position: fixed;
right: 30px;
@@ -283,11 +314,11 @@
text-align: center;
cursor: pointer;
z-index: 51;
display: none
display: none;
}

.lr-im-bell > i {
font-size: 18px
font-size: 18px;
}

.lr-im-bell > .point {
@@ -297,9 +328,10 @@
top: 17px;
width: 8px;
height: 8px;
border-radius: 50%
border-radius: 50%;
}


.lr-im-body {
position: fixed;
right: 10px;
@@ -309,11 +341,11 @@
background: #F9FBFB;
z-index: 50;
padding-left: 40px;
display: none
display: none;
}

.lr-im-body.open {
display: block
display: block;
}

.lr-im-title {
@@ -322,7 +354,7 @@
left: 0;
background: #3A3845;
width: 40px;
height: 100%
height: 100%;
}

.lr-im-title .title-item {
@@ -335,15 +367,15 @@
color: #696972;
font-size: 18px;
line-height: 50px;
text-align: center
text-align: center;
}

.lr-im-title .title-item.active {
color: #fff
color: #fff;
}

.lr-im-title .title-item.title-item-two {
top: 50px
top: 50px;
}

.lr-im-content {
@@ -352,24 +384,24 @@
height: 100%;
display: none;
border: 1px solid #E5E5E5;
border-left: 0
border-left: 0;
}

.lr-im-content.active {
display: block
display: block;
}

.lr-im-msg-list {
position: relative;
width: 100%;
height: 100%
height: 100%;
}

.lr-im-msg-list .msg-item {
position: relative;
width: 100%;
height: 50px;
cursor: pointer
cursor: pointer;
}

.lr-im-msg-list .msg-item:after {
@@ -380,25 +412,30 @@
width: 218px;
background: #E5E5E5;
bottom: 0;
left: 10px
left: 10px;
}

.lr-im-msg-list .msg-item .msglist-close {
.lr-im-msg-list .msg-item .remove {
position: absolute;
top: 15px;
left: 5px;
top: 0px;
left: 0px;
color: #333;
font-size: 12px;
display: none
display: none;
}

.lr-im-msg-list .msg-item:hover .remove {
display: block;
}


.lr-im-msg-list .msg-item .photo {
position: absolute;
width: 30px;
height: 30px;
border-radius: 3px;
top: 10px;
left: 10px
left: 10px;
}

.lr-im-msg-list .msg-item .icon {
@@ -412,13 +449,13 @@
background-color: #1D6DC5;
color: #fff;
font-size: 18px;
text-align: center
text-align: center;
}

.lr-im-msg-list .msg-item img {
width: 100%;
height: 100%;
border-radius: 3px
border-radius: 3px;
}

.lr-im-msg-list .msg-item .name {
@@ -426,11 +463,11 @@
top: 8px;
left: 50px;
height: 16px;
color: #333;
color: #333333;
font-size: 12px;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap
white-space: nowrap;
}

.lr-im-msg-list .msg-item .msg {
@@ -443,7 +480,7 @@
font-size: 12px;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap
white-space: nowrap;
}

.lr-im-msg-list .msg-item .date {
@@ -453,11 +490,12 @@
height: 16px;
color: #666;
font-size: 12px;
text-align: right
text-align: right;
}


.lr-im-userlist {
padding-top: 40px
padding-top: 40px;
}

.lr-im-search {
@@ -467,7 +505,7 @@
width: 100%;
height: 40px;
font-size: 0;
padding: 10px 20px
padding: 10px 20px;
}

.lr-im-search i {
@@ -477,7 +515,7 @@
font-size: 12px;
font-weight: 100;
color: #999;
z-index: 1
z-index: 1;
}

.lr-im-search input {
@@ -491,34 +529,35 @@
border-radius: 3px;
box-sizing: border-box;
color: #999;
outline: 0;
text-indent: 20px
outline: none;
text-indent: 20px;
}

.lr-im-search input::-webkit-input-placeholder {
text-align: center
text-align: center;
}

.lr-im-search input::-moz-placeholder {
text-align: center
.lr-im-search input::-moz-placeholder { /* Mozilla Firefox 19+ */
text-align: center;
}

.lr-im-search input:-moz-placeholder {
text-align: center
.lr-im-search input:-moz-placeholder { /* Mozilla Firefox 4 to 18 */
text-align: center;
}

.lr-im-search input:-ms-input-placeholder {
text-align: center
.lr-im-search input:-ms-input-placeholder { /* Internet Explorer 10-11 */
text-align: center;
}


.lr-im-content-userlist {
position: relative;
width: 100%;
height: 100%
height: 100%;
}

.lr-im-content-userlist .lr-scroll-box {
padding: 0 20px
padding: 0 20px;
}

.lr-im-item-name {
@@ -528,33 +567,34 @@
line-height: 30px;
cursor: pointer;
font-size: 12px;
color: #666
color: #666;
}

.lr-im-item-name > i {
color: #999;
font-size: 14px;
margin: 3px
margin: 3px;
}


.lr-im-item-name.open > i {
-webkit-transform: rotate(90deg);
-moz-transform: rotate(90deg);
-ms-transform: rotate(90deg);
-o-transform: rotate(90deg);
transform: rotate(90deg)
transform: rotate(90deg);
}

.lr-im-user-list {
position: relative;
width: 100%
width: 100%;
}

.lr-im-user {
position: relative;
height: 43px;
line-height: 43px;
padding-left: 40px
padding-left: 40px;
}

.lr-im-user > img {
@@ -563,7 +603,7 @@
left: 0;
width: 30px;
height: 30px;
border-radius: 50%
border-radius: 50%;
}

.lr-im-black-overlay {
@@ -575,11 +615,11 @@
overflow: hidden;
background: rgba(51,51,51,0.4);
z-index: 52;
display: none
display: none;
}

.lr-im-black-overlay.open {
display: block
display: block;
}

.lr-im-dialog {
@@ -594,7 +634,7 @@
border-radius: 3px;
box-shadow: 0 0 2px 0 rgba(0,0,0,0.50);
padding-top: 40px;
padding-bottom: 135px
padding-bottom: 135px;
}

.lr-im-header {
@@ -607,7 +647,7 @@
line-height: 39px;
padding-left: 10px;
font-size: 14px;
color: #333
color: #333333;
}

.lr-im-header .im-close {
@@ -621,13 +661,13 @@
cursor: pointer;
font-size: 12px;
color: #333;
font-weight: 100
font-weight: 100;
}

.lr-im-msgcontent {
position: relative;
width: 100%;
height: 100%
height: 100%;
}

.lr-im-msgcontent-tool {
@@ -640,11 +680,11 @@
bottom: 110px;
padding-right: 10px;
border-top: 1px solid #E5E5E5;
background: #F8F8F8
background: #F8F8F8;
}

.lr-im-msgcontent-tool > span {
cursor: pointer
cursor: pointer;
}

.lr-im-input {
@@ -653,7 +693,7 @@
left: 0;
width: 100%;
height: 110px;
border-top: 1px solid #E5E5E5
border-top: 1px solid #E5E5E5;
}

.lr-im-input .inp {
@@ -663,7 +703,7 @@
border: 0;
outline: 0;
padding: 5px;
background: transparent
background: transparent;
}

.lr-im-msgcontent .im-time {
@@ -674,14 +714,15 @@
height: 15px;
line-height: 15px;
text-align: left;
padding: 0 50px
padding: 0 50px;
}

.lr-im-msgcontent .me.im-time {
text-align: right
text-align: right;
}

.lr-im-msgcontent .im-me, .lr-im-msgcontent .im-other {
.lr-im-msgcontent .im-me,
.lr-im-msgcontent .im-other {
position: relative;
word-break: break-all;
height: auto;
@@ -689,11 +730,11 @@
width: 100%;
padding: 0 50px;
margin-bottom: 10px;
text-align: right
text-align: right;
}

.lr-im-msgcontent .im-other {
text-align: left
text-align: left;
}

.lr-im-msgcontent .im-other .headimg {
@@ -702,32 +743,34 @@
left: 10px;
width: 30px;
height: 30px;
border-radius: 50%
border-radius: 50%;
}

.lr-im-msgcontent .im-me img, .lr-im-msgcontent .im-other img {
.lr-im-msgcontent .im-me img,
.lr-im-msgcontent .im-other img {
width: 100%;
height: 100%;
border-radius: 50%
border-radius: 50%;
}

.lr-im-msgcontent .im-me .content, .lr-im-msgcontent .im-other .content {
.lr-im-msgcontent .im-me .content,
.lr-im-msgcontent .im-other .content {
display: inline-block;
background: #FFF;
background: #FFFFFF;
border: 1px solid #E5E5E5;
padding: 5px 13px 6px 19px;
font-size: 12px;
color: #333;
color: #333333;
box-sizing: border-box;
position: relative;
float: left;
max-width: 100%;
text-align: left;
line-height: 20px
line-height: 20px;
}

.lr-im-msgcontent .im-me .content {
float: right
float: right;
}

.lr-im-msgcontent .im-other .arrow {
@@ -746,7 +789,7 @@
z-index: 1;
clip: rect(0,8px,8px,0);
border-bottom: 0;
border-right: 0
border-right: 0;
}

.lr-im-msgcontent .im-me .headimg {
@@ -755,9 +798,10 @@
right: 10px;
width: 30px;
height: 30px;
border-radius: 50%
border-radius: 50%;
}


.lr-im-msgcontent .im-me .arrow {
width: 8px;
height: 8px;
@@ -774,36 +818,52 @@
z-index: 1;
clip: rect(0,8px,8px,0);
border-top: 0;
border-left: 0
border-left: 0;
}

.imHasMsg .point {
display: block
display: block;
}



/*语言设置*/
.lr-lg-setting {
position: absolute;
top: 21px;
left: 333px;
font-size: 14px;
z-index: 4;
color: #c6c6c6
color: #c6c6c6;
}

.lr-lg-setting > a {
color: #c6c6c6
color: #c6c6c6;
}

.lr-lg-setting span {
color: #fff
color: #fff;
}


.photo .fa {
display: block;
font-size: 20px;
line-height: 30px;
height: 30px;
width: 30px;
border-radius: 5px;
margin: 0 auto;
text-align: center;
color: #fff;
background-color: #985CE2;
}


/*新增*/
.lr-frame-tabs {
/*.lr-frame-tabs {
padding-left:280px;
}
}*/
.lr-frame-top{
background: #3286ed;
}


+ 5
- 2
Learun.Framework.Ultimate V7/Learun.Application.Web/Views/Home/AdminDefault.cshtml Ver fichero

@@ -17,9 +17,12 @@
</div>
<div>
<iframe style="position: absolute; top: 18px; right: 110px; height: 25px;" id="fancybox-frame" name="fancybox-frame1591155087436" frameborder="0" scrolling="no" hspace="0" src="http://i.tianqi.com/index.php?c=code&a=getcode&id=34&h=25&w=280"></iframe>
</div>
</div>
</div>
<div class="lr-lg-setting" id="lr_lg_setting">
<a href="javascript:void(0);" class="dropdown-toggle" data-toggle="dropdown" aria-expanded="false">[<span></span>]</a>
<ul class="dropdown-menu"></ul>
</div>



@* 即时通讯窗体 *@


+ 16
- 1
Learun.Framework.Ultimate V7/Learun.Application.Web/Views/Home/AdminDefault/index.css Ver fichero

@@ -358,7 +358,7 @@
text-align: center;
cursor: pointer;
z-index: 51;
display: none
display: none;
}

.lr-im-bell > i {
@@ -815,3 +815,18 @@
.lr-lg-setting span {
color: #3498DB
}



.photo .fa {
display: block;
font-size: 20px;
line-height: 30px;
height: 30px;
width: 30px;
border-radius: 5px;
margin: 0 auto;
text-align: center;
color: #fff;
background-color: #985CE2;
}

+ 4
- 0
Learun.Framework.Ultimate V7/Learun.Application.Web/Views/Home/AdminDefaultForDC.cshtml Ver fichero

@@ -19,6 +19,10 @@
<iframe style="position: absolute; top: 18px; right: 110px; height: 25px;" id="fancybox-frame" name="fancybox-frame1591155087436" frameborder="0" scrolling="no" hspace="0" src="http://i.tianqi.com/index.php?c=code&a=getcode&id=34&h=25&w=280"></iframe>
</div>
</div>
<div class="lr-lg-setting" id="lr_lg_setting">
<a href="javascript:void(0);" class="dropdown-toggle" data-toggle="dropdown" aria-expanded="false">[<span></span>]</a>
<ul class="dropdown-menu"></ul>
</div>


@* 即时通讯窗体 *@


+ 7
- 4
Learun.Framework.Ultimate V7/Learun.Application.Web/Views/Home/AdminNavigation.cshtml Ver fichero

@@ -17,7 +17,10 @@
</div>
<div><iframe style="position: absolute; top: 18px; right: 110px; height: 25px;" id="fancybox-frame" name="fancybox-frame1591155087436" frameborder="0" scrolling="no" hspace="0" src="http://i.tianqi.com/index.php?c=code&a=getcode&id=34&h=25&w=280"></iframe></div>
</div>

<div class="lr-lg-setting" id="lr_lg_setting">
<a href="javascript:void(0);" class="dropdown-toggle" data-toggle="dropdown" aria-expanded="false">[<span></span>]</a>
<ul class="dropdown-menu"></ul>
</div>


@* 即时通讯窗体 *@
@@ -35,8 +38,8 @@
<li><a href="javascript:void(0);" id="btn_tonggao"><i class="fa fa-paper-plane"></i>通告 @ViewBag.UnreadNews 条</a></li>
<li><a href="javascript:void(0);" id="btn_gongwen"><i class="fa fa-tag"></i>公文 @ViewBag.UnreadFile 条</a></li>
@*<li><a href="javascript:void(0);" id="btn_gongwen1"><i class="fa fa-quora"></i>未完成作业 2 条</a></li>
<li><a href="javascript:void(0);" id="btn_gongwen2"><i class="fa fa-anchor"></i>未批改作业 1 条</a></li>
<li><a href="javascript:void(0);" id="btn_gongwen3"><i class="fa fa-balance-scale"></i>备课任务 0 条</a></li>*@
<li><a href="javascript:void(0);" id="btn_gongwen2"><i class="fa fa-anchor"></i>未批改作业 1 条</a></li>
<li><a href="javascript:void(0);" id="btn_gongwen3"><i class="fa fa-balance-scale"></i>备课任务 0 条</a></li>*@
<li>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;共 @ViewBag.UnreadNum 条</li>
</ul>
</div>
@@ -77,7 +80,7 @@
</div>

<script>
var Ip = "@ViewBag.Ip";
var ACIp = "@ViewBag.ACIp";
var ACIp2 = "@ViewBag.ACIp2";


+ 4
- 0
Learun.Framework.Ultimate V7/Learun.Application.Web/Views/Home/AdminTop.cshtml Ver fichero

@@ -10,6 +10,10 @@
</div>
<div class="lr-frame-menu-btn" id="lr_frame_menu_btn"><i class="fa fa-fw fa-dedent"></i></div>
<div class="lr-second-menu-wrap"><div id="lr_second_menu_wrap"></div></div>
<div class="lr-lg-setting" id="lr_lg_setting">
<a href="javascript:void(0);" class="dropdown-toggle" data-toggle="dropdown" aria-expanded="false">[<span></span>]</a>
<ul class="dropdown-menu"></ul>
</div>

<div class="lr-im-bell" title="消息中心">
<span class="point"></span>


+ 186
- 125
Learun.Framework.Ultimate V7/Learun.Application.Web/Views/Home/AdminTop/Index.css Ver fichero

@@ -1,4 +1,11 @@
.lr-logo-title {
/*
* 版 本 Learun-ADMS V7.0.3 力软敏捷开发框架(http://www.learun.cn)
* Copyright (c) 2013-2018 上海力软信息技术有限公司
* 创建人:力软-前端开发组
* 日 期:2017.03.16
* 描 述:飞扬版样式
*/
.lr-logo-title {
display: block;
position: absolute;
top: 0;
@@ -9,24 +16,25 @@
text-decoration: none;
font-size: 18px;
white-space: nowrap;
line-height: 56px
line-height: 56px;
}

/*顶部*/
.lr-frame-top {
z-index: 3;
height: 60px;
background: #3286ed;
background-size: cover;
background-size: cover
background-size: cover;
}
/*菜单*/
.lr-frame-menu-wrap {
overflow: hidden
overflow: hidden;
}

.lr-first-menu-list {
white-space: nowrap;
height: 60px
height: 60px;
}

.lr-frame-menu {
@@ -34,13 +42,13 @@
height: 60px;
width: 100%;
z-index: 3;
padding: 0 143px 0 405px
padding: 0 143px 0 405px;
}

.lr-frame-menu li {
width: auto;
white-space: nowrap;
display: inline-block
display: inline-block;
}

.lr-frame-menu .lr-menu-item {
@@ -48,18 +56,19 @@
line-height: 60px;
font-size: 12px;
color: #fff;
padding: 0 19px 0 36px
padding: 0 19px 0 36px;
}

.lr-first-menu-list > li > .lr-menu-item.active, .lr-first-menu-list > li > .lr-menu-item:hover {
background-color: #156edb
.lr-first-menu-list > li > .lr-menu-item.active,
.lr-first-menu-list > li > .lr-menu-item:hover {
background-color: #156edb;
}

.lr-first-menu-list > li > .lr-menu-item > .lr-menu-item-icon {
display: block;
position: absolute;
top: 23px;
left: 14px
left: 14px;
}

.lr-first-menu-list > li > .lr-menu-item:before {
@@ -70,11 +79,12 @@
left: 0;
height: 36px;
width: 1px;
background-color: #156edb
background-color: #156edb;
}

.lr-first-menu-list > li.active + li > .lr-menu-item:before, .lr-first-menu-list > li:hover + li > .lr-menu-item:before {
display: none
.lr-first-menu-list > li.active + li > .lr-menu-item:before,
.lr-first-menu-list > li:hover + li > .lr-menu-item:before {
display: none;
}

.lr-second-menu-wrap {
@@ -86,46 +96,46 @@
background-color: #f8f8f8;
border-right: 1px solid #e1e2e2;
z-index: 2;
padding-top: 100px
padding-top: 100px;
}

.lr-second-menu-wrap > div {
position: relative;
height: 100%;
width: 100%
width: 100%;
}

.lr-second-menu-list .lr-menu-item {
height: 40px;
line-height: 40px;
color: #333;
padding: 0 0 0 20px;
font-size: 12px
padding: 0px 0px 0px 20px;
font-size: 12px;
}

.lr-second-menu-list .lr-menu-item:hover {
background-color: #ccc
background-color: #ccc;
}

.lr-second-menu-list .lr-menu-item-arrow .fa-angle-left {
position: absolute;
right: 15px;
top: 12px
top: 12px;
}

.lr-second-menu-list .open .lr-menu-item-arrow .fa-angle-left {
-webkit-transform: rotate(-90deg);
-ms-transform: rotate(-90deg);
-o-transform: rotate(-90deg);
transform: rotate(-90deg)
transform: rotate(-90deg);
}

.lr-three-menu-list {
display: block
display: block;
}

.lr-second-menu-list > li {
position: relative
position: relative;
}

.lr-second-menu-list > li:after {
@@ -137,38 +147,44 @@
margin-left: -70px;
width: 140px;
height: 1px;
background-color: #ccc
background-color: #ccc;
}

.lr-three-menu-list .lr-menu-item {
padding-left: 45px;
color: #666
color: #666;
}

.lr-four-menu-list .lr-menu-item {
padding-left: 60px;
color: #666;
}

/*tabs条*/
.lr-frame-tabs {
top: 60px;
padding: 0 30px 0 160px;
padding: 0px 30px 0px 160px;
background-color: #fff;
z-index: 1;
-webkit-box-shadow: 0 1px 3px rgba(0,0,0,.1);
box-shadow: 0 1px 3px rgba(0,0,0,.1);
border-bottom: 1px solid #d2d3d4;
height: 40px
height: 40px;
}

.lr-frame-tabs-wrap {
height: 40px
height: 40px;
}

.lr-frame-tabItem {
height: 39px;
line-height: 39px;
background: #fff;
margin-left: 0
margin-left: 0px;
}

.lr-frame-tabItem i {
color: #666
color: #666;
}

.lr-frame-tabItem.active:after {
@@ -179,50 +195,55 @@
left: 0;
height: 2px;
width: 100%;
background-color: #156edb
background-color: #156edb;
}

.lr-frame-tabItem.active .text {
font-weight: bold
font-weight: bold;
}

.lr-frame-tabItem .reomve {
top: 13px;
right: 4px
right: 4px;
}


/*个人设置和头像*/
.lr-frame-personCenter {
top: 0;
right: 10px;
height: 60px;
line-height: 60px
line-height: 60px;
}

.lr-frame-personCenter > a {
color: #fff
color: #fff;
}

.lr-frame-personCenter > .dropdown-toggle > img {
border: 2px solid #fff;
margin-top: 16px
margin-top: 16px;
}

.lr_frame_fullscreen {
top: 60px;
color: #666;
height: 39px;
line-height: 39px
line-height: 39px;
}

.lr_frame_fullscreen a {
color: #666
color: #666;
}

/*功能窗口*/
.lr-frame-main {
padding: 100px 0 0 160px;
background: #F0F3F4
padding: 100px 0px 0px 160px;
background: #F0F3F4;
}


/*风尚版独有-菜单缩进按钮*/
.lr-frame-menu-btn {
position: absolute;
left: 0;
@@ -237,28 +258,30 @@
opacity: .5;
background: #ededed;
border-bottom: 1px solid #ccc;
z-index: 3
z-index: 3;
}

.lr-frame-menu-btn:hover {
color: #999
color: #999;
}

/*导航缩进*/
.lr-menu-closed .lr-second-menu-wrap {
width: 50px
width: 50px;
}

.lr-menu-closed .lr-second-menu-wrap span, .lr-menu-closed .lr-second-menu-wrap .lr-menu-item-arrow {
display: none
.lr-menu-closed .lr-second-menu-wrap span,
.lr-menu-closed .lr-second-menu-wrap .lr-menu-item-arrow {
display: none;
}

.lr-menu-closed .lr-second-menu-wrap a {
padding: 0;
text-align: center
padding: 0px;
text-align: center;
}

.lr-menu-closed .lr-second-menu-wrap .lr-menu-item-icon {
margin: 0
margin: 0px;
}

.lr-menu-closed .lr-frame-menu-btn {
@@ -266,17 +289,18 @@
-ms-transform: rotate(-180deg);
-o-transform: rotate(-180deg);
transform: rotate(-180deg);
width: 50px
width: 50px;
}

.lr-menu-closed .lr-frame-main {
padding: 100px 0 0 50px
padding: 100px 0px 0px 50px;
}

.lr-menu-closed .lr-frame-tabs {
padding-left: 50px
padding-left: 50px;
}

/*即时通讯*/
.lr-im-bell {
position: fixed;
right: 105px;
@@ -288,11 +312,11 @@
text-align: center;
cursor: pointer;
z-index: 51;
display: none
display: none;
}

.lr-im-bell > i {
font-size: 20px
font-size: 20px;
}

.lr-im-bell > .point {
@@ -303,9 +327,10 @@
width: 8px;
height: 8px;
border-radius: 50%;
display: none
display: none;
}


.lr-im-body {
position: fixed;
right: 10px;
@@ -316,11 +341,11 @@
z-index: 50;
padding-top: 40px;
box-shadow: 0 0 10px 0 rgba(0,0,0,0.50);
display: none
display: none;
}

.lr-im-body.open {
display: block
display: block;
}

.lr-im-title {
@@ -330,9 +355,10 @@
background: #F8F8F8;
border-bottom: 1px solid #F8F8F8;
width: 100%;
height: 40px
height: 40px;
}


.lr-im-title .title-item {
position: absolute;
width: 50%;
@@ -343,16 +369,16 @@
color: #404040;
font-size: 14px;
line-height: 39px;
text-align: center
text-align: center;
}

.lr-im-title .title-item.active {
color: #3285ED;
background: #fff
background: #fff;
}

.lr-im-title .title-item.title-item-two {
left: 124px
left: 124px;
}

.lr-im-content {
@@ -360,24 +386,24 @@
width: 100%;
height: 100%;
display: none;
border-left: 0
border-left: 0;
}

.lr-im-content.active {
display: block
display: block;
}

.lr-im-msg-list {
position: relative;
width: 100%;
height: 100%
height: 100%;
}

.lr-im-msg-list .msg-item {
position: relative;
width: 100%;
height: 50px;
cursor: pointer
cursor: pointer;
}

.lr-im-msg-list .msg-item:after {
@@ -388,7 +414,20 @@
width: 100%;
background: #F8F8F8;
bottom: 0;
left: 0
left: 0;
}

.lr-im-msg-list .msg-item .remove {
position: absolute;
top: 0px;
left: 0px;
color: #333;
font-size: 12px;
display: none;
}

.lr-im-msg-list .msg-item:hover .remove {
display: block;
}

.lr-im-msg-list .msg-item .photo {
@@ -397,7 +436,7 @@
height: 30px;
border-radius: 50%;
top: 10px;
left: 10px
left: 10px;
}

.lr-im-msg-list .msg-item .icon {
@@ -411,7 +450,7 @@
background-color: #2B97DF;
color: #fff;
font-size: 18px;
text-align: center
text-align: center;
}

.lr-im-msg-list .msg-item .point {
@@ -422,13 +461,13 @@
position: absolute;
right: -4px;
top: -2px;
display: none
display: none;
}

.lr-im-msg-list .msg-item img {
width: 100%;
height: 100%;
border-radius: 50%
border-radius: 50%;
}

.lr-im-msg-list .msg-item .name {
@@ -436,11 +475,11 @@
top: 8px;
left: 50px;
height: 16px;
color: #333;
color: #333333;
font-size: 12px;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap
white-space: nowrap;
}

.lr-im-msg-list .msg-item .msg {
@@ -453,7 +492,7 @@
font-size: 12px;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap
white-space: nowrap;
}

.lr-im-msg-list .msg-item .date {
@@ -463,11 +502,12 @@
height: 16px;
color: #666;
font-size: 12px;
text-align: right
text-align: right;
}


.lr-im-userlist {
padding-top: 40px
padding-top: 40px;
}

.lr-im-search {
@@ -477,7 +517,7 @@
width: 100%;
height: 40px;
font-size: 0;
padding: 10px
padding: 10px;
}

.lr-im-search i {
@@ -487,7 +527,7 @@
font-size: 12px;
font-weight: 100;
color: #999;
z-index: 1
z-index: 1;
}

.lr-im-search input {
@@ -501,34 +541,35 @@
border-radius: 3px;
box-sizing: border-box;
color: #999;
outline: 0;
text-indent: 20px
outline: none;
text-indent: 20px;
}

.lr-im-search input::-webkit-input-placeholder {
text-align: center
text-align: center;
}

.lr-im-search input::-moz-placeholder {
text-align: center
.lr-im-search input::-moz-placeholder { /* Mozilla Firefox 19+ */
text-align: center;
}

.lr-im-search input:-moz-placeholder {
text-align: center
.lr-im-search input:-moz-placeholder { /* Mozilla Firefox 4 to 18 */
text-align: center;
}

.lr-im-search input:-ms-input-placeholder {
text-align: center
.lr-im-search input:-ms-input-placeholder { /* Internet Explorer 10-11 */
text-align: center;
}


.lr-im-content-userlist {
position: relative;
width: 100%;
height: 100%
height: 100%;
}

.lr-im-content-userlist .lr-scroll-box {
padding: 0 10px
padding: 0 10px;
}

.lr-im-item-name {
@@ -538,33 +579,34 @@
line-height: 30px;
cursor: pointer;
font-size: 12px;
color: #666
color: #666;
}

.lr-im-item-name > i {
color: #999;
font-size: 14px;
margin: 3px
margin: 3px;
}


.lr-im-item-name.open > i {
-webkit-transform: rotate(90deg);
-moz-transform: rotate(90deg);
-ms-transform: rotate(90deg);
-o-transform: rotate(90deg);
transform: rotate(90deg)
transform: rotate(90deg);
}

.lr-im-user-list {
position: relative;
width: 100%
width: 100%;
}

.lr-im-user {
position: relative;
height: 43px;
line-height: 43px;
padding-left: 40px
padding-left: 40px;
}

.lr-im-user > img {
@@ -573,7 +615,7 @@
left: 0;
width: 30px;
height: 30px;
border-radius: 50%
border-radius: 50%;
}

.lr-im-black-overlay {
@@ -585,11 +627,11 @@
overflow: hidden;
background: rgba(51,51,51,0.4);
z-index: 52;
display: none
display: none;
}

.lr-im-black-overlay.open {
display: block
display: block;
}

.lr-im-dialog {
@@ -604,7 +646,7 @@
border-radius: 3px;
box-shadow: 0 0 2px 0 rgba(0,0,0,0.50);
padding-top: 40px;
padding-bottom: 135px
padding-bottom: 135px;
}

.lr-im-header {
@@ -617,8 +659,8 @@
line-height: 39px;
padding-left: 10px;
font-size: 14px;
color: #333;
text-align: center
color: #333333;
text-align: center;
}

.lr-im-header .im-close {
@@ -632,13 +674,13 @@
cursor: pointer;
font-size: 12px;
color: #333;
font-weight: 100
font-weight: 100;
}

.lr-im-msgcontent {
position: relative;
width: 100%;
height: 100%
height: 100%;
}

.lr-im-msgcontent-tool {
@@ -651,11 +693,11 @@
bottom: 110px;
padding-right: 10px;
border-top: 1px solid #E5E5E5;
background: #F8F8F8
background: #F8F8F8;
}

.lr-im-msgcontent-tool > span {
cursor: pointer
cursor: pointer;
}

.lr-im-input {
@@ -664,7 +706,7 @@
left: 0;
width: 100%;
height: 110px;
border-top: 1px solid #E5E5E5
border-top: 1px solid #E5E5E5;
}

.lr-im-input .inp {
@@ -674,7 +716,7 @@
border: 0;
outline: 0;
padding: 5px;
background: transparent
background: transparent;
}

.lr-im-msgcontent .im-time {
@@ -685,14 +727,15 @@
height: 15px;
line-height: 15px;
text-align: left;
padding: 0 50px
padding: 0 50px;
}

.lr-im-msgcontent .me.im-time {
text-align: right
text-align: right;
}

.lr-im-msgcontent .im-me, .lr-im-msgcontent .im-other {
.lr-im-msgcontent .im-me,
.lr-im-msgcontent .im-other {
position: relative;
word-break: break-all;
height: auto;
@@ -700,11 +743,11 @@
width: 100%;
padding: 0 50px;
margin-bottom: 10px;
text-align: right
text-align: right;
}

.lr-im-msgcontent .im-other {
text-align: left
text-align: left;
}

.lr-im-msgcontent .im-other .headimg {
@@ -713,32 +756,34 @@
left: 10px;
width: 30px;
height: 30px;
border-radius: 50%
border-radius: 50%;
}

.lr-im-msgcontent .im-me img, .lr-im-msgcontent .im-other img {
.lr-im-msgcontent .im-me img,
.lr-im-msgcontent .im-other img {
width: 100%;
height: 100%;
border-radius: 50%
border-radius: 50%;
}

.lr-im-msgcontent .im-me .content, .lr-im-msgcontent .im-other .content {
.lr-im-msgcontent .im-me .content,
.lr-im-msgcontent .im-other .content {
display: inline-block;
background: #FFF;
background: #FFFFFF;
border: 1px solid #E5E5E5;
padding: 5px 13px 6px 19px;
font-size: 12px;
color: #333;
color: #333333;
box-sizing: border-box;
position: relative;
float: left;
max-width: 100%;
text-align: left;
line-height: 20px
line-height: 20px;
}

.lr-im-msgcontent .im-me .content {
float: right
float: right;
}

.lr-im-msgcontent .im-other .arrow {
@@ -757,7 +802,7 @@
z-index: 1;
clip: rect(0,8px,8px,0);
border-bottom: 0;
border-right: 0
border-right: 0;
}

.lr-im-msgcontent .im-me .headimg {
@@ -766,9 +811,10 @@
right: 10px;
width: 30px;
height: 30px;
border-radius: 50%
border-radius: 50%;
}


.lr-im-msgcontent .im-me .arrow {
width: 8px;
height: 8px;
@@ -785,30 +831,45 @@
z-index: 1;
clip: rect(0,8px,8px,0);
border-top: 0;
border-left: 0
border-left: 0;
}

.imHasMsg .point {
display: block
display: block;
}

/*语言设置*/
.lr-lg-setting {
position: absolute;
top: 21px;
left: 333px;
font-size: 14px;
z-index: 4;
color: #c6c6c6
color: #c6c6c6;
}

.lr-lg-setting > a {
color: #c6c6c6
color: #c6c6c6;
}

.lr-lg-setting span {
color: #fff
color: #fff;
}

.photo .fa {
display: block;
font-size: 20px;
line-height: 30px;
height: 30px;
width: 30px;
border-radius: 5px;
margin: 0 auto;
text-align: center;
color: #fff;
background-color: #985CE2;
}


.lr-menu-itemFour {
color: #666;
height: 40px;


+ 4
- 2
Learun.Framework.Ultimate V7/Learun.Application.Web/Views/Home/AdminWindos.cshtml Ver fichero

@@ -24,8 +24,10 @@
</div>
</div>



<div class="lr-lg-setting" id="lr_lg_setting">
<a href="javascript:void(0);" class="dropdown-toggle" data-toggle="dropdown" aria-expanded="false">[<span></span>]</a>
<ul class="dropdown-menu"></ul>
</div>

<div class="lr-im-body">
<div class="lr-im-title">


+ 218
- 155
Learun.Framework.Ultimate V7/Learun.Application.Web/Views/Home/AdminWindos/Index.css
La diferencia del archivo ha sido suprimido porque es demasiado grande
Ver fichero


+ 1
- 1
Learun.Framework.Ultimate V7/Learun.Application.Web/Views/LR_Content/plugin/scroll/scroll.js Ver fichero

@@ -110,7 +110,7 @@
// 监听鼠标滚动
$this.mousewheel(function (event, delta, deltaX, deltaY) {

console.log(delta);
//console.log(delta);

var $this = $(this);
var $select = $this.find('.lr-select-focus');


+ 139
- 0
Learun.Framework.Ultimate V7/Learun.Application.Web/Views/LR_Content/script/lr-language - 副本.js Ver fichero

@@ -0,0 +1,139 @@
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
/*
* 版 本 Learun-ADMS-Ultimate V7.0.0 数字化智慧校园(http://www.learun.cn)
* Copyright (c) 2013-2018 北京泉江科技有限公司
* 创建人:陈彬彬
* 日 期:2018.05.10
* 描 述:客户端语言包加载(菜单,tab条)
*/
(function (a, learun) {
var learunlanguage = "no";
var e = {};
var miancode = null;
var langobject = {};
var currlang = {};
var lang = {
get: function (i) {
if (localStorage) {
return JSON.parse(localStorage.getItem("lrlt_" + i)) || {}
} else {
return currlang[i] || {}
}
}, set: function (j, i) {
if (localStorage) {
localStorage.setItem("lrlt_" + j, JSON.stringify(i));
} else {
currlang[j] = i;
}
}
};
learun.language = {
getMainCode: function () {
return miancode;
}, get: function (l, i) {
if (learunlanguage != miancode) {
if (langobject[learunlanguage] && langobject[miancode]) {
var k = lang.get(miancode);
var j = lang.get(learunlanguage);
i(j.data[k.data[l]] || l);
} else {
setTimeout(function () {
learun.language.get(l, i);
},
200);
}
} else {
i(l);
}
}, getSyn: function (k) {
if (learunlanguage != miancode) {
var j = lang.get(miancode);
var i = lang.get(learunlanguage);
return i.data[j.data[k]] || k;
} else {
return k;
}
}
};
a(function () {
learunlanguage = top.$.cookie("learun_ADMS_V2_Language") || "no";
var i = a("#lr_lg_setting");
if (learunlanguage == "no") {
i.find("span").text("简体中文");
}
i.on("click",
"li>a",
function () {
var j = a(this).attr("data-value");
top.$.cookie("learun_ADMS_V2_Language",
j,
{
path: "/"
});
location.reload();
});
learun.httpAsyncGet(top.$.rootUrl + "/LR_LGManager/LGType/GetList",
function (m) {
if (m.code == 200) {
var j = i.find("ul");
a.each(m.data,
function (n, o) {
e[o.F_Code] = o.F_Name;
if (o.F_IsMain == 1) {
miancode = o.F_Code;
if (learunlanguage == "no") {
learunlanguage = miancode;
top.$.cookie("learun_ADMS_V2_Language",
learunlanguage,
{
path: "/"
});
}
}
langobject[o.F_Code] = false;
var p = '<li><a href="javascript:void(0);" data-value="' +
o.F_Code +
'" >' +
o.F_Name +
"</a></li>";
j.append(p)
});
i.find("span").text(e[learunlanguage]);
if (learunlanguage != miancode) {
var l = lang.get(miancode);
var k = lang.get(learunlanguage);
learun.httpAsyncGet(
top.$.rootUrl +
"/LR_LGManager/LGMap/GetLanguageByCode?typeCode=" +
miancode +
"&ver=" +
l.ver +
"&isMain=true",
function (n) {
if (n.code == 200) {
if (n.info != "no update") {
lang.set(miancode, n.data);
}
}
langobject[miancode] = true;
});
learun.httpAsyncGet(
top.$.rootUrl +
"/LR_LGManager/LGMap/GetLanguageByCode?typeCode=" +
learunlanguage +
"&ver=" +
k.ver +
"&isMain=false",
function (n) {
if (n.code == 200) {
if (n.info != "no update") {
lang.set(learunlanguage, n.data);
}
}
langobject[learunlanguage] = true;
});
}
}
});
});
})(window.jQuery, top.learun);

+ 119
- 117
Learun.Framework.Ultimate V7/Learun.Application.Web/Views/LR_Content/script/lr-language.js Ver fichero

@@ -1,139 +1,141 @@
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
/*
* 版 本 Learun-ADMS-Ultimate V7.0.0 数字化智慧校园(http://www.learun.cn)
* Copyright (c) 2013-2018 北京泉江科技有限公司
* 创建人:陈彬彬
/*
* 版 本 Learun-ADMS V7.0.3 力软敏捷开发框架(http://www.learun.cn)
* Copyright (c) 2013-2018 上海力软信息技术有限公司
* 创建人:力软-前端开发组
* 日 期:2018.05.10
* 描 述:客户端语言包加载(菜单,tab条)
*/
(function (a, learun) {
var learunlanguage = "no";
var e = {};
var miancode = null;
var langobject = {};
var currlang = {};
var lang = {
get: function (i) {
(function ($, learun) {
"use strict";

var type = 'no';
var lgTypeList = {};
var mainType = null;

var isRead = {};

var lgData = {};

var storage = {
get: function (name) {
if (localStorage) {
return JSON.parse(localStorage.getItem("lrlt_" + i)) || {}
} else {
return currlang[i] || {}
return JSON.parse(localStorage.getItem('lrlg_' + name)) || {};
}
}, set: function (j, i) {
else {
return lgData[name] || {};
}
},
set: function (name, data) {
if (localStorage) {
localStorage.setItem("lrlt_" + j, JSON.stringify(i));
} else {
currlang[j] = i;
localStorage.setItem('lrlg_' + name, JSON.stringify(data));
}
else {
lgData[name] = data;
}
}
};
learun.language = {
getMainCode: function () {
return miancode;
}, get: function (l, i) {
if (learunlanguage != miancode) {
if (langobject[learunlanguage] && langobject[miancode]) {
var k = lang.get(miancode);
var j = lang.get(learunlanguage);
i(j.data[k.data[l]] || l);
} else {
return mainType;
},
get: function (text, callback) {
// 判断当前客户端的语言版本
if (type != mainType) {
// 判断当前语言包是否加载完成
if (isRead[type] && isRead[mainType]) {
var mdata = storage.get(mainType);
var cdata = storage.get(type);

callback(cdata.data[mdata.data[text]] || text);
}
else {
setTimeout(function () {
learun.language.get(l, i);
},
200);
learun.language.get(text, callback);
}, 200);
}
} else {
i(l);
}
}, getSyn: function (k) {
if (learunlanguage != miancode) {
var j = lang.get(miancode);
var i = lang.get(learunlanguage);
return i.data[j.data[k]] || k;
} else {
return k;
else {
callback(text);
}
},
getSyn: function (text) {
// 判断当前客户端的语言版本
if (type != mainType) {
var mdata = storage.get(mainType);
var cdata = storage.get(type);
return cdata.data[mdata.data[text]] || text;
}
else {
return text;
}
}
};
a(function () {
learunlanguage = top.$.cookie("learun_ADMS_V2_Language") || "no";
var i = a("#lr_lg_setting");
if (learunlanguage == "no") {
i.find("span").text("简体中文");
$(function () {
type = top.$.cookie('Learn_ADMS_V7_Language') || 'no';

var $setting = $('#lr_lg_setting');
if (type == 'no') {
$setting.find('span').text('简体中文');
}
i.on("click",
"li>a",
function () {
var j = a(this).attr("data-value");
top.$.cookie("learun_ADMS_V2_Language",
j,
{
path: "/"

$setting.on('click', 'li>a', function () {
var code = $(this).attr('data-value');
top.$.cookie('Learn_ADMS_V7_Language', code, { path: "/" });
location.reload();
});

// 获取当前语言类型
learun.httpAsyncGet(top.$.rootUrl + '/LR_LGManager/LGType/GetList', function (res) {
if (res.code == 200) {
var $ul = $setting.find('ul');

$.each(res.data, function (_index, _item) {
lgTypeList[_item.F_Code] = _item.F_Name;
if (_item.F_IsMain == 1) {
mainType = _item.F_Code;
if (type == 'no') {
type = mainType;
top.$.cookie('Learn_ADMS_V7_Language', type, { path: "/" });
}
}
isRead[_item.F_Code] = false;

var html = '<li><a href="javascript:void(0);" data-value="' + _item.F_Code + '" >' + _item.F_Name + '</a></li>';
$ul.append(html);
});
$setting.find('span').text(lgTypeList[type]);


// 开始加载语言包,如果当前设置的语言不是主语言的话

if (type != mainType) {
// 加载主语言包和当前设置的语言包
var mlgdata = storage.get(mainType);
var lgdata = storage.get(type);

learun.httpAsyncGet(top.$.rootUrl + '/LR_LGManager/LGMap/GetLanguageByCode?typeCode=' + mainType + '&ver=' + mlgdata.ver + '&isMain=true', function (res) {
if (res.code == 200) {
if (res.info != 'no update') {
storage.set(mainType, res.data);
}
}
isRead[mainType] = true;
});
location.reload();
});
learun.httpAsyncGet(top.$.rootUrl + "/LR_LGManager/LGType/GetList",
function (m) {
if (m.code == 200) {
var j = i.find("ul");
a.each(m.data,
function (n, o) {
e[o.F_Code] = o.F_Name;
if (o.F_IsMain == 1) {
miancode = o.F_Code;
if (learunlanguage == "no") {
learunlanguage = miancode;
top.$.cookie("learun_ADMS_V2_Language",
learunlanguage,
{
path: "/"
});
}

learun.httpAsyncGet(top.$.rootUrl + '/LR_LGManager/LGMap/GetLanguageByCode?typeCode=' + type + '&ver=' + lgdata.ver + '&isMain=false', function (res) {
if (res.code == 200) {
if (res.info != 'no update') {
storage.set(type, res.data);
}
langobject[o.F_Code] = false;
var p = '<li><a href="javascript:void(0);" data-value="' +
o.F_Code +
'" >' +
o.F_Name +
"</a></li>";
j.append(p)
});
i.find("span").text(e[learunlanguage]);
if (learunlanguage != miancode) {
var l = lang.get(miancode);
var k = lang.get(learunlanguage);
learun.httpAsyncGet(
top.$.rootUrl +
"/LR_LGManager/LGMap/GetLanguageByCode?typeCode=" +
miancode +
"&ver=" +
l.ver +
"&isMain=true",
function (n) {
if (n.code == 200) {
if (n.info != "no update") {
lang.set(miancode, n.data);
}
}
langobject[miancode] = true;
});
learun.httpAsyncGet(
top.$.rootUrl +
"/LR_LGManager/LGMap/GetLanguageByCode?typeCode=" +
learunlanguage +
"&ver=" +
k.ver +
"&isMain=false",
function (n) {
if (n.code == 200) {
if (n.info != "no update") {
lang.set(learunlanguage, n.data);
}
}
langobject[learunlanguage] = true;
});
}
}
isRead[type] = true;
});

}
});
}
});
});
})(window.jQuery, top.learun);


})(window.jQuery, top.learun);

+ 2
- 2
Learun.Framework.Ultimate V7/Learun.Application.Web/Views/Login/Default/Index.js Ver fichero

@@ -157,8 +157,8 @@
window.location.href = DigitalschoolMisLoginurl + "?F_Account=" + username + "&returnurl=" + Returnurl + "/Home/Index?pwd=true";
}
else
//window.location.href = DigitalschoolMisLoginurl + "?F_Account=" + username + "&returnurl=" + Returnurl + "/Home/Index";
window.location.href = "/Home/Index";
window.location.href = DigitalschoolMisLoginurl + "?F_Account=" + username + "&returnurl=" + Returnurl + "/Home/Index";
//window.location.href = "/Home/Index";
}
}
else if (res.code == 400) {


+ 10
- 0
Learun.Framework.Ultimate V7/Learun.Application.Web/Views/UserCenter/Index.cshtml Ver fichero

@@ -24,6 +24,7 @@
{
<li data-value="6">选修流程</li>
}
<li data-value="7">语言设置</li>
</ul>
</div>
</div>
@@ -747,6 +748,15 @@
</div>

}

<div class="lr-layout-wrap-item" id="lr_layout_item7">
<div class="title">
<div>语言设置</div>
</div>
<div class="content" style="padding-top:20px;">
<iframe class="lr-layout-iframe" frameborder="0" src="~/UserCenter/LanguageForm"></iframe>
</div>
</div>
</div>
</div>
</div>


+ 13
- 0
Learun.Framework.Ultimate V7/Learun.Application.Web/Views/UserCenter/LanguageForm.cshtml Ver fichero

@@ -0,0 +1,13 @@
@{
ViewBag.Title = "个人中心-语言设置";
Layout = "~/Views/Shared/_Form.cshtml";
}
@Html.AppendCssFile("/Views/UserCenter/LanguageForm.css")
<div class="lr-form-wrap" id="form">
<div class="lr-form-item">
<div class="lr-form-item-title">客户端语言</div>
<div id="Setting"></div>
</div>
<div class="lr-form-item"><a class="btn btn-primary" id="lr_save_btn"><i class="fa fa-save"></i>&nbsp;保&nbsp;存</a></div>
</div>
@Html.AppendJsFile("/Views/UserCenter/LanguageForm.js")

+ 19
- 0
Learun.Framework.Ultimate V7/Learun.Application.Web/Views/UserCenter/LanguageForm.css Ver fichero

@@ -0,0 +1,19 @@
.lr-form-wrap {
padding: 0;
}

.lr-form-item {
width: 500px;
padding: 5px 0 5px 80px;
float: initial;
}

.lr-form-item-title {
width: 80px;
text-align: left;
padding-right: 10px;
}

.form-control {
border-radius: 4px;
}

+ 35
- 0
Learun.Framework.Ultimate V7/Learun.Application.Web/Views/UserCenter/LanguageForm.js Ver fichero

@@ -0,0 +1,35 @@
/*
* 版 本 Learun-ADMS V7.0.3 力软敏捷开发框架(http://www.learun.cn)
* Copyright (c) 2013-2018 上海力软信息技术有限公司
* 创建人:力软-前端开发组
* 日 期:2018.05.09
* 描 述:个人中心-语言设置
*/
var bootstrap = function ($, learun) {
"use strict";

var page = {
init: function () {
page.bind();
},
bind: function () {
$('#Setting').lrselect({
url: top.$.rootUrl + '/LR_LGManager/LGType/GetList',
value: 'F_Code',
text: 'F_Name',
title: 'F_Name'
});
var code = top.$.cookie('Learn_ADMS_V7_Language') || learun.language.getMainCode();
$('#Setting').lrselectSet(code);

$('#lr_save_btn').on('click', function () {
var formData = $('#form').lrGetFormData();
top.$.cookie('Learn_ADMS_V7_Language', formData.Setting, { path: "/" });

learun.alert.success('设置成功');

});
}
};
page.init();
}

+ 2
- 2
Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.Mapping/LR_LGManager/LR_Lg_MapMap.cs Ver fichero

@@ -1,4 +1,4 @@
using Learun.Application.TwoDevelopment.LR_LGManager;
using Learun.Application.Language;
using System.Data.Entity.ModelConfiguration;

namespace Learun.Application.Mapping
@@ -10,7 +10,7 @@ namespace Learun.Application.Mapping
/// 日 期:2018-09-29 14:51
/// 描 述:语言映射
/// </summary>
public class LgMapMap : EntityTypeConfiguration<LgMapEntity>
public class LgMapMap : EntityTypeConfiguration<LGMapEntity>
{
public LgMapMap()
{


+ 2
- 2
Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.Mapping/LR_LGManager/LR_Lg_TypeMap.cs Ver fichero

@@ -1,4 +1,4 @@
using Learun.Application.TwoDevelopment.LR_LGManager;
using Learun.Application.Language;
using System.Data.Entity.ModelConfiguration;

namespace Learun.Application.Mapping
@@ -10,7 +10,7 @@ namespace Learun.Application.Mapping
/// 日 期:2018-09-29 15:01
/// 描 述:多语言映射
/// </summary>
public class LgTypeMap : EntityTypeConfiguration<LgTypeEntity>
public class LgTypeMap : EntityTypeConfiguration<LGTypeEntity>
{
public LgTypeMap()
{


+ 4
- 0
Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.Mapping/Learun.Application.Mapping.csproj Ver fichero

@@ -571,6 +571,10 @@
<Project>{db34dfc9-7227-41fa-88aa-832dbf247811}</Project>
<Name>Learun.Application.IM</Name>
</ProjectReference>
<ProjectReference Include="..\Learun.Application.Language\Learun.Application.Language.csproj">
<Project>{36083FBB-CE7F-4EE0-8459-C4B60A2DD070}</Project>
<Name>Learun.Application.Language</Name>
</ProjectReference>
<ProjectReference Include="..\Learun.Application.Message\Learun.Application.Message.csproj">
<Project>{211fa31a-b9d8-4f48-80cc-573b9410828e}</Project>
<Name>Learun.Application.Message</Name>


+ 0
- 143
Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/LR_LGManager/LGMap/LGMapBLL.cs Ver fichero

@@ -1,143 +0,0 @@
using Learun.Util;
using System;
using System.Data;
using System.Collections.Generic;

namespace Learun.Application.TwoDevelopment.LR_LGManager
{
/// <summary>
/// 版 本 Learun-ADMS-Ultimate V7.0.0 数字化智慧校园
/// Copyright (c) 2013-2018 北京泉江科技有限公司
/// 创 建:超级管理员
/// 日 期:2018-09-29 14:51
/// 描 述:语言映射
/// </summary>
public class LGMapBLL : LGMapIBLL
{
private LGMapService lGMapService = new LGMapService();

#region 获取数据

/// <summary>
/// 获取页面显示列表数据
/// <summary>
/// <param name="queryJson">查询参数</param>
/// <returns></returns>
public DataTable GetPageList(Pagination pagination, string queryJson,string typeList)
{
try
{
return lGMapService.GetPageList(pagination, queryJson,typeList);
}
catch (Exception ex)
{
if (ex is ExceptionEx)
{
throw;
}
else
{
throw ExceptionEx.ThrowBusinessException(ex);
}
}
}

/// <summary>
/// 获取LR_Lg_Map表实体数据
/// <param name="keyValue">主键</param>
/// <summary>
/// <returns></returns>
public LgMapEntity GetLR_Lg_MapEntity(string keyValue)
{
try
{
return lGMapService.GetLR_Lg_MapEntity(keyValue);
}
catch (Exception ex)
{
if (ex is ExceptionEx)
{
throw;
}
else
{
throw ExceptionEx.ThrowBusinessException(ex);
}
}
}

#endregion

#region 提交数据

/// <summary>
/// 删除实体数据
/// <param name="keyValue">主键</param>
/// <summary>
/// <returns></returns>
public void DeleteEntity(string keyValue)
{
try
{
lGMapService.DeleteEntity(keyValue);
}
catch (Exception ex)
{
if (ex is ExceptionEx)
{
throw;
}
else
{
throw ExceptionEx.ThrowBusinessException(ex);
}
}
}

/// <summary>
/// 保存实体数据(新增、修改)
/// <param name="keyValue">主键</param>
/// <summary>
/// <returns></returns>
public void SaveEntity(string keyValue, LgMapEntity entity)
{
try
{
lGMapService.SaveEntity(keyValue, entity);
}
catch (Exception ex)
{
if (ex is ExceptionEx)
{
throw;
}
else
{
throw ExceptionEx.ThrowBusinessException(ex);
}
}
}

public IEnumerable<LgMapEntity> GetList(string queryJson)
{
try
{
return lGMapService.GetList(queryJson);
}
catch (Exception ex)
{
if (ex is ExceptionEx)
{
throw;
}
else
{
throw ExceptionEx.ThrowBusinessException(ex);
}
}
}

#endregion

}
}

+ 0
- 50
Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/LR_LGManager/LGMap/LGMapIBLL.cs Ver fichero

@@ -1,50 +0,0 @@
using Learun.Util;
using System.Data;
using System.Collections.Generic;

namespace Learun.Application.TwoDevelopment.LR_LGManager
{
/// <summary>
/// 版 本 Learun-ADMS-Ultimate V7.0.0 数字化智慧校园
/// Copyright (c) 2013-2018 北京泉江科技有限公司
/// 创 建:超级管理员
/// 日 期:2018-09-29 14:51
/// 描 述:语言映射
/// </summary>
public interface LGMapIBLL
{
#region 获取数据

/// <summary>
/// 获取页面显示列表数据
/// <summary>
/// <param name="queryJson">查询参数</param>
/// <returns></returns>
DataTable GetPageList(Pagination pagination, string queryJson,string typeList);
/// <summary>
/// 获取LR_Lg_Map表实体数据
/// <param name="keyValue">主键</param>
/// <summary>
/// <returns></returns>
LgMapEntity GetLR_Lg_MapEntity(string keyValue);
#endregion

#region 提交数据

/// <summary>
/// 删除实体数据
/// <param name="keyValue">主键</param>
/// <summary>
/// <returns></returns>
void DeleteEntity(string keyValue);
/// <summary>
/// 保存实体数据(新增、修改)
/// <param name="keyValue">主键</param>
/// <summary>
/// <returns></returns>
void SaveEntity(string keyValue, LgMapEntity entity);
IEnumerable<LgMapEntity> GetList(string queryJson);
#endregion

}
}

+ 0
- 216
Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/LR_LGManager/LGMap/LGMapService.cs Ver fichero

@@ -1,216 +0,0 @@
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.LR_LGManager
{
/// <summary>
/// 版 本 Learun-ADMS-Ultimate V7.0.0 数字化智慧校园
/// Copyright (c) 2013-2018 北京泉江科技有限公司
/// 创 建:超级管理员
/// 日 期:2018-09-29 14:51
/// 描 述:语言映射
/// </summary>
public class LGMapService : RepositoryFactory
{
#region 获取数据

/// <summary>
/// 获取页面显示列表数据
/// <summary>
/// <param name="queryJson">查询参数</param>
/// <returns></returns>
public DataTable GetPageList(Pagination pagination, string queryJson, string typeList)
{
try
{
var lgs = typeList.Split(',');
var strSql = new StringBuilder();
strSql.Append(" select F_Code, ");

for (int i = 0; i < lgs.Length; i++)
{
if (i == lgs.Length - 1)
{
strSql.Append($" MAX( case f_typecode when '{lgs[i]}' then f_name end ){lgs[i]}");

}
else
{
strSql.Append($" MAX( case f_typecode when '{lgs[i]}' then f_name end ){lgs[i]} ,");
}
}

strSql.Append(" From dbo.LR_Lg_Map");
strSql.Append(" WHERE 1=1 ");

var queryParam = queryJson.ToJObject();
// 虚拟参数
var dp = new DynamicParameters(new { });

strSql.Append(" group by F_Code");
return this.BaseRepository().FindTable(strSql.ToString(), dp, pagination);

//return this.BaseRepository().FindList<LgMapEntity>(strSql.ToString(), dp, pagination);
}
catch (Exception ex)
{
if (ex is ExceptionEx)
{
throw;
}
else
{
throw ExceptionEx.ThrowServiceException(ex);
}
}
}

/// <summary>
/// 获取LR_Lg_Map表实体数据
/// <param name="keyValue">主键</param>
/// <summary>
/// <returns></returns>
public LgMapEntity GetLR_Lg_MapEntity(string keyValue)
{
try
{
return this.BaseRepository().FindEntity<LgMapEntity>(keyValue);
}
catch (Exception ex)
{
if (ex is ExceptionEx)
{
throw;
}
else
{
throw ExceptionEx.ThrowServiceException(ex);
}
}
}

#endregion

#region 提交数据

/// <summary>
/// 删除实体数据
/// <param name="keyValue">主键</param>
/// <summary>
/// <returns></returns>
public void DeleteEntity(string keyValue)
{
try
{
this.BaseRepository().Delete<LgMapEntity>(t => t.F_Id == keyValue);
}
catch (Exception ex)
{
if (ex is ExceptionEx)
{
throw;
}
else
{
throw ExceptionEx.ThrowServiceException(ex);
}
}
}

/// <summary>
/// 保存实体数据(新增、修改)
/// <param name="keyValue">主键</param>
/// <summary>
/// <returns></returns>
public void SaveEntity(string keyValue, LgMapEntity entity)
{
try
{
if (!string.IsNullOrEmpty(keyValue))
{
entity.Modify(keyValue);
this.BaseRepository().Update(entity);
}
else
{
entity.Create();
this.BaseRepository().Insert(entity);
}
}
catch (Exception ex)
{
if (ex is ExceptionEx)
{
throw;
}
else
{
throw ExceptionEx.ThrowServiceException(ex);
}
}
}

#endregion

/// <summary>
/// 根据queryjson 查询数据库信息
/// </summary>
/// <param name="queryJson">The query json.</param>
/// <returns>IEnumerable&lt;LR_Lg_MapEntity&gt;.</returns>
public IEnumerable<LgMapEntity> GetList(string queryJson)
{
try
{
var strSql = new StringBuilder();
strSql.Append("SELECT ");
strSql.Append(@"
t.F_Code,
t.F_ID,
t.F_Name,
t.F_TypeCode


");
strSql.Append(" FROM LR_Lg_Map t ");
strSql.Append(" WHERE 1=1 ");
var queryParam = queryJson.ToJObject();
// 虚拟参数
var dp = new DynamicParameters(new { });
if (!queryParam["F_Code"].IsEmpty())
{
dp.Add("F_Code", queryParam["F_Code"].ToString(), dbType: DbType.String);
strSql.Append(" AND t.F_Code= @F_Code ");
}
if (!queryParam["F_Name"].IsEmpty())
{
dp.Add("F_Name", queryParam["F_Name"].ToString(), dbType: DbType.String);
strSql.Append(" AND t.F_Name= @F_Name ");
}
if (!queryParam["F_TypeCode"].IsEmpty())
{
dp.Add("F_TypeCode", queryParam["F_TypeCode"].ToString(), dbType: DbType.String);
strSql.Append(" AND t.F_TypeCode= @F_TypeCode ");
}
return this.BaseRepository().FindList<LgMapEntity>(strSql.ToString(), dp);
}
catch (Exception ex)
{
if (ex is ExceptionEx)
{
throw;
}
else
{
throw ExceptionEx.ThrowServiceException(ex);
}
}
}
}
}

+ 0
- 60
Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/LR_LGManager/LGMap/LR_Lg_MapEntity.cs Ver fichero

@@ -1,60 +0,0 @@
using Learun.Util;
using System;
using System.ComponentModel.DataAnnotations.Schema;

namespace Learun.Application.TwoDevelopment.LR_LGManager
{
/// <summary>
/// 版 本 Learun-ADMS-Ultimate V7.0.0 数字化智慧校园
/// Copyright (c) 2013-2018 北京泉江科技有限公司
/// 创 建:超级管理员
/// 日 期:2018-09-29 14:51
/// 描 述:语言映射
/// </summary>
public class LgMapEntity
{
#region 实体成员
/// <summary>
/// 主键
/// </summary>
[Column("F_ID")]
public string F_Id { get; set; }
/// <summary>
/// 显示内容
/// </summary>
[Column("F_NAME")]
public string F_Name { get; set; }
/// <summary>
/// 编码(系统自动产生,作为关联项)
/// </summary>
[Column("F_CODE")]
public string F_Code { get; set; }
/// <summary>
/// 对应语言显示编码
/// </summary>
[Column("F_TYPECODE")]
public string F_TypeCode { get; set; }
#endregion

#region 扩展操作
/// <summary>
/// 新增调用
/// </summary>
public void Create()
{
this.F_Id = Guid.NewGuid().ToString();
}
/// <summary>
/// 编辑调用
/// </summary>
/// <param name="keyValue"></param>
public void Modify(string keyValue)
{
this.F_Id = keyValue;
}
#endregion
#region 扩展字段
#endregion
}
}


+ 0
- 144
Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/LR_LGManager/LGType/LGTypeBLL.cs Ver fichero

@@ -1,144 +0,0 @@
using Learun.Util;
using System;
using System.Data;
using System.Collections.Generic;

namespace Learun.Application.TwoDevelopment.LR_LGManager
{
/// <summary>
/// 版 本 Learun-ADMS-Ultimate V7.0.0 数字化智慧校园
/// Copyright (c) 2013-2018 北京泉江科技有限公司
/// 创 建:超级管理员
/// 日 期:2018-09-29 15:01
/// 描 述:多语言映射
/// </summary>
public class LGTypeBLL : LGTypeIBLL
{
private LGTypeService lGTypeService = new LGTypeService();

#region 获取数据

/// <summary>
/// 获取页面显示列表数据
/// <summary>
/// <param name="queryJson">查询参数</param>
/// <returns></returns>
public IEnumerable<LgTypeEntity> GetPageList(Pagination pagination, string queryJson)
{
try
{
return lGTypeService.GetPageList(pagination, queryJson);
}
catch (Exception ex)
{
if (ex is ExceptionEx)
{
throw;
}
else
{
throw ExceptionEx.ThrowBusinessException(ex);
}
}
}

/// <summary>
/// 获取LR_Lg_Type表实体数据
/// <param name="keyValue">主键</param>
/// <summary>
/// <returns></returns>
public LgTypeEntity GetLR_Lg_TypeEntity(string keyValue)
{
try
{
return lGTypeService.GetLR_Lg_TypeEntity(keyValue);
}
catch (Exception ex)
{
if (ex is ExceptionEx)
{
throw;
}
else
{
throw ExceptionEx.ThrowBusinessException(ex);
}
}
}

#endregion

#region 提交数据

/// <summary>
/// 删除实体数据
/// <param name="keyValue">主键</param>
/// <summary>
/// <returns></returns>
public void DeleteEntity(string keyValue)
{
try
{
lGTypeService.DeleteEntity(keyValue);
}
catch (Exception ex)
{
if (ex is ExceptionEx)
{
throw;
}
else
{
throw ExceptionEx.ThrowBusinessException(ex);
}
}
}

/// <summary>
/// 保存实体数据(新增、修改)
/// <param name="keyValue">主键</param>
/// <summary>
/// <returns></returns>
public void SaveEntity(string keyValue, LgTypeEntity entity)
{
try
{
lGTypeService.SaveEntity(keyValue, entity);
}
catch (Exception ex)
{
if (ex is ExceptionEx)
{
throw;
}
else
{
throw ExceptionEx.ThrowBusinessException(ex);
}
}
}

public IEnumerable<LgTypeEntity> GetList(string quJson)
{
try
{
return lGTypeService.GetList(quJson);
}
catch (Exception ex)
{
if (ex is ExceptionEx)
{
throw;
}
else
{
throw ExceptionEx.ThrowBusinessException(ex);
}
}
}

#endregion

}
}

+ 0
- 50
Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/LR_LGManager/LGType/LGTypeIBLL.cs Ver fichero

@@ -1,50 +0,0 @@
using Learun.Util;
using System.Data;
using System.Collections.Generic;

namespace Learun.Application.TwoDevelopment.LR_LGManager
{
/// <summary>
/// 版 本 Learun-ADMS-Ultimate V7.0.0 数字化智慧校园
/// Copyright (c) 2013-2018 北京泉江科技有限公司
/// 创 建:超级管理员
/// 日 期:2018-09-29 15:01
/// 描 述:多语言映射
/// </summary>
public interface LGTypeIBLL
{
#region 获取数据

/// <summary>
/// 获取页面显示列表数据
/// <summary>
/// <param name="queryJson">查询参数</param>
/// <returns></returns>
IEnumerable<LgTypeEntity> GetPageList(Pagination pagination, string queryJson);
/// <summary>
/// 获取LR_Lg_Type表实体数据
/// <param name="keyValue">主键</param>
/// <summary>
/// <returns></returns>
LgTypeEntity GetLR_Lg_TypeEntity(string keyValue);
#endregion

#region 提交数据

/// <summary>
/// 删除实体数据
/// <param name="keyValue">主键</param>
/// <summary>
/// <returns></returns>
void DeleteEntity(string keyValue);
/// <summary>
/// 保存实体数据(新增、修改)
/// <param name="keyValue">主键</param>
/// <summary>
/// <returns></returns>
void SaveEntity(string keyValue, LgTypeEntity entity);
#endregion

IEnumerable<LgTypeEntity> GetList(string quJson);
}
}

+ 0
- 182
Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/LR_LGManager/LGType/LGTypeService.cs Ver fichero

@@ -1,182 +0,0 @@
using Dapper;
using Learun.DataBase.Repository;
using Learun.Util;
using System;
using System.Collections.Generic;
using System.Data;
using System.Text;
using Learun.Application.TwoDevelopment.LR_Desktop;

namespace Learun.Application.TwoDevelopment.LR_LGManager
{
/// <summary>
/// 版 本 Learun-ADMS-Ultimate V7.0.0 数字化智慧校园
/// Copyright (c) 2013-2018 北京泉江科技有限公司
/// 创 建:超级管理员
/// 日 期:2018-09-29 15:01
/// 描 述:多语言映射
/// </summary>
public class LGTypeService : RepositoryFactory
{
#region 获取数据

/// <summary>
/// 获取页面显示列表数据
/// <summary>
/// <param name="queryJson">查询参数</param>
/// <returns></returns>
public IEnumerable<LgTypeEntity> GetPageList(Pagination pagination, string queryJson)
{
try
{
var strSql = new StringBuilder();
strSql.Append("SELECT ");
strSql.Append(@"
t.F_Id,
t.F_Name,
t.F_Code,
t.F_IsMain
");
strSql.Append(" FROM LR_Lg_Type t ");
strSql.Append(" WHERE 1=1 ");
var queryParam = queryJson.ToJObject();
// 虚拟参数
var dp = new DynamicParameters(new { });
return this.BaseRepository().FindList<LgTypeEntity>(strSql.ToString(),dp, pagination);
}
catch (Exception ex)
{
if (ex is ExceptionEx)
{
throw;
}
else
{
throw ExceptionEx.ThrowServiceException(ex);
}
}
}

/// <summary>
/// 获取LR_Lg_Type表实体数据
/// <param name="keyValue">主键</param>
/// <summary>
/// <returns></returns>
public LgTypeEntity GetLR_Lg_TypeEntity(string keyValue)
{
try
{
return this.BaseRepository().FindEntity<LgTypeEntity>(keyValue);
}
catch (Exception ex)
{
if (ex is ExceptionEx)
{
throw;
}
else
{
throw ExceptionEx.ThrowServiceException(ex);
}
}
}

#endregion

#region 提交数据

/// <summary>
/// 删除实体数据
/// <param name="keyValue">主键</param>
/// <summary>
/// <returns></returns>
public void DeleteEntity(string keyValue)
{
try
{
this.BaseRepository().Delete<LgTypeEntity>(t=>t.F_Id == keyValue);
}
catch (Exception ex)
{
if (ex is ExceptionEx)
{
throw;
}
else
{
throw ExceptionEx.ThrowServiceException(ex);
}
}
}

/// <summary>
/// 保存实体数据(新增、修改)
/// <param name="keyValue">主键</param>
/// <summary>
/// <returns></returns>
public void SaveEntity(string keyValue, LgTypeEntity entity)
{
try
{
if (!string.IsNullOrEmpty(keyValue))
{
entity.Modify(keyValue);
this.BaseRepository().Update(entity);
}
else
{
entity.Create();
this.BaseRepository().Insert(entity);
}
}
catch (Exception ex)
{
if (ex is ExceptionEx)
{
throw;
}
else
{
throw ExceptionEx.ThrowServiceException(ex);
}
}
}

#endregion

public IEnumerable<LgTypeEntity> GetList(string queryJson)
{
try
{
var strSql = new StringBuilder();
strSql.Append("SELECT ");
strSql.Append(@"
t.F_Code,
t.F_ID,
t.F_isMain,
t.F_Name
");
strSql.Append(" FROM LR_Lg_Type t ");
strSql.Append(" WHERE 1=1 order by t.F_isMain DESC ");
var queryParam = queryJson.ToJObject();
// 虚拟参数
var dp = new DynamicParameters(new { });
return this.BaseRepository().FindList<LgTypeEntity>(strSql.ToString(), dp);
}
catch (Exception ex)
{
if (ex is ExceptionEx)
{
throw;
}
else
{
throw ExceptionEx.ThrowServiceException(ex);
}
}
}
}
}

+ 0
- 60
Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/LR_LGManager/LGType/LR_Lg_TypeEntity.cs Ver fichero

@@ -1,60 +0,0 @@
using Learun.Util;
using System;
using System.ComponentModel.DataAnnotations.Schema;

namespace Learun.Application.TwoDevelopment.LR_LGManager
{
/// <summary>
/// 版 本 Learun-ADMS-Ultimate V7.0.0 数字化智慧校园
/// Copyright (c) 2013-2018 北京泉江科技有限公司
/// 创 建:超级管理员
/// 日 期:2018-09-29 15:01
/// 描 述:多语言映射
/// </summary>
public class LgTypeEntity
{
#region 实体成员
/// <summary>
/// 主键
/// </summary>
[Column("F_ID")]
public string F_Id { get; set; }
/// <summary>
/// 语言名称
/// </summary>
[Column("F_NAME")]
public string F_Name { get; set; }
/// <summary>
/// 语言编码(不许重复)
/// </summary>
[Column("F_CODE")]
public string F_Code { get; set; }
/// <summary>
/// 是否是主语言0不是1是
/// </summary>
[Column("F_ISMAIN")]
public int? F_IsMain { get; set; }
#endregion

#region 扩展操作
/// <summary>
/// 新增调用
/// </summary>
public void Create()
{
this.F_Id = Guid.NewGuid().ToString();
}
/// <summary>
/// 编辑调用
/// </summary>
/// <param name="keyValue"></param>
public void Modify(string keyValue)
{
this.F_Id = keyValue;
}
#endregion
#region 扩展字段
#endregion
}
}


+ 0
- 8
Learun.Framework.Ultimate V7/Learun.Framework.Module/Learun.Application.Module/Learun.Application.TwoDevelopment/Learun.Application.TwoDevelopment.csproj Ver fichero

@@ -377,14 +377,6 @@
<Compile Include="LR_Desktop\DTChart\DTChartService.cs" />
<Compile Include="LR_Desktop\DTChart\DTChartBLL.cs" />
<Compile Include="LR_Desktop\DTChart\DTChartIBLL.cs" />
<Compile Include="LR_LGManager\LGMap\LR_Lg_MapEntity.cs" />
<Compile Include="LR_LGManager\LGMap\LGMapService.cs" />
<Compile Include="LR_LGManager\LGMap\LGMapBLL.cs" />
<Compile Include="LR_LGManager\LGMap\LGMapIBLL.cs" />
<Compile Include="LR_LGManager\LGType\LR_Lg_TypeEntity.cs" />
<Compile Include="LR_LGManager\LGType\LGTypeService.cs" />
<Compile Include="LR_LGManager\LGType\LGTypeBLL.cs" />
<Compile Include="LR_LGManager\LGType\LGTypeIBLL.cs" />
<Compile Include="LR_ReportTest\TestCRMReport\TestCRMReportService.cs" />
<Compile Include="LR_ReportTest\TestCRMReport\TestCRMReportBLL.cs" />
<Compile Include="LR_ReportTest\TestCRMReport\TestCRMReportIBLL.cs" />


Cargando…
Cancelar
Guardar