//---------------------------------------------------------------------------

#ifndef CDSHolidayFH
#define CDSHolidayFH
//---------------------------------------------------------------------------
#include <Classes.hpp>
#include <ADODB.hpp>
#include <DB.hpp>
#include "cxCustomData.hpp"
#include "ITSLibF.h"
//---------------------------------------------------------------------------

/*
*  Holiday class
*/
class TItsHoliday
{
public:
    TItsHoliday();
    virtual ~TItsHoliday();
    void Clear();
private:
    bool    FCompleted;
    int     FEditMode;
	int     FGridIndex;

public:
    String  YMD;            //VARCHAR2(8)	N			년월일
    String  DAY_TYPE_CD;    //VARCHAR2(7)	Y			요일 유형 코드
    String  LEGL_HLDY_NM;   //VARCHAR2(30)	Y			공휴일 명
    String  RMRK;           //VARCHAR2(200)	Y			비고

    String  DEL_YN;
    
public:
    __property bool   Completed = {read = FCompleted, write = FCompleted};
	__property int    EditMode  = {read = FEditMode,  write = FEditMode };
	__property int    GridIndex = {read = FGridIndex, write = FGridIndex };
};
//---------------------------------------------------------------------------

/*
* Holiday Manager
*/
class TItsHolidayManager
{
public:
    TItsHolidayManager();
    virtual ~TItsHolidayManager();

public:
    TItsMap<String, TItsHoliday*>    FLists;

public:
    bool LoadFromDb(TADOConnection *ADbConn=NULL);
};
//---------------------------------------------------------------------------
extern TItsHolidayManager *ItsHolidayManager;
//---------------------------------------------------------------------------

#endif

