Commit 20ed5a57 by liulongfei

登录 gh 服务名 与 viz用户名 改为可选

parent e63ff74b
......@@ -41,6 +41,5 @@ namespace VIZ.Package.Domain
/// Viz 层集合
/// </summary>
public readonly static List<VizLayer> VIZ_LAYERS = new List<VizLayer> { VizLayer.FRONT_LAYER, VizLayer.MAIN_LAYER, VizLayer.BACK_LAYER };
}
}
......@@ -70,13 +70,17 @@
<!-- ServerName -->
<TextBlock Text="服务名:" Grid.Row="3" VerticalAlignment="Center" HorizontalAlignment="Right" Margin="0,0,10,0"></TextBlock>
<dxe:TextEdit Grid.Row="3" Grid.Column="1" Height="30"
EditValue="{Binding GH_ServerName,Mode=TwoWay}"></dxe:TextEdit>
<dxe:ComboBoxEdit Grid.Row="3" Grid.Column="1" Height="30" IsTextEditable="False"
ItemsSource="{Binding Path=GH_ServerName_List}"
SelectedItem="{Binding Path=GH_ServerName,Mode=TwoWay}">
</dxe:ComboBoxEdit>
<!-- UserName -->
<TextBlock Text="用户名:" Grid.Row="4" VerticalAlignment="Center" HorizontalAlignment="Right" Margin="0,0,10,0"></TextBlock>
<dxe:TextEdit Grid.Row="4" Grid.Column="1" Height="30"
EditValue="{Binding VIZ_UserName,Mode=TwoWay}"></dxe:TextEdit>
<dxe:ComboBoxEdit Grid.Row="4" Grid.Column="1" Height="30" IsTextEditable="False"
ItemsSource="{Binding Path=VIZ_UserName_List}"
SelectedItem="{Binding Path=VIZ_UserName,Mode=TwoWay}">
</dxe:ComboBoxEdit>
<!-- Password -->
<TextBlock Text="密码:" Grid.Row="5" VerticalAlignment="Center" HorizontalAlignment="Right" Margin="0,0,10,0"></TextBlock>
......
......@@ -163,6 +163,20 @@ namespace VIZ.Package.Module
#endregion
#region GH_ServerName_List -- GH 服务名列表
private List<string> gh_ServerName_List;
/// <summary>
/// GH 服务名列表
/// </summary>
public List<string> GH_ServerName_List
{
get { return gh_ServerName_List; }
set { gh_ServerName_List = value; this.RaisePropertyChanged(nameof(GH_ServerName_List)); }
}
#endregion
#region VIZ_UserName -- VIZ 用户名
private string viz_userName;
......@@ -177,6 +191,20 @@ namespace VIZ.Package.Module
#endregion
#region VIZ_UserName_List -- VIZ 用户名列表
private List<string> viz_UserName_List;
/// <summary>
/// 用户名列表
/// </summary>
public List<string> VIZ_UserName_List
{
get { return viz_UserName_List; }
set { viz_UserName_List = value; this.RaisePropertyChanged(nameof(VIZ_UserName_List)); }
}
#endregion
#region VIZ_Password -- VIZ 密码
private string viz_password;
......@@ -214,6 +242,13 @@ namespace VIZ.Package.Module
this.IsLoading = true;
// Step 1. 加载GH服务名列表 & VIZ服务名
this.GH_ServerName_List = ApplicationDomainEx.IniStorage.GetValue<VizConfig, string>(p => p.VIZ_GH_SERVER_NAME)
?.Split(new char[] { '|' }, StringSplitOptions.RemoveEmptyEntries)?.ToList();
this.VIZ_UserName_List = ApplicationDomainEx.IniStorage.GetValue<VizConfig, string>(p => p.VIZ_USER_NAME)
?.Split(new char[] { '|' }, StringSplitOptions.RemoveEmptyEntries)?.ToList();
ThreadHelper.SafeRun(action: () =>
{
// Step 1. 加载Viz配置信息
......
......@@ -29,5 +29,17 @@ namespace VIZ.Package.Storage
/// </summary>
[Ini(Section = "Viz", DefaultValue = "position", Type = typeof(int))]
public string VIZ_FIELD_EDIT_DUPLET_TRIPLET_HIDDEN_FILTER { get; set; }
/// <summary>
/// Viz GH服务名: VizDbServer , 使用 "|" 分隔
/// </summary>
[Ini(Section = "Viz", DefaultValue = "VizDbServer", Type = typeof(string))]
public string VIZ_GH_SERVER_NAME { get; set; }
/// <summary>
/// Viz 用户名: Guest|Admin , 使用 "|" 分隔
/// </summary>
[Ini(Section = "Viz", DefaultValue = "Guest|Admin", Type = typeof(string))]
public string VIZ_USER_NAME { get; set; }
}
}
......@@ -8,3 +8,7 @@ VIZ_IMAGE_FILTER=图片|*.jpg;*.jpeg;*.bmp;*.png;
VIZ_PREVIEW_RESTART_WAIT=3000
; Viz预览编辑器类型: duplet、triplet 数据隐藏过滤器, 使用 "|" 分隔
VIZ_FIELD_EDIT_DUPLET_TRIPLET_HIDDEN_FILTER=position
; Viz GH服务名: VizDbServer , 使用 "|" 分隔
VIZ_GH_SERVER_NAME=VizDbServer
; Viz 用户名: Guest|Admin , 使用 "|" 分隔
VIZ_USER_NAME=Guest|Admin
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment