/// <summary> /// 根据窗口类型实例化包含不同标题、按钮文字等信息的定单改变窗口 /// </summary> /// <param name="type">窗口类型</param> public OrderChangedWindow(OrderChangedWindowType type) { InitializeComponent( ); _orderChangedInfo = new OrderChangedInformation( ); string windowTitle; string waterMark; string buttonContent; if (type == OrderChangedWindowType.Chargeback) { windowTitle = "平仓"; waterMark = "请输入平仓数量"; buttonContent = "平仓"; } else { windowTitle = "入库"; waterMark = "请输入入库数量"; buttonContent = "入库"; } Title = windowTitle; DudCount.Watermark = waterMark; BtOk.Content = buttonContent; }
/// <summary> /// 根据窗口类型实例化包含不同标题、按钮文字等信息的定单改变窗口 /// </summary> /// <param name="type">窗口类型</param> public OrderChangedWindow( OrderChangedWindowType type ) { InitializeComponent( ); _orderChangedInfo = new OrderChangedInformation( ); string windowTitle; string waterMark; string buttonContent; if( type == OrderChangedWindowType.Chargeback ) { windowTitle = "平仓"; waterMark = "请输入平仓数量"; buttonContent = "平仓"; } else { windowTitle = "入库"; waterMark = "请输入入库数量"; buttonContent = "入库"; } Title = windowTitle; DudCount.Watermark = waterMark; BtOk.Content = buttonContent; }