#if !defined(AFX_PRDRELATIONDLG_H__1128A553_ABC3_11D3_B99D_00C026EE04F6__INCLUDED_)
#define AFX_PRDRELATIONDLG_H__1128A553_ABC3_11D3_B99D_00C026EE04F6__INCLUDED_

#if _MSC_VER > 1000
#pragma once
#endif // _MSC_VER > 1000
// PrdRelationDlg.h : header file
//

/////////////////////////////////////////////////////////////////////////////
// CPrdRelationDlg dialog
class CaplInstance;
class CaplStepData;
class CaplProductManager;
class CaplCharacteristicManager;

class CPrdRelationDlg : public CaplTranslateDialog
{
// Construction
public:
	CPrdRelationDlg(CWnd* pParent = NULL);   // standard constructor

// Dialog Data
	//{{AFX_DATA(CPrdRelationDlg)
	enum { IDD = IDD_PRODUCT_RELATIONSHIP };
	CStatic	m_st_ref_des_ctrl;
	CEdit	m_ref_des_ctrl;
	CEdit	m_pdr_id_ctrl;
	CEdit	m_prd_descr_ctrl;
	CEdit	m_pdr_name_ctrl;
	CStatic	m_st_context;
	CButton	m_context_sel;
	CEdit	m_context_names;
	CaplButton	m_cancel_btn;
	CaplButton	m_ok_btn;
	//CStatic	m_st_sort;
	CStatic	m_st_count2;
	CEdit	m_count_2_ctrl;
	CComboBox	m_prd_unit_2;
	//CComboBox	m_sortament;
	CStatic	m_st_rank_rat;
	CStatic	m_st_name;
	CStatic	m_st_descr;
	CEdit	m_ranking_rationale_ctrl;
	CEdit	m_ranking_ctrl;
	CStatic	m_st_ranking;
	CEdit	m_count_ctrl;
	CStatic	m_static_count_name;
	CComboBox	m_pdr_unit;
	CStatic	m_pdr_id_name;
	double	m_count;
	CString	m_in_pdf_id;
	CString	m_in_prd_id;
	CString	m_out_pdf_id;
	CString	m_out_prd_name;
	CString	m_pdr_descr;
	CString	m_pdr_id;
	CString	m_pdr_name;
	CString	m_out_prd_id;
	CString	m_in_prd_name;
	int		m_ranking;
	CString	m_ranking_rationale;
	double	m_count_2;
	CString	m_ref_des;
	//}}AFX_DATA

// Overrides
	// ClassWizard generated virtual function overrides
	//{{AFX_VIRTUAL(CPrdRelationDlg)
	protected:
	virtual void DoDataExchange(CDataExchange* pDX);    // DDX/DDV support
	//}}AFX_VIRTUAL

public:
	void MoveRefDes();
	CaplInstance *m_in_pdf;
	CaplInstance *m_in_prd;

	CaplInstance *m_out_pdf;
	CaplInstance *m_out_prd;

	CaplInstance *m_pdr;
	CaplInstance *m_prd_r;
	CaplNetStepData *m_data;
	CaplProductManager *m_prd_mgr;
	CaplCharacteristicManager *m_charact_mgr;
	CString m_mode;

	CaplInstance *m_pd;
	CaplInstance *m_pd_i;

	aplExtent m_nauo_contexts;
	
	CaplInstance *m_nauo;//связь для создания заменителя в контексте сборки
	CaplInstance *m_subst;//связь заменитель в контексте сборки

// Implementation
protected:

	// Generated message map functions
	//{{AFX_MSG(CPrdRelationDlg)
	virtual BOOL OnInitDialog();
	virtual void OnOK();
	afx_msg void OnContextSel2();
	//}}AFX_MSG
	DECLARE_MESSAGE_MAP()
};

//{{AFX_INSERT_LOCATION}}
// Microsoft Visual C++ will insert additional declarations immediately before the previous line.

#endif // !defined(AFX_PRDRELATIONDLG_H__1128A553_ABC3_11D3_B99D_00C026EE04F6__INCLUDED_)
