This commit is contained in:
clovejunti 2024-06-03 00:38:52 +08:00
parent fff9a50650
commit 3495daf57c
54 changed files with 1691 additions and 602 deletions

1
.gitignore vendored
View File

@ -20,3 +20,4 @@ SqlSugarTest/obj
DeviceManager_20240529.zip
TsSFCDeivceClient/bin
Intend/bin
DeviceManager_20240530.zip

View File

@ -1,4 +1,8 @@
using System.Web.Http;
using System.Linq;
using System.Net.Http;
using System.Threading;
using System.Threading.Tasks;
using System.Web.Http;
using Microsoft.Owin.Security.OAuth;
namespace DeviceRepair.Api

View File

@ -11,6 +11,27 @@ namespace DeviceRepair.Api.Controllers
[RoutePrefix("Api/Device")]
public class DeviceController : CFController
{
/// <summary>
/// 获取设备路径
/// </summary>
/// <returns></returns>
[HttpGet, Route("GetDeviceRoute"), HttpAuthorize]
public APIResponseData GetDeviceRoute()
{
APIResponseData apiResponseData = new APIResponseData { Code = -1, Message = "未能获取到数据" };
try
{
apiResponseData = DeviceAccess.Instance.GetDeviceRoute();
}
catch (Exception ex)
{
apiResponseData.Code = -1;
apiResponseData.Message = ex.Message.ToString();
}
return apiResponseData;
}
[HttpGet]
[Route("GetModelByEquipmentID")]
[HttpAuthorize]

View File

@ -1,5 +1,6 @@
using DeviceRepair.Api.Common;
using DeviceRepair.Api.CustomAttribute;
using DeviceRepair.Api.Models;
using DeviceRepair.DataAccess;
using DeviceRepair.Models;
using System;
@ -24,13 +25,14 @@ namespace DeviceRepair.Api.Controllers
APIResponseData apiResponseData = new APIResponseData { Code = -1, Message = "操作失败!" };
try
{
return MaintenanceAccess.Instance.GetDatas(FilterInfo);
apiResponseData = MaintenanceAccess.Instance.GetDatas(FilterInfo);
}
catch (Exception ex)
{
apiResponseData.Code = -1;
apiResponseData.Message = ex.Message;
}
return apiResponseData;
}

View File

@ -0,0 +1,69 @@
using System.IO;
using System.IO.Compression;
using System.Linq;
using System.Net.Http;
using System.Text;
using System.Threading;
using System.Threading.Tasks;
using System.Web.Http.Filters;
namespace DeviceRepair.Api.CustomAttribute
{
public class GzipCompressionAttribute : ActionFilterAttribute
{
public override async Task OnActionExecutedAsync(HttpActionExecutedContext actionExecutedContext, CancellationToken cancellationToken)
{
if (actionExecutedContext.Response != null && actionExecutedContext.Response.Content != null)
{
var response = actionExecutedContext.Response;
// 检查客户端是否接受 GZIP 压缩
var acceptsEncoding = actionExecutedContext.Request.Headers.AcceptEncoding;
var gzipSupported = acceptsEncoding.Any(x => x.Value.Contains("gzip"));
if (gzipSupported)
{
// 读取原始响应内容
var originalContent = await response.Content.ReadAsStringAsync();
// 压缩内容
byte[] compressedContent = CompressString(originalContent);
// 创建一个新的内存流来保存压缩后的内容
var compressedStream = new MemoryStream(compressedContent);
// 创建一个新的响应内容,并设置内容类型、编码和头部信息
var compressedResponseContent = new StreamContent(compressedStream);
compressedResponseContent.Headers.ContentType = response.Content.Headers.ContentType;
compressedResponseContent.Headers.ContentEncoding.Add("gzip");
// 创建一个新的响应消息,并设置新的内容
var newResponse = new HttpResponseMessage(response.StatusCode)
{
Content = compressedResponseContent,
ReasonPhrase = response.ReasonPhrase
};
// 将新的响应设置为 actionExecutedContext 的结果
actionExecutedContext.Response = newResponse;
}
}
// 调用基类的方法以继续管道中的后续操作
await base.OnActionExecutedAsync(actionExecutedContext, cancellationToken);
}
private byte[] CompressString(string str)
{
byte[] buffer = Encoding.UTF8.GetBytes(str);
var memoryStream = new MemoryStream();
using (var gZipStream = new GZipStream(memoryStream, CompressionMode.Compress, true))
{
gZipStream.Write(buffer, 0, buffer.Length);
}
memoryStream.Position = 0;
return memoryStream.ToArray();
}
}
}

View File

@ -55,7 +55,7 @@ namespace DeviceRepair.Api.CustomAttribute
)
{
string @Value = Runtime.Cachce[model.LoginCode]?.ToString();
if (desToken.Equals(Value) || SfcUserValidate(model.LoginCode, model.Password, model.inParams))
if (desToken.Equals(Value) || SfcUserValidate(model.LoginCode, model.Password))
{
Runtime.Cachce.Add(model.LoginCode, desToken, null, DateTime.Now.AddMinutes(15), TimeSpan.Zero, CacheItemPriority.Normal, null);
return;
@ -80,6 +80,28 @@ namespace DeviceRepair.Api.CustomAttribute
}
/// <summary>
/// 验证SFC账户密码
/// </summary>
/// <param name="LoginCode"></param>
/// <param name="Password"></param>
/// <returns></returns>
public bool SfcUserValidate(string LoginCode, string Password)
{
try
{
APIResponseData apiResponseData = DataAccess.TsSFCAccess.Instance.ValideteToekn(LoginCode, Password);
if (!apiResponseData.IsSuccess)
return false;
return apiResponseData.ToInt() > 0;
}
catch
{
return false;
}
}
/// <summary>
/// 验证SFC账户密码
@ -89,6 +111,20 @@ namespace DeviceRepair.Api.CustomAttribute
/// <returns></returns>
public bool SfcUserValidate(string LoginCode, string Password, string inParams)
{
try
{
APIResponseData apiResponseData = DataAccess.TsSFCAccess.Instance.ValideteToekn(LoginCode, Password);
if (!apiResponseData.IsSuccess)
return false;
return apiResponseData.ToInt() > 0;
}
catch
{
return false;
}
try
{
string SFCWebServiceUrl = Utils.Config.Configurations.Properties.SFCWebServiceUrl;

View File

@ -235,12 +235,14 @@
<Compile Include="Controllers\PreserveController.cs" />
<Compile Include="Controllers\RoleController.cs" />
<Compile Include="Controllers\UserController.cs" />
<Compile Include="CustomAttribute\GzipCompressionAttribute.cs" />
<Compile Include="CustomAttribute\HttpAuthorizeAttribute.cs" />
<Compile Include="Global.asax.cs">
<DependentUpon>Global.asax</DependentUpon>
</Compile>
<Compile Include="Models\AccountBindingModels.cs" />
<Compile Include="Models\AccountViewModels.cs" />
<Compile Include="Models\CompressedContentResult.cs" />
<Compile Include="Models\IdentityModels.cs" />
<Compile Include="Properties\AssemblyInfo.cs" />
<Compile Include="Providers\ApplicationOAuthProvider.cs" />

View File

@ -0,0 +1,63 @@
using System.IO;
using System.IO.Compression;
using System.Linq;
using System.Net;
using System.Net.Http;
using System.Text;
using System.Threading;
using System.Threading.Tasks;
using System.Web.Http;
namespace DeviceRepair.Api.Models
{
public class CompressedContentResult<T> : IHttpActionResult
{
private readonly T _value;
private readonly HttpRequestMessage _request;
private readonly ApiController _controller;
public CompressedContentResult(T value, HttpRequestMessage request, ApiController controller)
{
_value = value;
_request = request;
_controller = controller;
}
public Task<HttpResponseMessage> ExecuteAsync(CancellationToken cancellationToken)
{
var response = _controller.Request.CreateResponse(HttpStatusCode.OK, _value, _controller.Configuration.Formatters.JsonFormatter);
// 检查客户端是否接受 GZIP 压缩
var acceptsEncoding = _request.Headers.AcceptEncoding;
var gzipSupported = acceptsEncoding.Any(x => x.Value.Contains("gzip"));
if (gzipSupported)
{
var originalContent = response.Content.ReadAsStringAsync().Result; // 注意:这里同步读取可能会导致问题,但在示例中为了简化
byte[] compressedContent = CompressString(originalContent);
var compressedStream = new MemoryStream(compressedContent);
var compressedContentResult = new StreamContent(compressedStream);
compressedContentResult.Headers.ContentType = response.Content.Headers.ContentType;
compressedContentResult.Headers.ContentEncoding.Add("gzip");
response.Content = compressedContentResult;
}
return Task.FromResult(response);
}
private byte[] CompressString(string str)
{
byte[] buffer = Encoding.UTF8.GetBytes(str);
var memoryStream = new MemoryStream();
using (var gZipStream = new GZipStream(memoryStream, CompressionMode.Compress, true))
{
gZipStream.Write(buffer, 0, buffer.Length);
}
memoryStream.Position = 0;
return memoryStream.ToArray();
}
}
}

View File

@ -5,7 +5,7 @@ https://go.microsoft.com/fwlink/?LinkID=208121.
<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<PropertyGroup>
<_PublishTargetUrl>C:\Users\Clove\Desktop\WebSite</_PublishTargetUrl>
<History>True|2024-05-30T09:42:28.4008960Z;True|2024-05-30T17:35:13.0117556+08:00;True|2024-05-30T17:28:00.7834102+08:00;True|2024-05-30T17:10:05.9943745+08:00;True|2024-05-29T13:43:17.4797209+08:00;</History>
<History>True|2024-05-31T02:08:51.2865889Z;True|2024-05-31T01:21:35.1603933+08:00;True|2024-05-30T17:42:28.4008960+08:00;True|2024-05-30T17:35:13.0117556+08:00;True|2024-05-30T17:28:00.7834102+08:00;True|2024-05-30T17:10:05.9943745+08:00;True|2024-05-29T13:43:17.4797209+08:00;</History>
</PropertyGroup>
<ItemGroup>
<File Include="Areas/HelpPage/HelpPage.css">
@ -78,37 +78,37 @@ https://go.microsoft.com/fwlink/?LinkID=208121.
<publishTime>05/28/2024 22:39:54</publishTime>
</File>
<File Include="bin/DeviceRepair.Api.dll">
<publishTime>05/30/2024 17:35:12</publishTime>
<publishTime>05/31/2024 10:08:50</publishTime>
</File>
<File Include="bin/DeviceRepair.Api.pdb">
<publishTime>05/30/2024 17:35:12</publishTime>
<publishTime>05/31/2024 10:08:50</publishTime>
</File>
<File Include="bin/DeviceRepair.DataAccess.dll">
<publishTime>05/30/2024 17:06:52</publishTime>
<publishTime>05/31/2024 10:06:56</publishTime>
</File>
<File Include="bin/DeviceRepair.DataAccess.dll.config">
<publishTime>05/30/2024 11:42:20</publishTime>
</File>
<File Include="bin/DeviceRepair.DataAccess.pdb">
<publishTime>05/30/2024 17:06:52</publishTime>
<publishTime>05/31/2024 10:06:56</publishTime>
</File>
<File Include="bin/DeviceRepair.Models.dll">
<publishTime>05/30/2024 17:06:52</publishTime>
<publishTime>05/31/2024 10:06:56</publishTime>
</File>
<File Include="bin/DeviceRepair.Models.dll.config">
<publishTime>05/30/2024 11:42:20</publishTime>
</File>
<File Include="bin/DeviceRepair.Models.pdb">
<publishTime>05/30/2024 17:06:52</publishTime>
<publishTime>05/31/2024 10:06:56</publishTime>
</File>
<File Include="bin/DeviceRepair.Utils.dll">
<publishTime>05/30/2024 17:06:52</publishTime>
<publishTime>05/31/2024 10:06:56</publishTime>
</File>
<File Include="bin/DeviceRepair.Utils.dll.config">
<publishTime>05/30/2024 11:42:20</publishTime>
</File>
<File Include="bin/DeviceRepair.Utils.pdb">
<publishTime>05/30/2024 17:06:52</publishTime>
<publishTime>05/31/2024 10:06:56</publishTime>
</File>
<File Include="bin/EntityFramework.dll">
<publishTime>05/28/2024 22:39:54</publishTime>
@ -414,7 +414,7 @@ https://go.microsoft.com/fwlink/?LinkID=208121.
<publishTime>04/16/2024 09:58:38</publishTime>
</File>
<File Include="Web.config">
<publishTime>05/30/2024 17:35:12</publishTime>
<publishTime>05/31/2024 10:08:50</publishTime>
</File>
</ItemGroup>
</Project>

View File

@ -22,6 +22,30 @@ namespace DeviceRepair.DataAccess
}
}
public APIResponseData GetDeviceRoute()
{
APIResponseData apiResponseData = new APIResponseData { Code = -1, Message = "没有查询到数据!" };
try
{
db.ChangeDatabase("main");
List<DeviceRouteInfo> Data = db.Queryable<DeviceRouteInfo>().Where(x => x.Status).ToList();
apiResponseData.Code = 1;
apiResponseData.Data = Data;
apiResponseData.Message = "";
}
catch (SqlSugarException ex)
{
apiResponseData.Code = -1;
apiResponseData.Message = ex.Message;
}
catch (Exception ex)
{
apiResponseData.Code = -1;
apiResponseData.Message = ex.Message;
}
return apiResponseData;
}
/// <summary>
/// 通过设备编号查询设备信息
/// </summary>
@ -74,9 +98,11 @@ namespace DeviceRepair.DataAccess
|| t1.Remarks.Contains(FilterValue)
|| t1.Specification.Contains(FilterValue)).ToExpression();//拼接表达式
var Datas = db.Queryable<DeviceInformationInfo, MaintenanceFormVersionInfo>(
(t1, t2) => new object[] { JoinType.Left, t1.MaintenanceFormVersion == t2.AutoID }
).Select((t1, t2) => new View_DriveInfomationModel
var Datas = db.Queryable<DeviceInformationInfo, MaintenanceFormVersionInfo, DeviceRouteInfo>(
(t1, t2, t3) => new object[] {
JoinType.Left, t1.MaintenanceFormVersion == t2.AutoID,
JoinType.Left, t1.Route == t3.AutoID
}).Select((t1, t2, t3) => new View_DriveInfomationModel
{
AutoID = t1.AutoID,
ChangeDate = t1.ChangeDate,
@ -103,6 +129,8 @@ namespace DeviceRepair.DataAccess
VersionCode = t2.VersionCode,
VersionRev = t2.VersionRev,
WarrantyPeriod = t1.WarrantyPeriod,
Route = t1.Route,
RouteText = t3.Name,
Weight = t1.Weight
}).Where(exp)
.ToList();

View File

@ -351,6 +351,11 @@ namespace DeviceRepair.DataAccess
apiResponseData.Message = string.Empty;
}
}
catch (System.Data.SqlClient.SqlException ex)
{
apiResponseData.Code = -1;
apiResponseData.Message = ex.Number == 2627 ? "当前数据已被处理,请刷新后在试!" : ex.Message;
}
catch (SqlSugarException e)
{
apiResponseData.Code = -1;
@ -436,11 +441,17 @@ namespace DeviceRepair.DataAccess
if (t == 1)
{
if (Entity.ValidateBy > 0)
throw new Exception("当前维修单数据已被处理,请刷新后再试!");
Entity.ValidateBy = Operation.Operator;
Entity.ValidateOn = CurrentTime;
}
else if (t == 2)
{
if (Entity.Validate2By > 0)
throw new Exception("当前维修单数据已被处理,请刷新后再试!");
Entity.Validate2By = Operation.Operator;
Entity.Validate2On = CurrentTime;
}

View File

@ -129,5 +129,35 @@ namespace DeviceRepair.DataAccess
return apiResponseData;
}
/// <summary>
/// 验证用户
/// </summary>
/// <param name="UserCode"></param>
/// <param name="Password"></param>
/// <returns></returns>
public APIResponseData ValideteToekn(string UserCode, string Password)
{
APIResponseData apiResponseData = new APIResponseData { Code = -1, Message = $"获取数据失败!" };
try
{
db.ChangeDatabase("data");
int Count = db.Queryable<UserInfoInfo>().Count(x => x.UserCode.Equals(UserCode) && x.Password.Equals(Password) && x.Status == "A");
apiResponseData.Code = 1;
apiResponseData.Message = "";
apiResponseData.Data = Count;
}
catch (SqlSugarException ex)
{
apiResponseData.Code = -1;
apiResponseData.Message = ex.Message;
}
catch (Exception ex)
{
apiResponseData.Code = -1;
apiResponseData.Message = ex.Message;
}
return apiResponseData;
}
}
}

View File

@ -23,5 +23,7 @@ namespace DeviceRepair.Models
[SugarColumn(IsIgnore = true)]
public bool MaintenanceFormStatus { get; set; }
public string RouteText { get; set; }
}
}

View File

@ -74,6 +74,7 @@
<Compile Include="Device\DeviceInformationInfoTree.cs" />
<Compile Include="Device\DeviceRouteInfo.cs" />
<Compile Include="Device\View_DriveInfomationModel.cs" />
<Compile Include="Enum\EnumDeviceRouteType.cs" />
<Compile Include="Enum\EnumMaintenanceCellType.cs" />
<Compile Include="Enum\EnumMaintenanceType.cs" />
<Compile Include="Enum\EnumMonth.cs" />
@ -125,6 +126,7 @@
<Compile Include="SFC\Addon\StaffsInfo.cs" />
<Compile Include="SFC\Addon\UserPostsInfo.cs" />
<Compile Include="SFC\Data\InspBatchInfo.cs" />
<Compile Include="SFC\Data\UserInfoInfo.cs" />
<Compile Include="User\TokenModel.cs" />
<Compile Include="User\UserInfoModel.cs" />
<Compile Include="Plan\View\View_CurrentMonthPlanTips.cs" />

View File

@ -0,0 +1,18 @@
namespace DeviceRepair.Models.Enum
{
public enum EnumDeviceRouteType
{
/// <summary>
/// 全部
/// </summary>
ALL,
/// <summary>
/// AM
/// </summary>
OEM,
/// <summary>
/// PM
/// </summary>
KH
}
}

View File

@ -0,0 +1,147 @@
using SqlSugar;
using System;
namespace DeviceRepair.Models.SFC
{
/// <summary>
///
///</summary>
[SugarTable("UserInfo")]
public class UserInfoInfo
{
/// <summary>
///
///</summary>
[SugarColumn(ColumnName = "Id", IsIdentity = true)]
public int Id { get; set; }
/// <summary>
/// 用户唯一标识
///</summary>
[SugarColumn(ColumnName = "GUID", IsPrimaryKey = true)]
public Guid Guid { get; set; }
/// <summary>
///
///</summary>
[SugarColumn(ColumnName = "UserCode")]
public string UserCode { get; set; }
/// <summary>
///
///</summary>
[SugarColumn(ColumnName = "UserName")]
public string UserName { get; set; }
/// <summary>
/// 用户类型(预留)0:域用户1SFC自建账号2ERP账号3其他
///</summary>
[SugarColumn(ColumnName = "UserType")]
public string UserType { get; set; }
/// <summary>
///
///</summary>
[SugarColumn(ColumnName = "Dept")]
public string Dept { get; set; }
/// <summary>
///
///</summary>
[SugarColumn(ColumnName = "EMail")]
public string EMail { get; set; }
/// <summary>
///
///</summary>
[SugarColumn(ColumnName = "Tel")]
public string Tel { get; set; }
/// <summary>
///
///</summary>
[SugarColumn(ColumnName = "Image")]
public string Image { get; set; }
/// <summary>
///
///</summary>
[SugarColumn(ColumnName = "Password")]
public string Password { get; set; }
/// <summary>
///
///</summary>
[SugarColumn(ColumnName = "Status")]
public string Status { get; set; }
/// <summary>
///
///</summary>
[SugarColumn(ColumnName = "CreateBy")]
public string CreateBy { get; set; }
/// <summary>
///
/// 默认值: (getdate())
///</summary>
[SugarColumn(ColumnName = "CreateOn")]
public DateTime CreateOn { get; set; }
/// <summary>
///
///</summary>
[SugarColumn(ColumnName = "ModifyBy")]
public string ModifyBy { get; set; }
/// <summary>
///
///</summary>
[SugarColumn(ColumnName = "ModifyOn")]
public DateTime? ModifyOn { get; set; }
/// <summary>
///
///</summary>
[SugarColumn(ColumnName = "LastLoginTime")]
public DateTime? LastLoginTime { get; set; }
/// <summary>
///
///</summary>
[SugarColumn(ColumnName = "LastLogoutTime")]
public DateTime? LastLogoutTime { get; set; }
/// <summary>
///
///</summary>
[SugarColumn(ColumnName = "LastPwdAlterTime")]
public DateTime? LastPwdAlterTime { get; set; }
/// <summary>
/// 用户所属组织(预留)
///</summary>
[SugarColumn(ColumnName = "Org")]
public string Org { get; set; }
/// <summary>
/// 备注
///</summary>
[SugarColumn(ColumnName = "Note")]
public string Note { get; set; }
/// <summary>
///
/// 默认值: ('N')
///</summary>
[SugarColumn(ColumnName = "PwdFirstAltered")]
public string PwdFirstAltered { get; set; }
/// <summary>
///
///</summary>
[SugarColumn(ColumnName = "IDCard")]
public string IDCard { get; set; }
}
}

View File

@ -1,4 +1,5 @@
using System.IO;
using System;
using System.IO;
using System.IO.Compression;
using System.Runtime.Serialization.Formatters.Binary;
@ -85,5 +86,24 @@ namespace DeviceRepair.Utils
}
}
}
/// <summary>
/// 将传入字符串以GZip算法压缩后返回Base64编码字符
/// </summary>
/// <param name="rawString">需要压缩的字符串</param>
/// <returns>压缩后的Base64编码的字符串</returns>
public static string GZipCompressString(string rawString)
{
if (string.IsNullOrEmpty(rawString) || rawString.Length == 0)
{
return "";
}
else
{
byte[] rawData = System.Text.Encoding.UTF8.GetBytes(rawString.ToString());
byte[] zippedData = Compress(rawData);
return (string)(Convert.ToBase64String(zippedData));
}
}
}
}

View File

@ -72,14 +72,14 @@
<!--<add key="Conn" value="Server=192.168.10.5;Database=DriveMaintenance;User=sa;Password=niaokang123;"/>-->
<!--<add key="ServiceName" value="DeviceRepairAPI" />-->
<!--<add key="ServiceIP" value="localhost" />
<add key="ServiceName" value="DeviceRepairAPI" />-->
<add key="ServiceIP" value="localhost" />
<add key="ServiceName" value="DeviceRepairAPI" />
<!--<add key="ServiceIP" value="www.clovejunti.cn:8181" />
<add key="ServiceName" value="DeviceRepairAPI2"/>-->
<add key="ServiceIP" value="193.112.23.48:8081" />
<add key="ServiceName" value="DeviceRepairApi2" />
<!--<add key="ServiceIP" value="193.112.23.48:8081" />
<add key="ServiceName" value="DeviceRepairApi2" />-->
<add key="SecureKey" value="A4E3uxwPTQ8Jpi7Sp4" />
<add key="ConnType" value="api" />

View File

@ -10,6 +10,7 @@ using System.Net;
using System.Net.Http;
using System.Text;
using System.Threading.Tasks;
using System.Linq;
namespace DeviceRepairAndOptimization.Biz
{
@ -45,6 +46,16 @@ namespace DeviceRepairAndOptimization.Biz
if (string.IsNullOrEmpty(ServiceUrl))
throw new Exception("调用API失败,参数ServiceUrl不能为null!");
if (item.IsGzip)
item.Header.Add("Accept-Encoding", "gzip, deflate");
else
{
if (item.Header.AllKeys.Any(x => x.Equals("Accept-Encoding")))
{
item.Header.Remove("item.Header");
}
}
item.Header.Add("auth", GlobalInfo.token);
item.Header.Add("Operator", GlobalInfo.CurrentUser == null ? "" : GlobalInfo.CurrentUser?.AutoID + "");
item.Header.Add("OperatorCode", GlobalInfo.CurrentUser == null ? "" : EncryptionHelper.UrlEncry(GlobalInfo.CurrentUser?.LoginCode));

View File

@ -24,6 +24,40 @@ namespace DeviceRepairAndOptimization.Biz
}
}
/// <summary>
/// 获取设备路径
/// </summary>
/// <returns></returns>
public APIResponseData GetDeviceRoute()
{
APIResponseData apiResponseData = new APIResponseData { Code = -1, Message = "没有查询到数据!" };
try
{
switch (DeviceRepair.Utils.Config.Configurations.Properties.ConnType?.ToLower())
{
case "api":
apiResponseData = ApiHelper.Instance.SendMessage(new HttpItem
{
URL = ServiceRouteConstValue.GetDeviceRoute,
Method = "Get",
ContentType = "application/json; charset=utf-8"
});
break;
case "sql":
apiResponseData = DeviceAccess.Instance.GetDeviceRoute();
break;
default:
break;
}
}
catch (Exception ex)
{
apiResponseData.Code = -1;
apiResponseData.Message = ex.Message;
}
return apiResponseData;
}
/// <summary>
/// 通过设备编号查询设备信息
/// </summary>

View File

@ -1,12 +1,9 @@
using CsharpHttpHelper;
using CsharpHttpHelper.Enum;
using DeviceRepair.DataAccess;
using DeviceRepair.Models;
using Newtonsoft.Json;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace DeviceRepairAndOptimization.Biz
{
@ -36,14 +33,19 @@ namespace DeviceRepairAndOptimization.Biz
switch (DeviceRepair.Utils.Config.Configurations.Properties.ConnType?.ToLower())
{
case "api":
apiResponseData = ApiHelper.Instance.SendMessage(new HttpItem
HttpItem item = new HttpItem
{
URL = $"{ServiceRouteConstValue.GetMaintenanceDatas}",
Method = "Post",
ContentType = "application/json; charset=utf-8",
Postdata = JsonConvert.SerializeObject(FilterInfo)
});
ContentType = "text/json",
Postdata = JsonConvert.SerializeObject(FilterInfo),
//IsGzip = true,
//Encoding = System.Text.Encoding.UTF8,
//Accept = "text/html, application/xhtml+xml, */*",
//ResultType = ResultType.String
};
apiResponseData = ApiHelper.Instance.SendMessage(item);
break;

View File

@ -410,6 +410,12 @@
<Compile Include="Pages\DriveInformation\page_DriveListInfo.Designer.cs">
<DependentUpon>page_DriveListInfo.cs</DependentUpon>
</Compile>
<Compile Include="Pages\DriveInformation\pageRouteAssign.cs">
<SubType>Form</SubType>
</Compile>
<Compile Include="Pages\DriveInformation\pageRouteAssign.Designer.cs">
<DependentUpon>pageRouteAssign.cs</DependentUpon>
</Compile>
<Compile Include="Pages\DriveMaintenance\page_AssignDriveTree.cs">
<SubType>Form</SubType>
</Compile>
@ -675,6 +681,9 @@
<EmbeddedResource Include="Pages\DriveInformation\page_DriveListInfo.resx">
<DependentUpon>page_DriveListInfo.cs</DependentUpon>
</EmbeddedResource>
<EmbeddedResource Include="Pages\DriveInformation\pageRouteAssign.resx">
<DependentUpon>pageRouteAssign.cs</DependentUpon>
</EmbeddedResource>
<EmbeddedResource Include="Pages\DriveMaintenance\Page_AssignDrives.resx">
<DependentUpon>Page_AssignDrives.cs</DependentUpon>
</EmbeddedResource>

View File

@ -175,13 +175,13 @@
// gridControl1
//
this.gridControl1.EmbeddedNavigator.Margin = new System.Windows.Forms.Padding(2);
this.gridControl1.Location = new System.Drawing.Point(12, 13);
this.gridControl1.Location = new System.Drawing.Point(12, 12);
this.gridControl1.MainView = this.gridView1;
this.gridControl1.Margin = new System.Windows.Forms.Padding(2);
this.gridControl1.Name = "gridControl1";
this.gridControl1.RepositoryItems.AddRange(new DevExpress.XtraEditors.Repository.RepositoryItem[] {
this.reposBtnStatus});
this.gridControl1.Size = new System.Drawing.Size(1011, 529);
this.gridControl1.Size = new System.Drawing.Size(1011, 531);
this.gridControl1.TabIndex = 4;
this.gridControl1.ViewCollection.AddRange(new DevExpress.XtraGrid.Views.Base.BaseView[] {
this.gridView1});
@ -337,7 +337,7 @@
this.layoutControlItem1.Control = this.gridControl1;
this.layoutControlItem1.Location = new System.Drawing.Point(0, 0);
this.layoutControlItem1.Name = "layoutControlItem1";
this.layoutControlItem1.Size = new System.Drawing.Size(1015, 533);
this.layoutControlItem1.Size = new System.Drawing.Size(1015, 535);
this.layoutControlItem1.TextSize = new System.Drawing.Size(0, 0);
this.layoutControlItem1.TextVisible = false;
//

View File

@ -176,15 +176,7 @@ namespace DeviceRepairAndOptimization.Pages.CustomField
try
{
string RoleCode = "";
//配件维护
if (FieldCode.ToUpper() == "ACCESSORIES")
{
RoleCode = "BIZ_FIELD_ACCESSORIES_ADD";
}
else
{
RoleCode = $"BIZ_FIELD_{FieldCode.ToUpper()}_EDIT";
}
RoleCode = $"BIZ_FIELD_{FieldCode.ToUpper()}_ADD";
if (!GlobalInfo.HasRole(RoleCode))
{
@ -353,19 +345,37 @@ namespace DeviceRepairAndOptimization.Pages.CustomField
throw new Exception($"当前账号缺少此操作的权限");
}
getRemark:
if (XtraMessageBoxHelper.AskYesNo($"<size=16>确认<b>{(CurrentFieldInfo.Status ? "<color=red><color/>" : "<color=LimeGreen><color/>")}<b/>字段{CurrentFieldInfo.FieldText} - {CurrentFieldInfo.FieldValue}?<size/>") == DialogResult.Yes)
{
// 录入原因
string result = XtraInputBox.Show("原因录入:", $"请录入字段{(CurrentFieldInfo.Status ? "" : "")}原因", "");
if (string.IsNullOrWhiteSpace(result))
XtraInputBoxArgs args = new XtraInputBoxArgs { Prompt = "原因录入:", Caption = $"请录入字段{(CurrentFieldInfo.Status ? "" : "")}原因", DefaultResponse = "" };
args.Buttons = new DialogResult[] { DialogResult.OK, DialogResult.Cancel };
args.DefaultButtonIndex = (int)DialogResult.Cancel;
// 声明默认返回值
DialogResult DiaResult = DialogResult.None;
args.Showing += (a, b) =>
{
//选中ok按钮将返回值变量改变为ok。
b.Buttons[DialogResult.OK].Click += (c, d) => { DiaResult = DialogResult.OK; };
};
getRemark:
DiaResult = DialogResult.None;
// 显示对话框
var Description = XtraInputBox.Show(args);
string DescriptionValue = Description + "";
// 判断点击的按钮
if (DiaResult == DialogResult.None)
return;
if (string.IsNullOrWhiteSpace(DescriptionValue))
{
if (XtraMessageBoxHelper.AskYesNo("原因不能为空,是否继续操作?") == DialogResult.Yes)
goto getRemark;
return;
}
if (result.Length > 200)
if (DescriptionValue.Length >= 3800)
{
if (XtraMessageBoxHelper.AskYesNo("原因描述超出长度最大长度为200") == DialogResult.Yes)
goto getRemark;
@ -373,9 +383,8 @@ namespace DeviceRepairAndOptimization.Pages.CustomField
}
bool BeStatus = !CurrentFieldInfo.Status;
string Description = result;
APIResponseData apiResponseData = FieldsManager.Instance.ChangeStatus(CurrentFieldInfo.AutoID, BeStatus, Description);
APIResponseData apiResponseData = FieldsManager.Instance.ChangeStatus(CurrentFieldInfo.AutoID, BeStatus, DescriptionValue);
if (!apiResponseData.IsSuccess)
throw new Exception(apiResponseData.Message);

View File

@ -87,13 +87,15 @@
this.layoutControlItem17 = new DevExpress.XtraLayout.LayoutControlItem();
this.layoutControlItem18 = new DevExpress.XtraLayout.LayoutControlItem();
this.layoutControlItem19 = new DevExpress.XtraLayout.LayoutControlItem();
this.layoutControlItem2 = new DevExpress.XtraLayout.LayoutControlItem();
this.layoutControlItem77 = new DevExpress.XtraLayout.LayoutControlItem();
this.Root = new DevExpress.XtraLayout.LayoutControlGroup();
this.layoutControlItem1 = new DevExpress.XtraLayout.LayoutControlItem();
this.layoutControlItem7 = new DevExpress.XtraLayout.LayoutControlItem();
this.splashScreenManager1 = new DevExpress.XtraSplashScreen.SplashScreenManager(this, typeof(global::DeviceRepairAndOptimization.frmWaiting), true, true);
this.dxErrorProvider1 = new DevExpress.XtraEditors.DXErrorProvider.DXErrorProvider(this.components);
this.layoutControlItem2 = new DevExpress.XtraLayout.LayoutControlItem();
this.txt_Route = new DevExpress.XtraEditors.ButtonEdit();
this.layoutControlItem20 = new DevExpress.XtraLayout.LayoutControlItem();
stackPanel1 = new DevExpress.Utils.Layout.StackPanel();
((System.ComponentModel.ISupportInitialize)(stackPanel1)).BeginInit();
stackPanel1.SuspendLayout();
@ -136,12 +138,14 @@
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem17)).BeginInit();
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem18)).BeginInit();
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem19)).BeginInit();
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem2)).BeginInit();
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem77)).BeginInit();
((System.ComponentModel.ISupportInitialize)(this.Root)).BeginInit();
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem1)).BeginInit();
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem7)).BeginInit();
((System.ComponentModel.ISupportInitialize)(this.dxErrorProvider1)).BeginInit();
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem2)).BeginInit();
((System.ComponentModel.ISupportInitialize)(this.txt_Route.Properties)).BeginInit();
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem20)).BeginInit();
this.SuspendLayout();
//
// stackPanel1
@ -149,26 +153,29 @@
stackPanel1.Controls.Add(this.btn_Cancel);
stackPanel1.Controls.Add(this.btn_Submit);
stackPanel1.LayoutDirection = DevExpress.Utils.Layout.StackPanelLayoutDirection.RightToLeft;
stackPanel1.Location = new System.Drawing.Point(464, 503);
stackPanel1.Location = new System.Drawing.Point(360, 425);
stackPanel1.Margin = new System.Windows.Forms.Padding(2, 2, 2, 2);
stackPanel1.Name = "stackPanel1";
stackPanel1.Size = new System.Drawing.Size(448, 56);
stackPanel1.Size = new System.Drawing.Size(347, 46);
stackPanel1.TabIndex = 21;
//
// btn_Cancel
//
this.btn_Cancel.DialogResult = System.Windows.Forms.DialogResult.Cancel;
this.btn_Cancel.Location = new System.Drawing.Point(332, 6);
this.btn_Cancel.Location = new System.Drawing.Point(257, 5);
this.btn_Cancel.Margin = new System.Windows.Forms.Padding(2, 2, 2, 2);
this.btn_Cancel.Name = "btn_Cancel";
this.btn_Cancel.Size = new System.Drawing.Size(113, 43);
this.btn_Cancel.Size = new System.Drawing.Size(88, 36);
this.btn_Cancel.TabIndex = 0;
this.btn_Cancel.Text = "取消";
this.btn_Cancel.Click += new System.EventHandler(this.btn_Cancel_Click);
//
// btn_Submit
//
this.btn_Submit.Location = new System.Drawing.Point(213, 6);
this.btn_Submit.Location = new System.Drawing.Point(165, 5);
this.btn_Submit.Margin = new System.Windows.Forms.Padding(2, 2, 2, 2);
this.btn_Submit.Name = "btn_Submit";
this.btn_Submit.Size = new System.Drawing.Size(113, 43);
this.btn_Submit.Size = new System.Drawing.Size(88, 36);
this.btn_Submit.TabIndex = 1;
this.btn_Submit.Text = "提交";
this.btn_Submit.Click += new System.EventHandler(this.btn_Submit_Click);
@ -178,6 +185,7 @@
this.layoutControl1.Controls.Add(this.layoutControl2);
this.layoutControl1.Dock = System.Windows.Forms.DockStyle.Fill;
this.layoutControl1.Location = new System.Drawing.Point(0, 0);
this.layoutControl1.Margin = new System.Windows.Forms.Padding(2, 2, 2, 2);
this.layoutControl1.Name = "layoutControl1";
this.layoutControl1.OptionsPrint.AppearanceGroupCaption.BackColor = System.Drawing.Color.LightGray;
this.layoutControl1.OptionsPrint.AppearanceGroupCaption.Font = new System.Drawing.Font("Microsoft Sans Serif", 10.25F);
@ -187,12 +195,13 @@
this.layoutControl1.OptionsPrint.AppearanceGroupCaption.TextOptions.HAlignment = DevExpress.Utils.HorzAlignment.Center;
this.layoutControl1.OptionsPrint.AppearanceGroupCaption.TextOptions.VAlignment = DevExpress.Utils.VertAlignment.Center;
this.layoutControl1.Root = this.Root;
this.layoutControl1.Size = new System.Drawing.Size(948, 595);
this.layoutControl1.Size = new System.Drawing.Size(737, 501);
this.layoutControl1.TabIndex = 0;
this.layoutControl1.Text = "layoutControl1";
//
// layoutControl2
//
this.layoutControl2.Controls.Add(this.txt_Route);
this.layoutControl2.Controls.Add(this.txt_UsingDate);
this.layoutControl2.Controls.Add(stackPanel1);
this.layoutControl2.Controls.Add(this.txt_EquipmentID);
@ -211,7 +220,8 @@
this.layoutControl2.Controls.Add(this.txt_Remarks);
this.layoutControl2.Controls.Add(this.btn_SelectFormRev);
this.layoutControl2.Controls.Add(this.ck_EquipmentStatus);
this.layoutControl2.Location = new System.Drawing.Point(12, 12);
this.layoutControl2.Location = new System.Drawing.Point(10, 10);
this.layoutControl2.Margin = new System.Windows.Forms.Padding(2, 2, 2, 2);
this.layoutControl2.Name = "layoutControl2";
this.layoutControl2.OptionsCustomizationForm.DesignTimeCustomizationFormPositionAndSize = new System.Drawing.Rectangle(1108, 339, 812, 500);
this.layoutControl2.OptionsPrint.AppearanceGroupCaption.BackColor = System.Drawing.Color.LightGray;
@ -222,94 +232,103 @@
this.layoutControl2.OptionsPrint.AppearanceGroupCaption.TextOptions.HAlignment = DevExpress.Utils.HorzAlignment.Center;
this.layoutControl2.OptionsPrint.AppearanceGroupCaption.TextOptions.VAlignment = DevExpress.Utils.VertAlignment.Center;
this.layoutControl2.Root = this.layoutControlGroup1;
this.layoutControl2.Size = new System.Drawing.Size(924, 571);
this.layoutControl2.Size = new System.Drawing.Size(717, 481);
this.layoutControl2.TabIndex = 4;
this.layoutControl2.Text = "layoutControl2";
//
// txt_UsingDate
//
this.txt_UsingDate.EditValue = 0D;
this.txt_UsingDate.Location = new System.Drawing.Point(169, 169);
this.txt_UsingDate.Location = new System.Drawing.Point(134, 140);
this.txt_UsingDate.Margin = new System.Windows.Forms.Padding(2, 2, 2, 2);
this.txt_UsingDate.Name = "txt_UsingDate";
this.txt_UsingDate.Properties.Buttons.AddRange(new DevExpress.XtraEditors.Controls.EditorButton[] {
new DevExpress.XtraEditors.Controls.EditorButton(DevExpress.XtraEditors.Controls.ButtonPredefines.Combo)});
this.txt_UsingDate.Properties.CalendarTimeProperties.Buttons.AddRange(new DevExpress.XtraEditors.Controls.EditorButton[] {
new DevExpress.XtraEditors.Controls.EditorButton(DevExpress.XtraEditors.Controls.ButtonPredefines.Combo)});
this.txt_UsingDate.Size = new System.Drawing.Size(291, 24);
this.txt_UsingDate.Size = new System.Drawing.Size(222, 22);
this.txt_UsingDate.StyleController = this.layoutControl2;
this.txt_UsingDate.TabIndex = 22;
//
// txt_EquipmentID
//
this.txt_EquipmentID.Location = new System.Drawing.Point(169, 22);
this.txt_EquipmentID.Location = new System.Drawing.Point(484, 19);
this.txt_EquipmentID.Margin = new System.Windows.Forms.Padding(2, 2, 2, 2);
this.txt_EquipmentID.Name = "txt_EquipmentID";
this.txt_EquipmentID.Size = new System.Drawing.Size(291, 24);
this.txt_EquipmentID.Size = new System.Drawing.Size(223, 22);
this.txt_EquipmentID.StyleController = this.layoutControl2;
this.txt_EquipmentID.TabIndex = 4;
//
// txt_EquipmentName
//
this.txt_EquipmentName.Location = new System.Drawing.Point(169, 71);
this.txt_EquipmentName.Location = new System.Drawing.Point(134, 58);
this.txt_EquipmentName.Margin = new System.Windows.Forms.Padding(2, 2, 2, 2);
this.txt_EquipmentName.Name = "txt_EquipmentName";
this.txt_EquipmentName.Size = new System.Drawing.Size(291, 24);
this.txt_EquipmentName.Size = new System.Drawing.Size(222, 22);
this.txt_EquipmentName.StyleController = this.layoutControl2;
this.txt_EquipmentName.TabIndex = 5;
//
// txt_Specification
//
this.txt_Specification.Location = new System.Drawing.Point(621, 71);
this.txt_Specification.Location = new System.Drawing.Point(484, 58);
this.txt_Specification.Margin = new System.Windows.Forms.Padding(2, 2, 2, 2);
this.txt_Specification.Name = "txt_Specification";
this.txt_Specification.Size = new System.Drawing.Size(291, 24);
this.txt_Specification.Size = new System.Drawing.Size(223, 22);
this.txt_Specification.StyleController = this.layoutControl2;
this.txt_Specification.TabIndex = 6;
//
// txt_Manufacturer
//
this.txt_Manufacturer.Location = new System.Drawing.Point(169, 120);
this.txt_Manufacturer.Location = new System.Drawing.Point(134, 99);
this.txt_Manufacturer.Margin = new System.Windows.Forms.Padding(2, 2, 2, 2);
this.txt_Manufacturer.Name = "txt_Manufacturer";
this.txt_Manufacturer.Size = new System.Drawing.Size(291, 24);
this.txt_Manufacturer.Size = new System.Drawing.Size(222, 22);
this.txt_Manufacturer.StyleController = this.layoutControl2;
this.txt_Manufacturer.TabIndex = 7;
//
// txt_SerialNumber
//
this.txt_SerialNumber.Location = new System.Drawing.Point(621, 120);
this.txt_SerialNumber.Location = new System.Drawing.Point(484, 99);
this.txt_SerialNumber.Margin = new System.Windows.Forms.Padding(2, 2, 2, 2);
this.txt_SerialNumber.Name = "txt_SerialNumber";
this.txt_SerialNumber.Size = new System.Drawing.Size(291, 24);
this.txt_SerialNumber.Size = new System.Drawing.Size(223, 22);
this.txt_SerialNumber.StyleController = this.layoutControl2;
this.txt_SerialNumber.TabIndex = 8;
//
// txt_Totalcapacity
//
this.txt_Totalcapacity.EditValue = 0D;
this.txt_Totalcapacity.Location = new System.Drawing.Point(621, 169);
this.txt_Totalcapacity.Location = new System.Drawing.Point(484, 140);
this.txt_Totalcapacity.Margin = new System.Windows.Forms.Padding(2, 2, 2, 2);
this.txt_Totalcapacity.Name = "txt_Totalcapacity";
this.txt_Totalcapacity.Properties.BeepOnError = false;
this.txt_Totalcapacity.Properties.MaskSettings.Set("MaskManagerType", typeof(DevExpress.Data.Mask.NumericMaskManager));
this.txt_Totalcapacity.Properties.MaskSettings.Set("MaskManagerSignature", "allowNull=False");
this.txt_Totalcapacity.Properties.MaskSettings.Set("mask", "f");
this.txt_Totalcapacity.Size = new System.Drawing.Size(291, 24);
this.txt_Totalcapacity.Size = new System.Drawing.Size(223, 22);
this.txt_Totalcapacity.StyleController = this.layoutControl2;
this.txt_Totalcapacity.TabIndex = 10;
//
// txt_Weight
//
this.txt_Weight.EditValue = 0D;
this.txt_Weight.Location = new System.Drawing.Point(169, 218);
this.txt_Weight.Location = new System.Drawing.Point(134, 181);
this.txt_Weight.Margin = new System.Windows.Forms.Padding(2, 2, 2, 2);
this.txt_Weight.Name = "txt_Weight";
this.txt_Weight.Properties.MaskSettings.Set("MaskManagerType", typeof(DevExpress.Data.Mask.NumericMaskManager));
this.txt_Weight.Properties.MaskSettings.Set("MaskManagerSignature", "allowNull=False");
this.txt_Weight.Properties.MaskSettings.Set("mask", "f");
this.txt_Weight.Size = new System.Drawing.Size(291, 24);
this.txt_Weight.Size = new System.Drawing.Size(222, 22);
this.txt_Weight.StyleController = this.layoutControl2;
this.txt_Weight.TabIndex = 11;
//
// txt_EquipmentCategory
//
this.txt_EquipmentCategory.Location = new System.Drawing.Point(621, 218);
this.txt_EquipmentCategory.Location = new System.Drawing.Point(484, 181);
this.txt_EquipmentCategory.Margin = new System.Windows.Forms.Padding(2, 2, 2, 2);
this.txt_EquipmentCategory.Name = "txt_EquipmentCategory";
this.txt_EquipmentCategory.Properties.BeepOnError = false;
this.txt_EquipmentCategory.Size = new System.Drawing.Size(291, 24);
this.txt_EquipmentCategory.Size = new System.Drawing.Size(223, 22);
this.txt_EquipmentCategory.StyleController = this.layoutControl2;
this.txt_EquipmentCategory.TabIndex = 12;
//
@ -320,65 +339,72 @@
0,
0,
0});
this.txt_EquipmentOriginalvalue.Location = new System.Drawing.Point(169, 267);
this.txt_EquipmentOriginalvalue.Location = new System.Drawing.Point(134, 222);
this.txt_EquipmentOriginalvalue.Margin = new System.Windows.Forms.Padding(2, 2, 2, 2);
this.txt_EquipmentOriginalvalue.Name = "txt_EquipmentOriginalvalue";
this.txt_EquipmentOriginalvalue.Properties.BeepOnError = false;
this.txt_EquipmentOriginalvalue.Properties.MaskSettings.Set("MaskManagerType", typeof(DevExpress.Data.Mask.NumericMaskManager));
this.txt_EquipmentOriginalvalue.Properties.MaskSettings.Set("MaskManagerSignature", "allowNull=False");
this.txt_EquipmentOriginalvalue.Properties.MaskSettings.Set("mask", "f");
this.txt_EquipmentOriginalvalue.Size = new System.Drawing.Size(291, 24);
this.txt_EquipmentOriginalvalue.Size = new System.Drawing.Size(222, 22);
this.txt_EquipmentOriginalvalue.StyleController = this.layoutControl2;
this.txt_EquipmentOriginalvalue.TabIndex = 13;
//
// txt_WarrantyPeriod
//
this.txt_WarrantyPeriod.Location = new System.Drawing.Point(169, 316);
this.txt_WarrantyPeriod.Location = new System.Drawing.Point(134, 263);
this.txt_WarrantyPeriod.Margin = new System.Windows.Forms.Padding(2, 2, 2, 2);
this.txt_WarrantyPeriod.Name = "txt_WarrantyPeriod";
this.txt_WarrantyPeriod.Size = new System.Drawing.Size(291, 24);
this.txt_WarrantyPeriod.Size = new System.Drawing.Size(222, 22);
this.txt_WarrantyPeriod.StyleController = this.layoutControl2;
this.txt_WarrantyPeriod.TabIndex = 15;
//
// txt_InstallationLocation
//
this.txt_InstallationLocation.Location = new System.Drawing.Point(621, 316);
this.txt_InstallationLocation.Location = new System.Drawing.Point(484, 263);
this.txt_InstallationLocation.Margin = new System.Windows.Forms.Padding(2, 2, 2, 2);
this.txt_InstallationLocation.Name = "txt_InstallationLocation";
this.txt_InstallationLocation.Size = new System.Drawing.Size(291, 24);
this.txt_InstallationLocation.Size = new System.Drawing.Size(223, 22);
this.txt_InstallationLocation.StyleController = this.layoutControl2;
this.txt_InstallationLocation.TabIndex = 16;
//
// txt_OwningUnit
//
this.txt_OwningUnit.Location = new System.Drawing.Point(169, 365);
this.txt_OwningUnit.Location = new System.Drawing.Point(134, 304);
this.txt_OwningUnit.Margin = new System.Windows.Forms.Padding(2, 2, 2, 2);
this.txt_OwningUnit.Name = "txt_OwningUnit";
this.txt_OwningUnit.Size = new System.Drawing.Size(291, 24);
this.txt_OwningUnit.Size = new System.Drawing.Size(222, 22);
this.txt_OwningUnit.StyleController = this.layoutControl2;
this.txt_OwningUnit.TabIndex = 17;
//
// txt_OperatingParameters
//
this.txt_OperatingParameters.Location = new System.Drawing.Point(621, 365);
this.txt_OperatingParameters.Location = new System.Drawing.Point(484, 304);
this.txt_OperatingParameters.Margin = new System.Windows.Forms.Padding(2, 2, 2, 2);
this.txt_OperatingParameters.Name = "txt_OperatingParameters";
this.txt_OperatingParameters.Size = new System.Drawing.Size(291, 24);
this.txt_OperatingParameters.Size = new System.Drawing.Size(223, 22);
this.txt_OperatingParameters.StyleController = this.layoutControl2;
this.txt_OperatingParameters.TabIndex = 18;
//
// txt_Remarks
//
this.txt_Remarks.Location = new System.Drawing.Point(169, 464);
this.txt_Remarks.Location = new System.Drawing.Point(134, 389);
this.txt_Remarks.Margin = new System.Windows.Forms.Padding(2, 2, 2, 2);
this.txt_Remarks.Name = "txt_Remarks";
this.txt_Remarks.Properties.MaxLength = 2000;
this.txt_Remarks.Size = new System.Drawing.Size(743, 24);
this.txt_Remarks.Size = new System.Drawing.Size(573, 22);
this.txt_Remarks.StyleController = this.layoutControl2;
this.txt_Remarks.TabIndex = 20;
//
// btn_SelectFormRev
//
this.btn_SelectFormRev.Location = new System.Drawing.Point(169, 414);
this.btn_SelectFormRev.Location = new System.Drawing.Point(134, 345);
this.btn_SelectFormRev.Margin = new System.Windows.Forms.Padding(2, 2, 2, 2);
this.btn_SelectFormRev.Name = "btn_SelectFormRev";
this.btn_SelectFormRev.Properties.Buttons.AddRange(new DevExpress.XtraEditors.Controls.EditorButton[] {
new DevExpress.XtraEditors.Controls.EditorButton(DevExpress.XtraEditors.Controls.ButtonPredefines.Ellipsis, "", 30, true, true, false, editorButtonImageOptions1, new DevExpress.Utils.KeyShortcut(System.Windows.Forms.Keys.None), serializableAppearanceObject1, serializableAppearanceObject2, serializableAppearanceObject3, serializableAppearanceObject4, "", null, null, DevExpress.Utils.ToolTipAnchor.Default)});
this.btn_SelectFormRev.Properties.ReadOnly = true;
this.btn_SelectFormRev.Size = new System.Drawing.Size(743, 24);
this.btn_SelectFormRev.Size = new System.Drawing.Size(573, 22);
this.btn_SelectFormRev.StyleController = this.layoutControl2;
this.btn_SelectFormRev.TabIndex = 19;
this.btn_SelectFormRev.ButtonClick += new DevExpress.XtraEditors.Controls.ButtonPressedEventHandler(this.btn_SelectFormRev_ButtonClick);
@ -386,14 +412,15 @@
// ck_EquipmentStatus
//
this.ck_EquipmentStatus.EditValue = true;
this.ck_EquipmentStatus.Location = new System.Drawing.Point(621, 257);
this.ck_EquipmentStatus.Location = new System.Drawing.Point(484, 215);
this.ck_EquipmentStatus.Margin = new System.Windows.Forms.Padding(2, 2, 2, 2);
this.ck_EquipmentStatus.Name = "ck_EquipmentStatus";
this.ck_EquipmentStatus.Properties.Appearance.BackColor = System.Drawing.SystemColors.Control;
this.ck_EquipmentStatus.Properties.Appearance.Options.UseBackColor = true;
this.ck_EquipmentStatus.Properties.Items.AddRange(new DevExpress.XtraEditors.Controls.RadioGroupItem[] {
new DevExpress.XtraEditors.Controls.RadioGroupItem(true, "启用"),
new DevExpress.XtraEditors.Controls.RadioGroupItem(false, "停用")});
this.ck_EquipmentStatus.Size = new System.Drawing.Size(291, 45);
this.ck_EquipmentStatus.Size = new System.Drawing.Size(223, 37);
this.ck_EquipmentStatus.StyleController = this.layoutControl2;
this.ck_EquipmentStatus.TabIndex = 14;
//
@ -418,8 +445,9 @@
this.layoutControlItem17,
this.layoutControlItem18,
this.layoutControlItem19,
this.layoutControlItem77,
this.layoutControlItem2,
this.layoutControlItem77});
this.layoutControlItem20});
this.layoutControlGroup1.LayoutMode = DevExpress.XtraLayout.Utils.LayoutMode.Table;
this.layoutControlGroup1.Name = "Root";
columnDefinition1.SizeType = System.Windows.Forms.SizeType.Percent;
@ -449,7 +477,7 @@
rowDefinition9.SizeType = System.Windows.Forms.SizeType.Percent;
rowDefinition10.Height = 100D;
rowDefinition10.SizeType = System.Windows.Forms.SizeType.Percent;
rowDefinition11.Height = 60D;
rowDefinition11.Height = 50D;
rowDefinition11.SizeType = System.Windows.Forms.SizeType.Absolute;
this.layoutControlGroup1.OptionsTableLayoutGroup.RowDefinitions.AddRange(new DevExpress.XtraLayout.RowDefinition[] {
rowDefinition1,
@ -463,217 +491,204 @@
rowDefinition9,
rowDefinition10,
rowDefinition11});
this.layoutControlGroup1.Size = new System.Drawing.Size(924, 571);
this.layoutControlGroup1.Size = new System.Drawing.Size(717, 481);
this.layoutControlGroup1.TextVisible = false;
//
// layoutControlItem3
//
this.layoutControlItem3.ContentVertAlignment = DevExpress.Utils.VertAlignment.Center;
this.layoutControlItem3.Control = this.txt_EquipmentName;
this.layoutControlItem3.Location = new System.Drawing.Point(0, 49);
this.layoutControlItem3.Location = new System.Drawing.Point(0, 41);
this.layoutControlItem3.Name = "layoutControlItem3";
this.layoutControlItem3.OptionsTableLayoutItem.RowIndex = 1;
this.layoutControlItem3.Size = new System.Drawing.Size(452, 49);
this.layoutControlItem3.Size = new System.Drawing.Size(350, 41);
this.layoutControlItem3.Text = "设备名称:";
this.layoutControlItem3.TextSize = new System.Drawing.Size(145, 18);
this.layoutControlItem3.TextSize = new System.Drawing.Size(115, 15);
//
// layoutControlItem4
//
this.layoutControlItem4.ContentVertAlignment = DevExpress.Utils.VertAlignment.Center;
this.layoutControlItem4.Control = this.txt_Specification;
this.layoutControlItem4.Location = new System.Drawing.Point(452, 49);
this.layoutControlItem4.Location = new System.Drawing.Point(350, 41);
this.layoutControlItem4.Name = "layoutControlItem4";
this.layoutControlItem4.OptionsTableLayoutItem.ColumnIndex = 1;
this.layoutControlItem4.OptionsTableLayoutItem.RowIndex = 1;
this.layoutControlItem4.Size = new System.Drawing.Size(452, 49);
this.layoutControlItem4.Size = new System.Drawing.Size(351, 41);
this.layoutControlItem4.Text = "设备型号规格:";
this.layoutControlItem4.TextSize = new System.Drawing.Size(145, 18);
this.layoutControlItem4.TextSize = new System.Drawing.Size(115, 15);
//
// layoutControlItem5
//
this.layoutControlItem5.ContentVertAlignment = DevExpress.Utils.VertAlignment.Center;
this.layoutControlItem5.Control = this.txt_Manufacturer;
this.layoutControlItem5.Location = new System.Drawing.Point(0, 98);
this.layoutControlItem5.Location = new System.Drawing.Point(0, 82);
this.layoutControlItem5.Name = "layoutControlItem5";
this.layoutControlItem5.OptionsTableLayoutItem.RowIndex = 2;
this.layoutControlItem5.Size = new System.Drawing.Size(452, 49);
this.layoutControlItem5.Size = new System.Drawing.Size(350, 41);
this.layoutControlItem5.Text = "制造厂家:";
this.layoutControlItem5.TextSize = new System.Drawing.Size(145, 18);
this.layoutControlItem5.TextSize = new System.Drawing.Size(115, 15);
//
// layoutControlItem6
//
this.layoutControlItem6.ContentVertAlignment = DevExpress.Utils.VertAlignment.Center;
this.layoutControlItem6.Control = this.txt_SerialNumber;
this.layoutControlItem6.Location = new System.Drawing.Point(452, 98);
this.layoutControlItem6.Location = new System.Drawing.Point(350, 82);
this.layoutControlItem6.Name = "layoutControlItem6";
this.layoutControlItem6.OptionsTableLayoutItem.ColumnIndex = 1;
this.layoutControlItem6.OptionsTableLayoutItem.RowIndex = 2;
this.layoutControlItem6.Size = new System.Drawing.Size(452, 49);
this.layoutControlItem6.Size = new System.Drawing.Size(351, 41);
this.layoutControlItem6.Text = "出厂编号:";
this.layoutControlItem6.TextSize = new System.Drawing.Size(145, 18);
this.layoutControlItem6.TextSize = new System.Drawing.Size(115, 15);
//
// layoutControlItem8
//
this.layoutControlItem8.ContentVertAlignment = DevExpress.Utils.VertAlignment.Center;
this.layoutControlItem8.Control = this.txt_Totalcapacity;
this.layoutControlItem8.Location = new System.Drawing.Point(452, 147);
this.layoutControlItem8.Location = new System.Drawing.Point(350, 123);
this.layoutControlItem8.Name = "layoutControlItem8";
this.layoutControlItem8.OptionsTableLayoutItem.ColumnIndex = 1;
this.layoutControlItem8.OptionsTableLayoutItem.RowIndex = 3;
this.layoutControlItem8.Size = new System.Drawing.Size(452, 49);
this.layoutControlItem8.Size = new System.Drawing.Size(351, 41);
this.layoutControlItem8.Text = "设备总容量KW";
this.layoutControlItem8.TextSize = new System.Drawing.Size(145, 18);
this.layoutControlItem8.TextSize = new System.Drawing.Size(115, 15);
//
// layoutControlItem9
//
this.layoutControlItem9.ContentVertAlignment = DevExpress.Utils.VertAlignment.Center;
this.layoutControlItem9.Control = this.txt_Weight;
this.layoutControlItem9.Location = new System.Drawing.Point(0, 196);
this.layoutControlItem9.Location = new System.Drawing.Point(0, 164);
this.layoutControlItem9.Name = "layoutControlItem9";
this.layoutControlItem9.OptionsTableLayoutItem.RowIndex = 4;
this.layoutControlItem9.Size = new System.Drawing.Size(452, 49);
this.layoutControlItem9.Size = new System.Drawing.Size(350, 41);
this.layoutControlItem9.Text = "设备重量(吨):";
this.layoutControlItem9.TextSize = new System.Drawing.Size(145, 18);
this.layoutControlItem9.TextSize = new System.Drawing.Size(115, 15);
//
// layoutControlItem10
//
this.layoutControlItem10.ContentVertAlignment = DevExpress.Utils.VertAlignment.Center;
this.layoutControlItem10.Control = this.txt_EquipmentCategory;
this.layoutControlItem10.Location = new System.Drawing.Point(452, 196);
this.layoutControlItem10.Location = new System.Drawing.Point(350, 164);
this.layoutControlItem10.Name = "layoutControlItem10";
this.layoutControlItem10.OptionsTableLayoutItem.ColumnIndex = 1;
this.layoutControlItem10.OptionsTableLayoutItem.RowIndex = 4;
this.layoutControlItem10.Size = new System.Drawing.Size(452, 49);
this.layoutControlItem10.Size = new System.Drawing.Size(351, 41);
this.layoutControlItem10.Text = "设备类别:";
this.layoutControlItem10.TextSize = new System.Drawing.Size(145, 18);
this.layoutControlItem10.TextSize = new System.Drawing.Size(115, 15);
//
// layoutControlItem11
//
this.layoutControlItem11.ContentVertAlignment = DevExpress.Utils.VertAlignment.Center;
this.layoutControlItem11.Control = this.txt_EquipmentOriginalvalue;
this.layoutControlItem11.Location = new System.Drawing.Point(0, 245);
this.layoutControlItem11.Location = new System.Drawing.Point(0, 205);
this.layoutControlItem11.Name = "layoutControlItem11";
this.layoutControlItem11.OptionsTableLayoutItem.RowIndex = 5;
this.layoutControlItem11.Size = new System.Drawing.Size(452, 49);
this.layoutControlItem11.Size = new System.Drawing.Size(350, 41);
this.layoutControlItem11.Text = "设备原值(万元):";
this.layoutControlItem11.TextSize = new System.Drawing.Size(145, 18);
this.layoutControlItem11.TextSize = new System.Drawing.Size(115, 15);
//
// layoutControlItem12
//
this.layoutControlItem12.ContentVertAlignment = DevExpress.Utils.VertAlignment.Center;
this.layoutControlItem12.Control = this.ck_EquipmentStatus;
this.layoutControlItem12.Location = new System.Drawing.Point(452, 245);
this.layoutControlItem12.Location = new System.Drawing.Point(350, 205);
this.layoutControlItem12.Name = "layoutControlItem12";
this.layoutControlItem12.OptionsTableLayoutItem.ColumnIndex = 1;
this.layoutControlItem12.OptionsTableLayoutItem.RowIndex = 5;
this.layoutControlItem12.Size = new System.Drawing.Size(452, 49);
this.layoutControlItem12.Size = new System.Drawing.Size(351, 41);
this.layoutControlItem12.Text = "设备状态:";
this.layoutControlItem12.TextSize = new System.Drawing.Size(145, 18);
this.layoutControlItem12.TextSize = new System.Drawing.Size(115, 15);
//
// layoutControlItem13
//
this.layoutControlItem13.ContentVertAlignment = DevExpress.Utils.VertAlignment.Center;
this.layoutControlItem13.Control = this.txt_WarrantyPeriod;
this.layoutControlItem13.Location = new System.Drawing.Point(0, 294);
this.layoutControlItem13.Location = new System.Drawing.Point(0, 246);
this.layoutControlItem13.Name = "layoutControlItem13";
this.layoutControlItem13.OptionsTableLayoutItem.RowIndex = 6;
this.layoutControlItem13.Size = new System.Drawing.Size(452, 49);
this.layoutControlItem13.Size = new System.Drawing.Size(350, 41);
this.layoutControlItem13.Text = "质保期:";
this.layoutControlItem13.TextSize = new System.Drawing.Size(145, 18);
this.layoutControlItem13.TextSize = new System.Drawing.Size(115, 15);
//
// layoutControlItem14
//
this.layoutControlItem14.ContentVertAlignment = DevExpress.Utils.VertAlignment.Center;
this.layoutControlItem14.Control = this.txt_InstallationLocation;
this.layoutControlItem14.Location = new System.Drawing.Point(452, 294);
this.layoutControlItem14.Location = new System.Drawing.Point(350, 246);
this.layoutControlItem14.Name = "layoutControlItem14";
this.layoutControlItem14.OptionsTableLayoutItem.ColumnIndex = 1;
this.layoutControlItem14.OptionsTableLayoutItem.RowIndex = 6;
this.layoutControlItem14.Size = new System.Drawing.Size(452, 49);
this.layoutControlItem14.Size = new System.Drawing.Size(351, 41);
this.layoutControlItem14.Text = "安装地点:";
this.layoutControlItem14.TextSize = new System.Drawing.Size(145, 18);
this.layoutControlItem14.TextSize = new System.Drawing.Size(115, 15);
//
// layoutControlItem15
//
this.layoutControlItem15.ContentVertAlignment = DevExpress.Utils.VertAlignment.Center;
this.layoutControlItem15.Control = this.txt_OwningUnit;
this.layoutControlItem15.Location = new System.Drawing.Point(0, 343);
this.layoutControlItem15.Location = new System.Drawing.Point(0, 287);
this.layoutControlItem15.Name = "layoutControlItem15";
this.layoutControlItem15.OptionsTableLayoutItem.RowIndex = 7;
this.layoutControlItem15.Size = new System.Drawing.Size(452, 49);
this.layoutControlItem15.Size = new System.Drawing.Size(350, 41);
this.layoutControlItem15.Text = "所属单元:";
this.layoutControlItem15.TextSize = new System.Drawing.Size(145, 18);
this.layoutControlItem15.TextSize = new System.Drawing.Size(115, 15);
//
// layoutControlItem16
//
this.layoutControlItem16.ContentVertAlignment = DevExpress.Utils.VertAlignment.Center;
this.layoutControlItem16.Control = this.txt_OperatingParameters;
this.layoutControlItem16.Location = new System.Drawing.Point(452, 343);
this.layoutControlItem16.Location = new System.Drawing.Point(350, 287);
this.layoutControlItem16.Name = "layoutControlItem16";
this.layoutControlItem16.OptionsTableLayoutItem.ColumnIndex = 1;
this.layoutControlItem16.OptionsTableLayoutItem.RowIndex = 7;
this.layoutControlItem16.Size = new System.Drawing.Size(452, 49);
this.layoutControlItem16.Size = new System.Drawing.Size(351, 41);
this.layoutControlItem16.Text = "运行参数:";
this.layoutControlItem16.TextSize = new System.Drawing.Size(145, 18);
this.layoutControlItem16.TextSize = new System.Drawing.Size(115, 15);
//
// layoutControlItem17
//
this.layoutControlItem17.ContentVertAlignment = DevExpress.Utils.VertAlignment.Center;
this.layoutControlItem17.Control = this.btn_SelectFormRev;
this.layoutControlItem17.Location = new System.Drawing.Point(0, 392);
this.layoutControlItem17.Location = new System.Drawing.Point(0, 328);
this.layoutControlItem17.Name = "layoutControlItem17";
this.layoutControlItem17.OptionsTableLayoutItem.ColumnSpan = 2;
this.layoutControlItem17.OptionsTableLayoutItem.RowIndex = 8;
this.layoutControlItem17.Size = new System.Drawing.Size(904, 49);
this.layoutControlItem17.Size = new System.Drawing.Size(701, 41);
this.layoutControlItem17.Text = "保养使用的表单:";
this.layoutControlItem17.TextSize = new System.Drawing.Size(145, 18);
this.layoutControlItem17.TextSize = new System.Drawing.Size(115, 15);
//
// layoutControlItem18
//
this.layoutControlItem18.ContentVertAlignment = DevExpress.Utils.VertAlignment.Center;
this.layoutControlItem18.Control = this.txt_Remarks;
this.layoutControlItem18.Location = new System.Drawing.Point(0, 441);
this.layoutControlItem18.Location = new System.Drawing.Point(0, 369);
this.layoutControlItem18.Name = "layoutControlItem18";
this.layoutControlItem18.OptionsTableLayoutItem.ColumnSpan = 2;
this.layoutControlItem18.OptionsTableLayoutItem.RowIndex = 9;
this.layoutControlItem18.Size = new System.Drawing.Size(904, 50);
this.layoutControlItem18.Size = new System.Drawing.Size(701, 46);
this.layoutControlItem18.Text = "备注:";
this.layoutControlItem18.TextSize = new System.Drawing.Size(145, 18);
this.layoutControlItem18.TextSize = new System.Drawing.Size(115, 15);
//
// layoutControlItem19
//
this.layoutControlItem19.Control = stackPanel1;
this.layoutControlItem19.Location = new System.Drawing.Point(452, 491);
this.layoutControlItem19.Location = new System.Drawing.Point(350, 415);
this.layoutControlItem19.Name = "layoutControlItem19";
this.layoutControlItem19.OptionsTableLayoutItem.ColumnIndex = 1;
this.layoutControlItem19.OptionsTableLayoutItem.RowIndex = 10;
this.layoutControlItem19.Size = new System.Drawing.Size(452, 60);
this.layoutControlItem19.Size = new System.Drawing.Size(351, 50);
this.layoutControlItem19.TextSize = new System.Drawing.Size(0, 0);
this.layoutControlItem19.TextVisible = false;
//
// layoutControlItem2
//
this.layoutControlItem2.ContentVertAlignment = DevExpress.Utils.VertAlignment.Center;
this.layoutControlItem2.Control = this.txt_EquipmentID;
this.layoutControlItem2.Location = new System.Drawing.Point(0, 0);
this.layoutControlItem2.MaxSize = new System.Drawing.Size(0, 28);
this.layoutControlItem2.MinSize = new System.Drawing.Size(223, 28);
this.layoutControlItem2.Name = "layoutControlItem2";
this.layoutControlItem2.Size = new System.Drawing.Size(452, 49);
this.layoutControlItem2.SizeConstraintsType = DevExpress.XtraLayout.SizeConstraintsType.Custom;
this.layoutControlItem2.Text = "设备编号:";
this.layoutControlItem2.TextSize = new System.Drawing.Size(145, 18);
//
// layoutControlItem77
//
this.layoutControlItem77.ContentVertAlignment = DevExpress.Utils.VertAlignment.Center;
this.layoutControlItem77.Control = this.txt_UsingDate;
this.layoutControlItem77.Location = new System.Drawing.Point(0, 147);
this.layoutControlItem77.Location = new System.Drawing.Point(0, 123);
this.layoutControlItem77.Name = "layoutControlItem77";
this.layoutControlItem77.OptionsTableLayoutItem.RowIndex = 3;
this.layoutControlItem77.Size = new System.Drawing.Size(452, 49);
this.layoutControlItem77.Size = new System.Drawing.Size(350, 41);
this.layoutControlItem77.Text = "投产年月:";
this.layoutControlItem77.TextSize = new System.Drawing.Size(145, 18);
this.layoutControlItem77.TextSize = new System.Drawing.Size(115, 15);
//
// Root
//
@ -682,7 +697,7 @@
this.Root.Items.AddRange(new DevExpress.XtraLayout.BaseLayoutItem[] {
this.layoutControlItem1});
this.Root.Name = "Root";
this.Root.Size = new System.Drawing.Size(948, 595);
this.Root.Size = new System.Drawing.Size(737, 501);
this.Root.TextVisible = false;
//
// layoutControlItem1
@ -690,7 +705,7 @@
this.layoutControlItem1.Control = this.layoutControl2;
this.layoutControlItem1.Location = new System.Drawing.Point(0, 0);
this.layoutControlItem1.Name = "layoutControlItem1";
this.layoutControlItem1.Size = new System.Drawing.Size(928, 575);
this.layoutControlItem1.Size = new System.Drawing.Size(721, 485);
this.layoutControlItem1.TextSize = new System.Drawing.Size(0, 0);
this.layoutControlItem1.TextVisible = false;
//
@ -712,17 +727,55 @@
//
this.dxErrorProvider1.ContainerControl = this;
//
// layoutControlItem2
//
this.layoutControlItem2.ContentVertAlignment = DevExpress.Utils.VertAlignment.Center;
this.layoutControlItem2.Control = this.txt_EquipmentID;
this.layoutControlItem2.Location = new System.Drawing.Point(350, 0);
this.layoutControlItem2.MaxSize = new System.Drawing.Size(0, 23);
this.layoutControlItem2.MinSize = new System.Drawing.Size(173, 23);
this.layoutControlItem2.Name = "layoutControlItem2";
this.layoutControlItem2.OptionsTableLayoutItem.ColumnIndex = 1;
this.layoutControlItem2.Size = new System.Drawing.Size(351, 41);
this.layoutControlItem2.SizeConstraintsType = DevExpress.XtraLayout.SizeConstraintsType.Custom;
this.layoutControlItem2.Text = "设备编号:";
this.layoutControlItem2.TextSize = new System.Drawing.Size(115, 15);
//
// txt_Route
//
this.txt_Route.Location = new System.Drawing.Point(134, 17);
this.txt_Route.Name = "txt_Route";
this.txt_Route.Properties.Buttons.AddRange(new DevExpress.XtraEditors.Controls.EditorButton[] {
new DevExpress.XtraEditors.Controls.EditorButton()});
this.txt_Route.Properties.TextEditStyle = DevExpress.XtraEditors.Controls.TextEditStyles.DisableTextEditor;
this.txt_Route.Size = new System.Drawing.Size(222, 22);
this.txt_Route.StyleController = this.layoutControl2;
this.txt_Route.TabIndex = 23;
this.txt_Route.ButtonClick += new DevExpress.XtraEditors.Controls.ButtonPressedEventHandler(this.buttonEdit1_ButtonClick);
//
// layoutControlItem20
//
this.layoutControlItem20.ContentHorzAlignment = DevExpress.Utils.HorzAlignment.Center;
this.layoutControlItem20.ContentVertAlignment = DevExpress.Utils.VertAlignment.Center;
this.layoutControlItem20.Control = this.txt_Route;
this.layoutControlItem20.Location = new System.Drawing.Point(0, 0);
this.layoutControlItem20.Name = "layoutControlItem20";
this.layoutControlItem20.Size = new System.Drawing.Size(350, 41);
this.layoutControlItem20.Text = "父级分类:";
this.layoutControlItem20.TextSize = new System.Drawing.Size(115, 15);
//
// Page_DriveInfoEdit
//
this.AcceptButton = this.btn_Submit;
this.AutoScaleDimensions = new System.Drawing.SizeF(9F, 18F);
this.AutoScaleDimensions = new System.Drawing.SizeF(7F, 15F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.CancelButton = this.btn_Cancel;
this.ClientSize = new System.Drawing.Size(948, 595);
this.ClientSize = new System.Drawing.Size(737, 501);
this.Controls.Add(this.layoutControl1);
this.DoubleBuffered = true;
this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedSingle;
this.IconOptions.SvgImage = ((DevExpress.Utils.Svg.SvgImage)(resources.GetObject("Page_DriveInfoEdit.IconOptions.SvgImage")));
this.Margin = new System.Windows.Forms.Padding(2, 2, 2, 2);
this.Name = "Page_DriveInfoEdit";
this.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen;
this.Text = "Page_DriveInfoEdit";
@ -768,12 +821,14 @@
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem17)).EndInit();
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem18)).EndInit();
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem19)).EndInit();
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem2)).EndInit();
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem77)).EndInit();
((System.ComponentModel.ISupportInitialize)(this.Root)).EndInit();
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem1)).EndInit();
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem7)).EndInit();
((System.ComponentModel.ISupportInitialize)(this.dxErrorProvider1)).EndInit();
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem2)).EndInit();
((System.ComponentModel.ISupportInitialize)(this.txt_Route.Properties)).EndInit();
((System.ComponentModel.ISupportInitialize)(this.layoutControlItem20)).EndInit();
this.ResumeLayout(false);
}
@ -821,9 +876,11 @@
private DevExpress.XtraLayout.LayoutControlItem layoutControlItem17;
private DevExpress.XtraLayout.LayoutControlItem layoutControlItem18;
private DevExpress.XtraLayout.LayoutControlItem layoutControlItem19;
private DevExpress.XtraLayout.LayoutControlItem layoutControlItem2;
private DevExpress.XtraEditors.DateEdit txt_UsingDate;
private DevExpress.XtraLayout.LayoutControlItem layoutControlItem7;
private DevExpress.XtraLayout.LayoutControlItem layoutControlItem77;
private DevExpress.XtraEditors.ButtonEdit txt_Route;
private DevExpress.XtraLayout.LayoutControlItem layoutControlItem2;
private DevExpress.XtraLayout.LayoutControlItem layoutControlItem20;
}
}

View File

@ -9,6 +9,7 @@ using DeviceRepairAndOptimization.Biz;
using DeviceRepair.Utils;
using DeviceRepair.Models.Common;
using Newtonsoft.Json.Linq;
using DeviceRepairAndOptimization.Pages.DriveMaintenance;
namespace DeviceRepairAndOptimization.Pages.DriveInformation
{
@ -37,6 +38,9 @@ namespace DeviceRepairAndOptimization.Pages.DriveInformation
private void BindDatas()
{
txt_Route.EditValue = CurrentModel.RouteText;
txt_Route.Tag = CurrentModel.Route;
// 设备编号
txt_EquipmentID.Enabled = false;
txt_EquipmentID.Text = CurrentModel.EquipmentID;
@ -201,6 +205,17 @@ namespace DeviceRepairAndOptimization.Pages.DriveInformation
Remarks = txt_Remarks.Text
};
#region
int Route = 0;
if (txt_Route.Tag == null || !int.TryParse(txt_Route.Tag + "", out Route) || Route <= 0)
{
dxErrorProvider1.SetError(txt_Route, "设备父级分类不能为空!", DevExpress.XtraEditors.DXErrorProvider.ErrorType.Warning);
return false;
}
t2.Route = Route;
#endregion
#region
if (CurrentModel.AutoID == 0)
{
@ -446,5 +461,23 @@ namespace DeviceRepairAndOptimization.Pages.DriveInformation
return false;
}
}
/// <summary>
/// 选则父级
/// </summary>
/// <param name="sender"></param>
/// <param name="e"></param>
private void buttonEdit1_ButtonClick(object sender, DevExpress.XtraEditors.Controls.ButtonPressedEventArgs e)
{
using (pageRouteAssign view = new pageRouteAssign((CurrentModel?.Route ?? 0)))
{
if (view.ShowDialog() == DialogResult.OK)
{
txt_Route.EditValue = view.CurrentSelectModel.Name;
txt_Route.Tag = view.CurrentSelectModel.AutoID;
}
}
}
}
}

View File

@ -121,7 +121,7 @@
<value>False</value>
</metadata>
<metadata name="dxErrorProvider1.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<value>245, 17</value>
<value>205, 17</value>
</metadata>
<assembly alias="DevExpress.Data.v20.2" name="DevExpress.Data.v20.2, Version=20.2.3.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" />
<data name="Page_DriveInfoEdit.IconOptions.SvgImage" type="DevExpress.Utils.Svg.SvgImage, DevExpress.Data.v20.2" mimetype="application/x-microsoft.net.object.bytearray.base64">

View File

@ -0,0 +1,188 @@

namespace DeviceRepairAndOptimization.Pages.DriveMaintenance
{
partial class pageRouteAssign
{
/// <summary>
/// Required designer variable.
/// </summary>
private System.ComponentModel.IContainer components = null;
/// <summary>
/// Clean up any resources being used.
/// </summary>
/// <param name="disposing">true if managed resources should be disposed; otherwise, false.</param>
protected override void Dispose(bool disposing)
{
if (disposing && (components != null))
{
components.Dispose();
}
base.Dispose(disposing);
}
#region Windows Form Designer generated code
/// <summary>
/// Required method for Designer support - do not modify
/// the contents of this method with the code editor.
/// </summary>
private void InitializeComponent()
{
this.components = new System.ComponentModel.Container();
System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(pageRouteAssign));
this.toolbarFormControl1 = new DevExpress.XtraBars.ToolbarForm.ToolbarFormControl();
this.toolbarFormManager1 = new DevExpress.XtraBars.ToolbarForm.ToolbarFormManager(this.components);
this.barDockControlTop = new DevExpress.XtraBars.BarDockControl();
this.barDockControlBottom = new DevExpress.XtraBars.BarDockControl();
this.barDockControlLeft = new DevExpress.XtraBars.BarDockControl();
this.barDockControlRight = new DevExpress.XtraBars.BarDockControl();
this.barButtonItem1 = new DevExpress.XtraBars.BarButtonItem();
this.splashScreenManager1 = new DevExpress.XtraSplashScreen.SplashScreenManager(this, typeof(global::DeviceRepairAndOptimization.frmWaiting), true, true);
this.treeList1 = new DevExpress.XtraTreeList.TreeList();
this.treeListColumn1 = new DevExpress.XtraTreeList.Columns.TreeListColumn();
((System.ComponentModel.ISupportInitialize)(this.toolbarFormControl1)).BeginInit();
((System.ComponentModel.ISupportInitialize)(this.toolbarFormManager1)).BeginInit();
((System.ComponentModel.ISupportInitialize)(this.treeList1)).BeginInit();
this.SuspendLayout();
//
// toolbarFormControl1
//
this.toolbarFormControl1.Location = new System.Drawing.Point(0, 0);
this.toolbarFormControl1.Manager = this.toolbarFormManager1;
this.toolbarFormControl1.Margin = new System.Windows.Forms.Padding(4);
this.toolbarFormControl1.Name = "toolbarFormControl1";
this.toolbarFormControl1.Size = new System.Drawing.Size(560, 31);
this.toolbarFormControl1.TabIndex = 0;
this.toolbarFormControl1.TabStop = false;
this.toolbarFormControl1.TitleItemLinks.Add(this.barButtonItem1);
this.toolbarFormControl1.ToolbarForm = this;
//
// toolbarFormManager1
//
this.toolbarFormManager1.DockControls.Add(this.barDockControlTop);
this.toolbarFormManager1.DockControls.Add(this.barDockControlBottom);
this.toolbarFormManager1.DockControls.Add(this.barDockControlLeft);
this.toolbarFormManager1.DockControls.Add(this.barDockControlRight);
this.toolbarFormManager1.Form = this;
this.toolbarFormManager1.Items.AddRange(new DevExpress.XtraBars.BarItem[] {
this.barButtonItem1});
this.toolbarFormManager1.MaxItemId = 1;
//
// barDockControlTop
//
this.barDockControlTop.CausesValidation = false;
this.barDockControlTop.Dock = System.Windows.Forms.DockStyle.Top;
this.barDockControlTop.Location = new System.Drawing.Point(0, 31);
this.barDockControlTop.Manager = this.toolbarFormManager1;
this.barDockControlTop.Margin = new System.Windows.Forms.Padding(4);
this.barDockControlTop.Size = new System.Drawing.Size(560, 0);
//
// barDockControlBottom
//
this.barDockControlBottom.CausesValidation = false;
this.barDockControlBottom.Dock = System.Windows.Forms.DockStyle.Bottom;
this.barDockControlBottom.Location = new System.Drawing.Point(0, 654);
this.barDockControlBottom.Manager = this.toolbarFormManager1;
this.barDockControlBottom.Margin = new System.Windows.Forms.Padding(4);
this.barDockControlBottom.Size = new System.Drawing.Size(560, 0);
//
// barDockControlLeft
//
this.barDockControlLeft.CausesValidation = false;
this.barDockControlLeft.Dock = System.Windows.Forms.DockStyle.Left;
this.barDockControlLeft.Location = new System.Drawing.Point(0, 31);
this.barDockControlLeft.Manager = this.toolbarFormManager1;
this.barDockControlLeft.Margin = new System.Windows.Forms.Padding(4);
this.barDockControlLeft.Size = new System.Drawing.Size(0, 623);
//
// barDockControlRight
//
this.barDockControlRight.CausesValidation = false;
this.barDockControlRight.Dock = System.Windows.Forms.DockStyle.Right;
this.barDockControlRight.Location = new System.Drawing.Point(560, 31);
this.barDockControlRight.Manager = this.toolbarFormManager1;
this.barDockControlRight.Margin = new System.Windows.Forms.Padding(4);
this.barDockControlRight.Size = new System.Drawing.Size(0, 623);
//
// barButtonItem1
//
this.barButtonItem1.Caption = "提交";
this.barButtonItem1.Id = 0;
this.barButtonItem1.ImageOptions.Image = ((System.Drawing.Image)(resources.GetObject("barButtonItem1.ImageOptions.Image")));
this.barButtonItem1.ImageOptions.LargeImage = ((System.Drawing.Image)(resources.GetObject("barButtonItem1.ImageOptions.LargeImage")));
this.barButtonItem1.Name = "barButtonItem1";
this.barButtonItem1.PaintStyle = DevExpress.XtraBars.BarItemPaintStyle.CaptionGlyph;
this.barButtonItem1.ItemClick += new DevExpress.XtraBars.ItemClickEventHandler(this.barButtonItem1_ItemClick);
//
// splashScreenManager1
//
this.splashScreenManager1.ClosingDelay = 500;
//
// treeList1
//
this.treeList1.Columns.AddRange(new DevExpress.XtraTreeList.Columns.TreeListColumn[] {
this.treeListColumn1});
this.treeList1.Dock = System.Windows.Forms.DockStyle.Fill;
this.treeList1.Location = new System.Drawing.Point(0, 31);
this.treeList1.MenuManager = this.toolbarFormManager1;
this.treeList1.Name = "treeList1";
this.treeList1.OptionsView.CheckBoxStyle = DevExpress.XtraTreeList.DefaultNodeCheckBoxStyle.Radio;
this.treeList1.OptionsView.RootCheckBoxStyle = DevExpress.XtraTreeList.NodeCheckBoxStyle.None;
this.treeList1.Size = new System.Drawing.Size(560, 623);
this.treeList1.TabIndex = 6;
this.treeList1.FocusedNodeChanged += new DevExpress.XtraTreeList.FocusedNodeChangedEventHandler(this.treeList1_FocusedNodeChanged);
this.treeList1.CustomDrawNodeCheckBox += new DevExpress.XtraTreeList.CustomDrawNodeCheckBoxEventHandler(this.treeList1_CustomDrawNodeCheckBox);
//
// treeListColumn1
//
this.treeListColumn1.Caption = "名称";
this.treeListColumn1.FieldName = "Name";
this.treeListColumn1.Name = "treeListColumn1";
this.treeListColumn1.OptionsColumn.ReadOnly = true;
this.treeListColumn1.Visible = true;
this.treeListColumn1.VisibleIndex = 0;
//
// pageRouteAssign
//
this.Appearance.Options.UseFont = true;
this.AutoScaleDimensions = new System.Drawing.SizeF(9F, 18F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.ClientSize = new System.Drawing.Size(560, 654);
this.Controls.Add(this.treeList1);
this.Controls.Add(this.barDockControlLeft);
this.Controls.Add(this.barDockControlRight);
this.Controls.Add(this.barDockControlBottom);
this.Controls.Add(this.barDockControlTop);
this.Controls.Add(this.toolbarFormControl1);
this.DoubleBuffered = true;
this.Font = new System.Drawing.Font("Microsoft Sans Serif", 11.2F);
this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedSingle;
this.IconOptions.Image = ((System.Drawing.Image)(resources.GetObject("pageRouteAssign.IconOptions.Image")));
this.Margin = new System.Windows.Forms.Padding(4);
this.Name = "pageRouteAssign";
this.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen;
this.Text = "设备信息组";
this.ToolbarFormControl = this.toolbarFormControl1;
((System.ComponentModel.ISupportInitialize)(this.toolbarFormControl1)).EndInit();
((System.ComponentModel.ISupportInitialize)(this.toolbarFormManager1)).EndInit();
((System.ComponentModel.ISupportInitialize)(this.treeList1)).EndInit();
this.ResumeLayout(false);
this.PerformLayout();
}
#endregion
private DevExpress.XtraBars.ToolbarForm.ToolbarFormControl toolbarFormControl1;
private DevExpress.XtraBars.ToolbarForm.ToolbarFormManager toolbarFormManager1;
private DevExpress.XtraBars.BarDockControl barDockControlTop;
private DevExpress.XtraBars.BarDockControl barDockControlBottom;
private DevExpress.XtraBars.BarDockControl barDockControlLeft;
private DevExpress.XtraBars.BarDockControl barDockControlRight;
private DevExpress.XtraSplashScreen.SplashScreenManager splashScreenManager1;
private DevExpress.XtraTreeList.TreeList treeList1;
private DevExpress.XtraTreeList.Columns.TreeListColumn treeListColumn1;
private DevExpress.XtraBars.BarButtonItem barButtonItem1;
}
}

View File

@ -0,0 +1,114 @@
using DevExpress.XtraBars.ToolbarForm;
using DevExpress.XtraTreeList.Nodes;
using DeviceRepair.Models;
using DeviceRepairAndOptimization.Biz;
using DeviceRepairAndOptimization.Common;
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Forms;
namespace DeviceRepairAndOptimization.Pages.DriveMaintenance
{
public partial class pageRouteAssign : ToolbarForm
{
public DeviceRouteInfo CurrentSelectModel = null;
List<DeviceRouteInfo> routes = null;
int CurrentRoute = 0;
public pageRouteAssign(int Route = 0)
{
InitializeComponent();
CurrentRoute = Route;
this.Load += PageRouteAssign_Load;
}
private void PageRouteAssign_Load(object sender, EventArgs e)
{
InitializeTreeDatas();
if (CurrentRoute != 0)
{
foreach (TreeListNode node in treeList1.Nodes)
{
SelectNodeByID(node, CurrentRoute);
}
}
}
private void SelectNodeByID(TreeListNode node, int targetID)
{
// 假设ID存储在节点的第一个列索引0
if (node.GetValue("AutoID")?.ToString() == targetID.ToString())
{
node.Checked = true;
return;
}
// 递归处理子节点
foreach (TreeListNode childNode in node.Nodes)
{
SelectNodeByID(childNode, targetID);
}
}
void InitializeTreeDatas()
{
try
{
APIResponseData apiResponseData = DeviceManager.Instance.GetDeviceRoute();
if (apiResponseData.Code != 1)
{
splashScreenManager1.CloseWaitForm();
XtraMessageBoxHelper.Error(apiResponseData.Message);
return;
}
routes = apiResponseData.ToDeserializeObject<List<DeviceRouteInfo>>();
treeList1.DataSource = routes;
treeList1.KeyFieldName = "AutoID";
treeList1.ParentFieldName = "ParentID";
treeList1.ExpandAll();
}
catch (Exception ex)
{
XtraMessageBoxHelper.Error(ex.Message);
}
}
private void treeList1_CustomDrawNodeCheckBox(object sender, DevExpress.XtraTreeList.CustomDrawNodeCheckBoxEventArgs e)
{
if (e.Node.Level == 1)
{
e.Handled = true;
return;
}
}
private void barButtonItem1_ItemClick(object sender, DevExpress.XtraBars.ItemClickEventArgs e)
{
List<TreeListNode> treeListNodes = treeList1.GetAllCheckedNodes();
if ((treeListNodes?.Count ?? 0) > 0)
{
TreeListNode node = treeListNodes.FirstOrDefault();
CurrentSelectModel = routes.FirstOrDefault(x => x.AutoID == node.Id);
this.DialogResult = DialogResult.OK;
}
else
{
XtraMessageBoxHelper.Warn("选中数据不能为空!");
}
}
private void treeList1_FocusedNodeChanged(object sender, DevExpress.XtraTreeList.FocusedNodeChangedEventArgs e)
{
treeList1.UncheckAll();
e.Node.Checked = true;
}
}
}

View File

@ -0,0 +1,195 @@
<?xml version="1.0" encoding="utf-8"?>
<root>
<!--
Microsoft ResX Schema
Version 2.0
The primary goals of this format is to allow a simple XML format
that is mostly human readable. The generation and parsing of the
various data types are done through the TypeConverter classes
associated with the data types.
Example:
... ado.net/XML headers & schema ...
<resheader name="resmimetype">text/microsoft-resx</resheader>
<resheader name="version">2.0</resheader>
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
<value>[base64 mime encoded serialized .NET Framework object]</value>
</data>
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
<comment>This is a comment</comment>
</data>
There are any number of "resheader" rows that contain simple
name/value pairs.
Each data row contains a name, and value. The row also contains a
type or mimetype. Type corresponds to a .NET class that support
text/value conversion through the TypeConverter architecture.
Classes that don't support this are serialized and stored with the
mimetype set.
The mimetype is used for serialized objects, and tells the
ResXResourceReader how to depersist the object. This is currently not
extensible. For a given mimetype the value must be set accordingly:
Note - application/x-microsoft.net.object.binary.base64 is the format
that the ResXResourceWriter will generate, however the reader can
read any of the formats listed below.
mimetype: application/x-microsoft.net.object.binary.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.soap.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.bytearray.base64
value : The object must be serialized into a byte array
: using a System.ComponentModel.TypeConverter
: and then encoded with base64 encoding.
-->
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
<xsd:element name="root" msdata:IsDataSet="true">
<xsd:complexType>
<xsd:choice maxOccurs="unbounded">
<xsd:element name="metadata">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" />
</xsd:sequence>
<xsd:attribute name="name" use="required" type="xsd:string" />
<xsd:attribute name="type" type="xsd:string" />
<xsd:attribute name="mimetype" type="xsd:string" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="assembly">
<xsd:complexType>
<xsd:attribute name="alias" type="xsd:string" />
<xsd:attribute name="name" type="xsd:string" />
</xsd:complexType>
</xsd:element>
<xsd:element name="data">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="resheader">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" />
</xsd:complexType>
</xsd:element>
</xsd:choice>
</xsd:complexType>
</xsd:element>
</xsd:schema>
<resheader name="resmimetype">
<value>text/microsoft-resx</value>
</resheader>
<resheader name="version">
<value>2.0</value>
</resheader>
<resheader name="reader">
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<resheader name="writer">
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<metadata name="toolbarFormManager1.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<value>205, 17</value>
</metadata>
<assembly alias="System.Drawing" name="System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />
<data name="pageRouteAssign.IconOptions.Image" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value>
iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAABGdBTUEAALGPC/xhBQAAABl0RVh0U29m
dHdhcmUAQWRvYmUgSW1hZ2VSZWFkeXHJZTwAAAASdEVYdFRpdGxlAFNwcmVhZHNoZWV0O5hnIwkAAAJx
SURBVDhPjZLdS9NhFMd/pmVTa2rdhP4LOU1wqZiltm6K+ZLZRlYMCpXQtLml82UkLXFJhJCiy8hi9qLo
0FWi0VKjCLqSlIhKL3vX4dyb8e2c30Y4LejAh+c5z/me77l4jgDgn1CEERHEliCRQfi+mQgLaThUeAGK
AqYGivxqdoho7Zx4bu52YD1XboxPiiZrDRT5NTiorBbylOdFKCJbro9TaWM0tT/mAVtZtIkIZ/KUVeLU
YM7vEuO1Mfj8v7Di8cMVhPMGs521EqH5Zq7DeCsXzb25aOrNQaMlBw09Oajr2u8gQQxP8vlXA81uH5bd
fngpr28dYYMowdB9AAtLjwg75heZUcz/HEFtRxYLpIY2O6xDb2DpfwWL9aVID6E32bgeLbBwasGAyfl6
ZKsT4fikx7OPOlRezWBBXB1N8vpW4VzxwukK4KFc2zLM9Rihsj0DTz9oodbLoNInQaVLwtj7SpSZ0lgQ
r7tsExuWXD44l710BgxqjINc3yaUm+R48q4Cc1/v4ph2N+a+3Mbo7BlojKks2Km9NASPlwyoeVHEA7fX
j6rGAa5vFzTGPbDNajD89jRmPlswOHOSOIHS+mTRoJom9Q28RtedF8S0eHb2TeOc4UHAIOt4wkS2KhH7
CLoHKElAZvGuCRLsqGp8CDf9wA+n5w/8pRV199lASogryQshSc0s4UdJMOf3WJ7EDd+X3PjmJOh00VeW
6ftZGxuyiSnpxUhJPyok7yXkRVQXpOUX7wV3IJSztdaNBjJ5EZLlhZClFYiQIOqI2jxZcKoD6zmsapui
enSIwXooeKWjiTgifg2c83v4Xxv/Hwi/AfE7QKNuCEi+AAAAAElFTkSuQmCC
</value>
</data>
<data name="barButtonItem1.ImageOptions.Image" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value>
iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAABGdBTUEAALGPC/xhBQAAABl0RVh0U29m
dHdhcmUAQWRvYmUgSW1hZ2VSZWFkeXHJZTwAAAANdEVYdFRpdGxlAFVwbG9hZDtrfH1EAAACfUlEQVQ4
T22T7UtTcRTH3VaZkdGriqJ/oretuWk1bOlcFsMMJDUf0FmZc25ZUgq9CPOVLIqSwIfN7apzDwZShDh1
StkLIbSV+TArXVhv6t2+nfNbE276hQ/3d8/5nnN/93fuTUvp4u3QFoWOEIcUF+yBSybi3zrN1JSkwObn
vFxcBEBAUhjqeg6VtI1ulLSObuRaug9zLJU3WndqYA+KZCKR4FslPcU78i6G4NtV5Ft9EsVUhGiS1+Bj
j1wmWyBVrDhfL5nbXsxgOv4H4fXfuN81jdzrXjPlRBND/RD75DI2im0pdKWdR4pbQvHJlV8YXkwytvQT
Rc3BuPpKxzHyKNnH5v/FQZXh5qDkiyxjILoJ14cfAs/8JqSJJegtngHy7Ca4iUyiWF/TW3T36RRc79fh
jHxF1+w6nhNiPfMNDmcY2rKuYvJyE9kulCcvtx81OwLxkbkNPJlYw+NwDHf8nwTO8RicdD84+x2mhqH4
CeO941QjzkNUk5Rna72S3iKBrjhT40UnFdmHo3D4ougcW0V2tQfZVf3QVbmRVd7Lr7KL2GrACw6kE5k5
ZH42uYZb0gIxj443K9BWuPkDOUjsI/YQssPkBcPbytBVusVrPHq9LGgnsq65uMF+gh+0fRLayn6+cCJd
U9YzyQUa4lQ50wf11e4pyu1lj7q0l71yFdI/QOIGfMK8zUyCt5ziAMHxHcfIUhQ0BcaNtiDybQHkNfqR
ZyUahgWGep/g3I2BMHm5yTYp9XUS+ubiePhqCQ9Gv6D15SJaQp/R7I/C7vuIxsEF6JKHmZEsIaX+MJIq
p9odPk0TyKFxMdmVNDaCJ6CtcImD1JR2R8ibkaxD2l8LSG3B/RVp8wAAAABJRU5ErkJggg==
</value>
</data>
<data name="barButtonItem1.ImageOptions.LargeImage" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value>
iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAABGdBTUEAALGPC/xhBQAAABl0RVh0U29m
dHdhcmUAQWRvYmUgSW1hZ2VSZWFkeXHJZTwAAAANdEVYdFRpdGxlAFVwbG9hZDtrfH1EAAAHLklEQVRY
R71Wa1BVVRTe2Mtq0t41zfTD+tM01dQPp6xUtOyp9jC1d40oiWEqFylAQETxVY0NYApqiCLce3lzuSCI
gFcQwUAo5K2AwuVNgqDyaPWtfc4lbNNMNk3fzDf7nHX3Xt9ea6+9zhVEdA2vE05j+I+g6CkGHZvjykWw
mVkmNjloAo2nxUZjGU9xCjhQNM+w2zYPzxO89hSKtREFwjO8QBgwGnjcnS88dml0QNFTDDpY7NLw7+MS
cFoefGhysPF0i89PhS2LDaF3sq13aEQwL+r8bVDjqjAbr5FQ9BSDjiBEOla0TyfA6b7BL6poR05FK2WU
NtOqsLwQtvFvDtEeyWHRc3VYuIcc43USip5i0BF4qBSCiGgMARaf4BF6eGpIasWIfWCIGvsHKTi2ZGTp
5qSp+E1ugkW7wa4rGt1+yOW1EoqeYtARcLBEE9bTygQmPDV97kTf/cWllfY+Ot1zlU50XqGy5ovkHpJb
/ujTzrfyHIdw1+Vh0Qm6fn+U10ooeopBx7qoU9pZIpVMgKO/0fPHvDXm/HNU2zdItvYByrH3U1n3Zdp/
pJqWbE5by3N4bgeE2y8PifaBIeGyNZvXSyh6ikGHd2QRznJYEpDnviQwesqG6JL+Jojntw1QdsslyrrQ
R5nn+6iyc4AMYbb+t1bufITn8prW/iHR2j8oPg/OZB8Sip5i0OG156Q8RyYwAbx5ddixlILqDvoZYlkQ
PdzUR9aGXko7d5Gy8Xyk3E6fBlnTMPcWXmO/NCha+gbFx0EZ7ENC0VMMOgzhhfIMAZn6ZVtSFoSlVlBN
zxUpzKIWMLmuh5JqeyixppuKkJHg6FO0YG30Yqy5idee770qPlxvZT8Sip5i0LFmZwEPMvUzF66+z7Ar
317ZdomyG3uvEY2v6iJzZScZKzrJdKaLCht66PNNGfZn5rjcj7WyHhb5WdiXhKKnGHSsDDnOA6f+lmXb
MkOTCpvoBCJMqO6muKpuiHZBsJNifu2g6F/a6WBZOx0obaPkqk6Kyqqhd7zMu7CWb4WsB1BC0VMMf4IX
3fSe594X/COLRspbIQ7nLBjzC0TLIQpGQTSypJX2/WynPcV2ijjZQtl13eT23dER58++fxE+bgY5EAlF
TzFokKl/YMoTdyzdfqTs6Jl2ijzZTN/lNFBY/gWKKG6RYvtOaYI7Cy5QyPHz9O3RBtqUUU/bMs9SQvEF
mm8wV0y6fwq3aXkU7FjRUwwaeMcTP/RL8ApF4aVWdND27HO0JessbT1yjrZi5Gdm8OGztOlwPW1Mr6Mg
ax0FptXReksthWOjgVFFNHtZuC98OY5C1VMMeupnfRTwmPuOvP5jSOeOnEYI1Utu1kcWZQbpwhvSaiFe
SwGpNeSfUkN+oBlHs9Anuf/JV1Y+Dp98FE6KnmLQo/9gvcUSj8JLQ6HFwhEzRmeQVRPeICOupfVMCO8r
bKa9J5opAkeyG0cSfhxjRg05u+7nRnAb+1b0FMPoBjLofXBxQAYt8k+nRX5Wem+dlQ7g/FlUCiPV/hZE
DHG/lGqKQNpf90ik19Yk0qurEugVcM5X8fQyqG/gBkVPMWhHwEXDC+4AJ4N3gw+962Oh+LK20RQz1yXX
kG9SNfmAu2znpSDmPgzeC94FchHeDsrGpOgpBg3yFoC8EeZE8J75XqlkKm2FaDX56vRJrCJvZkIVheY1
0awvzezkPpALj0V5/WgvUPQUgw7He3FTL7+yo3s4uv24dp7mM2ClHA0mjR7GM/L6Pb80xrGBcSP+K1WD
jjc9k+T7ycY/NzDb3SyLzMNYQR4mEOMaZmwFrQa3oAdMc/mPNoBCckQvryV4t/MKM0WgujnSrbj/zC3p
uJZM3IiN4HNLDrETPn+5AVv9b2KayyE8alD0FIOOOaviHdE76mHSs59F5nCEcCgj5ZEFx3LqJ/v4/xcX
rux+uXU9AnY8alD0FIOO2e5x4kTDRf1NXk1uJJNAju4BnQ+OIb9z6llc/h8ARW7tv9jAIn+rWOhnFbj3
YoEv/7+QWWCHHBWnljfzd+Q5PNdp5gqzmLHcKKZ/AbrGwvQPN7BAE7bxvX/b20JvfZ1K879OoXleKfSm
ZzK9YUjSms3qxNFm85J7HM1CkTqvMJGzm4lmLDcRhOlF11h6YVmsDbdD+lb0/mpgvuttESycXdNFWdVd
lInPcDr+dKTho5T6azsllbdRAhpSHHqCscROMada6GBRM0Xhi/kT2vDefLRhWxP9mNdIYbkN9Dzq5bkl
MeNqjWtExIKjTa/skF+/a756GfgG4DsQiIrnb4Bsw+A6tGLuiN7gN2hKXvGVtDaukrZn1jsKdFytcY1z
PZO5D9he99BSPZrmlXFaqtHtnN3MNAOp5jRPdzVymsEYRMs3RLkdx69rAxBGH0gQEBYQFhAWL31pFhAW
M91MYuZykywsnK+AsODzncZ0iZEV/3ccT2tc4/9HEn8AzxGRRmj4WqwAAAAASUVORK5CYII=
</value>
</data>
</root>

View File

@ -115,7 +115,7 @@ namespace DeviceRepairAndOptimization.Pages
tableLayoutPanel1.RowCount = 2;
tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Absolute, 48F));
tableLayoutPanel1.RowStyles.Add(new System.Windows.Forms.RowStyle(System.Windows.Forms.SizeType.Percent, 100F));
tableLayoutPanel1.Size = new System.Drawing.Size(1854, 900);
tableLayoutPanel1.Size = new System.Drawing.Size(1598, 916);
tableLayoutPanel1.TabIndex = 1;
//
// gridControl1
@ -128,7 +128,7 @@ namespace DeviceRepairAndOptimization.Pages
this.gridControl1.RepositoryItems.AddRange(new DevExpress.XtraEditors.Repository.RepositoryItem[] {
this.Operations,
this.btn_DeviceOperations});
this.gridControl1.Size = new System.Drawing.Size(1848, 846);
this.gridControl1.Size = new System.Drawing.Size(1592, 862);
this.gridControl1.TabIndex = 1;
this.gridControl1.ViewCollection.AddRange(new DevExpress.XtraGrid.Views.Base.BaseView[] {
this.gridView1});
@ -393,7 +393,7 @@ namespace DeviceRepairAndOptimization.Pages
flowLayoutPanel1.Controls.Add(this.btn_Filter);
flowLayoutPanel1.Controls.Add(this.EditSearch);
flowLayoutPanel1.FlowDirection = System.Windows.Forms.FlowDirection.RightToLeft;
flowLayoutPanel1.Location = new System.Drawing.Point(1404, 0);
flowLayoutPanel1.Location = new System.Drawing.Point(1148, 0);
flowLayoutPanel1.Margin = new System.Windows.Forms.Padding(0);
flowLayoutPanel1.Name = "flowLayoutPanel1";
flowLayoutPanel1.Padding = new System.Windows.Forms.Padding(7);
@ -432,7 +432,7 @@ namespace DeviceRepairAndOptimization.Pages
stackPanel1.Location = new System.Drawing.Point(0, 0);
stackPanel1.Margin = new System.Windows.Forms.Padding(0);
stackPanel1.Name = "stackPanel1";
stackPanel1.Size = new System.Drawing.Size(1404, 48);
stackPanel1.Size = new System.Drawing.Size(1148, 48);
stackPanel1.TabIndex = 2;
//
// btn_Add
@ -455,7 +455,7 @@ namespace DeviceRepairAndOptimization.Pages
// page_DriveListInfo
//
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.None;
this.ClientSize = new System.Drawing.Size(1854, 900);
this.ClientSize = new System.Drawing.Size(1598, 916);
this.Controls.Add(tableLayoutPanel1);
this.Name = "page_DriveListInfo";
this.Text = "page_DriveListInfo";

View File

@ -203,7 +203,25 @@ namespace DeviceRepairAndOptimization.Pages.Maintain
throw new Exception("请选择要修改的配件行!");
}
int Count = XtraInputBox.Show<int>("请输入配件的数量:", "配件添加", 1);
XtraInputBoxArgs args = new XtraInputBoxArgs { Prompt = "请输入配件的数量:", Caption = "配件添加", DefaultResponse = 1 };
args.Buttons = new DialogResult[] { DialogResult.OK, DialogResult.Cancel };
args.DefaultButtonIndex = (int)DialogResult.Cancel;
// 声明默认返回值
DialogResult DiaResult = DialogResult.None;
args.Showing += (a, b) =>
{
//选中ok按钮将返回值变量改变为ok。
b.Buttons[DialogResult.OK].Click += (c, d) => { DiaResult = DialogResult.OK; };
};
// 显示对话框
int Count = XtraInputBox.Show<int>(args);
// 判断点击的按钮
if (DiaResult == DialogResult.None)
return;
if (Count > 0)
{
CurrentAccessoriesInfoModel.AccessoriesCount = Count;

View File

@ -213,9 +213,10 @@ namespace DeviceRepairAndOptimization.Pages.Maintain
if (DiaResult == DialogResult.None)
return;
else
//int result = XtraInputBox.Show<int>("请输入配件的数量:", "配件添加", 0);
//if (result > 0)
{
if (result <= 0)
throw new Exception("配件的数量必须大于零!");
CurrentAccessories = new DeviceWarrantyRequestAccessoriesInfo
{
AccessoriesCount = result,

View File

@ -311,8 +311,6 @@ namespace DeviceRepairAndOptimization.Pages.Maintain
throw new Exception("获取行数据出错,请重试!");
}
//CurrentObjectInfo = gridView1.GetRow(e.FocusedRowHandle) as DeviceWarrantyRequestFormView;
btn_Maintain.Enabled = CurrentObjectInfo.MaintaionItems == null || CurrentObjectInfo.MaintaionItems.SubmitBy == 0 ? true : false;
btn_ChangeDownStatus.Enabled = CurrentObjectInfo.MaintaionItems == null || CurrentObjectInfo.MaintaionItems?.SubmitBy == 0 ? true : false;

View File

@ -82,12 +82,11 @@
this.layoutControl1.Controls.Add(this.txtRoleName);
this.layoutControl1.Controls.Add(this.txtNote);
this.layoutControl1.Dock = System.Windows.Forms.DockStyle.Fill;
this.layoutControl1.Location = new System.Drawing.Point(0, 39);
this.layoutControl1.Margin = new System.Windows.Forms.Padding(4);
this.layoutControl1.Location = new System.Drawing.Point(0, 31);
this.layoutControl1.Name = "layoutControl1";
this.layoutControl1.OptionsCustomizationForm.DesignTimeCustomizationFormPositionAndSize = new System.Drawing.Rectangle(569, 0, 650, 400);
this.layoutControl1.Root = this.Root;
this.layoutControl1.Size = new System.Drawing.Size(873, 713);
this.layoutControl1.Size = new System.Drawing.Size(679, 596);
this.layoutControl1.TabIndex = 6;
this.layoutControl1.Text = "layoutControl1";
//
@ -96,12 +95,8 @@
this.tvAuths.Columns.AddRange(new DevExpress.XtraTreeList.Columns.TreeListColumn[] {
this.tColumnRoleCode,
this.treeListColumn5});
this.tvAuths.FixedLineWidth = 3;
this.tvAuths.HorzScrollStep = 4;
this.tvAuths.Location = new System.Drawing.Point(24, 125);
this.tvAuths.Margin = new System.Windows.Forms.Padding(4);
this.tvAuths.Location = new System.Drawing.Point(20, 104);
this.tvAuths.MenuManager = this.toolbarFormManager1;
this.tvAuths.MinWidth = 26;
this.tvAuths.Name = "tvAuths";
this.tvAuths.OptionsBehavior.AllowIndeterminateCheckState = true;
this.tvAuths.OptionsBehavior.ReadOnly = true;
@ -111,30 +106,27 @@
this.tvAuths.OptionsFind.AllowFindPanel = false;
this.tvAuths.OptionsView.BestFitNodes = DevExpress.XtraTreeList.TreeListBestFitNodes.All;
this.tvAuths.OptionsView.CheckBoxStyle = DevExpress.XtraTreeList.DefaultNodeCheckBoxStyle.Check;
this.tvAuths.Size = new System.Drawing.Size(825, 564);
this.tvAuths.Size = new System.Drawing.Size(639, 472);
this.tvAuths.TabIndex = 10;
this.tvAuths.TreeLevelWidth = 23;
//
// tColumnRoleCode
//
this.tColumnRoleCode.Caption = "权限编码";
this.tColumnRoleCode.FieldName = "AuthCode";
this.tColumnRoleCode.MinWidth = 26;
this.tColumnRoleCode.Name = "tColumnRoleCode";
this.tColumnRoleCode.Visible = true;
this.tColumnRoleCode.VisibleIndex = 0;
this.tColumnRoleCode.Width = 284;
this.tColumnRoleCode.Width = 221;
//
// treeListColumn5
//
this.treeListColumn5.Caption = "权限名称";
this.treeListColumn5.FieldName = "AuthName";
this.treeListColumn5.MinWidth = 26;
this.treeListColumn5.Name = "treeListColumn5";
this.treeListColumn5.OptionsFilter.AllowFilter = false;
this.treeListColumn5.Visible = true;
this.treeListColumn5.VisibleIndex = 1;
this.treeListColumn5.Width = 495;
this.treeListColumn5.Width = 385;
//
// toolbarFormManager1
//
@ -151,37 +143,33 @@
//
this.barDockControlTop.CausesValidation = false;
this.barDockControlTop.Dock = System.Windows.Forms.DockStyle.Top;
this.barDockControlTop.Location = new System.Drawing.Point(0, 39);
this.barDockControlTop.Location = new System.Drawing.Point(0, 31);
this.barDockControlTop.Manager = this.toolbarFormManager1;
this.barDockControlTop.Margin = new System.Windows.Forms.Padding(4);
this.barDockControlTop.Size = new System.Drawing.Size(873, 0);
this.barDockControlTop.Size = new System.Drawing.Size(679, 0);
//
// barDockControlBottom
//
this.barDockControlBottom.CausesValidation = false;
this.barDockControlBottom.Dock = System.Windows.Forms.DockStyle.Bottom;
this.barDockControlBottom.Location = new System.Drawing.Point(0, 752);
this.barDockControlBottom.Location = new System.Drawing.Point(0, 627);
this.barDockControlBottom.Manager = this.toolbarFormManager1;
this.barDockControlBottom.Margin = new System.Windows.Forms.Padding(4);
this.barDockControlBottom.Size = new System.Drawing.Size(873, 0);
this.barDockControlBottom.Size = new System.Drawing.Size(679, 0);
//
// barDockControlLeft
//
this.barDockControlLeft.CausesValidation = false;
this.barDockControlLeft.Dock = System.Windows.Forms.DockStyle.Left;
this.barDockControlLeft.Location = new System.Drawing.Point(0, 39);
this.barDockControlLeft.Location = new System.Drawing.Point(0, 31);
this.barDockControlLeft.Manager = this.toolbarFormManager1;
this.barDockControlLeft.Margin = new System.Windows.Forms.Padding(4);
this.barDockControlLeft.Size = new System.Drawing.Size(0, 713);
this.barDockControlLeft.Size = new System.Drawing.Size(0, 596);
//
// barDockControlRight
//
this.barDockControlRight.CausesValidation = false;
this.barDockControlRight.Dock = System.Windows.Forms.DockStyle.Right;
this.barDockControlRight.Location = new System.Drawing.Point(873, 39);
this.barDockControlRight.Location = new System.Drawing.Point(679, 31);
this.barDockControlRight.Manager = this.toolbarFormManager1;
this.barDockControlRight.Margin = new System.Windows.Forms.Padding(4);
this.barDockControlRight.Size = new System.Drawing.Size(0, 713);
this.barDockControlRight.Size = new System.Drawing.Size(0, 596);
//
// bBtnSave
//
@ -196,44 +184,40 @@
// txtRoleCode
//
this.txtRoleCode.Enabled = false;
this.txtRoleCode.Location = new System.Drawing.Point(84, 12);
this.txtRoleCode.Margin = new System.Windows.Forms.Padding(4);
this.txtRoleCode.Location = new System.Drawing.Point(67, 10);
this.txtRoleCode.Name = "txtRoleCode";
this.txtRoleCode.Properties.MaxLength = 50;
this.txtRoleCode.Size = new System.Drawing.Size(329, 24);
this.txtRoleCode.Size = new System.Drawing.Size(254, 22);
this.txtRoleCode.StyleController = this.layoutControl1;
this.txtRoleCode.TabIndex = 4;
//
// txtRoleDesc
//
this.txtRoleDesc.Enabled = false;
this.txtRoleDesc.Location = new System.Drawing.Point(84, 40);
this.txtRoleDesc.Margin = new System.Windows.Forms.Padding(4);
this.txtRoleDesc.Location = new System.Drawing.Point(67, 36);
this.txtRoleDesc.Name = "txtRoleDesc";
this.txtRoleDesc.Properties.MaxLength = 50;
this.txtRoleDesc.Size = new System.Drawing.Size(329, 24);
this.txtRoleDesc.Size = new System.Drawing.Size(254, 22);
this.txtRoleDesc.StyleController = this.layoutControl1;
this.txtRoleDesc.TabIndex = 7;
//
// txtRoleName
//
this.txtRoleName.Enabled = false;
this.txtRoleName.Location = new System.Drawing.Point(489, 12);
this.txtRoleName.Margin = new System.Windows.Forms.Padding(4);
this.txtRoleName.Location = new System.Drawing.Point(382, 10);
this.txtRoleName.Name = "txtRoleName";
this.txtRoleName.Properties.MaxLength = 50;
this.txtRoleName.Size = new System.Drawing.Size(372, 24);
this.txtRoleName.Size = new System.Drawing.Size(287, 22);
this.txtRoleName.StyleController = this.layoutControl1;
this.txtRoleName.TabIndex = 5;
//
// txtNote
//
this.txtNote.Enabled = false;
this.txtNote.Location = new System.Drawing.Point(489, 40);
this.txtNote.Margin = new System.Windows.Forms.Padding(4);
this.txtNote.Location = new System.Drawing.Point(382, 36);
this.txtNote.Name = "txtNote";
this.txtNote.Properties.MaxLength = 50;
this.txtNote.Size = new System.Drawing.Size(372, 24);
this.txtNote.Size = new System.Drawing.Size(287, 22);
this.txtNote.StyleController = this.layoutControl1;
this.txtNote.TabIndex = 8;
//
@ -249,7 +233,7 @@
this.layoutControlItem2,
this.layoutControlItem5});
this.Root.Name = "Root";
this.Root.Size = new System.Drawing.Size(873, 713);
this.Root.Size = new System.Drawing.Size(679, 596);
this.Root.TextVisible = false;
//
// layoutControlItem1
@ -258,17 +242,17 @@
this.layoutControlItem1.CustomizationFormText = "角色编码";
this.layoutControlItem1.Location = new System.Drawing.Point(0, 0);
this.layoutControlItem1.Name = "layoutControlItem1";
this.layoutControlItem1.Size = new System.Drawing.Size(405, 28);
this.layoutControlItem1.Size = new System.Drawing.Size(315, 26);
this.layoutControlItem1.Text = "角色编码";
this.layoutControlItem1.TextSize = new System.Drawing.Size(60, 18);
this.layoutControlItem1.TextSize = new System.Drawing.Size(48, 15);
//
// layoutControlGroup2
//
this.layoutControlGroup2.Items.AddRange(new DevExpress.XtraLayout.BaseLayoutItem[] {
this.layoutControlItem6});
this.layoutControlGroup2.Location = new System.Drawing.Point(0, 75);
this.layoutControlGroup2.Location = new System.Drawing.Point(0, 63);
this.layoutControlGroup2.Name = "layoutControlGroup2";
this.layoutControlGroup2.Size = new System.Drawing.Size(853, 618);
this.layoutControlGroup2.Size = new System.Drawing.Size(663, 517);
this.layoutControlGroup2.Text = "选择权限";
//
// layoutControlItem6
@ -276,52 +260,51 @@
this.layoutControlItem6.Control = this.tvAuths;
this.layoutControlItem6.Location = new System.Drawing.Point(0, 0);
this.layoutControlItem6.Name = "layoutControlItem6";
this.layoutControlItem6.Size = new System.Drawing.Size(829, 568);
this.layoutControlItem6.Size = new System.Drawing.Size(643, 476);
this.layoutControlItem6.TextSize = new System.Drawing.Size(0, 0);
this.layoutControlItem6.TextVisible = false;
//
// emptySpaceItem1
//
this.emptySpaceItem1.AllowHotTrack = false;
this.emptySpaceItem1.Location = new System.Drawing.Point(0, 56);
this.emptySpaceItem1.Location = new System.Drawing.Point(0, 52);
this.emptySpaceItem1.Name = "emptySpaceItem1";
this.emptySpaceItem1.Size = new System.Drawing.Size(853, 19);
this.emptySpaceItem1.Size = new System.Drawing.Size(663, 11);
this.emptySpaceItem1.TextSize = new System.Drawing.Size(0, 0);
//
// layoutControlItem4
//
this.layoutControlItem4.Control = this.txtRoleDesc;
this.layoutControlItem4.Location = new System.Drawing.Point(0, 28);
this.layoutControlItem4.Location = new System.Drawing.Point(0, 26);
this.layoutControlItem4.Name = "layoutControlItem4";
this.layoutControlItem4.Size = new System.Drawing.Size(405, 28);
this.layoutControlItem4.Size = new System.Drawing.Size(315, 26);
this.layoutControlItem4.Text = "角色描述";
this.layoutControlItem4.TextSize = new System.Drawing.Size(60, 18);
this.layoutControlItem4.TextSize = new System.Drawing.Size(48, 15);
//
// layoutControlItem2
//
this.layoutControlItem2.Control = this.txtRoleName;
this.layoutControlItem2.Location = new System.Drawing.Point(405, 0);
this.layoutControlItem2.Location = new System.Drawing.Point(315, 0);
this.layoutControlItem2.Name = "layoutControlItem2";
this.layoutControlItem2.Size = new System.Drawing.Size(448, 28);
this.layoutControlItem2.Size = new System.Drawing.Size(348, 26);
this.layoutControlItem2.Text = "角色名称";
this.layoutControlItem2.TextSize = new System.Drawing.Size(60, 18);
this.layoutControlItem2.TextSize = new System.Drawing.Size(48, 15);
//
// layoutControlItem5
//
this.layoutControlItem5.Control = this.txtNote;
this.layoutControlItem5.Location = new System.Drawing.Point(405, 28);
this.layoutControlItem5.Location = new System.Drawing.Point(315, 26);
this.layoutControlItem5.Name = "layoutControlItem5";
this.layoutControlItem5.Size = new System.Drawing.Size(448, 28);
this.layoutControlItem5.Size = new System.Drawing.Size(348, 26);
this.layoutControlItem5.Text = "备注";
this.layoutControlItem5.TextSize = new System.Drawing.Size(60, 18);
this.layoutControlItem5.TextSize = new System.Drawing.Size(48, 15);
//
// toolbarFormControl1
//
this.toolbarFormControl1.Location = new System.Drawing.Point(0, 0);
this.toolbarFormControl1.Manager = this.toolbarFormManager1;
this.toolbarFormControl1.Margin = new System.Windows.Forms.Padding(4);
this.toolbarFormControl1.Name = "toolbarFormControl1";
this.toolbarFormControl1.Size = new System.Drawing.Size(873, 39);
this.toolbarFormControl1.Size = new System.Drawing.Size(679, 31);
this.toolbarFormControl1.TabIndex = 7;
this.toolbarFormControl1.TabStop = false;
this.toolbarFormControl1.TitleItemLinks.Add(this.bBtnSave);
@ -333,10 +316,10 @@
//
// frmRoleAuths
//
this.AutoScaleDimensions = new System.Drawing.SizeF(9F, 18F);
this.AutoScaleDimensions = new System.Drawing.SizeF(7F, 15F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.AutoSize = true;
this.ClientSize = new System.Drawing.Size(873, 752);
this.ClientSize = new System.Drawing.Size(679, 627);
this.Controls.Add(this.layoutControl1);
this.Controls.Add(this.barDockControlLeft);
this.Controls.Add(this.barDockControlRight);
@ -345,7 +328,6 @@
this.Controls.Add(this.toolbarFormControl1);
this.DoubleBuffered = true;
this.IconOptions.Image = global::DeviceRepairAndOptimization.Properties.Resources.role_16x16;
this.Margin = new System.Windows.Forms.Padding(4);
this.MaximizeBox = false;
this.MinimizeBox = false;
this.Name = "frmRoleAuths";

View File

@ -118,7 +118,7 @@
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<metadata name="toolbarFormManager1.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<value>245, 17</value>
<value>205, 17</value>
</metadata>
<assembly alias="System.Drawing" name="System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />
<data name="bBtnSave.ImageOptions.Image" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">

View File

@ -106,7 +106,6 @@
//
this.colStatus.Caption = "状态";
this.colStatus.FieldName = "Status";
this.colStatus.MinWidth = 26;
this.colStatus.Name = "colStatus";
this.colStatus.OptionsColumn.AllowEdit = false;
this.colStatus.OptionsColumn.AllowGroup = DevExpress.Utils.DefaultBoolean.False;
@ -118,7 +117,7 @@
this.colStatus.OptionsFilter.AllowFilter = false;
this.colStatus.Visible = true;
this.colStatus.VisibleIndex = 3;
this.colStatus.Width = 84;
this.colStatus.Width = 65;
//
// layoutControl1
//
@ -131,12 +130,11 @@
this.layoutControl1.Controls.Add(this.txtNote);
this.layoutControl1.Controls.Add(this.comboBoxEdit1);
this.layoutControl1.Dock = System.Windows.Forms.DockStyle.Fill;
this.layoutControl1.Location = new System.Drawing.Point(0, 39);
this.layoutControl1.Margin = new System.Windows.Forms.Padding(4);
this.layoutControl1.Location = new System.Drawing.Point(0, 31);
this.layoutControl1.Name = "layoutControl1";
this.layoutControl1.OptionsCustomizationForm.DesignTimeCustomizationFormPositionAndSize = new System.Drawing.Rectangle(569, 0, 650, 400);
this.layoutControl1.Root = this.Root;
this.layoutControl1.Size = new System.Drawing.Size(1243, 717);
this.layoutControl1.Size = new System.Drawing.Size(967, 599);
this.layoutControl1.TabIndex = 6;
this.layoutControl1.Text = "layoutControl1";
//
@ -145,34 +143,28 @@
this.tvAuths.Columns.AddRange(new DevExpress.XtraTreeList.Columns.TreeListColumn[] {
this.tColumnRoleCode,
this.treeListColumn5});
this.tvAuths.FixedLineWidth = 3;
this.tvAuths.HorzScrollStep = 4;
this.tvAuths.Location = new System.Drawing.Point(24, 149);
this.tvAuths.Margin = new System.Windows.Forms.Padding(4);
this.tvAuths.Location = new System.Drawing.Point(20, 131);
this.tvAuths.MenuManager = this.toolbarFormManager1;
this.tvAuths.MinWidth = 26;
this.tvAuths.Name = "tvAuths";
this.tvAuths.OptionsBehavior.AllowIndeterminateCheckState = true;
this.tvAuths.OptionsView.BestFitNodes = DevExpress.XtraTreeList.TreeListBestFitNodes.All;
this.tvAuths.OptionsView.CheckBoxStyle = DevExpress.XtraTreeList.DefaultNodeCheckBoxStyle.Check;
this.tvAuths.Size = new System.Drawing.Size(508, 544);
this.tvAuths.Size = new System.Drawing.Size(393, 448);
this.tvAuths.TabIndex = 10;
this.tvAuths.TreeLevelWidth = 23;
//
// tColumnRoleCode
//
this.tColumnRoleCode.Caption = "权限编码";
this.tColumnRoleCode.FieldName = "AuthCode";
this.tColumnRoleCode.MinWidth = 26;
this.tColumnRoleCode.Name = "tColumnRoleCode";
this.tColumnRoleCode.Visible = true;
this.tColumnRoleCode.VisibleIndex = 0;
this.tColumnRoleCode.Width = 58;
//
// treeListColumn5
//
this.treeListColumn5.Caption = "权限名称";
this.treeListColumn5.FieldName = "AuthName";
this.treeListColumn5.MinWidth = 26;
this.treeListColumn5.Name = "treeListColumn5";
this.treeListColumn5.OptionsColumn.AllowEdit = false;
this.treeListColumn5.OptionsColumn.AllowMove = false;
@ -181,7 +173,7 @@
this.treeListColumn5.OptionsFilter.AllowFilter = false;
this.treeListColumn5.Visible = true;
this.treeListColumn5.VisibleIndex = 1;
this.treeListColumn5.Width = 156;
this.treeListColumn5.Width = 121;
//
// toolbarFormManager1
//
@ -198,37 +190,33 @@
//
this.barDockControlTop.CausesValidation = false;
this.barDockControlTop.Dock = System.Windows.Forms.DockStyle.Top;
this.barDockControlTop.Location = new System.Drawing.Point(0, 39);
this.barDockControlTop.Location = new System.Drawing.Point(0, 31);
this.barDockControlTop.Manager = this.toolbarFormManager1;
this.barDockControlTop.Margin = new System.Windows.Forms.Padding(4);
this.barDockControlTop.Size = new System.Drawing.Size(1243, 0);
this.barDockControlTop.Size = new System.Drawing.Size(967, 0);
//
// barDockControlBottom
//
this.barDockControlBottom.CausesValidation = false;
this.barDockControlBottom.Dock = System.Windows.Forms.DockStyle.Bottom;
this.barDockControlBottom.Location = new System.Drawing.Point(0, 756);
this.barDockControlBottom.Location = new System.Drawing.Point(0, 630);
this.barDockControlBottom.Manager = this.toolbarFormManager1;
this.barDockControlBottom.Margin = new System.Windows.Forms.Padding(4);
this.barDockControlBottom.Size = new System.Drawing.Size(1243, 0);
this.barDockControlBottom.Size = new System.Drawing.Size(967, 0);
//
// barDockControlLeft
//
this.barDockControlLeft.CausesValidation = false;
this.barDockControlLeft.Dock = System.Windows.Forms.DockStyle.Left;
this.barDockControlLeft.Location = new System.Drawing.Point(0, 39);
this.barDockControlLeft.Location = new System.Drawing.Point(0, 31);
this.barDockControlLeft.Manager = this.toolbarFormManager1;
this.barDockControlLeft.Margin = new System.Windows.Forms.Padding(4);
this.barDockControlLeft.Size = new System.Drawing.Size(0, 717);
this.barDockControlLeft.Size = new System.Drawing.Size(0, 599);
//
// barDockControlRight
//
this.barDockControlRight.CausesValidation = false;
this.barDockControlRight.Dock = System.Windows.Forms.DockStyle.Right;
this.barDockControlRight.Location = new System.Drawing.Point(1243, 39);
this.barDockControlRight.Location = new System.Drawing.Point(967, 31);
this.barDockControlRight.Manager = this.toolbarFormManager1;
this.barDockControlRight.Margin = new System.Windows.Forms.Padding(4);
this.barDockControlRight.Size = new System.Drawing.Size(0, 717);
this.barDockControlRight.Size = new System.Drawing.Size(0, 599);
//
// bBtnSave
//
@ -242,13 +230,12 @@
//
// dgvUsers
//
this.dgvUsers.EmbeddedNavigator.Margin = new System.Windows.Forms.Padding(4, 6, 4, 6);
this.dgvUsers.Location = new System.Drawing.Point(560, 177);
this.dgvUsers.EmbeddedNavigator.Margin = new System.Windows.Forms.Padding(2, 4, 2, 4);
this.dgvUsers.Location = new System.Drawing.Point(437, 157);
this.dgvUsers.MainView = this.gridView1;
this.dgvUsers.Margin = new System.Windows.Forms.Padding(4);
this.dgvUsers.MenuManager = this.toolbarFormManager1;
this.dgvUsers.Name = "dgvUsers";
this.dgvUsers.Size = new System.Drawing.Size(659, 516);
this.dgvUsers.Size = new System.Drawing.Size(510, 422);
this.dgvUsers.TabIndex = 12;
this.dgvUsers.ViewCollection.AddRange(new DevExpress.XtraGrid.Views.Base.BaseView[] {
this.gridView1});
@ -259,7 +246,7 @@
this.colLoginCode,
this.colRealName,
this.colStatus});
this.gridView1.DetailHeight = 450;
this.gridView1.DetailHeight = 375;
gridFormatRule1.ApplyToRow = true;
gridFormatRule1.Column = this.colStatus;
gridFormatRule1.Name = "Format0";
@ -284,19 +271,19 @@
this.gridView1.FormatRules.Add(gridFormatRule1);
this.gridView1.FormatRules.Add(gridFormatRule2);
this.gridView1.GridControl = this.dgvUsers;
this.gridView1.IndicatorWidth = 51;
this.gridView1.IndicatorWidth = 40;
this.gridView1.Name = "gridView1";
this.gridView1.OptionsFind.FindMode = DevExpress.XtraEditors.FindMode.FindClick;
this.gridView1.OptionsSelection.MultiSelect = true;
this.gridView1.OptionsSelection.MultiSelectMode = DevExpress.XtraGrid.Views.Grid.GridMultiSelectMode.CheckBoxRowSelect;
this.gridView1.OptionsSelection.ShowCheckBoxSelectorInColumnHeader = DevExpress.Utils.DefaultBoolean.True;
this.gridView1.OptionsView.ShowDetailButtons = false;
this.gridView1.OptionsView.ShowGroupPanel = false;
//
// colLoginCode
//
this.colLoginCode.Caption = "用户编码";
this.colLoginCode.FieldName = "LoginCode";
this.colLoginCode.MinWidth = 26;
this.colLoginCode.Name = "colLoginCode";
this.colLoginCode.OptionsColumn.AllowEdit = false;
this.colLoginCode.OptionsColumn.AllowGroup = DevExpress.Utils.DefaultBoolean.False;
@ -306,13 +293,12 @@
this.colLoginCode.OptionsColumn.ReadOnly = true;
this.colLoginCode.Visible = true;
this.colLoginCode.VisibleIndex = 1;
this.colLoginCode.Width = 145;
this.colLoginCode.Width = 113;
//
// colRealName
//
this.colRealName.Caption = "用户名";
this.colRealName.FieldName = "RealName";
this.colRealName.MinWidth = 26;
this.colRealName.Name = "colRealName";
this.colRealName.OptionsColumn.AllowEdit = false;
this.colRealName.OptionsColumn.AllowGroup = DevExpress.Utils.DefaultBoolean.False;
@ -322,15 +308,14 @@
this.colRealName.OptionsColumn.ReadOnly = true;
this.colRealName.Visible = true;
this.colRealName.VisibleIndex = 2;
this.colRealName.Width = 148;
this.colRealName.Width = 115;
//
// txtRoleCode
//
this.txtRoleCode.Location = new System.Drawing.Point(114, 12);
this.txtRoleCode.Margin = new System.Windows.Forms.Padding(4);
this.txtRoleCode.Location = new System.Drawing.Point(91, 10);
this.txtRoleCode.Name = "txtRoleCode";
this.txtRoleCode.Properties.MaxLength = 50;
this.txtRoleCode.Size = new System.Drawing.Size(430, 24);
this.txtRoleCode.Size = new System.Drawing.Size(332, 22);
this.txtRoleCode.StyleController = this.layoutControl1;
this.txtRoleCode.TabIndex = 4;
conditionValidationRule1.ConditionOperator = DevExpress.XtraEditors.DXErrorProvider.ConditionOperator.IsNotBlank;
@ -339,21 +324,19 @@
//
// txtRoleDesc
//
this.txtRoleDesc.Location = new System.Drawing.Point(650, 40);
this.txtRoleDesc.Margin = new System.Windows.Forms.Padding(4);
this.txtRoleDesc.Location = new System.Drawing.Point(508, 36);
this.txtRoleDesc.Name = "txtRoleDesc";
this.txtRoleDesc.Properties.MaxLength = 50;
this.txtRoleDesc.Size = new System.Drawing.Size(581, 24);
this.txtRoleDesc.Size = new System.Drawing.Size(449, 22);
this.txtRoleDesc.StyleController = this.layoutControl1;
this.txtRoleDesc.TabIndex = 7;
//
// txtRoleName
//
this.txtRoleName.Location = new System.Drawing.Point(114, 40);
this.txtRoleName.Margin = new System.Windows.Forms.Padding(4);
this.txtRoleName.Location = new System.Drawing.Point(91, 36);
this.txtRoleName.Name = "txtRoleName";
this.txtRoleName.Properties.MaxLength = 50;
this.txtRoleName.Size = new System.Drawing.Size(430, 24);
this.txtRoleName.Size = new System.Drawing.Size(332, 22);
this.txtRoleName.StyleController = this.layoutControl1;
this.txtRoleName.TabIndex = 5;
conditionValidationRule2.ConditionOperator = DevExpress.XtraEditors.DXErrorProvider.ConditionOperator.IsNotBlank;
@ -362,18 +345,16 @@
//
// txtNote
//
this.txtNote.Location = new System.Drawing.Point(114, 68);
this.txtNote.Margin = new System.Windows.Forms.Padding(4);
this.txtNote.Location = new System.Drawing.Point(91, 62);
this.txtNote.Name = "txtNote";
this.txtNote.Properties.MaxLength = 50;
this.txtNote.Size = new System.Drawing.Size(1117, 24);
this.txtNote.Size = new System.Drawing.Size(866, 22);
this.txtNote.StyleController = this.layoutControl1;
this.txtNote.TabIndex = 8;
//
// comboBoxEdit1
//
this.comboBoxEdit1.Location = new System.Drawing.Point(662, 149);
this.comboBoxEdit1.Margin = new System.Windows.Forms.Padding(4);
this.comboBoxEdit1.Location = new System.Drawing.Point(518, 131);
this.comboBoxEdit1.MenuManager = this.toolbarFormManager1;
this.comboBoxEdit1.Name = "comboBoxEdit1";
this.comboBoxEdit1.Properties.Buttons.AddRange(new DevExpress.XtraEditors.Controls.EditorButton[] {
@ -384,7 +365,7 @@
"显示停用用户"});
this.comboBoxEdit1.Properties.TextEditStyle = DevExpress.XtraEditors.Controls.TextEditStyles.DisableTextEditor;
this.comboBoxEdit1.Properties.SelectedIndexChanged += new System.EventHandler(this.comboBoxEdit1_Properties_SelectedIndexChanged);
this.comboBoxEdit1.Size = new System.Drawing.Size(233, 24);
this.comboBoxEdit1.Size = new System.Drawing.Size(178, 22);
this.comboBoxEdit1.StyleController = this.layoutControl1;
this.comboBoxEdit1.TabIndex = 15;
//
@ -402,7 +383,7 @@
this.emptySpaceItem1,
this.layoutControlGroup1});
this.Root.Name = "Root";
this.Root.Size = new System.Drawing.Size(1243, 717);
this.Root.Size = new System.Drawing.Size(967, 599);
this.Root.TextVisible = false;
//
// layoutControlItem1
@ -411,52 +392,52 @@
this.layoutControlItem1.CustomizationFormText = "角色编码";
this.layoutControlItem1.Location = new System.Drawing.Point(0, 0);
this.layoutControlItem1.Name = "layoutControlItem1";
this.layoutControlItem1.Size = new System.Drawing.Size(536, 28);
this.layoutControlItem1.Size = new System.Drawing.Size(417, 26);
this.layoutControlItem1.Text = "角色编码";
this.layoutControlItem1.TextSize = new System.Drawing.Size(90, 18);
this.layoutControlItem1.TextSize = new System.Drawing.Size(72, 15);
//
// layoutControlItem2
//
this.layoutControlItem2.Control = this.txtRoleName;
this.layoutControlItem2.Location = new System.Drawing.Point(0, 28);
this.layoutControlItem2.Location = new System.Drawing.Point(0, 26);
this.layoutControlItem2.Name = "layoutControlItem2";
this.layoutControlItem2.Size = new System.Drawing.Size(536, 28);
this.layoutControlItem2.Size = new System.Drawing.Size(417, 26);
this.layoutControlItem2.Text = "角色名称";
this.layoutControlItem2.TextSize = new System.Drawing.Size(90, 18);
this.layoutControlItem2.TextSize = new System.Drawing.Size(72, 15);
//
// emptySpaceItem3
//
this.emptySpaceItem3.AllowHotTrack = false;
this.emptySpaceItem3.Location = new System.Drawing.Point(536, 0);
this.emptySpaceItem3.Location = new System.Drawing.Point(417, 0);
this.emptySpaceItem3.Name = "emptySpaceItem3";
this.emptySpaceItem3.Size = new System.Drawing.Size(687, 28);
this.emptySpaceItem3.Size = new System.Drawing.Size(534, 26);
this.emptySpaceItem3.TextSize = new System.Drawing.Size(0, 0);
//
// layoutControlItem4
//
this.layoutControlItem4.Control = this.txtRoleDesc;
this.layoutControlItem4.Location = new System.Drawing.Point(536, 28);
this.layoutControlItem4.Location = new System.Drawing.Point(417, 26);
this.layoutControlItem4.Name = "layoutControlItem4";
this.layoutControlItem4.Size = new System.Drawing.Size(687, 28);
this.layoutControlItem4.Size = new System.Drawing.Size(534, 26);
this.layoutControlItem4.Text = "角色描述";
this.layoutControlItem4.TextSize = new System.Drawing.Size(90, 18);
this.layoutControlItem4.TextSize = new System.Drawing.Size(72, 15);
//
// layoutControlItem5
//
this.layoutControlItem5.Control = this.txtNote;
this.layoutControlItem5.Location = new System.Drawing.Point(0, 56);
this.layoutControlItem5.Location = new System.Drawing.Point(0, 52);
this.layoutControlItem5.Name = "layoutControlItem5";
this.layoutControlItem5.Size = new System.Drawing.Size(1223, 28);
this.layoutControlItem5.Size = new System.Drawing.Size(951, 26);
this.layoutControlItem5.Text = "备注";
this.layoutControlItem5.TextSize = new System.Drawing.Size(90, 18);
this.layoutControlItem5.TextSize = new System.Drawing.Size(72, 15);
//
// layoutControlGroup2
//
this.layoutControlGroup2.Items.AddRange(new DevExpress.XtraLayout.BaseLayoutItem[] {
this.layoutControlItem6});
this.layoutControlGroup2.Location = new System.Drawing.Point(0, 99);
this.layoutControlGroup2.Location = new System.Drawing.Point(0, 90);
this.layoutControlGroup2.Name = "layoutControlGroup2";
this.layoutControlGroup2.Size = new System.Drawing.Size(536, 598);
this.layoutControlGroup2.Size = new System.Drawing.Size(417, 493);
this.layoutControlGroup2.Text = "角色权限选择";
//
// layoutControlItem6
@ -464,16 +445,16 @@
this.layoutControlItem6.Control = this.tvAuths;
this.layoutControlItem6.Location = new System.Drawing.Point(0, 0);
this.layoutControlItem6.Name = "layoutControlItem6";
this.layoutControlItem6.Size = new System.Drawing.Size(512, 548);
this.layoutControlItem6.Size = new System.Drawing.Size(397, 452);
this.layoutControlItem6.TextSize = new System.Drawing.Size(0, 0);
this.layoutControlItem6.TextVisible = false;
//
// emptySpaceItem1
//
this.emptySpaceItem1.AllowHotTrack = false;
this.emptySpaceItem1.Location = new System.Drawing.Point(0, 84);
this.emptySpaceItem1.Location = new System.Drawing.Point(0, 78);
this.emptySpaceItem1.Name = "emptySpaceItem1";
this.emptySpaceItem1.Size = new System.Drawing.Size(1223, 15);
this.emptySpaceItem1.Size = new System.Drawing.Size(951, 12);
this.emptySpaceItem1.TextSize = new System.Drawing.Size(0, 0);
//
// layoutControlGroup1
@ -482,17 +463,17 @@
this.layoutControlItem7,
this.layoutControlItem3,
this.emptySpaceItem2});
this.layoutControlGroup1.Location = new System.Drawing.Point(536, 99);
this.layoutControlGroup1.Location = new System.Drawing.Point(417, 90);
this.layoutControlGroup1.Name = "layoutControlGroup1";
this.layoutControlGroup1.Size = new System.Drawing.Size(687, 598);
this.layoutControlGroup1.Size = new System.Drawing.Size(534, 493);
this.layoutControlGroup1.Text = "用户选择";
//
// layoutControlItem7
//
this.layoutControlItem7.Control = this.dgvUsers;
this.layoutControlItem7.Location = new System.Drawing.Point(0, 28);
this.layoutControlItem7.Location = new System.Drawing.Point(0, 26);
this.layoutControlItem7.Name = "layoutControlItem7";
this.layoutControlItem7.Size = new System.Drawing.Size(663, 520);
this.layoutControlItem7.Size = new System.Drawing.Size(514, 426);
this.layoutControlItem7.TextSize = new System.Drawing.Size(0, 0);
this.layoutControlItem7.TextVisible = false;
//
@ -502,25 +483,24 @@
this.layoutControlItem3.CustomizationFormText = "选择";
this.layoutControlItem3.Location = new System.Drawing.Point(0, 0);
this.layoutControlItem3.Name = "layoutControlItem3";
this.layoutControlItem3.Size = new System.Drawing.Size(339, 28);
this.layoutControlItem3.Size = new System.Drawing.Size(263, 26);
this.layoutControlItem3.Text = "选择用户状态";
this.layoutControlItem3.TextSize = new System.Drawing.Size(90, 18);
this.layoutControlItem3.TextSize = new System.Drawing.Size(72, 15);
//
// emptySpaceItem2
//
this.emptySpaceItem2.AllowHotTrack = false;
this.emptySpaceItem2.Location = new System.Drawing.Point(339, 0);
this.emptySpaceItem2.Location = new System.Drawing.Point(263, 0);
this.emptySpaceItem2.Name = "emptySpaceItem2";
this.emptySpaceItem2.Size = new System.Drawing.Size(324, 28);
this.emptySpaceItem2.Size = new System.Drawing.Size(251, 26);
this.emptySpaceItem2.TextSize = new System.Drawing.Size(0, 0);
//
// toolbarFormControl1
//
this.toolbarFormControl1.Location = new System.Drawing.Point(0, 0);
this.toolbarFormControl1.Manager = this.toolbarFormManager1;
this.toolbarFormControl1.Margin = new System.Windows.Forms.Padding(4);
this.toolbarFormControl1.Name = "toolbarFormControl1";
this.toolbarFormControl1.Size = new System.Drawing.Size(1243, 39);
this.toolbarFormControl1.Size = new System.Drawing.Size(967, 31);
this.toolbarFormControl1.TabIndex = 7;
this.toolbarFormControl1.TabStop = false;
this.toolbarFormControl1.TitleItemLinks.Add(this.bBtnSave);
@ -536,9 +516,9 @@
//
// frmRoleEdit
//
this.AutoScaleDimensions = new System.Drawing.SizeF(9F, 18F);
this.AutoScaleDimensions = new System.Drawing.SizeF(7F, 15F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.ClientSize = new System.Drawing.Size(1243, 756);
this.ClientSize = new System.Drawing.Size(967, 630);
this.Controls.Add(this.layoutControl1);
this.Controls.Add(this.barDockControlLeft);
this.Controls.Add(this.barDockControlRight);
@ -546,7 +526,6 @@
this.Controls.Add(this.barDockControlTop);
this.Controls.Add(this.toolbarFormControl1);
this.IconOptions.Image = ((System.Drawing.Image)(resources.GetObject("frmRoleEdit.IconOptions.Image")));
this.Margin = new System.Windows.Forms.Padding(4);
this.MaximizeBox = false;
this.MinimizeBox = false;
this.Name = "frmRoleEdit";

View File

@ -118,26 +118,26 @@
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<metadata name="toolbarFormManager1.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<value>465, 17</value>
<value>387, 17</value>
</metadata>
<assembly alias="System.Drawing" name="System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />
<data name="bBtnSave.ImageOptions.Image" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value>
iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8
YQUAAAAZdEVYdFNvZnR3YXJlAEFkb2JlIEltYWdlUmVhZHlxyWU8AAAAC3RFWHRUaXRsZQBTYXZlO/no
+QkAAABYSURBVDhPY/j//z9FGExMzlq/F4j/gzCUD2ajYzS5vSA+zABcilDE0OVAfPoYAMPY1GI1AB9G
V4shSAqmvgEgNjF41AA8BpCKkQ3Yji5JBN4ON4B8/J8BAL6u0wsmtxusAAAAAElFTkSuQmCC
iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAABGdBTUEAALGPC/xhBQAAABl0RVh0U29m
dHdhcmUAQWRvYmUgSW1hZ2VSZWFkeXHJZTwAAAALdEVYdFRpdGxlAFNhdmU7+ej5CQAAAFhJREFUOE9j
+P//P0UYTEzOWr8XiP+DMJQPZqNjNLm9ID7MAFyKUMTQ5UB8+hgAw9jUYjUAH0ZXiyFICqa+ASA2MXjU
ADwGkIqRDdiOLkkE3g43gHz8nwEAvq7TCya3G6wAAAAASUVORK5CYII=
</value>
</data>
<data name="bBtnSave.ImageOptions.LargeImage" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value>
iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8
YQUAAAAZdEVYdFNvZnR3YXJlAEFkb2JlIEltYWdlUmVhZHlxyWU8AAAAC3RFWHRUaXRsZQBTYXZlO/no
+QkAAAENSURBVFhH7ZfRCcMwDESzWaBfmaXrdJDO0T0CGcPVidicheQm0DgE8vHAlY6nI38dUkqn4g57
4g57Uv14Pd+j8BESgTnDuyark2dwj3zTFlgonOHjVthkddr5wjdtARsGfDzKAN2zJ3JinikP4IUFFRNe
BuiePZET80x5AC8sqJjwMkD37ImcmGfKA3hhQcWElwG6Z0/kxDxTHsALCyomvAzQPXsiJ+aZ8gBeWFAx
4WVcIme+By5ZoAn7Iifvf4aPgG/eBVoFHgJmu2AfeeHaXaASb4V9jOzuAneBu8D1CkxCJd8C+8gL1+4C
h8E3bYHZhg9g5pu2AD6V99/gX8A98c2qwBm4w564w36k4QtaC2pTkRLrNgAAAABJRU5ErkJggg==
iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAABGdBTUEAALGPC/xhBQAAABl0RVh0U29m
dHdhcmUAQWRvYmUgSW1hZ2VSZWFkeXHJZTwAAAALdEVYdFRpdGxlAFNhdmU7+ej5CQAAAQ1JREFUWEft
l9EJwzAMRLNZoF+Zpet0kM7RPQIZw9WJ2JyF5CbQOATy8cCVjqcjfx1SSqfiDnviDntS/Xg936PwERKB
OcO7JquTZ3CPfNMWWCic4eNW2GR12vnCN20BGwZ8PMoA3bMncmKeKQ/ghQUVE14G6J49kRPzTHkALyyo
mPAyQPfsiZyYZ8oDeGFBxYSXAbpnT+TEPFMewAsLKia8DNA9eyIn5pnyAF5YUDHhZVwiZ74HLlmgCfsi
J+9/ho+Ab94FWgUeAma7YB954dpdoBJvhX2M7O4Cd4G7wPUKTEIl3wL7yAvX7gKHwTdtgdmGD2Dmm7YA
PpX33+BfwD3xzarAGbjDnrjDfqThC1oLalOREus2AAAAAElFTkSuQmCC
</value>
</data>
<data name="frmRoleEdit.IconOptions.Image" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
@ -152,9 +152,9 @@
</value>
</data>
<metadata name="dxValidationProvider1.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<value>245, 17</value>
<value>205, 17</value>
</metadata>
<metadata name="dxErrorProvider1.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<value>689, 17</value>
<value>573, 17</value>
</metadata>
</root>

View File

@ -92,7 +92,6 @@
//
this.colStatus.Caption = "状态";
this.colStatus.FieldName = "Status";
this.colStatus.MinWidth = 26;
this.colStatus.Name = "colStatus";
this.colStatus.OptionsColumn.AllowEdit = false;
this.colStatus.OptionsColumn.AllowGroup = DevExpress.Utils.DefaultBoolean.False;
@ -101,7 +100,7 @@
this.colStatus.OptionsColumn.ReadOnly = true;
this.colStatus.Visible = true;
this.colStatus.VisibleIndex = 3;
this.colStatus.Width = 172;
this.colStatus.Width = 134;
//
// layoutControl1
//
@ -113,24 +112,22 @@
this.layoutControl1.Controls.Add(this.txtNote);
this.layoutControl1.Controls.Add(this.comboBoxEdit1);
this.layoutControl1.Dock = System.Windows.Forms.DockStyle.Fill;
this.layoutControl1.Location = new System.Drawing.Point(0, 39);
this.layoutControl1.Margin = new System.Windows.Forms.Padding(4);
this.layoutControl1.Location = new System.Drawing.Point(0, 31);
this.layoutControl1.Name = "layoutControl1";
this.layoutControl1.OptionsCustomizationForm.DesignTimeCustomizationFormPositionAndSize = new System.Drawing.Rectangle(569, 0, 650, 400);
this.layoutControl1.Root = this.Root;
this.layoutControl1.Size = new System.Drawing.Size(864, 717);
this.layoutControl1.Size = new System.Drawing.Size(672, 599);
this.layoutControl1.TabIndex = 6;
this.layoutControl1.Text = "layoutControl1";
//
// dgvUsers
//
this.dgvUsers.EmbeddedNavigator.Margin = new System.Windows.Forms.Padding(4, 6, 4, 6);
this.dgvUsers.Location = new System.Drawing.Point(24, 186);
this.dgvUsers.EmbeddedNavigator.Margin = new System.Windows.Forms.Padding(2, 4, 2, 4);
this.dgvUsers.Location = new System.Drawing.Point(20, 157);
this.dgvUsers.MainView = this.gridView1;
this.dgvUsers.Margin = new System.Windows.Forms.Padding(4);
this.dgvUsers.MenuManager = this.toolbarFormManager1;
this.dgvUsers.Name = "dgvUsers";
this.dgvUsers.Size = new System.Drawing.Size(816, 507);
this.dgvUsers.Size = new System.Drawing.Size(632, 422);
this.dgvUsers.TabIndex = 12;
this.dgvUsers.ViewCollection.AddRange(new DevExpress.XtraGrid.Views.Base.BaseView[] {
this.gridView1});
@ -141,7 +138,7 @@
this.colLoginCode,
this.colRealName,
this.colStatus});
this.gridView1.DetailHeight = 450;
this.gridView1.DetailHeight = 375;
gridFormatRule1.ApplyToRow = true;
gridFormatRule1.Column = this.colStatus;
gridFormatRule1.Enabled = false;
@ -167,20 +164,20 @@
this.gridView1.FormatRules.Add(gridFormatRule1);
this.gridView1.FormatRules.Add(gridFormatRule2);
this.gridView1.GridControl = this.dgvUsers;
this.gridView1.IndicatorWidth = 51;
this.gridView1.IndicatorWidth = 40;
this.gridView1.Name = "gridView1";
this.gridView1.OptionsBehavior.AllowPartialGroups = DevExpress.Utils.DefaultBoolean.False;
this.gridView1.OptionsFind.FindMode = DevExpress.XtraEditors.FindMode.FindClick;
this.gridView1.OptionsSelection.MultiSelect = true;
this.gridView1.OptionsSelection.MultiSelectMode = DevExpress.XtraGrid.Views.Grid.GridMultiSelectMode.CheckBoxRowSelect;
this.gridView1.OptionsSelection.ShowCheckBoxSelectorInColumnHeader = DevExpress.Utils.DefaultBoolean.False;
this.gridView1.OptionsView.ShowDetailButtons = false;
this.gridView1.OptionsView.ShowGroupPanel = false;
//
// colLoginCode
//
this.colLoginCode.Caption = "用户编码";
this.colLoginCode.FieldName = "LoginCode";
this.colLoginCode.MinWidth = 26;
this.colLoginCode.Name = "colLoginCode";
this.colLoginCode.OptionsColumn.AllowEdit = false;
this.colLoginCode.OptionsColumn.AllowGroup = DevExpress.Utils.DefaultBoolean.False;
@ -190,13 +187,12 @@
this.colLoginCode.OptionsColumn.ReadOnly = true;
this.colLoginCode.Visible = true;
this.colLoginCode.VisibleIndex = 1;
this.colLoginCode.Width = 204;
this.colLoginCode.Width = 159;
//
// colRealName
//
this.colRealName.Caption = "用户名";
this.colRealName.FieldName = "RealName";
this.colRealName.MinWidth = 26;
this.colRealName.Name = "colRealName";
this.colRealName.OptionsColumn.AllowEdit = false;
this.colRealName.OptionsColumn.AllowGroup = DevExpress.Utils.DefaultBoolean.False;
@ -205,7 +201,7 @@
this.colRealName.OptionsColumn.ReadOnly = true;
this.colRealName.Visible = true;
this.colRealName.VisibleIndex = 2;
this.colRealName.Width = 297;
this.colRealName.Width = 231;
//
// toolbarFormManager1
//
@ -222,37 +218,33 @@
//
this.barDockControlTop.CausesValidation = false;
this.barDockControlTop.Dock = System.Windows.Forms.DockStyle.Top;
this.barDockControlTop.Location = new System.Drawing.Point(0, 39);
this.barDockControlTop.Location = new System.Drawing.Point(0, 31);
this.barDockControlTop.Manager = this.toolbarFormManager1;
this.barDockControlTop.Margin = new System.Windows.Forms.Padding(4);
this.barDockControlTop.Size = new System.Drawing.Size(864, 0);
this.barDockControlTop.Size = new System.Drawing.Size(672, 0);
//
// barDockControlBottom
//
this.barDockControlBottom.CausesValidation = false;
this.barDockControlBottom.Dock = System.Windows.Forms.DockStyle.Bottom;
this.barDockControlBottom.Location = new System.Drawing.Point(0, 756);
this.barDockControlBottom.Location = new System.Drawing.Point(0, 630);
this.barDockControlBottom.Manager = this.toolbarFormManager1;
this.barDockControlBottom.Margin = new System.Windows.Forms.Padding(4);
this.barDockControlBottom.Size = new System.Drawing.Size(864, 0);
this.barDockControlBottom.Size = new System.Drawing.Size(672, 0);
//
// barDockControlLeft
//
this.barDockControlLeft.CausesValidation = false;
this.barDockControlLeft.Dock = System.Windows.Forms.DockStyle.Left;
this.barDockControlLeft.Location = new System.Drawing.Point(0, 39);
this.barDockControlLeft.Location = new System.Drawing.Point(0, 31);
this.barDockControlLeft.Manager = this.toolbarFormManager1;
this.barDockControlLeft.Margin = new System.Windows.Forms.Padding(4);
this.barDockControlLeft.Size = new System.Drawing.Size(0, 717);
this.barDockControlLeft.Size = new System.Drawing.Size(0, 599);
//
// barDockControlRight
//
this.barDockControlRight.CausesValidation = false;
this.barDockControlRight.Dock = System.Windows.Forms.DockStyle.Right;
this.barDockControlRight.Location = new System.Drawing.Point(864, 39);
this.barDockControlRight.Location = new System.Drawing.Point(672, 31);
this.barDockControlRight.Manager = this.toolbarFormManager1;
this.barDockControlRight.Margin = new System.Windows.Forms.Padding(4);
this.barDockControlRight.Size = new System.Drawing.Size(0, 717);
this.barDockControlRight.Size = new System.Drawing.Size(0, 599);
//
// bBtnSave
//
@ -267,51 +259,46 @@
// txtRoleCode
//
this.txtRoleCode.Enabled = false;
this.txtRoleCode.Location = new System.Drawing.Point(114, 12);
this.txtRoleCode.Margin = new System.Windows.Forms.Padding(4);
this.txtRoleCode.Location = new System.Drawing.Point(91, 10);
this.txtRoleCode.Name = "txtRoleCode";
this.txtRoleCode.Properties.MaxLength = 50;
this.txtRoleCode.Size = new System.Drawing.Size(265, 24);
this.txtRoleCode.Size = new System.Drawing.Size(203, 22);
this.txtRoleCode.StyleController = this.layoutControl1;
this.txtRoleCode.TabIndex = 4;
//
// txtRoleDesc
//
this.txtRoleDesc.Enabled = false;
this.txtRoleDesc.Location = new System.Drawing.Point(485, 40);
this.txtRoleDesc.Margin = new System.Windows.Forms.Padding(4);
this.txtRoleDesc.Location = new System.Drawing.Point(379, 36);
this.txtRoleDesc.Name = "txtRoleDesc";
this.txtRoleDesc.Properties.MaxLength = 50;
this.txtRoleDesc.Size = new System.Drawing.Size(367, 24);
this.txtRoleDesc.Size = new System.Drawing.Size(283, 22);
this.txtRoleDesc.StyleController = this.layoutControl1;
this.txtRoleDesc.TabIndex = 7;
//
// txtRoleName
//
this.txtRoleName.Enabled = false;
this.txtRoleName.Location = new System.Drawing.Point(114, 40);
this.txtRoleName.Margin = new System.Windows.Forms.Padding(4);
this.txtRoleName.Location = new System.Drawing.Point(91, 36);
this.txtRoleName.Name = "txtRoleName";
this.txtRoleName.Properties.MaxLength = 50;
this.txtRoleName.Size = new System.Drawing.Size(265, 24);
this.txtRoleName.Size = new System.Drawing.Size(203, 22);
this.txtRoleName.StyleController = this.layoutControl1;
this.txtRoleName.TabIndex = 5;
//
// txtNote
//
this.txtNote.Enabled = false;
this.txtNote.Location = new System.Drawing.Point(114, 68);
this.txtNote.Margin = new System.Windows.Forms.Padding(4);
this.txtNote.Location = new System.Drawing.Point(91, 62);
this.txtNote.Name = "txtNote";
this.txtNote.Properties.MaxLength = 50;
this.txtNote.Size = new System.Drawing.Size(738, 24);
this.txtNote.Size = new System.Drawing.Size(571, 22);
this.txtNote.StyleController = this.layoutControl1;
this.txtNote.TabIndex = 8;
//
// comboBoxEdit1
//
this.comboBoxEdit1.Location = new System.Drawing.Point(126, 158);
this.comboBoxEdit1.Margin = new System.Windows.Forms.Padding(4);
this.comboBoxEdit1.Location = new System.Drawing.Point(101, 131);
this.comboBoxEdit1.MenuManager = this.toolbarFormManager1;
this.comboBoxEdit1.Name = "comboBoxEdit1";
this.comboBoxEdit1.Properties.Buttons.AddRange(new DevExpress.XtraEditors.Controls.EditorButton[] {
@ -322,7 +309,7 @@
"显示停用用户"});
this.comboBoxEdit1.Properties.TextEditStyle = DevExpress.XtraEditors.Controls.TextEditStyles.DisableTextEditor;
this.comboBoxEdit1.Properties.SelectedIndexChanged += new System.EventHandler(this.comboBoxEdit1_Properties_SelectedIndexChanged);
this.comboBoxEdit1.Size = new System.Drawing.Size(313, 24);
this.comboBoxEdit1.Size = new System.Drawing.Size(240, 22);
this.comboBoxEdit1.StyleController = this.layoutControl1;
this.comboBoxEdit1.TabIndex = 15;
//
@ -339,7 +326,7 @@
this.emptySpaceItem1,
this.layoutControlGroup1});
this.Root.Name = "Root";
this.Root.Size = new System.Drawing.Size(864, 717);
this.Root.Size = new System.Drawing.Size(672, 599);
this.Root.TextVisible = false;
//
// layoutControlItem1
@ -348,51 +335,51 @@
this.layoutControlItem1.CustomizationFormText = "角色编码";
this.layoutControlItem1.Location = new System.Drawing.Point(0, 0);
this.layoutControlItem1.Name = "layoutControlItem1";
this.layoutControlItem1.Size = new System.Drawing.Size(371, 28);
this.layoutControlItem1.Size = new System.Drawing.Size(288, 26);
this.layoutControlItem1.Text = "角色编码";
this.layoutControlItem1.TextSize = new System.Drawing.Size(90, 18);
this.layoutControlItem1.TextSize = new System.Drawing.Size(72, 15);
//
// layoutControlItem2
//
this.layoutControlItem2.Control = this.txtRoleName;
this.layoutControlItem2.Location = new System.Drawing.Point(0, 28);
this.layoutControlItem2.Location = new System.Drawing.Point(0, 26);
this.layoutControlItem2.Name = "layoutControlItem2";
this.layoutControlItem2.Size = new System.Drawing.Size(371, 28);
this.layoutControlItem2.Size = new System.Drawing.Size(288, 26);
this.layoutControlItem2.Text = "角色名称";
this.layoutControlItem2.TextSize = new System.Drawing.Size(90, 18);
this.layoutControlItem2.TextSize = new System.Drawing.Size(72, 15);
//
// emptySpaceItem3
//
this.emptySpaceItem3.AllowHotTrack = false;
this.emptySpaceItem3.Location = new System.Drawing.Point(371, 0);
this.emptySpaceItem3.Location = new System.Drawing.Point(288, 0);
this.emptySpaceItem3.Name = "emptySpaceItem3";
this.emptySpaceItem3.Size = new System.Drawing.Size(473, 28);
this.emptySpaceItem3.Size = new System.Drawing.Size(368, 26);
this.emptySpaceItem3.TextSize = new System.Drawing.Size(0, 0);
//
// layoutControlItem4
//
this.layoutControlItem4.Control = this.txtRoleDesc;
this.layoutControlItem4.Location = new System.Drawing.Point(371, 28);
this.layoutControlItem4.Location = new System.Drawing.Point(288, 26);
this.layoutControlItem4.Name = "layoutControlItem4";
this.layoutControlItem4.Size = new System.Drawing.Size(473, 28);
this.layoutControlItem4.Size = new System.Drawing.Size(368, 26);
this.layoutControlItem4.Text = "角色描述";
this.layoutControlItem4.TextSize = new System.Drawing.Size(90, 18);
this.layoutControlItem4.TextSize = new System.Drawing.Size(72, 15);
//
// layoutControlItem5
//
this.layoutControlItem5.Control = this.txtNote;
this.layoutControlItem5.Location = new System.Drawing.Point(0, 56);
this.layoutControlItem5.Location = new System.Drawing.Point(0, 52);
this.layoutControlItem5.Name = "layoutControlItem5";
this.layoutControlItem5.Size = new System.Drawing.Size(844, 28);
this.layoutControlItem5.Size = new System.Drawing.Size(656, 26);
this.layoutControlItem5.Text = "备注";
this.layoutControlItem5.TextSize = new System.Drawing.Size(90, 18);
this.layoutControlItem5.TextSize = new System.Drawing.Size(72, 15);
//
// emptySpaceItem1
//
this.emptySpaceItem1.AllowHotTrack = false;
this.emptySpaceItem1.Location = new System.Drawing.Point(0, 84);
this.emptySpaceItem1.Location = new System.Drawing.Point(0, 78);
this.emptySpaceItem1.Name = "emptySpaceItem1";
this.emptySpaceItem1.Size = new System.Drawing.Size(844, 24);
this.emptySpaceItem1.Size = new System.Drawing.Size(656, 12);
this.emptySpaceItem1.TextSize = new System.Drawing.Size(0, 0);
//
// layoutControlGroup1
@ -401,17 +388,17 @@
this.layoutControlItem7,
this.layoutControlItem3,
this.emptySpaceItem2});
this.layoutControlGroup1.Location = new System.Drawing.Point(0, 108);
this.layoutControlGroup1.Location = new System.Drawing.Point(0, 90);
this.layoutControlGroup1.Name = "layoutControlGroup1";
this.layoutControlGroup1.Size = new System.Drawing.Size(844, 589);
this.layoutControlGroup1.Size = new System.Drawing.Size(656, 493);
this.layoutControlGroup1.Text = "用户选择";
//
// layoutControlItem7
//
this.layoutControlItem7.Control = this.dgvUsers;
this.layoutControlItem7.Location = new System.Drawing.Point(0, 28);
this.layoutControlItem7.Location = new System.Drawing.Point(0, 26);
this.layoutControlItem7.Name = "layoutControlItem7";
this.layoutControlItem7.Size = new System.Drawing.Size(820, 511);
this.layoutControlItem7.Size = new System.Drawing.Size(636, 426);
this.layoutControlItem7.TextSize = new System.Drawing.Size(0, 0);
this.layoutControlItem7.TextVisible = false;
//
@ -421,25 +408,24 @@
this.layoutControlItem3.CustomizationFormText = "选择";
this.layoutControlItem3.Location = new System.Drawing.Point(0, 0);
this.layoutControlItem3.Name = "layoutControlItem3";
this.layoutControlItem3.Size = new System.Drawing.Size(419, 28);
this.layoutControlItem3.Size = new System.Drawing.Size(325, 26);
this.layoutControlItem3.Text = "选择用户状态";
this.layoutControlItem3.TextSize = new System.Drawing.Size(90, 18);
this.layoutControlItem3.TextSize = new System.Drawing.Size(72, 15);
//
// emptySpaceItem2
//
this.emptySpaceItem2.AllowHotTrack = false;
this.emptySpaceItem2.Location = new System.Drawing.Point(419, 0);
this.emptySpaceItem2.Location = new System.Drawing.Point(325, 0);
this.emptySpaceItem2.Name = "emptySpaceItem2";
this.emptySpaceItem2.Size = new System.Drawing.Size(401, 28);
this.emptySpaceItem2.Size = new System.Drawing.Size(311, 26);
this.emptySpaceItem2.TextSize = new System.Drawing.Size(0, 0);
//
// toolbarFormControl1
//
this.toolbarFormControl1.Location = new System.Drawing.Point(0, 0);
this.toolbarFormControl1.Manager = this.toolbarFormManager1;
this.toolbarFormControl1.Margin = new System.Windows.Forms.Padding(4);
this.toolbarFormControl1.Name = "toolbarFormControl1";
this.toolbarFormControl1.Size = new System.Drawing.Size(864, 39);
this.toolbarFormControl1.Size = new System.Drawing.Size(672, 31);
this.toolbarFormControl1.TabIndex = 7;
this.toolbarFormControl1.TabStop = false;
this.toolbarFormControl1.TitleItemLinks.Add(this.bBtnSave);
@ -451,9 +437,9 @@
//
// frmRoleUsers
//
this.AutoScaleDimensions = new System.Drawing.SizeF(9F, 18F);
this.AutoScaleDimensions = new System.Drawing.SizeF(7F, 15F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.ClientSize = new System.Drawing.Size(864, 756);
this.ClientSize = new System.Drawing.Size(672, 630);
this.Controls.Add(this.layoutControl1);
this.Controls.Add(this.barDockControlLeft);
this.Controls.Add(this.barDockControlRight);
@ -461,7 +447,6 @@
this.Controls.Add(this.barDockControlTop);
this.Controls.Add(this.toolbarFormControl1);
this.IconOptions.Image = ((System.Drawing.Image)(resources.GetObject("frmRoleUsers.IconOptions.Image")));
this.Margin = new System.Windows.Forms.Padding(4);
this.MaximizeBox = false;
this.MinimizeBox = false;
this.Name = "frmRoleUsers";

View File

@ -118,44 +118,43 @@
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<metadata name="toolbarFormManager1.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<value>245, 17</value>
<value>205, 17</value>
</metadata>
<assembly alias="System.Drawing" name="System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />
<data name="bBtnSave.ImageOptions.Image" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value>
iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8
YQUAAAAZdEVYdFNvZnR3YXJlAEFkb2JlIEltYWdlUmVhZHlxyWU8AAAAC3RFWHRUaXRsZQBTYXZlO/no
+QkAAABYSURBVDhPY/j//z9FGExMzlq/F4j/gzCUD2ajYzS5vSA+zABcilDE0OVAfPoYAMPY1GI1AB9G
V4shSAqmvgEgNjF41AA8BpCKkQ3Yji5JBN4ON4B8/J8BAL6u0wsmtxusAAAAAElFTkSuQmCC
iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAABGdBTUEAALGPC/xhBQAAABl0RVh0U29m
dHdhcmUAQWRvYmUgSW1hZ2VSZWFkeXHJZTwAAAALdEVYdFRpdGxlAFNhdmU7+ej5CQAAAFhJREFUOE9j
+P//P0UYTEzOWr8XiP+DMJQPZqNjNLm9ID7MAFyKUMTQ5UB8+hgAw9jUYjUAH0ZXiyFICqa+ASA2MXjU
ADwGkIqRDdiOLkkE3g43gHz8nwEAvq7TCya3G6wAAAAASUVORK5CYII=
</value>
</data>
<data name="bBtnSave.ImageOptions.LargeImage" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value>
iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8
YQUAAAAZdEVYdFNvZnR3YXJlAEFkb2JlIEltYWdlUmVhZHlxyWU8AAAAC3RFWHRUaXRsZQBTYXZlO/no
+QkAAAENSURBVFhH7ZfRCcMwDESzWaBfmaXrdJDO0T0CGcPVidicheQm0DgE8vHAlY6nI38dUkqn4g57
4g57Uv14Pd+j8BESgTnDuyark2dwj3zTFlgonOHjVthkddr5wjdtARsGfDzKAN2zJ3JinikP4IUFFRNe
BuiePZET80x5AC8sqJjwMkD37ImcmGfKA3hhQcWElwG6Z0/kxDxTHsALCyomvAzQPXsiJ+aZ8gBeWFAx
4WVcIme+By5ZoAn7Iifvf4aPgG/eBVoFHgJmu2AfeeHaXaASb4V9jOzuAneBu8D1CkxCJd8C+8gL1+4C
h8E3bYHZhg9g5pu2AD6V99/gX8A98c2qwBm4w564w36k4QtaC2pTkRLrNgAAAABJRU5ErkJggg==
iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAABGdBTUEAALGPC/xhBQAAABl0RVh0U29m
dHdhcmUAQWRvYmUgSW1hZ2VSZWFkeXHJZTwAAAALdEVYdFRpdGxlAFNhdmU7+ej5CQAAAQ1JREFUWEft
l9EJwzAMRLNZoF+Zpet0kM7RPQIZw9WJ2JyF5CbQOATy8cCVjqcjfx1SSqfiDnviDntS/Xg936PwERKB
OcO7JquTZ3CPfNMWWCic4eNW2GR12vnCN20BGwZ8PMoA3bMncmKeKQ/ghQUVE14G6J49kRPzTHkALyyo
mPAyQPfsiZyYZ8oDeGFBxYSXAbpnT+TEPFMewAsLKia8DNA9eyIn5pnyAF5YUDHhZVwiZ74HLlmgCfsi
J+9/ho+Ab94FWgUeAma7YB954dpdoBJvhX2M7O4Cd4G7wPUKTEIl3wL7yAvX7gKHwTdtgdmGD2Dmm7YA
PpX33+BfwD3xzarAGbjDnrjDfqThC1oLalOREus2AAAAAElFTkSuQmCC
</value>
</data>
<data name="frmRoleUsers.IconOptions.Image" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value>
iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8
YQUAAAATdEVYdFRpdGxlAFBlb3BsZTtBc3NpZ25+WIkkAAACoUlEQVQ4T6WSe0iTYRTGP2e63DRMKF3e
JtllmnhLTZR0Oa2M8lZeyqGiJZSF5a3MjVYNnBMjdGZeRjdNUsuIskJjGonNDFJRSkkrkULtjygjS5/e
d21h4h9FD/x4v3POc853eHkZAP/FokkDehkRWATjedD4l2dh03yIjJoPuW7X5Hl2PM73Hm/N9pipSxV0
ybbaJ5Casc6zsGk+1NSQJhh/oc6Yay9ORF9tLh7JYyAT2X8lNbbe84fouhSDTFUxTtO3CyJwqyAKhZEb
UCH2Qm4A7zOpcXUD0i576iBikfNHSo1HpW/cKi6J6SATqchB03wqEdPvtfjQWQaV2A/pG60bSc2sK9+R
9v2+IHZSlRuankuRfNG9OyzLiU9yJqt5y/nNBXu+fRltw0SHEuVi71k7y6VutOdJngPD7Ctz0exVuSKh
TID4UgEGJivxYECC1AqfybAcfigx8tRHdw73XJOgXRkPWTj/Nc3JglcwrZm2DBNTvAZjn+7quQPtuAT1
veHQDB/Hkerg79E5zoqbkvDRmozNKN/vi/JEu6GUTRZr6XYEFrPjNB9Px/Kh7vFHzTM/VHf7oErrjdJ2
H8TK1s0VKqJn3z2U4m1tFN7URWKkLh6NB2xnquOsrp4IWSZggo/x2oQ5NhBm2SA4yxrlnS6QNjtDeJA3
23ApG1O9N/Dx3mFMqIN0TF4Jw1RTLHoUAVBFLHtFtmDYBHrrK/3SrSCvD8T6SG5/Q2kmRlqUeHk+BINy
V4yd89AxeNYFfTIBtBIXlGzjgvFKtmA8kyzoIK67mAvHLaaNbEuW3fWTuy+U7LJuKQo171WIOEPKUA6K
RBzIhWbDZ4LM+iWB7Pt5/mwFbTRoCcGcwNF/U+h2NKYb0r8YMPjYiz7hf2HR5N8D5idfz/Dx6LWU+wAA
AABJRU5ErkJggg==
iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAABGdBTUEAALGPC/xhBQAAABN0RVh0VGl0
bGUAUGVvcGxlO0Fzc2lnbn5YiSQAAAKhSURBVDhPpZJ7SJNhFMY/Z7rcNEwoXd4m2WWaeEtNlHQ5rYzy
Vl7KoaIllIXlrcyNVg2cEyN0Zl5GN01Sy4iyQmMaic0MUlFKSSuRQu2PKCNLn953bWHiH0UP/Hi/c85z
znd4eRkA/8WiSQN6GRFYBON50PiXZ2HTfIiMmg+5btfkeXY8zvceb832mKlLFXTJttonkJqxzrOwaT7U
1JAmGH+hzphrL05EX20uHsljIBPZfyU1tt7zh+i6FINMVTFO07cLInCrIAqFkRtQIfZCbgDvM6lxdQPS
LnvqIGKR80dKjUelb9wqLonpIBOpyEHTfCoR0++1+NBZBpXYD+kbrRtJzawr35H2/b4gdlKVG5qeS5F8
0b07LMuJT3Imq3nL+c0Fe759GW3DRIcS5WLvWTvLpW6050meA8PsK3PR7FW5IqFMgPhSAQYmK/FgQILU
Cp/JsBx+KDHy1Ed3Dvdck6BdGQ9ZOP81zcmCVzCtmbYME1O8BmOf7uq5A+24BPW94dAMH8eR6uDv0TnO
ipuS8NGajM0o3++L8kS7oZRNFmvpdgQWs+M0H0/H8qHu8UfNMz9Ud/ugSuuN0nYfxMrWzRUqomffPZTi
bW0U3tRFYqQuHo0HbGeq46yunghZJmCCj/HahDk2EGbZIDjLGuWdLpA2O0N4kDfbcCkbU7038PHeYUyo
g3RMXgnDVFMsehQBUEUse0W2YNgEeusr/dKtIK8PxPpIbn9DaSZGWpR4eT4Eg3JXjJ3z0DF41gV9MgG0
EheUbOOC8Uq2YDyTLOggrruYC8ctpo1sS5bd9ZO7L5Tssm4pCjXvVYg4Q8pQDopEHMiFZsNngsz6JYHs
+3n+bAVtNGgJwZzA0X9T6HY0phvSvxgw+NiLPuF/YdHk3wPmJ1/P8PHotZT7AAAAAElFTkSuQmCC
</value>
</data>
</root>

View File

@ -307,7 +307,7 @@
// dgvDatas
//
this.dgvDatas.EmbeddedNavigator.Margin = new System.Windows.Forms.Padding(2, 4, 2, 4);
this.dgvDatas.Location = new System.Drawing.Point(20, 71);
this.dgvDatas.Location = new System.Drawing.Point(24, 75);
this.dgvDatas.MainView = this.gridView1;
this.dgvDatas.Margin = new System.Windows.Forms.Padding(2, 3, 2, 3);
this.dgvDatas.MenuManager = this.toolbarFormManager1;
@ -321,7 +321,7 @@
this.reposBtnUserCode,
this.repositoryItemButtonEdit2,
this.reposBtnStatus});
this.dgvDatas.Size = new System.Drawing.Size(1068, 544);
this.dgvDatas.Size = new System.Drawing.Size(1060, 536);
this.dgvDatas.TabIndex = 6;
this.dgvDatas.ViewCollection.AddRange(new DevExpress.XtraGrid.Views.Base.BaseView[] {
this.gridView1});
@ -373,6 +373,7 @@
this.gridView1.OptionsFind.AlwaysVisible = true;
this.gridView1.OptionsFind.FindNullPrompt = "输入内容查询";
this.gridView1.OptionsView.ColumnAutoWidth = false;
this.gridView1.OptionsView.ShowDetailButtons = false;
this.gridView1.OptionsView.ShowGroupPanel = false;
this.gridView1.CustomDrawRowIndicator += new DevExpress.XtraGrid.Views.Grid.RowIndicatorCustomDrawEventHandler(this.gridView1_CustomDrawRowIndicator);
this.gridView1.FocusedRowChanged += new DevExpress.XtraGrid.Views.Base.FocusedRowChangedEventHandler(this.gridView1_FocusedRowChanged);
@ -650,7 +651,7 @@
//
// comboBoxEdit1
//
this.comboBoxEdit1.Location = new System.Drawing.Point(101, 45);
this.comboBoxEdit1.Location = new System.Drawing.Point(108, 49);
this.comboBoxEdit1.Margin = new System.Windows.Forms.Padding(2, 3, 2, 3);
this.comboBoxEdit1.MenuManager = this.toolbarFormManager1;
this.comboBoxEdit1.Name = "comboBoxEdit1";
@ -661,7 +662,7 @@
"显示在用用户",
"显示停用用户"});
this.comboBoxEdit1.Properties.TextEditStyle = DevExpress.XtraEditors.Controls.TextEditStyles.DisableTextEditor;
this.comboBoxEdit1.Size = new System.Drawing.Size(451, 22);
this.comboBoxEdit1.Size = new System.Drawing.Size(444, 22);
this.comboBoxEdit1.StyleController = this.layoutControl1;
this.comboBoxEdit1.TabIndex = 9;
this.comboBoxEdit1.SelectedIndexChanged += new System.EventHandler(this.comboBoxEdit1_SelectedIndexChanged);
@ -681,7 +682,7 @@
this.tabbedControlGroup1.Location = new System.Drawing.Point(0, 0);
this.tabbedControlGroup1.Name = "tabbedControlGroup1";
this.tabbedControlGroup1.SelectedTabPage = this.layoutControlGroup1;
this.tabbedControlGroup1.Size = new System.Drawing.Size(1092, 619);
this.tabbedControlGroup1.Size = new System.Drawing.Size(1088, 615);
this.tabbedControlGroup1.TabPages.AddRange(new DevExpress.XtraLayout.BaseLayoutItem[] {
this.layoutControlGroup1});
this.tabbedControlGroup1.Text = "角色列表";
@ -694,7 +695,7 @@
this.emptySpaceItem2});
this.layoutControlGroup1.Location = new System.Drawing.Point(0, 0);
this.layoutControlGroup1.Name = "layoutControlGroup1";
this.layoutControlGroup1.Size = new System.Drawing.Size(1072, 574);
this.layoutControlGroup1.Size = new System.Drawing.Size(1064, 566);
this.layoutControlGroup1.Text = "用户列表";
//
// layoutControlItem6
@ -702,7 +703,7 @@
this.layoutControlItem6.Control = this.comboBoxEdit1;
this.layoutControlItem6.Location = new System.Drawing.Point(0, 0);
this.layoutControlItem6.Name = "layoutControlItem6";
this.layoutControlItem6.Size = new System.Drawing.Size(536, 26);
this.layoutControlItem6.Size = new System.Drawing.Size(532, 26);
this.layoutControlItem6.Text = "选择用户状态";
this.layoutControlItem6.TextSize = new System.Drawing.Size(72, 15);
//
@ -711,16 +712,16 @@
this.layoutControlItem3.Control = this.dgvDatas;
this.layoutControlItem3.Location = new System.Drawing.Point(0, 26);
this.layoutControlItem3.Name = "layoutControlItem3";
this.layoutControlItem3.Size = new System.Drawing.Size(1072, 548);
this.layoutControlItem3.Size = new System.Drawing.Size(1064, 540);
this.layoutControlItem3.TextSize = new System.Drawing.Size(0, 0);
this.layoutControlItem3.TextVisible = false;
//
// emptySpaceItem2
//
this.emptySpaceItem2.AllowHotTrack = false;
this.emptySpaceItem2.Location = new System.Drawing.Point(536, 0);
this.emptySpaceItem2.Location = new System.Drawing.Point(532, 0);
this.emptySpaceItem2.Name = "emptySpaceItem2";
this.emptySpaceItem2.Size = new System.Drawing.Size(536, 26);
this.emptySpaceItem2.Size = new System.Drawing.Size(532, 26);
this.emptySpaceItem2.TextSize = new System.Drawing.Size(0, 0);
//
// cmsUser

View File

@ -196,7 +196,7 @@ namespace DeviceRepairAndOptimization.Pages.Users
if (e.Button.Caption.Contains("随机密码重置"))
{
GenRandomPassword:
GenRandomPassword:
vPwdReset = PasswordStrategy.Instance.GenRandomPassword();
if (EncryptionHelper.EncryptByMD5(vPwdReset) == CurrentUser.PassWord.ToUpper())
goto GenRandomPassword;
@ -329,21 +329,51 @@ namespace DeviceRepairAndOptimization.Pages.Users
return;
}
getRemark:
if (XtraMessageBox.Show($"<size=16>确认<b>{(CurrentUser.Status ? "<color=red><color/>" : "<color=LimeGreen><color/>")}<b/>用户{CurrentUser.LoginCode}-{CurrentUser.RealName}?<size/>",
"询问", MessageBoxButtons.OKCancel, MessageBoxIcon.Question, allowHtmlText: DevExpress.Utils.DefaultBoolean.True) == DialogResult.OK)
{
// 录入原因
string result = XtraInputBox.Show("原因录入:", $"请录入用户{(CurrentUser.Status ? "" : "")}原因", "");
if (string.IsNullOrWhiteSpace(result))
XtraInputBoxArgs args = new XtraInputBoxArgs { Prompt = "原因录入:", Caption = $"请录入用户{(CurrentUser.Status ? "" : "")}原因", DefaultResponse = "" };
args.Buttons = new DialogResult[] { DialogResult.OK, DialogResult.Cancel };
args.DefaultButtonIndex = (int)DialogResult.Cancel;
// 声明默认返回值
DialogResult DiaResult = DialogResult.None;
args.Showing += (a, b) =>
{
//选中ok按钮将返回值变量改变为ok。
b.Buttons[DialogResult.OK].Click += (c, d) => { DiaResult = DialogResult.OK; };
};
getRemark:
// 显示对话框
DiaResult = DialogResult.None;
var Description = XtraInputBox.Show(args);
string DescriptionValue = Description + "";
// 判断点击的按钮
if (DiaResult != DialogResult.None)
{
if (string.IsNullOrWhiteSpace(DescriptionValue))
{
if (XtraMessageBoxHelper.AskYesNo("原因不能为空,是否继续操作?") == DialogResult.Yes)
goto getRemark;
return;
}
if (DescriptionValue.Length >= 3800)
{
if (XtraMessageBoxHelper.AskYesNo("锁定原因的长度超出限制,请重试!") == DialogResult.Yes)
goto getRemark;
return;
}
}
else
{
if (XtraMessageBoxHelper.AskYesNo("原因不能为空,是否继续操作?") == DialogResult.Yes)
goto getRemark;
return;
}
CurrentUser.Status = !CurrentUser.Status;
CurrentUser.Description = result;
CurrentUser.Description = DescriptionValue;
APIResponseData apiResponseData = UserManager.Instance.Update(CurrentUser);
if (apiResponseData.IsSuccess)
@ -358,21 +388,6 @@ namespace DeviceRepairAndOptimization.Pages.Users
{
throw new Exception(apiResponseData.Message);
}
//if (apiResult.Code == 1)
//{
// HistoryManager.Instance.UserLockHistoryWrite(CurrentUser.AutoID, CurrentUser.Status ? "锁定" : "解锁");
// LoadingDatas();
// gridView1.RefreshData();
// splashScreenManager1.TryCloseWait();
// gridView1.FocusedRowHandle = m_SelectedCurrentRowIndex > 0 ? 0 : m_SelectedCurrentRowIndex + 1;
// XtraMessageBoxHelper.Info("用户更新成功!");
//}
//else
//{
// throw new Exception(apiResult.Message);
//}
}
}
catch (Exception ex)

View File

@ -1,10 +1,12 @@
using AutoUpdaterDotNET;
using DeviceRepair.Models;
using DeviceRepairAndOptimization;
using DeviceRepairAndOptimization.Common;
using Newtonsoft.Json;
using System;
using System.Drawing;
using System.IO;
using System.Threading;
using System.Windows.Forms;
namespace DeviceRepairAndOptimization
@ -17,89 +19,74 @@ namespace DeviceRepairAndOptimization
[STAThread]
static void Main(string[] args)
{
Application.EnableVisualStyles();
Application.SetCompatibleTextRenderingDefault(false);
bool isAppRunning;
//Application.Run(new page_DriveMaintenance());
#region , config中的数据库连接字符串 &
if (args != null && args.Length > 0)
using (Mutex mutex= new Mutex(true, "设备管理软件", out isAppRunning))
{
//UserInfoModel us1 = JsonConvert.DeserializeObject<UserInfoModel>("{\"AutoID\": 1,\"LoginCode\": \"myl\",\"PassWord\": \"Kanghui2\",\"RealName\": \"管理员\",\"Gender\": 1,\"Birthday\": \"/Date(1693471604770)/\",\"Phone\": \"13800000000\",\"RuleGroup\": 0}");
//string aa = JWT.JsonWebToken.Encode(us1, GlobalInfo.SecureKey, JWT.JwtHashAlgorithm.HS256);
AutoUpdater.AppTitle = "Device Repair And Optimization";
var vUpdateDir = Path.Combine(Application.StartupPath, "Update");
if (!Directory.Exists(vUpdateDir))
if (!isAppRunning)
{
Directory.CreateDirectory(vUpdateDir);
// 如果应用程序已在运行,则显示一个消息框并退出。
XtraMessageBoxHelper.Error("应用程序已运行。");
return;
}
// 指定下载文件的存储目录
AutoUpdater.DownloadPath = vUpdateDir;
AutoUpdater.UpdateFormSize = new Size(800, 600);
Application.EnableVisualStyles();
Application.SetCompatibleTextRenderingDefault(false);
AutoUpdater.Synchronous = true;
AutoUpdater.ShowSkipButton = false;
AutoUpdater.ShowRemindLaterButton = false;
AutoUpdater.Start($"http://{DeviceRepair.Utils.Config.Configurations.Properties.ServiceIP}/{DeviceRepair.Utils.Config.Configurations.Properties.ServiceName}/Update/DOAutoUpdater.xml");
//Application.Run(new page_DriveMaintenance());
try
#region , config中的数据库连接字符串 &
if (args != null && args.Length > 0)
{
string argsValue = string.Join("|", args);
string usValue = JWT.JsonWebToken.Decode(argsValue, DeviceRepair.Utils.Config.Configurations.Properties.SecureKey, true);
UserInfoModel us = JsonConvert.DeserializeObject<UserInfoModel>(usValue);
if (us != null)
//UserInfoModel us1 = JsonConvert.DeserializeObject<UserInfoModel>("{\"AutoID\": 1,\"LoginCode\": \"myl\",\"PassWord\": \"Kanghui2\",\"RealName\": \"管理员\",\"Gender\": 1,\"Birthday\": \"/Date(1693471604770)/\",\"Phone\": \"13800000000\",\"RuleGroup\": 0}");
//string aa = JWT.JsonWebToken.Encode(us1, GlobalInfo.SecureKey, JWT.JwtHashAlgorithm.HS256);
AutoUpdater.AppTitle = "Device Repair And Optimization";
var vUpdateDir = Path.Combine(Application.StartupPath, "Update");
if (!Directory.Exists(vUpdateDir))
{
GlobalInfo.token = argsValue;
GlobalInfo.CurrentUser = us;
Application.Run(new frm_Launch());
Directory.CreateDirectory(vUpdateDir);
}
// 指定下载文件的存储目录
AutoUpdater.DownloadPath = vUpdateDir;
AutoUpdater.UpdateFormSize = new Size(800, 600);
AutoUpdater.Synchronous = true;
AutoUpdater.ShowSkipButton = false;
AutoUpdater.ShowRemindLaterButton = false;
AutoUpdater.Start($"http://{DeviceRepair.Utils.Config.Configurations.Properties.ServiceIP}/{DeviceRepair.Utils.Config.Configurations.Properties.ServiceName}/Update/DOAutoUpdater.xml");
try
{
string argsValue = string.Join("|", args);
string usValue = JWT.JsonWebToken.Decode(argsValue, DeviceRepair.Utils.Config.Configurations.Properties.SecureKey, true);
UserInfoModel us = JsonConvert.DeserializeObject<UserInfoModel>(usValue);
if (us != null)
{
GlobalInfo.token = argsValue;
GlobalInfo.CurrentUser = us;
Application.Run(new frm_Launch());
return;
}
}
catch (Exception ex)
{
DevExpress.XtraEditors.XtraMessageBox.Show(ex.Message, "错误");
return;
}
}
catch (Exception ex)
#endregion
frmLogin login = new frmLogin();
if (login.ShowDialog() == DialogResult.OK)
{
DevExpress.XtraEditors.XtraMessageBox.Show(ex.Message, "错误");
return;
Application.Run(new frm_Launch());
}
}
//// 创建并显示等待窗口
//SplashScreenManager.ShowDefaultWaitForm("程序初始化", "请稍等...");
//if (string.IsNullOrEmpty(GlobalInfo.connectionString))
//{
// SplashScreenManager.Default.SetWaitFormDescription("出错:连接字符串错误...");
// return;
//}
////测试数据库连接 - 判断字符串是否正确
//SqlSugarClient db = GlobalInfo.dbClient;
//try
//{
// //通过获取表信息的方式测试连接
// db.DbMaintenance.GetTableInfoList();
// SplashScreenManager.Default.SetWaitFormDescription("成功");
//}
//catch (Exception ex)
//{
// SplashScreenManager.Default.SetWaitFormDescription($"出错:{ex.Message}...");
// return;
//}
//// 关闭等待窗口
//SplashScreenManager.CloseDefaultWaitForm();
#endregion
//Application.Run(new Pages.Maintain.pageMaintainEdit());
frmLogin login = new frmLogin();
if (login.ShowDialog() == DialogResult.OK)
{
Application.Run(new frm_Launch());
}
}
}
}

View File

@ -31,5 +31,5 @@ using System.Runtime.InteropServices;
//可以指定所有这些值,也可以使用“生成号”和“修订号”的默认值
//通过使用 "*",如下所示:
// [assembly: AssemblyVersion("1.0.*")]
[assembly: AssemblyVersion("2.0.1.9")]
[assembly: AssemblyFileVersion("2.0.1.9")]
[assembly: AssemblyVersion("2.0.1.10")]
[assembly: AssemblyFileVersion("2.0.1.10")]

View File

@ -1,19 +1,20 @@
DevExpress.XtraEditors.ComboBoxEdit, DevExpress.XtraEditors.v20.2, Version=20.2.3.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a
DevExpress.XtraEditors.DateEdit, DevExpress.XtraEditors.v20.2, Version=20.2.3.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a
DevExpress.XtraBars.BarManager, DevExpress.XtraBars.v20.2, Version=20.2.3.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a
DevExpress.XtraDataLayout.DataLayoutControl, DevExpress.XtraLayout.v20.2, Version=20.2.3.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a
DevExpress.XtraEditors.GridLookUpEdit, DevExpress.XtraGrid.v20.2, Version=20.2.3.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a
DevExpress.XtraEditors.Repository.RepositoryItemTextEdit, DevExpress.XtraEditors.v20.2, Version=20.2.3.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a
DevExpress.XtraEditors.Repository.RepositoryItemPictureEdit, DevExpress.XtraEditors.v20.2, Version=20.2.3.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a
DevExpress.XtraEditors.PictureEdit, DevExpress.XtraEditors.v20.2, Version=20.2.3.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a
DevExpress.XtraBars.Ribbon.RibbonControl, DevExpress.XtraBars.v20.2, Version=20.2.3.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a
DevExpress.XtraEditors.LookUpEdit, DevExpress.XtraEditors.v20.2, Version=20.2.3.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a
DevExpress.XtraTreeList.TreeList, DevExpress.XtraTreeList.v20.2, Version=20.2.3.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a
DevExpress.XtraEditors.TextEdit, DevExpress.XtraEditors.v20.2, Version=20.2.3.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a
DevExpress.XtraEditors.Repository.RepositoryItemButtonEdit, DevExpress.XtraEditors.v20.2, Version=20.2.3.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a
DevExpress.XtraGrid.GridControl, DevExpress.XtraGrid.v20.2, Version=20.2.3.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a
DevExpress.XtraEditors.Repository.RepositoryItemCheckEdit, DevExpress.XtraEditors.v20.2, Version=20.2.3.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a
DevExpress.XtraEditors.PictureEdit, DevExpress.XtraEditors.v20.2, Version=20.2.3.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a
DevExpress.XtraEditors.DateEdit, DevExpress.XtraEditors.v20.2, Version=20.2.3.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a
DevExpress.XtraEditors.ButtonEdit, DevExpress.XtraEditors.v20.2, Version=20.2.3.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a
DevExpress.XtraLayout.LayoutControl, DevExpress.XtraLayout.v20.2, Version=20.2.3.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a
DevExpress.XtraSpreadsheet.SpreadsheetControl, DevExpress.XtraSpreadsheet.v20.2, Version=20.2.3.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a
DevExpress.XtraTreeList.TreeList, DevExpress.XtraTreeList.v20.2, Version=20.2.3.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a
DevExpress.XtraGrid.GridControl, DevExpress.XtraGrid.v20.2, Version=20.2.3.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a
DevExpress.XtraPdfViewer.PdfViewer, DevExpress.XtraPdfViewer.v20.2, Version=20.2.3.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a
DevExpress.XtraBars.BarManager, DevExpress.XtraBars.v20.2, Version=20.2.3.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a
DevExpress.XtraEditors.TextEdit, DevExpress.XtraEditors.v20.2, Version=20.2.3.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a
DevExpress.XtraEditors.Repository.RepositoryItemCheckEdit, DevExpress.XtraEditors.v20.2, Version=20.2.3.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a
DevExpress.XtraEditors.TreeListLookUpEdit, DevExpress.XtraTreeList.v20.2, Version=20.2.3.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a
DevExpress.XtraEditors.GridLookUpEdit, DevExpress.XtraGrid.v20.2, Version=20.2.3.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a
DevExpress.XtraSpreadsheet.SpreadsheetControl, DevExpress.XtraSpreadsheet.v20.2, Version=20.2.3.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a
DevExpress.XtraEditors.LookUpEdit, DevExpress.XtraEditors.v20.2, Version=20.2.3.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a
DevExpress.XtraEditors.Repository.RepositoryItemPictureEdit, DevExpress.XtraEditors.v20.2, Version=20.2.3.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a
DevExpress.XtraLayout.LayoutControl, DevExpress.XtraLayout.v20.2, Version=20.2.3.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a
DevExpress.XtraEditors.ComboBoxEdit, DevExpress.XtraEditors.v20.2, Version=20.2.3.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a
DevExpress.XtraEditors.Repository.RepositoryItemTextEdit, DevExpress.XtraEditors.v20.2, Version=20.2.3.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a
DevExpress.XtraEditors.Repository.RepositoryItemButtonEdit, DevExpress.XtraEditors.v20.2, Version=20.2.3.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a

View File

@ -167,6 +167,11 @@
#region
/// <summary>
/// 获取设备路径
/// </summary>
public const string GetDeviceRoute = "Api/Device/GetDeviceRoute";
/// <summary>
/// 通过设备编号查询设备信息(非主键ID)
/// </summary>

View File

@ -37,7 +37,7 @@ namespace DeviceRepairAndOptimization
private void FrmLogin_Load(object sender, EventArgs e)
{
AutoUpdate();
lblVersion.Text = $"Ver {GetAppVersion()}";
lblVersion.Text = $"Ver 5.0";
}
#region

View File

@ -115,7 +115,7 @@ namespace DeviceRepairAndOptimization
if (string.IsNullOrEmpty(txt_UserPass.Text.Trim()))
throw new Exception("您输入的密码错误,请重试。");
var responseData = DeviceRepairAndOptimization.Biz.UserManager.Instance.GetDataByCodeAndPwd(new UserInfoModel
var responseData = Biz.UserManager.Instance.GetDataByCodeAndPwd(new UserInfoModel
{
LoginCode = txt_UserCode.Text.Trim(),
PassWord = DeviceRepair.Utils.Security.EncryptionHelper.EncryptByMD5(txt_UserPass.Text)

View File

@ -1,5 +1,8 @@
<?xml version="1.0" encoding="utf-8"?>
<configuration>
<appSettings>
<add key="ServiceApiUrl" value="http://193.112.23.48/DeviceRepairApi2"/>
</appSettings>
<startup>
<supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.5.2" />
</startup>

View File

@ -4,11 +4,8 @@ using DevExpress.XtraEditors.DXErrorProvider;
using DeviceRepair.Models;
using DeviceRepair.Models.Common;
using Newtonsoft.Json;
using Newtonsoft.Json.Linq;
using System;
using System.Collections.Generic;
using System.Data;
using System.Text.RegularExpressions;
using System.Windows.Forms;
using TsSFCDeivceClient.Common;
using TsSFCDeivceClient.Email;
@ -18,16 +15,8 @@ namespace TsSFCDeivceClient
public partial class DowntimeFormAdd : ToolbarForm
{
MailKitHelp mail = new MailKitHelp();
string emailPattern = @"\w+([-+.']\w+)*@\w+([-.]\w+)*\.\w+([-.]\w+)*";
public DeviceInformationInfo CurrentDeviceInfo = null;
System.Configuration.Configuration m_Config = System.Configuration.ConfigurationManager.OpenExeConfiguration(System.Configuration.ConfigurationUserLevel.None);
string ServiceUrl
{
get
{
return m_Config.AppSettings.Settings["ServiceApiUrl"].Value.Trim();
}
}
bool InProduction
{
get { return Convert.ToBoolean(rg_NeedValidate.EditValue); }
@ -52,7 +41,7 @@ namespace TsSFCDeivceClient
private void DowntimeFormAdd_Load(object sender, EventArgs e)
{
if (string.IsNullOrWhiteSpace(ServiceUrl))
if (string.IsNullOrWhiteSpace(RunConfig.config.ServiceApiUrl))
{
XtraMessageBoxHelper.Error($"缺少配置字段设备管理软件接口地址【ServiceApiUrl】。");
this.Close();
@ -60,7 +49,7 @@ namespace TsSFCDeivceClient
APIResponseData apiResponseData = Biz.HttpHelper.Instance.Get($"{ServiceUrl}{DeviceApiUrlConstValue.GetWhereFailureOccurred}");
APIResponseData apiResponseData = Biz.HttpHelper.Instance.Get($"{RunConfig.config.ServiceApiUrl}{DeviceApiUrlConstValue.GetWhereFailureOccurred}");
if (!apiResponseData.IsSuccess)
throw new Exception(apiResponseData.Message);
@ -85,7 +74,7 @@ namespace TsSFCDeivceClient
mail = new MailKitHelp();
}
//发件服务器设置
APIResponseData apiRtn = Biz.HttpHelper.Instance.Get($"{ServiceUrl}{DeviceApiUrlConstValue.SysEmailConfig}?ModuleCode=DeviceWarranty");
APIResponseData apiRtn = Biz.HttpHelper.Instance.Get($"{RunConfig.config.ServiceApiUrl}{DeviceApiUrlConstValue.SysEmailConfig}?ModuleCode=DeviceWarranty");
if (!apiRtn.IsSuccess)
throw new Exception(apiRtn.Message);
@ -232,14 +221,14 @@ namespace TsSFCDeivceClient
if (InProduction)
{
APIResponseData apiRtn = Biz.HttpHelper.Instance.Get($"{ServiceUrl}{DeviceApiUrlConstValue.GetBatchInfoToStaff}?Batch={cBatch}");
APIResponseData apiRtn = Biz.HttpHelper.Instance.Get($"{RunConfig.config.ServiceApiUrl}{DeviceApiUrlConstValue.GetBatchInfoToStaff}?Batch={cBatch}");
if (!apiRtn.IsSuccess)
throw new Exception(apiRtn.Message);
if (apiRtn.ToInt() == 0)
throw new Exception("当前批次不存在!");
apiRtn = Biz.HttpHelper.Instance.Get($"{ServiceUrl}{DeviceApiUrlConstValue.CurrentBatchManagerEmail}?Batch={cBatch}");
apiRtn = Biz.HttpHelper.Instance.Get($"{RunConfig.config.ServiceApiUrl}{DeviceApiUrlConstValue.CurrentBatchManagerEmail}?Batch={cBatch}");
if (!apiRtn.IsSuccess)
throw new Exception(apiRtn.Message);
emailLst.AddRange(apiRtn.ToDeserializeObject<List<string>>());
@ -259,7 +248,7 @@ namespace TsSFCDeivceClient
ReceivingDep = "设备设施部"
};
APIResponseData apiResponseData = Biz.HttpHelper.Instance.Post($"{ServiceUrl}{DeviceApiUrlConstValue.DeviceDownFormAdd}", JsonConvert.SerializeObject(deviceWarrantyRequestForm));
APIResponseData apiResponseData = Biz.HttpHelper.Instance.Post($"{RunConfig.config.ServiceApiUrl}{DeviceApiUrlConstValue.DeviceDownFormAdd}", JsonConvert.SerializeObject(deviceWarrantyRequestForm));
if (!apiResponseData.IsSuccess)
throw new Exception(apiResponseData.Message);

View File

@ -0,0 +1,38 @@
using System.Configuration;
using System.Windows.Forms;
namespace TsSFCDeivceClient
{
public class RunConfig
{
private static RunConfig Manger;
public static RunConfig config
{
get
{
if (Manger == null)
Manger = new RunConfig();
return Manger;
}
}
public RunConfig()
{
}
Configuration m_Config = ConfigurationManager.OpenExeConfiguration(System.IO.Path.Combine(Application.StartupPath, "TsSFCDeivceClient.dll"));
private string _ServiceApiUrl;
public string ServiceApiUrl
{
get
{
if (string.IsNullOrWhiteSpace(_ServiceApiUrl))
_ServiceApiUrl = m_Config.AppSettings.Settings["ServiceApiUrl"].Value.Trim();
return _ServiceApiUrl;
}
}
}
}

View File

@ -142,6 +142,7 @@
</Compile>
<Compile Include="Program.cs" />
<Compile Include="Properties\AssemblyInfo.cs" />
<Compile Include="RunConfig.cs" />
<Compile Include="Runtime.cs" />
<EmbeddedResource Include="DowntimeFormAdd.resx">
<DependentUpon>DowntimeFormAdd.cs</DependentUpon>
@ -181,10 +182,6 @@
<None Include="App.config" />
</ItemGroup>
<ItemGroup>
<ProjectReference Include="..\DeviceRepair.DataAccess\DeviceRepair.DataAccess.csproj">
<Project>{4e787bc1-b925-4829-a81f-b0075d8d6790}</Project>
<Name>DeviceRepair.DataAccess</Name>
</ProjectReference>
<ProjectReference Include="..\DeviceRepair.Models\DeviceRepair.Models.csproj">
<Project>{2a1ffb12-b20f-4f9b-905e-1f928f17b4ee}</Project>
<Name>DeviceRepair.Models</Name>

View File

@ -12,15 +12,7 @@ namespace TsSFCDeivceClient
int m_SelectedCurrentRowIndex = 0;
public DeviceInformationInfo CurrentDeviceInfo = null;
System.Configuration.Configuration m_Config = System.Configuration.ConfigurationManager.OpenExeConfiguration(System.Configuration.ConfigurationUserLevel.None);
string ServiceUrl
{
get
{
return m_Config.AppSettings.Settings["ServiceApiUrl"].Value.Trim();
}
}
string FilterString
{
get { return txt_Filter.EditValue?.ToString()?.Trim(); }
@ -34,7 +26,7 @@ namespace TsSFCDeivceClient
private void PageDeivceView_Load(object sender, EventArgs e)
{
if (string.IsNullOrWhiteSpace(ServiceUrl))
if (string.IsNullOrWhiteSpace(RunConfig.config.ServiceApiUrl))
{
XtraMessageBoxHelper.Error($"缺少配置字段设备管理软件接口地址【ServiceApiUrl】。");
this.Close();
@ -49,7 +41,7 @@ namespace TsSFCDeivceClient
try
{
splashScreenManager1.ShowWaitForm();
APIResponseData apiResponseData = Biz.HttpHelper.Instance.Get($"{ServiceUrl}{DeviceApiUrlConstValue.GetDeviceDatas}?FilterString={FilterString}");
APIResponseData apiResponseData = Biz.HttpHelper.Instance.Get($"{RunConfig.config.ServiceApiUrl}{DeviceApiUrlConstValue.GetDeviceDatas}?FilterString={FilterString}");
if (!apiResponseData.IsSuccess)
throw new Exception(apiResponseData.Message);

View File

@ -20,16 +20,7 @@ namespace TsSFCDeivceClient
{
int m_SelectedCurrentRowIndex = 0;
DataRow CurrentRequestForm = null;
System.Configuration.Configuration m_Config = System.Configuration.ConfigurationManager.OpenExeConfiguration(System.Configuration.ConfigurationUserLevel.None);
string ServiceUrl
{
get
{
return m_Config.AppSettings.Settings["ServiceApiUrl"].Value.Trim();
}
}
List<LookUpItemModel> lookupMaintenanceStatus;
#region
@ -115,14 +106,14 @@ namespace TsSFCDeivceClient
this.Close();
}
if (string.IsNullOrWhiteSpace(ServiceUrl))
if (string.IsNullOrWhiteSpace(RunConfig.config.ServiceApiUrl))
{
XtraMessageBoxHelper.Error($"缺少配置字段设备管理软件接口地址【ServiceApiUrl】。");
this.Close();
}
APIResponseData apiResponseData = Biz.HttpHelper.Instance.Get($"{ServiceUrl}{DeviceApiUrlConstValue.CurrentIsManager}?UserCode={Runtime.CurrentUser.UserCode}");
APIResponseData apiResponseData = Biz.HttpHelper.Instance.Get($"{RunConfig.config.ServiceApiUrl}{DeviceApiUrlConstValue.CurrentIsManager}?UserCode={Runtime.CurrentUser.UserCode}");
if (!apiResponseData.IsSuccess)
{
XtraMessageBoxHelper.Error(apiResponseData.Message);
@ -213,7 +204,7 @@ namespace TsSFCDeivceClient
try
{
splashScreenManager1.ShowWaitForm();
APIResponseData apiResponseData = Biz.HttpHelper.Instance.Post($"{ServiceUrl}{DeviceApiUrlConstValue.GetMaintenance}", JsonConvert.SerializeObject(FilterInfo));
APIResponseData apiResponseData = Biz.HttpHelper.Instance.Post($"{RunConfig.config.ServiceApiUrl}{DeviceApiUrlConstValue.GetMaintenance}", JsonConvert.SerializeObject(FilterInfo));
if (!apiResponseData.IsSuccess)
throw new Exception(apiResponseData.Message);
@ -507,7 +498,7 @@ namespace TsSFCDeivceClient
FormID = Item.AutoID,
};
APIResponseData apiResponseData = Biz.HttpHelper.Instance.Post($"{ServiceUrl}{DeviceApiUrlConstValue.MaintenanceFormAssessment}", JsonConvert.SerializeObject(info));
APIResponseData apiResponseData = Biz.HttpHelper.Instance.Post($"{RunConfig.config.ServiceApiUrl}{DeviceApiUrlConstValue.MaintenanceFormAssessment}", JsonConvert.SerializeObject(info));
if (!apiResponseData.IsSuccess)
throw new Exception(apiResponseData.Message);
CloseWaitForm();
@ -569,7 +560,7 @@ namespace TsSFCDeivceClient
FormID = Item.AutoID,
};
APIResponseData apiResponseData = Biz.HttpHelper.Instance.Post($"{ServiceUrl}{DeviceApiUrlConstValue.MaintenanceFormAssessment}", JsonConvert.SerializeObject(info));
APIResponseData apiResponseData = Biz.HttpHelper.Instance.Post($"{RunConfig.config.ServiceApiUrl}{DeviceApiUrlConstValue.MaintenanceFormAssessment}", JsonConvert.SerializeObject(info));
if (!apiResponseData.IsSuccess)
throw new Exception(apiResponseData.Message);
}
@ -625,7 +616,7 @@ namespace TsSFCDeivceClient
{
splashScreenManager1.ShowWaitForm();
APIResponseData apiResponseData = Biz.HttpHelper.Instance.Post($"{ServiceUrl}{DeviceApiUrlConstValue.DeviceResumptionComfirm}?AutoID={AutoID}", "");
APIResponseData apiResponseData = Biz.HttpHelper.Instance.Post($"{RunConfig.config.ServiceApiUrl}{DeviceApiUrlConstValue.DeviceResumptionComfirm}?AutoID={AutoID}", "");
if (!apiResponseData.IsSuccess)
throw new Exception(apiResponseData.Message);