1
This commit is contained in:
parent
9f22a23149
commit
9a000f8d43
@ -481,7 +481,7 @@ namespace Learun.Application.Web.AppApi
|
||||
}
|
||||
else
|
||||
{
|
||||
prop.EnumDataCode += detail.DataItemName + "||" + detail.DataItemNameEN + ",";//同时带出属性的中文和英文
|
||||
prop.EnumDataCode += detail.DataItemName + GlobalObject.enum_separator + detail.DataItemNameEN + ",";//同时带出属性的中文和英文
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -774,7 +774,7 @@ namespace Learun.Application.Web.AppApi
|
||||
}
|
||||
else
|
||||
{
|
||||
prop.EnumDataCode += detail.DataItemName + "||" + detail.DataItemNameEN + ",";//同时带出属性的中文和英文
|
||||
prop.EnumDataCode += detail.DataItemName + GlobalObject.enum_separator + detail.DataItemNameEN + ",";//同时带出属性的中文和英文
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -1,6 +1,7 @@
|
||||
using Learun.Application.TwoDevelopment.ZZDT_EC;
|
||||
using Learun.Util;
|
||||
using Learun.Util.SqlSugar;
|
||||
using NPOI.SS.Formula.Functions;
|
||||
using NPOI.SS.Formula.PTG;
|
||||
using NPOI.Util.Collections;
|
||||
using Pipelines.Sockets.Unofficial.Arenas;
|
||||
@ -103,7 +104,13 @@ namespace Learun.Application.Web.AppApi
|
||||
{
|
||||
var tagProps = propAll.FindAll(x => x.EngineDataID == pointTag.EngineDataID);
|
||||
var Prop_Frame = tagProps.FirstOrDefault(x => x.PropertyName == GlobalObject.propName_Frame)?.PropertyValue;
|
||||
Prop_Frame = Prop_Frame.Split(new string[] { "||" }, StringSplitOptions.None)[0];//插件端对于下拉列表 都是 name || nameEN
|
||||
Prop_Frame = Prop_Frame.Split(new string[] { GlobalObject.enum_separator }, StringSplitOptions.None)[0];//插件端对于下拉列表 都是 name || nameEN
|
||||
var xValue = frameLists.FirstOrDefault(X => X.Num == Prop_Frame).Value;
|
||||
if (xValue < 400)
|
||||
{
|
||||
// 小于400,我几乎可以认为此时肋位号用的是m这个单位。因为如果用的是mm,400mm的肋位号似乎也太小了。
|
||||
xValue = 1000* xValue; // 转成mm
|
||||
}
|
||||
var Prop_FrameOff = tagProps.FirstOrDefault(x => x.PropertyName == GlobalObject.propName_FrameOff)?.PropertyValue;
|
||||
var Prop_YOff = tagProps.FirstOrDefault(x => x.PropertyName == GlobalObject.propName_YOff)?.PropertyValue;
|
||||
var DECK = tagProps.FirstOrDefault(x => x.PropertyName == "甲板号")?.PropertyValue;
|
||||
@ -114,7 +121,7 @@ namespace Learun.Application.Web.AppApi
|
||||
FileId = "",
|
||||
PixelOnDwg = pointsOnDwg.FirstOrDefault(x => x.EngineDataID == pointTag.EngineDataID)?.PixelCode,
|
||||
TagNumber = pointTag.TagNumber,
|
||||
X = frameLists.FirstOrDefault(X => X.Num == Prop_Frame).Value,
|
||||
X = xValue,
|
||||
XOff = Prop_FrameOff,
|
||||
YOff = Prop_YOff,
|
||||
deck = DECK,
|
||||
@ -138,7 +145,7 @@ namespace Learun.Application.Web.AppApi
|
||||
|
||||
//这里要考虑下拉列表 带 ||的问题
|
||||
var matchedTagIds = propAll.Where(x => x.PropertyName == keyProp
|
||||
&& (x.PropertyValue == keyValue || x.PropertyValue.StartsWith(keyValue + "||"))).
|
||||
&& (x.PropertyValue == keyValue || x.PropertyValue.StartsWith(keyValue + GlobalObject.enum_separator))).
|
||||
Select(X => X.EngineDataID).Distinct().ToList();
|
||||
|
||||
//有效范围的设备
|
||||
@ -164,12 +171,19 @@ namespace Learun.Application.Web.AppApi
|
||||
{
|
||||
var tagProps = EquipPropAll.Where(x => x.EngineDataID == matchPointTagId).ToList();
|
||||
var Prop_Frame = tagProps.FirstOrDefault(x => x.PropertyName == GlobalObject.propName_Frame)?.PropertyValue;
|
||||
Prop_Frame = Prop_Frame.Split(new string[] { "||" }, StringSplitOptions.None)[0];//插件端对于下拉列表 都是 name || nameEN
|
||||
Prop_Frame = Prop_Frame.Split(new string[] { GlobalObject.enum_separator }, StringSplitOptions.None)[0];//插件端对于下拉列表 都是 name || nameEN
|
||||
var xValue = frameLists.FirstOrDefault(X => X.Num == Prop_Frame).Value;
|
||||
if (xValue < 400)
|
||||
{
|
||||
// 小于400,我几乎可以认为此时肋位号用的是m这个单位。因为如果用的是mm,400mm的肋位号似乎也太小了。
|
||||
xValue = 1000 * xValue; // 转成mm
|
||||
}
|
||||
var Prop_FrameOff = tagProps.FirstOrDefault(x => x.PropertyName == GlobalObject.propName_FrameOff)?.PropertyValue;
|
||||
var Prop_YOff = tagProps.FirstOrDefault(x => x.PropertyName == GlobalObject.propName_YOff)?.PropertyValue;
|
||||
|
||||
var tagInfo = matchedTags.FirstOrDefault(X => X.EngineDataID == matchPointTagId);
|
||||
|
||||
var systemProp = tagProps.FirstOrDefault(x => x.PropertyName == GlobalObject.propName_System)?.PropertyValue;
|
||||
var tagProp = tagProps.FirstOrDefault(x => x.PropertyName == GlobalObject.propName_Tag)?.PropertyValue;
|
||||
#region 判断是否满足特定条件
|
||||
var fileId = tagInfo.DefaultLayoutLibFileID;
|
||||
var matched = false;
|
||||
@ -228,14 +242,33 @@ namespace Learun.Application.Web.AppApi
|
||||
}
|
||||
}
|
||||
#endregion
|
||||
|
||||
#region 拆tag number
|
||||
var TagNumber_Upper = ""; var TagNumber_Lower = "";
|
||||
var lastDashPos = tagInfo.TagNumber.LastIndexOf('-');//最后一个'-'的位置
|
||||
if (lastDashPos > 0 && lastDashPos < tagInfo.TagNumber.Length - 1)
|
||||
{
|
||||
TagNumber_Upper = tagInfo.TagNumber.Substring(0, lastDashPos);
|
||||
TagNumber_Lower = tagInfo.TagNumber.Substring(lastDashPos + 1);
|
||||
}
|
||||
else
|
||||
{
|
||||
TagNumber_Upper = tagInfo.TagNumber;
|
||||
TagNumber_Lower = "";
|
||||
}
|
||||
#endregion
|
||||
var layoutTagInfo = new layoutTagInfoBrief()
|
||||
{
|
||||
EngineDataID = matchPointTagId,
|
||||
FileId = fileId, //2个优先级
|
||||
IsNotDefaultSymbol= isNotDefaultSymbol,
|
||||
IsNotDefaultSymbol = isNotDefaultSymbol,
|
||||
PixelOnDwg = "",
|
||||
TagNumber = tagInfo.TagNumber,
|
||||
X = frameLists.FirstOrDefault(X => X.Num == Prop_Frame).Value,
|
||||
TagNumber_Upper = TagNumber_Upper,
|
||||
TagNumber_Lower = TagNumber_Lower,
|
||||
System = systemProp,
|
||||
Tag = tagProp,
|
||||
X = xValue,
|
||||
XOff = Prop_FrameOff,
|
||||
YOff = Prop_YOff,
|
||||
deck = basePoint.deck,
|
||||
|
@ -1494,8 +1494,8 @@ namespace Learun.Application.Web.Areas.ZZDT_EC.Controllers
|
||||
英文名称 = SqlFunc.IIF(eep.PropertyName == "英文名称", eep.PropertyValue, string.Empty),
|
||||
设备单元 = SqlFunc.IIF(eep.PropertyName =="设备单元",eep.PropertyValue, string.Empty),
|
||||
甲板号 = SqlFunc.IIF(eep.PropertyName == "甲板号", SqlFunc.IIF(
|
||||
SqlFunc.Contains(eep.PropertyValue, "||"),
|
||||
SqlFunc.Trim(SqlFunc.Substring(eep.PropertyValue, 0, SqlFunc.CharIndexNew(eep.PropertyValue, "||") - 1)),
|
||||
SqlFunc.Contains(eep.PropertyValue, GlobalObject.enum_separator),
|
||||
SqlFunc.Trim(SqlFunc.Substring(eep.PropertyValue, 0, SqlFunc.CharIndexNew(eep.PropertyValue, GlobalObject.enum_separator) - 1)),
|
||||
eep.PropertyValue), string.Empty),
|
||||
房间号 = SqlFunc.IIF(eep.PropertyName == "房间号", eep.PropertyValue, string.Empty),
|
||||
肋位号 = SqlFunc.IIF(eep.PropertyName == "肋位号", eep.PropertyValue, string.Empty)
|
||||
|
@ -2,7 +2,7 @@
|
||||
<Project ToolsVersion="Current" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<PropertyGroup>
|
||||
<LastActiveSolutionConfig>Debug|Any CPU</LastActiveSolutionConfig>
|
||||
<NameOfLastUsedPublishProfile>C:\repo\CODE\009\Server\Learun.Application.Web\Properties\PublishProfiles\FolderProfile2.pubxml</NameOfLastUsedPublishProfile>
|
||||
<NameOfLastUsedPublishProfile>C:\repo\CODE\009_DI-Elec\Learun.Application.Web\Properties\PublishProfiles\FolderProfile3.pubxml</NameOfLastUsedPublishProfile>
|
||||
<UseIISExpress>true</UseIISExpress>
|
||||
<Use64BitIISExpress />
|
||||
<IISExpressSSLPort />
|
||||
|
@ -15,6 +15,17 @@ var bootstrap = function ($, learun) {
|
||||
page.bind();
|
||||
},
|
||||
bind: function () {
|
||||
// 复制
|
||||
$('#lr_copy').on('click', function () {
|
||||
learun.layerForm({
|
||||
id: 'lookupBatchCopy',
|
||||
title: '对象类型多选',
|
||||
url: top.$.rootUrl + '/ZZDT_EC/ec_LookupTable/SelectObjectType?objectTypeId=' + typeId + "&ProjectId=" + ProjectId,
|
||||
width: 700,
|
||||
height: 600,
|
||||
btn: null
|
||||
});
|
||||
});
|
||||
// 查询
|
||||
$('#btn_Search').on('click', function () {
|
||||
page.search();
|
||||
|
@ -30,10 +30,10 @@ var bootstrap = function ($, learun) {
|
||||
}).lrselectSet(upDataItemDetailID);//lrselectSet获取下拉框选择的值,传入UpObjectTypeID
|
||||
/*检测重复项*/
|
||||
$('#DataItemName').on('blur', function () {
|
||||
$.lrExistField(keyValue, 'DataItemName', top.$.rootUrl + '/ZZDT_EC/ec_dataitem/ExistDetailItemName', { itemCode: itemCode, ProjectId: ProjectId });
|
||||
$.lrExistField(keyValue, 'DataItemName', top.$.rootUrl + '/ZZDT_EC/ec_dataitem/ExistDetailItemName', { itemCode: dataItemID, ProjectId: ProjectId });
|
||||
});
|
||||
$('#DataItemCode').on('blur', function () {
|
||||
$.lrExistField(keyValue, 'DataItemCode', top.$.rootUrl + '/ZZDT_EC/ec_dataitem/ExistDetailItemCode', { itemCode: itemCode, ProjectId: ProjectId });
|
||||
$.lrExistField(keyValue, 'DataItemCode', top.$.rootUrl + '/ZZDT_EC/ec_dataitem/ExistDetailItemCode', { itemCode: dataItemID, ProjectId: ProjectId });
|
||||
});
|
||||
},
|
||||
initData: function () {
|
||||
|
@ -43,7 +43,10 @@
|
||||
<a id="lr_category" class="btn btn-default"><i class="fa fa-tags"></i> <span class="lrlg">字典分类</span></a>
|
||||
</div>
|
||||
<div class=" btn-group btn-group-sm">
|
||||
<a id="lr_bulkload" class="btn btn-default"><i class="fa fa-tags"></i> <span class="lrlg">Smart 3D电气分类导入</span></a>
|
||||
<a id="lr_export" class="btn btn-default"><i class="fa fa-download"></i> <span class="lrlg">数据字典导出</span></a>
|
||||
<a id="lr_bulkload" class="btn btn-default"><i class="fa fa-file-excel-o"></i> <span class="lrlg">通用导入</span></a>
|
||||
|
||||
<a id="lr_bulkload_3D" class="btn btn-default"><i class="fa fa-file-excel-o"></i> <span class="lrlg">Smart 3D电气分类导入</span></a>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
@ -92,6 +92,23 @@ var bootstrap = function ($, learun) {
|
||||
|
||||
//excel导入
|
||||
$('#lr_bulkload').on('click', function () {
|
||||
var format = 'xlsx';
|
||||
var uploadKeyValue = Guid.NewGuid().toString();
|
||||
learun.layerForm({
|
||||
id: 'importfile2',
|
||||
title: '数据字典通用导入',
|
||||
url: top.$.rootUrl + '/LR_SystemModule/Annexes/UploadForm?keyVaule=' + uploadKeyValue + "&multiple=false" + "&format=" + format,
|
||||
width: 600,
|
||||
height: 400,
|
||||
maxmin: true,
|
||||
btn: ['确认'],
|
||||
callBack: function (id) {
|
||||
learun.layerClose('importfile2');//关闭上传excel的弹窗
|
||||
ExcelImport(uploadKeyValue);
|
||||
}
|
||||
});
|
||||
});
|
||||
$('#lr_bulkload_3D').on('click', function () {
|
||||
var format = 'xlsx';
|
||||
var uploadKeyValue = Guid.NewGuid().toString();
|
||||
learun.layerForm({
|
||||
@ -103,11 +120,26 @@ var bootstrap = function ($, learun) {
|
||||
maxmin: true,
|
||||
btn: ['确认'],
|
||||
callBack: function (id) {
|
||||
learun.layerClose('importfile');
|
||||
ExcelImport(uploadKeyValue);
|
||||
learun.layerClose('importfile');//关闭上传excel的弹窗
|
||||
ExcelImport_3D(uploadKeyValue);
|
||||
}
|
||||
});
|
||||
});
|
||||
|
||||
// lr_export
|
||||
$('#lr_export').on('click', function () {
|
||||
|
||||
var iframeUrl = top.$.rootUrl + '/ZZDT_EC/ec_dataitem/exportSingle?ProjectId=' + ProjectId + "&dataItemID=" + dataItemID;//"&dataItemDetailIDOrDwgCategoryID=" + dataItemDetailIDOrDrawingCategoryID + "&model=" + model;
|
||||
learun.loading(true, "生成报表中...");
|
||||
var body = document.getElementsByTagName("body")[0];
|
||||
var downloadIframe = document.createElement("iframe");
|
||||
downloadIframe.setAttribute("src", iframeUrl);
|
||||
downloadIframe.setAttribute("style", "display:none;")
|
||||
body.appendChild(downloadIframe);
|
||||
learun.loading(false);
|
||||
|
||||
|
||||
});
|
||||
},
|
||||
initTree: function () {
|
||||
$('#lr_left_tree').lrtree({
|
||||
@ -161,7 +193,6 @@ var bootstrap = function ($, learun) {
|
||||
|
||||
|
||||
}
|
||||
|
||||
function ExcelImport(fileId) {
|
||||
var learun = top.learun;
|
||||
learun.loading(true, "数据字典导入中...");
|
||||
@ -185,3 +216,26 @@ function ExcelImport(fileId) {
|
||||
}
|
||||
});
|
||||
}
|
||||
function ExcelImport_3D(fileId) {
|
||||
var learun = top.learun;
|
||||
learun.loading(true, "3D数据导入中...");
|
||||
$.ajax({
|
||||
type: 'POST',
|
||||
url: top.$.rootUrl + '/ZZDT_EC/ec_dataitem/ExcelImport3D?ProjectId=' + ProjectId + "&keyValue=" + fileId,
|
||||
data: { ProjectId: ProjectId, fileId: fileId },
|
||||
traditional: true,
|
||||
success: function (data) {
|
||||
var data = JSON.parse(data);
|
||||
if (data.code == '200') {
|
||||
location.reload();
|
||||
}
|
||||
learun.alert.success(data.info);
|
||||
},
|
||||
error: function (msg) {
|
||||
learun.alert.error(msg);
|
||||
},
|
||||
complete: function (data) {
|
||||
learun.loading(false);
|
||||
}
|
||||
});
|
||||
}
|
||||
|
@ -108,7 +108,7 @@ var bootstrap = function ($, learun) {
|
||||
}
|
||||
}
|
||||
});
|
||||
page.search();
|
||||
//page.search(); 默认显示,但此时并没有选catalogue
|
||||
},
|
||||
search: function (param) {
|
||||
param = param || {};
|
||||
|
@ -136,14 +136,40 @@ var bootstrap = function ($, learun) {
|
||||
Save = function (callBack) {
|
||||
|
||||
var formData = $('#form').lrGetFormData();
|
||||
|
||||
console.log(formData.trigger_property_id);
|
||||
console.log(formData.dependency_type);
|
||||
console.log(formData.trigger_operator);
|
||||
//VALIDATE
|
||||
if (formData.trigger_property_id != -1) {
|
||||
if (formData.dependency_type == -1 || formData.dependency_type == 0) {
|
||||
learun.alert.warning('请选择一个需要的联动类型。');
|
||||
//if (formData.trigger_property_id != -1) {
|
||||
// if (formData.dependency_type == -1 || formData.dependency_type == 0) {
|
||||
// learun.alert.warning('请选择一个需要的联动类型。');
|
||||
// return;
|
||||
// }
|
||||
//}
|
||||
|
||||
//没选 联动类型,就会保存为 不需要
|
||||
if (formData.dependency_type === "" || formData.dependency_type === "-1") {
|
||||
learun.alert.warning('请选择一个需要的联动类型。'); return;
|
||||
}
|
||||
else if (formData.dependency_type == 1) {
|
||||
if (formData.trigger_property_id === "" || formData.trigger_property_id === "-1") {
|
||||
learun.alert.warning('请选择一个前置属性。');
|
||||
return;
|
||||
}
|
||||
|
||||
}
|
||||
else if (formData.dependency_type == 2) {
|
||||
if (formData.trigger_property_id === "" || formData.trigger_property_id === "-1") {
|
||||
learun.alert.warning('请选择一个前置属性。'); return;
|
||||
}
|
||||
if (formData.trigger_value === "" || formData.trigger_value === "-1") {
|
||||
learun.alert.warning('前置属性的属性值需要填写。'); return;
|
||||
}
|
||||
if (formData.trigger_operator === "" || formData.trigger_operator === "-1") {
|
||||
learun.alert.warning('前置属性的操作符需要填写。'); return;
|
||||
}
|
||||
}
|
||||
|
||||
var obj = {
|
||||
PropertyID: PropertyID, // 这里根据你的数据模型,提取需要的字段
|
||||
IsRequired: IsRequired,
|
||||
@ -153,7 +179,7 @@ var bootstrap = function ($, learun) {
|
||||
dependency_type: formData.dependency_type,
|
||||
trigger_value: formData.trigger_value,
|
||||
trigger_operator: formData.trigger_operator,
|
||||
PropertyType:"1"
|
||||
PropertyType: "1"
|
||||
}
|
||||
console.log(obj);
|
||||
var dataList = [obj]; // 将单个对象包装成数组
|
||||
|
@ -30,6 +30,7 @@ var bootstrap = function ($, learun) {
|
||||
type: "GET",
|
||||
dataType: "json",
|
||||
success: function (data) {
|
||||
//这个data就是整个http返回结果,也就是Success(XXX)这个结构
|
||||
if (data.code == 200 && data.data.length > 0) {
|
||||
$.each(data.data, function (i, item) {
|
||||
selectData.push(item.ObjectTypeID);
|
||||
|
@ -120,6 +120,60 @@ var bootstrap = function ($, learun) {
|
||||
table.rows().invalidate().draw();
|
||||
});
|
||||
|
||||
$('#lr_propertyImport').on('click', function () {
|
||||
//批量导入
|
||||
var format = 'xlsx';
|
||||
var uploadKeyValue = Guid.NewGuid().toString();
|
||||
learun.layerForm({
|
||||
id: 'importfile',
|
||||
title: '对象类型 - 必填属性导入',
|
||||
url: top.$.rootUrl + '/LR_SystemModule/Annexes/UploadForm?keyVaule=' + uploadKeyValue + "&multiple=false" + "&format=" + format,
|
||||
width: 600,
|
||||
height: 400,
|
||||
maxmin: true,
|
||||
btn: ['确认'],
|
||||
callBack: function (id) {
|
||||
learun.layerClose('importfile');
|
||||
//MuliteImport(uploadKeyValue);
|
||||
|
||||
learun.loading(true, "批量导入数据中...");
|
||||
$.ajax({
|
||||
type: 'POST',
|
||||
url: top.$.rootUrl + "/ZZDT_EC/ec_objecttype/ImportPropsIfNeed?rdo=" + Math.random(),
|
||||
data: { fileId: fileId, ProjectId: ProjectId },
|
||||
traditional: true,
|
||||
success: function (data) {
|
||||
var data = JSON.parse(data);
|
||||
if (data.code == '200') {
|
||||
location.reload();
|
||||
}
|
||||
learun.alert.success(data.info);
|
||||
},
|
||||
error: function (msg) {
|
||||
learun.alert.error(msg);
|
||||
}, complete: function (data) {
|
||||
learun.loading(false);
|
||||
}
|
||||
});
|
||||
|
||||
}
|
||||
});
|
||||
|
||||
});
|
||||
//属性必填矩阵导出
|
||||
$('#lr_propertyExport').on('click', function () {
|
||||
|
||||
learun.loading(true, "导出中...");
|
||||
var iframeUrl = top.$.rootUrl + '/ZZDT_EC/ec_objecttype/ExportPropsIfNeed?ProjectId=' + ProjectId;
|
||||
|
||||
var body = document.getElementsByTagName("body")[0];
|
||||
var downloadIframe = document.createElement("iframe");
|
||||
downloadIframe.setAttribute("src", iframeUrl);
|
||||
downloadIframe.setAttribute("style", "display:none;")
|
||||
body.appendChild(downloadIframe);
|
||||
learun.loading(false);
|
||||
});
|
||||
|
||||
},
|
||||
// 初始化列表
|
||||
initGird: function () {
|
||||
@ -231,7 +285,7 @@ var bootstrap = function ($, learun) {
|
||||
<option value="-1" ${data == -1 ? 'selected' : ''}>无需检查</option>
|
||||
<option value="1" ${data == 1 ? 'selected' : ''}>即时更新版</option>
|
||||
<option value="2" ${data == 2 ? 'selected' : ''}>送审图</option>
|
||||
<option value="3" ${data == 3 ? 'selected' : ''}>O版图</option>
|
||||
<option value="3" ${data == 3 ? 'selected' : ''}>清洁版</option>
|
||||
<option value="4" ${data == 4 ? 'selected' : ''}>施工图</option>
|
||||
<option value="5" ${data == 5 ? 'selected' : ''}>完工图</option>
|
||||
</select>
|
||||
|
Binary file not shown.
Binary file not shown.
@ -116,9 +116,9 @@ namespace Learun.Application.TwoDevelopment.ZZDT_EC
|
||||
EngineDataID = x.EngineDataID,
|
||||
PropertyName = x.PropertyName,
|
||||
PropertyValue = SqlFunc.IIF(x.PropertyName == "所属系统", SqlFunc.IIF(
|
||||
SqlFunc.Contains(x.PropertyValue, "||"),
|
||||
SqlFunc.Contains(x.PropertyValue, GlobalObject.enum_separator),
|
||||
SqlFunc.Trim(SqlFunc.Substring(x.PropertyValue, 0,
|
||||
SqlFunc.CharIndexNew(x.PropertyValue, "||") - 1)),
|
||||
SqlFunc.CharIndexNew(x.PropertyValue, GlobalObject.enum_separator) - 1)),
|
||||
x.PropertyValue), x.PropertyValue)
|
||||
})
|
||||
.ToList();
|
||||
|
@ -23,8 +23,14 @@ namespace Learun.Application.TwoDevelopment.ZZDT_EC
|
||||
/// 位号
|
||||
/// </summary>
|
||||
public string TagNumber { get; set; } = "";
|
||||
public string TagNumber_Upper { get; set; }
|
||||
public string TagNumber_Lower { get; set; }
|
||||
public string System { get; set; }
|
||||
public string Tag { get; set; }
|
||||
/// <summary>
|
||||
/// 是否默认图标
|
||||
/// 是否默认图标。默认图标就是<see cref="ec_objecttypeEntity.DefaultLayoutLibFileID"/>。(此时拆)
|
||||
/// 不是默认时,就是满足某个细分规则里的图标<see cref="ec_objTypeLayoutFilter.LayoutLibFileID"/>。(此时不拆)
|
||||
/// 同时也影响位号的文字放置(一行 / 两行)
|
||||
/// </summary>
|
||||
public bool IsNotDefaultSymbol { get; set; }
|
||||
/// <summary>
|
||||
|
@ -412,9 +412,9 @@ namespace Learun.Application.TwoDevelopment.ZZDT_EC
|
||||
EngineDataID = x.EngineDataID,
|
||||
PropertyName = x.PropertyName,
|
||||
PropertyValue = SqlFunc.IIF(x.PropertyName == "所属系统", SqlFunc.IIF(
|
||||
SqlFunc.Contains(x.PropertyValue, "||"),
|
||||
SqlFunc.Contains(x.PropertyValue, GlobalObject.enum_separator),
|
||||
SqlFunc.Trim(SqlFunc.Substring(x.PropertyValue, 0,
|
||||
SqlFunc.CharIndexNew(x.PropertyValue, "||") - 1)),
|
||||
SqlFunc.CharIndexNew(x.PropertyValue, GlobalObject.enum_separator) - 1)),
|
||||
x.PropertyValue), x.PropertyValue)
|
||||
})
|
||||
.ToList();
|
||||
@ -766,9 +766,9 @@ namespace Learun.Application.TwoDevelopment.ZZDT_EC
|
||||
EngineDataID = x.EngineDataID,
|
||||
PropertyName = x.PropertyName,
|
||||
PropertyValue = SqlFunc.IIF(x.PropertyName == "所属系统", SqlFunc.IIF(
|
||||
SqlFunc.Contains(x.PropertyValue, "||"),
|
||||
SqlFunc.Contains(x.PropertyValue, GlobalObject.enum_separator),
|
||||
SqlFunc.Trim(SqlFunc.Substring(x.PropertyValue, 0,
|
||||
SqlFunc.CharIndexNew(x.PropertyValue, "||") - 1)),
|
||||
SqlFunc.CharIndexNew(x.PropertyValue, GlobalObject.enum_separator) - 1)),
|
||||
x.PropertyValue), string.Empty)
|
||||
})
|
||||
.ToList();
|
||||
|
@ -57,7 +57,7 @@ namespace Learun.Application.TwoDevelopment.ZZDT_EC
|
||||
InnerJoin<ec_objecttypeEntity>((a, b, c) => b.ObjectTypeID == c.ObjectTypeID).AS<ec_objecttypeEntity>(typeTbName).Where(
|
||||
(a, b, c) =>
|
||||
a.PropertyName == GlobalObject.propName_System
|
||||
&& (a.PropertyValue == curSystem.DataItemName || a.PropertyValue.Replace(" ", "").Replace("||", "") == curSystem.DataItemName.Replace(" ", "") + curSystem.DataItemNameEN.Replace(" ", ""))
|
||||
&& (a.PropertyValue == curSystem.DataItemName || a.PropertyValue.Replace(" ", "").Replace(GlobalObject.enum_separator, "") == curSystem.DataItemName.Replace(" ", "") + curSystem.DataItemNameEN.Replace(" ", ""))
|
||||
&& !c.ObjectTypeName.EndsWith("电缆")
|
||||
).
|
||||
Select(a => a.EngineDataID).Distinct().
|
||||
@ -155,7 +155,7 @@ namespace Learun.Application.TwoDevelopment.ZZDT_EC
|
||||
Where(
|
||||
(a, b, c) =>
|
||||
a.PropertyName == GlobalObject.propName_PackageUnit
|
||||
&& (a.PropertyValue == curUnit.DataItemName || a.PropertyValue.Replace(" ", "").Replace("||", "") == curUnit.DataItemName.Replace(" ", "") + curUnit.DataItemNameEN.Replace(" ", ""))
|
||||
&& (a.PropertyValue == curUnit.DataItemName || a.PropertyValue.Replace(" ", "").Replace(GlobalObject.enum_separator, "") == curUnit.DataItemName.Replace(" ", "") + curUnit.DataItemNameEN.Replace(" ", ""))
|
||||
&& !c.ObjectTypeName.EndsWith("电缆")
|
||||
).
|
||||
Select(a => a.EngineDataID).Distinct().
|
||||
@ -218,7 +218,7 @@ namespace Learun.Application.TwoDevelopment.ZZDT_EC
|
||||
{
|
||||
var propertyvalue = x.ToTag?.EngineDataProperty?.
|
||||
FirstOrDefault(y => y.PropertyName == GlobalObject.propName_PackageUnit)?.PropertyValue;
|
||||
return propertyvalue == UnitName || propertyvalue?.Replace(" ", "").Replace("||", "") == curUnit?.DataItemName?.Replace(" ", "") + curUnit?.DataItemNameEN?.Replace(" ", "");
|
||||
return propertyvalue == UnitName || propertyvalue?.Replace(" ", "").Replace(GlobalObject.enum_separator, "") == curUnit?.DataItemName?.Replace(" ", "") + curUnit?.DataItemNameEN?.Replace(" ", "");
|
||||
});
|
||||
if (res2.connected_cables.Count == 0)
|
||||
{
|
||||
|
Loading…
x
Reference in New Issue
Block a user