#if !defined(AFX_ACTIONRESDLG_H__350F4FD5_D19C_4661_AACD_EEC04F7D4349__INCLUDED_)
#define AFX_ACTIONRESDLG_H__350F4FD5_D19C_4661_AACD_EEC04F7D4349__INCLUDED_

#if _MSC_VER > 1000
#pragma once
#endif // _MSC_VER > 1000
// BPResDlg.h : header file
//
#include "resource.h"
#include <apl_gui.h>
/////////////////////////////////////////////////////////////////////////////
// CBPResDlg dialog

class CaplInstance;
class CaplAPI;

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

// Dialog Data
	//{{AFX_DATA(CBPResDlg)
	enum { IDD = IDD_BP_RES };
	CEdit	m_ranking_ctrl;
	CEdit	m_ranking_rationale_ctrl;
	//CComboBox	m_sortament;
	CEdit	m_val_der_ctrl;
	CComboBox	m_unit_der_ctrl;
	CEdit	m_val_ctrl;
	CEdit	m_descr_ctrl;
	CComboBox	m_unit_ctrl;
	CComboBox	m_type_ctrl;
	CEdit	m_obj_ctrl;
	CEdit	m_name_ctrl;
	CEdit	m_id_ctrl;
	CaplButton	m_cancel_btn;
	CaplButton	m_ok_btn;
	CString	m_id;
	CString	m_name;
	CString	m_descr;
	CString	m_ranking_rationale;
	//}}AFX_DATA
	CaplInstance *m_inst;
	CaplInstance *m_bp;
	CaplInstance *m_bp_inst;
	CaplInstance *m_bp_rev;
	CaplInstance *m_obj;

	CaplInstance *m_base_pdr;
	CaplInstance *m_base_res;
	
	CaplInstance *m_type;
	CaplInstance *m_unit;
	CaplInstance *m_unit_der;
	CaplInstance *m_assortment;
	double m_res_value;
	double m_res_der_value;
	int m_ranking_value;

	CaplAPI *m_api;
	bool m_ReadOnly;

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

// Implementation
protected:

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

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

#endif // !defined(AFX_ACTIONRESDLG_H__350F4FD5_D19C_4661_AACD_EEC04F7D4349__INCLUDED_)
