You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
93 lines
2.6 KiB
93 lines
2.6 KiB
1 year ago
|
using System.Collections.Generic;
|
||
|
using UniRx;
|
||
|
|
||
|
public class LinkageForces
|
||
|
{
|
||
|
public List<LinkageForce> Forces;
|
||
|
}
|
||
|
public class LinkageForce
|
||
|
{
|
||
|
public string Id;
|
||
|
/// <summary>
|
||
|
/// 部门
|
||
|
/// </summary>
|
||
|
public string Department { get; set; }
|
||
|
/// <summary>
|
||
|
/// 单位名称
|
||
|
/// </summary>
|
||
|
public string Organization { get; set; }
|
||
|
/// <summary>
|
||
|
/// 地址
|
||
|
/// </summary>
|
||
|
public string Address { get; set; }
|
||
|
/// <summary>
|
||
|
/// 电话
|
||
|
/// </summary>
|
||
|
public string Phone { get; set; }
|
||
|
/// <summary>
|
||
|
/// 力量调派
|
||
|
/// </summary>
|
||
|
public string ForceAllocation { get; set; }
|
||
|
/// <summary>
|
||
|
/// 任务职责
|
||
|
/// </summary>
|
||
|
public string Duty { get; set; }
|
||
|
}
|
||
|
public class LinkageForceReactive
|
||
|
{
|
||
|
private LinkageForce Data = new LinkageForce();
|
||
|
public ReactiveProperty<string> Id { get; set; } = new ReactiveProperty<string>();
|
||
|
/// <summary>
|
||
|
/// 部门
|
||
|
/// </summary>
|
||
|
public ReactiveProperty<string> Department { get; set; } = new ReactiveProperty<string>();
|
||
|
/// <summary>
|
||
|
/// 单位名称
|
||
|
/// </summary>
|
||
|
public ReactiveProperty<string> Organization { get; set; } = new ReactiveProperty<string>();
|
||
|
/// <summary>
|
||
|
/// 地址
|
||
|
/// </summary>
|
||
|
public ReactiveProperty<string> Address { get; set; } = new ReactiveProperty<string>();
|
||
|
/// <summary>
|
||
|
/// 电话
|
||
|
/// </summary>
|
||
|
public ReactiveProperty<string> Phone { get; set; } = new ReactiveProperty<string>();
|
||
|
/// <summary>
|
||
|
/// 力量调派
|
||
|
/// </summary>
|
||
|
public ReactiveProperty<string> ForceAllocation { get; set; } = new ReactiveProperty<string>();
|
||
|
/// <summary>
|
||
|
/// 任务职责
|
||
|
/// </summary>
|
||
|
public ReactiveProperty<string> Duty { get; set; } = new ReactiveProperty<string>();
|
||
|
|
||
|
public LinkageForceReactive()
|
||
|
{
|
||
|
Id.Subscribe(value => Data.Id = value);
|
||
|
Department.Subscribe(value => Data.Department = value);
|
||
|
Organization.Subscribe(value => Data.Organization = value);
|
||
|
Address.Subscribe(value => Data.Address = value);
|
||
|
Phone.Subscribe(value => Data.Phone = value);
|
||
|
ForceAllocation.Subscribe(value => Data.ForceAllocation = value);
|
||
|
Duty.Subscribe(value => Data.Duty = value);
|
||
|
}
|
||
|
|
||
|
public void SetData(LinkageForce data)
|
||
|
{
|
||
|
Data = data;
|
||
|
Id.Value = data.Id;
|
||
|
Department.Value = data.Department;
|
||
|
Organization.Value = data.Organization;
|
||
|
Address.Value = data.Address;
|
||
|
Phone.Value = data.Phone;
|
||
|
ForceAllocation.Value = data.ForceAllocation;
|
||
|
Duty.Value = data.Duty;
|
||
|
}
|
||
|
|
||
|
public LinkageForce GetData()
|
||
|
{
|
||
|
return Data;
|
||
|
}
|
||
|
}
|