提交代码
This commit is contained in:
@@ -0,0 +1,7 @@
|
||||
alter table dbo.Person_Persons
|
||||
add IsInspectionBrigade bit
|
||||
go
|
||||
|
||||
exec sp_addextendedproperty 'MS_Description', N'是否督查人员', 'SCHEMA', 'dbo', 'TABLE', 'Person_Persons', 'COLUMN',
|
||||
'IsInspectionBrigade'
|
||||
go
|
||||
@@ -750,6 +750,7 @@ namespace BLL
|
||||
RelativeTel = person.RelativeTel,
|
||||
MultiProject = person.MultiProject,
|
||||
HomePageType = person.HomePageType,
|
||||
IsInspectionBrigade = person.IsInspectionBrigade,
|
||||
};
|
||||
|
||||
if (string.IsNullOrEmpty(person.QRCodeAttachUrl))
|
||||
@@ -859,7 +860,7 @@ namespace BLL
|
||||
newPerson.HomePageType = person.HomePageType;
|
||||
newPerson.LogWorkPostId = person.LogWorkPostId;
|
||||
newPerson.LogMachineId = person.LogMachineId;
|
||||
|
||||
newPerson.IsInspectionBrigade = person.IsInspectionBrigade;
|
||||
newPerson.IsCardNoOK = IDCardValid.CheckIDCard(person.IdentityCard);
|
||||
if (string.IsNullOrEmpty(person.QRCodeAttachUrl))
|
||||
{
|
||||
|
||||
@@ -1925,6 +1925,38 @@
|
||||
var responeData = BLL.ServerService.PushCNCEC(resultJsonReport, baseurl);
|
||||
return responeData.code;
|
||||
}
|
||||
#endregion
|
||||
|
||||
#region 督查人员推送
|
||||
|
||||
public static int PushInspectionBrigadeUser()
|
||||
{
|
||||
|
||||
string baseurl = "/api/InspectionBrigade/SaveInspectionBrigadeUser";
|
||||
var CollCropCode = BLL.CommonService.GetIsThisUnit()?.CollCropCode;
|
||||
var userList = from x in Funs.DB.Person_Persons
|
||||
where x.IsInspectionBrigade == true
|
||||
select new Model.InspectionBrigadeUserItem()
|
||||
{
|
||||
|
||||
UserId = x.PersonId,
|
||||
UserName = x.PersonName,
|
||||
Sex = x.Sex,
|
||||
Account = x.Account,
|
||||
Password = x.Password,
|
||||
IdentityCard = x.IdentityCard,
|
||||
Telephone = x.Telephone,
|
||||
CollCropCode = CollCropCode
|
||||
|
||||
};
|
||||
|
||||
var resultJsonReport = JsonConvert.SerializeObject(userList.ToList());
|
||||
resultJsonReport = "{\"InspectionBrigadeUserItems\":" + resultJsonReport.Replace("}{", ",") + "}";
|
||||
var responeData = BLL.ServerService.PushCNCEC(resultJsonReport, baseurl);
|
||||
return responeData.code;
|
||||
}
|
||||
|
||||
|
||||
#endregion
|
||||
#endregion
|
||||
|
||||
|
||||
@@ -320,7 +320,7 @@
|
||||
<f:RadioItem Text="施工管理" Value="1" Selected="true" />
|
||||
<f:RadioItem Text="QHSE" Value="2" />
|
||||
</f:RadioButtonList>
|
||||
<f:Label runat="server" ID="lb1"></f:Label>
|
||||
<f:CheckBox runat="server" Label="是否督查人员" LabelWidth="120px" LabelAlign="Right" ID="cbIsInspectionBrigade"/>
|
||||
<f:Label runat="server" ID="lb2"></f:Label>
|
||||
<f:Label runat="server" ID="lb3"></f:Label>
|
||||
</Items>
|
||||
|
||||
@@ -207,6 +207,7 @@ namespace FineUIPro.Web.Person
|
||||
{
|
||||
this.drpMaritalStatus.SelectedValue = person.MaritalStatus;
|
||||
}
|
||||
cbIsInspectionBrigade.Checked = person.IsInspectionBrigade ?? false;
|
||||
this.txtRelativeName.Text = person.RelativeName;
|
||||
this.txtRelativeTel.Text = person.RelativeTel;
|
||||
this.txtAddress.Text = person.Address;
|
||||
@@ -563,6 +564,7 @@ namespace FineUIPro.Web.Person
|
||||
IsOffice = this.ckIsOffice.Checked,
|
||||
};
|
||||
newPerson.HomePageType = this.rblHomePageType.SelectedValue;
|
||||
newPerson.IsInspectionBrigade = cbIsInspectionBrigade.Checked;
|
||||
newPerson.RoleIds = Funs.GetStringByArray(this.drpRole.SelectedValueArray);
|
||||
if (!string.IsNullOrEmpty(imgPhoto.ImageUrl) && imgPhoto.ImageUrl != "~/res/images/blank.png")
|
||||
{
|
||||
|
||||
+4
-6
@@ -7,12 +7,10 @@
|
||||
// </自动生成>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace FineUIPro.Web.Person
|
||||
{
|
||||
namespace FineUIPro.Web.Person {
|
||||
|
||||
|
||||
public partial class PersonEdit
|
||||
{
|
||||
public partial class PersonEdit {
|
||||
|
||||
/// <summary>
|
||||
/// _form1 控件。
|
||||
@@ -618,13 +616,13 @@ namespace FineUIPro.Web.Person
|
||||
protected global::FineUIPro.RadioButtonList rblHomePageType;
|
||||
|
||||
/// <summary>
|
||||
/// lb1 控件。
|
||||
/// cbIsInspectionBrigade 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Label lb1;
|
||||
protected global::FineUIPro.CheckBox cbIsInspectionBrigade;
|
||||
|
||||
/// <summary>
|
||||
/// lb2 控件。
|
||||
|
||||
@@ -54,6 +54,9 @@
|
||||
<f:Button ID="btnIDCard" Text="刷新信息" Icon="ArrowRefresh" Hidden="true" runat="server"
|
||||
OnClick="btnIDCard_Click">
|
||||
</f:Button>
|
||||
<f:Button ID="btnUpdata" Text="推送督查人员" Icon="PageSave" runat="server" ConfirmText="确定推送?"
|
||||
ToolTip="推送" ValidateForms="SimpleForm1" OnClick="btnPush_Click" MarginRight="10px">
|
||||
</f:Button>
|
||||
</Items>
|
||||
</f:Toolbar>
|
||||
</Toolbars>
|
||||
|
||||
@@ -306,5 +306,20 @@ namespace FineUIPro.Web.Person
|
||||
//info += "共处理人员所在当前项目取值" + pCountRecod.ToString() + "条。";
|
||||
Alert.ShowInParent(info, MessageBoxIcon.Information);
|
||||
}
|
||||
|
||||
protected void btnPush_Click(object sender, EventArgs e)
|
||||
{
|
||||
string code = CNCECHSSEWebService.PushInspectionBrigadeUser().ToString();
|
||||
if (code == "1")
|
||||
{
|
||||
ShowNotify("同步成功!", MessageBoxIcon.Success);
|
||||
PageContext.RegisterStartupScript(ActiveWindow.GetHidePostBackReference());
|
||||
return;
|
||||
}
|
||||
else
|
||||
{
|
||||
Alert.ShowInParent("同步异常,请退出后重试!", MessageBoxIcon.Error);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
+11
-4
@@ -7,12 +7,10 @@
|
||||
// </自动生成>
|
||||
//------------------------------------------------------------------------------
|
||||
|
||||
namespace FineUIPro.Web.Person
|
||||
{
|
||||
namespace FineUIPro.Web.Person {
|
||||
|
||||
|
||||
public partial class PersonLib
|
||||
{
|
||||
public partial class PersonLib {
|
||||
|
||||
/// <summary>
|
||||
/// form1 控件。
|
||||
@@ -167,6 +165,15 @@ namespace FineUIPro.Web.Person
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Button btnIDCard;
|
||||
|
||||
/// <summary>
|
||||
/// btnUpdata 控件。
|
||||
/// </summary>
|
||||
/// <remarks>
|
||||
/// 自动生成的字段。
|
||||
/// 若要进行修改,请将字段声明从设计器文件移到代码隐藏文件。
|
||||
/// </remarks>
|
||||
protected global::FineUIPro.Button btnUpdata;
|
||||
|
||||
/// <summary>
|
||||
/// lbSex 控件。
|
||||
/// </summary>
|
||||
|
||||
@@ -0,0 +1,91 @@
|
||||
using System;
|
||||
|
||||
namespace Model
|
||||
{
|
||||
public class InspectionBrigadeUserItem
|
||||
{
|
||||
/// <summary>
|
||||
/// 用户ID
|
||||
/// </summary>
|
||||
public string UserId
|
||||
{
|
||||
get;
|
||||
set;
|
||||
}
|
||||
/// <summary>
|
||||
/// 账号
|
||||
/// </summary>
|
||||
public string Account
|
||||
{
|
||||
get;
|
||||
set;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 密码
|
||||
/// </summary>
|
||||
public string Password
|
||||
{
|
||||
get;
|
||||
set;
|
||||
}
|
||||
/// <summary>
|
||||
/// 用户名称
|
||||
/// </summary>
|
||||
public string UserName
|
||||
{
|
||||
get;
|
||||
set;
|
||||
}
|
||||
/// <summary>
|
||||
/// 性别
|
||||
/// </summary>
|
||||
public string Sex
|
||||
{
|
||||
get;
|
||||
set;
|
||||
}
|
||||
/// <summary>
|
||||
/// 单位ID
|
||||
/// </summary>
|
||||
public string UnitId
|
||||
{
|
||||
get;
|
||||
set;
|
||||
}
|
||||
/// <summary>
|
||||
/// 单位名称
|
||||
/// </summary>
|
||||
public string UnitName
|
||||
{
|
||||
get;
|
||||
set;
|
||||
}
|
||||
/// <summary>
|
||||
/// 单位社会统一信用代码
|
||||
/// </summary>
|
||||
public string CollCropCode
|
||||
{
|
||||
get;
|
||||
set;
|
||||
}
|
||||
/// <summary>
|
||||
/// 身份证
|
||||
/// </summary>
|
||||
public string IdentityCard
|
||||
{
|
||||
get;
|
||||
set;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// 电话
|
||||
/// </summary>
|
||||
public string Telephone
|
||||
{
|
||||
get;
|
||||
set;
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
@@ -160060,6 +160060,8 @@ namespace Model
|
||||
|
||||
private string _LogMachineId;
|
||||
|
||||
private System.Nullable<bool> _IsInspectionBrigade;
|
||||
|
||||
private EntitySet<Accident_AccidentHandle> _Accident_AccidentHandle;
|
||||
|
||||
private EntitySet<Accident_AccidentPersonRecord> _Accident_AccidentPersonRecord;
|
||||
@@ -160672,6 +160674,8 @@ namespace Model
|
||||
partial void OnLogWorkPostIdChanged();
|
||||
partial void OnLogMachineIdChanging(string value);
|
||||
partial void OnLogMachineIdChanged();
|
||||
partial void OnIsInspectionBrigadeChanging(System.Nullable<bool> value);
|
||||
partial void OnIsInspectionBrigadeChanged();
|
||||
#endregion
|
||||
|
||||
public Person_Persons()
|
||||
@@ -162234,6 +162238,26 @@ namespace Model
|
||||
}
|
||||
}
|
||||
|
||||
[global::System.Data.Linq.Mapping.ColumnAttribute(Storage="_IsInspectionBrigade", DbType="Bit")]
|
||||
public System.Nullable<bool> IsInspectionBrigade
|
||||
{
|
||||
get
|
||||
{
|
||||
return this._IsInspectionBrigade;
|
||||
}
|
||||
set
|
||||
{
|
||||
if ((this._IsInspectionBrigade != value))
|
||||
{
|
||||
this.OnIsInspectionBrigadeChanging(value);
|
||||
this.SendPropertyChanging();
|
||||
this._IsInspectionBrigade = value;
|
||||
this.SendPropertyChanged("IsInspectionBrigade");
|
||||
this.OnIsInspectionBrigadeChanged();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
[global::System.Data.Linq.Mapping.AssociationAttribute(Name="FK_Accident_AccidentHandle_Person_Persons", Storage="_Accident_AccidentHandle", ThisKey="PersonId", OtherKey="CompileMan", DeleteRule="NO ACTION")]
|
||||
public EntitySet<Accident_AccidentHandle> Accident_AccidentHandle
|
||||
{
|
||||
|
||||
@@ -133,6 +133,7 @@
|
||||
<Compile Include="APIItem\HSSE\SeDinMonthReport4OtherItem.cs" />
|
||||
<Compile Include="APIItem\HTGL\PersonItem.cs" />
|
||||
<Compile Include="APIItem\HTGL\Pro_PersonItem.cs" />
|
||||
<Compile Include="APIItem\InspectionBrigadeUserItem.cs" />
|
||||
<Compile Include="APIItem\Law_RulesRegulations.cs" />
|
||||
<Compile Include="APIItem\NoticeOutput.cs" />
|
||||
<Compile Include="APIItem\OperationReportDto.cs" />
|
||||
|
||||
Reference in New Issue
Block a user