Index: branches/src/ProcessManagement/ProcessManagement/Common/CommonDefine.cs
===================================================================
--- branches/src/ProcessManagement/ProcessManagement/Common/CommonDefine.cs	(revision 59)
+++ branches/src/ProcessManagement/ProcessManagement/Common/CommonDefine.cs	(revision 60)
@@ -1678,5 +1678,18 @@
         }
         #endregion
 
+        #region 資材返却期限
+        /// <summary>
+        /// 資材返却期限コントロールアイテム      // Add BIT 2017/03/18
+        /// </summary>
+        public static string[,] MaterualLimitItem = new string[2,4] {
+                                                                      { "資材返却", "本日返却期限の資材があります。",   "0xFF0000", "0x000000" },
+                                                                      { "資材返却", "返却期限を過ぎた資材があります。", "0x808080", "0xFF0000" }
+                                                                    };
+        public static List<KeyValuePair<int, int>> MaterualStatusCheckList = new List<KeyValuePair<int, int>>{
+            new KeyValuePair<int, int>((int)CommonDefine.TermDateCheckTiming.CheckSchdule1, 0),
+            new KeyValuePair<int, int>((int)CommonDefine.TermDateCheckTiming.CheckSchdule3, 1)};
+        #endregion
+
     }
 }
Index: branches/src/ProcessManagement/ProcessManagement/Common/Process/ClsChangeLedgerData.cs
===================================================================
--- branches/src/ProcessManagement/ProcessManagement/Common/Process/ClsChangeLedgerData.cs	(revision 59)
+++ branches/src/ProcessManagement/ProcessManagement/Common/Process/ClsChangeLedgerData.cs	(revision 60)
@@ -773,7 +773,7 @@
         /// </summary>
         /// <param name="TargetMonth"></param>
         /// <returns></returns>
-        private static int CalcTargetMonthToColumn(DateTime StartDate, DateTime TargetMonth)
+        public static int CalcTargetMonthToColumn(DateTime StartDate, DateTime TargetMonth)
         {
             FrmConstructionLedger frm = new FrmConstructionLedger();
             int Columncnt = frm.GetGridColumsCount - 1;
Index: branches/src/ProcessManagement/ProcessManagement/Common/Process/ClsExcute.cs
===================================================================
--- branches/src/ProcessManagement/ProcessManagement/Common/Process/ClsExcute.cs	(revision 59)
+++ branches/src/ProcessManagement/ProcessManagement/Common/Process/ClsExcute.cs	(revision 60)
@@ -114,6 +114,7 @@
             ConstructionExpenses = 126,         // 126:施工経費区分登録
             MaterialKind = 127,                 // 127:資材種類マスタ
             MaterialItem = 128,                 // 128:資材品目マスタ
+            SalesConfirm = 129,                 // 129:売上確認
         }
         #endregion
 
@@ -206,6 +207,7 @@
                                                                                 { (int)MaintenanceExecuteNo.ConstructionExpenses,       "施工経費区分登録"},           // 126
                                                                                 { (int)MaintenanceExecuteNo.MaterialKind,               "資材種類登録"},              // 127
                                                                                 { (int)MaintenanceExecuteNo.MaterialItem,               "資材品目登録"},              // 128
+                                                                                { (int)MaintenanceExecuteNo.SalesConfirm,               "売上確認"},              // 128
                                                                                 };
         #endregion
 
@@ -470,6 +472,9 @@
                         case (int)ProcessExecuteNo.RequestInput:                         // 31:請求入力
                             ProcessExecuteNo_RequestInput(m_ProcControlPara[NowPoint]);
                             break;
+                        case (int)ProcessExecuteNo.RequestPrint:                        // 32：請求書印刷
+                            ProcessExecuteNo_RequestPrint(m_ProcControlPara[NowPoint]);
+                            break;
 
                         #endregion  
 
@@ -559,6 +564,9 @@
                         case (int)MaintenanceExecuteNo.MaterialItem:                    // 128:資材品目マスタ
                             MaintenanceExecuteNo_MaterialItems(m_ProcControlPara[NowPoint]);
                             break;
+                        case (int)MaintenanceExecuteNo.SalesConfirm:                    // 129:売上確認
+                            MaintenanceExecuteNo_SalesConfirm(m_ProcControlPara[NowPoint]);
+                            break;
 
 
                         #endregion
@@ -1900,6 +1908,18 @@
             FrmRequestSummaryList frm = new FrmRequestSummaryList();
             try
             {
+                int ProcessNo = (int)ProcessExecuteNo.RequestSummaryList;
+
+                // 起動・編集フラグ
+                int EditFlg = (int)CommonDefine.ProcessDataEdit.Reference;
+                if (!ClsSecurityPermission.GetExecutePermission(ProcessNo, ref EditFlg))
+                {
+                    BackProcess();
+                    return;
+                }
+
+                if (EditFlg == (int)CommonDefine.ProcessDataEdit.Reference) frm.EditLock = true;
+
                 // パラメータセット
                 frm.Labourkind = CurrentPara.IntExecParameter[0];
 
@@ -1924,19 +1944,39 @@
         /// <returns></returns>
         public static void ProcessExecuteNo_RequestInput(ProcessParameter CurrentPara)
         {
-            // 工事案件選択画面
-            FrmConstructionDiag frmCnstDlg = new FrmConstructionDiag();
 
-            // 工事一覧の表示に必要なデータを設定(担当者コード、工事担当者検索)
-            frmCnstDlg.PersonCode = CommonMotions.LoginUserData.PersonCode;
-            frmCnstDlg.PersonCharge = (int)FrmConstructionDiag.PersonChargePoint.Construction;
-            frmCnstDlg.SelectType = CurrentPara.IntExecParameter[0];
+            int nConstructionCode = 0;
+            bool bEdit = true;
 
-            // 工事案件選択画面のオープン
-            frmCnstDlg.ShowDialog();
+            if( CurrentPara.BoolExecParameter[0] == false )
+            {
 
+                // 工事案件選択画面
+                FrmConstructionDiag frmCnstDlg = new FrmConstructionDiag();
+
+                // 工事一覧の表示に必要なデータを設定(担当者コード、工事担当者検索)
+                frmCnstDlg.PersonCode = CommonMotions.LoginUserData.PersonCode;
+                frmCnstDlg.PersonCharge = (int)FrmConstructionDiag.PersonChargePoint.Construction;
+                frmCnstDlg.SelectType = CurrentPara.IntExecParameter[3];
+
+                // 工事案件選択画面のオープン
+                frmCnstDlg.ShowDialog();
+
+                nConstructionCode = frmCnstDlg.ConstructionCode;
+
+                frmCnstDlg.Dispose();
+                frmCnstDlg = null;
+
+            }
+            else{
+                nConstructionCode = CurrentPara.IntExecParameter[0];
+
+                bEdit = false;
+            }
+
+
             // 工事番号を取得できなかった場合
-            if (0 == frmCnstDlg.ConstructionCode)
+            if (0 == nConstructionCode)
             {
                 ClsExcute.BackProcess();
                 return;
@@ -1949,7 +1989,10 @@
             {
 
                 // 工事案件選択画面で選択された工事番号をセット
-                frm.ConstructionCode = frmCnstDlg.ConstructionCode;
+                frm.ConstructionCode = nConstructionCode;
+                frm.ApprovalCode = CurrentPara.IntExecParameter[1];
+                frm.OrderNo = CurrentPara.IntExecParameter[2];
+                frm.EditFlg = bEdit;
 
                 // 請求入力の表示
                 frm.ShowDialog();
@@ -1977,6 +2020,17 @@
             FrmSelectPayment frm = new FrmSelectPayment();
             try
             {
+                int ProcessNo = (int)ProcessExecuteNo.PaymentConfirmation;
+
+                // 起動・編集フラグ
+                int EditFlg = (int)CommonDefine.ProcessDataEdit.Reference;
+                if (!ClsSecurityPermission.GetExecutePermission(ProcessNo, ref EditFlg))
+                {
+                    BackProcess();
+                    return;
+                }
+
+                // フォーム表示
                 frm.ShowDialog();
             }
             catch (Exception ex)
@@ -1990,6 +2044,41 @@
         }
         #endregion
 
+        #region 請求書印刷
+        /// <summary>
+        /// 請求書印刷
+        /// </summary>
+        /// <param name="CurrentPara"></param>
+        public static void ProcessExecuteNo_RequestPrint(ProcessParameter CurrentPara)
+        {
+            //　入金確認
+            FrmEntryReqSelOrderer frm = new FrmEntryReqSelOrderer();
+            try
+            {
+                int ProcessNo = (int)ProcessExecuteNo.PaymentConfirmation;
+
+                // 起動・編集フラグ
+                int EditFlg = (int)CommonDefine.ProcessDataEdit.Reference;
+                if (!ClsSecurityPermission.GetExecutePermission(ProcessNo, ref EditFlg))
+                {
+                    BackProcess();
+                    return;
+                }
+
+                // フォーム表示
+                frm.ShowDialog();
+            }
+            catch (Exception ex)
+            {
+                logger.ErrorFormat("システムエラー：{0}：{1}", CommonMotions.GetMethodName(), ex.Message);
+            }
+            finally
+            {
+                frm.Dispose(); frm = null;
+            }
+        }
+        #endregion
+
         #region マスタメンテナンス
         // ----------------- メンテナンス起動
         #region 管理マスタ
@@ -2901,8 +2990,42 @@
         }
         #endregion
 
+        #region 売上確認
+        /// <summary>
+        /// 売上確認
+        /// </summary>
+        /// <param name="CurrentPara"></param>
+        public static void MaintenanceExecuteNo_SalesConfirm(ProcessParameter CurrentPara)
+        {
+            //　売上確認
+            FrmSalesConfirm frm = new FrmSalesConfirm();
+            try
+            {
+                int ProcessNo = (int)MaintenanceExecuteNo.SalesConfirm;
+                // 起動・編集フラグ
+                int EditFlg = (int)CommonDefine.ProcessDataEdit.Reference;
+                if (!ClsSecurityPermission.GetExecutePermission(ProcessNo, ref EditFlg))
+                {
+                    BackProcess();
+                    return;
+                }
+
+                // フォーム表示
+                frm.ShowDialog();
+            }
+            catch (Exception ex)
+            {
+                logger.ErrorFormat("システムエラー：{0}：{1}", CommonMotions.GetMethodName(), ex.Message);
+            }
+            finally
+            {
+                frm.Dispose(); frm = null;
+            }
+        }
         #endregion
 
+        #endregion
+
         #region サブフォーム
         #region 掲示板メッセージ入力
         /// <summary>
Index: branches/src/ProcessManagement/ProcessManagement/Common/Process/ClsProcessExist.cs
===================================================================
--- branches/src/ProcessManagement/ProcessManagement/Common/Process/ClsProcessExist.cs	(revision 59)
+++ branches/src/ProcessManagement/ProcessManagement/Common/Process/ClsProcessExist.cs	(revision 60)
@@ -925,11 +925,11 @@
                 foreach (RequestDataDetail dt in ReqDtlList)
                 {
                     // 最終承認されている(承認済）の場合
-                    if (ClsApprovalPermission.CheckApprovalData(m_ConstructionCode, (int)ClsExcute.ApprovalListNo.OrderBillingApproval, dt.OrderNo))
-                    {
-                        Approvedflg = true;
-                        break;
-                    }
+//                    if (ClsApprovalPermission.CheckApprovalData(m_ConstructionCode, (int)ClsExcute.ApprovalListNo.OrderBillingApproval, dt.OrderNo))
+//                    {
+//                        Approvedflg = true;
+//                        break;
+//                   }
                 }
 
                 return Approvedflg;
Index: branches/src/ProcessManagement/ProcessManagement/Common/Process/ClsSecurityPermission.cs
===================================================================
--- branches/src/ProcessManagement/ProcessManagement/Common/Process/ClsSecurityPermission.cs	(revision 59)
+++ branches/src/ProcessManagement/ProcessManagement/Common/Process/ClsSecurityPermission.cs	(revision 60)
@@ -34,8 +34,42 @@
         #endregion
 
         #region 定数
+
+        #region 保護区分
+        /// <summary>
+        /// 保護区分
+        /// </summary>
+        public enum SecRangeType
+        {
+            AllDepartment = 1,
+            MultiDepartment = 2,
+            OneDepartment = 3,
+            InCharge = 4,
+        }
         #endregion
 
+        #endregion
+
+        #region ユーザ情報
+        /// <summary>
+        /// ユーザ情報
+        /// </summary>
+        public class UserInfo
+        {
+            public CommonDefine.SecurityRankPos m_Type { get; set; }            // 権限
+            public int m_GeneralAffairsFlg { get; set; }                        // 総務業務フラグ
+            public SecRangeType m_SecRange { get; set; }                        // 保護区分
+            public bool CanEditDeposit
+            {
+                get { return m_GeneralAffairsFlg == 1; }
+            }
+            public bool CanEditDepositDetail
+            {
+                get { return m_GeneralAffairsFlg == 0; }
+            }
+        }
+        #endregion
+
         #region 旧セキュリティメソッド
         #region 工事データアクセス許可
         /// <summary>
@@ -1112,6 +1146,55 @@
         }
         #endregion
 
+        #region ユーザタイプ判定
+        /// <summary>
+        /// ユーザタイプ判定
+        /// </summary>
+        public static void SetUserType(UserInfo userInfo)
+        {
+            try
+            {
+                // 保護区分ランク
+                // システム管理者・特別権限
+                if (CommonMotions.LoginUserData.PersonCode == CommonDefine.AdminCode
+                 || CommonMotions.LoginUserData.SecurityManagement == CommonDefine.SecurityRankList[(int)CommonDefine.SecurityRankPos.SpecialAuthority].Key)
+                {
+                    // 特別権限
+                    userInfo.m_Type = CommonDefine.SecurityRankPos.SpecialAuthority;
+                }
+                // 統括者権限
+                else if (CommonMotions.LoginUserData.SecurityManagement == CommonDefine.SecurityRankList[(int)CommonDefine.SecurityRankPos.FreeAuthority].Key)
+                {
+                    // 統括者権限
+                    userInfo.m_Type = CommonDefine.SecurityRankPos.FreeAuthority;
+
+                }
+                // 所属長権限
+                else if (CommonMotions.LoginUserData.SecurityManagement == CommonDefine.SecurityRankList[(int)CommonDefine.SecurityRankPos.LimitedAuthority].Key)
+                {
+                    // 所属長権限
+                    userInfo.m_Type = CommonDefine.SecurityRankPos.LimitedAuthority;
+
+                }
+                // 一般権限
+                else if (CommonMotions.LoginUserData.SecurityManagement == CommonDefine.SecurityRankList[(int)CommonDefine.SecurityRankPos.NormalAuthority].Key)
+                {
+                    // 一般権限
+                    userInfo.m_Type = CommonDefine.SecurityRankPos.NormalAuthority;
+                }
+
+                // 保護区分範囲
+                userInfo.m_SecRange = (SecRangeType)CommonMotions.LoginUserSecurity.SecRange;
+                // 総務業務フラグ
+                userInfo.m_GeneralAffairsFlg = CommonMotions.LoginUserSecurity.GeneralAffairs;
+            }
+            catch (Exception ex)
+            {
+                logger.ErrorFormat("システムエラー：{0}：{1}", ex.Message);
+            }
+        }
         #endregion
+
+        #endregion
     }
 }
Index: branches/src/ProcessManagement/ProcessManagement/Common/Process/ClsSystemOnceExecute.cs
===================================================================
--- branches/src/ProcessManagement/ProcessManagement/Common/Process/ClsSystemOnceExecute.cs	(revision 59)
+++ branches/src/ProcessManagement/ProcessManagement/Common/Process/ClsSystemOnceExecute.cs	(revision 60)
@@ -86,6 +86,9 @@
                 if (!(ProcessFlg = UpDateTargetDate(DateTime.Now))) return;
 
                 // ----- データチェック
+                // 資材返却期限のチェックを行う
+                if (!(ProcessFlg = MaterialLimitCheck(m_lastsessionDate))) return;
+
                 // 日付の期限チェックを行う
                 if(!(ProcessFlg = SubmittedDateCheck(m_lastsessionDate))) return;
 
@@ -248,6 +251,243 @@
         }
         #endregion
 
+        #region 資材返却ステータス取得処理
+        /// <summary>
+        /// 資材返却ステータス取得処理
+        /// </summary>
+        /// <returns></returns>
+        public void MaterualStatusCheck(MaterialRecordInfo checkRec, DateTime CriteriaDate, ref TermMaster TermRec)
+        {
+            try
+            {
+                // 対象日付を設定
+                DateTime Target = checkRec.RepayPlanDate;
+
+                TermMaster TermMasterData = new TermMaster();
+
+                // 当日のチェック 今日を基準に対象日と比較する
+                if (Target.Date == CriteriaDate.Date)
+                {
+                    TermMasterData.CheckSchdule = (int)CommonDefine.TermDateCheckTiming.CheckSchdule1;
+                    TermMasterData.TermDays     = CommonDefine.MaterualStatusCheckList[0].Value;
+                    TermMasterData.SendTitle    = CommonDefine.MaterualLimitItem[0, 0];
+                    TermMasterData.SendMessage  = CommonDefine.MaterualLimitItem[0, 1];
+                    TermMasterData.BackColor    = CommonDefine.MaterualLimitItem[0, 2];
+                    TermMasterData.ForeColor    = CommonDefine.MaterualLimitItem[0, 3];
+                }
+                // 後日以降継続のチェック 今日を基準に経過日（1日）が過ぎているか比較する
+                if (Target.AddDays(1).Date <= CriteriaDate.Date)
+                {
+                    TermMasterData.CheckSchdule = (int)CommonDefine.TermDateCheckTiming.CheckSchdule3;
+                    TermMasterData.TermDays     = CommonDefine.MaterualStatusCheckList[1].Value;
+                    TermMasterData.SendTitle    = CommonDefine.MaterualLimitItem[1, 0];
+                    TermMasterData.SendMessage  = CommonDefine.MaterualLimitItem[1, 1];
+                    TermMasterData.BackColor    = CommonDefine.MaterualLimitItem[1, 2];
+                    TermMasterData.ForeColor    = CommonDefine.MaterualLimitItem[1, 3];
+                }
+
+                TermRec = TermMasterData;
+            }
+            catch (Exception ex)
+            {
+                logger.ErrorFormat("システムエラー：{0}", ex.Message);
+            }
+        }
+        #endregion
+
+        #region 秘書からのメッセージ作成
+        /// <summary>
+        /// 秘書からのメッセージ作成
+        /// </summary>
+        private bool MakeSecretaryMassageData(IOMessageBoardData mbdDB,
+                                        IOMessageBoardTerget mbtDB,
+                                        IOConstructionBaseInfoDetail cbiDB,
+                                        MaterialRecordInfo wrkRec, TermMaster CheckRec, DateTime CriteriaDate)
+        {
+            try
+            {
+                // 工事名称・担当者取得
+                string strSQL = "SELECT A.DETAILSTRING, C.PERSONCODE CCODE, C.PERSONNAME CNAME";
+                strSQL += " FROM ConstructionBaseInfo P";
+                strSQL += string.Format(" LEFT JOIN PERSONINCHARGEMASTER C ON C.PERSONCODE = {0}", wrkRec.PersonCode);
+                strSQL += " , CONSTRUCTIONBASEINFODETAIL A";
+                strSQL += string.Format(" WHERE P.CONSTRUCTIONCODE = {0}", wrkRec.ConstructionCode);
+                strSQL += string.Format(" AND A.CONSTRUCTIONCODE = P.CONSTRUCTIONCODE AND A.DETAILNO = {0}", (int)ConstructionBaseInfoDetail.DetailDataNo.ConstructionName);
+                ArrayList arList = new ArrayList();
+                if (!cbiDB.ExecuteReader(strSQL, ref arList)) return false;
+
+                string DetailString = string.Empty;
+                int SalesPersonCode = 0;
+                string SalesPersonName = string.Empty;
+                int ConstructionPersonCode = 0;
+                string ConstructionPersonName = string.Empty;
+                foreach (object[] onjwrk in arList)
+                {
+                    DetailString = CommonMotions.cnvString(onjwrk[0]);
+                    ConstructionPersonCode = CommonMotions.cnvInt(onjwrk[1]);
+                    ConstructionPersonName = CommonMotions.cnvString(onjwrk[2]);
+                    break;
+                }
+
+                // 新規メッセージ作成
+                MessageBoardData WriteData = new MessageBoardData();
+                List<MessageBoardTerget> WriteDetail = new List<MessageBoardTerget>();
+
+                // 掲示板メッセージ
+                WriteData.FromCode = CommonDefine.s_MsgBoardSystemCode;	                                    // 書込み者コード
+                WriteData.FromName = string.Format(CommonDefine.s_MsgBoardSystemNameFormat, "秘書");        // 書込み者名
+
+                WriteData.MessageTitle = CheckRec.SendTitle;                                                // 伝言タイトル
+
+                // リンク情報
+                WriteData.LinkType = (int)CommonDefine.LinkType.ConstructionInfo;
+                WriteData.LinkMessage = string.Format("工事番号：{0} 工事名称：{1}"
+                                                                            , CommonMotions.cnvStringCodeFromInt(wrkRec.ConstructionCode, "-", 8)
+                                                                            , DetailString);
+                WriteData.LinkCode = string.Format("{0}", CommonMotions.cnvStringCodeFromInt(wrkRec.ConstructionCode, "-", 8));
+
+                // 伝言内容
+                WriteData.MessageContent = CheckRec.SendMessage;
+
+
+                //WriteData.WritingDate = DateTime.Now;	                                                    // 書込み日付
+                WriteData.WritingDate = CriteriaDate.Date + DateTime.Now.TimeOfDay;	                        // 書込み日付
+                WriteData.PersonCode = CommonDefine.s_MsgBoardSystemCode;	                                // 書込み担当者コード
+                WriteData.ShareFlag = 1;	                                                                // 管理者対象フラグ
+
+                WriteData.BackColor = CheckRec.BackColor;                                                   // 背景色セット
+                WriteData.MessageColor = CheckRec.ForeColor;                                                // 背景色セット
+
+                // 掲示板対象者テーブル
+                MessageBoardTerget DetailTbl = new MessageBoardTerget();
+                DetailTbl.ToCode = ConstructionPersonCode;                                                  // 対象者コード
+                DetailTbl.ToName = ConstructionPersonName;	                                                // 対象者
+                WriteDetail.Add(DetailTbl);
+
+                // メッセージフラグを自動に設定する
+                WriteData.MessageFlag = (int)CommonDefine.MessageFlg.Secretary;
+
+                // 掲示板へメッセージを載せる
+                if (!ClsMessageBoradAccess.CreateMessage(mbdDB, mbtDB, WriteData, WriteDetail)) return false;
+
+                return true;
+            }
+            catch (Exception ex)
+            {
+                logger.ErrorFormat("システムエラー：{0}", ex.Message);
+                return false;
+            }
+        }
+        #endregion
+
+        #region 資材返却期限チェック処理
+        /// <summary>
+        /// チェック処理
+        /// </summary>
+        /// <returns></returns>
+        public bool MaterialLimitCheck(DateTime StartDate)
+        {
+            IOConstructionBaseInfo cbiDB = new IOConstructionBaseInfo();
+            IOConstructionBaseInfoDetail cbiDDB = new IOConstructionBaseInfoDetail();
+            IOMessageBoardData mbdDB = new IOMessageBoardData();
+            IOMessageBoardTerget mbtDB = new IOMessageBoardTerget();
+
+            string strSQL = "SELECT";
+            strSQL += " t1.MaterialItemCode";
+            strSQL += ", t1.ProcessDate";
+            strSQL += ", t1.SeqNo";
+            strSQL += ", t1.RecKind";
+            strSQL += ", t1.ConstructionCode";
+            strSQL += ", t1.PersonCode";
+            strSQL += ", t1.MaterialCount";
+            strSQL += ", MAX(t1.REPAYPLANDATE) AS RepayPlanDate";
+            strSQL += ", t1.CommentText";
+            strSQL += ", t1.EntryDate";
+            strSQL += ", t1.UpdateDate";
+            strSQL += " FROM";
+            strSQL += " MATERIALRECORDINFO AS t1";
+            strSQL += " INNER JOIN CONSTRUCTIONMATERIALINFO AS t2";
+            strSQL += " ON t1.CONSTRUCTIONCODE = t2.CONSTRUCTIONCODE";
+            strSQL += " AND t1.MATERIALITEMCODE = t2.MATERIALITEMCODE";
+            strSQL += " AND t2.COMPLETEFLG = 0";
+            strSQL += " WHERE";
+            strSQL += " t1.CONSTRUCTIONCODE > 0";
+            strSQL += " AND t1.CONSTRUCTIONCODE IS NOT NULL";
+            strSQL += " AND t1.RECKIND = 0";
+            strSQL += " AND t1.REPAYPLANDATE <= DATE_FORMAT(NOW(), '%Y/%m/%d')";
+            strSQL += " GROUP BY";
+            strSQL += " t1.CONSTRUCTIONCODE";
+            strSQL += ", t1.PERSONCODE";
+            strSQL += " ORDER BY";
+            strSQL += " t1.CONSTRUCTIONCODE";
+            strSQL += " , t1.REPAYPLANDATE";
+
+            try
+            {
+                cbiDB.connect(); cbiDB.beginTran();
+                cbiDDB.connect(); cbiDDB.beginTran();
+                mbdDB.connect(); mbdDB.beginTran();
+                mbtDB.connect(); mbtDB.beginTran();
+
+                bool procflg = true;
+
+                // 資材履歴情報の返却未完了の貸出データを取得する
+                IOMaterialRecordInfo mrDB = new IOMaterialRecordInfo();
+                ArrayList mrData = new ArrayList();
+                List<MaterialRecordInfo> data = new List<MaterialRecordInfo>();
+
+                if (mrDB.ExecuteReader(strSQL, ref mrData))
+                {
+                    foreach (object[] objwrk in mrData)
+                    {
+                        MaterialRecordInfo wrkRec = new MaterialRecordInfo();
+                        mrDB.Reader2Struct(objwrk, ref wrkRec);
+                        // チェック
+                        TermMaster term = new TermMaster();
+                        MaterualStatusCheck(wrkRec, StartDate, ref term);
+
+                        // メッセージ作成 掲示板にメッセージを載せる処理
+                        if (!MakeSecretaryMassageData(mbdDB, mbtDB, cbiDDB, wrkRec, term, StartDate))
+                        {
+                            procflg = false;
+                            break;
+                        }
+                    }
+
+                    if (procflg)
+                    {
+                        cbiDB.commit();
+                        cbiDDB.commit();
+                        mbdDB.commit();
+                        mbtDB.commit();
+                    }
+                    else
+                    {
+                        cbiDB.rollback();
+                        cbiDDB.rollback();
+                        mbdDB.rollback();
+                        mbtDB.rollback();
+                    }
+
+                    return procflg;
+                }
+            }
+            catch (Exception ex)
+            {
+                logger.ErrorFormat("システムエラー：{0}", ex.Message);
+                return false;
+            }
+            finally
+            {
+                cbiDB.close(); cbiDB = null;
+                cbiDDB.close(); cbiDDB = null;
+                mbdDB.close(); mbdDB = null;
+                mbtDB.close(); mbtDB = null;
+            }
+            return true;
+        }
+        #endregion
+
         #region 工事情報チェック処理
         /// <summary>
         /// 日付の期限チェックを行う
@@ -623,7 +863,7 @@
                 strSQL += string.Format(" < STR_TO_DATE('{0}','%Y/%m/%d')", DateTime.Now.ToShortDateString());
                 strSQL += string.Format(" AND CONSTRUCTIONSTATUSFLG IN({0}, {1})", iCode2, iCode3);
                 strSQL += string.Format(" AND ESTIMATETYPE IN ({0}, {1}))", (int)CommonDefine.BaseInfoEstimateType.Normal, (int)CommonDefine.BaseInfoEstimateType.GetBudget);
-                strSQL += " ) AS TMP"; // MySql対応（Updateの副問合せ対応）
+                strSQL += " ) AS TMP )"; // MySql対応（Updateの副問合せ対応）
                 if (!BaseDB.ExecuteNonQuery(strSQL))
                 {
                     logger.ErrorFormat("工事基本情報更新エラー　非受注案件移行処理失敗：{0}：{1}", CommonMotions.GetMethodName(), strSQL);
@@ -701,7 +941,7 @@
                 string strSQL = "SELECT A.PERSONCODE, A.MONTHLYSALARY, A.YEARSALARY, A.STARTDATE, C.MONTHLYSALARY, C.YEARSALARY";
                 strSQL += " FROM PERSONSALARYMASTER A,";
                 strSQL += " (SELECT PERSONCODE, MAX(STARTDATE) sDate FROM PERSONSALARYMASTER";
-                strSQL += string.Format(" WHERE DATE(STARTDATE) <= STR_TO_DATE('{0}') GROUP BY PERSONCODE) B,", DateTime.Today.ToShortDateString());
+                strSQL += string.Format(" WHERE DATE(STARTDATE) <= STR_TO_DATE('{0}', '%Y/%m/%d') GROUP BY PERSONCODE) B,", DateTime.Today.ToShortDateString());
                 strSQL += " PERSONINCHARGEMASTER C";
                 strSQL += "  WHERE A.PERSONCODE = B.PERSONCODE AND A.STARTDATE = B.sDate";
                 strSQL += " AND C.PERSONCODE = A.PERSONCODE";
Index: branches/src/ProcessManagement/ProcessManagement/DB/IOAccess/IODepositData.cs
===================================================================
--- branches/src/ProcessManagement/ProcessManagement/DB/IOAccess/IODepositData.cs	(revision 59)
+++ branches/src/ProcessManagement/ProcessManagement/DB/IOAccess/IODepositData.cs	(revision 60)
@@ -38,7 +38,9 @@
             OrderersCode,
             TargetDate,
             SeqNo,
+            BusinessPeriod,
             DepositDate,
+            DepositAmount,
             DepositAmountCash,
             DepositAmountBill,
             EntryDate,
@@ -73,7 +75,9 @@
             strcmd += ",OrderersCode";
             strcmd += ",TargetDate";
             strcmd += ",SeqNo";
+            strcmd += ",BusinessPeriod";
             strcmd += ",DATE_FORMAT(DepositDate, '%Y/%m/%d')";
+            strcmd += ",DepositAmount";
             strcmd += ",DepositAmountCash";
             strcmd += ",DepositAmountBill";
             strcmd += ",DATE_FORMAT(EntryDate, '%Y/%m/%d %H:%i:%s')";
@@ -209,7 +213,9 @@
                     strcmd += string.Format(", {0}", data.OrderersCode.ToString());
                     strcmd += string.Format(", {0}", data.TargetDate.ToString());
                     strcmd += string.Format(", {0}", data.SeqNo.ToString());
+                    strcmd += string.Format(", {0}", data.BusinessPeriod.ToString());
                     strcmd += string.Format(", DATE_FORMAT('{0}','%Y/%m/%d')", data.DepositDate.ToShortDateString());
+                    strcmd += string.Format(", {0}", data.DepositAmount.ToString());
                     strcmd += string.Format(", {0}", data.DepositAmountCash.ToString());
                     strcmd += string.Format(", {0}", data.DepositAmountBill.ToString());
                     strcmd += ", DATE_FORMAT(DATE_FORMAT(NOW(),'%Y/%m/%d %H:%i:%s'),'%Y/%m/%d %H:%i:%s')";
@@ -249,7 +255,9 @@
                 strcmd += string.Format(",OrderersCode = {0}", data.OrderersCode.ToString());
                 strcmd += string.Format(",TargetDate = {0}", data.TargetDate.ToString());
                 strcmd += string.Format(",SeqNo = {0}", data.SeqNo.ToString());
+                strcmd += string.Format(",BusinessPeriod = {0}", data.BusinessPeriod.ToString());
                 strcmd += string.Format(",DepositDate = DATE_FORMAT('{0}','%Y%m%d')", data.DepositDate.ToString());
+                strcmd += string.Format(",DepositAmount = {0}", data.DepositAmount.ToString());
                 strcmd += string.Format(",DepositAmountCash = {0}", data.DepositAmountCash.ToString());
                 strcmd += string.Format(",DepositAmountBill = {0}", data.DepositAmountBill.ToString());
                 strcmd += ", UpdateDate = DATE_FORMAT(DATE_FORMAT(NOW(),'%Y/%m/%d %H:%i:%s'),'%Y/%m/%d %H:%i:%s')";
@@ -309,7 +317,9 @@
                 wrk.OrderersCode = int.Parse(objwrk[(int)ColumnName.OrderersCode].ToString());
                 wrk.TargetDate = objwrk[(int)ColumnName.TargetDate].ToString();
                 wrk.SeqNo = int.Parse(objwrk[(int)ColumnName.SeqNo].ToString());
+                wrk.BusinessPeriod = int.Parse(objwrk[(int)ColumnName.BusinessPeriod].ToString());
                 wrk.DepositDate = DateTime.Parse(objwrk[(int)ColumnName.DepositDate].ToString());
+                wrk.DepositAmount = int.Parse(objwrk[(int)ColumnName.DepositAmount].ToString());
                 wrk.DepositAmountCash = int.Parse(objwrk[(int)ColumnName.DepositAmountCash].ToString());
                 wrk.DepositAmountBill = int.Parse(objwrk[(int)ColumnName.DepositAmountBill].ToString());
 
Index: branches/src/ProcessManagement/ProcessManagement/DB/IOAccess/IODepositDataDetail.cs
===================================================================
--- branches/src/ProcessManagement/ProcessManagement/DB/IOAccess/IODepositDataDetail.cs	(revision 59)
+++ branches/src/ProcessManagement/ProcessManagement/DB/IOAccess/IODepositDataDetail.cs	(revision 60)
@@ -87,7 +87,7 @@
                 strcmd = "SELECT";
                 strcmd += " OrderersDivision";
                 strcmd += " ,OrderersCode";
-                strcmd += " ,DATE_FORMAT(TargetDate, '%Y/%m/%d')";
+                strcmd += " ,CAST(TargetDate As Char)";
                 strcmd += " ,SeqNo";
                 strcmd += " ,LineCount";
                 strcmd += " ,RequestNo";
Index: branches/src/ProcessManagement/ProcessManagement/DB/IOAccess/IOInvoiceData.cs
===================================================================
--- branches/src/ProcessManagement/ProcessManagement/DB/IOAccess/IOInvoiceData.cs	(nonexistent)
+++ branches/src/ProcessManagement/ProcessManagement/DB/IOAccess/IOInvoiceData.cs	(revision 60)
@@ -0,0 +1,560 @@
+﻿using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Text;
+using System.Threading.Tasks;
+using System.Collections;
+
+using log4net;
+using MySql.Data.MySqlClient;
+
+using ProcessManagement.DB.MySql;
+using ProcessManagement.DB.Core;
+using ProcessManagement.DataModel;
+
+using ProcessManagement.Common;
+
+namespace ProcessManagement.DB.IOAccess
+{
+    /// <summary>
+    /// 請求書データアクセスクラス
+    /// </summary>
+    public class IOInvoiceData : MySqlProcess
+    {
+        #region 定義部
+        /// <summary>
+        /// log4netログを使用する
+        /// </summary>
+        private static readonly ILog logger = LogManager.GetLogger(System.Reflection.MethodBase.GetCurrentMethod().DeclaringType);
+        #endregion
+
+        #region 定数
+        /// <summary>
+        /// 請求データフィールド並び
+        /// </summary>
+        public enum NameColumn
+        {
+            InvoiceNo = 0,
+            OrderersDivision,
+            OrderersCode,
+            RequestMonth,
+            SeqNo,
+            CretateDate,
+            RequestDate,
+            RequestName,
+            TotalAmount,
+            TaxAmount,
+            Comment1,
+            Comment2,
+            Comment3,
+            Comment4,
+            Comment5,
+            CompleteFlg,
+            ENTRY_DATE,
+            UPDATE_DATE,
+        }
+        #endregion
+
+        #region コンストラクタ
+        /// <summary>
+        /// コンストラクタ
+        /// </summary>
+        /// <param name="connectionString"></param>
+        public IOInvoiceData()
+            : base(DBCommon.Instance.DBConnectString)
+        {
+        }
+
+        #endregion
+
+
+        #region 請求書データ検索(１件取得)
+        /// <summary>
+        /// 請求書データ検索(複数件取得)
+        /// </summary>
+        /// <param name="AddSQLString"></param>
+        /// <param name="data"></param>
+        /// <param name="bConnect"></param>
+        /// <returns></returns>
+        public bool SelectAction(string AddSQLString, ref InvoiceData data, bool bConnect = true)
+        {
+            //Oracle インターフェース
+            string strcmd = "";
+            ArrayList arData = new ArrayList();
+
+            try
+            {
+                // SQL作成（oracleのDateTime型が変換できないのでCharに変換しておく）
+                strcmd = CreateSelectSQL();
+                strcmd += AddSQLString;
+
+                // SQL実行
+                if (!ExecuteReader(strcmd, ref arData, bConnect)) return false;
+
+                // データセット
+                foreach (object[] objwrk in arData)
+                {
+                    Reader2Struct(objwrk, ref data);
+                    break;
+                }
+
+                return true;
+            }
+            catch (Exception ex)
+            {
+                logger.ErrorFormat("システムエラー：：{0}：{1}：{2}", CommonMotions.GetMethodName(2), ex.Message, strcmd);
+                return false;
+            }
+        }
+        #endregion
+        #region 請求書データ検索(複数件取得)
+        /// <summary>
+        /// 請求書データ検索(複数件取得)
+        /// </summary>
+        /// <param name="AddSQLString"></param>
+        /// <param name="data"></param>
+        /// <param name="bConnect"></param>
+        /// <returns></returns>
+        public bool SelectAction(string AddSQLString, ref List<InvoiceData> data, bool bConnect = true)
+        {
+            //Oracle インターフェース
+            string strcmd = "";
+            ArrayList arData = new ArrayList();
+
+            try
+            {
+                // SQL作成（oracleのDateTime型が変換できないのでCharに変換しておく）
+                strcmd = CreateSelectSQL();
+                strcmd += AddSQLString;
+
+                // SQL実行
+                if (!ExecuteReader(strcmd, ref arData, bConnect)) return false;
+
+                // データセット
+                foreach (object[] objwrk in arData)
+                {
+                    InvoiceData work = new InvoiceData();
+                    Reader2Struct(objwrk, ref work);
+                    data.Add(work);
+                }
+
+                return true;
+            }
+            catch (Exception ex)
+            {
+                logger.ErrorFormat("システムエラー：：{0}：{1}：{2}", CommonMotions.GetMethodName(2), ex.Message, strcmd);
+                return false;
+            }
+        }
+        #endregion
+
+        #region 請求書データ複数追加
+        /// <summary>
+        /// 請求書データ複数追加
+        /// </summary>
+        /// <param name="data">請求データ</param>
+        /// <returns>true：成功 false：失敗</returns>
+        public bool InsertAction(List<InvoiceData> data, bool bConnect = true)
+        {
+            string strcmd = "";
+            try
+            {
+
+                foreach (InvoiceData work in data)
+                {
+                    if (!InsertAction(work, bConnect)) return false;
+                }
+                return true;
+            }
+            catch (Exception ex)
+            {
+                logger.ErrorFormat("システムエラー：：{0}：{1}：{2}", CommonMotions.GetMethodName(2), ex.Message, strcmd);
+                return false;
+            }
+        }
+        #endregion
+
+        #region 請求書データ１件追加
+        /// <summary>
+        /// 請求書データ１件追加
+        /// </summary>
+        /// <param name="data"></param>
+        /// <param name="bConnect"></param>
+        /// <returns></returns>
+        public bool InsertAction(InvoiceData data, bool bConnect = true)
+        {
+            string strcmd = "";
+            try
+            {
+
+                strcmd = "INSERT INTO InvoiceData";
+                strcmd += " VALUES (";
+
+                strcmd += string.Format(" {0}", data.InvoiceNo.ToString());
+                strcmd += string.Format(", {0}", data.OrderersDivision.ToString());
+                strcmd += string.Format(", {0}", data.OrderersCode.ToString());
+                strcmd += string.Format(", {0}", data.RequestMonth.ToString());
+                strcmd += string.Format(", {0}", data.SeqNo.ToString());
+                strcmd += string.Format(", STR_TO_DATE('{0}','%Y/%m/%d')", data.CretateDate.ToShortDateString());
+                strcmd += string.Format(", STR_TO_DATE('{0}','%Y/%m/%d')", data.RequestDate.ToShortDateString());
+                strcmd += string.Format(", '{0}'", data.RequestName.ToString());
+                strcmd += string.Format(", {0}", data.TotalAmount.ToString());    
+                strcmd += string.Format(", {0}", data.TaxAmount.ToString());
+                strcmd += string.Format(", '{0}'", data.Comment1.ToString());
+                strcmd += string.Format(", '{0}'", data.Comment2.ToString());
+                strcmd += string.Format(", '{0}'", data.Comment3.ToString());
+                strcmd += string.Format(", '{0}'", data.Comment4.ToString());
+                strcmd += string.Format(", '{0}'", data.Comment5.ToString());
+                strcmd += string.Format(", {0}", data.CompleteFlg.ToString());
+                strcmd += ", DATE_FORMAT(DATE_FORMAT(NOW(),'%Y/%m/%d %H:%i:%s'),'%Y/%m/%d %H:%i:%s')";
+                strcmd += ", DATE_FORMAT(DATE_FORMAT(NOW(),'%Y/%m/%d %H:%i:%s'),'%Y/%m/%d %H:%i:%s')";
+                strcmd = strcmd + ")";
+
+                if (!ExecuteNonQuery(strcmd, bConnect)) return false;
+
+                return true;
+            }
+            catch (Exception ex)
+            {
+                logger.ErrorFormat("システムエラー：：{0}：{1}：{2}", CommonMotions.GetMethodName(2), ex.Message, strcmd);
+                return false;
+            }
+        }
+        #endregion
+
+        #region 請求書データ更新
+        /// <summary>
+        /// 請求データ更新
+        /// </summary>
+        /// <param name="AddSQLString">更新条件SQL文字列</param>
+        /// <param name="data">請求書データ</param>
+        /// <returns>true：成功 false：失敗</returns>
+        public bool UpdateAction(string AddSQLString, InvoiceData data, bool bConnect = true)
+        {
+            string strcmd = "";
+            try
+            {
+
+                strcmd = "UPDATE InvoiceData";
+
+                strcmd += " SET";
+
+                strcmd += string.Format(" OrderersDivision = {0}", data.OrderersDivision.ToString());
+                strcmd += string.Format(", OrderersCode = {0}", data.OrderersCode.ToString());
+                strcmd += string.Format(", RequestMonth = {0}", data.RequestMonth.ToString());
+                strcmd += string.Format(", SeqNo = {0}", data.SeqNo.ToString());
+                strcmd += string.Format(", CretateDate = STR_TO_DATE('{0}','%Y/%m/%d')", data.CretateDate.ToShortDateString());
+                strcmd += string.Format(", RequestDate = STR_TO_DATE('{0}','%Y/%m/%d')", data.RequestDate.ToShortDateString());
+                strcmd += string.Format(", RequestName = '{0}'", data.RequestName.ToString());
+                strcmd += string.Format(", TotalAmount = {0}", data.TotalAmount.ToString());
+                strcmd += string.Format(", TaxAmount = {0}", data.TaxAmount.ToString());
+                strcmd += string.Format(", Comment1 = '{0}'", data.Comment1.ToString());
+                strcmd += string.Format(", Comment2 = '{0}'", data.Comment2.ToString());
+                strcmd += string.Format(", Comment3 = '{0}'", data.Comment3.ToString());
+                strcmd += string.Format(", Comment4 = '{0}'", data.Comment4.ToString());
+                strcmd += string.Format(", Comment5 = '{0}'", data.Comment5.ToString());
+                strcmd += string.Format(", CompleteFlg = {0}", data.CompleteFlg.ToString());
+                strcmd += ", UpdateDate = DATE_FORMAT(DATE_FORMAT(NOW(),'%Y/%m/%d %H:%i:%s'),'%Y/%m/%d %H:%i:%s')";
+
+                strcmd += AddSQLString;
+
+                if (!ExecuteNonQuery(strcmd, bConnect)) return false;
+
+                return true;
+            }
+            catch (Exception ex)
+            {
+                logger.ErrorFormat("システムエラー：：{0}：{1}：{2}", CommonMotions.GetMethodName(2), ex.Message, strcmd);
+                return false;
+            }
+        }
+        #endregion
+
+        #region 請求書データ削除
+        /// <summary>
+        /// 請求データ削除
+        /// </summary>
+        /// <param name="AddSQLString">削除条件SQL文字列</param>
+        /// <param name="bConnect"></param>
+        /// <returns></returns>
+        public bool DeleteAction(string AddSQLString, bool bConnect = true)
+        {
+            //Oracle インターフェース
+            string strcmd = "";
+            try
+            {
+                strcmd = string.Format("{0}{1}", "DELETE FROM InvoiceData", AddSQLString);
+
+                if (!ExecuteNonQuery(strcmd, bConnect)) return false;
+
+                return true;
+            }
+            catch (Exception ex)
+            {
+                logger.ErrorFormat("システムエラー：：{0}：{1}：{2}", CommonMotions.GetMethodName(2), ex.Message, strcmd);
+                return false;
+            }
+        }
+        #endregion
+
+        #region OracleDataReaderより構造体へセットする
+        /// <summary>
+        /// OracleDataReaderより構造体へセットする
+        /// </summary>
+        /// <param name="reader">OracleDataReader</param>
+        /// <param name="wrk">構造体</param>
+        public void Reader2Struct(object[] objwrk, ref InvoiceData wrk)
+        {
+            try
+            {
+                // データ取得
+                wrk.InvoiceNo = int.Parse(objwrk[(int)NameColumn.InvoiceNo].ToString());
+                
+                wrk.OrderersDivision = int.Parse(objwrk[(int)NameColumn.OrderersDivision].ToString());
+                wrk.OrderersCode = int.Parse(objwrk[(int)NameColumn.OrderersCode].ToString());
+                wrk.RequestMonth = int.Parse(objwrk[(int)NameColumn.RequestMonth].ToString());
+                wrk.SeqNo = int.Parse(objwrk[(int)NameColumn.SeqNo].ToString());
+
+                wrk.CretateDate = DateTime.Parse(objwrk[(int)NameColumn.CretateDate].ToString());
+                wrk.RequestDate = DateTime.Parse(objwrk[(int)NameColumn.RequestDate].ToString());
+
+                wrk.RequestName = objwrk[(int)NameColumn.RequestName].ToString();
+
+                wrk.TotalAmount = int.Parse(objwrk[(int)NameColumn.TotalAmount].ToString());
+                wrk.TaxAmount = int.Parse(objwrk[(int)NameColumn.TaxAmount].ToString());
+
+                wrk.Comment1 = objwrk[(int)NameColumn.Comment1].ToString();
+                wrk.Comment2 = objwrk[(int)NameColumn.Comment2].ToString();
+                wrk.Comment3 = objwrk[(int)NameColumn.Comment3].ToString();
+                wrk.Comment4 = objwrk[(int)NameColumn.Comment4].ToString();
+                wrk.Comment5 = objwrk[(int)NameColumn.Comment5].ToString();
+
+                wrk.CompleteFlg = int.Parse(objwrk[(int)NameColumn.CompleteFlg].ToString());
+
+                wrk.EntryDate = DateTime.Parse(objwrk[(int)NameColumn.ENTRY_DATE].ToString());
+                wrk.UpdateDate = DateTime.Parse(objwrk[(int)NameColumn.UPDATE_DATE].ToString());
+            }
+            catch (MySqlException myex)
+            {
+                logger.ErrorFormat("ＭｙＳＱＬエラー：{0}：{1}", CommonMotions.GetMethodName(2), myex.Message);
+            }
+            catch (Exception ex)
+            {
+                logger.ErrorFormat("システムエラー：：{0}：{1}：{2}", CommonMotions.GetMethodName(), ex.Message);
+            }
+        }
+        #endregion
+
+        #region 構造体クリア
+        /// <summary>
+        /// 構造体クリア
+        /// </summary>
+        /// <param name="wrk"></param>
+        public void ClearStruct(ref InvoiceData wrk)
+        {
+            try
+            {
+                // データ取得
+                wrk.InvoiceNo = 0;
+                
+                wrk.OrderersDivision = 0;
+                wrk.OrderersCode = 0;
+                wrk.RequestMonth = 0;
+                wrk.SeqNo = 0;
+                
+                wrk.CretateDate = DateTime.MinValue;
+                wrk.RequestDate = DateTime.MinValue;
+                
+                wrk.RequestName = "";
+                
+                wrk.TotalAmount = 0;
+                wrk.TaxAmount = 0;
+                
+                wrk.Comment1 = "";
+                wrk.Comment2 = "";
+                wrk.Comment3 = "";
+                wrk.Comment4 = "";
+                wrk.Comment5 = "";
+
+                wrk.CompleteFlg = 0;
+
+                wrk.EntryDate = DateTime.Now;
+                wrk.UpdateDate = DateTime.Now;
+            }
+            catch (MySqlException myex)
+            {
+                logger.ErrorFormat("ＭｙＳＱＬエラー：{0}：{1}", CommonMotions.GetMethodName(2), myex.Message);
+            }
+            catch (Exception ex)
+            {
+                logger.ErrorFormat("システムエラー：：{0}：{1}：{2}", CommonMotions.GetMethodName(), ex.Message);
+            }
+        }
+        #endregion
+
+        #region 主キー検索の文字列を返す
+        /// <summary>
+        /// 主キー検索の文字列を返す
+        /// </summary>
+        /// <param name="InvoiceNo">請求書No</param>
+        /// <returns>Where文字列</returns>
+        public string CreatePrimarykeyString(int InvoiceNo)
+        {
+            string strWork = string.Empty;
+            try
+            {
+                strWork = string.Format(" Where InvoiceNo = {0}", InvoiceNo.ToString());
+            }
+            catch (Exception ex)
+            {
+                logger.ErrorFormat("システムエラー：{0}：{1}：{2}", CommonMotions.GetMethodName(2), ex.Message, strWork);
+            }
+
+            return strWork;
+        }
+        #endregion
+
+        #region サブキー検索の文字列を返す
+        /// <summary>
+        /// サブキー検索の文字列を返す
+        /// </summary>
+        /// <param name="OrderersDivision">発注者区分</param>
+        /// <param name="OrderersCode">発注者コード</param>
+        /// <param name="RequestMonth">請求月</param>
+        /// <param name="SeqNo">連番</param>
+        /// <returns>Where文字列</returns>
+        public string CreateSubkeyString(int OrderersDivision, int OrderersCode, int RequestMonth = -1, int SeqNo = -1 )
+        {
+            string strWork = string.Empty;
+            try
+            {
+                strWork = string.Format(" Where OrderersDivision = {0} and OrderersCode = {1}", OrderersDivision.ToString(),OrderersCode.ToString() );
+                if( RequestMonth != -1 ){
+                    strWork += string.Format(" and RequestMonth = {0}", RequestMonth.ToString() ) ;
+                }
+                if( SeqNo != -1 ){
+                    strWork += string.Format(" and SeqNo = {0}", SeqNo.ToString() ) ;
+                }
+            }
+            catch (Exception ex)
+            {
+                logger.ErrorFormat("システムエラー：{0}：{1}：{2}", CommonMotions.GetMethodName(2), ex.Message, strWork);
+            }
+
+            return strWork;
+        }
+        #endregion
+
+        #region 請求書Noの採番
+        public int NumberingInvoiceNo(int RequestMonth, bool bConnect = true)
+        {
+            int ret = -1;
+
+            string sql = "";
+            ArrayList arData = new ArrayList();
+
+            try
+            {
+                sql = string.Format("SELECT IFNULL(MAX(InvoiceNo),0) FROM InvoiceData WHERE RequestMonth = {0}", RequestMonth);
+
+                // SQL実行
+                if (!ExecuteReader(sql, ref arData, bConnect)) return -1;
+
+                // データセット
+                foreach (object[] objwrk in arData)
+                {
+                    ret = int.Parse(objwrk[0].ToString());
+                    break;
+                }
+
+                if (ret > 0)
+                {
+                    ret++;
+                }
+                else
+                {
+                    ret = (RequestMonth * 1000) + 1;
+                }
+
+            }
+            catch (Exception ex)
+            {
+                logger.ErrorFormat("システムエラー：：{0}：{1}：{2}", CommonMotions.GetMethodName(2), ex.Message, sql);
+            }
+
+            return ret;
+
+        }
+        #endregion
+
+        #region 連番の採番
+        public int NumberingSeqNo(int nOrderersDivision, int nOrderersCode, int RequestMonth, bool bConnect = true)
+        {
+            int ret = -1;
+
+            string sql = "";
+            ArrayList arData = new ArrayList();
+
+            try
+            {
+                sql = "SELECT IFNULL(MAX(SeqNo),0) FROM InvoiceData" ;
+                sql += string.Format(" WHERE OrderersDivision = {0}", nOrderersDivision);
+                sql += string.Format(" AND OrderersCode = {0}", nOrderersCode);
+                sql += string.Format(" AND RequestMonth = {0}", RequestMonth);
+
+                // SQL実行
+                if (!ExecuteReader(sql, ref arData, bConnect)) return -1;
+
+                // データセット
+                foreach (object[] objwrk in arData)
+                {
+                    ret = int.Parse(objwrk[0].ToString());
+                    break;
+                }
+
+                ret++;
+
+            }
+            catch (Exception ex)
+            {
+                logger.ErrorFormat("システムエラー：：{0}：{1}：{2}", CommonMotions.GetMethodName(2), ex.Message, sql);
+            }
+
+            return ret;
+
+        }
+        #endregion
+
+        #region SELECT　SQL作成
+        private string CreateSelectSQL()
+        {
+            string strcmd = "SELECT";
+            strcmd += " InvoiceNo";
+            strcmd += " ,OrderersDivision";
+            strcmd += " ,OrderersCode";
+            strcmd += " ,RequestMonth";
+            strcmd += " ,SeqNo";
+            strcmd += " ,DATE_FORMAT(CretateDate, '%Y/%m/%d')";
+            strcmd += " ,DATE_FORMAT(RequestDate, '%Y/%m/%d')";
+            strcmd += " ,RequestName";
+            strcmd += " ,TotalAmount";
+            strcmd += " ,TaxAmount";
+            strcmd += " ,Comment1";
+            strcmd += " ,Comment2";
+            strcmd += " ,Comment3";
+            strcmd += " ,Comment4";
+            strcmd += " ,Comment5";
+            strcmd += " ,CompleteFlg";
+            strcmd += " ,DATE_FORMAT(EntryDate, '%Y/%m/%d %H:%i:%s')";
+            strcmd += " ,DATE_FORMAT(UpdateDate, '%Y/%m/%d %H:%i:%s')";
+            strcmd += " FROM InvoiceData";
+
+            return strcmd;
+        }
+        #endregion
+
+
+    }
+
+}
+
Index: branches/src/ProcessManagement/ProcessManagement/DB/IOAccess/IORequestData.cs
===================================================================
--- branches/src/ProcessManagement/ProcessManagement/DB/IOAccess/IORequestData.cs	(revision 59)
+++ branches/src/ProcessManagement/ProcessManagement/DB/IOAccess/IORequestData.cs	(revision 60)
@@ -35,15 +35,21 @@
         public enum NameColumn
         {
             RequestNo = 0,
-            ConstructionCode,
-            OrderersDivision,
-            OrderersCode,
-            AmountPaid,
-            PricePaid,
-            TaxPricePaid,
-            PriceBalance,
-            TaxBalance,
-            AmountBlance,
+            MainConstructionCode,
+            ConstructionName,
+            ContractAmount,
+            PaidAmount,
+            RequestAmount0,
+            RequestAmount1,
+            RequestAmount2,
+            RequestAmount3,
+            RequestAmount4,
+            RequestAmount5,
+            RequestAmount6,
+            UnclaimedAmount,
+            UnpaidAmount,
+            TaxAmount,
+            Note,
             ENTRY_DATE,
             UPDATE_DATE,
         }
@@ -80,15 +86,22 @@
                 // SQL作成（oracleのDateTime型が変換できないのでCharに変換しておく）
                 strcmd = "SELECT";
                 strcmd += " RequestNo";
-                strcmd += " ,ConstructionCode";
-                strcmd += " ,OrderersDivision";
-                strcmd += " ,OrderersCode";
-                strcmd += " ,AmountPaid";
-                strcmd += " ,PricePaid";
-                strcmd += " ,TaxPricePaid";
-                strcmd += " ,PriceBalance";
-                strcmd += " ,TaxBalance";
-                strcmd += " ,AmountBlance";
+                strcmd += " ,MainConstructionCode";
+
+                strcmd += " ,ConstructionName";
+                strcmd += " ,ContractAmount";
+                strcmd += " ,PaidAmount";
+                strcmd += " ,RequestAmount0";
+                strcmd += " ,RequestAmount1";
+                strcmd += " ,RequestAmount2";
+                strcmd += " ,RequestAmount3";
+                strcmd += " ,RequestAmount4";
+                strcmd += " ,RequestAmount5";
+                strcmd += " ,RequestAmount6";
+                strcmd += " ,UnclaimedAmount";
+                strcmd += " ,UnpaidAmount";
+                strcmd += " ,TaxAmount";
+                strcmd += " ,Note";
                 strcmd += " ,DATE_FORMAT(EntryDate, '%Y/%m/%d %H:%i:%s')";
                 strcmd += " ,DATE_FORMAT(UpdateDate, '%Y/%m/%d %H:%i:%s')";
                 strcmd += " FROM RequestData";
@@ -155,20 +168,27 @@
             {
 
                 strcmd = "INSERT INTO RequestData";
-
                 strcmd += " VALUES (";
 
                 strcmd += string.Format(" {0}", data.RequestNo.ToString());
-                strcmd += string.Format(", {0}", data.ConstructionCode.ToString());
-                strcmd += string.Format(", {0}", data.OrderersDivision.ToString());
-                strcmd += string.Format(", {0}", data.OrderersCode.ToString());
-                strcmd += string.Format(", {0}", data.AmountPaid.ToString());
-                strcmd += string.Format(", {0}", data.PricePaid.ToString());
-                strcmd += string.Format(", {0}", data.TaxPricePaid.ToString());
-                strcmd += string.Format(", {0}", data.PriceBalance.ToString());
-                strcmd += string.Format(", {0}", data.TaxBalance.ToString());
-                strcmd += string.Format(", {0}", data.AmountBlance.ToString());
 
+                strcmd += string.Format(", {0}", data.MainConstructionCode.ToString());
+                strcmd += string.Format(", '{0}'", data.ConstructionName.ToString());
+
+                strcmd += string.Format(", {0}", data.ContractAmount.ToString());
+                strcmd += string.Format(", {0}", data.PaidAmount.ToString());
+                strcmd += string.Format(", {0}", data.RequestAmount0.ToString());
+                strcmd += string.Format(", {0}", data.RequestAmount1.ToString());
+                strcmd += string.Format(", {0}", data.RequestAmount2.ToString());
+                strcmd += string.Format(", {0}", data.RequestAmount3.ToString());
+                strcmd += string.Format(", {0}", data.RequestAmount4.ToString());
+                strcmd += string.Format(", {0}", data.RequestAmount5.ToString());
+                strcmd += string.Format(", {0}", data.RequestAmount6.ToString());
+                strcmd += string.Format(", {0}", data.UnclaimedAmount.ToString());
+                strcmd += string.Format(", {0}", data.UnpaidAmount.ToString());
+                strcmd += string.Format(", {0}", data.TaxAmount.ToString());
+                strcmd += string.Format(", '{0}'", data.Note.ToString());
+
                 strcmd += ", DATE_FORMAT(DATE_FORMAT(NOW(),'%Y/%m/%d %H:%i:%s'),'%Y/%m/%d %H:%i:%s')";
                 strcmd += ", DATE_FORMAT(DATE_FORMAT(NOW(),'%Y/%m/%d %H:%i:%s'),'%Y/%m/%d %H:%i:%s')";
                 strcmd = strcmd + ")";
@@ -202,20 +222,26 @@
 
                 strcmd += " SET";
 
-                // strcmd += string.Format(" RequestNo = {0}", data.RequestNo.ToString());
-                strcmd += string.Format(" ConstructionCode = {0}", data.ConstructionCode.ToString());
-                strcmd += string.Format(",OrderersDivision = {0}", data.OrderersDivision.ToString());
-                strcmd += string.Format(",OrderersCode = {0}", data.OrderersCode.ToString());
-                strcmd += string.Format(",AmountPaid = {0}", data.AmountPaid.ToString());
-                strcmd += string.Format(",PricePaid = {0}", data.PricePaid.ToString());
-                strcmd += string.Format(",TaxPricePaid = {0}", data.TaxPricePaid.ToString());
-                strcmd += string.Format(",PriceBalance = {0}", data.PriceBalance.ToString());
-                strcmd += string.Format(",TaxBalance = {0}", data.TaxBalance.ToString());
-                strcmd += string.Format(",AmountBlance = {0}", data.AmountBlance.ToString());
+                strcmd += string.Format(" ConstructionName = '{0}'", data.ConstructionName.ToString());
+                strcmd += string.Format(",ContractAmount = {0}", data.ContractAmount.ToString());
+                strcmd += string.Format(",PaidAmount = {0}", data.PaidAmount.ToString());
 
+                strcmd += string.Format(",RequestAmount0 = {0}", data.RequestAmount0.ToString());
+                strcmd += string.Format(",RequestAmount1 = {0}", data.RequestAmount1.ToString());
+                strcmd += string.Format(",RequestAmount2 = {0}", data.RequestAmount2.ToString());
+                strcmd += string.Format(",RequestAmount3 = {0}", data.RequestAmount3.ToString());
+                strcmd += string.Format(",RequestAmount4 = {0}", data.RequestAmount4.ToString());
+                strcmd += string.Format(",RequestAmount5 = {0}", data.RequestAmount5.ToString());
+                strcmd += string.Format(",RequestAmount6 = {0}", data.RequestAmount6.ToString());
+
+                strcmd += string.Format(",UnclaimedAmount = {0}", data.UnclaimedAmount.ToString());
+                strcmd += string.Format(",UnpaidAmount = {0}", data.UnpaidAmount.ToString());
+                strcmd += string.Format(",TaxAmount = {0}", data.TaxAmount.ToString());
+                strcmd += string.Format(",Note = '{0}'", data.Note.ToString());
+
                 strcmd += ", UpdateDate = DATE_FORMAT(DATE_FORMAT(NOW(),'%Y/%m/%d %H:%i:%s'),'%Y/%m/%d %H:%i:%s')";
 
-                strcmd += string.Format(" Where RequestNo = {0}", data.RequestNo.ToString());
+                strcmd += string.Format(" Where RequestNo = {0} And MainConstructionCode = {1}", data.RequestNo.ToString(), data.MainConstructionCode.ToString());
                 strcmd += AddSQLString;
 
                 if (!ExecuteNonQuery(strcmd, bConnect)) return false;
@@ -230,6 +256,29 @@
         }
         #endregion
 
+        #region 請求データ更新（複数件更新）
+        /// <summary>
+        /// 請求データ更新（複数件更新）
+        /// </summary>
+        /// <param name="lst">請求データリスト</param>
+        /// <returns>true：成功 false：失敗</returns>
+        public bool UpdateAction(List<RequestData> lst, bool bConnect = true)
+        {
+            string sql;
+
+            foreach( RequestData data in lst )
+            {
+                sql = CreatePrimarykeyString( data.RequestNo, data.MainConstructionCode );
+
+                if( UpdateAction( sql, data, bConnect ) == false)
+                {
+                    return false;
+                }
+            }
+            return true;
+        }
+        #endregion
+
         #region 請求データ削除
         /// <summary>
         /// 請求データ削除
@@ -269,16 +318,23 @@
             {
                 // データ取得
                 wrk.RequestNo = int.Parse(objwrk[(int)NameColumn.RequestNo].ToString());
-                wrk.ConstructionCode = int.Parse(objwrk[(int)NameColumn.ConstructionCode].ToString());
-                wrk.OrderersDivision = int.Parse(objwrk[(int)NameColumn.OrderersDivision].ToString());
-                wrk.OrderersCode = int.Parse(objwrk[(int)NameColumn.OrderersCode].ToString());
-                wrk.AmountPaid = int.Parse(objwrk[(int)NameColumn.AmountPaid].ToString());
-                wrk.PricePaid = int.Parse(objwrk[(int)NameColumn.PricePaid].ToString());
-                wrk.TaxPricePaid = int.Parse(objwrk[(int)NameColumn.TaxPricePaid].ToString());
-                wrk.PriceBalance = int.Parse(objwrk[(int)NameColumn.PriceBalance].ToString());
-                wrk.TaxBalance = int.Parse(objwrk[(int)NameColumn.TaxBalance].ToString());
-                wrk.AmountBlance = int.Parse(objwrk[(int)NameColumn.AmountBlance].ToString());
+                wrk.MainConstructionCode = int.Parse(objwrk[(int)NameColumn.MainConstructionCode].ToString());
 
+                wrk.ConstructionName = objwrk[(int)NameColumn.ConstructionName].ToString();
+                wrk.ContractAmount = int.Parse(objwrk[(int)NameColumn.ContractAmount].ToString());
+                wrk.PaidAmount = int.Parse(objwrk[(int)NameColumn.PaidAmount].ToString());
+                wrk.RequestAmount0 = int.Parse(objwrk[(int)NameColumn.RequestAmount0].ToString());
+                wrk.RequestAmount1 = int.Parse(objwrk[(int)NameColumn.RequestAmount1].ToString());
+                wrk.RequestAmount2 = int.Parse(objwrk[(int)NameColumn.RequestAmount2].ToString());
+                wrk.RequestAmount3 = int.Parse(objwrk[(int)NameColumn.RequestAmount3].ToString());
+                wrk.RequestAmount4 = int.Parse(objwrk[(int)NameColumn.RequestAmount4].ToString());
+                wrk.RequestAmount5 = int.Parse(objwrk[(int)NameColumn.RequestAmount5].ToString());
+                wrk.RequestAmount6 = int.Parse(objwrk[(int)NameColumn.RequestAmount6].ToString());
+                wrk.UnclaimedAmount = int.Parse(objwrk[(int)NameColumn.UnclaimedAmount].ToString());
+                wrk.UnpaidAmount = int.Parse(objwrk[(int)NameColumn.UnpaidAmount].ToString());
+                wrk.TaxAmount = int.Parse(objwrk[(int)NameColumn.TaxAmount].ToString());
+                wrk.Note = objwrk[(int)NameColumn.Note].ToString();
+
                 wrk.EntryDate = DateTime.Parse(objwrk[(int)NameColumn.ENTRY_DATE].ToString());
                 wrk.UpdateDate = DateTime.Parse(objwrk[(int)NameColumn.UPDATE_DATE].ToString());
             }
@@ -304,16 +360,24 @@
             {
                 // データ取得
                 wrk.RequestNo = 0;
-                wrk.ConstructionCode = 0;
-                wrk.OrderersDivision = 0;
-                wrk.OrderersCode = 0;
-                wrk.AmountPaid = 0;
-                wrk.PricePaid = 0;
-                wrk.TaxPricePaid = 0;
-                wrk.PriceBalance = 0;
-                wrk.TaxBalance = 0;
-                wrk.AmountBlance = 0;
+                wrk.MainConstructionCode = 0;
 
+                wrk.ConstructionName = "";
+
+                wrk.ContractAmount = 0;
+                wrk.PaidAmount = 0;
+                wrk.RequestAmount0 = 0;
+                wrk.RequestAmount1 = 0;
+                wrk.RequestAmount2 = 0;
+                wrk.RequestAmount3 = 0;
+                wrk.RequestAmount4 = 0;
+                wrk.RequestAmount5 = 0;
+                wrk.RequestAmount6 = 0;
+                wrk.UnclaimedAmount = 0;
+                wrk.UnpaidAmount = 0;
+                wrk.TaxAmount = 0;
+                wrk.Note = "";
+
                 wrk.EntryDate = DateTime.Now;
                 wrk.UpdateDate = DateTime.Now;
             }
@@ -332,14 +396,19 @@
         /// <summary>
         /// 主キー検索の文字列を返す
         /// </summary>
-        /// <param name="BusinessTypeCode"></param>
+        /// <param name="RequestNo">請求No</param>
+        /// <param name="MainConstructionCode">本工事番号</param>
         /// <returns>Where文字列</returns>
-        public string CreatePrimarykeyString(int RequestNo)
+        public string CreatePrimarykeyString(int RequestNo, int MainConstructionCode = 0)
         {
             string strWork = string.Empty;
             try
             {
                 strWork = string.Format(" Where RequestNo = {0}", RequestNo.ToString());
+                if (MainConstructionCode > 0)
+                {
+                    strWork += string.Format(" And MainConstructionCode = {0}", MainConstructionCode.ToString());
+                }
             }
             catch (Exception ex)
             {
@@ -349,30 +418,6 @@
             return strWork;
         }
         #endregion
-
-        #region サブキー検索の文字列を返す
-        /// <summary>
-        /// サブキー検索の文字列を返す
-        /// </summary>
-        /// <param name="BusinessTypeCode"></param>
-        /// <returns>Where文字列</returns>
-        public string CreateSubkeyString(int ConstructionCode)
-        {
-            string strWork = string.Empty;
-            try
-            {
-                strWork = string.Format(" Where ConstructionCode = {0}", ConstructionCode.ToString());
-
-            }
-            catch (Exception ex)
-            {
-                logger.ErrorFormat("システムエラー：{0}：{1}：{2}", CommonMotions.GetMethodName(2), ex.Message, strWork);
-            }
-
-            return strWork;
-        }
-        #endregion
     }
-
 }
 
Index: branches/src/ProcessManagement/ProcessManagement/DB/IOAccess/IORequestDataDetail.cs
===================================================================
--- branches/src/ProcessManagement/ProcessManagement/DB/IOAccess/IORequestDataDetail.cs	(revision 59)
+++ branches/src/ProcessManagement/ProcessManagement/DB/IOAccess/IORequestDataDetail.cs	(revision 60)
@@ -17,7 +17,7 @@
 namespace ProcessManagement.DB.IOAccess
 {
     /// <summary>
-    /// 請求明細データアクセスクラス
+    /// 請求データ明細アクセスクラス
     /// </summary>
     public class IORequestDataDetail : MySqlProcess
     {
@@ -30,17 +30,16 @@
 
         #region 定数
         /// <summary>
-        /// 請求データフィールド並び
+        /// 請求データ明細フィールド並び
         /// </summary>
         public enum NameColumn
         {
             RequestNo = 0,
-            OrderNo,
+            MainConstructionCode,
             ConstructionCode,
             ConstructionKind,
-            BillPrice,
-            TaxPrice,
-            AmountBlance,
+            RequestAmount,
+            TaxAmount,
             ENTRY_DATE,
             UPDATE_DATE,
         }
@@ -58,9 +57,9 @@
 
         #endregion
 
-        #region 請求明細データ検索
+        #region 請求データ明細検索
         /// <summary>
-        /// 請求明細データ検索
+        /// 請求データ明細検索
         /// </summary>
         /// <param name="AddSQLString"></param>
         /// <param name="data"></param>
@@ -77,12 +76,12 @@
                 // SQL作成（oracleのDateTime型が変換できないのでCharに変換しておく）
                 strcmd = "SELECT";
                 strcmd += " RequestNo";
-                strcmd += " ,OrderNo";
+                strcmd += " ,MainConstructionCode";
                 strcmd += " ,ConstructionCode";
+
                 strcmd += " ,ConstructionKind";
-                strcmd += " ,BillPrice";
-                strcmd += " ,TaxPrice";
-                strcmd += " ,AmountBlance";
+                strcmd += " ,RequestAmount";
+                strcmd += " ,TaxAmount";
                 strcmd += " ,DATE_FORMAT(EntryDate, '%Y/%m/%d %H:%i:%s')";
                 strcmd += " ,DATE_FORMAT(UpdateDate, '%Y/%m/%d %H:%i:%s')";
                 strcmd += " FROM RequestDataDetail";
@@ -109,11 +108,11 @@
         }
         #endregion
 
-        #region 請求明細データ複数追加
+        #region 請求データ明細複数追加
         /// <summary>
-        /// 請求明細データ複数追加
+        /// 請求データ明細複数追加
         /// </summary>
-        /// <param name="data">請求明細データ</param>
+        /// <param name="data">請求データ明細</param>
         /// <returns>true：成功 false：失敗</returns>
         public bool InsertAction(List<RequestDataDetail> data, bool bConnect = true)
         {
@@ -135,9 +134,9 @@
         }
         #endregion
 
-        #region 請求明細データ１件追加
+        #region 請求データ明細１件追加
         /// <summary>
-        /// 請求明細データ１件追加
+        /// 請求データ明細１件追加
         /// </summary>
         /// <param name="data"></param>
         /// <param name="bConnect"></param>
@@ -149,16 +148,15 @@
             {
 
                 strcmd = "INSERT INTO RequestDataDetail";
-
                 strcmd += " VALUES (";
 
                 strcmd += string.Format(" {0}", data.RequestNo.ToString());
-                strcmd += string.Format(", {0}", data.OrderNo.ToString());
+                strcmd += string.Format(", {0}", data.MainConstructionCode.ToString());
                 strcmd += string.Format(", {0}", data.ConstructionCode.ToString());
+
                 strcmd += string.Format(", {0}", data.ConstructionKind.ToString());
-                strcmd += string.Format(", {0}", data.BillPrice.ToString());
-                strcmd += string.Format(", {0}", data.TaxPrice.ToString());
-                strcmd += string.Format(", {0}", data.AmountBlance.ToString());
+                strcmd += string.Format(", {0}", data.RequestAmount.ToString());
+                strcmd += string.Format(", {0}", data.TaxAmount.ToString());
 
                 strcmd += ", DATE_FORMAT(DATE_FORMAT(NOW(),'%Y/%m/%d %H:%i:%s'),'%Y/%m/%d %H:%i:%s')";
                 strcmd += ", DATE_FORMAT(DATE_FORMAT(NOW(),'%Y/%m/%d %H:%i:%s'),'%Y/%m/%d %H:%i:%s')";
@@ -176,12 +174,12 @@
         }
         #endregion
 
-        #region 請求明細データ更新
+        #region 請求データ明細更新
         /// <summary>
-        /// 請求明細データ更新
+        /// 請求データ明細更新
         /// </summary>
         /// <param name="AddSQLString">更新条件SQL文字列</param>
-        /// <param name="data">請求明細データ</param>
+        /// <param name="data">請求データ明細</param>
         /// <returns>true：成功 false：失敗</returns>
         public bool UpdateAction(string AddSQLString, RequestDataDetail data, bool bConnect = true)
         {
@@ -193,18 +191,15 @@
 
                 strcmd += " SET";
 
-                // strcmd += string.Format(" RequestNo = {0}", data.RequestNo.ToString());
-                // strcmd += string.Format(",OrderNo = {0}", data.OrderNo.ToString());
-                // strcmd += string.Format(",ConstructionCode = {0}", data.ConstructionCode.ToString());
-                strcmd += string.Format(" ConstructionKind = {0}", data.ConstructionKind.ToString());
-                strcmd += string.Format(",BillPrice = {0}", data.BillPrice.ToString());
-                strcmd += string.Format(",TaxPrice = {0}", data.TaxPrice.ToString());
-                strcmd += string.Format(",AmountBlance = {0}", data.AmountBlance.ToString());
+                strcmd += string.Format(" ConstructionKind = '{0}'", data.ConstructionKind.ToString());
+                strcmd += string.Format(",RequestAmount = {0}", data.RequestAmount.ToString());
+                strcmd += string.Format(",TaxAmount = {0}", data.TaxAmount.ToString());
 
                 strcmd += ", UpdateDate = DATE_FORMAT(DATE_FORMAT(NOW(),'%Y/%m/%d %H:%i:%s'),'%Y/%m/%d %H:%i:%s')";
+
                 strcmd += string.Format(" Where RequestNo = {0}", data.RequestNo.ToString());
-                strcmd += string.Format(" And OrderNo = {0}", data.OrderNo.ToString());
-                strcmd += string.Format(" And ConstructionCode = {0}", data.ConstructionCode.ToString());
+                strcmd += string.Format("  And MainConstructionCode = {0}", data.MainConstructionCode.ToString());
+                strcmd += string.Format("  And ConstructionCode = {0} ", data.ConstructionCode.ToString());
                 strcmd += AddSQLString;
 
                 if (!ExecuteNonQuery(strcmd, bConnect)) return false;
@@ -219,10 +214,34 @@
         }
         #endregion
 
-        #region 請求明細データ削除
+        #region 請求データ明細更新（複数件更新）
         /// <summary>
-        /// 請求明細データ削除
+        /// 請求データ明細更新（複数件更新）
         /// </summary>
+        /// <param name="lst">請求データ明細リスト</param>
+        /// <returns>true：成功 false：失敗</returns>
+        public bool UpdateAction(List<RequestDataDetail> lst, bool bConnect = true)
+        {
+            string sql;
+
+            foreach (RequestDataDetail ReqDetail in lst)
+            {
+                sql = CreatePrimarykeyString(ReqDetail.RequestNo, ReqDetail.MainConstructionCode, ReqDetail.ConstructionCode);
+
+                if (UpdateAction(sql, ReqDetail, bConnect) == false)
+                {
+                    return false;
+                }
+            }
+
+            return true;
+        }
+        #endregion
+
+        #region 請求データ明細削除
+        /// <summary>
+        /// 請求データ明細削除
+        /// </summary>
         /// <param name="AddSQLString">削除条件SQL文字列</param>
         /// <param name="bConnect"></param>
         /// <returns></returns>
@@ -258,12 +277,12 @@
             {
                 // データ取得
                 wrk.RequestNo = int.Parse(objwrk[(int)NameColumn.RequestNo].ToString());
-                wrk.OrderNo = int.Parse(objwrk[(int)NameColumn.OrderNo].ToString());
+                wrk.MainConstructionCode = int.Parse(objwrk[(int)NameColumn.MainConstructionCode].ToString());
                 wrk.ConstructionCode = int.Parse(objwrk[(int)NameColumn.ConstructionCode].ToString());
+
                 wrk.ConstructionKind = int.Parse(objwrk[(int)NameColumn.ConstructionKind].ToString());
-                wrk.BillPrice = int.Parse(objwrk[(int)NameColumn.BillPrice].ToString());
-                wrk.TaxPrice = int.Parse(objwrk[(int)NameColumn.TaxPrice].ToString());
-                wrk.AmountBlance = int.Parse(objwrk[(int)NameColumn.AmountBlance].ToString());
+                wrk.RequestAmount = int.Parse(objwrk[(int)NameColumn.RequestAmount].ToString());
+                wrk.TaxAmount = int.Parse(objwrk[(int)NameColumn.TaxAmount].ToString());
 
                 wrk.EntryDate = DateTime.Parse(objwrk[(int)NameColumn.ENTRY_DATE].ToString());
                 wrk.UpdateDate = DateTime.Parse(objwrk[(int)NameColumn.UPDATE_DATE].ToString());
@@ -290,12 +309,12 @@
             {
                 // データ取得
                 wrk.RequestNo = 0;
-                wrk.OrderNo = 0;
+                wrk.MainConstructionCode = 0;
                 wrk.ConstructionCode = 0;
+
                 wrk.ConstructionKind = 0;
-                wrk.BillPrice = 0;
-                wrk.TaxPrice = 0;
-                wrk.AmountBlance = 0;
+                wrk.RequestAmount = 0;
+                wrk.TaxAmount = 0;
 
                 wrk.EntryDate = DateTime.Now;
                 wrk.UpdateDate = DateTime.Now;
@@ -315,18 +334,25 @@
         /// <summary>
         /// 主キー検索の文字列を返す
         /// </summary>
-        /// <param name="BusinessTypeCode"></param>
+        /// <param name="RequestNo">請求No</param>
+        /// <param name="MainConstructionCode">本工事番号</param>
+        /// <param name="ConstructionCode">工事番号</param>
         /// <returns>Where文字列</returns>
-        public string CreatePrimarykeyString(int RequestNo, int OrderNo = 0, int ConstructionCode = 0)
+        public string CreatePrimarykeyString(int RequestNo, int MainConstructionCode = 0, int ConstructionCode = 0)
         {
             string strWork = string.Empty;
             try
             {
                 strWork = string.Format(" Where RequestNo = {0}", RequestNo.ToString());
-                if (OrderNo != 0)
-                    strWork += string.Format(" And OrderNo = {0}", OrderNo.ToString());
-                if (ConstructionCode != 0)
+                if (MainConstructionCode > 0)
+                {
+                    strWork += string.Format(" And MainConstructionCode = {0}", MainConstructionCode.ToString());
+                }
+                if (ConstructionCode > 0)
+                {
                     strWork += string.Format(" And ConstructionCode = {0}", ConstructionCode.ToString());
+                }
+
             }
             catch (Exception ex)
             {
@@ -336,6 +362,6 @@
             return strWork;
         }
         #endregion
-
     }
 }
+
Index: branches/src/ProcessManagement/ProcessManagement/DB/IOAccess/IORequestHead.cs
===================================================================
--- branches/src/ProcessManagement/ProcessManagement/DB/IOAccess/IORequestHead.cs	(nonexistent)
+++ branches/src/ProcessManagement/ProcessManagement/DB/IOAccess/IORequestHead.cs	(revision 60)
@@ -0,0 +1,495 @@
+﻿using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Text;
+using System.Threading.Tasks;
+using System.Collections;
+
+using log4net;
+using MySql.Data.MySqlClient;
+
+using ProcessManagement.DB.MySql;
+using ProcessManagement.DB.Core;
+using ProcessManagement.DataModel;
+
+using ProcessManagement.Common;
+
+namespace ProcessManagement.DB.IOAccess
+{
+    /// <summary>
+    /// 請求ヘッダアクセスクラス
+    /// </summary>
+    public class IORequestHead : MySqlProcess
+    {
+        #region 定義部
+        /// <summary>
+        /// log4netログを使用する
+        /// </summary>
+        private static readonly ILog logger = LogManager.GetLogger(System.Reflection.MethodBase.GetCurrentMethod().DeclaringType);
+        #endregion
+
+        #region 定数
+        /// <summary>
+        /// 請求データフィールド並び
+        /// </summary>
+        public enum NameColumn
+        {
+            RequestNo = 0,
+            ReqConstructionCode,
+            OrderNo,
+            RequestMonth,
+            OrderersDivision,
+            OrderersCode,
+            OrderersName,
+            ReqConstructionName,
+            RequestTotalAmount,
+            RequestAmount,
+            TaxAmount,
+            UnpaidAmount,
+            Note,
+            AssignedFlg,
+            InvoiceNo,
+            ENTRY_DATE,
+            UPDATE_DATE,
+        }
+        #endregion
+
+        #region コンストラクタ
+        /// <summary>
+        /// コンストラクタ
+        /// </summary>
+        /// <param name="connectionString"></param>
+        public IORequestHead()
+            : base(DBCommon.Instance.DBConnectString)
+        {
+        }
+
+        #endregion
+
+        #region 請求ヘッダ検索
+        /// <summary>
+        /// 請求ヘッダ検索
+        /// </summary>
+        /// <param name="AddSQLString"></param>
+        /// <param name="data"></param>
+        /// <param name="bConnect"></param>
+        /// <returns></returns>
+        public bool SelectAction(string AddSQLString, ref List<RequestHead> data, bool bConnect = true)
+        {
+            //Oracle インターフェース
+            string strcmd = "";
+            ArrayList arData = new ArrayList();
+
+            try
+            {
+                // SQL作成（oracleのDateTime型が変換できないのでCharに変換しておく）
+                strcmd = "SELECT";
+                strcmd += " RequestNo";
+                strcmd += " ,ReqConstructionCode";
+                strcmd += " ,OrderNo";
+                strcmd += " ,RequestMonth";
+                strcmd += " ,OrderersDivision";
+                strcmd += " ,OrderersCode";
+                strcmd += " ,OrderersName";
+                strcmd += " ,ReqConstructionName";
+                strcmd += " ,RequestTotalAmount";
+                strcmd += " ,RequestAmount";
+                strcmd += " ,TaxAmount";
+                strcmd += " ,UnpaidAmount";
+                strcmd += " ,Note";
+                strcmd += " ,AssignedFlg";
+                strcmd += " ,InvoiceNo";
+                strcmd += " ,DATE_FORMAT(EntryDate, '%Y/%m/%d %H:%i:%s')";
+                strcmd += " ,DATE_FORMAT(UpdateDate, '%Y/%m/%d %H:%i:%s')";
+                strcmd += " FROM RequestHead";
+                strcmd += AddSQLString;
+
+                // SQL実行
+                if (!ExecuteReader(strcmd, ref arData, bConnect)) return false;
+
+                // データセット
+                foreach (object[] objwrk in arData)
+                {
+                    RequestHead work = new RequestHead();
+                    Reader2Struct(objwrk, ref work);
+                    data.Add(work);
+                }
+
+                return true;
+            }
+            catch (Exception ex)
+            {
+                logger.ErrorFormat("システムエラー：：{0}：{1}：{2}", CommonMotions.GetMethodName(2), ex.Message, strcmd);
+                return false;
+            }
+        }
+        #endregion
+
+        #region 請求ヘッダ複数追加
+        /// <summary>
+        /// 請求ヘッダ複数追加
+        /// </summary>
+        /// <param name="data">請求データ</param>
+        /// <returns>true：成功 false：失敗</returns>
+        public bool InsertAction(List<RequestHead> data, bool bConnect = true)
+        {
+            string strcmd = "";
+            try
+            {
+                foreach (RequestHead work in data)
+                {
+                    if (!InsertAction(work, bConnect)) return false;
+                }
+                return true;
+            }
+            catch (Exception ex)
+            {
+                logger.ErrorFormat("システムエラー：：{0}：{1}：{2}", CommonMotions.GetMethodName(2), ex.Message, strcmd);
+                return false;
+            }
+        }
+        #endregion
+
+        #region 請求ヘッダ１件追加
+        /// <summary>
+        /// 請求ヘッダ１件追加
+        /// </summary>
+        /// <param name="data"></param>
+        /// <param name="bConnect"></param>
+        /// <returns></returns>
+        public bool InsertAction(RequestHead data, bool bConnect = true)
+        {
+            string strcmd = "";
+            try
+            {
+
+                strcmd = "INSERT INTO RequestHead";
+                strcmd += " VALUES (";
+
+                strcmd += string.Format(" {0}", data.RequestNo.ToString());
+
+                strcmd += string.Format(", {0}", data.ReqConstructionCode.ToString());
+                strcmd += string.Format(", {0}", data.OrderNo.ToString());
+
+                strcmd += string.Format(", {0}", data.RequestMonth.ToString());
+                strcmd += string.Format(", {0}", data.OrderersDivision.ToString());
+                strcmd += string.Format(", {0}", data.OrderersCode.ToString());
+                strcmd += string.Format(", '{0}'", data.OrderersName.ToString());
+                strcmd += string.Format(", '{0}'", data.ReqConstructionName.ToString());
+                strcmd += string.Format(", {0}", data.RequestTotalAmount.ToString());
+                strcmd += string.Format(", {0}", data.RequestAmount.ToString());
+                strcmd += string.Format(", {0}", data.TaxAmount.ToString());
+                strcmd += string.Format(", {0}", data.UnpaidAmount.ToString());
+                strcmd += string.Format(", '{0}'", data.Note.ToString());    
+                strcmd += string.Format(", {0}", data.AssignedFlg.ToString());
+                strcmd += string.Format(", {0}", data.InvoiceNo.ToString());
+
+                strcmd += ", DATE_FORMAT(DATE_FORMAT(NOW(),'%Y/%m/%d %H:%i:%s'),'%Y/%m/%d %H:%i:%s')";
+                strcmd += ", DATE_FORMAT(DATE_FORMAT(NOW(),'%Y/%m/%d %H:%i:%s'),'%Y/%m/%d %H:%i:%s')";
+                strcmd = strcmd + ")";
+
+                if (!ExecuteNonQuery(strcmd, bConnect)) return false;
+
+                return true;
+            }
+            catch (Exception ex)
+            {
+                logger.ErrorFormat("システムエラー：：{0}：{1}：{2}", CommonMotions.GetMethodName(2), ex.Message, strcmd);
+                return false;
+            }
+        }
+        #endregion
+
+        #region 請求ヘッダ更新（複数件更新）
+
+        /// <summary>
+        /// 請求ヘッダ更新（複数件更新）
+        /// </summary>
+        /// <param name="lstReqHead"></param>
+        /// <param name="bConnect"></param>
+        /// <returns></returns>
+        public bool UpdateAction(List<RequestHead> lstReqHead, bool bConnect = true)
+        {
+            foreach (RequestHead ReqHead in lstReqHead)
+            {
+                string sql = CreatePrimarykeyString(ReqHead.RequestNo);
+
+                bool ret = UpdateAction(sql, ReqHead, bConnect);
+                if (ret == false)
+                {
+                    return false;
+                }
+            }
+
+            return true;
+        }
+
+        #endregion
+
+        #region 請求ヘッダ更新（１件更新）
+        /// <summary>
+        /// 請求データ更新（１件更新）
+        /// </summary>
+        /// <param name="AddSQLString">更新条件SQL文字列</param>
+        /// <param name="data">請求ヘッダ</param>
+        /// <returns>true：成功 false：失敗</returns>
+        public bool UpdateAction(string AddSQLString, RequestHead data, bool bConnect = true)
+        {
+            string strcmd = "";
+            try
+            {
+
+                strcmd = "UPDATE RequestHead";
+
+                strcmd += " SET";
+
+                strcmd += string.Format(" ReqConstructionCode = {0}", data.ReqConstructionCode.ToString());
+                strcmd += string.Format(",OrderNo = {0}", data.OrderNo.ToString());
+                strcmd += string.Format(",RequestMonth = {0}", data.RequestMonth.ToString());
+
+                strcmd += string.Format(",OrderersDivision = {0}", data.OrderersDivision.ToString());
+                strcmd += string.Format(",OrderersCode = {0}", data.OrderersCode.ToString());
+                strcmd += string.Format(",OrderersName = '{0}'", data.OrderersName.ToString());
+
+
+                strcmd += string.Format(",ReqConstructionName = '{0}'", data.ReqConstructionName.ToString());
+                strcmd += string.Format(",RequestTotalAmount = {0}", data.RequestTotalAmount.ToString());
+                strcmd += string.Format(",RequestAmount = {0}", data.RequestAmount.ToString());
+                strcmd += string.Format(",TaxAmount = {0}", data.TaxAmount.ToString());
+                strcmd += string.Format(",UnpaidAmount = {0}", data.UnpaidAmount.ToString());
+                strcmd += string.Format(",Note = '{0}'", data.Note.ToString());
+                
+                strcmd += string.Format(",AssignedFlg = {0}", data.AssignedFlg.ToString());
+                strcmd += string.Format(",InvoiceNo = {0}", data.InvoiceNo.ToString());
+
+                strcmd += ", UpdateDate = DATE_FORMAT(DATE_FORMAT(NOW(),'%Y/%m/%d %H:%i:%s'),'%Y/%m/%d %H:%i:%s')";
+
+                //strcmd += string.Format(" Where RequestNo = {0}", data.RequestNo.ToString());
+                strcmd += AddSQLString;
+
+                if (!ExecuteNonQuery(strcmd, bConnect)) return false;
+
+                return true;
+            }
+            catch (Exception ex)
+            {
+                logger.ErrorFormat("システムエラー：：{0}：{1}：{2}", CommonMotions.GetMethodName(2), ex.Message, strcmd);
+                return false;
+            }
+        }
+        #endregion
+
+        #region 請求ヘッダ削除
+        /// <summary>
+        /// 請求データ削除
+        /// </summary>
+        /// <param name="AddSQLString">削除条件SQL文字列</param>
+        /// <param name="bConnect"></param>
+        /// <returns></returns>
+        public bool DeleteAction(string AddSQLString, bool bConnect = true)
+        {
+            //Oracle インターフェース
+            string strcmd = "";
+            try
+            {
+                strcmd = string.Format("{0}{1}", "DELETE FROM RequestHead", AddSQLString);
+
+                if (!ExecuteNonQuery(strcmd, bConnect)) return false;
+
+                return true;
+            }
+            catch (Exception ex)
+            {
+                logger.ErrorFormat("システムエラー：：{0}：{1}：{2}", CommonMotions.GetMethodName(2), ex.Message, strcmd);
+                return false;
+            }
+        }
+        #endregion
+
+        #region OracleDataReaderより構造体へセットする
+        /// <summary>
+        /// OracleDataReaderより構造体へセットする
+        /// </summary>
+        /// <param name="reader">OracleDataReader</param>
+        /// <param name="wrk">構造体</param>
+        public void Reader2Struct(object[] objwrk, ref RequestHead wrk)
+        {
+            try
+            {
+                // データ取得
+                wrk.RequestNo = int.Parse(objwrk[(int)NameColumn.RequestNo].ToString());
+                
+                wrk.ReqConstructionCode = int.Parse(objwrk[(int)NameColumn.ReqConstructionCode].ToString());
+                wrk.OrderNo = int.Parse(objwrk[(int)NameColumn.OrderNo].ToString());
+
+                wrk.RequestMonth = int.Parse(objwrk[(int)NameColumn.RequestMonth].ToString());
+                wrk.OrderersDivision = int.Parse(objwrk[(int)NameColumn.OrderersDivision].ToString());
+                wrk.OrderersCode = int.Parse(objwrk[(int)NameColumn.OrderersCode].ToString());
+                wrk.OrderersName = objwrk[(int)NameColumn.OrderersName].ToString();
+
+                wrk.ReqConstructionName = objwrk[(int)NameColumn.ReqConstructionName].ToString();
+
+                wrk.RequestTotalAmount = int.Parse(objwrk[(int)NameColumn.RequestTotalAmount].ToString());
+                wrk.RequestAmount = int.Parse(objwrk[(int)NameColumn.RequestAmount].ToString());
+                wrk.TaxAmount = int.Parse(objwrk[(int)NameColumn.TaxAmount].ToString());
+                wrk.UnpaidAmount = int.Parse(objwrk[(int)NameColumn.UnpaidAmount].ToString());
+
+                wrk.Note = objwrk[(int)NameColumn.Note].ToString();
+
+                wrk.AssignedFlg = int.Parse(objwrk[(int)NameColumn.AssignedFlg].ToString());
+                wrk.InvoiceNo = int.Parse(objwrk[(int)NameColumn.InvoiceNo].ToString());
+
+                wrk.EntryDate = DateTime.Parse(objwrk[(int)NameColumn.ENTRY_DATE].ToString());
+                wrk.UpdateDate = DateTime.Parse(objwrk[(int)NameColumn.UPDATE_DATE].ToString());
+            }
+            catch (MySqlException myex)
+            {
+                logger.ErrorFormat("ＭｙＳＱＬエラー：{0}：{1}", CommonMotions.GetMethodName(2), myex.Message);
+            }
+            catch (Exception ex)
+            {
+                logger.ErrorFormat("システムエラー：：{0}：{1}：{2}", CommonMotions.GetMethodName(), ex.Message);
+            }
+        }
+        #endregion
+
+        #region 構造体クリア
+        /// <summary>
+        /// 構造体クリア
+        /// </summary>
+        /// <param name="wrk"></param>
+        public void ClearStruct(ref RequestHead wrk)
+        {
+            try
+            {
+                // データ取得
+                wrk.RequestNo = 0;
+                
+                wrk.ReqConstructionCode = 0;
+                wrk.OrderNo = 0;
+                wrk.RequestMonth = 0;
+
+                wrk.OrderersDivision = 0;
+                wrk.OrderersCode = 0;
+
+                wrk.OrderersName = "";
+                wrk.ReqConstructionName = "";
+                
+                wrk.RequestTotalAmount = 0;
+                wrk.RequestAmount = 0;
+                wrk.TaxAmount = 0;
+                wrk.UnpaidAmount = 0;
+                
+                wrk.Note = "";
+
+                wrk.AssignedFlg = 0;
+                wrk.InvoiceNo = 0;
+
+                wrk.EntryDate = DateTime.Now;
+                wrk.UpdateDate = DateTime.Now;
+            }
+            catch (MySqlException myex)
+            {
+                logger.ErrorFormat("ＭｙＳＱＬエラー：{0}：{1}", CommonMotions.GetMethodName(2), myex.Message);
+            }
+            catch (Exception ex)
+            {
+                logger.ErrorFormat("システムエラー：：{0}：{1}：{2}", CommonMotions.GetMethodName(), ex.Message);
+            }
+        }
+        #endregion
+
+        #region 主キー検索の文字列を返す
+        /// <summary>
+        /// 主キー検索の文字列を返す
+        /// </summary>
+        /// <param name="RequestNo">請求No</param>
+        /// <returns>Where文字列</returns>
+        public string CreatePrimarykeyString(int RequestNo)
+        {
+            string strWork = string.Empty;
+            try
+            {
+                strWork = string.Format(" Where RequestNo = {0}", RequestNo.ToString());
+            }
+            catch (Exception ex)
+            {
+                logger.ErrorFormat("システムエラー：{0}：{1}：{2}", CommonMotions.GetMethodName(2), ex.Message, strWork);
+            }
+
+            return strWork;
+        }
+        #endregion
+
+        #region サブキー検索の文字列を返す
+        /// <summary>
+        /// サブキー検索の文字列を返す
+        /// </summary>
+        /// <param name="ReqConstructionCode">請求工事番号</param>
+        /// <param name="OrderNo">受付番号</param>
+        /// <returns>Where文字列</returns>
+        public string CreateSubkeyString(int ReqConstructionCode, int OrderNo = 0)
+        {
+            string strWork = string.Empty;
+            try
+            {
+                strWork = string.Format(" Where ReqConstructionCode = {0}", ReqConstructionCode.ToString() );
+                if (OrderNo > 0)
+                {
+                    strWork += string.Format(" And OrderNo = {0}", OrderNo.ToString());
+                }
+            }
+            catch (Exception ex)
+            {
+                logger.ErrorFormat("システムエラー：{0}：{1}：{2}", CommonMotions.GetMethodName(2), ex.Message, strWork);
+            }
+
+            return strWork;
+        }
+        #endregion
+
+        #region 請求Noの採番
+        public int NumberingRequestNo(int RequestMonth, bool bConnect = true)
+        {
+            int ret = -1;
+
+            string  sql = "";
+            ArrayList arData = new ArrayList();
+
+            try
+            {
+                sql = string.Format("SELECT IFNULL(MAX(RequestNo),0) FROM RequestHead WHERE RequestMonth = {0}", RequestMonth) ;
+
+                // SQL実行
+                if (!ExecuteReader(sql, ref arData, bConnect)) return -1;
+
+                // データセット
+                foreach (object[] objwrk in arData)
+                {
+                    ret = int.Parse(objwrk[0].ToString());
+                    break;
+                }
+
+                if (ret > 0)
+                {
+                    ret++;
+                }
+                else
+                {
+                    ret = (RequestMonth * 1000) + 1;
+                }
+
+            }
+            catch (Exception ex)
+            {
+                logger.ErrorFormat("システムエラー：：{0}：{1}：{2}", CommonMotions.GetMethodName(2), ex.Message, sql);
+            }
+            return ret;
+
+        }
+        #endregion
+
+    }
+
+}
+
Index: branches/src/ProcessManagement/ProcessManagement/DataModel/DepositData.cs
===================================================================
--- branches/src/ProcessManagement/ProcessManagement/DataModel/DepositData.cs	(revision 59)
+++ branches/src/ProcessManagement/ProcessManagement/DataModel/DepositData.cs	(revision 60)
@@ -16,7 +16,9 @@
         private int m_OrderersCode = 0;                         // 発注者コード
         private string m_TargetDate = string.Empty;             // 対象年月
         private int m_SeqNo = 0;                                // 連番
+        private int m_BusinessPeriod = 0;                         // 営業期
         private DateTime m_DepositDate = DateTime.MinValue;     // 入金日
+        private int m_DepositAmount = 0;                        // 入金金額
         private int m_DepositAmountCash = 0;                    // 入金金額（現金）
         private int m_DepositAmountBill = 0;                    // 入金金額（手形）
         private DateTime m_EntryDate = DateTime.Now;            // 登録年月日
@@ -64,6 +66,15 @@
         }
 
         /// <summary>
+        /// 営業期
+        /// </summary>
+        public int BusinessPeriod
+        {
+            get { return m_BusinessPeriod; }
+            set { m_BusinessPeriod = value; }
+        }
+
+        /// <summary>
         /// 入金日
         /// </summary>
         public DateTime DepositDate
@@ -73,6 +84,15 @@
         }
 
         /// <summary>
+        /// 入金金額
+        /// </summary>
+        public int DepositAmount
+        {
+            get { return m_DepositAmount; }
+            set { m_DepositAmount = value; }
+        }
+
+        /// <summary>
         /// 入金金額（現金）
         /// </summary>
         public int	DepositAmountCash
Index: branches/src/ProcessManagement/ProcessManagement/DataModel/InvoiceData.cs
===================================================================
--- branches/src/ProcessManagement/ProcessManagement/DataModel/InvoiceData.cs	(nonexistent)
+++ branches/src/ProcessManagement/ProcessManagement/DataModel/InvoiceData.cs	(revision 60)
@@ -0,0 +1,204 @@
+﻿using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Text;
+using System.Threading.Tasks;
+
+namespace ProcessManagement.DataModel
+{
+    /// <summary>
+    /// 請求書データ
+    /// </summary>
+    public class InvoiceData
+    {
+        #region メンバ変数
+        private int         m_InvoiceNo = 0;                    // 請求書No
+        private int         m_OrderersDivision = 0;             // 発注者区分
+        private int         m_OrderersCode = 0;                 // 発注者コード
+        private int         m_RequestMonth = 0;                 // 請求月
+        private int         m_SeqNo = 0;                        // 連番
+        private DateTime    m_CretateDate = DateTime.MinValue;  // 作成日
+        private DateTime    m_RequestDate = DateTime.MinValue;  // 請求日
+        private string      m_RequestName = "";                 // 請求先名
+        private int         m_TotalAmount = 0;                  // 税込み合計金額
+        private int         m_TaxAmount = 0;                    // 消費税金額
+        private string      m_Comment1 = "";                    // コメント1
+        private string      m_Comment2 = "";                    // コメント2
+        private string      m_Comment3 = "";                    // コメント3
+        private string      m_Comment4 = "";                    // コメント4
+        private string      m_Comment5 = "";                    // コメント5
+        private int         m_CompleteFlg = 0;                  // 出力完了フラグ
+        private DateTime    m_EntryDate = DateTime.Now;         // 登録日付
+        private DateTime    m_UpdateDate = DateTime.Now;        // 更新日付
+        #endregion
+
+        #region コンストラクタ
+        #endregion
+
+        #region プロパティ
+        /// <summary>
+        /// 請求書No
+        /// </summary>
+        public int InvoiceNo
+        {
+            get { return m_InvoiceNo; }
+            set { m_InvoiceNo = value; }
+        }
+
+        /// <summary>
+        /// 発注者区分
+        /// </summary>
+        public int OrderersDivision
+        {
+            get { return m_OrderersDivision; }
+            set { m_OrderersDivision = value; }
+        }
+
+        /// <summary>
+        /// 発注者コード
+        /// </summary>
+        public int OrderersCode
+        {
+            get { return m_OrderersCode; }
+            set { m_OrderersCode = value; }
+        }
+
+        /// <summary>
+        /// 請求月
+        /// </summary>
+        public int RequestMonth
+        {
+            get { return m_RequestMonth; }
+            set { m_RequestMonth = value; }
+        }
+
+        /// <summary>
+        /// 連番
+        /// </summary>
+        public int SeqNo
+        {
+            get { return m_SeqNo; }
+            set { m_SeqNo = value; }
+        }
+
+        /// <summary>
+        /// 作成日
+        /// </summary>
+        public DateTime CretateDate
+        {
+            get { return m_CretateDate; }
+            set { m_CretateDate = value; }
+        }
+
+        /// <summary>
+        /// 請求日
+        /// </summary>
+        public DateTime RequestDate
+        {
+            get { return m_RequestDate; }
+            set { m_RequestDate = value; }
+        }
+
+        /// <summary>
+        /// 請求先名
+        /// </summary>
+        public string RequestName
+        {
+            get { return m_RequestName; }
+            set { m_RequestName = value; }
+        }
+
+        /// <summary>
+        /// 税込み合計金額
+        /// </summary>
+        public int TotalAmount
+        {
+            get { return m_TotalAmount; }
+            set { m_TotalAmount = value; }
+        }
+
+        /// <summary>
+        /// 消費税金額
+        /// </summary>
+        public int TaxAmount
+        {
+            get { return m_TaxAmount; }
+            set { m_TaxAmount = value; }
+        }
+
+        /// <summary>
+        /// コメント1
+        /// </summary>
+        public string Comment1
+        {
+            get { return m_Comment1; }
+            set { m_Comment1 = value; }
+        }
+
+        /// <summary>
+        /// コメント2
+        /// </summary>
+        public string Comment2
+        {
+            get { return m_Comment2; }
+            set { m_Comment2 = value; }
+        }
+
+        /// <summary>
+        /// コメント3
+        /// </summary>
+        public string Comment3
+        {
+            get { return m_Comment3; }
+            set { m_Comment3 = value; }
+        }
+
+        /// <summary>
+        /// コメント4
+        /// </summary>
+        public string Comment4
+        {
+            get { return m_Comment4; }
+            set { m_Comment4 = value; }
+        }
+
+        /// <summary>
+        /// コメント5
+        /// </summary>
+        public string Comment5
+        {
+            get { return m_Comment5; }
+            set { m_Comment5 = value; }
+        }
+
+        /// <summary>
+        /// 出力完了フラグ
+        /// </summary>
+        public int CompleteFlg
+        {
+            get { return m_CompleteFlg; }
+            set { m_CompleteFlg = value; }
+        }
+
+        /// <summary>
+        /// 登録日付
+        /// </summary>
+        public DateTime EntryDate
+        {
+            get { return m_EntryDate; }
+            set { m_EntryDate = value; }
+        }
+
+        /// <summary>
+        /// 更新日付
+        /// </summary>
+        public DateTime UpdateDate
+        {
+            get { return m_UpdateDate; }
+            set { m_UpdateDate = value; }
+        }
+
+        #endregion
+
+    }
+}
Index: branches/src/ProcessManagement/ProcessManagement/DataModel/RequestData.cs
===================================================================
--- branches/src/ProcessManagement/ProcessManagement/DataModel/RequestData.cs	(revision 59)
+++ branches/src/ProcessManagement/ProcessManagement/DataModel/RequestData.cs	(revision 60)
@@ -13,15 +13,21 @@
     {
         #region メンバ変数
         private int         m_RequestNo = 0;                    // 請求No
-        private int         m_ConstructionCode = 0;             // 工事番号
-        private int         m_OrderersDivision = 0;             // 発注者区分
-        private int         m_OrderersCode = 0;                 // 発注者コード
-        private int         m_AmountPaid = 0;                   // 請求済金額
-        private int         m_PricePaid = 0;                    // 請求済工事金額
-        private int         m_TaxPricePaid = 0;                 // 請求済消費税金額
-        private int         m_PriceBalance = 0;                 // 請求残工事金額
-        private int         m_TaxBalance = 0;                   // 請求残消費税金額
-        private int         m_AmountBlance = 0;                 // 未収金額
+        private int         m_MainConstructionCode = 0;         // 本工事番号
+        private string      m_ConstructionName = "";            // 工事件名
+        private int         m_ContractAmount = 0;               // 請負金額
+        private int         m_PaidAmount = 0;                   // 請求済金額
+        private int         m_RequestAmount0 = 0;               // 請求金額０
+        private int         m_RequestAmount1 = 0;               // 請求金額１
+        private int         m_RequestAmount2 = 0;               // 請求金額２
+        private int         m_RequestAmount3 = 0;               // 請求金額３
+        private int         m_RequestAmount4 = 0;               // 請求金額４
+        private int         m_RequestAmount5 = 0;               // 請求金額５
+        private int         m_RequestAmount6 = 0;               // 請求金額６
+        private int         m_UnclaimedAmount = 0;              // 請求残金額
+        private int         m_UnpaidAmount = 0;                 // 未入金金額
+        private int         m_TaxAmount = 0;                    // 消費税
+        private string      m_Note = "";                        // 備考
         private DateTime    m_EntryDate = DateTime.Now;         // 登録日付
         private DateTime    m_UpdateDate = DateTime.Now;        // 更新日付
         #endregion
@@ -40,87 +46,141 @@
         }
 
         /// <summary>
-        /// 工事番号
+        /// 本工事番号
         /// </summary>
-        public int ConstructionCode
+        public int MainConstructionCode
         {
-            get { return m_ConstructionCode; }
-            set { m_ConstructionCode = value; }
+            get { return m_MainConstructionCode; }
+            set { m_MainConstructionCode = value; }
         }
-
+        
         /// <summary>
-        /// 発注者区分
+        /// 工事件名
         /// </summary>
-        public int OrderersDivision
+        public string ConstructionName
         {
-            get { return m_OrderersDivision; }
-            set { m_OrderersDivision = value; }
+            get { return m_ConstructionName; }
+            set { m_ConstructionName = value; }
         }
 
         /// <summary>
-        /// 発注者コード
+        /// 請負金額
         /// </summary>
-        public int OrderersCode
+        public int ContractAmount
         {
-            get { return m_OrderersCode; }
-            set { m_OrderersCode = value; }
+            get { return m_ContractAmount; }
+            set { m_ContractAmount = value; }
         }
 
         /// <summary>
         /// 請求済金額
         /// </summary>
-        public int AmountPaid
+        public int PaidAmount
         {
-            get { return m_AmountPaid; }
-            set { m_AmountPaid = value; }
+            get { return m_PaidAmount; }
+            set { m_PaidAmount = value; }
         }
 
         /// <summary>
-        /// 請求済工事金額
+        /// 請求金額０
         /// </summary>
-        public int PricePaid
+        public int RequestAmount0
         {
-            get { return m_PricePaid; }
-            set { m_PricePaid = value; }
+            get { return m_RequestAmount0; }
+            set { m_RequestAmount0 = value; }
         }
 
         /// <summary>
-        /// 請求済消費税金額
+        /// 請求金額１
         /// </summary>
-        public int TaxPricePaid
+        public int RequestAmount1
         {
-            get { return m_TaxPricePaid; }
-            set { m_TaxPricePaid = value; }
+            get { return m_RequestAmount1; }
+            set { m_RequestAmount1 = value; }
         }
+        
+        /// <summary>
+        /// 請求金額２
+        /// </summary>
+        public int RequestAmount2
+        {
+            get { return m_RequestAmount2; }
+            set { m_RequestAmount2 = value; }
+        }
+        
+        /// <summary>
+        /// 請求金額３
+        /// </summary>
+        public int RequestAmount3
+        {
+            get { return m_RequestAmount3; }
+            set { m_RequestAmount3 = value; }
+        }
+        
+        /// <summary>
+        /// 請求金額４
+        /// </summary>
+        public int RequestAmount4
+        {
+            get { return m_RequestAmount4; }
+            set { m_RequestAmount4 = value; }
+        }
+        
+        /// <summary>
+        /// 請求金額５
+        /// </summary>
+        public int RequestAmount5
+        {
+            get { return m_RequestAmount5; }
+            set { m_RequestAmount5 = value; }
+        }
 
         /// <summary>
-        /// 請求残工事金額
+        /// 請求金額６
         /// </summary>
-        public int PriceBalance
+        public int RequestAmount6
         {
-            get { return m_PriceBalance; }
-            set { m_PriceBalance = value; }
+            get { return m_RequestAmount6; }
+            set { m_RequestAmount6 = value; }
         }
 
         /// <summary>
-        /// 請求残消費税金額
+        /// 請求残金額
         /// </summary>
-        public int TaxBalance
+        public int UnclaimedAmount
         {
-            get { return m_TaxBalance; }
-            set { m_TaxBalance = value; }
+            get { return m_UnclaimedAmount; }
+            set { m_UnclaimedAmount = value; }
         }
 
         /// <summary>
-        /// 未収金額
+        /// 未入金金額
         /// </summary>
-        public int AmountBlance
+        public int UnpaidAmount
         {
-            get { return m_AmountBlance; }
-            set { m_AmountBlance = value; }
+            get { return m_UnpaidAmount; }
+            set { m_UnpaidAmount = value; }
         }
 
         /// <summary>
+        /// 消費税
+        /// </summary>
+        public int TaxAmount
+        {
+            get { return m_TaxAmount; }
+            set { m_TaxAmount = value; }
+        }
+
+        /// <summary>
+        /// 備考
+        /// </summary>
+        public string Note
+        {
+            get { return m_Note; }
+            set { m_Note = value; }
+        }
+
+        /// <summary>
         /// 登録日付
         /// </summary>
         public DateTime EntryDate
Index: branches/src/ProcessManagement/ProcessManagement/DataModel/RequestDataDetail.cs
===================================================================
--- branches/src/ProcessManagement/ProcessManagement/DataModel/RequestDataDetail.cs	(revision 59)
+++ branches/src/ProcessManagement/ProcessManagement/DataModel/RequestDataDetail.cs	(revision 60)
@@ -7,20 +7,19 @@
 namespace ProcessManagement.DataModel
 {
     /// <summary>
-    /// 請求明細データ
+    /// 請求データ
     /// </summary>
     public class RequestDataDetail
     {
         #region メンバ変数
-        private int         m_RequestNo = 0;                // 請求No
-        private int         m_OrderNo = 0;                  // 受付番号
-        private int         m_ConstructionCode = 0;         // 工事番号
-        private int         m_ConstructionKind = 0;         // 工事区分
-        private int         m_BillPrice = 0;                // 請求金額
-        private int         m_TaxPrice = 0;                 // 消費税
-        private int         m_AmountBlance = 0;             // 未入金分
-        private DateTime    m_EntryDate = DateTime.Now;     // 登録年月日
-        private DateTime    m_UpdateDate = DateTime.Now;    // 更新年月日
+        private int         m_RequestNo = 0;                    // 請求No
+        private int         m_MainConstructionCode = 0;         // 本工事番号
+        private int         m_ConstructionCode = 0;             // 工事番号
+        private int         m_ConstructionKind = 0;             // 工事区分
+        private int         m_RequestAmount = 0;                // 請求金額
+        private int         m_TaxAmount = 0;                    // 消費税
+        private DateTime    m_EntryDate = DateTime.Now;         // 登録日付
+        private DateTime    m_UpdateDate = DateTime.Now;        // 更新日付
         #endregion
 
         #region コンストラクタ
@@ -28,7 +27,7 @@
 
         #region プロパティ
         /// <summary>
-        /// 請求No 
+        /// 請求No
         /// </summary>
         public int RequestNo
         {
@@ -37,13 +36,14 @@
         }
 
         /// <summary>
-        /// 受付番号
+        /// 本工事番号
         /// </summary>
-        public int OrderNo
+        public int MainConstructionCode
         {
-            get { return m_OrderNo; }
-            set { m_OrderNo = value; }
+            get { return m_MainConstructionCode; }
+            set { m_MainConstructionCode = value; }
         }
+        
 
         /// <summary>
         /// 工事番号
@@ -66,33 +66,24 @@
         /// <summary>
         /// 請求金額
         /// </summary>
-        public int BillPrice
+        public int RequestAmount
         {
-            get { return m_BillPrice; }
-            set { m_BillPrice = value; }
+            get { return m_RequestAmount; }
+            set { m_RequestAmount = value; }
         }
 
         /// <summary>
         /// 消費税
         /// </summary>
-        public int TaxPrice
+        public int TaxAmount
         {
-            get { return m_TaxPrice; }
-            set { m_TaxPrice = value; }
+            get { return m_TaxAmount; }
+            set { m_TaxAmount = value; }
         }
 
         /// <summary>
-        /// 未入金分
+        /// 登録日付
         /// </summary>
-        public int AmountBlance
-        {
-            get { return m_AmountBlance; }
-            set { m_AmountBlance = value; }
-        }
-
-        /// <summary>
-        /// 登録年月日
-        /// </summary>
         public DateTime EntryDate
         {
             get { return m_EntryDate; }
@@ -100,7 +91,7 @@
         }
 
         /// <summary>
-        /// 更新年月日
+        /// 更新日付
         /// </summary>
         public DateTime UpdateDate
         {
Index: branches/src/ProcessManagement/ProcessManagement/DataModel/RequestHead.cs
===================================================================
--- branches/src/ProcessManagement/ProcessManagement/DataModel/RequestHead.cs	(nonexistent)
+++ branches/src/ProcessManagement/ProcessManagement/DataModel/RequestHead.cs	(revision 60)
@@ -0,0 +1,193 @@
+﻿using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Text;
+using System.Threading.Tasks;
+
+namespace ProcessManagement.DataModel
+{
+    /// <summary>
+    /// 請求ヘッダ
+    /// </summary>
+    public class RequestHead
+    {
+        #region メンバ変数
+        private int         m_RequestNo = 0;                    // 請求No
+        private int         m_ReqConstructionCode = 0;          // 請求工事番号
+        private int         m_OrderNo = 0;                      // 受付番号
+        private int         m_RequestMonth = 0;                 // 請求月
+        private int         m_OrderersDivision = 0;             // 発注者区分
+        private int         m_OrderersCode = 0;                 // 発注者コード
+        private string      m_OrderersName = "";                // 発注者名
+        private string      m_ReqConstructionName = "";         // 請求工事件名
+        private int         m_RequestTotalAmount = 0;           // 請求金額合計
+        private int         m_RequestAmount = 0;                // 請求金額
+        private int         m_TaxAmount = 0;                    // 消費税
+        private int         m_UnpaidAmount = 0;                 // 未入金
+        private string      m_Note ="";                         // 備考
+        private int         m_AssignedFlg = 0;                  // 割当済フラグ
+        private int         m_InvoiceNo = 0;                    // 請求書No
+        private DateTime    m_EntryDate = DateTime.Now;         // 登録日付
+        private DateTime    m_UpdateDate = DateTime.Now;        // 更新日付
+        #endregion
+
+        #region コンストラクタ
+        #endregion
+
+        #region プロパティ
+        /// <summary>
+        /// 請求No
+        /// </summary>
+        public int RequestNo
+        {
+            get { return m_RequestNo; }
+            set { m_RequestNo = value; }
+        }
+
+        /// <summary>
+        /// 請求工事番号
+        /// </summary>
+        public int ReqConstructionCode
+        {
+            get { return m_ReqConstructionCode; }
+            set { m_ReqConstructionCode = value; }
+        }
+
+        /// <summary>
+        /// 受付番号
+        /// </summary>
+        public int OrderNo
+        {
+            get { return m_OrderNo; }
+            set { m_OrderNo = value; }
+        }
+
+        /// <summary>
+        /// 請求月
+        /// </summary>
+        public int RequestMonth
+        {
+            get { return m_RequestMonth; }
+            set { m_RequestMonth = value; }
+        }
+
+        /// <summary>
+        /// 発注者区分
+        /// </summary>
+        public int OrderersDivision
+        {
+            get { return m_OrderersDivision; }
+            set { m_OrderersDivision = value; }
+        }
+
+        /// <summary>
+        /// 発注者コード
+        /// </summary>
+        public int OrderersCode
+        {
+            get { return m_OrderersCode; }
+            set { m_OrderersCode = value; }
+        }
+
+        /// <summary>
+        /// 発注者名
+        /// </summary>
+        public string OrderersName
+        {
+            get { return m_OrderersName; }
+            set { m_OrderersName = value; }
+        }
+
+        /// <summary>
+        /// 請求工事件名
+        /// </summary>
+        public string ReqConstructionName
+        {
+            get { return m_ReqConstructionName; }
+            set { m_ReqConstructionName = value; }
+        }
+        
+        /// <summary>
+        /// 請求金額合計
+        /// </summary>
+        public int RequestTotalAmount
+        {
+            get { return m_RequestTotalAmount; }
+            set { m_RequestTotalAmount = value; }
+        }
+
+        /// <summary>
+        /// 請求金額
+        /// </summary>
+        public int RequestAmount
+        {
+            get { return m_RequestAmount; }
+            set { m_RequestAmount = value; }
+        }
+
+        /// <summary>
+        /// 消費税
+        /// </summary>
+        public int TaxAmount
+        {
+            get { return m_TaxAmount; }
+            set { m_TaxAmount = value; }
+        }
+
+        /// <summary>
+        /// 未入金
+        /// </summary>
+        public int UnpaidAmount
+        {
+            get { return m_UnpaidAmount; }
+            set { m_UnpaidAmount = value; }
+        }
+
+        /// <summary>
+        /// 備考
+        /// </summary>
+        public string Note
+        {
+            get { return m_Note; }
+            set { m_Note = value; }
+        }
+
+        /// <summary>
+        /// 割当済フラグ
+        /// </summary>
+        public int AssignedFlg
+        {
+            get { return m_AssignedFlg; }
+            set { m_AssignedFlg = value; }
+        }
+
+        /// <summary>
+        /// 請求書No
+        /// </summary>
+        public int InvoiceNo
+        {
+            get { return m_InvoiceNo; }
+            set { m_InvoiceNo = value; }
+        }
+
+        /// <summary>
+        /// 登録日付
+        /// </summary>
+        public DateTime EntryDate
+        {
+            get { return m_EntryDate; }
+            set { m_EntryDate = value; }
+        }
+
+        /// <summary>
+        /// 更新日付
+        /// </summary>
+        public DateTime UpdateDate
+        {
+            get { return m_UpdateDate; }
+            set { m_UpdateDate = value; }
+        }
+        #endregion
+
+    }
+}
Index: branches/src/ProcessManagement/ProcessManagement/Forms/DataEntry/ApprovalScreen/FrmApprovalScreen.cs
===================================================================
--- branches/src/ProcessManagement/ProcessManagement/Forms/DataEntry/ApprovalScreen/FrmApprovalScreen.cs	(revision 59)
+++ branches/src/ProcessManagement/ProcessManagement/Forms/DataEntry/ApprovalScreen/FrmApprovalScreen.cs	(revision 60)
@@ -628,6 +628,10 @@
                 case (int)ClsExcute.ApprovalListNo.PurchaseOrderEntryApproval:              // 4:���������F
                     iNextProcessNo = (int)ClsExcute.ProcessExecuteNo.PurchaseOrderEntry;
                     break;
+                case (int)ClsExcute.ApprovalListNo.OrderBillingApproval:                    // 5:���������F
+                    iNextProcessNo = (int)ClsExcute.ProcessExecuteNo.RequestInput;
+                    break;
+
             }
             if (iNextProcessNo == 0) return;
 
@@ -648,6 +652,7 @@
                 case (int)ClsExcute.ApprovalListNo.ConstructionBudgetApproval:              // 3:�H���\�Z�����F
                     break;
                 case (int)ClsExcute.ApprovalListNo.PurchaseOrderEntryApproval:              // 4:���������F
+                case (int)ClsExcute.ApprovalListNo.OrderBillingApproval:                    // 5:���������F
                     ClsExcute.ProcControlPara[NowPoint].BoolExecParameter.Add(true);        // ----- ���ڕ\���t���O
                     break;
             }
Index: branches/src/ProcessManagement/ProcessManagement/Forms/DataEntry/ConstructionBaseInfo/DataChange.cs
===================================================================
--- branches/src/ProcessManagement/ProcessManagement/Forms/DataEntry/ConstructionBaseInfo/DataChange.cs	(revision 59)
+++ branches/src/ProcessManagement/ProcessManagement/Forms/DataEntry/ConstructionBaseInfo/DataChange.cs	(revision 60)
@@ -46,9 +46,9 @@
                 int iCode1 = CommonDefine.ProjectsStatus.First(x => x.Value.Equals("�� �� ��")).Key;
 
                 string strSQL = "SELECT SUM(ORDERSDECISIONPRICE) FROM CONSTRUCTIONBASEINFO";
-                strSQL += string.Format(" WHERE (TRUNCATE(CONSTRUCTIONCODE / 100) = {0})", (int)(m_ConstructionCode / 100));
+                strSQL += string.Format(" WHERE (TRUNCATE(CONSTRUCTIONCODE / 100,0) = {0})", (int)(m_ConstructionCode / 100));
                 strSQL += string.Format(" AND CONSTRUCTIONSTATUSFLG != {0}", iCode1);
-                strSQL += " GROUP BY TRUNCATE(CONSTRUCTIONCODE / 100)";
+                strSQL += " GROUP BY TRUNCATE(CONSTRUCTIONCODE / 100,0)";
 
                 ArrayList Arlist = new ArrayList();
                 if (!cbiDB.ExecuteReader(strSQL, ref Arlist, false)) return 0;
Index: branches/src/ProcessManagement/ProcessManagement/Forms/DataEntry/ConstructionLedger/FrmConstructionLedgerAuxiliary.cs
===================================================================
--- branches/src/ProcessManagement/ProcessManagement/Forms/DataEntry/ConstructionLedger/FrmConstructionLedgerAuxiliary.cs	(revision 59)
+++ branches/src/ProcessManagement/ProcessManagement/Forms/DataEntry/ConstructionLedger/FrmConstructionLedgerAuxiliary.cs	(revision 60)
@@ -717,7 +717,7 @@
                     string strSQL = "SELECT SUM(A.ORDERSDECISIONPRICE) FROM CONSTRUCTIONBASEINFO A";
                     strSQL += " WHERE A.CONSTRUCTIONCODE IN";
                     strSQL += " (SELECT B.CONSTRUCTIONCODE FROM PROCESSAPPROVAL B";
-                    strSQL += string.Format(" WHERE  TRUNCATE(B.CONSTRUCTIONCODE / 100) = {0}", CommonMotions.cnvTruncate(m_ConstructionCode / 100));
+                    strSQL += string.Format(" WHERE  TRUNCATE(B.CONSTRUCTIONCODE / 100,0) = {0}", CommonMotions.cnvTruncate(m_ConstructionCode / 100));
                     strSQL += string.Format(" AND B.APPROVALCODE = {0}", (int)ClsExcute.ApprovalListNo.ConstructionBudgetApproval);
                     strSQL += string.Format(" AND B.ORDERNO = {0}", CommonDefine.s_Default_OrderNo);
                     strSQL += string.Format(" AND B.SEQNO = 1 AND B.APPROVALSTATUS = {0})", (int)CommonDefine.ApprovalStatus.Approval);
Index: branches/src/ProcessManagement/ProcessManagement/Forms/DataEntry/ConstructionLedgerList/FrmConstructionLedgerListAuxiliary.cs
===================================================================
--- branches/src/ProcessManagement/ProcessManagement/Forms/DataEntry/ConstructionLedgerList/FrmConstructionLedgerListAuxiliary.cs	(revision 59)
+++ branches/src/ProcessManagement/ProcessManagement/Forms/DataEntry/ConstructionLedgerList/FrmConstructionLedgerListAuxiliary.cs	(revision 60)
@@ -980,7 +980,7 @@
                 strSQL += " AND B.PERSONCODE = C.CONSTRUCTIONPERSONCODE";
                 strSQL += " AND D.CONSTRUCTIONCODE = C.CONSTRUCTIONCODE";
 
-                strSQL += " GROUP BY A.DEPARTMENTCODE, A.DEPARTMENTSTRING, A.DISPLAYORDER))";
+                strSQL += " GROUP BY A.DEPARTMENTCODE, A.DEPARTMENTSTRING, A.DISPLAYORDER) AS TMP )";
 
                 // 16�����胊�t�H�[���͌_��Ј����ǉ�����
                 if (numUDConstPro.Value < 17 && DepartmentCode == 9)
Index: branches/src/ProcessManagement/ProcessManagement/Forms/DataEntry/DepExpenssList/FrmDepExpenssListAuxiliary.cs
===================================================================
--- branches/src/ProcessManagement/ProcessManagement/Forms/DataEntry/DepExpenssList/FrmDepExpenssListAuxiliary.cs	(revision 59)
+++ branches/src/ProcessManagement/ProcessManagement/Forms/DataEntry/DepExpenssList/FrmDepExpenssListAuxiliary.cs	(revision 60)
@@ -987,7 +987,7 @@
                 strSQL += " AND A.DEPARTMENTCODE = B.DEPARTMENTCODE";
                 strSQL += " AND (B.PERSONCODE = C.CONSTRUCTIONPERSONCODE OR B.PERSONCODE = C.CONSTRUCTIONINSTRUCTOR OR B.PERSONCODE = C.CONSTRSUBPERSONCODE)";
                 strSQL += " AND D.CONSTRUCTIONCODE = C.CONSTRUCTIONCODE";
-                strSQL += " GROUP BY A.DEPARTMENTCODE, A.DEPARTMENTSTRING, A.DISPLAYORDER))";
+                strSQL += " GROUP BY A.DEPARTMENTCODE, A.DEPARTMENTSTRING, A.DISPLAYORDER) AS TMP )";
 
                 // 16�����胊�t�H�[���͌_��Ј����ǉ�����
                 if (numUDConstPro.Value <= 16 && DepartmentCode != 9)
Index: branches/src/ProcessManagement/ProcessManagement/Forms/DataEntry/Request/FrmRegField.cs
===================================================================
--- branches/src/ProcessManagement/ProcessManagement/Forms/DataEntry/Request/FrmRegField.cs	(revision 59)
+++ branches/src/ProcessManagement/ProcessManagement/Forms/DataEntry/Request/FrmRegField.cs	(revision 60)
@@ -123,7 +123,9 @@
                 // 現場選択画面を初期化
                 FrmConstructionDiag frmConstructionDiag = new FrmConstructionDiag();
                 frmConstructionDiag.PersonCode = CommonMotions.LoginUserData.PersonCode;
-                frmConstructionDiag.PersonCharge = (int)FrmConstructionDiag.PersonChargePoint.Construction; //関連工事のみ表示する
+                //frmConstructionDiag.PersonCharge = (int)FrmConstructionDiag.PersonChargePoint.Construction; //関連工事のみ表示する
+                frmConstructionDiag.PersonCharge = m_ConstructionFieldNameHeader.PersonCharge;
+                frmConstructionDiag.SelectType = (int)FrmConstructionDiag.SelectConstructionType.Ongoing;
 
                 // 現場選択画面表示
                 frmConstructionDiag.ShowDialog();
Index: branches/src/ProcessManagement/ProcessManagement/Forms/DataEntry/Request/FrmSelectRequest.cs
===================================================================
--- branches/src/ProcessManagement/ProcessManagement/Forms/DataEntry/Request/FrmSelectRequest.cs	(revision 59)
+++ branches/src/ProcessManagement/ProcessManagement/Forms/DataEntry/Request/FrmSelectRequest.cs	(revision 60)
@@ -220,6 +220,11 @@
                 {
                     for(int Index = 0; Index < dgv.Rows.Count; Index++)
                     {
+                        if (dgv[(int)DispColumn.RequestNo, Index].Value == null)
+                        {
+                            break;
+                        }
+
                         DataGridViewCheckBoxCell cb = (DataGridViewCheckBoxCell)dgv.Rows[Index].Cells[(int)DispColumn.Select];
                         if ((bool)cb.Value == true)
                         {
@@ -426,7 +431,7 @@
         // 発注者追加：現場リスト表示
         public bool DispFieldName(int OrderDiv, int OrderCode)
         {
-            IORequestTotalData IoRtd = new IORequestTotalData();
+            IORequestHead IoRtd = new IORequestHead();
             ArrayList arData = new ArrayList();
             StringBuilder sql;
             DataGridView dgv = this.dgvmaster;
@@ -435,62 +440,50 @@
             {
                 // SQL作成
                 sql = new StringBuilder();
-                sql.AppendLine("select  ");
-                sql.AppendLine("Rtd.RequestNo, ");                              // 請求合計データ       ：請求No.
-                sql.AppendLine("Rtd.OrderNo, ");                                //                      ：受付番号
-                sql.AppendLine("Rtd.OrderersDivision, ");                       //                      ：発注者区分
-                sql.AppendLine("Rtd.OrderersCode, ");                           //                      ：発注者コード
-                sql.AppendLine("DATE_FORMAT(Rtd.BillCreationDate, '%Y/%m/%d') as BillCreationDate, "); //：請求書作成日
-                sql.AppendLine("Rtd.BillTotalPrice, ");                              //                 ：請求書合計金額
-                sql.AppendLine("Rtd.BillPrice, ");                              //                      ：請求金額
-                sql.AppendLine("Rtd.TaxPrice, ");                               //                      ：消費税
+                sql.Append("SELECT");
+                sql.Append(" ReqHead.RequestNo");                            // 請求No
+                sql.Append(",0");                                            // 受付番号（廃止予定）
+                sql.Append(",ReqHead.OrderersDivision");                    // 発注者区分
+                sql.Append(",ReqHead.OrderersCode");                        // 発注者コード
+                sql.Append(",DATE_FORMAT(InvData.CretateDate, '%Y/%m/%d') as CreateDate "); // 請求書作成日
+                sql.Append(",ReqHead.RequestTotalAmount");                              // 請求書合計金額
+                sql.Append(",ReqHead.RequestAmount");                                   // 請求金額
+                sql.Append(",ReqHead.TaxAmount");                                       // 消費税
+                sql.Append(",ReqHead.ReqConstructionName");                             // 請求件名
+                sql.Append(",Prsn.PersonName ");                                        // 担当者名
+                sql.Append(",Prsn.DepartmentCode ");                                    // 所属部署コード
 
-                sql.AppendLine("CbiD.DetailString, ");                          // 工事基本情報明細     ：明細内容
+                sql.Append(" FROM RequestHead AS ReqHead ");
+                sql.Append(" INNER JOIN InvoiceData AS InvData ON ");
+                sql.Append(" ReqHead.InvoiceNo = InvData.InvoiceNo ");
+                sql.Append(" INNER JOIN ConstructionBaseInfo AS Info ON ");
+                sql.Append(" ReqHead.ReqConstructionCode = Info.ConstructionCode ");
+                sql.Append(" INNER JOIN PersonInChargeMaster AS Prsn ON ");
+                sql.Append(" Info.ConstructionPersonCode = Prsn.PersonCode ");
 
-                sql.AppendLine("PicM.PersonName, ");                            // 担当者マスタ         ：担当者名
-                sql.AppendLine("PicM.DepartmentCode ");                         //                      ：所属部署コード
+                sql.Append(" WHERE ");
+                sql.AppendFormat(" ReqHead.OrderersDivision = {0} ", OrderDiv);
+                sql.AppendFormat(" AND ReqHead.OrderersCode = {0} ", OrderCode);
+                sql.Append(" AND ReqHead.AssignedFlg = 0 ");
+                sql.AppendFormat(" AND EXISTS ( SELECT * FROM PersonDepartmentMaster AS PsnDep WHERE PsnDep.PersonCode = {0} AND Prsn.DepartmentCode = PsnDep.DepartmentCode ) ", CommonMotions.LoginUserData.PersonCode);
+                sql.Append(" ORDER BY ReqHead.RequestNo ");
 
-                sql.AppendLine("from RequestTotalData as Rtd ");
-                sql.AppendLine("left join ConstructionBaseInfoDetail as CbiD on Rtd.RequestNo = CbiD.ConstructionCode and CbiD.DetailNo = 2 ");
-                sql.AppendLine("left join ");
-                sql.AppendLine("    (ConstructionBaseInfo as Cbi left join ");
-                sql.AppendLine("        (PersonInChargeMaster as PicM left join ApprovalMaster as Am on PicM.DepartmentCode = Am.DepartmentCode and Am.ApprovalCode = 3 and Am.ApprovalAuthority = 1) ");
-                sql.AppendLine("    on Cbi.ConstructionPersonCode = PicM.PersonCode) ");
-                sql.AppendLine("on Rtd.RequestNo = Cbi.ConstructionCode ");
-
-                sql.AppendFormat("where Rtd.OrderersDivision = {0} and Rtd.OrderersCode = {1} and Rtd.AssignedFlg = 0 ", OrderDiv, OrderCode);
-                // 現場追加の場合はログインユーザでフィルタ
-                if (m_mode == OpenMode.AddFld)
-                {
-                    sql.AppendFormat("and PicM.PersonCode = {0} ", CommonMotions.LoginUserData.PersonCode);
-                }
-
-                sql.AppendLine("group by ");
-                sql.AppendLine("Rtd.RequestNo, ");
-                sql.AppendLine("Rtd.OrderNo, ");
-                sql.AppendLine("Rtd.OrderersDivision, ");
-                sql.AppendLine("Rtd.OrderersCode, ");
-                sql.AppendLine("Rtd.BillCreationDate, ");
-                sql.AppendLine("Rtd.BillTotalPrice, ");
-                sql.AppendLine("Rtd.BillPrice, ");
-                sql.AppendLine("Rtd.TaxPrice, ");
-                sql.AppendLine("CbiD.DetailString, ");
-                sql.AppendLine("PicM.PersonName, ");
-                sql.AppendLine("PicM.DepartmentCode ");
-
-                sql.AppendLine("order by Rtd.RequestNo, Rtd.OrderNo ");
-
                 // データ取得
                 if (!IoRtd.ExecuteReader(sql.ToString(), ref arData)) return false;
 
                 int LineCnt = 0;
-                
+
                 // グリッドの行を一旦初期化
                 dgv.Rows.Clear();
+
+                dgv.Rows.Add(20);
+
                 foreach (object[] work in arData)
                 {
-                    dgv.Rows.Add();
-
+                    if (LineCnt >= 20)
+                    {
+                        dgv.Rows.Add();
+                    }
                     dgv.Rows[LineCnt].Cells[(int)DispColumn.No].Value = LineCnt + 1;
                     dgv.Rows[LineCnt].Cells[(int)DispColumn.RequestNo].Value = CommonMotions.cnvInt(work[(int)ClickGetData.RequestNo]);
                     dgv.Rows[LineCnt].Cells[(int)DispColumn.OrderNo].Value = CommonMotions.cnvInt(work[(int)ClickGetData.OrderNo]);
Index: branches/src/ProcessManagement/ProcessManagement/Forms/DataEntry/Request/RequestEntry/FrmEntryReqSelOrderer.Designer.cs
===================================================================
--- branches/src/ProcessManagement/ProcessManagement/Forms/DataEntry/Request/RequestEntry/FrmEntryReqSelOrderer.Designer.cs	(nonexistent)
+++ branches/src/ProcessManagement/ProcessManagement/Forms/DataEntry/Request/RequestEntry/FrmEntryReqSelOrderer.Designer.cs	(revision 60)
@@ -0,0 +1,242 @@
+﻿namespace ProcessManagement.Forms.DataEntry
+{
+    partial class FrmEntryReqSelOrderer
+    {
+        /// <summary>
+        /// Required designer variable.
+        /// </summary>
+        private System.ComponentModel.IContainer components = null;
+
+        /// <summary>
+        /// Clean up any resources being used.
+        /// </summary>
+        /// <param name="disposing">true if managed resources should be disposed; otherwise, false.</param>
+        protected override void Dispose(bool disposing)
+        {
+            if (disposing && (components != null))
+            {
+                components.Dispose();
+            }
+            base.Dispose(disposing);
+        }
+
+        #region Windows Form Designer generated code
+
+        /// <summary>
+        /// Required method for Designer support - do not modify
+        /// the contents of this method with the code editor.
+        /// </summary>
+        private void InitializeComponent()
+        {
+            System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle1 = new System.Windows.Forms.DataGridViewCellStyle();
+            System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle2 = new System.Windows.Forms.DataGridViewCellStyle();
+            System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle3 = new System.Windows.Forms.DataGridViewCellStyle();
+            System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle4 = new System.Windows.Forms.DataGridViewCellStyle();
+            this.label4 = new System.Windows.Forms.Label();
+            this.cbReqMonth = new System.Windows.Forms.ComboBox();
+            this.dgv1 = new System.Windows.Forms.DataGridView();
+            this.btnSelRequest = new System.Windows.Forms.Button();
+            this.btnEnd = new System.Windows.Forms.Button();
+            this.col1 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.col2 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.col3 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.col4 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.col5 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.col6 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.col7 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            ((System.ComponentModel.ISupportInitialize)(this.dgv1)).BeginInit();
+            this.SuspendLayout();
+            // 
+            // label4
+            // 
+            this.label4.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(255)))), ((int)(((byte)(255)))), ((int)(((byte)(128)))));
+            this.label4.BorderStyle = System.Windows.Forms.BorderStyle.Fixed3D;
+            this.label4.CausesValidation = false;
+            this.label4.Font = new System.Drawing.Font("ＭＳ 明朝", 11.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(128)));
+            this.label4.Location = new System.Drawing.Point(12, 9);
+            this.label4.Name = "label4";
+            this.label4.Size = new System.Drawing.Size(100, 23);
+            this.label4.TabIndex = 22;
+            this.label4.Text = "請求月";
+            this.label4.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
+            // 
+            // cbReqMonth
+            // 
+            this.cbReqMonth.BackColor = System.Drawing.Color.White;
+            this.cbReqMonth.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
+            this.cbReqMonth.FormattingEnabled = true;
+            this.cbReqMonth.Location = new System.Drawing.Point(118, 9);
+            this.cbReqMonth.Name = "cbReqMonth";
+            this.cbReqMonth.Size = new System.Drawing.Size(109, 23);
+            this.cbReqMonth.TabIndex = 23;
+            this.cbReqMonth.SelectedIndexChanged += new System.EventHandler(this.cbReqMonth_SelectedIndexChanged);
+            // 
+            // dgv1
+            // 
+            this.dgv1.AllowUserToAddRows = false;
+            this.dgv1.AllowUserToDeleteRows = false;
+            this.dgv1.AllowUserToResizeColumns = false;
+            this.dgv1.AllowUserToResizeRows = false;
+            dataGridViewCellStyle1.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleCenter;
+            dataGridViewCellStyle1.BackColor = System.Drawing.SystemColors.Control;
+            dataGridViewCellStyle1.Font = new System.Drawing.Font("ＭＳ 明朝", 11.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(128)));
+            dataGridViewCellStyle1.ForeColor = System.Drawing.SystemColors.WindowText;
+            dataGridViewCellStyle1.SelectionBackColor = System.Drawing.SystemColors.Highlight;
+            dataGridViewCellStyle1.SelectionForeColor = System.Drawing.SystemColors.HighlightText;
+            dataGridViewCellStyle1.WrapMode = System.Windows.Forms.DataGridViewTriState.True;
+            this.dgv1.ColumnHeadersDefaultCellStyle = dataGridViewCellStyle1;
+            this.dgv1.ColumnHeadersHeight = 28;
+            this.dgv1.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.DisableResizing;
+            this.dgv1.Columns.AddRange(new System.Windows.Forms.DataGridViewColumn[] {
+            this.col1,
+            this.col2,
+            this.col3,
+            this.col4,
+            this.col5,
+            this.col6,
+            this.col7});
+            this.dgv1.Location = new System.Drawing.Point(12, 42);
+            this.dgv1.MultiSelect = false;
+            this.dgv1.Name = "dgv1";
+            this.dgv1.RowHeadersVisible = false;
+            this.dgv1.RowTemplate.Height = 21;
+            this.dgv1.SelectionMode = System.Windows.Forms.DataGridViewSelectionMode.FullRowSelect;
+            this.dgv1.Size = new System.Drawing.Size(661, 272);
+            this.dgv1.TabIndex = 24;
+            this.dgv1.SelectionChanged += new System.EventHandler(this.dgv1_SelectionChanged);
+            // 
+            // btnSelRequest
+            // 
+            this.btnSelRequest.BackColor = System.Drawing.Color.Blue;
+            this.btnSelRequest.Cursor = System.Windows.Forms.Cursors.Default;
+            this.btnSelRequest.Enabled = false;
+            this.btnSelRequest.Font = new System.Drawing.Font("ＭＳ 明朝", 11.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(128)));
+            this.btnSelRequest.ForeColor = System.Drawing.Color.White;
+            this.btnSelRequest.Location = new System.Drawing.Point(427, 322);
+            this.btnSelRequest.Name = "btnSelRequest";
+            this.btnSelRequest.Size = new System.Drawing.Size(120, 30);
+            this.btnSelRequest.TabIndex = 25;
+            this.btnSelRequest.Text = "請求選択";
+            this.btnSelRequest.UseVisualStyleBackColor = false;
+            this.btnSelRequest.Click += new System.EventHandler(this.btnSelRequest_Click);
+            // 
+            // btnEnd
+            // 
+            this.btnEnd.BackColor = System.Drawing.Color.Red;
+            this.btnEnd.Cursor = System.Windows.Forms.Cursors.Default;
+            this.btnEnd.Font = new System.Drawing.Font("ＭＳ 明朝", 11.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(128)));
+            this.btnEnd.ForeColor = System.Drawing.Color.Black;
+            this.btnEnd.Location = new System.Drawing.Point(553, 322);
+            this.btnEnd.Name = "btnEnd";
+            this.btnEnd.Size = new System.Drawing.Size(120, 30);
+            this.btnEnd.TabIndex = 26;
+            this.btnEnd.Text = "終　了";
+            this.btnEnd.UseVisualStyleBackColor = false;
+            this.btnEnd.Click += new System.EventHandler(this.btnEnd_Click);
+            // 
+            // col1
+            // 
+            this.col1.HeaderText = "請求先";
+            this.col1.Name = "col1";
+            this.col1.ReadOnly = true;
+            this.col1.Resizable = System.Windows.Forms.DataGridViewTriState.False;
+            this.col1.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable;
+            this.col1.Width = 320;
+            // 
+            // col2
+            // 
+            dataGridViewCellStyle2.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleRight;
+            this.col2.DefaultCellStyle = dataGridViewCellStyle2;
+            this.col2.HeaderText = "請求済";
+            this.col2.Name = "col2";
+            this.col2.ReadOnly = true;
+            this.col2.Resizable = System.Windows.Forms.DataGridViewTriState.False;
+            this.col2.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable;
+            this.col2.Width = 80;
+            // 
+            // col3
+            // 
+            dataGridViewCellStyle3.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleRight;
+            this.col3.DefaultCellStyle = dataGridViewCellStyle3;
+            this.col3.HeaderText = "未請求";
+            this.col3.Name = "col3";
+            this.col3.ReadOnly = true;
+            this.col3.Resizable = System.Windows.Forms.DataGridViewTriState.False;
+            this.col3.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable;
+            this.col3.Width = 80;
+            // 
+            // col4
+            // 
+            dataGridViewCellStyle4.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleRight;
+            this.col4.DefaultCellStyle = dataGridViewCellStyle4;
+            this.col4.HeaderText = "総額";
+            this.col4.Name = "col4";
+            this.col4.ReadOnly = true;
+            this.col4.Resizable = System.Windows.Forms.DataGridViewTriState.False;
+            this.col4.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable;
+            this.col4.Width = 160;
+            // 
+            // col5
+            // 
+            this.col5.HeaderText = "OrderersDivision";
+            this.col5.Name = "col5";
+            this.col5.ReadOnly = true;
+            this.col5.Resizable = System.Windows.Forms.DataGridViewTriState.False;
+            this.col5.Visible = false;
+            // 
+            // col6
+            // 
+            this.col6.HeaderText = "OrderersCode";
+            this.col6.Name = "col6";
+            this.col6.ReadOnly = true;
+            this.col6.Resizable = System.Windows.Forms.DataGridViewTriState.False;
+            this.col6.Visible = false;
+            // 
+            // col7
+            // 
+            this.col7.HeaderText = "OrderersName";
+            this.col7.Name = "col7";
+            this.col7.ReadOnly = true;
+            this.col7.Resizable = System.Windows.Forms.DataGridViewTriState.False;
+            this.col7.Visible = false;
+            // 
+            // FrmEntryReqSelOrderer
+            // 
+            this.AutoScaleDimensions = new System.Drawing.SizeF(9F, 15F);
+            this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
+            this.BackColor = System.Drawing.Color.Black;
+            this.ClientSize = new System.Drawing.Size(684, 362);
+            this.Controls.Add(this.btnEnd);
+            this.Controls.Add(this.btnSelRequest);
+            this.Controls.Add(this.dgv1);
+            this.Controls.Add(this.cbReqMonth);
+            this.Controls.Add(this.label4);
+            this.Cursor = System.Windows.Forms.Cursors.Default;
+            this.Font = new System.Drawing.Font("ＭＳ 明朝", 11.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(128)));
+            this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedSingle;
+            this.Margin = new System.Windows.Forms.Padding(4);
+            this.Name = "FrmEntryReqSelOrderer";
+            this.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen;
+            this.Text = "請求書作成";
+            this.Load += new System.EventHandler(this.FrmEntryReqSelOrderer_Load);
+            ((System.ComponentModel.ISupportInitialize)(this.dgv1)).EndInit();
+            this.ResumeLayout(false);
+
+        }
+
+        #endregion
+
+        private System.Windows.Forms.Label label4;
+        private System.Windows.Forms.ComboBox cbReqMonth;
+        private System.Windows.Forms.DataGridView dgv1;
+        private System.Windows.Forms.Button btnSelRequest;
+        private System.Windows.Forms.Button btnEnd;
+        private System.Windows.Forms.DataGridViewTextBoxColumn col1;
+        private System.Windows.Forms.DataGridViewTextBoxColumn col2;
+        private System.Windows.Forms.DataGridViewTextBoxColumn col3;
+        private System.Windows.Forms.DataGridViewTextBoxColumn col4;
+        private System.Windows.Forms.DataGridViewTextBoxColumn col5;
+        private System.Windows.Forms.DataGridViewTextBoxColumn col6;
+        private System.Windows.Forms.DataGridViewTextBoxColumn col7;
+    }
+}
\ No newline at end of file
Index: branches/src/ProcessManagement/ProcessManagement/Forms/DataEntry/Request/RequestEntry/FrmEntryReqSelOrderer.cs
===================================================================
--- branches/src/ProcessManagement/ProcessManagement/Forms/DataEntry/Request/RequestEntry/FrmEntryReqSelOrderer.cs	(nonexistent)
+++ branches/src/ProcessManagement/ProcessManagement/Forms/DataEntry/Request/RequestEntry/FrmEntryReqSelOrderer.cs	(revision 60)
@@ -0,0 +1,512 @@
+﻿using System;
+using System.Collections.Generic;
+using System.ComponentModel;
+using System.Data;
+using System.Drawing;
+using System.Linq;
+using System.Text;
+using System.Threading.Tasks;
+using System.Windows.Forms;
+
+using ProcessManagement.Common;
+using ProcessManagement.DataModel;
+using ProcessManagement.DB;
+using ProcessManagement.DB.IOAccess;
+using ProcessManagement.Forms.ControlsAction;
+using ProcessManagement.Forms.SubForms;
+
+namespace ProcessManagement.Forms.DataEntry
+{
+    public partial class FrmEntryReqSelOrderer : Form
+    {
+        #region 使用定義
+        //log4netログを使用する
+        private static readonly log4net.ILog logger = log4net.LogManager.GetLogger(System.Reflection.MethodBase.GetCurrentMethod().DeclaringType);
+        #endregion
+
+        #region 変数
+
+        #region ClsOrdererReqDataクラス定義
+        /// <summary>
+        /// 発注者請求
+        /// </summary>
+        private class ClsOrdererReqData
+        {
+            #region ClsOrdererReqData変数
+            private int m_nOrderersDivision = 0;        // 発注者区分
+            private int m_nOrderersCode = 0;            // 発注者コード
+            private string m_strOrderersName = "";      // 発注者名
+
+            private int m_nDoneCount = 0;               // 請求済数
+            private int m_nUndoneCount = 0;             // 未請求数
+
+            private int m_nTotalAmount = 0;             // 総額
+
+            private List<RequestHead> m_lstReqHead = new List<RequestHead>();       // 請求ヘッダリスト
+
+            #endregion
+
+            #region ClsOrdererReqDataプロパティ
+            public int OrderersDivision
+            {
+                get { return m_nOrderersDivision; }
+            }
+            public int OrderersCode
+            {
+                get { return m_nOrderersCode; }
+            }
+            public string OrderersName
+            {
+                get { return m_strOrderersName; }
+            }
+            public int DoneCount
+            {
+                get { return m_nDoneCount; }
+            }
+            public int UndoneCount
+            {
+                get { return m_nUndoneCount; }
+            }
+            public int TotalAmount
+            {
+                get { return m_nTotalAmount; }
+            }
+
+            public List<RequestHead> ListReqHead
+            {
+                get { return m_lstReqHead; }
+            }
+            #endregion
+
+            #region ClsOrdererReqDataコンストラクタ
+            /// <summary>
+            /// コンストラクタ
+            /// </summary>
+            /// <param name="nOrderersDivision"></param>
+            /// <param name="nOrderersCode"></param>
+            /// <param name="strOrderersName"></param>
+            public ClsOrdererReqData(int nOrderersDivision, int nOrderersCode, string strOrderersName)
+            {
+                m_nOrderersDivision = nOrderersDivision;
+                m_nOrderersCode = nOrderersCode;
+                m_strOrderersName = strOrderersName.Trim();
+            }
+            #endregion
+
+            #region ClsOrdererReqData キー文字列の取得
+            public string GetKeyString()
+            {
+                return GetKeyString(m_nOrderersDivision, m_nOrderersCode, m_strOrderersName);
+            }
+            #endregion
+
+            #region ClsOrdererReqData キー文字列の取得(static)
+            public static string GetKeyString(int nOrderersDivision, int nOrderersCode, string strOrderersName)
+            {
+                string ret = "";
+
+                ret = nOrderersDivision.ToString("D5");
+                ret += "_";
+                ret += nOrderersCode.ToString("D5");
+                ret += "_";
+                ret += strOrderersName;
+
+                return ret;
+            }
+            #endregion
+
+            #region ClsOrdererReqData 請求ヘッダの追加
+            public void AddReqHead(RequestHead ReqHead)
+            {
+                if (ReqHead.InvoiceNo > 0)
+                {
+                    m_nDoneCount++;
+                }
+                else
+                {
+                    m_nUndoneCount++;
+                }
+
+                m_nTotalAmount += ReqHead.RequestTotalAmount;
+
+                m_lstReqHead.Add(ReqHead);
+                return;
+            }
+            #endregion
+
+        }
+        #endregion
+
+        // 発注者請求データハッシュテーブル
+        Dictionary<int, Dictionary<string, ClsOrdererReqData>> m_dicOrdererReqData = new Dictionary<int, Dictionary<string, ClsOrdererReqData>>();
+
+        #endregion
+
+        #region コンストラクタ
+        public FrmEntryReqSelOrderer()
+        {
+            InitializeComponent();
+        }
+        #endregion
+
+        #region フォームのロード
+        /// <summary>
+        /// フォームのロード
+        /// </summary>
+        /// <param name="sender"></param>
+        /// <param name="e"></param>
+        private void FrmEntryReqSelOrderer_Load(object sender, EventArgs e)
+        {
+            // データグリッドビュの設定
+            dgv1.EnableHeadersVisualStyles = false;
+            dgv1.AutoGenerateColumns = false;
+            dgv1.ColumnHeadersHeight = 28;
+            dgv1.ColumnHeadersDefaultCellStyle.Alignment = DataGridViewContentAlignment.MiddleCenter;
+            dgv1.AllowUserToAddRows = false;
+            dgv1.RowTemplate.Height = 24;
+            dgv1.Font = new System.Drawing.Font("ＭＳ 明朝", 11.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(128)));
+            dgv1.ColumnHeadersDefaultCellStyle.BackColor = Color.Aquamarine;
+
+            List<int> lstReqMonth = new List<int>();
+
+            // 請求月の取得
+            GetRequestMonth(ref lstReqMonth);
+
+            List<KeyValuePair<int, string>> lstKeyVal = new List<KeyValuePair<int, string>>();
+
+            foreach (int nMonth in lstReqMonth)
+            {
+                int yyyy = CommonMotions.cnvTruncate((double)(nMonth / 100));
+                int mm = nMonth % 100;
+                string strReqMonth = string.Format("{0}/{1}", yyyy, mm.ToString("D2"));
+
+                KeyValuePair<int, string> key = new KeyValuePair<int, string>(nMonth, strReqMonth);
+
+                lstKeyVal.Add(key);
+            }
+
+            int nReqMonth = 0;
+
+            cbReqMonth.ValueMember = "Key";
+            cbReqMonth.DisplayMember = "Value";
+
+            // コンボボックス初期表示
+            ComboBoxAction.InitDataSetCombBox(cbReqMonth, lstKeyVal, false);
+
+            if (cbReqMonth.Items.Count > 0)
+            {
+                cbReqMonth.SelectedValue = int.Parse(DateTime.Now.ToString("yyyyMM"));
+                nReqMonth = int.Parse(cbReqMonth.SelectedValue.ToString());
+
+                // 請求データの取得
+                GetRequestData( nReqMonth );
+            }
+
+            // 請求データの表示
+            DispOrdererReqData(nReqMonth);
+
+        }
+        #endregion
+
+        #region [請求選択]ボタン押下
+        /// <summary>
+        /// [請求選択]ボタン押下
+        /// </summary>
+        /// <param name="sender"></param>
+        /// <param name="e"></param>
+        private void btnSelRequest_Click(object sender, EventArgs e)
+        {
+
+            int nOrderersDivision = 0;
+            int nOrderersCode = 0;
+            string strOrderersName = "";
+
+            foreach (DataGridViewRow r in dgv1.SelectedRows)
+            {
+                if (r.Cells[4].Value != null)
+                {
+                    nOrderersDivision = int.Parse(r.Cells[4].Value.ToString());
+                    nOrderersCode = int.Parse(r.Cells[5].Value.ToString());
+                    strOrderersName = r.Cells[6].Value.ToString();
+
+                    break;
+                }
+            }
+
+            // ダミー行の選択の場合はスルー
+            if (nOrderersDivision == 0)
+            {
+                return;
+            }
+
+            FrmEntryReqSelRequest frmEntry = new FrmEntryReqSelRequest();
+
+            frmEntry.EditFlg = true;
+            frmEntry.RequestMonth = int.Parse(cbReqMonth.SelectedValue.ToString());
+            frmEntry.OrderersDivision = nOrderersDivision;
+            frmEntry.OrderersCode = nOrderersCode;
+            frmEntry.OrderersName = strOrderersName;
+
+            Visible = false;
+
+            DialogResult ret = frmEntry.ShowDialog(this);
+
+            int nInvoiceNo = frmEntry.InvoiceNo;
+
+            frmEntry.Dispose();
+
+            if ( ret == DialogResult.Cancel)
+            {
+                Visible = true;
+                return;
+            }
+
+            FrmRequestPrint frmPrint = new FrmRequestPrint();
+
+            frmPrint.InvoiceNo = nInvoiceNo;
+
+            frmPrint.ShowDialog(this);
+            
+        }
+        #endregion
+
+        #region [終了]ボタン押下
+        /// <summary>
+        /// [終了]ボタン押下
+        /// </summary>
+        /// <param name="sender"></param>
+        /// <param name="e"></param>
+        private void btnEnd_Click(object sender, EventArgs e)
+        {
+            ClsExcute.BackProcess();
+
+            Close();
+        }
+        #endregion
+
+        #region 請求月コンボの変更
+        /// <summary>
+        /// 請求月コンボの変更
+        /// </summary>
+        /// <param name="sender"></param>
+        /// <param name="e"></param>
+        private void cbReqMonth_SelectedIndexChanged(object sender, EventArgs e)
+        {
+            // 請求月コンボから請求月を取得
+            int nReqMonth = int.Parse(cbReqMonth.SelectedValue.ToString());
+
+            // 請求データの取得
+            GetRequestData(nReqMonth);
+
+            // データグリッドビュの行削除
+            dgv1.Rows.Clear();
+
+            // 請求データの表示
+            DispOrdererReqData(nReqMonth);
+
+        }
+        #endregion
+
+        #region データグリッドビュの選択変更
+        private void dgv1_SelectionChanged(object sender, EventArgs e)
+        {
+            bool bEnable = false;
+
+            foreach (DataGridViewRow r in dgv1.SelectedRows)
+            {
+                if (r.Cells[4].Value != null)
+                {
+                    bEnable = true;                   
+                }
+            }
+
+            btnSelRequest.Enabled = bEnable;
+        }
+        #endregion
+
+        #region 請求月の取得
+        /// <summary>
+        /// 請求月の取得
+        /// </summary>
+        private void GetRequestMonth( ref List<int> lstReqestMonth )
+        {
+            IORequestHead ioReqHead = new IORequestHead();
+
+            List<RequestHead> lstWork = new List<RequestHead>();
+
+            Dictionary<int, List<RequestHead>> dicWork = new Dictionary<int, List<RequestHead>>();
+
+            try
+            {
+                string sql = " Where AssignedFlg = 0 Order By RequestMonth Desc, ReqConstructionCode Asc";
+
+                // 請求ヘッダの取得
+                if (ioReqHead.SelectAction(sql, ref lstWork) == false)
+                {
+                    return;
+                }
+
+                // 請求ヘッダレコード分ループ
+                foreach (RequestHead ReqHead in lstWork)
+                {
+                    List<RequestHead> lstReqHead = null;
+
+                    // 請求月毎の工事番号リストが存在しない場合
+                    if( dicWork.TryGetValue( ReqHead.RequestMonth, out lstReqHead ) == false )
+                    {
+                        // 工事番号リストを構築
+                        lstReqHead = new List<RequestHead>();
+                        // ハッシュテーブルに追加
+                        dicWork.Add(ReqHead.RequestMonth, lstReqHead);
+                    }
+                    // 工事番号リストに追加
+                    lstReqHead.Add(ReqHead);
+                }
+
+                List<int> lstKey = new List<int>(dicWork.Keys);
+
+                foreach (int nRequestMonth in lstKey)
+                {
+                    List<RequestHead> lstReqHead = null;
+
+                    if (dicWork.TryGetValue(nRequestMonth, out lstReqHead) == true)
+                    {
+                        foreach (RequestHead ReqHead in lstReqHead)
+                        {
+                            // 最終承認済
+                            if (ClsApprovalPermission.CheckApprovalData(ReqHead.ReqConstructionCode, (int)ClsExcute.ApprovalListNo.OrderBillingApproval, ReqHead.OrderNo) == true)
+                            {
+                                // 請求月をリストに追加（以降はチェックする必要なし）
+                                lstReqestMonth.Add(nRequestMonth);
+                                break;
+                            }
+                        }
+                    }
+                }
+            }
+            catch (Exception ex)
+            {
+                logger.ErrorFormat("システムエラー：{0}：{1}", CommonMotions.GetMethodName(), ex.Message);
+            }
+            finally
+            {
+                ioReqHead.close();
+                ioReqHead = null;
+            }
+
+            return;
+        }
+        #endregion
+
+        #region 発注者請求データの取得
+        /// <summary>
+        /// 請求先一覧の取得
+        /// </summary>
+        private void GetRequestData( int nReqMonth )
+        {
+            IORequestHead ioReqHead = new IORequestHead();
+
+            List<RequestHead> lstWork = new List<RequestHead>();
+
+            try
+            {
+                Dictionary<string, ClsOrdererReqData> dicReqData = null;
+
+                // 当該請求月が既に登録されている場合
+                if (m_dicOrdererReqData.TryGetValue(nReqMonth, out dicReqData) == true)
+                {
+                    return;
+                }
+
+                // 当該請求月の請求ヘッダを取得
+                string sql = string.Format(" Where RequestMonth = {0} And AssignedFlg = 0 Order by ReqConstructionCode", nReqMonth);
+                if (ioReqHead.SelectAction(sql, ref lstWork) == false)
+                {
+                    return;
+                }
+
+                // ハッシュテーブルを追加
+                dicReqData = new Dictionary<string, ClsOrdererReqData>();
+                m_dicOrdererReqData.Add(nReqMonth, dicReqData);
+
+                foreach (RequestHead ReqHead in lstWork)
+                {
+                    // 最終承認されていない場合は対象外
+                    if (ClsApprovalPermission.CheckApprovalData(ReqHead.ReqConstructionCode, (int)ClsExcute.ApprovalListNo.OrderBillingApproval, ReqHead.OrderNo) == false)
+                    {
+                        continue;
+                    }
+
+                    // キー文字列を取得
+                    string strKey = ClsOrdererReqData.GetKeyString(ReqHead.OrderersDivision, ReqHead.OrderersCode, ReqHead.OrderersName);
+                    ClsOrdererReqData OdrReqData = null ;
+
+                    // まだ登録されていない場合
+                    if (dicReqData.TryGetValue(strKey, out OdrReqData) == false)
+                    {
+                        // 発注者請求データを追加
+                        OdrReqData = new ClsOrdererReqData(ReqHead.OrderersDivision, ReqHead.OrderersCode, ReqHead.OrderersName);
+                        dicReqData.Add(strKey, OdrReqData);
+
+                    }
+                    
+                    // 発注者請求データに請求ヘッダを追加
+                    OdrReqData.AddReqHead(ReqHead);
+                }
+            }
+            catch (Exception ex)
+            {
+                logger.ErrorFormat("システムエラー：{0}：{1}", CommonMotions.GetMethodName(), ex.Message);
+            }
+            finally
+            {
+                ioReqHead.close();
+                ioReqHead = null;
+            }
+        }
+        #endregion
+
+        #region 請求データの表示
+        private void DispOrdererReqData(int nReqMonth)
+        {
+            Dictionary<string, ClsOrdererReqData> dicReqData = null;
+            if (m_dicOrdererReqData.TryGetValue(nReqMonth, out dicReqData) == false)
+            {
+                return;
+            }
+
+            int nCount = dicReqData.Count();
+
+            if( nCount < 10 )
+            {
+                nCount = 10;
+            }
+            dgv1.Rows.Add(nCount);
+
+            int trow = 0;
+
+            List<string> lstKey = new List<string>(dicReqData.Keys);
+            foreach (string strKey in lstKey)
+            {
+                ClsOrdererReqData   OrdReqData = null;
+                if (dicReqData.TryGetValue(strKey, out OrdReqData) == true)
+                {
+                    dgv1[0, trow].Value = OrdReqData.OrderersName;
+                    dgv1[1, trow].Value = OrdReqData.DoneCount.ToString("#,0");
+                    dgv1[2, trow].Value = OrdReqData.UndoneCount.ToString("#,0");
+                    dgv1[3, trow].Value = OrdReqData.TotalAmount.ToString("#,0");
+                    dgv1[4, trow].Value = OrdReqData.OrderersDivision;
+                    dgv1[5, trow].Value = OrdReqData.OrderersCode;
+                    dgv1[6, trow].Value = OrdReqData.OrderersName;
+
+                    trow++;
+                }
+            }
+
+            dgv1[0,0].Selected = false;
+        }
+        #endregion
+
+
+    }
+}
Index: branches/src/ProcessManagement/ProcessManagement/Forms/DataEntry/Request/RequestEntry/FrmEntryReqSelOrderer.resx
===================================================================
--- branches/src/ProcessManagement/ProcessManagement/Forms/DataEntry/Request/RequestEntry/FrmEntryReqSelOrderer.resx	(nonexistent)
+++ branches/src/ProcessManagement/ProcessManagement/Forms/DataEntry/Request/RequestEntry/FrmEntryReqSelOrderer.resx	(revision 60)
@@ -0,0 +1,141 @@
+﻿<?xml version="1.0" encoding="utf-8"?>
+<root>
+  <!-- 
+    Microsoft ResX Schema 
+    
+    Version 2.0
+    
+    The primary goals of this format is to allow a simple XML format 
+    that is mostly human readable. The generation and parsing of the 
+    various data types are done through the TypeConverter classes 
+    associated with the data types.
+    
+    Example:
+    
+    ... ado.net/XML headers & schema ...
+    <resheader name="resmimetype">text/microsoft-resx</resheader>
+    <resheader name="version">2.0</resheader>
+    <resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
+    <resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
+    <data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
+    <data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
+    <data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
+        <value>[base64 mime encoded serialized .NET Framework object]</value>
+    </data>
+    <data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
+        <value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
+        <comment>This is a comment</comment>
+    </data>
+                
+    There are any number of "resheader" rows that contain simple 
+    name/value pairs.
+    
+    Each data row contains a name, and value. The row also contains a 
+    type or mimetype. Type corresponds to a .NET class that support 
+    text/value conversion through the TypeConverter architecture. 
+    Classes that don't support this are serialized and stored with the 
+    mimetype set.
+    
+    The mimetype is used for serialized objects, and tells the 
+    ResXResourceReader how to depersist the object. This is currently not 
+    extensible. For a given mimetype the value must be set accordingly:
+    
+    Note - application/x-microsoft.net.object.binary.base64 is the format 
+    that the ResXResourceWriter will generate, however the reader can 
+    read any of the formats listed below.
+    
+    mimetype: application/x-microsoft.net.object.binary.base64
+    value   : The object must be serialized with 
+            : System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
+            : and then encoded with base64 encoding.
+    
+    mimetype: application/x-microsoft.net.object.soap.base64
+    value   : The object must be serialized with 
+            : System.Runtime.Serialization.Formatters.Soap.SoapFormatter
+            : and then encoded with base64 encoding.
+
+    mimetype: application/x-microsoft.net.object.bytearray.base64
+    value   : The object must be serialized into a byte array 
+            : using a System.ComponentModel.TypeConverter
+            : and then encoded with base64 encoding.
+    -->
+  <xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
+    <xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
+    <xsd:element name="root" msdata:IsDataSet="true">
+      <xsd:complexType>
+        <xsd:choice maxOccurs="unbounded">
+          <xsd:element name="metadata">
+            <xsd:complexType>
+              <xsd:sequence>
+                <xsd:element name="value" type="xsd:string" minOccurs="0" />
+              </xsd:sequence>
+              <xsd:attribute name="name" use="required" type="xsd:string" />
+              <xsd:attribute name="type" type="xsd:string" />
+              <xsd:attribute name="mimetype" type="xsd:string" />
+              <xsd:attribute ref="xml:space" />
+            </xsd:complexType>
+          </xsd:element>
+          <xsd:element name="assembly">
+            <xsd:complexType>
+              <xsd:attribute name="alias" type="xsd:string" />
+              <xsd:attribute name="name" type="xsd:string" />
+            </xsd:complexType>
+          </xsd:element>
+          <xsd:element name="data">
+            <xsd:complexType>
+              <xsd:sequence>
+                <xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
+                <xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
+              </xsd:sequence>
+              <xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
+              <xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
+              <xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
+              <xsd:attribute ref="xml:space" />
+            </xsd:complexType>
+          </xsd:element>
+          <xsd:element name="resheader">
+            <xsd:complexType>
+              <xsd:sequence>
+                <xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
+              </xsd:sequence>
+              <xsd:attribute name="name" type="xsd:string" use="required" />
+            </xsd:complexType>
+          </xsd:element>
+        </xsd:choice>
+      </xsd:complexType>
+    </xsd:element>
+  </xsd:schema>
+  <resheader name="resmimetype">
+    <value>text/microsoft-resx</value>
+  </resheader>
+  <resheader name="version">
+    <value>2.0</value>
+  </resheader>
+  <resheader name="reader">
+    <value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
+  </resheader>
+  <resheader name="writer">
+    <value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
+  </resheader>
+  <metadata name="col1.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="col2.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="col3.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="col4.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="col5.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="col6.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="col7.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+</root>
\ No newline at end of file
Index: branches/src/ProcessManagement/ProcessManagement/Forms/DataEntry/Request/RequestEntry/FrmEntryReqSelRequest.Designer.cs
===================================================================
--- branches/src/ProcessManagement/ProcessManagement/Forms/DataEntry/Request/RequestEntry/FrmEntryReqSelRequest.Designer.cs	(nonexistent)
+++ branches/src/ProcessManagement/ProcessManagement/Forms/DataEntry/Request/RequestEntry/FrmEntryReqSelRequest.Designer.cs	(revision 60)
@@ -0,0 +1,430 @@
+﻿namespace ProcessManagement.Forms.DataEntry
+{
+
+    partial class FrmEntryReqSelRequest
+    {
+        /// <summary>
+        /// Required designer variable.
+        /// </summary>
+        private System.ComponentModel.IContainer components = null;
+
+        /// <summary>
+        /// Clean up any resources being used.
+        /// </summary>
+        /// <param name="disposing">true if managed resources should be disposed; otherwise, false.</param>
+        protected override void Dispose(bool disposing)
+        {
+            if (disposing && (components != null))
+            {
+                components.Dispose();
+            }
+            base.Dispose(disposing);
+        }
+
+        #region Windows Form Designer generated code
+
+        /// <summary>
+        /// Required method for Designer support - do not modify
+        /// the contents of this method with the code editor.
+        /// </summary>
+        private void InitializeComponent()
+        {
+            System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle1 = new System.Windows.Forms.DataGridViewCellStyle();
+            System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle2 = new System.Windows.Forms.DataGridViewCellStyle();
+            System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle3 = new System.Windows.Forms.DataGridViewCellStyle();
+            this.label4 = new System.Windows.Forms.Label();
+            this.lbReqMonth = new System.Windows.Forms.Label();
+            this.label2 = new System.Windows.Forms.Label();
+            this.lbOrderersName = new System.Windows.Forms.Label();
+            this.btnEnd = new System.Windows.Forms.Button();
+            this.btnGenerate = new System.Windows.Forms.Button();
+            this.panel1 = new System.Windows.Forms.Panel();
+            this.lbTotalAmount = new System.Windows.Forms.Label();
+            this.dgv1 = new System.Windows.Forms.DataGridView();
+            this.col1 = new System.Windows.Forms.DataGridViewCheckBoxColumn();
+            this.col2 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.col3 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.col4 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.col5 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.col6 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.label8 = new System.Windows.Forms.Label();
+            this.btnAllUnselect = new System.Windows.Forms.Button();
+            this.label7 = new System.Windows.Forms.Label();
+            this.btnAllSelect = new System.Windows.Forms.Button();
+            this.lbSelect = new System.Windows.Forms.Label();
+            this.label5 = new System.Windows.Forms.Label();
+            this.label10 = new System.Windows.Forms.Label();
+            this.cbCreateDate = new System.Windows.Forms.ComboBox();
+            this.btnDel = new System.Windows.Forms.Button();
+            this.panel1.SuspendLayout();
+            ((System.ComponentModel.ISupportInitialize)(this.dgv1)).BeginInit();
+            this.SuspendLayout();
+            // 
+            // label4
+            // 
+            this.label4.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(255)))), ((int)(((byte)(255)))), ((int)(((byte)(128)))));
+            this.label4.BorderStyle = System.Windows.Forms.BorderStyle.Fixed3D;
+            this.label4.CausesValidation = false;
+            this.label4.Font = new System.Drawing.Font("ＭＳ 明朝", 11.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(128)));
+            this.label4.Location = new System.Drawing.Point(12, 9);
+            this.label4.Name = "label4";
+            this.label4.Size = new System.Drawing.Size(100, 23);
+            this.label4.TabIndex = 23;
+            this.label4.Text = "請求月";
+            this.label4.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
+            // 
+            // lbReqMonth
+            // 
+            this.lbReqMonth.BackColor = System.Drawing.Color.White;
+            this.lbReqMonth.ForeColor = System.Drawing.SystemColors.ControlText;
+            this.lbReqMonth.Location = new System.Drawing.Point(118, 8);
+            this.lbReqMonth.Name = "lbReqMonth";
+            this.lbReqMonth.Size = new System.Drawing.Size(103, 24);
+            this.lbReqMonth.TabIndex = 24;
+            this.lbReqMonth.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
+            // 
+            // label2
+            // 
+            this.label2.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(255)))), ((int)(((byte)(255)))), ((int)(((byte)(128)))));
+            this.label2.BorderStyle = System.Windows.Forms.BorderStyle.Fixed3D;
+            this.label2.CausesValidation = false;
+            this.label2.Font = new System.Drawing.Font("ＭＳ 明朝", 11.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(128)));
+            this.label2.Location = new System.Drawing.Point(12, 42);
+            this.label2.Name = "label2";
+            this.label2.Size = new System.Drawing.Size(100, 23);
+            this.label2.TabIndex = 25;
+            this.label2.Text = "請求先";
+            this.label2.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
+            // 
+            // lbOrderersName
+            // 
+            this.lbOrderersName.BackColor = System.Drawing.Color.White;
+            this.lbOrderersName.ForeColor = System.Drawing.SystemColors.ControlText;
+            this.lbOrderersName.Location = new System.Drawing.Point(118, 42);
+            this.lbOrderersName.Name = "lbOrderersName";
+            this.lbOrderersName.Size = new System.Drawing.Size(591, 24);
+            this.lbOrderersName.TabIndex = 26;
+            this.lbOrderersName.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
+            // 
+            // btnEnd
+            // 
+            this.btnEnd.BackColor = System.Drawing.Color.Aqua;
+            this.btnEnd.Cursor = System.Windows.Forms.Cursors.Default;
+            this.btnEnd.Font = new System.Drawing.Font("ＭＳ 明朝", 11.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(128)));
+            this.btnEnd.ForeColor = System.Drawing.Color.Black;
+            this.btnEnd.Location = new System.Drawing.Point(640, 441);
+            this.btnEnd.Name = "btnEnd";
+            this.btnEnd.Size = new System.Drawing.Size(120, 30);
+            this.btnEnd.TabIndex = 34;
+            this.btnEnd.Text = "終　了";
+            this.btnEnd.UseVisualStyleBackColor = false;
+            this.btnEnd.Click += new System.EventHandler(this.btnEnd_Click);
+            // 
+            // btnGenerate
+            // 
+            this.btnGenerate.BackColor = System.Drawing.Color.Blue;
+            this.btnGenerate.Cursor = System.Windows.Forms.Cursors.Default;
+            this.btnGenerate.Font = new System.Drawing.Font("ＭＳ 明朝", 11.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(128)));
+            this.btnGenerate.ForeColor = System.Drawing.Color.White;
+            this.btnGenerate.Location = new System.Drawing.Point(514, 441);
+            this.btnGenerate.Name = "btnGenerate";
+            this.btnGenerate.Size = new System.Drawing.Size(120, 30);
+            this.btnGenerate.TabIndex = 33;
+            this.btnGenerate.Text = "請求書作成";
+            this.btnGenerate.UseVisualStyleBackColor = false;
+            this.btnGenerate.Click += new System.EventHandler(this.btnGenerate_Click);
+            // 
+            // panel1
+            // 
+            this.panel1.BorderStyle = System.Windows.Forms.BorderStyle.Fixed3D;
+            this.panel1.Controls.Add(this.lbTotalAmount);
+            this.panel1.Controls.Add(this.dgv1);
+            this.panel1.Controls.Add(this.label8);
+            this.panel1.Controls.Add(this.btnAllUnselect);
+            this.panel1.Controls.Add(this.label7);
+            this.panel1.Controls.Add(this.btnAllSelect);
+            this.panel1.Controls.Add(this.lbSelect);
+            this.panel1.Controls.Add(this.label5);
+            this.panel1.ForeColor = System.Drawing.Color.Black;
+            this.panel1.Location = new System.Drawing.Point(12, 77);
+            this.panel1.Name = "panel1";
+            this.panel1.Size = new System.Drawing.Size(745, 354);
+            this.panel1.TabIndex = 37;
+            // 
+            // lbTotalAmount
+            // 
+            this.lbTotalAmount.BackColor = System.Drawing.Color.White;
+            this.lbTotalAmount.ForeColor = System.Drawing.Color.Black;
+            this.lbTotalAmount.Location = new System.Drawing.Point(304, 6);
+            this.lbTotalAmount.Name = "lbTotalAmount";
+            this.lbTotalAmount.Size = new System.Drawing.Size(185, 24);
+            this.lbTotalAmount.TabIndex = 42;
+            this.lbTotalAmount.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
+            // 
+            // dgv1
+            // 
+            this.dgv1.AllowUserToAddRows = false;
+            this.dgv1.AllowUserToDeleteRows = false;
+            this.dgv1.AllowUserToResizeColumns = false;
+            this.dgv1.AllowUserToResizeRows = false;
+            dataGridViewCellStyle1.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleCenter;
+            dataGridViewCellStyle1.BackColor = System.Drawing.SystemColors.Control;
+            dataGridViewCellStyle1.Font = new System.Drawing.Font("ＭＳ 明朝", 11.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(128)));
+            dataGridViewCellStyle1.ForeColor = System.Drawing.SystemColors.WindowText;
+            dataGridViewCellStyle1.SelectionBackColor = System.Drawing.SystemColors.Highlight;
+            dataGridViewCellStyle1.SelectionForeColor = System.Drawing.SystemColors.HighlightText;
+            dataGridViewCellStyle1.WrapMode = System.Windows.Forms.DataGridViewTriState.True;
+            this.dgv1.ColumnHeadersDefaultCellStyle = dataGridViewCellStyle1;
+            this.dgv1.ColumnHeadersHeight = 28;
+            this.dgv1.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.DisableResizing;
+            this.dgv1.Columns.AddRange(new System.Windows.Forms.DataGridViewColumn[] {
+            this.col1,
+            this.col2,
+            this.col3,
+            this.col4,
+            this.col5,
+            this.col6});
+            this.dgv1.Location = new System.Drawing.Point(8, 36);
+            this.dgv1.Name = "dgv1";
+            this.dgv1.RowHeadersVisible = false;
+            this.dgv1.RowHeadersWidthSizeMode = System.Windows.Forms.DataGridViewRowHeadersWidthSizeMode.DisableResizing;
+            this.dgv1.RowTemplate.Height = 21;
+            this.dgv1.SelectionMode = System.Windows.Forms.DataGridViewSelectionMode.FullRowSelect;
+            this.dgv1.Size = new System.Drawing.Size(721, 270);
+            this.dgv1.TabIndex = 43;
+            this.dgv1.CellContentClick += new System.Windows.Forms.DataGridViewCellEventHandler(this.dgv1_CellContentClick);
+            this.dgv1.CellContentDoubleClick += new System.Windows.Forms.DataGridViewCellEventHandler(this.dgv1_CellContentDoubleClick);
+            // 
+            // col1
+            // 
+            this.col1.Frozen = true;
+            this.col1.HeaderText = "";
+            this.col1.Name = "col1";
+            this.col1.ReadOnly = true;
+            this.col1.Width = 30;
+            // 
+            // col2
+            // 
+            this.col2.Frozen = true;
+            this.col2.HeaderText = "請求件名";
+            this.col2.Name = "col2";
+            this.col2.ReadOnly = true;
+            this.col2.Resizable = System.Windows.Forms.DataGridViewTriState.False;
+            this.col2.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable;
+            this.col2.Width = 370;
+            // 
+            // col3
+            // 
+            dataGridViewCellStyle2.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleRight;
+            this.col3.DefaultCellStyle = dataGridViewCellStyle2;
+            this.col3.Frozen = true;
+            this.col3.HeaderText = "請求金額";
+            this.col3.Name = "col3";
+            this.col3.ReadOnly = true;
+            this.col3.Resizable = System.Windows.Forms.DataGridViewTriState.False;
+            this.col3.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable;
+            this.col3.Width = 160;
+            // 
+            // col4
+            // 
+            dataGridViewCellStyle3.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleCenter;
+            this.col4.DefaultCellStyle = dataGridViewCellStyle3;
+            this.col4.Frozen = true;
+            this.col4.HeaderText = "作成";
+            this.col4.Name = "col4";
+            this.col4.ReadOnly = true;
+            this.col4.Resizable = System.Windows.Forms.DataGridViewTriState.False;
+            this.col4.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable;
+            this.col4.Width = 140;
+            // 
+            // col5
+            // 
+            this.col5.HeaderText = "RequestNo";
+            this.col5.Name = "col5";
+            this.col5.ReadOnly = true;
+            this.col5.Visible = false;
+            // 
+            // col6
+            // 
+            this.col6.HeaderText = "InvoiceNo";
+            this.col6.Name = "col6";
+            this.col6.ReadOnly = true;
+            this.col6.Visible = false;
+            // 
+            // label8
+            // 
+            this.label8.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(255)))), ((int)(((byte)(255)))), ((int)(((byte)(128)))));
+            this.label8.BorderStyle = System.Windows.Forms.BorderStyle.Fixed3D;
+            this.label8.CausesValidation = false;
+            this.label8.Font = new System.Drawing.Font("ＭＳ 明朝", 11.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(128)));
+            this.label8.ForeColor = System.Drawing.Color.Black;
+            this.label8.Location = new System.Drawing.Point(200, 6);
+            this.label8.Name = "label8";
+            this.label8.Size = new System.Drawing.Size(100, 24);
+            this.label8.TabIndex = 41;
+            this.label8.Text = "金額合計";
+            this.label8.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
+            // 
+            // btnAllUnselect
+            // 
+            this.btnAllUnselect.BackColor = System.Drawing.Color.Lime;
+            this.btnAllUnselect.Cursor = System.Windows.Forms.Cursors.Default;
+            this.btnAllUnselect.Font = new System.Drawing.Font("ＭＳ 明朝", 11.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(128)));
+            this.btnAllUnselect.ForeColor = System.Drawing.Color.Black;
+            this.btnAllUnselect.Location = new System.Drawing.Point(134, 312);
+            this.btnAllUnselect.Name = "btnAllUnselect";
+            this.btnAllUnselect.Size = new System.Drawing.Size(120, 30);
+            this.btnAllUnselect.TabIndex = 38;
+            this.btnAllUnselect.Text = "全選択解除";
+            this.btnAllUnselect.UseVisualStyleBackColor = false;
+            this.btnAllUnselect.Click += new System.EventHandler(this.btnAllUnselect_Click);
+            // 
+            // label7
+            // 
+            this.label7.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(255)))), ((int)(((byte)(255)))), ((int)(((byte)(128)))));
+            this.label7.BorderStyle = System.Windows.Forms.BorderStyle.Fixed3D;
+            this.label7.CausesValidation = false;
+            this.label7.Font = new System.Drawing.Font("ＭＳ 明朝", 11.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(128)));
+            this.label7.ForeColor = System.Drawing.Color.Black;
+            this.label7.Location = new System.Drawing.Point(151, 6);
+            this.label7.Name = "label7";
+            this.label7.Size = new System.Drawing.Size(42, 24);
+            this.label7.TabIndex = 40;
+            this.label7.Text = "件";
+            this.label7.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
+            // 
+            // btnAllSelect
+            // 
+            this.btnAllSelect.BackColor = System.Drawing.Color.Yellow;
+            this.btnAllSelect.Cursor = System.Windows.Forms.Cursors.Default;
+            this.btnAllSelect.Font = new System.Drawing.Font("ＭＳ 明朝", 11.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(128)));
+            this.btnAllSelect.ForeColor = System.Drawing.Color.Black;
+            this.btnAllSelect.Location = new System.Drawing.Point(8, 312);
+            this.btnAllSelect.Name = "btnAllSelect";
+            this.btnAllSelect.Size = new System.Drawing.Size(120, 30);
+            this.btnAllSelect.TabIndex = 37;
+            this.btnAllSelect.Text = "全選択";
+            this.btnAllSelect.UseVisualStyleBackColor = false;
+            this.btnAllSelect.Click += new System.EventHandler(this.btnAllSelect_Click);
+            // 
+            // lbSelect
+            // 
+            this.lbSelect.BackColor = System.Drawing.Color.White;
+            this.lbSelect.ForeColor = System.Drawing.SystemColors.ControlText;
+            this.lbSelect.Location = new System.Drawing.Point(93, 6);
+            this.lbSelect.Name = "lbSelect";
+            this.lbSelect.Size = new System.Drawing.Size(55, 24);
+            this.lbSelect.TabIndex = 39;
+            this.lbSelect.TextAlign = System.Drawing.ContentAlignment.MiddleRight;
+            // 
+            // label5
+            // 
+            this.label5.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(255)))), ((int)(((byte)(255)))), ((int)(((byte)(128)))));
+            this.label5.BorderStyle = System.Windows.Forms.BorderStyle.Fixed3D;
+            this.label5.CausesValidation = false;
+            this.label5.Font = new System.Drawing.Font("ＭＳ 明朝", 11.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(128)));
+            this.label5.ForeColor = System.Drawing.Color.Black;
+            this.label5.Location = new System.Drawing.Point(9, 6);
+            this.label5.Name = "label5";
+            this.label5.Size = new System.Drawing.Size(80, 24);
+            this.label5.TabIndex = 38;
+            this.label5.Text = "選択";
+            this.label5.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
+            // 
+            // label10
+            // 
+            this.label10.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(255)))), ((int)(((byte)(255)))), ((int)(((byte)(128)))));
+            this.label10.BorderStyle = System.Windows.Forms.BorderStyle.Fixed3D;
+            this.label10.CausesValidation = false;
+            this.label10.Font = new System.Drawing.Font("ＭＳ 明朝", 11.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(128)));
+            this.label10.Location = new System.Drawing.Point(227, 9);
+            this.label10.Name = "label10";
+            this.label10.Size = new System.Drawing.Size(100, 23);
+            this.label10.TabIndex = 38;
+            this.label10.Text = "作成日";
+            this.label10.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
+            // 
+            // cbCreateDate
+            // 
+            this.cbCreateDate.BackColor = System.Drawing.Color.White;
+            this.cbCreateDate.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
+            this.cbCreateDate.FormattingEnabled = true;
+            this.cbCreateDate.Location = new System.Drawing.Point(333, 10);
+            this.cbCreateDate.Name = "cbCreateDate";
+            this.cbCreateDate.Size = new System.Drawing.Size(150, 23);
+            this.cbCreateDate.TabIndex = 39;
+            this.cbCreateDate.SelectedIndexChanged += new System.EventHandler(this.cbCreateDate_SelectedIndexChanged);
+            // 
+            // btnDel
+            // 
+            this.btnDel.BackColor = System.Drawing.Color.Red;
+            this.btnDel.Cursor = System.Windows.Forms.Cursors.Default;
+            this.btnDel.Enabled = false;
+            this.btnDel.Font = new System.Drawing.Font("ＭＳ 明朝", 11.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(128)));
+            this.btnDel.ForeColor = System.Drawing.Color.Black;
+            this.btnDel.Location = new System.Drawing.Point(12, 440);
+            this.btnDel.Name = "btnDel";
+            this.btnDel.Size = new System.Drawing.Size(120, 30);
+            this.btnDel.TabIndex = 40;
+            this.btnDel.Text = "請求書削除";
+            this.btnDel.UseVisualStyleBackColor = false;
+            this.btnDel.Click += new System.EventHandler(this.btnDel_Click);
+            // 
+            // FrmEntryReqSelRequest
+            // 
+            this.AutoScaleDimensions = new System.Drawing.SizeF(9F, 15F);
+            this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
+            this.BackColor = System.Drawing.Color.Black;
+            this.ClientSize = new System.Drawing.Size(768, 481);
+            this.Controls.Add(this.btnDel);
+            this.Controls.Add(this.cbCreateDate);
+            this.Controls.Add(this.label10);
+            this.Controls.Add(this.panel1);
+            this.Controls.Add(this.btnEnd);
+            this.Controls.Add(this.btnGenerate);
+            this.Controls.Add(this.lbOrderersName);
+            this.Controls.Add(this.label2);
+            this.Controls.Add(this.lbReqMonth);
+            this.Controls.Add(this.label4);
+            this.Font = new System.Drawing.Font("ＭＳ 明朝", 11.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(128)));
+            this.ForeColor = System.Drawing.SystemColors.ControlText;
+            this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedSingle;
+            this.Margin = new System.Windows.Forms.Padding(4);
+            this.Name = "FrmEntryReqSelRequest";
+            this.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen;
+            this.Text = "請求書作成";
+            this.Load += new System.EventHandler(this.FrmEntryReqSelRequest_Load);
+            this.panel1.ResumeLayout(false);
+            ((System.ComponentModel.ISupportInitialize)(this.dgv1)).EndInit();
+            this.ResumeLayout(false);
+
+        }
+
+        #endregion
+
+        private System.Windows.Forms.Label label4;
+        private System.Windows.Forms.Label lbReqMonth;
+        private System.Windows.Forms.Label label2;
+        private System.Windows.Forms.Label lbOrderersName;
+        private System.Windows.Forms.Button btnEnd;
+        private System.Windows.Forms.Button btnGenerate;
+        private System.Windows.Forms.Panel panel1;
+        private System.Windows.Forms.Button btnAllUnselect;
+        private System.Windows.Forms.Button btnAllSelect;
+        private System.Windows.Forms.Label label5;
+        private System.Windows.Forms.Label lbTotalAmount;
+        private System.Windows.Forms.Label label8;
+        private System.Windows.Forms.Label label7;
+        private System.Windows.Forms.Label lbSelect;
+        private System.Windows.Forms.DataGridView dgv1;
+        private System.Windows.Forms.Label label10;
+        private System.Windows.Forms.ComboBox cbCreateDate;
+        private System.Windows.Forms.DataGridViewCheckBoxColumn col1;
+        private System.Windows.Forms.DataGridViewTextBoxColumn col2;
+        private System.Windows.Forms.DataGridViewTextBoxColumn col3;
+        private System.Windows.Forms.DataGridViewTextBoxColumn col4;
+        private System.Windows.Forms.DataGridViewTextBoxColumn col5;
+        private System.Windows.Forms.DataGridViewTextBoxColumn col6;
+        private System.Windows.Forms.Button btnDel;
+    }
+}
\ No newline at end of file
Index: branches/src/ProcessManagement/ProcessManagement/Forms/DataEntry/Request/RequestEntry/FrmEntryReqSelRequest.cs
===================================================================
--- branches/src/ProcessManagement/ProcessManagement/Forms/DataEntry/Request/RequestEntry/FrmEntryReqSelRequest.cs	(nonexistent)
+++ branches/src/ProcessManagement/ProcessManagement/Forms/DataEntry/Request/RequestEntry/FrmEntryReqSelRequest.cs	(revision 60)
@@ -0,0 +1,1013 @@
+﻿using System;
+using System.Collections;
+using System.Collections.Generic;
+using System.ComponentModel;
+using System.Data;
+using System.Drawing;
+using System.Linq;
+using System.Text;
+using System.Threading.Tasks;
+using System.Windows.Forms;
+
+using ProcessManagement.Common;
+using ProcessManagement.DataModel;
+using ProcessManagement.DB;
+using ProcessManagement.DB.IOAccess;
+using ProcessManagement.Forms.SubForms;
+using ProcessManagement.Forms.ControlsAction;
+
+
+namespace ProcessManagement.Forms.DataEntry
+{
+    public partial class FrmEntryReqSelRequest : Form
+    {
+        #region 使用定義
+        //log4netログを使用する
+        private static readonly log4net.ILog logger = log4net.LogManager.GetLogger(System.Reflection.MethodBase.GetCurrentMethod().DeclaringType);
+        #endregion
+
+        #region 定数
+
+        /// <summary>
+        /// チェック結果
+        /// </summary>
+        enum CheckState
+        {
+            Ok = 0,
+            Warning,
+            Error,
+        }
+        #endregion
+
+        #region 変数
+
+        private bool m_bEditFlg = true;             // 編集モード
+        private int m_nInvoiceNo = 0;               // 請求書No
+        private int m_nRequestMonth = 0;            // 請求月
+        private int m_nOrderersDivision = 0;        // 発注者区分
+        private int m_nOrderersCode = 0;            // 発注者コード
+        private string m_strOrderersName = "";      // 発注者名
+        private int m_nOldSelectedValue = 0;
+
+        // 請求ヘッダ
+        private List<RequestHead> m_lstReqHead = new List<RequestHead>();
+
+        // 請求書データ
+        private Dictionary<int, InvoiceData> m_dicInvData = new Dictionary<int, InvoiceData>();
+
+        #endregion
+
+        #region プロパティ
+
+        public bool EditFlg
+        {
+            get { return m_bEditFlg; }
+            set { m_bEditFlg = value; }
+        }
+        public int InvoiceNo
+        {
+            get { return m_nInvoiceNo; }
+            set { m_nInvoiceNo = value; }
+        }
+        public int RequestMonth
+        {
+            get { return m_nRequestMonth; }
+            set { m_nRequestMonth = value; }
+        }
+        public int OrderersDivision
+        {
+            get { return m_nOrderersDivision; }
+            set { m_nOrderersDivision = value; }
+        }
+        public int OrderersCode
+        {
+            get { return m_nOrderersCode; }
+            set { m_nOrderersCode = value; }
+        }
+        public string OrderersName
+        {
+            get { return m_strOrderersName; }
+            set { m_strOrderersName = value; }
+        }
+
+        #endregion
+
+        #region コンストラクタ
+        public FrmEntryReqSelRequest()
+        {
+            InitializeComponent();
+        }
+        #endregion
+
+        #region フォームのロード
+        private void FrmEntryReqSelRequest_Load(object sender, EventArgs e)
+        {
+            dgv1.EnableHeadersVisualStyles = false;
+            dgv1.AutoGenerateColumns = false;
+            dgv1.ColumnHeadersHeight = 28;
+            dgv1.ColumnHeadersDefaultCellStyle.Alignment = DataGridViewContentAlignment.MiddleCenter;
+            dgv1.AllowUserToAddRows = false;
+            dgv1.RowTemplate.Height = 24;
+            dgv1.Font = new System.Drawing.Font("ＭＳ 明朝", 11.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(128)));
+            dgv1.ColumnHeadersDefaultCellStyle.BackColor = Color.Aquamarine;
+
+            int yyyy = CommonMotions.cnvTruncate((double)m_nRequestMonth / 100);
+            int mm = m_nRequestMonth % 100;
+            lbReqMonth.Text = string.Format("{0}/{1}", yyyy, mm.ToString("D2"));
+            lbOrderersName.Text = m_strOrderersName;
+
+            // 請求書データ取得
+            GetInvoiceData();
+
+            List<int> lstCreateData = new List<int>();
+
+            if (m_nInvoiceNo == 0)
+            {
+                // 作成日コンボの取得
+                SetRequestCreateDateAll();
+            }
+            else
+            {
+                // 作成日コンボの取得
+                SetRequestCreateDateOnly();
+            }
+
+            cbCreateDate.SelectedIndex = 0;
+
+            // 請求データ取得
+            GetReqestData();
+
+            // 請求データ表示
+            DispRequestData();
+
+            // 請求書が指定されている場合は、チェックボックス変更に関わる操作は許可しない
+            if (m_nInvoiceNo > 0)
+            {
+                btnAllSelect.Enabled = false;
+                btnAllUnselect.Enabled = false;
+            }
+            UpdateCheckValue(0);
+
+            dgv1.Rows[0].Visible = false;
+
+        }
+        #endregion
+
+        #region [全選択]ボタン押下
+        private void btnAllSelect_Click(object sender, EventArgs e)
+        {
+            int nInvoiceNo = int.Parse(cbCreateDate.SelectedValue.ToString());
+
+            dgv1.CellContentClick -= dgv1_CellContentClick;
+            dgv1.CellContentDoubleClick -= dgv1_CellContentDoubleClick;
+
+            for (int i = 1; i < dgv1.Rows.Count; i++)
+            {
+                // 請求ヘッダが紐づいていない行はダミー
+                if (dgv1[4, i].Value == null)
+                {
+                    break;
+                }
+
+                // 請求書が紐づいていないものはON
+                if (dgv1[5, i].Value == null)
+                {
+                    dgv1[0, i].Value = true;
+                }
+                // 請求書が紐づいていても選択されている請求書のものはON
+                else if (int.Parse(dgv1[5, i].Value.ToString()) == nInvoiceNo)
+                {
+                    dgv1[0, i].Value = true;
+                }
+            }
+
+            // 選択数、選択金額の更新
+            UpdateCheckValue(0);
+
+            dgv1.CellContentClick += dgv1_CellContentClick;
+            dgv1.CellContentDoubleClick += dgv1_CellContentDoubleClick;
+
+        }
+        #endregion
+
+        #region [全選択解除]ボタン押下
+        private void btnAllUnselect_Click(object sender, EventArgs e)
+        {
+            int nInvoiceNo = int.Parse(cbCreateDate.SelectedValue.ToString());
+
+            for (int i = 1; i < dgv1.Rows.Count; i++)
+            {
+                // 請求ヘッダが紐づいていない行はダミー
+                if (dgv1[4, i].Value == null)
+                {
+                    break;
+                }
+
+                // 請求書が紐づいていないものはOFF
+                if (dgv1[5, i].Value == null)
+                {
+                    dgv1[0, i].Value = false;
+                }
+                // 請求書が紐づいていても選択されていない請求書のものはOFF
+                else if (int.Parse(dgv1[5, i].Value.ToString()) != nInvoiceNo)
+                {
+                    dgv1[0, i].Value = false;
+                }
+            }
+            // 選択数、選択金額の更新
+            UpdateCheckValue(0);
+        }
+        #endregion
+
+        #region [削除]ボタン押下
+        private void btnDel_Click(object sender, EventArgs e)
+        {
+            if (MessageBox.Show("表示されている請求書を削除しますがよろしいですか？", "削除確認", MessageBoxButtons.YesNo, MessageBoxIcon.Information) == DialogResult.No)
+            {
+                return;
+            }
+
+            int nInvoiceNo = int.Parse(cbCreateDate.SelectedValue.ToString());
+
+            // 請求書データの削除
+            if (DeleteInvoiceData(nInvoiceNo) == false)
+            {
+                return;
+            }
+
+            foreach (RequestHead ReqHead in m_lstReqHead)
+            {
+                if (ReqHead.InvoiceNo == nInvoiceNo)
+                {
+                    ReqHead.InvoiceNo = 0;
+                }
+            }
+
+            for (int i = 0; i < dgv1.Rows.Count; i++)
+            {
+                // 請求ヘッダが紐づいていない行はダミー
+                if (dgv1[4, i].Value == null)
+                {
+                    break;
+                }
+
+                // 削除対象の設計書データが紐づいている場合
+                if ((dgv1[5, i].Value != null) && (int.Parse(dgv1[5, i].Value.ToString()) == nInvoiceNo))
+                {
+                    dgv1[5, i].Value = null;
+                    dgv1[3, i].Value = null; 
+                }
+
+            }
+
+            // 請求データから該当請求書を削除
+            m_dicInvData.Remove(nInvoiceNo);
+
+            cbCreateDate.SelectedIndexChanged -= cbCreateDate_SelectedIndexChanged;
+
+            cbCreateDate.DataSource = null;
+            cbCreateDate.Items.Clear();
+
+            // 作成日コンボの取得
+            SetRequestCreateDateAll();
+
+            cbCreateDate.SelectedIndexChanged += cbCreateDate_SelectedIndexChanged;
+
+            cbCreateDate.SelectedIndex = 0;
+
+
+            RefleshRequestList(nInvoiceNo);
+
+        }
+        #endregion
+
+        #region [請求書作成]ボタン押下
+        private void btnGenerate_Click(object sender, EventArgs e)
+        {
+            int ret;
+            string msg = "";
+
+            // 作成チェック
+            ret  = CheckGenerate(ref msg);
+
+            if (ret == (int)CheckState.Ok)
+            {
+                if (MessageBox.Show(msg, "登録確認", MessageBoxButtons.YesNo, MessageBoxIcon.Question) != DialogResult.Yes)
+                {
+                    return;
+                }
+            }
+            else if (ret == (int)CheckState.Warning)
+            {
+                if (MessageBox.Show(msg, "登録確認", MessageBoxButtons.YesNo, MessageBoxIcon.Warning) != DialogResult.Yes)
+                {
+                    return;
+                }
+            }
+            else
+            {
+                MessageBox.Show(msg, "登録確認", MessageBoxButtons.OK, MessageBoxIcon.Error);
+                return;
+            }
+
+            // データの登録
+            m_nInvoiceNo = EntryData();
+
+            DialogResult = DialogResult.OK;
+
+            // 画面クローズ
+            Close();
+        }
+        #endregion
+
+        #region [終了]ボタン押下
+        private void btnEnd_Click(object sender, EventArgs e)
+        {
+            // 画面クローズ
+            Close();
+        }
+        #endregion
+
+        #region 作成日コンボの選択変更
+        private void cbCreateDate_SelectedIndexChanged(object sender, EventArgs e)
+        {
+            int nInvoiceNo = int.Parse(cbCreateDate.SelectedValue.ToString());
+
+            if (m_nOldSelectedValue == nInvoiceNo)
+            {
+                return;
+            }
+
+            m_nOldSelectedValue = nInvoiceNo;
+
+            RefleshRequestList(nInvoiceNo);
+        }
+
+        #endregion
+
+        #region 一覧の更新
+
+        private void RefleshRequestList( int nInvoiceNo )
+        {
+            bool bEnabled = false;
+
+            // 新規以外が選択された場合
+            if (nInvoiceNo != 0)
+            {
+                InvoiceData InvData = null;
+                if (m_dicInvData.TryGetValue(nInvoiceNo, out InvData) == true)
+                {
+                    if (InvData.CompleteFlg == 0)
+                    {
+                        bEnabled = true;
+                    }
+                }
+            }
+
+            btnDel.Enabled = bEnabled;
+
+            for (int i = 1; i < dgv1.Rows.Count; i++)
+            {
+                // 請求ヘッダが紐づいていない行はダミー
+                if (dgv1[4, i].Value == null)
+                {
+                    break;
+                }
+
+                // 新規請求書が選択された場合は全OFF
+                if (nInvoiceNo == 0)
+                {
+                    dgv1[0, i].Value = false;
+                    dgv1[0, i].ReadOnly = false;
+                }
+                else
+                {
+                    // 請求書が選択された場合は該当設計書のみON
+                    if ((dgv1[5, i].Value != null) && (int.Parse(dgv1[5, i].Value.ToString()) == nInvoiceNo))
+                    {
+                        dgv1[0, i].Value = true;
+                        dgv1[0, i].ReadOnly = true;
+
+                    }
+                    else
+                    {
+                        dgv1[0, i].Value = false;
+                        dgv1[0, i].ReadOnly = false;
+                    }
+                }
+            }
+            // 選択数、選択金額の更新
+            UpdateCheckValue(0);
+        }
+
+        #endregion
+
+        #region セル内容のクリック
+        private void dgv1_CellContentClick(object sender, DataGridViewCellEventArgs e)
+        {
+            UpdateCheckValue(e.ColumnIndex); 
+        }
+        #endregion
+
+        #region セル内容のWクリック
+        private void dgv1_CellContentDoubleClick(object sender, DataGridViewCellEventArgs e)
+        {
+            UpdateCheckValue(e.ColumnIndex); 
+        }
+        #endregion
+
+        #region 選択数、選択金額の更新
+        void UpdateCheckValue(int tcol)
+        {
+            int cnt = 0;
+            int val;
+            int amount = 0;
+
+            for (int i = 1; i < dgv1.Rows.Count; i++)
+            {
+                if (dgv1[tcol, i].EditedFormattedValue.Equals(true) == true)
+                {
+                    cnt++;
+
+                    if (dgv1[2, i].Value != null)
+                    {
+                        val = int.Parse(dgv1[2, i].Value.ToString().Replace(",", string.Empty));
+                    }
+                    else
+                    {
+                        val = 0;
+                    }
+
+                    amount += val;
+                }
+            }
+
+            lbSelect.Text = cnt.ToString("#,0");
+            lbTotalAmount.Text = amount.ToString("#,0");
+        }
+        #endregion
+
+        #region 請求書データの取得
+        private void GetInvoiceData()
+        {
+            IOInvoiceData ioInvData = new IOInvoiceData();
+
+            ArrayList arData = new ArrayList();
+
+            try
+            {
+                string sql = "SELECT";
+                sql += " InvData.InvoiceNo";
+                sql += " ,InvData.OrderersDivision";
+                sql += " ,InvData.OrderersCode";
+                sql += " ,InvData.RequestMonth";
+                sql += " ,InvData.SeqNo";
+                sql += " ,DATE_FORMAT(InvData.CretateDate, '%Y/%m/%d')";
+                sql += " ,DATE_FORMAT(InvData.RequestDate, '%Y/%m/%d')";
+                sql += " ,InvData.RequestName";
+                sql += " ,InvData.TotalAmount";
+                sql += " ,InvData.TaxAmount";
+                sql += " ,InvData.Comment1";
+                sql += " ,InvData.Comment2";
+                sql += " ,InvData.Comment3";
+                sql += " ,InvData.Comment4";
+                sql += " ,InvData.Comment5";
+                sql += " ,InvData.CompleteFlg";
+                sql += " ,DATE_FORMAT(InvData.EntryDate, '%Y/%m/%d %H:%i:%s')";
+                sql += " ,DATE_FORMAT(InvData.UpdateDate, '%Y/%m/%d %H:%i:%s')";
+                sql += " FROM";
+                sql += " InvoiceData InvData";
+                sql += string.Format(" WHERE InvData.OrderersDivision = {0}", m_nOrderersDivision);
+                sql += string.Format(" AND InvData.OrderersCode = {0} ", m_nOrderersCode);
+                sql += string.Format(" AND InvData.RequestMonth = {0} ", m_nRequestMonth);
+                sql += " AND EXISTS( SELECT * FROM RequestHead ReqHead WHERE ReqHead.InvoiceNo = InvData.InvoiceNo )";
+                sql += " ORDER BY InvData.CretateDate Asc, InvData.SeqNo Asc";
+
+                // SQL実行
+                if (!ioInvData.ExecuteReader(sql, ref arData, true)) return;
+
+                // データセット
+                foreach (object[] objwrk in arData)
+                {
+                    InvoiceData work = new InvoiceData();
+                    ioInvData.Reader2Struct(objwrk, ref work);
+
+                    m_dicInvData.Add(work.InvoiceNo, work);
+                }
+
+            }
+            catch (Exception ex)
+            {
+                logger.ErrorFormat("システムエラー：{0}：{1}", CommonMotions.GetMethodName(), ex.Message);
+            }
+            finally
+            {
+                ioInvData.close();
+                ioInvData = null;
+            }
+            return;
+        }
+        #endregion
+
+        #region 請求データの取得
+
+        private void GetReqestData()
+        {
+
+            IORequestHead ioReqHead = new IORequestHead();
+
+            try
+            {
+                List<RequestHead> lstWork = new List<RequestHead>();
+
+                string sql = string.Format(" Where RequestMonth = {0}",m_nRequestMonth); 
+                sql += string.Format(" And OrderersDivision = {0}", m_nOrderersDivision);
+                sql += string.Format(" And OrderersCode = {0}", m_nOrderersCode);
+                sql += string.Format(" And OrderersName = '{0}'", m_strOrderersName);
+                sql += " And AssignedFlg = 0";
+                sql += " Order by ReqConstructionCode Asc, OrderNo Asc";
+
+                if (ioReqHead.SelectAction(sql, ref lstWork) == false)
+                {
+                    return;
+                }
+
+                foreach (RequestHead ReqHead in lstWork)
+                {
+                    // 最終承認済
+                    if (ClsApprovalPermission.CheckApprovalData(ReqHead.ReqConstructionCode, (int)ClsExcute.ApprovalListNo.OrderBillingApproval, ReqHead.OrderNo) == false)
+                    {
+                        continue;
+                    }
+
+                    // 請求ヘッダの追加
+                    m_lstReqHead.Add(ReqHead);
+
+                }
+
+            }
+            catch (Exception ex)
+            {
+                logger.ErrorFormat("システムエラー：{0}：{1}", CommonMotions.GetMethodName(), ex.Message);
+            }
+            finally
+            {
+                ioReqHead.close();
+                ioReqHead = null;
+            }
+        }
+        #endregion
+
+        #region 請求データの表示
+
+        private void DispRequestData()
+        {
+            int nCount = m_lstReqHead.Count;
+            if (nCount < 10)
+            {
+                nCount = 10;
+            }
+
+            // 行を追加
+            dgv1.Rows.Add(nCount+1);
+
+            int trow = 1;
+            foreach (RequestHead ReqHead in m_lstReqHead)
+            {
+                // 請求書Noが指定されている場合は、チェックボックスの変更不可
+                if (m_nInvoiceNo == 0)
+                {
+                    dgv1[0, trow].ReadOnly = false;
+                }
+
+                dgv1[1, trow].Value = ReqHead.ReqConstructionName;
+                dgv1[2, trow].Value = ReqHead.RequestTotalAmount.ToString("#,0");
+                dgv1[4, trow].Value = ReqHead.RequestNo;
+
+                if (ReqHead.InvoiceNo > 0)
+                {
+                    InvoiceData InvData = null;
+
+                    if (m_dicInvData.TryGetValue(ReqHead.InvoiceNo, out InvData) == true)
+                    {
+                        dgv1[3, trow].Value = InvData.CretateDate.ToString("yyyy/MM/dd");
+                        dgv1[5, trow].Value = InvData.InvoiceNo;
+                    }
+
+                }
+                trow++;
+            }
+        }
+
+        #endregion
+
+        #region 作成日コンボの設定
+        private void SetRequestCreateDateAll()
+        {
+            List<int> lstKeyInvNo = new List<int>(m_dicInvData.Keys);
+            Dictionary<string, List<InvoiceData>> dicWork = new Dictionary<string, List<InvoiceData>>();
+            List<KeyValuePair<int, string>> lstKeyVal = new List<KeyValuePair<int, string>>();
+
+            foreach (int nInvoiceNo in lstKeyInvNo)
+            {
+                InvoiceData InvData = null;
+                if (m_dicInvData.TryGetValue(nInvoiceNo, out InvData) == true)
+                {
+                    string strDate = InvData.CretateDate.ToString("yyyy/MM/dd");
+
+                    List<InvoiceData> lstWork = null;
+
+                    if (dicWork.TryGetValue(strDate, out lstWork) == false)
+                    {
+                        lstWork = new List<InvoiceData>();
+
+                        dicWork.Add(strDate, lstWork);
+                    }
+                    lstWork.Add(InvData);
+                }
+            }
+            
+            List<string> lstKeyDate = new List<string>(dicWork.Keys);
+
+            KeyValuePair<int, string> KeyValNew = new KeyValuePair<int, string>(0, "新規");
+            lstKeyVal.Add(KeyValNew);
+
+            foreach (string strDate in lstKeyDate)
+            {
+                List<InvoiceData> lstWork = null;
+
+                if (dicWork.TryGetValue(strDate, out lstWork) == true)
+                {
+                    for (int i = 0; i < lstWork.Count; i++)
+                    {
+                        string strValue;
+
+                        strValue = strDate;
+                        if (i > 0)
+                        {
+                            strValue += string.Format("({0})", i);
+                        }
+
+                        KeyValuePair<int, string> KeyVal = new KeyValuePair<int, string>(lstWork[i].InvoiceNo, strValue);
+
+                        lstKeyVal.Add(KeyVal);
+                    }
+                }
+            }
+
+            cbCreateDate.ValueMember = "Key";
+            cbCreateDate.DisplayMember = "Value";
+
+            // コンボボックス初期表示
+            ComboBoxAction.InitDataSetCombBox(cbCreateDate, lstKeyVal, false);
+                                    
+            return;
+        }
+
+        private void SetRequestCreateDateOnly()
+        {
+
+            List<KeyValuePair<int, string>> lstKeyVal = new List<KeyValuePair<int, string>>();
+            InvoiceData InvData = null;
+
+            if (m_dicInvData.TryGetValue(m_nInvoiceNo, out InvData) == true)
+            {
+                string strDate = InvData.CretateDate.ToString("yyyy/MM/dd");
+
+                KeyValuePair<int, string> KeyVal = new KeyValuePair<int, string>(InvData.InvoiceNo, strDate);
+
+                lstKeyVal.Add(KeyVal);
+            }
+
+            cbCreateDate.ValueMember = "Key";
+            cbCreateDate.DisplayMember = "Value";
+
+            // コンボボックス初期表示
+            ComboBoxAction.InitDataSetCombBox(cbCreateDate, lstKeyVal, false);
+
+            return;
+        }
+
+        #endregion
+
+        #region 作成チェック
+        private int CheckGenerate(ref string msg)
+        {
+            int nInvoiceNo = int.Parse(cbCreateDate.SelectedValue.ToString());
+
+            int nSelect = int.Parse(lbSelect.Text.ToString());
+            int nRet = (int)CheckState.Ok;
+
+            // 選択なし
+            if (nSelect == 0)
+            {
+                msg = "請求件名が選択されていません";
+
+                return (int)CheckState.Error;
+            }
+
+            int tcol = 0;
+            for (int i = 1; i < dgv1.Rows.Count; i++)
+            {
+                // 請求ヘッダが紐づいていない行はダミー
+                if (dgv1[4, i].Value == null)
+                {
+                    break;
+                }
+
+                // 選択れている場合
+                if (dgv1[tcol, i].EditedFormattedValue.Equals(true) == true)
+                {
+                    if (dgv1[5, i].Value == null)
+                    {
+                        continue;
+                    }
+
+                    if (int.Parse(dgv1[5, i].Value.ToString()) != nInvoiceNo)
+                    {
+                        nRet = (int)CheckState.Warning;
+                        break;
+                    }
+                }
+            }
+
+            if (nRet == (int)CheckState.Warning)
+            {
+                msg = "他で請求されている請求件名が選択されています。\nこの内容で請求書を作成してよろしいですか？";
+                return nRet;
+            }
+
+            for (int i = 1; i < dgv1.Rows.Count; i++)
+            {
+                // 請求ヘッダが紐づいていない行はダミー
+                if (dgv1[4, i].Value == null)
+                {
+                    break;
+                }
+
+
+                // 選択れている場合
+                if (dgv1[tcol, i].EditedFormattedValue.Equals(true) == true)
+                {
+                    if (dgv1[5, i].Value != null)
+                    {
+                        continue;
+                    }
+
+                    if (InvoiceNo > 0)
+                    {
+                            msg = "既に作成済の請求書に新規請求件名を追加します。\nこの内容で請求書を作成してよろしいですか？";
+                            nRet = (int)CheckState.Warning;
+                            break;
+                    }
+                }
+            }
+
+
+            if (nRet == (int)CheckState.Ok)
+            {
+                msg = "この内容で請求書を作成してよろしいですか？";
+            }
+
+            return nRet;
+            
+        }
+        #endregion
+
+        #region 請求書データ登録
+
+        private int EntryData()
+        {
+            int nInvoiceNo = int.Parse(cbCreateDate.SelectedValue.ToString());
+
+            List<RequestHead> lstReqHead = new List<RequestHead>();
+
+            int tcol = 0;
+            for (int i = 1; i < dgv1.Rows.Count; i++)
+            {
+                // 請求ヘッダが紐づいていない行はダミー
+                if (dgv1[4, i].Value == null)
+                {
+                    break;
+                }
+
+                // 選択れている場合
+                if (dgv1[tcol, i].EditedFormattedValue.Equals(true) == true)
+                {
+                    lstReqHead.Add(m_lstReqHead[i-1]);
+                }
+            }
+
+            // 請求書データの登録
+            nInvoiceNo = AddInvoiceData(nInvoiceNo, lstReqHead);
+
+            return nInvoiceNo;
+        }
+
+        #endregion
+
+        #region 請求書データの登録
+
+        private int AddInvoiceData(int nInvoiceNo, List<RequestHead> lstReqHead)
+        {
+            IOInvoiceData ioInvData = new IOInvoiceData();
+            IORequestHead ioReqHead = new IORequestHead();
+
+            InvoiceData InvData = null;
+
+
+            ioInvData.beginTran();
+            ioReqHead.beginTran();
+
+            try
+            {
+                // 請求書Noが指定されていない場合
+                if (nInvoiceNo == 0)
+                {
+                    // 請求書Noの採番
+                    nInvoiceNo = ioInvData.NumberingInvoiceNo(m_nRequestMonth);
+                    if (nInvoiceNo == -1)
+                    {
+                        // DBロールバック
+                        ioInvData.rollback();
+                        ioReqHead.rollback();
+
+                        return -1;
+                    }
+
+                    // 請求書データ構築
+                    InvData = new InvoiceData();
+
+                    InvData.InvoiceNo = nInvoiceNo;
+                    InvData.OrderersDivision = m_nOrderersDivision;
+                    InvData.OrderersCode = m_nOrderersCode;
+                    InvData.RequestMonth = m_nRequestMonth;
+                    InvData.SeqNo = ioInvData.NumberingSeqNo(m_nOrderersDivision, m_nOrderersCode,m_nRequestMonth);
+                    InvData.CretateDate = DateTime.Now;
+                    InvData.RequestDate = DateTime.MinValue;
+                    InvData.RequestName = m_strOrderersName;
+                    InvData.TotalAmount = 0;
+                    InvData.TaxAmount = 0;
+
+                    // 請求書データの挿入
+                    if (ioInvData.InsertAction(InvData) == false)
+                    {
+                        // DBロールバック
+                        ioInvData.rollback();
+                        ioReqHead.rollback();
+
+                        return -1;
+                    }
+                }
+                else
+                {
+                    // 請求書データの取得
+                    if (m_dicInvData.TryGetValue(nInvoiceNo, out InvData) == false)
+                    {
+                        // DBロールバック
+                        ioInvData.rollback();
+                        ioReqHead.rollback();
+                        return -1;
+                    }
+
+                    // 作成日のみ更新
+                    InvData.CretateDate = DateTime.Now;
+                    InvData.TotalAmount = 0;
+                    InvData.TaxAmount = 0;
+
+                    // 請求書データの更新
+                    string sql = string.Format(" Where InvoiceNo = {0}", nInvoiceNo);
+                    if (ioInvData.UpdateAction(sql, InvData) == false)
+                    {
+                        // DBロールバック
+                        ioInvData.rollback();
+                        ioReqHead.rollback();
+
+                        return -1;
+                    }
+                }
+
+                // 選択されている請求ヘッダの請求書Noを更新
+                foreach (RequestHead ReqHead in lstReqHead)
+                {
+                    ReqHead.InvoiceNo = nInvoiceNo;
+                }
+                if (ioReqHead.UpdateAction(lstReqHead) == false)
+                {
+                    // DBロールバック
+                    ioInvData.rollback();
+                    ioReqHead.rollback();
+
+                    return -1;
+                }
+
+                // DBコミット
+                ioInvData.commit();
+                ioReqHead.commit();
+
+                return nInvoiceNo;
+            }
+            catch (Exception ex)
+            {
+                logger.ErrorFormat("システムエラー：{0}：{1}", CommonMotions.GetMethodName(), ex.Message);
+                return -1;
+            }
+            finally
+            {
+                ioInvData.close();
+                ioInvData = null;
+                ioReqHead.close();
+                ioReqHead = null;
+            }
+        }
+
+        #endregion
+
+        #region 請求書配下の金額を取得
+        private void GetReqHeadAmount(List<RequestHead> lstReqHead, ref int nTotalAmount, ref int nTaxAmount)
+        {
+            foreach (RequestHead ReqHead in lstReqHead)
+            {
+                nTotalAmount += ReqHead.RequestTotalAmount;
+                nTaxAmount += ReqHead.TaxAmount;
+            }
+            return;
+        }
+        #endregion
+
+        #region 請求データの削除
+        private bool DeleteInvoiceData(int nInvoiceNo)
+        {
+            string sql = "";
+
+            IOInvoiceData ioInvData = new IOInvoiceData();
+            IORequestHead ioReqHead = new IORequestHead();
+
+            ioInvData.beginTran();
+            ioReqHead.beginTran();
+
+            try
+            {
+                // 請求書データの削除
+                sql = string.Format(" Where InvoiceNo = {0}", nInvoiceNo);
+                if (ioInvData.DeleteAction(sql) == false)
+                {
+                    ioInvData.rollback();
+                    ioReqHead.rollback();
+
+                    return false;
+                }
+
+                List<RequestHead> lstReqHead = new List<RequestHead>();
+
+                sql = string.Format(" Where InvoiceNo = {0}", nInvoiceNo);
+                if (ioReqHead.SelectAction(sql, ref lstReqHead) == false)
+                {
+                    ioInvData.rollback();
+                    ioReqHead.rollback();
+
+                    return false;
+                }
+
+                // 請求ヘッダの請求書Noをクリア
+                foreach (RequestHead ReqHead in lstReqHead)
+                {
+                    ReqHead.InvoiceNo = 0;
+
+                    
+                }
+
+                // 請求ヘッダを更新
+                if (ioReqHead.UpdateAction(lstReqHead) == false)
+                {
+                    ioInvData.rollback();
+                    ioReqHead.rollback();
+
+                    return false;
+
+                }
+
+                ioInvData.commit();
+                ioReqHead.commit();
+
+                return true; 
+
+            }
+            catch (Exception ex)
+            {
+                logger.ErrorFormat("システムエラー：{0}：{1}", CommonMotions.GetMethodName(), ex.Message);
+                return false;
+            }
+            finally
+            {
+                ioInvData.close();
+                ioInvData = null;
+                ioReqHead.close();
+                ioReqHead = null;
+            }
+
+        }
+        #endregion
+
+    }
+}
Index: branches/src/ProcessManagement/ProcessManagement/Forms/DataEntry/Request/RequestEntry/FrmEntryReqSelRequest.resx
===================================================================
--- branches/src/ProcessManagement/ProcessManagement/Forms/DataEntry/Request/RequestEntry/FrmEntryReqSelRequest.resx	(nonexistent)
+++ branches/src/ProcessManagement/ProcessManagement/Forms/DataEntry/Request/RequestEntry/FrmEntryReqSelRequest.resx	(revision 60)
@@ -0,0 +1,138 @@
+﻿<?xml version="1.0" encoding="utf-8"?>
+<root>
+  <!-- 
+    Microsoft ResX Schema 
+    
+    Version 2.0
+    
+    The primary goals of this format is to allow a simple XML format 
+    that is mostly human readable. The generation and parsing of the 
+    various data types are done through the TypeConverter classes 
+    associated with the data types.
+    
+    Example:
+    
+    ... ado.net/XML headers & schema ...
+    <resheader name="resmimetype">text/microsoft-resx</resheader>
+    <resheader name="version">2.0</resheader>
+    <resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
+    <resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
+    <data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
+    <data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
+    <data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
+        <value>[base64 mime encoded serialized .NET Framework object]</value>
+    </data>
+    <data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
+        <value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
+        <comment>This is a comment</comment>
+    </data>
+                
+    There are any number of "resheader" rows that contain simple 
+    name/value pairs.
+    
+    Each data row contains a name, and value. The row also contains a 
+    type or mimetype. Type corresponds to a .NET class that support 
+    text/value conversion through the TypeConverter architecture. 
+    Classes that don't support this are serialized and stored with the 
+    mimetype set.
+    
+    The mimetype is used for serialized objects, and tells the 
+    ResXResourceReader how to depersist the object. This is currently not 
+    extensible. For a given mimetype the value must be set accordingly:
+    
+    Note - application/x-microsoft.net.object.binary.base64 is the format 
+    that the ResXResourceWriter will generate, however the reader can 
+    read any of the formats listed below.
+    
+    mimetype: application/x-microsoft.net.object.binary.base64
+    value   : The object must be serialized with 
+            : System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
+            : and then encoded with base64 encoding.
+    
+    mimetype: application/x-microsoft.net.object.soap.base64
+    value   : The object must be serialized with 
+            : System.Runtime.Serialization.Formatters.Soap.SoapFormatter
+            : and then encoded with base64 encoding.
+
+    mimetype: application/x-microsoft.net.object.bytearray.base64
+    value   : The object must be serialized into a byte array 
+            : using a System.ComponentModel.TypeConverter
+            : and then encoded with base64 encoding.
+    -->
+  <xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
+    <xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
+    <xsd:element name="root" msdata:IsDataSet="true">
+      <xsd:complexType>
+        <xsd:choice maxOccurs="unbounded">
+          <xsd:element name="metadata">
+            <xsd:complexType>
+              <xsd:sequence>
+                <xsd:element name="value" type="xsd:string" minOccurs="0" />
+              </xsd:sequence>
+              <xsd:attribute name="name" use="required" type="xsd:string" />
+              <xsd:attribute name="type" type="xsd:string" />
+              <xsd:attribute name="mimetype" type="xsd:string" />
+              <xsd:attribute ref="xml:space" />
+            </xsd:complexType>
+          </xsd:element>
+          <xsd:element name="assembly">
+            <xsd:complexType>
+              <xsd:attribute name="alias" type="xsd:string" />
+              <xsd:attribute name="name" type="xsd:string" />
+            </xsd:complexType>
+          </xsd:element>
+          <xsd:element name="data">
+            <xsd:complexType>
+              <xsd:sequence>
+                <xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
+                <xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
+              </xsd:sequence>
+              <xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
+              <xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
+              <xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
+              <xsd:attribute ref="xml:space" />
+            </xsd:complexType>
+          </xsd:element>
+          <xsd:element name="resheader">
+            <xsd:complexType>
+              <xsd:sequence>
+                <xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
+              </xsd:sequence>
+              <xsd:attribute name="name" type="xsd:string" use="required" />
+            </xsd:complexType>
+          </xsd:element>
+        </xsd:choice>
+      </xsd:complexType>
+    </xsd:element>
+  </xsd:schema>
+  <resheader name="resmimetype">
+    <value>text/microsoft-resx</value>
+  </resheader>
+  <resheader name="version">
+    <value>2.0</value>
+  </resheader>
+  <resheader name="reader">
+    <value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
+  </resheader>
+  <resheader name="writer">
+    <value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
+  </resheader>
+  <metadata name="col1.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="col2.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="col3.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="col4.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="col5.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="col6.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+</root>
\ No newline at end of file
Index: branches/src/ProcessManagement/ProcessManagement/Forms/DataEntry/Request/RequestInput/FrmRequestInput.Designer.cs
===================================================================
--- branches/src/ProcessManagement/ProcessManagement/Forms/DataEntry/Request/RequestInput/FrmRequestInput.Designer.cs	(revision 59)
+++ branches/src/ProcessManagement/ProcessManagement/Forms/DataEntry/Request/RequestInput/FrmRequestInput.Designer.cs	(revision 60)
@@ -28,37 +28,75 @@
         /// </summary>
         private void InitializeComponent()
         {
-            System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle64 = new System.Windows.Forms.DataGridViewCellStyle();
-            System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle65 = new System.Windows.Forms.DataGridViewCellStyle();
-            System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle66 = new System.Windows.Forms.DataGridViewCellStyle();
-            System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle67 = new System.Windows.Forms.DataGridViewCellStyle();
-            System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle68 = new System.Windows.Forms.DataGridViewCellStyle();
-            System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle69 = new System.Windows.Forms.DataGridViewCellStyle();
-            System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle70 = new System.Windows.Forms.DataGridViewCellStyle();
-            System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle71 = new System.Windows.Forms.DataGridViewCellStyle();
-            System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle72 = new System.Windows.Forms.DataGridViewCellStyle();
+            System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle1 = new System.Windows.Forms.DataGridViewCellStyle();
+            System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle2 = new System.Windows.Forms.DataGridViewCellStyle();
+            System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle3 = new System.Windows.Forms.DataGridViewCellStyle();
+            System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle4 = new System.Windows.Forms.DataGridViewCellStyle();
+            System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle5 = new System.Windows.Forms.DataGridViewCellStyle();
+            System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle6 = new System.Windows.Forms.DataGridViewCellStyle();
+            System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle7 = new System.Windows.Forms.DataGridViewCellStyle();
+            System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle8 = new System.Windows.Forms.DataGridViewCellStyle();
+            System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle9 = new System.Windows.Forms.DataGridViewCellStyle();
+            System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle10 = new System.Windows.Forms.DataGridViewCellStyle();
+            System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle11 = new System.Windows.Forms.DataGridViewCellStyle();
+            System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle12 = new System.Windows.Forms.DataGridViewCellStyle();
+            System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle13 = new System.Windows.Forms.DataGridViewCellStyle();
+            System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle14 = new System.Windows.Forms.DataGridViewCellStyle();
+            System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle15 = new System.Windows.Forms.DataGridViewCellStyle();
+            System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle16 = new System.Windows.Forms.DataGridViewCellStyle();
+            System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle17 = new System.Windows.Forms.DataGridViewCellStyle();
+            System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle18 = new System.Windows.Forms.DataGridViewCellStyle();
+            System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle19 = new System.Windows.Forms.DataGridViewCellStyle();
+            System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle20 = new System.Windows.Forms.DataGridViewCellStyle();
+            System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle21 = new System.Windows.Forms.DataGridViewCellStyle();
             this.label3 = new System.Windows.Forms.Label();
             this.dgv1 = new System.Windows.Forms.DataGridView();
-            this.GridSectionIndex = new System.Windows.Forms.DataGridViewTextBoxColumn();
-            this.GridRowKind = new System.Windows.Forms.DataGridViewTextBoxColumn();
-            this.GridConstructionCode = new System.Windows.Forms.DataGridViewTextBoxColumn();
-            this.col0 = new System.Windows.Forms.DataGridViewTextBoxColumn();
-            this.col1 = new System.Windows.Forms.DataGridViewTextBoxColumn();
-            this.col3 = new System.Windows.Forms.DataGridViewTextBoxColumn();
-            this.col4 = new System.Windows.Forms.DataGridViewTextBoxColumn();
-            this.col5 = new System.Windows.Forms.DataGridViewTextBoxColumn();
-            this.col6 = new System.Windows.Forms.DataGridViewTextBoxColumn();
-            this.col7 = new System.Windows.Forms.DataGridViewTextBoxColumn();
-            this.col8 = new System.Windows.Forms.DataGridViewTextBoxColumn();
-            this.col11 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.col001 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.col002 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.col003 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.col004 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.col005 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.col006 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.col007 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.col008 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.col009 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.col010 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.col011 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.col12 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.col13 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.col14 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.col15 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.col16 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.col17 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.col18 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.col19 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.col20 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.col21 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.col22 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.col23 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.col098 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.col99 = new System.Windows.Forms.DataGridViewTextBoxColumn();
             this.label2 = new System.Windows.Forms.Label();
-            this.label1 = new System.Windows.Forms.Label();
-            this.button3 = new System.Windows.Forms.Button();
-            this.button2 = new System.Windows.Forms.Button();
+            this.btnEntry = new System.Windows.Forms.Button();
+            this.btnEnd = new System.Windows.Forms.Button();
             this.btnAdd = new System.Windows.Forms.Button();
             this.btnOtherProc = new System.Windows.Forms.Button();
             this.lblStatus = new System.Windows.Forms.Label();
+            this.label4 = new System.Windows.Forms.Label();
+            this.cbReqMonth = new System.Windows.Forms.ComboBox();
+            this.label5 = new System.Windows.Forms.Label();
+            this.lblReqOrder = new System.Windows.Forms.Label();
+            this.btnApproval = new System.Windows.Forms.Button();
+            this.txtOrderer = new System.Windows.Forms.TextBox();
+            this.button1 = new System.Windows.Forms.Button();
+            this.pnlNormal = new System.Windows.Forms.Panel();
+            this.pnlApproval = new System.Windows.Forms.Panel();
+            this.btnDeny = new System.Windows.Forms.Button();
+            this.btnPend = new System.Windows.Forms.Button();
+            this.btnAgree = new System.Windows.Forms.Button();
             ((System.ComponentModel.ISupportInitialize)(this.dgv1)).BeginInit();
+            this.pnlNormal.SuspendLayout();
+            this.pnlApproval.SuspendLayout();
             this.SuspendLayout();
             // 
             // label3
@@ -65,7 +103,7 @@
             // 
             this.label3.BackColor = System.Drawing.Color.White;
             this.label3.Font = new System.Drawing.Font("ＭＳ Ｐゴシック", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(128)));
-            this.label3.Location = new System.Drawing.Point(495, 20);
+            this.label3.Location = new System.Drawing.Point(510, 14);
             this.label3.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
             this.label3.Name = "label3";
             this.label3.Size = new System.Drawing.Size(340, 38);
@@ -79,151 +117,309 @@
             this.dgv1.ColumnHeadersHeight = 34;
             this.dgv1.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.DisableResizing;
             this.dgv1.Columns.AddRange(new System.Windows.Forms.DataGridViewColumn[] {
-            this.GridSectionIndex,
-            this.GridRowKind,
-            this.GridConstructionCode,
-            this.col0,
-            this.col1,
-            this.col3,
-            this.col4,
-            this.col5,
-            this.col6,
-            this.col7,
-            this.col8,
-            this.col11});
-            this.dgv1.Location = new System.Drawing.Point(12, 108);
+            this.col001,
+            this.col002,
+            this.col003,
+            this.col004,
+            this.col005,
+            this.col006,
+            this.col007,
+            this.col008,
+            this.col009,
+            this.col010,
+            this.col011,
+            this.col12,
+            this.col13,
+            this.col14,
+            this.col15,
+            this.col16,
+            this.col17,
+            this.col18,
+            this.col19,
+            this.col20,
+            this.col21,
+            this.col22,
+            this.col23,
+            this.col098,
+            this.col99});
+            this.dgv1.Location = new System.Drawing.Point(12, 100);
             this.dgv1.Name = "dgv1";
             this.dgv1.RowHeadersWidth = 24;
             this.dgv1.RowTemplate.Height = 21;
-            this.dgv1.Size = new System.Drawing.Size(1306, 547);
+            this.dgv1.Size = new System.Drawing.Size(1308, 439);
             this.dgv1.TabIndex = 4;
-            this.dgv1.CellContentClick += new System.Windows.Forms.DataGridViewCellEventHandler(this.dgv1_CellContentClick);
+            this.dgv1.CellBeginEdit += new System.Windows.Forms.DataGridViewCellCancelEventHandler(this.dgv1_CellBeginEdit);
+            this.dgv1.CellFormatting += new System.Windows.Forms.DataGridViewCellFormattingEventHandler(this.dgv1_CellFormatting);
+            this.dgv1.CellValidating += new System.Windows.Forms.DataGridViewCellValidatingEventHandler(this.dgv1_CellValidating);
             this.dgv1.CellValueChanged += new System.Windows.Forms.DataGridViewCellEventHandler(this.dgv1_CellValueChanged);
-            this.dgv1.CurrentCellChanged += new System.EventHandler(this.dgv1_CurrentCellChanged);
-            this.dgv1.SelectionChanged += new System.EventHandler(this.dgv1_SelectionChanged);
             // 
-            // GridSectionIndex
+            // col001
             // 
-            this.GridSectionIndex.Frozen = true;
-            this.GridSectionIndex.HeaderText = "";
-            this.GridSectionIndex.Name = "GridSectionIndex";
-            this.GridSectionIndex.Visible = false;
+            this.col001.Frozen = true;
+            this.col001.HeaderText = "";
+            this.col001.Name = "col001";
+            this.col001.Visible = false;
+            this.col001.Width = 60;
             // 
-            // GridRowKind
+            // col002
             // 
-            this.GridRowKind.Frozen = true;
-            this.GridRowKind.HeaderText = "";
-            this.GridRowKind.Name = "GridRowKind";
-            this.GridRowKind.Visible = false;
+            this.col002.Frozen = true;
+            this.col002.HeaderText = "";
+            this.col002.Name = "col002";
+            this.col002.Visible = false;
             // 
-            // GridConstructionCode
+            // col003
             // 
-            this.GridConstructionCode.Frozen = true;
-            this.GridConstructionCode.HeaderText = "";
-            this.GridConstructionCode.Name = "GridConstructionCode";
-            this.GridConstructionCode.Visible = false;
+            this.col003.Frozen = true;
+            this.col003.HeaderText = "";
+            this.col003.Name = "col003";
+            this.col003.Visible = false;
+            this.col003.Width = 120;
             // 
-            // col0
+            // col004
             // 
-            this.col0.AutoSizeMode = System.Windows.Forms.DataGridViewAutoSizeColumnMode.None;
-            dataGridViewCellStyle64.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleCenter;
-            dataGridViewCellStyle64.BackColor = System.Drawing.SystemColors.Control;
-            this.col0.DefaultCellStyle = dataGridViewCellStyle64;
-            this.col0.Frozen = true;
-            this.col0.HeaderText = "";
-            this.col0.Name = "col0";
-            this.col0.ReadOnly = true;
-            this.col0.Resizable = System.Windows.Forms.DataGridViewTriState.False;
-            this.col0.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable;
-            this.col0.Width = 80;
+            this.col004.AutoSizeMode = System.Windows.Forms.DataGridViewAutoSizeColumnMode.None;
+            dataGridViewCellStyle1.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleCenter;
+            dataGridViewCellStyle1.BackColor = System.Drawing.SystemColors.Control;
+            this.col004.DefaultCellStyle = dataGridViewCellStyle1;
+            this.col004.Frozen = true;
+            this.col004.HeaderText = "";
+            this.col004.Name = "col004";
+            this.col004.ReadOnly = true;
+            this.col004.Resizable = System.Windows.Forms.DataGridViewTriState.False;
+            this.col004.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable;
+            this.col004.Width = 80;
             // 
-            // col1
+            // col005
             // 
-            dataGridViewCellStyle65.BackColor = System.Drawing.Color.White;
-            this.col1.DefaultCellStyle = dataGridViewCellStyle65;
-            this.col1.Frozen = true;
-            this.col1.HeaderText = "工事名";
-            this.col1.Name = "col1";
-            this.col1.ReadOnly = true;
-            this.col1.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable;
-            this.col1.Width = 340;
+            dataGridViewCellStyle2.BackColor = System.Drawing.Color.White;
+            this.col005.DefaultCellStyle = dataGridViewCellStyle2;
+            this.col005.Frozen = true;
+            this.col005.HeaderText = "";
+            this.col005.Name = "col005";
+            this.col005.ReadOnly = true;
+            this.col005.Resizable = System.Windows.Forms.DataGridViewTriState.False;
+            this.col005.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable;
+            this.col005.Width = 340;
             // 
-            // col3
+            // col006
             // 
-            dataGridViewCellStyle66.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleRight;
-            dataGridViewCellStyle66.BackColor = System.Drawing.Color.White;
-            this.col3.DefaultCellStyle = dataGridViewCellStyle66;
-            this.col3.Frozen = true;
-            this.col3.HeaderText = "受注金額";
-            this.col3.Name = "col3";
-            this.col3.ReadOnly = true;
-            this.col3.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable;
-            this.col3.Width = 120;
+            dataGridViewCellStyle3.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleRight;
+            dataGridViewCellStyle3.BackColor = System.Drawing.Color.White;
+            this.col006.DefaultCellStyle = dataGridViewCellStyle3;
+            this.col006.Frozen = true;
+            this.col006.HeaderText = "受注金額";
+            this.col006.Name = "col006";
+            this.col006.ReadOnly = true;
+            this.col006.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable;
+            this.col006.Width = 120;
             // 
-            // col4
+            // col007
             // 
-            dataGridViewCellStyle67.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleCenter;
-            dataGridViewCellStyle67.BackColor = System.Drawing.SystemColors.Control;
-            this.col4.DefaultCellStyle = dataGridViewCellStyle67;
-            this.col4.Frozen = true;
-            this.col4.HeaderText = "";
-            this.col4.Name = "col4";
-            this.col4.ReadOnly = true;
-            this.col4.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable;
-            this.col4.Width = 120;
+            dataGridViewCellStyle4.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleCenter;
+            dataGridViewCellStyle4.BackColor = System.Drawing.SystemColors.Control;
+            this.col007.DefaultCellStyle = dataGridViewCellStyle4;
+            this.col007.Frozen = true;
+            this.col007.HeaderText = "";
+            this.col007.Name = "col007";
+            this.col007.ReadOnly = true;
+            this.col007.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable;
+            this.col007.Width = 120;
             // 
-            // col5
+            // col008
             // 
-            dataGridViewCellStyle68.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleRight;
-            this.col5.DefaultCellStyle = dataGridViewCellStyle68;
-            this.col5.FillWeight = 120F;
-            this.col5.Frozen = true;
-            this.col5.HeaderText = "合計";
-            this.col5.Name = "col5";
-            this.col5.ReadOnly = true;
-            this.col5.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable;
-            this.col5.Width = 120;
+            dataGridViewCellStyle5.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleRight;
+            this.col008.DefaultCellStyle = dataGridViewCellStyle5;
+            this.col008.FillWeight = 120F;
+            this.col008.Frozen = true;
+            this.col008.HeaderText = "合計";
+            this.col008.Name = "col008";
+            this.col008.ReadOnly = true;
+            this.col008.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable;
+            this.col008.Width = 120;
             // 
-            // col6
+            // col009
             // 
-            dataGridViewCellStyle69.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleRight;
-            this.col6.DefaultCellStyle = dataGridViewCellStyle69;
-            this.col6.HeaderText = "1回目";
-            this.col6.Name = "col6";
-            this.col6.ReadOnly = true;
-            this.col6.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable;
-            this.col6.Width = 120;
+            dataGridViewCellStyle6.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleRight;
+            this.col009.DefaultCellStyle = dataGridViewCellStyle6;
+            this.col009.HeaderText = "1回目";
+            this.col009.Name = "col009";
+            this.col009.ReadOnly = true;
+            this.col009.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable;
+            this.col009.Width = 120;
             // 
-            // col7
+            // col010
             // 
-            dataGridViewCellStyle70.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleRight;
-            this.col7.DefaultCellStyle = dataGridViewCellStyle70;
-            this.col7.HeaderText = "2回目";
-            this.col7.Name = "col7";
-            this.col7.ReadOnly = true;
-            this.col7.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable;
-            this.col7.Width = 120;
+            dataGridViewCellStyle7.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleRight;
+            this.col010.DefaultCellStyle = dataGridViewCellStyle7;
+            this.col010.HeaderText = "2回目";
+            this.col010.Name = "col010";
+            this.col010.ReadOnly = true;
+            this.col010.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable;
+            this.col010.Width = 120;
             // 
-            // col8
+            // col011
             // 
-            dataGridViewCellStyle71.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleRight;
-            this.col8.DefaultCellStyle = dataGridViewCellStyle71;
-            this.col8.HeaderText = "3回目";
-            this.col8.Name = "col8";
-            this.col8.ReadOnly = true;
-            this.col8.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable;
-            this.col8.Width = 120;
+            dataGridViewCellStyle8.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleRight;
+            this.col011.DefaultCellStyle = dataGridViewCellStyle8;
+            this.col011.HeaderText = "3回目";
+            this.col011.Name = "col011";
+            this.col011.ReadOnly = true;
+            this.col011.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable;
+            this.col011.Width = 120;
             // 
-            // col11
+            // col12
             // 
-            dataGridViewCellStyle72.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleRight;
-            this.col11.DefaultCellStyle = dataGridViewCellStyle72;
-            this.col11.HeaderText = "残り";
-            this.col11.Name = "col11";
-            this.col11.ReadOnly = true;
-            this.col11.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable;
-            this.col11.Width = 120;
+            dataGridViewCellStyle9.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleRight;
+            this.col12.DefaultCellStyle = dataGridViewCellStyle9;
+            this.col12.HeaderText = "4回目";
+            this.col12.Name = "col12";
+            this.col12.ReadOnly = true;
+            this.col12.Resizable = System.Windows.Forms.DataGridViewTriState.False;
+            this.col12.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.Programmatic;
+            this.col12.Width = 120;
             // 
+            // col13
+            // 
+            dataGridViewCellStyle10.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleRight;
+            this.col13.DefaultCellStyle = dataGridViewCellStyle10;
+            this.col13.HeaderText = "5回目";
+            this.col13.Name = "col13";
+            this.col13.ReadOnly = true;
+            this.col13.Resizable = System.Windows.Forms.DataGridViewTriState.False;
+            this.col13.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable;
+            this.col13.Width = 120;
+            // 
+            // col14
+            // 
+            dataGridViewCellStyle11.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleRight;
+            this.col14.DefaultCellStyle = dataGridViewCellStyle11;
+            this.col14.HeaderText = "6回目";
+            this.col14.Name = "col14";
+            this.col14.ReadOnly = true;
+            this.col14.Resizable = System.Windows.Forms.DataGridViewTriState.False;
+            this.col14.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.Programmatic;
+            this.col14.Width = 120;
+            // 
+            // col15
+            // 
+            dataGridViewCellStyle12.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleRight;
+            this.col15.DefaultCellStyle = dataGridViewCellStyle12;
+            this.col15.HeaderText = "7回目";
+            this.col15.Name = "col15";
+            this.col15.ReadOnly = true;
+            this.col15.Resizable = System.Windows.Forms.DataGridViewTriState.False;
+            this.col15.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable;
+            this.col15.Width = 120;
+            // 
+            // col16
+            // 
+            dataGridViewCellStyle13.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleRight;
+            this.col16.DefaultCellStyle = dataGridViewCellStyle13;
+            this.col16.HeaderText = "8回目";
+            this.col16.Name = "col16";
+            this.col16.ReadOnly = true;
+            this.col16.Resizable = System.Windows.Forms.DataGridViewTriState.False;
+            this.col16.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable;
+            this.col16.Width = 120;
+            // 
+            // col17
+            // 
+            dataGridViewCellStyle14.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleRight;
+            this.col17.DefaultCellStyle = dataGridViewCellStyle14;
+            this.col17.HeaderText = "9回目";
+            this.col17.Name = "col17";
+            this.col17.ReadOnly = true;
+            this.col17.Resizable = System.Windows.Forms.DataGridViewTriState.False;
+            this.col17.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable;
+            this.col17.Width = 120;
+            // 
+            // col18
+            // 
+            dataGridViewCellStyle15.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleRight;
+            this.col18.DefaultCellStyle = dataGridViewCellStyle15;
+            this.col18.HeaderText = "10回目";
+            this.col18.Name = "col18";
+            this.col18.ReadOnly = true;
+            this.col18.Resizable = System.Windows.Forms.DataGridViewTriState.False;
+            this.col18.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable;
+            this.col18.Width = 120;
+            // 
+            // col19
+            // 
+            dataGridViewCellStyle16.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleRight;
+            this.col19.DefaultCellStyle = dataGridViewCellStyle16;
+            this.col19.HeaderText = "11回目";
+            this.col19.Name = "col19";
+            this.col19.ReadOnly = true;
+            this.col19.Resizable = System.Windows.Forms.DataGridViewTriState.False;
+            this.col19.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.Programmatic;
+            this.col19.Width = 120;
+            // 
+            // col20
+            // 
+            dataGridViewCellStyle17.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleRight;
+            this.col20.DefaultCellStyle = dataGridViewCellStyle17;
+            this.col20.HeaderText = "12回目";
+            this.col20.Name = "col20";
+            this.col20.ReadOnly = true;
+            this.col20.Resizable = System.Windows.Forms.DataGridViewTriState.False;
+            this.col20.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable;
+            this.col20.Width = 120;
+            // 
+            // col21
+            // 
+            dataGridViewCellStyle18.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleRight;
+            this.col21.DefaultCellStyle = dataGridViewCellStyle18;
+            this.col21.HeaderText = "13回目";
+            this.col21.Name = "col21";
+            this.col21.ReadOnly = true;
+            this.col21.Resizable = System.Windows.Forms.DataGridViewTriState.False;
+            this.col21.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable;
+            this.col21.Width = 120;
+            // 
+            // col22
+            // 
+            dataGridViewCellStyle19.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleRight;
+            this.col22.DefaultCellStyle = dataGridViewCellStyle19;
+            this.col22.HeaderText = "14回目";
+            this.col22.Name = "col22";
+            this.col22.ReadOnly = true;
+            this.col22.Resizable = System.Windows.Forms.DataGridViewTriState.False;
+            this.col22.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable;
+            this.col22.Width = 120;
+            // 
+            // col23
+            // 
+            dataGridViewCellStyle20.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleRight;
+            this.col23.DefaultCellStyle = dataGridViewCellStyle20;
+            this.col23.HeaderText = "15回目";
+            this.col23.Name = "col23";
+            this.col23.ReadOnly = true;
+            this.col23.Resizable = System.Windows.Forms.DataGridViewTriState.False;
+            this.col23.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable;
+            this.col23.Width = 120;
+            // 
+            // col098
+            // 
+            dataGridViewCellStyle21.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleRight;
+            this.col098.DefaultCellStyle = dataGridViewCellStyle21;
+            this.col098.HeaderText = "残り";
+            this.col098.Name = "col098";
+            this.col098.ReadOnly = true;
+            this.col098.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable;
+            this.col098.Width = 120;
+            // 
+            // col99
+            // 
+            this.col99.HeaderText = "コメント";
+            this.col99.MaxInputLength = 120;
+            this.col99.Name = "col99";
+            this.col99.ReadOnly = true;
+            this.col99.Resizable = System.Windows.Forms.DataGridViewTriState.False;
+            this.col99.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable;
+            this.col99.Width = 240;
+            // 
             // label2
             // 
             this.label2.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(255)))), ((int)(((byte)(255)))), ((int)(((byte)(128)))));
@@ -230,55 +426,45 @@
             this.label2.BorderStyle = System.Windows.Forms.BorderStyle.Fixed3D;
             this.label2.CausesValidation = false;
             this.label2.Font = new System.Drawing.Font("ＭＳ 明朝", 11.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(128)));
-            this.label2.Location = new System.Drawing.Point(12, 72);
+            this.label2.Location = new System.Drawing.Point(12, 63);
             this.label2.Name = "label2";
-            this.label2.Size = new System.Drawing.Size(80, 25);
+            this.label2.Size = new System.Drawing.Size(100, 25);
             this.label2.TabIndex = 7;
             this.label2.Text = "請求先";
             this.label2.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
             // 
-            // label1
+            // btnEntry
             // 
-            this.label1.BackColor = System.Drawing.Color.White;
-            this.label1.Font = new System.Drawing.Font("ＭＳ 明朝", 12F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(128)));
-            this.label1.Location = new System.Drawing.Point(98, 72);
-            this.label1.Name = "label1";
-            this.label1.Size = new System.Drawing.Size(400, 25);
-            this.label1.TabIndex = 8;
-            this.label1.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
+            this.btnEntry.BackColor = System.Drawing.Color.GreenYellow;
+            this.btnEntry.Font = new System.Drawing.Font("ＭＳ 明朝", 12F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(128)));
+            this.btnEntry.ForeColor = System.Drawing.Color.Black;
+            this.btnEntry.Location = new System.Drawing.Point(1072, 547);
+            this.btnEntry.Name = "btnEntry";
+            this.btnEntry.Size = new System.Drawing.Size(120, 28);
+            this.btnEntry.TabIndex = 16;
+            this.btnEntry.Text = "登　録";
+            this.btnEntry.UseVisualStyleBackColor = false;
+            this.btnEntry.Click += new System.EventHandler(this.btnEntry_Click);
             // 
-            // button3
+            // btnEnd
             // 
-            this.button3.BackColor = System.Drawing.Color.GreenYellow;
-            this.button3.Font = new System.Drawing.Font("ＭＳ 明朝", 12F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(128)));
-            this.button3.ForeColor = System.Drawing.Color.Black;
-            this.button3.Location = new System.Drawing.Point(1073, 671);
-            this.button3.Name = "button3";
-            this.button3.Size = new System.Drawing.Size(120, 28);
-            this.button3.TabIndex = 16;
-            this.button3.Text = "登　録";
-            this.button3.UseVisualStyleBackColor = false;
-            this.button3.Click += new System.EventHandler(this.button3_Click);
+            this.btnEnd.BackColor = System.Drawing.Color.Magenta;
+            this.btnEnd.Font = new System.Drawing.Font("ＭＳ 明朝", 12F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(128)));
+            this.btnEnd.ForeColor = System.Drawing.Color.Black;
+            this.btnEnd.Location = new System.Drawing.Point(1198, 547);
+            this.btnEnd.Name = "btnEnd";
+            this.btnEnd.Size = new System.Drawing.Size(120, 28);
+            this.btnEnd.TabIndex = 15;
+            this.btnEnd.Text = "終　了";
+            this.btnEnd.UseVisualStyleBackColor = false;
+            this.btnEnd.Click += new System.EventHandler(this.btnEnd_Click);
             // 
-            // button2
-            // 
-            this.button2.BackColor = System.Drawing.Color.Magenta;
-            this.button2.Font = new System.Drawing.Font("ＭＳ 明朝", 12F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(128)));
-            this.button2.ForeColor = System.Drawing.Color.Black;
-            this.button2.Location = new System.Drawing.Point(1199, 671);
-            this.button2.Name = "button2";
-            this.button2.Size = new System.Drawing.Size(120, 28);
-            this.button2.TabIndex = 15;
-            this.button2.Text = "終　了";
-            this.button2.UseVisualStyleBackColor = false;
-            this.button2.Click += new System.EventHandler(this.button2_Click);
-            // 
             // btnAdd
             // 
             this.btnAdd.BackColor = System.Drawing.Color.Orange;
             this.btnAdd.Font = new System.Drawing.Font("ＭＳ 明朝", 12F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(128)));
             this.btnAdd.ForeColor = System.Drawing.Color.Black;
-            this.btnAdd.Location = new System.Drawing.Point(158, 671);
+            this.btnAdd.Location = new System.Drawing.Point(158, 547);
             this.btnAdd.Name = "btnAdd";
             this.btnAdd.Size = new System.Drawing.Size(120, 28);
             this.btnAdd.TabIndex = 17;
@@ -291,7 +477,7 @@
             this.btnOtherProc.BackColor = System.Drawing.Color.Lime;
             this.btnOtherProc.Font = new System.Drawing.Font("ＭＳ 明朝", 12F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(128)));
             this.btnOtherProc.ForeColor = System.Drawing.Color.Black;
-            this.btnOtherProc.Location = new System.Drawing.Point(12, 671);
+            this.btnOtherProc.Location = new System.Drawing.Point(12, 547);
             this.btnOtherProc.Name = "btnOtherProc";
             this.btnOtherProc.Size = new System.Drawing.Size(140, 28);
             this.btnOtherProc.TabIndex = 18;
@@ -303,36 +489,183 @@
             // 
             this.lblStatus.BackColor = System.Drawing.Color.GreenYellow;
             this.lblStatus.Font = new System.Drawing.Font("ＭＳ 明朝", 12F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(128)));
-            this.lblStatus.Location = new System.Drawing.Point(1177, 72);
+            this.lblStatus.Location = new System.Drawing.Point(132, 25);
             this.lblStatus.Name = "lblStatus";
-            this.lblStatus.Size = new System.Drawing.Size(141, 26);
+            this.lblStatus.Size = new System.Drawing.Size(35, 16);
             this.lblStatus.TabIndex = 20;
             this.lblStatus.Text = "請求準備";
             this.lblStatus.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
+            this.lblStatus.Visible = false;
             // 
+            // label4
+            // 
+            this.label4.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(255)))), ((int)(((byte)(255)))), ((int)(((byte)(128)))));
+            this.label4.BorderStyle = System.Windows.Forms.BorderStyle.Fixed3D;
+            this.label4.CausesValidation = false;
+            this.label4.Font = new System.Drawing.Font("ＭＳ 明朝", 11.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(128)));
+            this.label4.Location = new System.Drawing.Point(594, 64);
+            this.label4.Name = "label4";
+            this.label4.Size = new System.Drawing.Size(100, 25);
+            this.label4.TabIndex = 21;
+            this.label4.Text = "請求月";
+            this.label4.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
+            // 
+            // cbReqMonth
+            // 
+            this.cbReqMonth.BackColor = System.Drawing.Color.White;
+            this.cbReqMonth.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
+            this.cbReqMonth.FormattingEnabled = true;
+            this.cbReqMonth.Location = new System.Drawing.Point(699, 64);
+            this.cbReqMonth.Name = "cbReqMonth";
+            this.cbReqMonth.Size = new System.Drawing.Size(109, 24);
+            this.cbReqMonth.TabIndex = 22;
+            // 
+            // label5
+            // 
+            this.label5.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(255)))), ((int)(((byte)(255)))), ((int)(((byte)(128)))));
+            this.label5.BorderStyle = System.Windows.Forms.BorderStyle.Fixed3D;
+            this.label5.CausesValidation = false;
+            this.label5.Font = new System.Drawing.Font("ＭＳ 明朝", 11.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(128)));
+            this.label5.Location = new System.Drawing.Point(819, 64);
+            this.label5.Name = "label5";
+            this.label5.Size = new System.Drawing.Size(100, 25);
+            this.label5.TabIndex = 23;
+            this.label5.Text = "請求回数";
+            this.label5.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
+            // 
+            // lblReqOrder
+            // 
+            this.lblReqOrder.BackColor = System.Drawing.Color.White;
+            this.lblReqOrder.Location = new System.Drawing.Point(924, 64);
+            this.lblReqOrder.Name = "lblReqOrder";
+            this.lblReqOrder.Size = new System.Drawing.Size(85, 24);
+            this.lblReqOrder.TabIndex = 24;
+            this.lblReqOrder.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
+            // 
+            // btnApproval
+            // 
+            this.btnApproval.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(255)))), ((int)(((byte)(128)))), ((int)(((byte)(128)))));
+            this.btnApproval.Font = new System.Drawing.Font("ＭＳ 明朝", 11.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(128)));
+            this.btnApproval.Location = new System.Drawing.Point(3, 5);
+            this.btnApproval.Name = "btnApproval";
+            this.btnApproval.Size = new System.Drawing.Size(130, 27);
+            this.btnApproval.TabIndex = 25;
+            this.btnApproval.Text = "請求書申請";
+            this.btnApproval.UseVisualStyleBackColor = false;
+            this.btnApproval.Click += new System.EventHandler(this.btnApproval_Click);
+            // 
+            // txtOrderer
+            // 
+            this.txtOrderer.BackColor = System.Drawing.Color.White;
+            this.txtOrderer.Location = new System.Drawing.Point(117, 65);
+            this.txtOrderer.Name = "txtOrderer";
+            this.txtOrderer.ReadOnly = true;
+            this.txtOrderer.Size = new System.Drawing.Size(470, 23);
+            this.txtOrderer.TabIndex = 26;
+            this.txtOrderer.TextChanged += new System.EventHandler(this.txtOrderer_TextChanged);
+            this.txtOrderer.Validating += new System.ComponentModel.CancelEventHandler(this.txtOrderer_Validating);
+            // 
+            // button1
+            // 
+            this.button1.Font = new System.Drawing.Font("ＭＳ 明朝", 9.75F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(128)));
+            this.button1.Location = new System.Drawing.Point(1271, 25);
+            this.button1.Name = "button1";
+            this.button1.Size = new System.Drawing.Size(45, 23);
+            this.button1.TabIndex = 31;
+            this.button1.Text = "･･･";
+            this.button1.UseVisualStyleBackColor = true;
+            this.button1.Visible = false;
+            this.button1.Click += new System.EventHandler(this.button1_Click_1);
+            // 
+            // pnlNormal
+            // 
+            this.pnlNormal.Controls.Add(this.btnApproval);
+            this.pnlNormal.Location = new System.Drawing.Point(1014, 56);
+            this.pnlNormal.Name = "pnlNormal";
+            this.pnlNormal.Size = new System.Drawing.Size(136, 36);
+            this.pnlNormal.TabIndex = 32;
+            // 
+            // pnlApproval
+            // 
+            this.pnlApproval.Controls.Add(this.btnDeny);
+            this.pnlApproval.Controls.Add(this.btnPend);
+            this.pnlApproval.Controls.Add(this.btnAgree);
+            this.pnlApproval.Location = new System.Drawing.Point(1014, 56);
+            this.pnlApproval.Name = "pnlApproval";
+            this.pnlApproval.Size = new System.Drawing.Size(254, 36);
+            this.pnlApproval.TabIndex = 33;
+            this.pnlApproval.Visible = false;
+            // 
+            // btnDeny
+            // 
+            this.btnDeny.BackColor = System.Drawing.Color.Red;
+            this.btnDeny.Font = new System.Drawing.Font("ＭＳ 明朝", 11.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(128)));
+            this.btnDeny.Location = new System.Drawing.Point(169, 5);
+            this.btnDeny.Name = "btnDeny";
+            this.btnDeny.Size = new System.Drawing.Size(80, 27);
+            this.btnDeny.TabIndex = 27;
+            this.btnDeny.Text = "不承認";
+            this.btnDeny.UseVisualStyleBackColor = false;
+            this.btnDeny.Click += new System.EventHandler(this.btnDeny_Click);
+            // 
+            // btnPend
+            // 
+            this.btnPend.BackColor = System.Drawing.Color.Yellow;
+            this.btnPend.Font = new System.Drawing.Font("ＭＳ 明朝", 11.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(128)));
+            this.btnPend.Location = new System.Drawing.Point(86, 5);
+            this.btnPend.Name = "btnPend";
+            this.btnPend.Size = new System.Drawing.Size(80, 27);
+            this.btnPend.TabIndex = 26;
+            this.btnPend.Text = "保留";
+            this.btnPend.UseVisualStyleBackColor = false;
+            this.btnPend.Click += new System.EventHandler(this.btnPend_Click);
+            // 
+            // btnAgree
+            // 
+            this.btnAgree.BackColor = System.Drawing.Color.Lime;
+            this.btnAgree.Font = new System.Drawing.Font("ＭＳ 明朝", 11.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(128)));
+            this.btnAgree.Location = new System.Drawing.Point(3, 5);
+            this.btnAgree.Name = "btnAgree";
+            this.btnAgree.Size = new System.Drawing.Size(80, 27);
+            this.btnAgree.TabIndex = 25;
+            this.btnAgree.Text = "承認";
+            this.btnAgree.UseVisualStyleBackColor = false;
+            this.btnAgree.Click += new System.EventHandler(this.btnAgree_Click);
+            // 
             // FrmRequestInput
             // 
             this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.None;
             this.BackColor = System.Drawing.Color.Black;
-            this.ClientSize = new System.Drawing.Size(1330, 710);
+            this.ClientSize = new System.Drawing.Size(1328, 588);
+            this.Controls.Add(this.pnlNormal);
+            this.Controls.Add(this.button1);
+            this.Controls.Add(this.txtOrderer);
+            this.Controls.Add(this.lblReqOrder);
+            this.Controls.Add(this.label5);
+            this.Controls.Add(this.cbReqMonth);
+            this.Controls.Add(this.label4);
             this.Controls.Add(this.lblStatus);
             this.Controls.Add(this.dgv1);
             this.Controls.Add(this.btnOtherProc);
             this.Controls.Add(this.btnAdd);
-            this.Controls.Add(this.button3);
-            this.Controls.Add(this.button2);
-            this.Controls.Add(this.label1);
+            this.Controls.Add(this.btnEntry);
+            this.Controls.Add(this.btnEnd);
             this.Controls.Add(this.label2);
             this.Controls.Add(this.label3);
-            this.Font = new System.Drawing.Font("ＭＳ 明朝", 12F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(128)));
+            this.Controls.Add(this.pnlApproval);
+            this.Font = new System.Drawing.Font("ＭＳ 明朝", 12F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(128)));
             this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedSingle;
             this.Margin = new System.Windows.Forms.Padding(4);
             this.MaximizeBox = false;
             this.MinimizeBox = false;
             this.Name = "FrmRequestInput";
-            this.Load += new System.EventHandler(this.Form1_Load);
+            this.Activated += new System.EventHandler(this.FrmRequestInput_Activated);
+            this.Load += new System.EventHandler(this.FrmRequestInput_Load);
             ((System.ComponentModel.ISupportInitialize)(this.dgv1)).EndInit();
+            this.pnlNormal.ResumeLayout(false);
+            this.pnlApproval.ResumeLayout(false);
             this.ResumeLayout(false);
+            this.PerformLayout();
 
         }
 
@@ -341,24 +674,48 @@
         private System.Windows.Forms.Label label3;
         private System.Windows.Forms.DataGridView dgv1;
         private System.Windows.Forms.Label label2;
-        private System.Windows.Forms.Label label1;
-        private System.Windows.Forms.Button button3;
-        private System.Windows.Forms.Button button2;
+        private System.Windows.Forms.Button btnEntry;
+        private System.Windows.Forms.Button btnEnd;
         private System.Windows.Forms.Button btnAdd;
         private System.Windows.Forms.Button btnOtherProc;
         private System.Windows.Forms.Label lblStatus;
-        private System.Windows.Forms.DataGridViewTextBoxColumn GridSectionIndex;
-        private System.Windows.Forms.DataGridViewTextBoxColumn GridRowKind;
-        private System.Windows.Forms.DataGridViewTextBoxColumn GridConstructionCode;
-        private System.Windows.Forms.DataGridViewTextBoxColumn col0;
-        private System.Windows.Forms.DataGridViewTextBoxColumn col1;
-        private System.Windows.Forms.DataGridViewTextBoxColumn col3;
-        private System.Windows.Forms.DataGridViewTextBoxColumn col4;
-        private System.Windows.Forms.DataGridViewTextBoxColumn col5;
-        private System.Windows.Forms.DataGridViewTextBoxColumn col6;
-        private System.Windows.Forms.DataGridViewTextBoxColumn col7;
-        private System.Windows.Forms.DataGridViewTextBoxColumn col8;
-        private System.Windows.Forms.DataGridViewTextBoxColumn col11;
+        private System.Windows.Forms.Label label4;
+        private System.Windows.Forms.ComboBox cbReqMonth;
+        private System.Windows.Forms.Label label5;
+        private System.Windows.Forms.Label lblReqOrder;
+        private System.Windows.Forms.Button btnApproval;
+        private System.Windows.Forms.TextBox txtOrderer;
+        private System.Windows.Forms.Button button1;
+        private System.Windows.Forms.DataGridViewTextBoxColumn col001;
+        private System.Windows.Forms.DataGridViewTextBoxColumn col002;
+        private System.Windows.Forms.DataGridViewTextBoxColumn col003;
+        private System.Windows.Forms.DataGridViewTextBoxColumn col004;
+        private System.Windows.Forms.DataGridViewTextBoxColumn col005;
+        private System.Windows.Forms.DataGridViewTextBoxColumn col006;
+        private System.Windows.Forms.DataGridViewTextBoxColumn col007;
+        private System.Windows.Forms.DataGridViewTextBoxColumn col008;
+        private System.Windows.Forms.DataGridViewTextBoxColumn col009;
+        private System.Windows.Forms.DataGridViewTextBoxColumn col010;
+        private System.Windows.Forms.DataGridViewTextBoxColumn col011;
+        private System.Windows.Forms.DataGridViewTextBoxColumn col12;
+        private System.Windows.Forms.DataGridViewTextBoxColumn col13;
+        private System.Windows.Forms.DataGridViewTextBoxColumn col14;
+        private System.Windows.Forms.DataGridViewTextBoxColumn col15;
+        private System.Windows.Forms.DataGridViewTextBoxColumn col16;
+        private System.Windows.Forms.DataGridViewTextBoxColumn col17;
+        private System.Windows.Forms.DataGridViewTextBoxColumn col18;
+        private System.Windows.Forms.DataGridViewTextBoxColumn col19;
+        private System.Windows.Forms.DataGridViewTextBoxColumn col20;
+        private System.Windows.Forms.DataGridViewTextBoxColumn col21;
+        private System.Windows.Forms.DataGridViewTextBoxColumn col22;
+        private System.Windows.Forms.DataGridViewTextBoxColumn col23;
+        private System.Windows.Forms.DataGridViewTextBoxColumn col098;
+        private System.Windows.Forms.DataGridViewTextBoxColumn col99;
+        private System.Windows.Forms.Panel pnlNormal;
+        private System.Windows.Forms.Panel pnlApproval;
+        private System.Windows.Forms.Button btnAgree;
+        private System.Windows.Forms.Button btnDeny;
+        private System.Windows.Forms.Button btnPend;
     }
 }
 
Index: branches/src/ProcessManagement/ProcessManagement/Forms/DataEntry/Request/RequestInput/FrmRequestInput.cs
===================================================================
--- branches/src/ProcessManagement/ProcessManagement/Forms/DataEntry/Request/RequestInput/FrmRequestInput.cs	(revision 59)
+++ branches/src/ProcessManagement/ProcessManagement/Forms/DataEntry/Request/RequestInput/FrmRequestInput.cs	(revision 60)
@@ -8,11 +8,15 @@
 using System.Threading.Tasks;
 using System.Windows.Forms;
 using System.Collections;
+using System.Diagnostics;
+using System.Drawing.Drawing2D;
 
 using ProcessManagement.Common;
 using ProcessManagement.DataModel;
 using ProcessManagement.DB.IOAccess;
 using ProcessManagement.Forms.SubForms;
+using ProcessManagement.Forms.ControlsAction;
+using ProcessManagement.Forms.DataEntry;
 
 namespace ProcessManagement.Forms.DataEntry
 {
@@ -23,6 +27,9 @@
         private static readonly log4net.ILog logger = log4net.LogManager.GetLogger(System.Reflection.MethodBase.GetCurrentMethod().DeclaringType);
         #endregion
 
+        #region 定数
+        #endregion
+
         #region 変数
         /// <summary>
         /// 工事番号
@@ -54,6 +61,15 @@
 
         private bool m_bChengeAns = false;
 
+        //        private List<RequestData> m_RequestData = new List<RequestData>();
+
+        private bool m_bDirty = false;
+        private bool m_bVisible = false;
+        private bool m_bEdit = true;
+
+        private int m_ApprovalCode = 0;         // 承認機能番号
+        private int m_OrderNo = 0;              // 受付番号
+
         #endregion
 
         #region プロパティ
@@ -83,6 +99,32 @@
             set { m_BillingSplitFlg = value; }
         }
 
+        /// <summary>
+        /// 編集フラグ
+        /// </summary>
+        public bool EditFlg
+        {
+            set { m_bEdit = value; }
+        }
+
+        /// <summary>
+        /// 承認機能番号
+        /// </summary>
+        public int ApprovalCode
+        {
+            get { return m_ApprovalCode; }
+            set { m_ApprovalCode = value; }
+        }
+
+        /// <summary>
+        /// 受付番号
+        /// </summary>
+        public int OrderNo
+        {
+            get { return m_OrderNo; }
+            set { m_OrderNo = value; }
+        }
+
         #endregion
 
         /// <summary>
@@ -93,273 +135,579 @@
             InitializeComponent();
         }
 
-        private void Form1_Load(object sender, EventArgs e)
+        /// <summary>
+        /// フォームのロード
+        /// </summary>
+        private void FrmRequestInput_Load(object sender, EventArgs e)
         {
-            dgv1.CellValueChanged -= dgv1_CellValueChanged;
+            int ret;
 
+            // 初期起動チェック
+            ret = CheckInit();
+            if (ret > 0)
+            {
+                ShowMessageBox("該当工事は結合工事の子工事として請求済のため、単独での請求はできません。", "請求入力", MessageBoxButtons.OK, MessageBoxIcon.Error);
+
+                this.Close();
+
+                return;
+            }
+            else if (ret == -1)
+            {
+                ShowMessageBox("起動に失敗しました。再起動してください", "請求入力", MessageBoxButtons.OK, MessageBoxIcon.Error);
+
+                this.Close();
+
+                return;
+            }
+
             // DataGridViewに項目名を設定
             SetGridDisplay();
 
-            dgv1.Visible = true;
+            // 請求データの取得
+            GetRequestDispData();
 
-            dgv1.CellValueChanged += dgv1_CellValueChanged;
-            dgv1.CellDoubleClick += dgv1_CellDoubleClicked;
+            // 請求データの設定
+            SetRequestDispData();
 
+            // 請求月の設定
+            SetRequestMonth();
+
+            for (int i = 1; i < m_nMaxOrderNo; i++)
+            {
+                int tcol = 8 + i;
+
+                dgv1.Columns[tcol].Visible = true;
+            }
+
             // [回数追加]ボタンの制御
             btnAdd.Enabled = GetbtnAddEnabled();
 
+            if( m_bEdit == false ){
+                btnEntry.Enabled = false;
+            }
+
             // *-----* 処理移動ボタン設定 *-----*
             CreateProcessContextMenu(m_SubForm);
             // *-----* 処理移動ボタン設定 *-----*
 
+            // 承認機能番号が0以外(=承認画面からの呼び出し)の場合
+            if (m_ApprovalCode != 0)
+            {
+                pnlNormal.Visible = false;
+
+                ApprovalMaster App = null;
+
+                // 承認経路上にログインユーザがある場合は、承認の各ボタンを表示
+                if ( m_dicApprovalMaster.TryGetValue(CommonMotions.LoginUserData.PersonCode, out App ) == true)
+                {
+                    pnlApproval.Visible = true;
+                }
+            }
+            m_bDirty = false;
+
         }
 
-        // 
-        private void dgv1_SelectionChanged(object sender, EventArgs e)
+        /// <summary>
+        /// 請求入力がアクティブになった
+        /// </summary>
+        /// <param name="sender"></param>
+        /// <param name="e"></param>
+        private void FrmRequestInput_Activated(object sender, EventArgs e)
         {
-            
+            // 再描画
+            //this.Refresh();
         }
 
-        private void dgv1_CurrentCellChanged(object sender, EventArgs e)
+        /// <summary>
+        /// 「回数追加」ボタン押下
+        /// </summary>
+        /// <param name="sender"></param>
+        /// <param name="e"></param>
+        private void btnAdd_Click(object sender, EventArgs e)
         {
-            DataGridView dgv = sender as DataGridView;
-            DataGridViewCell cell = dgv.CurrentCell;
+            try
+            {
+                // データが変更されている場合
+                if (m_bDirty == true)
+                {
+                    if (ShowMessageBox("データが保存されます。よろしいですか？", "保存確認", MessageBoxButtons.YesNo, MessageBoxIcon.Information) == DialogResult.No)
+                    {
+                        return;
+                    }
+                    // データ保存
+                    AcceptData();
+                }
 
-            int cnt = dgv.ColumnCount;
-        }
 
-        // DataGridViewのセルクリック時
-        private void dgv1_CellContentClick(object sender, DataGridViewCellEventArgs e)
-        {
+                // 請求回追加
+                AddRequest();
 
+                btnAdd.Enabled = false;
+
+            }
+            catch (Exception ex)
+            {
+                logger.ErrorFormat("システムエラー：{0}：{1}", CommonMotions.GetMethodName(), ex.Message);
+            }
+
         }
 
         /// <summary>
-        /// セルの値が変更された際のコールバック
+        /// [請求書申請]ボタン押下
         /// </summary>
         /// <param name="sender"></param>
         /// <param name="e"></param>
-        private void dgv1_CellValueChanged(object sender, DataGridViewCellEventArgs e)
+        private void btnApproval_Click(object sender, EventArgs e)
         {
-            dgv1.CellValueChanged -= dgv1_CellValueChanged;
+            int ret;
 
-            try
+            int nOldState = m_lstOrderState[m_nMaxOrderNo - 1];
+
+            List<int> lstMainConstructionCode = new List<int>();
+
+            // データが変更されている場合
+            if (m_bDirty == true)
             {
-                if ((e.RowIndex >= 0) && (e.ColumnIndex >= 0))
+                if (ShowMessageBox("データが保存されます。よろしいですか？", "保存確認", MessageBoxButtons.YesNo, MessageBoxIcon.Information) == DialogResult.No)
                 {
-                    // 請求明細列以外は無視
-                    int minIndex = GetColumnIndexNum(ColumnIndex.RequestInfo, 1);
-                    int maxIndex = GetColumnIndexNum(ColumnIndex.RequestInfo, m_RequestColumnCount);
-                    if ((e.ColumnIndex >= minIndex) && (e.ColumnIndex <= maxIndex))
-                    {
-                        var targetCell = dgv1.Rows[e.RowIndex].Cells[e.ColumnIndex] as DataGridViewCell;
-                        RowSectionIndex sectionIndex = (RowSectionIndex)dgv1.Rows[e.RowIndex].Cells[GetColumnIndexNum(ColumnIndex.SectionIndex)].Value;
+                    return;
+                }
+                // データ保存
+                AcceptData();
+            }
 
-                        // 本工事セクションか増減工事セクション以外は無視
-                        if ((sectionIndex == RowSectionIndex.OriginalConstruction) || (sectionIndex == RowSectionIndex.ChildConstruction))
-                        {
-                            if (targetCell.Value.GetType() == typeof(string))
-                            {
-                                double dest = 0;
-                                double.TryParse((string)targetCell.Value, out dest);
-                                targetCell.Value = dest;
-                                targetCell.Style.ForeColor = (dest < 0) ? Color.Red : Color.Black;
-                            }
+            // エラー表示を一旦クリア
+            ClearErrorIndicate();
 
-                            // 自動計算セル再計算
-                            SetAutoCalcCell(dgv1.Rows[e.RowIndex]);
+            // 申請チェック
+            ret = CheckApproval(ref lstMainConstructionCode);
 
-                            // 該当列の合計セクションを計算
-                            SetTotalInfoColumn(e.ColumnIndex);
+            // 状態が入力中の場合
+            if (nOldState == (int)ApprovalState.Entry)
+            {
 
-                            // 合計セクションの合計列および残り列の計算
-                            SetTotalSectionInfo();
+                if (ret == (int)CheckResult.ErrorStatus)
+                {
+                    // エラー表示
+                    SetErrorIndicate(lstMainConstructionCode);
 
-                        }
+                    ShowMessageBox("施工準備ではないため、請求書承認の申請はできません。", "申請確認", MessageBoxButtons.OK, MessageBoxIcon.Error);
 
+                    return;
+                }
+
+                if (ret == (int)CheckResult.NoError)
+                {
+                    if (ShowMessageBox("請求書承認を申請してよろしいですか？", "申請確認", MessageBoxButtons.YesNo, MessageBoxIcon.Information) == DialogResult.No)
+                    {
+                        return;
                     }
+                }
+                else if (ret == (int)CheckResult.WarningUnmatch)
+                {
+                    if (ShowMessageBox("工事金額が全て請求されていませんが、\n請求書承認を申請してよろしいですか？", "申請確認", MessageBoxButtons.YesNo, MessageBoxIcon.Warning) == DialogResult.No)
+                    {
+                        return;
+                    }
+                }
+                else if (ret == (int)CheckResult.WarningOver)
+                {
+                    if (ShowMessageBox("請求金額が工事金額を超えていますが、\n請求書承認を申請してよろしいですか？", "申請確認", MessageBoxButtons.YesNo, MessageBoxIcon.Warning) == DialogResult.No)
+                    {
+                        return;
+                    }
+                }
+                else
+                {
+                    return;
+                }
+            }
 
+            // 承認画面を表示
+            FrmApprovalScreen frmApprovalScreen = new FrmApprovalScreen();
+            frmApprovalScreen.ConstructionCode = m_ConstructionCode;
+            frmApprovalScreen.ApprovalCode = (int)ClsExcute.ApprovalListNo.OrderBillingApproval;
+            frmApprovalScreen.OrderNo = m_nMaxOrderNo;
+            frmApprovalScreen.ShowDialog(this);
+
+            m_dicProcessApproval.Clear();
+
+            // 承認データの再取得
+            GetProcessApproval(m_ConstructionCode, ref m_dicProcessApproval);
+
+            int nNewState = GetApprovalState(m_ConstructionCode, m_nMaxOrderNo);
+
+            int tcol = m_nMaxOrderNo + 7;
+
+            if (nNewState != nOldState)
+            {
+                m_lstOrderState[m_nMaxOrderNo - 1] = nNewState;
+
+                SetRequestMonthAndApprovalState(m_nMaxOrderNo, 0, nNewState);
+
+                if (nNewState != (int)ApprovalState.End)
+                {
+                    txtOrderer.ReadOnly = false;
+                    cbReqMonth.Enabled = false;
                 }
+                else
+                {
+                    txtOrderer.ReadOnly = true;
+                    cbReqMonth.Enabled = true;
+                }
+            }
 
+        }
+
+        /// <summary>
+        /// [登録]ボタン押下
+        /// </summary>
+        /// <param name="sender"></param>
+        /// <param name="e"></param>
+        private void btnEntry_Click(object sender, EventArgs e)
+        {
+            // エラー表示クリア
+            ClearErrorIndicate();
+
+            // 登録確認メッセージ表示
+            if (ShowMessageBox("表示中のデータを登録します。", "登録確認", MessageBoxButtons.YesNo, MessageBoxIcon.Question) != DialogResult.Yes)
+            {
+                return;
             }
-            catch (Exception ex)
+
+            // セルの内容をオブジェクトに反映
+            SetDispData();
+
+            // データ登録
+            SaveDispData();
+
+            // Formを閉じる
+            Close();
+        }
+
+        /// <summary>
+        /// [終了]ボタン押下
+        /// </summary>
+        /// <param name="sender"></param>
+        /// <param name="e"></param>
+        private void btnEnd_Click(object sender, EventArgs e)
+        {
+            // データが変更されている場合
+            if ((m_bDirty == true)&&(m_bEdit == true ))
             {
-                logger.ErrorFormat("システムエラー：{0}：{1}", CommonMotions.GetMethodName(), ex.Message);
+                // 破棄確認メッセージ表示
+                if (ShowMessageBox("データに変更があります、登録せずに終了してよろしいですか？。", "終了確認", MessageBoxButtons.YesNo, MessageBoxIcon.Warning) == DialogResult.No)
+                {
+                    return ;
+                }
             }
 
-            dgv1.CellValueChanged += dgv1_CellValueChanged;
+            m_EndButton = DialogResult.Cancel;
 
+            // 前プロセスに戻る
+            ClsExcute.BackProcess();
+
+            Close();
+
         }
 
         /// <summary>
-        /// 「回数追加」ボタン押下
+        /// セル編集開始
         /// </summary>
         /// <param name="sender"></param>
         /// <param name="e"></param>
-        private void btnAdd_Click(object sender, EventArgs e)
+        private void dgv1_CellBeginEdit(object sender, DataGridViewCellCancelEventArgs e)
         {
-            dgv1.CellValueChanged -= dgv1_CellValueChanged;
+            int tcol = e.ColumnIndex;
+            int trow = e.RowIndex;
 
-            try
+            this.dgv1.CellBeginEdit -= dgv1_CellBeginEdit;
+
+            // 対象セルが数値（金額）系の場合
+            if (isEditNumCell(tcol, trow) == true)
             {
-                AddRequest();
+                string val;
 
+                // セルに値が格納されている場合
+                if (dgv1[tcol, trow].Value != null)
+                {
+                    // カンマ区切りを解除
+                    val = dgv1[tcol, trow].Value.ToString().Replace(",", string.Empty);
+                }
+                else
+                {
+                    // 0を入力
+                    val = "0";
+                }
+                dgv1[tcol, trow].Value = val;
+
+                // 文字色は一律黒
+                dgv1[tcol, trow].Style.ForeColor = Color.Black;
             }
-            catch (Exception ex)
-            {
-                logger.ErrorFormat("システムエラー：{0}：{1}", CommonMotions.GetMethodName(), ex.Message);
-            }
 
-            dgv1.CellValueChanged += dgv1_CellValueChanged;
+            this.dgv1.CellBeginEdit += dgv1_CellBeginEdit;
         }
 
         /// <summary>
-        /// 「他の画面へ」ボタン押下
+        /// セルフォーマッティング（セル書式指定）
         /// </summary>
         /// <param name="sender"></param>
         /// <param name="e"></param>
-        //private void btnOtherProc_Click(object sender, EventArgs e)
-        //{
-        //    // 暫定的に直接印刷画面を表示する
-        //    FrmRequestPrint frmRequestPrint = new FrmRequestPrint();
+        private void dgv1_CellFormatting(object sender, DataGridViewCellFormattingEventArgs e)
+        {
+            int tcol = e.ColumnIndex;
+            int trow = e.RowIndex;
 
-        //    // パラメータを渡す
-        //    frmRequestPrint.RequestNo = m_RequestData.RequestNo;
-        //    frmRequestPrint.ConstructionCode = m_ConstructionCode;
+            this.dgv1.CellFormatting -= dgv1_CellFormatting;
 
-        //    frmRequestPrint.ShowDialog();
-           
+            if (dgv1[tcol, trow].Value == null)
+            {
+                this.dgv1.CellFormatting += dgv1_CellFormatting;
+                return;
+            }
 
-        //}
+            // セルの編集タイプを取得
+            int nType = GetEditType(tcol, trow);
 
+            // 金額系セルの場合
+            if (nType == (int)EditType.Amount)
+            {
+                // 金額系セルの終了制御(カンマ区切り、文字色変更等)
+                CellEditEnd(tcol, trow);
+
+                // 編集行の合計列を再計算
+                calcTotal(trow);
+
+                // 編集行の残り列を再計算
+                calcBalance(trow);
+
+                // 受付回目列のヘッダ部合計を再計算
+                setOrderTotal(m_nMaxOrderNo);
+
+                // 合計列のヘッダ部合計を再計算
+                setOrderTotal(0);
+
+                // ヘッダ部請求合計行の残り列を再計算
+                calcBalance(2);
+
+                // ヘッダ部請求金額行の残り列を再計算
+                calcBalance(3);
+
+                // ヘッダ部消費税行の残り列を再計算
+                calcBalance(4);
+
+            }
+
+            this.dgv1.CellFormatting += dgv1_CellFormatting;
+        }
+
         /// <summary>
-        /// セルダブルクリック時の処理
+        /// データグリッドビュのセルが変更された
         /// </summary>
         /// <param name="sender"></param>
         /// <param name="e"></param>
-        private void dgv1_CellDoubleClicked(object sender, DataGridViewCellEventArgs e)
+        private void dgv1_CellValueChanged(object sender, DataGridViewCellEventArgs e)
         {
-            try
-            {
-                // 確認のためのインデックス取得
-                int statRowIndex = GetRowIndexNum(RowSectionIndex.Header, RowKind.ApprobalStatus);
-                int minStatColIndex = GetColumnIndexNum(ColumnIndex.RequestInfo, 1);
-                int maxStatColIndex = GetColumnIndexNum(ColumnIndex.RequestInfo, m_LstRequestTotalData.Count);
+            m_bDirty = true;
+        }
 
-                // 対象セルがステータス行であることを確認
-                if (e.RowIndex == statRowIndex)
-                {
-                    // 対象セルが請求明細列であることを確認
-                    if ((e.ColumnIndex >= minStatColIndex) && (e.ColumnIndex <= maxStatColIndex))
-                    {
-                        int orderNo = m_LstRequestTotalData[e.ColumnIndex - minStatColIndex].OrderNo;
+        /// <summary>
+        /// セル検証
+        /// </summary>
+        /// <param name="sender"></param>
+        /// <param name="e"></param>
+        private void dgv1_CellValidating(object sender, DataGridViewCellValidatingEventArgs e)
+        {
+            int tcol = e.ColumnIndex;
+            int trow = e.RowIndex;
 
-                        // 請求書申請チェックを実施
-                        if (checkApproval(orderNo))
-                        {
-                            // チェック結果がOKなら以下の処理を実施
+            // 新規行または変更されていない場合はスルー
+            if (e.RowIndex == dgv1.NewRowIndex || !dgv1.IsCurrentCellDirty)
+            {
+                return;
+            }
 
-                            // 承認画面を表示
-                            FrmApprovalScreen frmApprovalScreen = new FrmApprovalScreen();
-                            frmApprovalScreen.ConstructionCode = m_ConstructionCode;
-                            frmApprovalScreen.ApprovalCode = 5;
-                            frmApprovalScreen.OrderNo = orderNo;
-                            frmApprovalScreen.ShowDialog();
+            // セルの編集タイプを取得
+            int nType = GetEditType(tcol, trow);
 
-                        }
+            // セルの編集タイプが金額系の場合
+            if (nType == (int)EditType.Amount)
+            {
+                string str = e.FormattedValue.ToString().Replace(",", string.Empty); ;
 
-                        // 承認データを再取得
-                        m_DicProcessApproval.Clear();
-                        GetProcessApproval(m_ConstructionCode, ref m_DicProcessApproval);
+                str.Trim();
 
-                        // 対象の請求明細列を再表示
-                        SetRequestInfoColumn(orderNo - 1);
+                if (str == "")
+                {
+                    str = "0";
+                }
 
-                    }
+                try
+                {
+                    int n = int.Parse(str);
                 }
+                catch (Exception)
+                {
+                    ShowMessageBox("金額を入力してください", "入力エラー", MessageBoxButtons.OK, MessageBoxIcon.Error);
+                    e.Cancel = true;
+                }
 
+
             }
-            catch (Exception ex)
+            // セルの編集タイプが名称系の場合
+            else if (nType == (int)EditType.Name)
             {
-                logger.ErrorFormat("システムエラー：{0}：{1}", CommonMotions.GetMethodName(), ex.Message);
+                string str = e.FormattedValue.ToString();
+
+                str.Trim();
+                
+                string msg = "";
+
+                if (str == "")
+                {
+                    msg = "件名を入力してください";
+                }
+                else if (str.Length > 120)
+                {
+                    msg = "件名が長すぎます(120文字まで入力可能)2";
+                }
+
+                if (msg != "")
+                {
+                    ShowMessageBox(msg, "入力エラー", MessageBoxButtons.OK, MessageBoxIcon.Error);
+                    e.Cancel = true;
+                }
             }
+        }
 
+        /// <summary>
+        /// 請求先の変更
+        /// </summary>
+        /// <param name="sender"></param>
+        /// <param name="e"></param>
+        private void txtOrderer_TextChanged(object sender, EventArgs e)
+        {
+            m_bDirty = true;
         }
 
         /// <summary>
-        /// 登録ボタン押下時処理
+        /// 請求先の検証
         /// </summary>
         /// <param name="sender"></param>
         /// <param name="e"></param>
-        private void button3_Click(object sender, EventArgs e)
+        private void txtOrderer_Validating(object sender, CancelEventArgs e)
         {
-            try
+            if (txtOrderer.Text.Length > 120)
             {
-                // データ登録処理
-                AcceptData();
+                string msg = "件名が長すぎます(120文字まで入力可能)";
+                ShowMessageBox(msg, "入力エラー", MessageBoxButtons.OK, MessageBoxIcon.Error);
+                e.Cancel = true;
+                txtOrderer.Select(0, txtOrderer.Text.Length);
+            }
+        }
 
+        /// <summary>
+        /// デバッグ用ダミー
+        /// </summary>
+        /// <param name="sender"></param>
+        /// <param name="e"></param>
+        private void button1_Click_1(object sender, EventArgs e)
+        {
+            if (m_bVisible)
+            {
+                m_bVisible = false;
             }
-            catch (Exception ex)
+            else
             {
-                logger.ErrorFormat("システムエラー：{0}：{1}", CommonMotions.GetMethodName(), ex.Message);
+                m_bVisible = true;
             }
+            dgv1.Columns[0].Visible = m_bVisible;
+            dgv1.Columns[1].Visible = m_bVisible;
+            dgv1.Columns[2].Visible = m_bVisible;
+
         }
 
+        private DialogResult ShowMessageBox(string text, string caption, MessageBoxButtons buttons, MessageBoxIcon icon)
+        {
+            dgv1.CellFormatting -= dgv1_CellFormatting;
+
+            DialogResult ret = MessageBox.Show(this, text, caption, buttons, icon);
+
+            dgv1.CellFormatting += dgv1_CellFormatting;
+
+            return ret;
+        }
+
         /// <summary>
-        /// 終了ボタン押下時処理
+        /// [承認]ボタン押下
         /// </summary>
         /// <param name="sender"></param>
         /// <param name="e"></param>
-        private void button2_Click(object sender, EventArgs e)
+        private void btnAgree_Click(object sender, EventArgs e)
         {
+            if (ShowMessageBox("案件を承認します、よろしいですか？。", "承認確認", MessageBoxButtons.YesNo, MessageBoxIcon.Information) == DialogResult.No)
+            {
+                return;
+            }
 
+            // 承認で登録
+            SetProcessApproval((int)CommonDefine.ApprovalStatus.Approval);
+
             m_EndButton = DialogResult.Cancel;
 
             // 前プロセスに戻る
             ClsExcute.BackProcess();
-            
+
             Close();
+
         }
 
         /// <summary>
-        /// [回数追加]ボタン活性状態の取得
+        /// [保留]ボタン押下
         /// </summary>
-        private bool GetbtnAddEnabled()
+        /// <param name="sender"></param>
+        /// <param name="e"></param>
+        private void btnPend_Click(object sender, EventArgs e)
         {
-            // 入金が完了している場合
-            if (m_ConstructionLedger.ComplateFlg == 1)
+            if (ShowMessageBox("案件を保留とします、よろしいですか？。", "保留確認", MessageBoxButtons.YesNo, MessageBoxIcon.Information) == DialogResult.No)
             {
-                return false;
+                return;
             }
 
-            // 分割払いの場合
-            if (m_BillingSplitFlg == 1)
-            {
-                return true;
-            }
+            // 保留で登録
+            SetProcessApproval((int)CommonDefine.ApprovalStatus.Pending);
 
-            double totalDiff = 0;
+            m_EndButton = DialogResult.Cancel;
 
-            // 繰越金額がある場合
-            // 合計値を計算
-            foreach (var detail in m_LstRequestTotalData)
-            {
-                if (m_DicDepositDataDetail.ContainsKey(detail.OrderNo))
-                {
-                    var depDetail = m_DicDepositDataDetail[detail.OrderNo];
-                    totalDiff += depDetail.CarryAmount;
-                }
-            }
+            // 前プロセスに戻る
+            ClsExcute.BackProcess();
 
-            // 繰越金が存在する場合
-            if (totalDiff > 0)
+            Close();
+        }
+
+        /// <summary>
+        /// [不承認]ボタン押下
+        /// </summary>
+        /// <param name="sender"></param>
+        /// <param name="e"></param>
+        private void btnDeny_Click(object sender, EventArgs e)
+        {
+            if (ShowMessageBox("案件を不承認します、よろしいですか？。", "不承認確認", MessageBoxButtons.YesNo, MessageBoxIcon.Information) == DialogResult.No)
             {
-                return true;
+                return;
             }
 
-            return false;
+            // 不承認で登録
+            SetProcessApproval((int)CommonDefine.ApprovalStatus.NotApproval);
+
+            m_EndButton = DialogResult.Cancel;
+
+            // 前プロセスに戻る
+            ClsExcute.BackProcess();
+
+            Close();
         }
 
-
     }
 }
Index: branches/src/ProcessManagement/ProcessManagement/Forms/DataEntry/Request/RequestInput/FrmRequestInput.resx
===================================================================
--- branches/src/ProcessManagement/ProcessManagement/Forms/DataEntry/Request/RequestInput/FrmRequestInput.resx	(revision 59)
+++ branches/src/ProcessManagement/ProcessManagement/Forms/DataEntry/Request/RequestInput/FrmRequestInput.resx	(revision 60)
@@ -117,76 +117,79 @@
   <resheader name="writer">
     <value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
   </resheader>
-  <metadata name="GridSectionIndex.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+  <metadata name="col001.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
     <value>True</value>
   </metadata>
-  <metadata name="GridRowKind.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+  <metadata name="col002.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
     <value>True</value>
   </metadata>
-  <metadata name="GridConstructionCode.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+  <metadata name="col003.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
     <value>True</value>
   </metadata>
-  <metadata name="col0.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+  <metadata name="col004.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
     <value>True</value>
   </metadata>
-  <metadata name="col1.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+  <metadata name="col005.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
     <value>True</value>
   </metadata>
-  <metadata name="col3.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+  <metadata name="col006.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
     <value>True</value>
   </metadata>
-  <metadata name="col4.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+  <metadata name="col007.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
     <value>True</value>
   </metadata>
-  <metadata name="col5.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+  <metadata name="col008.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
     <value>True</value>
   </metadata>
-  <metadata name="col6.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+  <metadata name="col009.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
     <value>True</value>
   </metadata>
-  <metadata name="col7.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+  <metadata name="col010.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
     <value>True</value>
   </metadata>
-  <metadata name="col8.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+  <metadata name="col011.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
     <value>True</value>
   </metadata>
-  <metadata name="col11.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+  <metadata name="col12.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
     <value>True</value>
   </metadata>
-  <metadata name="GridSectionIndex.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+  <metadata name="col13.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
     <value>True</value>
   </metadata>
-  <metadata name="GridRowKind.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+  <metadata name="col14.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
     <value>True</value>
   </metadata>
-  <metadata name="GridConstructionCode.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+  <metadata name="col15.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
     <value>True</value>
   </metadata>
-  <metadata name="col0.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+  <metadata name="col16.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
     <value>True</value>
   </metadata>
-  <metadata name="col1.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+  <metadata name="col17.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
     <value>True</value>
   </metadata>
-  <metadata name="col3.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+  <metadata name="col18.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
     <value>True</value>
   </metadata>
-  <metadata name="col4.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+  <metadata name="col19.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
     <value>True</value>
   </metadata>
-  <metadata name="col5.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+  <metadata name="col20.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
     <value>True</value>
   </metadata>
-  <metadata name="col6.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+  <metadata name="col21.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
     <value>True</value>
   </metadata>
-  <metadata name="col7.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+  <metadata name="col22.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
     <value>True</value>
   </metadata>
-  <metadata name="col8.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+  <metadata name="col23.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
     <value>True</value>
   </metadata>
-  <metadata name="col11.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+  <metadata name="col098.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
     <value>True</value>
   </metadata>
+  <metadata name="col99.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
 </root>
\ No newline at end of file
Index: branches/src/ProcessManagement/ProcessManagement/Forms/DataEntry/Request/RequestInput/FrmRequestInputAuxiliary.cs
===================================================================
--- branches/src/ProcessManagement/ProcessManagement/Forms/DataEntry/Request/RequestInput/FrmRequestInputAuxiliary.cs	(revision 59)
+++ branches/src/ProcessManagement/ProcessManagement/Forms/DataEntry/Request/RequestInput/FrmRequestInputAuxiliary.cs	(revision 60)
@@ -6,31 +6,67 @@
 using System.Windows.Forms;
 using System.Collections;
 using System.Drawing;
+using System.Diagnostics;
 
 using ProcessManagement.Common;
 using ProcessManagement.DataModel;
 using ProcessManagement.DB.IOAccess;
+using ProcessManagement.Forms.SubForms;
+using ProcessManagement.Forms.ControlsAction;
+using ProcessManagement.Forms.DataEntry;
 
 namespace ProcessManagement.Forms.DataEntry
 {
     public partial class FrmRequestInput : Form
     {
-        #region 変数
+        #region 定数
         /// <summary>
-        /// 増減工事表示行数
+        /// DataGridView区分
         /// </summary>
-        private int m_ChildConstructionRowCount = 4;
+        private enum dgvKind
+        {
+            Header = 0,                     // ヘッダ
+            BodyMainConstruction = 1,       // ボディ（本工事）
+            BodySubConstruction = 2,        // ボディ（増減工事）
+            Body = 3,                       // ボディ
+            Footer = 4,                     // フッタ
+        }
 
-        /// <summary>
-        /// 請求明細表示列数
-        /// </summary>
-        private int m_RequestColumnCount = 3;
+        private enum ApprovalState
+        {
+            Entry = 0,              // 入力中
+            Apply = 1,              // 申請中
+            Approval = 2,           // 承認中
+            Pending = 3,            // 保留
+            Dismissal = 4,          // 却下
+            End = 5,                // 承認済
+        }
 
-        /// <summary>
-        /// DataGridViewRowオブジェクトハッシュテーブル
-        /// </summary>
-        private Hashtable m_HtRowObject = new Hashtable();
+        private enum DepositState
+        {
+            None = 0,               // なし
+            Done = 1,               // 確認済
+        }
 
+        private enum EditType
+        {
+            NotEdit = 0,            // 編集対象外
+            Name = 1,               // 名前（文字列）
+            Amount = 2,             // 金額（カンマ区切り）
+        }
+
+        private enum CheckResult
+        {
+            NoError = 0,            // エラーなし
+            WarningUnmatch = 1,     // 金額不一致
+            WarningOver = 2,        // 請求超過（残りがマイナス）
+            ErrorStatus = 3,        // 施工完了ではない
+            UnknownError = 99,
+        }
+
+    #endregion
+
+        #region 変数
         /// <summary>
         /// 消費税率
         /// </summary>
@@ -37,954 +73,1931 @@
         private double m_TaxRate = (CommonMotions.SystemMasterData.ConsumptionTax / 100);
 
         /// <summary>
-        /// 工事基本情報
+        /// 以下、追加分
         /// </summary>
-        private ConstructionBaseInfo m_ConstructionData = new ConstructionBaseInfo();
 
         /// <summary>
-        /// 工事詳細台帳データ
+        /// 請求工事の工事基本情報明細リスト
         /// </summary>
-        private ConstructionLedger m_ConstructionLedger = new ConstructionLedger();
+//        private List<ConstructionBaseInfoDetail> m_BaseConstructionBaseInfoDetail = new List<ConstructionBaseInfoDetail>();
 
+        //private Dictionary<int, ConstructionBaseInfoDetail> m_ConstructionBaseInfoDetail = new Dictionary<int, ConstructionBaseInfoDetail>();
+
         /// <summary>
-        /// 工事基本明細情報
+        /// 請求ヘッダリスト
         /// </summary>
-        private Dictionary<int,string> m_DicConstructionDetail = new Dictionary<int, string>();
+        private List<RequestHead> m_lstRequestHead = new List<RequestHead>();
 
         /// <summary>
-        /// 請求情報
+        /// 請求データリスト
         /// </summary>
-        private RequestData m_RequestData = new RequestData();
+        private List<Dictionary<int, RequestData>> m_lstRequestData = new List<Dictionary<int, RequestData>>();
 
         /// <summary>
-        /// 請求合計情報
+        /// 請求データ明細リスト
         /// </summary>
-        private List<RequestTotalData> m_LstRequestTotalData = new List<RequestTotalData>();
+        private List<Dictionary<int, List<RequestDataDetail>>> m_lstRequestDataDetail = new List<Dictionary<int, List<RequestDataDetail>>>();
 
         /// <summary>
-        /// 請求明細情報
+        /// 入金データ明細用リスト
         /// </summary>
-        private Dictionary<int,Dictionary<int,RequestDataDetail>> m_DicRequestDataDetail = new Dictionary<int, Dictionary<int, RequestDataDetail>>();
-
+        private List<DepositDataDetail> m_lstDepDataDetail = new List<DepositDataDetail>();
+        private List<DateTime> m_lstDepositDate = new List<DateTime>();
+        private List<int> m_lstDepositState = new List<int>();
+ 
         /// <summary>
-        /// 入金明細情報
+        /// 請求工事の工事基本情報
         /// </summary>
-        private Dictionary<int,DepositDataDetail> m_DicDepositDataDetail = new Dictionary<int, DepositDataDetail>();
+        private ConstructionBaseInfo m_BaseConstructionBaseInfo = new ConstructionBaseInfo();
 
         /// <summary>
-        /// 工事増減情報リスト
+        /// 請求工事の工事基本情報明細文字列リスト
         /// </summary>
-        private List<int> m_LstConstructionLink = new List<int>();
+        private Dictionary<int, string> m_dicBaseConstructionString = new Dictionary<int, string>();
 
         /// <summary>
-        /// 増減工事・基本情報
+        /// 工事基本情報リスト
         /// </summary>
-        private List<ConstructionBaseInfo> m_LstChldContructionData = new List<ConstructionBaseInfo>();
+        private Dictionary<int, ConstructionBaseInfo> m_dicConstructionBaseInfo = new Dictionary<int, ConstructionBaseInfo>();
 
         /// <summary>
-        /// 増減工事・明細情報
+        /// 工事基本情報明細文字列リスト
         /// </summary>
-        private Dictionary<int,Dictionary<int,string>> m_DicChldConstructionDetail = new Dictionary<int,Dictionary<int, string>>();
+        private Dictionary<int, string> m_dicConstructionName = new Dictionary<int, string>();
 
         /// <summary>
-        /// 増減工事・詳細台帳データ
+        /// 承認経路マスタ
         /// </summary>
-        private Dictionary<int,ConstructionLedger> m_DicChldConstructionLedger = new Dictionary<int, ConstructionLedger>();
+        private Dictionary<int, ApprovalMaster> m_dicApprovalMaster = new Dictionary<int, ApprovalMaster>();
 
         /// <summary>
         /// 承認データ
         /// </summary>
-        private Dictionary<int,List<ProcessApproval>> m_DicProcessApproval = new Dictionary<int, List<ProcessApproval>>();
+        private Dictionary<int, List<ProcessApproval>> m_dicProcessApproval = new Dictionary<int, List<ProcessApproval>>();
 
         /// <summary>
-        /// 承認経路データ
+        /// 工事詳細台帳
         /// </summary>
-        private Dictionary<int,ApprovalMaster> m_DicApprovalMaster = new Dictionary<int, ApprovalMaster>();
+        private ConstructionLedger m_ConstructionLedger = new ConstructionLedger();
 
         /// <summary>
-        /// 請求合計レコード更新追加確認ディクショナリ
+        /// 承認状態リスト
         /// </summary>
-        private Dictionary<RequestTotalData, bool> m_DicReqTotalRec = new Dictionary<RequestTotalData, bool>();
+        private List<int> m_lstOrderState = new List<int>();
 
+
+        private int m_nLeaderConstructionCode = 0;              // 詳細台帳用工事番号
+        private int m_nRequestNo = 0;                           // 請求No
+        private int m_nMaxOrderNo = 0;                          // 最大受付番号
+        private int m_nMaxRowNo = 0;                            // 最大行数
+
+        private int m_nOldRequestMonth = 0;                     // 起動時請求年月
+        private int m_nOldRequestAmount = 0;                    // 起動時請求金額
+
+
+        public RequestData m_RequestData = new RequestData();
+
+        #endregion
+
+        #region データグリッドビュ関連メソッド
+
+        #region DataGridViewの初期表示設定
         /// <summary>
-        /// 請求明細レコード更新追加確認ディクショナリ
+        /// DataGridViewの初期表示設定
         /// </summary>
-        private Dictionary<RequestDataDetail, bool> m_DicReqDetailRec = new Dictionary<RequestDataDetail, bool>();
+        private void SetGridDisplay()
+        {
+            try
+            {
+                // DataGrid全体のプロパティ設定
+                dgv1.EnableHeadersVisualStyles = false;
+                dgv1.AutoGenerateColumns = false;
+                dgv1.ColumnHeadersHeight = dgv1.ColumnHeadersHeight + 5;
+                dgv1.ColumnHeadersDefaultCellStyle.Alignment = DataGridViewContentAlignment.MiddleCenter;
+                dgv1.ColumnHeadersDefaultCellStyle.BackColor = Color.Aquamarine;
+                dgv1.AllowUserToAddRows = false;
+                dgv1.RowTemplate.Height = 22;
+                dgv1.Font = new System.Drawing.Font("ＭＳ 明朝", 11.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(128)));
 
+
+                for (int i = 9; i < dgv1.ColumnCount - 2; i++)
+                {
+                    dgv1.Columns[i].Visible = false;
+                }
+
+                // 列タイトル設定
+                string[] title = new string[] { "", "", "", "", " 工事名", " 工事金額", "", " 合計", " 1回目", " 2回目", " 3回目", " 4回目", " 5回目", " 6回目", " 7回目", " 8回目", " 9回目", " 10回目", " 11回目", " 12回目", " 13回目", " 14回目", " 15回目", " 残り", " コメント" };
+
+                for (int i = 0; i < dgv1.ColumnCount; i++)
+                {
+                    dgv1.Columns[i].HeaderText = title[i];
+                }
+
+                // ヘッダ部構築
+                int cnt = Createheader(dgv1);
+
+                // ボディ部構築
+                cnt = CreateBody(dgv1, cnt);
+
+                // フッタ部構築
+                cnt = CreateFooter(dgv1, cnt);
+
+            }
+            catch (Exception ex)
+            {
+                logger.ErrorFormat("システムエラー：{0}：{1}", CommonMotions.GetMethodName(), ex.Message);
+            }
+        }
+        #endregion
+
+        #region  ヘッダ部の構築
         /// <summary>
-        /// 案件進捗日付データ
+        /// ヘッダ部の構築
         /// </summary>
-        private Dictionary<int, ConstructionProgressDate> m_DicConstProgressDate = new Dictionary<int, ConstructionProgressDate>();
+        private int Createheader(DataGridView dgv)
+        {
+            string[] title = new string[]{ "請求月", "承認状態", "請求合計", "請求金額", "消費税", "未入金分" };
+
+            dgv.Rows.Add(6);
+
+            for (int i = 0; i < 6; i++)
+            {
+                dgv.Rows[i].DefaultCellStyle.BackColor = Color.Yellow;
+                dgv.Rows[i].Frozen = true;
+
+                dgv[0, i].Value = i.ToString();
+                dgv[1, i].Value = ((int)dgvKind.Header).ToString();
+                dgv[6, i].Value = title[i];
+            }
+
+            dgv[3, 0].Value = "請求工事";
+
+            dgv.ClearSelection();
+
+            return 6;
+        }
         #endregion
 
+        #region ボディ部の構築
         /// <summary>
-        /// 請求データ未登録フラグ
+        /// ボディ部の構築
         /// </summary>
-        private bool isEmptyConstructionBaseInfo = false;
+        private int CreateBody(DataGridView dgv, int cnt)
+        {
+            dgv.Rows.Add(24);
 
+            for (int i = 0; i < 12; i++)
+            {
+                for (int j = 0; j < 2; j++)
+                {
+                    if (i % 2 != 0)
+                    {
+                        dgv.Rows[cnt].DefaultCellStyle.BackColor = Color.LightBlue;
+                    }
+                    dgv[0, cnt].Value = cnt.ToString();
+
+                    dgv[6, cnt].Style.ForeColor = Color.DarkGray;
+                    if (j == 0)
+                    {
+                        dgv[6, cnt].Value = "請求金額";
+
+                    }
+                    else
+                    {
+                        dgv[6, cnt].Value = "消費税";
+                    }
+
+                    if (cnt > 13)
+                    {
+                        dgv.Rows[cnt].Visible = false;
+                    }
+
+                    cnt++;
+                }
+            }
+
+            return cnt;
+        }
+        #endregion
+
+        #region フッタ部の構築
         /// <summary>
-        /// 請求書申請チェックと確認メッセージボックスの表示
+        /// フッタ部の構築
         /// </summary>
-        /// <param name="orderNo"></param>
-        /// <returns></returns>
-        private bool checkApproval(int orderNo)
+        private int CreateFooter(DataGridView dgv, int cnt)
         {
-            bool chkResult = true;
+            dgv.Rows.Add(4);
 
-            // 合計セクションの請求金額行を取得
-            var totalRow = GetDataGridViewRowObject(RowSectionIndex.Total, RowKind.BillPrice);
+            string[] title = { "入金日", "入金金額", "差額", "入金確認" };
 
-            // 工事金額と請求金額を取得
-            double constPrice = (double)totalRow.Cells[GetColumnIndexNum(ColumnIndex.ConstructionPrice)].Value;
-            double billPrice = (double)totalRow.Cells[GetColumnIndexNum(ColumnIndex.Total)].Value;
+            for (int i = 0; i < 4; i++)
+            {
+                dgv.Rows[cnt].DefaultCellStyle.BackColor = Color.Yellow;
 
-            // 一括請求の場合
-            if ((m_ConstructionData.BillingSplitFlg == 0) && (orderNo == 1))
+                dgv[0, cnt].Value = cnt.ToString();
+                dgv[1, cnt].Value = ((int)dgvKind.Footer).ToString();
+                dgv[6, cnt].Value = title[i];
+
+                cnt++;
+            }
+
+            return cnt;
+        }
+        #endregion
+
+        #region 全ての回の合計を反映
+        /// <summary>
+        /// 全ての回の合計を反映
+        /// </summary>
+        private void setAllOrderTotal()
+        {
+            for (int i = 1; i <= m_nMaxOrderNo; i++)
             {
-                if (m_ConstructionData.ConstructionStatusFlg < 8)
+                setOrderTotal(i);
+            }
+
+            return;
+        }
+        #endregion
+
+        #region 指定回の合計を反映
+        /// <summary>
+        /// 指定回の合計を反映
+        /// </summary>
+        private void setOrderTotal(int nOrderNo)
+        {
+            int i;
+            int tcol = nOrderNo + 7;
+            int nPrice = 0;
+            int nTax = 0;
+            int val;
+
+            for (i = 6; i <= m_nMaxRowNo; i += 2)
+            {
+                if (dgv1[2, i].Value == null)
                 {
-                    // 工事のステータスが施工完了未満の場合はエラー
-                    MessageBox.Show(this, s_MessageNotCompletionConstruction, s_RequestApprovalDialogTitle, MessageBoxButtons.OK, MessageBoxIcon.Error);
-                    chkResult = false;
+                    break;
                 }
-                else if (constPrice > billPrice)
+
+                // 請求金額
+                if (dgv1[tcol, i].Value != null)
                 {
-                    // 請求金額合計が工事金額に満たないので、確認ダイアログを表示
-                    DialogResult res = MessageBox.Show(this, s_MessageNotCompletionRequest, s_RequestApprovalDialogTitle, MessageBoxButtons.YesNo, MessageBoxIcon.Warning);
-                    chkResult = (res == DialogResult.Yes);
+                    val = CommonMotions.cnvInt(dgv1[tcol, i].Value.ToString());
+                    nPrice += val;
                 }
+
+                // 消費税
+                if (dgv1[tcol, i + 1].Value != null)
+                {
+                    val = CommonMotions.cnvInt(dgv1[tcol, i + 1].Value.ToString());
+                    nTax += val;
+                }
             }
-            else if (constPrice < billPrice)
+
+            setAmount(tcol, 2, nPrice + nTax);
+            setAmount(tcol, 3, nPrice);
+            setAmount(tcol, 4, nTax);
+
+            return;
+        }
+        #endregion
+
+        #region 残りの設定
+        /// <summary>
+        /// 残りの設定
+        /// </summary>
+        private void setBalance()
+        {
+            int i;
+
+            // 請求合計、請求金額、消費税、未入金分の残りを設定
+            for (i = 2; i < 6; i++)
             {
-                // 請求金額合計が工事金額を超えているので、確認ダイアログを表示
-                DialogResult res = MessageBox.Show(this, s_MessageOverRequest, s_RequestApprovalDialogTitle, MessageBoxButtons.YesNo, MessageBoxIcon.Warning);
-                chkResult = (res == DialogResult.Yes);
+                calcBalance(i);
             }
-            else
+
+            // 工事一覧の残りを設定
+            for (i = 6; i < 29; i += 2)
             {
-                // 承認データチェック
-                RequestApprovalStatus stat = RequestApprovalStatus.NowInput;
-                if (m_DicProcessApproval.ContainsKey(orderNo))
+                if (dgv1[2, i].Value == null)
                 {
-                    stat = CheckApprovalStatus(m_DicProcessApproval[orderNo], m_DicApprovalMaster);
+                    break;
                 }
 
-                if (stat == RequestApprovalStatus.NowInput)
+                calcBalance(i);
+
+                calcBalance(i + 1);
+            }
+        }
+        #endregion
+
+        #region 残りの算出
+        /// <summary>
+        /// 残りの算出
+        /// </summary>
+        private void calcBalance(int trow)
+        {
+            int nPrice = 0;
+            int nPayment = 0;
+            int tcol = dgv1.Columns.Count - 2;
+
+            nPrice = CommonMotions.cnvInt(dgv1[5, trow].Value);
+            nPayment = CommonMotions.cnvInt(dgv1[7, trow].Value);
+
+            setAmount(tcol, trow, nPrice - nPayment);
+        }
+        #endregion
+
+        #region 合計の設定
+        /// <summary>
+        /// 合計の設定
+        /// </summary>
+        private void setTotal()
+        {
+            int i;
+
+            // 請求合計、請求金額、消費税、未入金分の合計を設定
+            for (i = 2; i < 6; i++)
+            {
+                calcTotal(i);
+            }
+
+            // 工事一覧の合計を設定
+            for (i = 6; i < 29; i += 2)
+            {
+                if (dgv1[2, i].Value == null)
                 {
-                    DialogResult res = MessageBox.Show(this, s_MessageComfirmRequest, s_RequestApprovalDialogTitle, MessageBoxButtons.YesNo, MessageBoxIcon.Question);
-                    chkResult = (res == DialogResult.Yes);
+                    break;
                 }
 
+                calcTotal(i);
+                calcTotal(i + 1);
+
             }
+        }
+        #endregion
 
-            return chkResult;
+        #region 合計の算出
+        /// <summary>
+        /// 合計の算出
+        /// </summary>
+        private void calcTotal(int trow)
+        {
+            int tcol = 7;
+            int nPrice = 0;
+
+            nPrice = GetTotalPrice(trow);
+            setAmount(tcol, trow, nPrice);
         }
+        #endregion
 
+        #region 合計金額の取得
         /// <summary>
-        /// DataGridViewでのカラムインデックス番号を取得
+        /// 合計金額の取得
         /// </summary>
-        /// <param name="cEnum">カラム種別</param>
-        /// <param name="count">請求情報の回数。請求情報以外のカラム種別を指定する際は省略可</param>
-        /// <returns></returns>
-        private int GetColumnIndexNum(ColumnIndex cEnum, int count = 1)
+        private int GetTotalPrice(int trow)
         {
-            int cIndex = -1;
-            try
+            int val = 0;
+            int total = 0;
+
+            for (int i = 8; i < dgv1.Columns.Count - 2; i++)
             {
-                if (cEnum < ColumnIndex.RequestInfo)
+                if (dgv1[i, trow].Value != null)
                 {
-                    cIndex = (int)cEnum;
+                    val = CommonMotions.cnvInt(dgv1[i, trow].Value.ToString());
                 }
-                else if (cEnum == ColumnIndex.RequestInfo)
-                {
-                    cIndex = (int)ColumnIndex.RequestInfo + count - 1;
-                }
                 else
                 {
-                    cIndex = (int)cEnum + m_RequestColumnCount - 1;
+                    val = 0;
                 }
+                total += val;
             }
-            catch (Exception ex)
-            {
-                logger.ErrorFormat("システムエラー：{0}：{1}", CommonMotions.GetMethodName(), ex.Message);
-            }
 
-            return cIndex;
+            return total;
         }
+        #endregion
 
+        #region 金額の設定
         /// <summary>
-        /// DataGridViewでの行インデックス番号を取得
+        /// 金額の設定
         /// </summary>
-        /// <param name="cEnum">カラム種別</param>
-        /// <param name="count">請求情報の回数。請求情報以外のカラム種別を指定する際は省略可</param>
-        /// <returns></returns>
-        private int GetRowIndexNum(RowSectionIndex section, RowKind kind, int childIndex = 0)
+        private void setAmount(int tcol, int trow, int amount)
         {
-            int rIndex = -1;
-            try
+            dgv1[tcol, trow].Value = amount.ToString("#,0");
+
+            if (amount >= 0)
             {
-                var row = GetDataGridViewRowObject(section, kind, childIndex);
-                rIndex = (row != null) ? row.Index : -1;
+                dgv1[tcol, trow].Style.ForeColor = Color.Black;
             }
-            catch (Exception ex)
+            else
             {
-                logger.ErrorFormat("システムエラー：{0}：{1}", CommonMotions.GetMethodName(), ex.Message);
+                dgv1[tcol, trow].Style.ForeColor = Color.Red;
             }
-
-            return rIndex;
         }
+        #endregion
 
+        #region セル編集終了
         /// <summary>
-        /// DataGridViewRowオブジェクトをハッシュテーブルより取得する
+        ///  セル編集終了
         /// </summary>
-        /// <param name="sectIndex"></param>
-        /// <param name="kind"></param>
-        /// <param name="childIndex"></param>
-        /// <returns></returns>
-        private DataGridViewRow GetDataGridViewRowObject(RowSectionIndex sectIndex, RowKind kind, int childIndex = 0)
+        private void CellEditEnd(int tcol, int trow)
         {
-            DataGridViewRow dataGridRow = null;
+            // まだ編集中
+            if (dgv1[tcol, trow].IsInEditMode == true)
+            {
+                return;
+            }
 
-            try
+            if (dgv1[tcol, trow].Value == null)
             {
-                if (m_HtRowObject.ContainsKey(sectIndex))
+                dgv1[tcol, trow].Value = string.Empty;
+
+                return;
+            }
+
+
+            string str = dgv1[tcol, trow].Value.ToString().Replace(",", string.Empty);
+            if (string.IsNullOrEmpty(str) != true)
+            {
+                try
                 {
-                    var lst = m_HtRowObject[sectIndex] as List<Hashtable>;
+                    int n = int.Parse(str);
 
-                    if (childIndex < lst.Count)
+                    if (n >= 0)
                     {
-                        var htInSection = lst[childIndex] as Hashtable;
+                        dgv1[tcol, trow].Style.ForeColor = Color.Black;
+                    }
+                    else
+                    {
+                        dgv1[tcol, trow].Style.ForeColor = Color.Red;
+                    }
 
-                        if (htInSection.ContainsKey(kind))
-                        {
-                            dataGridRow = (DataGridViewRow)htInSection[kind];
-                        }
-                    }
+                    string s = n.ToString("#,0");
+                    dgv1[tcol, trow].Value = s;
+
                 }
+                catch
+                {
+                    dgv1[tcol, trow].Value = null;
+                    return;
+                }
             }
-            catch (Exception ex)
+            else
             {
-                logger.ErrorFormat("システムエラー：{0}：{1}", CommonMotions.GetMethodName(), ex.Message);
+                dgv1[tcol, trow].Value = null;
+
+                return;
             }
 
-            return dataGridRow;
+            return;
         }
+        #endregion
 
+        #endregion
+
+        #region チェック関連メソッド
+
+        #region 初期起動時チェック
         /// <summary>
-        /// DataGridViewRowオブジェクトをハッシュテーブルに設定する
+        /// 初期起動時チェック
         /// </summary>
-        /// <param name="gridRow"></param>
-        /// <param name="sectIndex"></param>
-        /// <param name="kind"></param>
-        /// <param name="childIndex"></param>
-        private void SetDataGridViewRowObject(DataGridViewRow gridRow, RowSectionIndex sectIndex, RowKind kind, int childIndex = 0)
+        private int CheckInit()
         {
-            try
-            {
-                List<Hashtable> lst;
-                if (!m_HtRowObject.ContainsKey(sectIndex))
-                {
-                    // ハッシュテーブルのリストを追加
-                    lst = new List<Hashtable>();
-                    m_HtRowObject.Add(sectIndex, lst);
+            int ret;
+            string wrk ;
+
+            StringBuilder sql = new StringBuilder();
+            IOConstructionLink ioLink = new IOConstructionLink();
+            IORequestData ioData = new IORequestData();
+
+            List<ConstructionLink> lstLink = new List<ConstructionLink>();
+            ArrayList ar = new ArrayList();
+
+            ret = -1;
+
+            try{
+                wrk = string.Format(" Where FluctuationCode = {0}", m_ConstructionCode);
+
+                if(ioLink.SelectAction(wrk, ref lstLink ) == false){
+                    return -1;
                 }
-                else
-                {
-                    lst = m_HtRowObject[sectIndex] as List<Hashtable>;
-                }
 
-                Hashtable htInSection;
-                if (lst.Count <= childIndex)
+                // 独立系はOK
+                if( lstLink.Count == 0)
                 {
-                    htInSection = new Hashtable();
-                    lst.Add(htInSection);
+                    return 0 ;
                 }
-                else
-                {
-                    htInSection = lst[childIndex] as Hashtable;
-                }
 
-                if (!htInSection.ContainsKey(kind))
+                // 結合子の場合は、結合親の本工事として請求データが存在するか確認する
+                sql.AppendLine("SELECT ");
+                sql.AppendLine("dt.MainConstructionCode ");
+                sql.AppendLine("FROM ");
+                sql.AppendLine("RequestHead hd ");
+                sql.AppendLine(",INNER JOIN RequestData dt ON hd.RequestNo = dt.RequestNo ");
+                sql.AppendLine("WHERE  ");
+                sql.AppendFormat("hd.ReqConstructionCode = {0}", lstLink[0].ConstructionCode);
+                sql.AppendFormat("And dt.MainConstructionCode = {0}", m_ConstructionCode);
+
+                if (ioData.ExecuteReader(sql.ToString(), ref ar) == false)
                 {
-                    htInSection.Add(kind, gridRow);
+                    return -1;
                 }
-                else
-                {
-                    htInSection[kind] = gridRow;
-                }
 
+                ret = ar.Count;
             }
             catch (Exception ex)
             {
                 logger.ErrorFormat("システムエラー：{0}：{1}", CommonMotions.GetMethodName(), ex.Message);
             }
+            finally
+            {
+                ioLink.close();
+                ioLink = null;
+                ioData.close();
+                ioData = null;
+            }
+
+            return ret;
         }
+        #endregion
 
-        /// <summary>
-        /// DataGridViewの初期表示設定
-        /// </summary>
-        private void SetGridDisplay()
+        #region 承認チェック
+
+        private int CheckApproval(ref List<int> lstMainConstructionCode)
         {
+            IOConstructionProgressDate ioProg = new IOConstructionProgressDate();
+
             try
             {
-                // DataGrid全体のプロパティ設定
-                dgv1.EnableHeadersVisualStyles = false;
-                dgv1.AutoGenerateColumns = false;
-                dgv1.ColumnHeadersHeight = this.dgv1.ColumnHeadersHeight + 5;
-                dgv1.ColumnHeadersDefaultCellStyle.Alignment = DataGridViewContentAlignment.MiddleCenter;
-                dgv1.ColumnHeadersDefaultCellStyle.BackColor = Color.Aquamarine;
-                dgv1.AllowUserToAddRows = false;
-                dgv1.RowTemplate.Height = 22;
-                dgv1.Font = new System.Drawing.Font("ＭＳ 明朝", 11.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(128)));
+                int nBalance = 0;
 
-                // 列タイトル設定
-                foreach (ColumnIndex cIndex in s_HtColumnTitles.Keys)
+                // 一括請求の場合
+                if (m_BaseConstructionBaseInfo.BillingSplitFlg == 0)
                 {
-                    if (s_HtColumnTitles[cIndex].GetType() == typeof(string))
+                    Dictionary<int, RequestData> dicReqData = m_lstRequestData[m_nMaxOrderNo - 1];
+
+                    List<int> lstKey = new List<int>(dicReqData.Keys);
+
+                    foreach (int nMainConstructionCode in lstKey)
                     {
-                        dgv1.Columns[GetColumnIndexNum(cIndex)].HeaderText = (string)s_HtColumnTitles[cIndex];
-                    }
-                    else if (s_HtColumnTitles[cIndex].GetType() == typeof(List<string>))
-                    {
-                        var lst = s_HtColumnTitles[cIndex] as List<string>;
-                        foreach (var strTitle in lst)
+                        ConstructionBaseInfo Info = null;
+
+                        if (m_dicConstructionBaseInfo.TryGetValue(nMainConstructionCode, out Info) == true)
                         {
-                            int colIndex = GetColumnIndexNum(cIndex, lst.IndexOf(strTitle) + 1);
-                            dgv1.Columns[colIndex].HeaderText = strTitle;
-                            dgv1.Columns[colIndex].HeaderCell.Style.ForeColor = Color.DarkGray;
+                            if (Info.ConstructionStatusFlg == (int)CommonDefine.StatNumArray.Status9)
+                            {
+                                continue;
+                            }
                         }
+                        string sql = ioProg.CreatePrimarykeyString(nMainConstructionCode, (int)CommonDefine.StatNumArray.Status9);
+                        List<ConstructionProgressDate> lstProg = new List<ConstructionProgressDate>();
+                        if (ioProg.SelectAction(sql, ref lstProg) == false)
+                        {
+                            return (int)CheckResult.UnknownError;
+                        }
+
+                        // 施工完了が存在しない場合
+                        if (lstProg.Count == 0)
+                        {
+                            lstMainConstructionCode.Add(nMainConstructionCode);
+                        }
                     }
+                    // 本工事番号が登録されている場合
+                    if (lstMainConstructionCode.Count > 0)
+                    {
+                        return (int)CheckResult.ErrorStatus;
+                    }
+
+                    nBalance = CommonMotions.cnvInt(dgv1[dgv1.ColumnCount-1, 2].Value); 
+                    // 請求残が存在する場合
+                    if( nBalance > 0 )
+                    {
+                        return (int)CheckResult.WarningUnmatch;
+                    }
                 }
 
-                // 行追加処理
-                int rIndex = 0;
-                foreach (RowSectionIndex sectionIndex in Enum.GetValues(typeof(RowSectionIndex)))
+                nBalance = CommonMotions.cnvInt(dgv1[dgv1.ColumnCount - 1, 2].Value);
+                // 請求残がマイナスの場合
+                if( nBalance < 0 )
                 {
-                    // セクションごとの処理
+                    return (int)CheckResult.WarningOver;
+                }
 
-                    for (int sectLoop = 0; sectLoop < ((sectionIndex == RowSectionIndex.ChildConstruction) ? 4 : 1); sectLoop++)
+            }
+            catch (Exception ex)
+            {
+                logger.ErrorFormat("システムエラー：{0}：{1}", CommonMotions.GetMethodName(), ex.Message);
+            }
+            finally
+            {
+                ioProg.close();
+                ioProg = null;
+            }
+
+
+            return (int)CheckResult.NoError;
+        }
+        #endregion
+
+        #region エラー表示セット
+        private void SetErrorIndicate( List<int>lstErrorConstructionCode)
+        {
+            foreach( int nMainConstrucitionCode in lstErrorConstructionCode)
+            {
+                for (int i = 6; i <= m_nMaxRowNo; i += 2)
+                {
+                    int nConstructionCode = int.Parse(dgv1[2, i].Value.ToString());
+                    if (nConstructionCode == nMainConstrucitionCode)
                     {
-                        // 増減工事セクションは4回繰り返す
+                        dgv1[4, i].Style.BackColor = Color.Red;
 
-                        foreach (RowKind kindIndex in s_HtRowSections[sectionIndex])
-                        {
-                            // セクション内の行の追加
-                            dgv1.Rows.Add();
-                            dgv1.Rows[dgv1.RowCount - 1].Cells[GetColumnIndexNum(ColumnIndex.SectionIndex)].Value = sectionIndex;
-                            dgv1.Rows[dgv1.RowCount - 1].Cells[GetColumnIndexNum(ColumnIndex.RowKind)].Value = kindIndex;
+                        break;
+                    }
+                }
+            }
 
-                            // ハッシュデータに行オブジェクトを追加
-                            SetDataGridViewRowObject(dgv1.Rows[rIndex], sectionIndex, kindIndex, sectLoop);
+            return ;
+        }
+        #endregion
 
-                            // 固定表示ラベルの設定
-                            if (s_HtLabels.ContainsKey(sectionIndex) && s_HtLabels[sectionIndex].ContainsKey(kindIndex))
-                            {
-                                foreach (ColumnIndex cIndex in s_HtLabels[sectionIndex][kindIndex].Keys)
-                                {
-                                    int cNum = GetColumnIndexNum(cIndex);
-                                    dgv1.Rows[rIndex].Cells[cNum].Value = s_HtLabels[sectionIndex][kindIndex][cIndex];
-                                    dgv1.Rows[rIndex].Cells[cNum].Style.Alignment = DataGridViewContentAlignment.MiddleCenter;
-                                }
-                            }
+        #region エラー表示クリア
+        private void ClearErrorIndicate()
+        {
+            int nColor = 0;
 
-                            // 背景色の設定
-                            SetRowBackgroundColor(sectionIndex, dgv1.Rows[rIndex], sectLoop);
+            for (int i = 6; i <= m_nMaxRowNo; i += 2)
+            {
+                if ( nColor == 0)
+                {
+                    dgv1[4, i].Style.BackColor = Color.White;
 
-                            if (sectionIndex == RowSectionIndex.ChildConstruction)
-                            {
-                                // 増減工事行は一旦文字色をDarkGrayに設定
-                                dgv1.Rows[rIndex].DefaultCellStyle.ForeColor = Color.DarkGray;
+                    nColor = 1;
+                }
+                else
+                {
+                    dgv1[4, i].Style.BackColor = Color.LightBlue;
 
-                            }
-                            rIndex++;
-                        }
-                    }
+                    nColor = 0;
                 }
+            }
 
-                dgv1.Rows[2].Frozen = true;
+            return;
+        }
+        #endregion
 
-                GetDisplayDatas();
+        #endregion
+
+        #region データ取得関連メソッド
+
+        #region 表示データの取得
+        private void GetRequestDispData()
+        {
+            // 請求ヘッダの取得
+            GetRequestHead();
+
+            // 請求ヘッダが存在しない場合(初回起動）
+            if (m_lstRequestHead.Count == 0)
+            {
+                // 請求データを現在の工事データより構築する
+                CreateRequest();
             }
-            catch (Exception ex)
+            else
             {
-                logger.ErrorFormat("システムエラー：{0}：{1}", CommonMotions.GetMethodName(), ex.Message);
+                RequestHead    ReqHead = m_lstRequestHead[m_nMaxOrderNo-1];
+
+                // 請求年月と請求金額合計を退避（詳細台帳反映用）
+                m_nOldRequestMonth = ReqHead.RequestMonth;
+                m_nOldRequestAmount = ReqHead.RequestAmount;
+
+                // 請求データと請求明細の取得
+                GetRequestDataAndDetail(ReqHead.RequestNo);
+
             }
+
+            // 入金データの取得
+            GetDepositData();
+
+            // 対象が結合子工事の場合
+            if (m_BaseConstructionBaseInfo.JoinFlg == 2)
+            {
+                GetConstructionLinkFromFluctuationCode(m_BaseConstructionBaseInfo.ConstructionCode, 1, ref m_nLeaderConstructionCode);
+            }
+            else
+            {
+                m_nLeaderConstructionCode = m_ConstructionCode;
+            }
+
+            // 詳細台帳の取得
+            GetConstructionLedger(m_nLeaderConstructionCode, ref m_ConstructionLedger);
+
+            // 承認経路の取得
+            GetApprovalMaster(m_BaseConstructionBaseInfo.ConstructionPersonCode, ref m_dicApprovalMaster);
+
+            // 承認データの取得
+            GetProcessApproval( m_ConstructionCode, ref m_dicProcessApproval );
+
         }
+        #endregion
 
-        /// <summary>
-        /// 増減工事行の追加処理
-        /// </summary>
-        /// <param name="stbIndex"></param>
-        private void AddChildConstructionInfoRow(int stbIndex)
+        #region 工事文字列の追加
+        private void AddConstructionString(int key, string str)
         {
+            string wk;
+
+            if (m_dicConstructionName.TryGetValue(key, out wk) == false)
+            {
+                m_dicConstructionName.Add(key, str);
+            }
+
+            return;
+        }
+        #endregion
+
+        #region 工事基本情報の追加
+        private void AddConstructionBaseInfo(int key, ConstructionBaseInfo info)
+        {
+            ConstructionBaseInfo wk;
+
+            if (m_dicConstructionBaseInfo.TryGetValue(key, out wk) == false)
+            {
+                m_dicConstructionBaseInfo.Add(key, info);
+            }
+
+            return;
+        }
+        #endregion
+
+        #region 請求ヘッダの取得
+        private void GetRequestHead()
+        {
+            IORequestHead ioReqHead = new IORequestHead();
+            IORequestData ioReqData = new IORequestData();
+            IORequestDataDetail ioReqDetail = new IORequestDataDetail();
+
+            string strSQL;
+
             try
             {
-                // 増減工事最終行のオブジェクトを取得
-                var lastChldConstRow = GetDataGridViewRowObject(RowSectionIndex.ChildConstruction, RowKind.TaxPrice, m_ChildConstructionRowCount - 1);
+                // 工事基本情報の取得
+                GetConstructionBaseInfo(m_ConstructionCode, ref m_BaseConstructionBaseInfo);
 
-                // 増減工事最終行の行番号を取得
-                int lastChldConstRowIndex = dgv1.Rows.IndexOf(lastChldConstRow);
+                AddConstructionBaseInfo(m_ConstructionCode, m_BaseConstructionBaseInfo);
 
-                // 行を追加
-                foreach (RowKind kindIndex in s_HtRowSections[RowSectionIndex.ChildConstruction])
+                // 工事基本情報明細（文字列）の取得
+                GetConstructionBaseInfoDetail(m_ConstructionCode, ref m_dicBaseConstructionString);
+
+
+                // 請求ヘッダを取得
+                strSQL = ioReqHead.CreateSubkeyString(m_ConstructionCode);
+                strSQL += " Order by OrderNo Asc " ;
+                if (ioReqHead.SelectAction(strSQL, ref m_lstRequestHead) == false)
                 {
-                    // 行オブジェクト作成
-                    var rowObject = new DataGridViewRow();
+                    return;
+                }
 
-                    // セクション内の行の挿入
-                    dgv1.Rows.Insert(++lastChldConstRowIndex, rowObject);
+                // 請求ヘッダがない場合は請求データがＤＢ上に存在しないため終了
+                if (m_lstRequestHead.Count == 0)
+                {
+                    return;
+                }
 
-                    dgv1.Rows[lastChldConstRowIndex].Cells[GetColumnIndexNum(ColumnIndex.SectionIndex)].Value = RowSectionIndex.ChildConstruction;
-                    dgv1.Rows[lastChldConstRowIndex].Cells[GetColumnIndexNum(ColumnIndex.RowKind)].Value = kindIndex;
+                // 最新の請求Noおよび受付番号を確保
+                m_nRequestNo = m_lstRequestHead[m_lstRequestHead.Count-1].RequestNo;
+                m_nMaxOrderNo = m_lstRequestHead[m_lstRequestHead.Count-1].OrderNo;
 
-                    // 行の背景色を設定
-                    SetRowBackgroundColor(RowSectionIndex.ChildConstruction, dgv1.Rows[lastChldConstRowIndex], stbIndex);
+                // 請求ヘッダレコード分ループ
+                foreach (RequestHead ReqHead in m_lstRequestHead)
+                {
+                    // 直近受付は、工事情報と絡めて実施
+                    if (ReqHead.OrderNo == m_nMaxOrderNo)
+                    {
+                        break;
+                    }
 
-                    // ハッシュデータに行オブジェクトを追加
-                    SetDataGridViewRowObject(dgv1.Rows[lastChldConstRowIndex], RowSectionIndex.ChildConstruction, kindIndex, stbIndex);
+                    // 請求データリストの構築（ＤＢ取得用）
+                    List<RequestData> lstData = new List<RequestData>();
 
-                    // 固定ラベルの表示
-                    if (s_HtLabels.ContainsKey(RowSectionIndex.ChildConstruction))
+                    // 請求データの取得(検索キーは請求Noのみ)
+                    strSQL = ioReqData.CreatePrimarykeyString(ReqHead.RequestNo);
+                    strSQL += " Order by MainConstructionCode Asc ";
+                    if (ioReqData.SelectAction(strSQL, ref lstData) == false)
                     {
-                        if (s_HtLabels[RowSectionIndex.ChildConstruction].ContainsKey(kindIndex))
+                        return;
+                    }
+
+                    if( lstData.Count == 0){
+                        return;
+                    }
+
+                    // 請求データ辞書（キー：本工事番号）の構築
+                    Dictionary<int, RequestData> dicData = new Dictionary<int, RequestData>();
+
+                    // 請求データ明細リスト辞書（キー：本工事番号）の構築
+                    Dictionary<int, List<RequestDataDetail>> dicDetail = new Dictionary<int, List<RequestDataDetail>>(); 
+
+                    foreach( RequestData ReqData in lstData)
+                    {
+                        dicData.Add(ReqData.MainConstructionCode, ReqData);
+                        
+                        List<RequestDataDetail> lstDetail = new List<RequestDataDetail>();
+
+                        // 請求データ明細の取得
+                        strSQL = ioReqDetail.CreatePrimarykeyString(ReqData.RequestNo, ReqData.MainConstructionCode);
+                        strSQL += " Order by ConstructionKind Asc, ConstructionCode Asc ";
+                        if (ioReqDetail.SelectAction(strSQL, ref lstDetail) == false)
                         {
-                            foreach (var colIndex in s_HtLabels[RowSectionIndex.ChildConstruction][kindIndex].Keys)
-                            {
-                                int cIndex = GetColumnIndexNum(colIndex);
-                                dgv1.Rows[lastChldConstRowIndex].Cells[cIndex].Value = s_HtLabels[RowSectionIndex.ChildConstruction][kindIndex][colIndex];
-                            }
+                            return;
                         }
+
+                        if( lstDetail.Count == 0){
+                            return;
+                        }
+
+                        dicDetail.Add(ReqData.MainConstructionCode, lstDetail); 
+                        
                     }
 
+                    m_lstRequestData.Add(dicData);
+                    m_lstRequestDataDetail.Add(dicDetail);
                 }
 
-                m_ChildConstructionRowCount++;
             }
             catch (Exception ex)
             {
                 logger.ErrorFormat("システムエラー：{0}：{1}", CommonMotions.GetMethodName(), ex.Message);
             }
+            finally
+            {
+                ioReqHead.close();
+                ioReqHead = null;
+                ioReqData.close();
+                ioReqData = null;
+                ioReqDetail.close();
+                ioReqDetail = null;
+            }
+
         }
+        #endregion
 
-        /// <summary>
-        /// 行の背景色の設定
-        /// </summary>
-        /// <param name="sectionIndex"></param>
-        /// <param name="gridRow"></param>
-        /// <param name="sectLoop"></param>
-        private void SetRowBackgroundColor(RowSectionIndex sectionIndex, DataGridViewRow gridRow, int sectLoop = 0)
+        #region 請求データ、明細の取得
+        private void GetRequestDataAndDetail(int nRequestNo)
         {
+            string sql = "";
+            string str = "";
+
+            IORequestData ioReqData = new IORequestData();
+            IORequestDataDetail ioReqDetail = new IORequestDataDetail();
+
+            Dictionary<int, RequestData> dicData = new Dictionary<int, RequestData>();
+            Dictionary<int, List<RequestDataDetail>> dicDetail = new Dictionary<int, List<RequestDataDetail>>();
+
             try
             {
-                // 行の背景色の設定
-                if (s_HtRowColors.ContainsKey(sectionIndex))
+                List<int> lstMainConstructionCode = new List<int>();
+
+                // 結合フラグが結合（親）以外の場合
+                if (m_BaseConstructionBaseInfo.JoinFlg != 1)
                 {
-                    if (s_HtRowColors[sectionIndex].GetType() == typeof(Color))
+                    // 単独、結合（子）は、請求工事＝本工事
+                    lstMainConstructionCode.Add(m_ConstructionCode);
+
+                }
+                else
+                {
+                    // リンク種別が結合子の工事で検索
+                    GetConstructionLink(m_ConstructionCode, 1, ref lstMainConstructionCode);
+                }
+
+                List<RequestData> lstDataWork = new List<RequestData>();
+                sql = ioReqData.CreatePrimarykeyString(nRequestNo);
+                sql += " Order By MainConstructionCode Asc ";
+
+                if (ioReqData.SelectAction(sql, ref lstDataWork) == false)
+                {
+                    return;
+                }
+ 
+                Dictionary<int,RequestData> dicDataWork = new Dictionary<int,RequestData>();
+                foreach (RequestData ReqData in lstDataWork)
+                {
+                    dicDataWork.Add(ReqData.MainConstructionCode, ReqData);
+                }
+
+
+                ConstructionBaseInfo info = null;
+                Dictionary<int, string> dicString = null;
+
+                foreach (int nMainConstructonCode in lstMainConstructionCode)
+                {
+                    bool bNewMainConstruction = false;
+
+                    RequestData ReqData = null;
+
+                    info = new ConstructionBaseInfo();
+                    dicString = new Dictionary<int, string>();
+
+                    GetConstructionBaseInfo(nMainConstructonCode, ref info);
+                    AddConstructionBaseInfo(nMainConstructonCode, info);
+
+                    GetConstructionBaseInfoDetail(nMainConstructonCode, ref dicString);
+                    // 工事件名
+                    if (dicString.TryGetValue((int)ConstructionBaseInfoDetail.DetailDataNo.ConstructionName, out str) == true)
                     {
-                        // セクションごとの色を設定
-                        gridRow.DefaultCellStyle.BackColor = (Color)s_HtRowColors[sectionIndex];
+                        AddConstructionString(nMainConstructonCode, str);
                     }
-                    else if (s_HtRowColors[sectionIndex].GetType() == typeof(List<Color>))
+
+                    // 請求データが存在しない場合（結合子工事が増えた）
+                    if (dicDataWork.TryGetValue(nMainConstructonCode, out ReqData) == false)
                     {
-                        var lst = s_HtRowColors[sectionIndex] as List<Color>;
-                        gridRow.DefaultCellStyle.BackColor = lst[(sectLoop % lst.Count)];
+                        // 請求データを生成
+                        ReqData = new RequestData();
+
+                        ReqData.RequestNo = nRequestNo;
+                        ReqData.MainConstructionCode = nMainConstructonCode;
+                        // 工事件名
+                        ReqData.ConstructionName = str;
+
+                        bNewMainConstruction = true;
                     }
-                    else
+
+                    dicData.Add(nMainConstructonCode, ReqData);
+
+                    List<RequestDataDetail> lstDetailWork = new List<RequestDataDetail>();
+                    List<RequestDataDetail> lstDetail = new List<RequestDataDetail>();
+                    Dictionary<int, RequestDataDetail> dicDetailWork = new Dictionary<int, RequestDataDetail>();
+
+                    List<int> lstConstructionCode = new List<int>();
+                    GetConstructionLink(nMainConstructonCode, 0, ref lstConstructionCode);
+
+                    if (bNewMainConstruction == false)
                     {
-                        gridRow.DefaultCellStyle.BackColor = Color.White;
+                        sql = ioReqDetail.CreatePrimarykeyString(nRequestNo, nMainConstructonCode);
+                        sql += " Order By ConstructionKind Asc, ConstructionCode Asc";
+                        if (ioReqDetail.SelectAction(sql, ref lstDetailWork) == false)
+                        {
+                            return;
+                        }
+                        foreach (RequestDataDetail ReqDetail in lstDetailWork)
+                        {
+                            dicDetailWork.Add(ReqDetail.ConstructionCode, ReqDetail);
+                        }
+
                     }
 
-                    if (gridRow.DefaultCellStyle.BackColor == Color.White)
+                    RequestDataDetail ReqDetailMain = null;
+
+                    // 本工事で構築
+                    if (dicDetailWork.TryGetValue(nMainConstructonCode, out ReqDetailMain) == false)
                     {
-                        gridRow.Cells[GetColumnIndexNum(ColumnIndex.Headline)].Style.BackColor = System.Drawing.SystemColors.Control;
-                        gridRow.Cells[GetColumnIndexNum(ColumnIndex.Label)].Style.BackColor = System.Drawing.SystemColors.Control;
+                        ReqDetailMain = new RequestDataDetail();
+                        ReqDetailMain.RequestNo = nRequestNo;
+                        ReqDetailMain.MainConstructionCode = nMainConstructonCode;
+                        ReqDetailMain.ConstructionKind = 0;
                     }
+                    lstDetail.Add(ReqDetailMain);
+ 
+                    foreach (int nConstructionCode in lstConstructionCode)
+                    {
+                        RequestDataDetail ReqDetailSub = null;
+
+                        if (dicDetailWork.TryGetValue(nConstructionCode, out ReqDetailSub) == false)
+                        {
+                            ReqDetailSub = new RequestDataDetail();
+                            ReqDetailSub.RequestNo = nRequestNo;
+                            ReqDetailSub.MainConstructionCode = nMainConstructonCode;
+                            ReqDetailSub.ConstructionKind = 1;
+                        }
+
+                        info = new ConstructionBaseInfo();
+                        GetConstructionBaseInfo(nConstructionCode, ref info);
+                        AddConstructionBaseInfo(nConstructionCode, info);
+
+                        dicString = new Dictionary<int, string>();
+                        GetConstructionBaseInfoDetail(nConstructionCode, ref dicString);
+
+                        if( dicString.TryGetValue((int)ConstructionBaseInfoDetail.DetailDataNo.ConstructionName, out str) == true ){
+                            AddConstructionString(nConstructionCode, str);
+                        }
+
+                        lstDetail.Add(ReqDetailSub); 
+                    }
+
+                    dicDetail.Add( nMainConstructonCode, lstDetail);
+
                 }
 
+                m_lstRequestData.Add(dicData);
+                m_lstRequestDataDetail.Add(dicDetail);
+
             }
             catch (Exception ex)
             {
                 logger.ErrorFormat("システムエラー：{0}：{1}", CommonMotions.GetMethodName(), ex.Message);
             }
+            finally
+            {
+                ioReqData.close();
+                ioReqData = null;
+                ioReqDetail.close();
+                ioReqDetail = null;
+            }
+
+
         }
+        #endregion
 
-        /// <summary>
-        /// データベースよりデータを取得し、画面表示に反映する
-        /// </summary>
-        private void GetDisplayDatas()
+        #region 入金データ取得
+        private void GetDepositData()
         {
-            try
+            for (int i = 0; i < m_lstRequestHead.Count; i++)
             {
-                // 工事基本情報取得
-                if (GetConstructionBaseInfo(m_ConstructionCode, ref m_ConstructionData))
-                {
-                    // 請求データ取得
-                    if (GetRequestData(ref m_RequestData))
-                    {
-                        // 請求合計データ取得
-                        if (GetRequestTotalDatas(m_RequestData.RequestNo, ref m_LstRequestTotalData))
-                        {
-                            // 請求明細データ取得
-                            GetRequestDataDetails(m_RequestData.RequestNo, ref m_DicRequestDataDetail);
+                RequestHead ReqHead = m_lstRequestHead[i];
 
-                            // 入金明細データ取得
-                            GetDepositDataDetail(m_RequestData.RequestNo, ref m_DicDepositDataDetail);
+                List<DepositDataDetail> lstDepDetail = new List<DepositDataDetail>() ;
 
-                            // 承認データ取得
-                            GetProcessApproval(m_ConstructionCode, ref m_DicProcessApproval);
-                        }
-                    }
-                    else
+                GetDepositDataDetail( ReqHead.RequestNo, ref lstDepDetail);
+
+                DepositDataDetail DepDetail = null;
+                int nDepositState = (int)DepositState.None;
+                DateTime dtDeposit = DateTime.MinValue;
+
+                if (lstDepDetail.Count > 0)
+                {
+                    DepDetail = lstDepDetail[0];
+                    if (DepDetail.ApprovalEndFlg == true)
                     {
-                        isEmptyConstructionBaseInfo = true;
-                        // 工事番号から工事基本情報を取得
-                        m_RequestData.RequestNo = m_ConstructionCode;
-                        m_RequestData.ConstructionCode = m_ConstructionCode;
-                        if (!GetRequestDataFromConstructionBase(ref m_RequestData)) return;
+                        nDepositState = (int)DepositState.Done;
                     }
 
-                    // 工事基本情報明細取得
-                    GetConstructionBaseInfoDetail(m_ConstructionCode, ref m_DicConstructionDetail);
+                    DepositData DepData = new DepositData();
+                    GetDepositData(DepDetail.OrderersDivision, DepDetail.OrderersCode, DepDetail.TargetDate, DepDetail.SeqNo, ref DepData);
+                    dtDeposit = DepData.DepositDate;
 
-                    // 工事詳細台帳データ取得
-                    GetConstructionLedger(m_ConstructionCode, ref m_ConstructionLedger);
+                }
+                else
+                {
+                    DepDetail = new DepositDataDetail();
+                }
 
-                    // 工事増減情報取得
-                    if (GetConstructionLink(ref m_LstConstructionLink))
-                    {
-                        // 増減工事の工事基本情報をすべて取得
-                        if (GetChildConstructionBaseInfo(m_LstConstructionLink, ref m_LstChldContructionData))
-                        {
-                            // 増減工事の工事明細情報をすべて取得
-                            GetChildConstructionBaseInfoDetail(m_LstConstructionLink, ref m_DicChldConstructionDetail);
+                m_lstDepDataDetail.Add(DepDetail);
+                m_lstDepositState.Add(nDepositState);
+                m_lstDepositDate.Add(dtDeposit);
 
-                            // 増減工事の工事詳細台帳データを取得
-                            GetChildConstructionLedger(m_LstConstructionLink, ref m_DicChldConstructionLedger);
-                        }
-                    }
+            }
+        }
+        #endregion
 
-                    // 案件進捗日付データを取得
-                    GetConstructionProgressDate(m_ConstructionCode, ref m_DicConstProgressDate);
+        #region 請求データの生成
+        private void CreateRequest()
+        {
+            // 最大受付番号加算
+            m_nMaxOrderNo++;
 
-                    // 承認経路マスタを取得
-                    GetApprovalMaster(m_ConstructionData.ConstructionPersonCode, ref m_DicApprovalMaster);
+            // 請求ヘッダの生成
+            CreateRequestHead(m_nMaxOrderNo);
 
-                }
+            // 請求データの生成
+            CreateRequestData();
+            
+            // 請求データ明細の生成
+            CreateRequestDataDetail();
+        }
+        #endregion
 
-                // 請求先名ラベル設定
-                if (m_DicConstructionDetail.ContainsKey((int)ConstructionBaseInfoDetail.DetailDataNo.OrderersName))
-                {
-                    label1.Text = (string)m_DicConstructionDetail[(int)ConstructionBaseInfoDetail.DetailDataNo.OrderersName];
-                }
-                label1.TextAlign = ContentAlignment.MiddleLeft;
+        #region 請求ヘッダの生成
+        private void CreateRequestHead(int nOrderNo)
+        {
+            RequestHead ReqHead = new RequestHead();
 
-                // 工事状態表示
-                SetConstructionStatus();
+            ReqHead.ReqConstructionCode = m_ConstructionCode;           // 請求工事番号
 
-                // 本工事行表示
-                SetOriginalConstructionInfo();
+            string str;
 
-                // 増減工事行表示
-                SetChildConstructionInfo();
+            // 請求Noは登録時に採番（初期値）  
 
-                // 請求明細列表示
-                foreach (var total in m_LstRequestTotalData)
-                {
-                    SetRequestInfoColumn(total.OrderNo - 1);
-                }
+            // 受付番号は引数の受付番号に準拠                                      
+            ReqHead.OrderNo = nOrderNo;
 
-                // 入金情報行表示
-                SetDepositInfo();
+            // 請求年月も登録時に決定（初期値）      
 
-                // 自動計算セル表示
-                SetAutoCalcRow();
+            ReqHead.OrderersDivision = m_BaseConstructionBaseInfo.OrderersDivision;   // 発注者区分   
+            ReqHead.OrderersCode = m_BaseConstructionBaseInfo.OrderersCode;           // 発注者コード
 
-                // 合計行表示
-                SetTotalInfo();
+            // 発注者名
+            m_dicBaseConstructionString.TryGetValue((int)ConstructionBaseInfoDetail.DetailDataNo.OrderersName, out str);
+            ReqHead.OrderersName = str;
 
-                // 入金情報行表示
-                SetDepositInfo();
+            // 工事件名
+            m_dicBaseConstructionString.TryGetValue((int)ConstructionBaseInfoDetail.DetailDataNo.ConstructionName, out str);
+            ReqHead.ReqConstructionName = str;
 
-                // データが存在しない場合
-                if (m_LstRequestTotalData.Count == 0)
-                {
-                    // 1回目を追加
-                    AddRequest();
-                }
+            // 請求金額関係は全て0（初期値）
+            // 備考は初期値
+            // 割当済フラグも初期値
+            // 請求書Noも初期値
 
+            // リストに追加
+            m_lstRequestHead.Add(ReqHead);
 
-            }
-            catch (Exception ex)
-            {
-                logger.ErrorFormat("システムエラー：{0}：{1}", CommonMotions.GetMethodName(), ex.Message);
-            }
-
+            return;
         }
+        #endregion
 
-        /// <summary>
-        /// 工事状態表示設定
-        /// </summary>
-        private void SetConstructionStatus()
+        #region 請求データの生成
+        private void CreateRequestData()
         {
-            // 状態フラグが10(請求完了)が存在すれば
-            if (m_DicConstProgressDate.ContainsKey(10))
+            List<int> lstConstructionCode = new List<int>();
+            Dictionary<int, RequestData> dicData = new Dictionary<int, RequestData>();
+
+            // 結合フラグが結合（親）以外の場合
+            if (m_BaseConstructionBaseInfo.JoinFlg != 1)
             {
-                lblStatus.Text = "請求完了";
-                lblStatus.BackColor = Color.Blue;
-                lblStatus.ForeColor = Color.White;
+                // 単独、結合（子）は、請求工事＝本工事
+                lstConstructionCode.Add(m_ConstructionCode);
+
             }
-            // 状態フラグが9(請求準備)が存在すれば
-            else if(m_DicConstProgressDate.ContainsKey(9))
+            else
             {
-                lblStatus.Text = "請求準備";
-                lblStatus.BackColor = Color.GreenYellow;
-                lblStatus.ForeColor = Color.Black;
+                // リンク種別が結合子の工事で検索
+                GetConstructionLink(m_ConstructionCode, 1, ref lstConstructionCode);
             }
-            // その他
-            else
+
+            foreach (int nConstructionCode in lstConstructionCode)
             {
-                lblStatus.Text = "";
-                lblStatus.BackColor = Color.Black;
-                lblStatus.ForeColor = Color.White;
+                RequestData data = new RequestData();
+
+                ConstructionBaseInfo info = new ConstructionBaseInfo();
+                Dictionary<int, string> dic = new Dictionary<int, string>();
+
+                string str;
+
+                GetConstructionBaseInfo(nConstructionCode, ref info);
+                AddConstructionBaseInfo(nConstructionCode, info);
+
+                GetConstructionBaseInfoDetail(nConstructionCode, ref dic);
+
+                // 請求Noは登録時に決定
+                data.MainConstructionCode = nConstructionCode;      // 本工事番号
+
+                // 工事件名
+                dic.TryGetValue((int)ConstructionBaseInfoDetail.DetailDataNo.ConstructionName, out str);
+                data.ConstructionName = str;
+
+                dicData.Add(nConstructionCode, data);
             }
 
+            m_lstRequestData.Add(dicData);
         }
+        #endregion
 
-        /// <summary>
-        /// 本工事行表示設定
-        /// </summary>
-        /// <param name="m_HtConstructionDetail"></param>
-        /// <param name="m_ConstructionLedger"></param>
-        private void SetOriginalConstructionInfo()
+        #region 請求データ明細の生成
+        private void CreateRequestDataDetail()
         {
-            try
+            RequestDataDetail data;
+
+            Dictionary<int, RequestData> dicData = m_lstRequestData[0];
+
+            Dictionary<int, List<RequestDataDetail>> dicDetail = new Dictionary<int, List<RequestDataDetail>>();
+
+            List<int> lstKey = new List<int>(dicData.Keys);
+
+            foreach (int nMainConstructionCode in lstKey)
             {
-                var gridRowBillPrice = GetDataGridViewRowObject(RowSectionIndex.OriginalConstruction, RowKind.BillPrice);
-                var gridRowTaxPrice = GetDataGridViewRowObject(RowSectionIndex.OriginalConstruction, RowKind.TaxPrice);
-                var gridRowAmount = GetDataGridViewRowObject(RowSectionIndex.OriginalConstruction, RowKind.AmountPrice);
+                string str;
 
-                // 工事金額の消費税額を計算
-                double constructionTaxPrice = Math.Truncate(m_ConstructionLedger.OrdersDecisionPrice * m_TaxRate);
+                List<RequestDataDetail> lstDetail = new List<RequestDataDetail>();
 
-                int cIndex;
+                List<int> lstWork = new List<int>();
 
-                // 工事番号
-                cIndex = GetColumnIndexNum(ColumnIndex.ConstructionCode);
-                gridRowBillPrice.Cells[cIndex].Value = m_ConstructionCode;
-                gridRowTaxPrice.Cells[cIndex].Value = m_ConstructionCode;
-                gridRowAmount.Cells[cIndex].Value = m_ConstructionCode;
+                data = new RequestDataDetail();
 
-                // 工事名
-                cIndex = GetColumnIndexNum(ColumnIndex.ConstructionName);
-                gridRowBillPrice.Cells[cIndex].Value = m_DicConstructionDetail[(int)ConstructionBaseInfoDetail.DetailDataNo.ConstructionName];
+                // 請求Noは登録時に裁判
+                data.MainConstructionCode = nMainConstructionCode;          // 本工事番号
+                data.ConstructionCode = nMainConstructionCode;              // 工事番号
+                data.ConstructionKind = 0;                                  // 工事区分(=本工事)
 
-                // 工事金額
-                cIndex = GetColumnIndexNum(ColumnIndex.ConstructionPrice);
-                SetDataGridCellDecimal(gridRowBillPrice.Cells[cIndex], m_ConstructionLedger.OrdersDecisionPrice);
-                SetDataGridCellDecimal(gridRowTaxPrice.Cells[cIndex], constructionTaxPrice);
+                lstDetail.Add(data);
 
+                // 増減工事の取得
+                GetConstructionLink(nMainConstructionCode, 0, ref lstWork);
+
+                foreach (int nConstructionCode in lstWork)
+                {
+                    ConstructionBaseInfo info = new ConstructionBaseInfo();
+                    GetConstructionBaseInfo(nConstructionCode, ref info);
+                    AddConstructionBaseInfo(nConstructionCode, info);
+
+                    data = new RequestDataDetail();
+
+                    // 請求Noは登録時に裁判
+                    data.MainConstructionCode = nMainConstructionCode;          // 本工事番号
+                    data.ConstructionCode = nConstructionCode;                  // 工事番号
+                    data.ConstructionKind = 1;                                  // 工事区分(=増減工事)
+
+                    Dictionary<int, string> dicString = new Dictionary<int, string>();
+                    GetConstructionBaseInfoDetail(nConstructionCode, ref dicString);
+
+                    dicString.TryGetValue((int)ConstructionBaseInfoDetail.DetailDataNo.ConstructionName, out str);
+                    AddConstructionString(nConstructionCode, str);
+
+                    lstDetail.Add(data);
+                }
+
+                dicDetail.Add(nMainConstructionCode, lstDetail);
             }
-            catch (Exception ex)
+
+            m_lstRequestDataDetail.Add(dicDetail);
+
+            return;
+        }
+        #endregion
+
+        #endregion
+
+        #region 設定系メソッド
+
+        #region 表示データの設定
+        private void SetRequestDispData()
+        {
+            this.dgv1.CellBeginEdit -= dgv1_CellBeginEdit;
+            this.dgv1.CellFormatting -= this.dgv1_CellFormatting;
+
+            RequestHead ReqHead = m_lstRequestHead[m_nMaxOrderNo - 1];
+
+            // 請求先名
+            txtOrderer.Text = ReqHead.OrderersName;
+
+            // 編集可かつ請求書データに紐づかない場合のみ編集可能
+            if ((m_bEdit == true) && (ReqHead.InvoiceNo == 0))
             {
-                logger.ErrorFormat("システムエラー：{0}：{1}", CommonMotions.GetMethodName(), ex.Message);
+                txtOrderer.ReadOnly = false;
             }
 
+            // 回目
+            lblReqOrder.Text = string.Format("{0}回目", m_nMaxOrderNo);
+
+            // 請求件名
+            dgv1[4, 0].Value = ReqHead.ReqConstructionName.Trim();
+
+            dgv1[4, 0].ReadOnly = (m_bEdit == true ? (false) : (true));                // 請求件名は編集可能
+            dgv1[2, 0].Value = m_ConstructionCode.ToString();
+
+            // ボディ部の設定
+            SetRequestDispDataBody();
+
+            // 受付回数毎の設定
+            SetRequestDispDataOrder();
+
+            // ヘッダ部の設定
+            SetRequestDispDataHead();
+
+            // フッタ部の設定
+            SetRequestDispDataFooter();
+
+
+            this.dgv1.CellBeginEdit += dgv1_CellBeginEdit;
+            this.dgv1.CellFormatting += this.dgv1_CellFormatting;
+
+            return;
         }
+        #endregion
 
-        /// <summary>
-        /// 入金情報行表示設定
-        /// </summary>
-        /// <param name="m_HtRequestDataDetail"></param>
-        /// <param name="m_HtDepositDataDetail"></param>
-        private void SetDepositInfo ()
+        #region ヘッダ部の設定
+        private void SetRequestDispDataHead()
         {
-            try
+            int tcol = 5;
+            int trow = 6;
+
+            int nAmount = 0;
+            int nPriceTotal = 0;
+            int nTaxTotal = 0;
+
+            while (true)
             {
-                var gridPrice = GetDataGridViewRowObject(RowSectionIndex.DepositInfo, RowKind.DepositPrice);
-                var gridDiff = GetDataGridViewRowObject(RowSectionIndex.DepositInfo, RowKind.DifferencePrice);
+                if (dgv1[2, trow].Value == null)
+                {
+                    break;
+                }
 
-                int cIndex;
-                double totalDeposit = 0;
-                double totalDiff = 0;
+                nAmount = CommonMotions.cnvInt(dgv1[tcol, trow].Value);
+                nPriceTotal += nAmount;
 
-                // 合計値を計算
-                foreach (var detail in m_LstRequestTotalData)
+                nAmount = CommonMotions.cnvInt(dgv1[tcol, trow+1].Value);
+                nTaxTotal += nAmount;
+
+                trow += 2;
+            }
+
+            setAmount(tcol, 2, nPriceTotal + nTaxTotal);
+            setAmount(tcol, 3, nPriceTotal);
+            setAmount(tcol, 4, nTaxTotal);
+
+
+            for (int i = 0; i < m_nMaxOrderNo; i++)
+            {
+                trow = 6 ; 
+                tcol = 8+i;
+                nPriceTotal = 0;
+                nTaxTotal = 0;
+
+                int nState = m_lstOrderState[i];
+
+                RequestHead ReqHead = m_lstRequestHead[i];
+
+                setAmount(tcol, 5, ReqHead.UnpaidAmount);
+
+                // 最終承認済ではない場合は未入金行は編集可
+                if (m_lstOrderState[i] != (int)ApprovalState.End)
                 {
-                    if (m_DicDepositDataDetail.ContainsKey(detail.OrderNo))
+                    dgv1[tcol, 5].ReadOnly = (m_bEdit == true ? (false):(true));    
+                }
+
+                while (true)
+                {
+                    if (dgv1[2, trow].Value == null)
                     {
-                        var depDetail = m_DicDepositDataDetail[detail.OrderNo];
-                        totalDeposit += depDetail.DepositAmount;
-                        totalDiff += depDetail.CarryAmount;
+                        break;
                     }
+
+                    nAmount = CommonMotions.cnvInt(dgv1[tcol, trow].Value);
+                    nPriceTotal += nAmount;
+
+                    nAmount = CommonMotions.cnvInt(dgv1[tcol, trow + 1].Value);
+                    nTaxTotal += nAmount;
+
+                    // 承認が最終承認済ではない場合
+                    if (nState != (int)ApprovalState.End)
+                    {
+                        dgv1[tcol, trow].ReadOnly = (m_bEdit == true ? (false) : (true));
+                        dgv1[tcol, trow + 1].ReadOnly = (m_bEdit == true ? (false) : (true));
+                    }
+
+                    trow += 2;
                 }
 
-                // 工事金額総計を計算
-                double totalOrderDecisionPrice = m_ConstructionLedger.OrdersDecisionPrice;
-                foreach (int constCode in m_LstConstructionLink)
+                setAmount(tcol, 2, nPriceTotal + nTaxTotal);
+                setAmount(tcol, 3, nPriceTotal);
+                setAmount(tcol, 4, nTaxTotal);                
+
+            }
+        }
+        #endregion
+
+        #region ボディ部の設定
+        private void SetRequestDispDataBody()
+        {
+            int trow = 6;
+            int nAmount;
+
+            Dictionary<int, RequestData> dicData = m_lstRequestData[m_nMaxOrderNo - 1];
+            Dictionary<int, List<RequestDataDetail>> dicDetail = m_lstRequestDataDetail[m_nMaxOrderNo - 1];
+
+            List<int> lstKey = new List<int>(dicDetail.Keys);
+            
+            foreach( int nConstructionCode in lstKey )
+            {
+                List<RequestDataDetail> lst = null;
+                if (dicDetail.TryGetValue(nConstructionCode, out lst) == false)
                 {
-                    totalOrderDecisionPrice += m_DicChldConstructionLedger[constCode].OrdersDecisionPrice;
+                    return;
                 }
 
-                // 合計列
-                cIndex = GetColumnIndexNum(ColumnIndex.Total);
-                SetDataGridCellDecimal(gridPrice.Cells[cIndex], totalDeposit);
-                SetDataGridCellDecimal(gridDiff.Cells[cIndex], totalDiff);
+                // 請求データを取得しておく
+                RequestData ReqData = null;
+                if (dicData.TryGetValue(lst[0].MainConstructionCode, out ReqData) == false)
+                {
+                    return;
+                }
 
-                // 残り列
-                cIndex = GetColumnIndexNum(ColumnIndex.Amount);
-                double amountDeposit = totalOrderDecisionPrice * (m_TaxRate + 1) - totalDeposit + totalDiff;
-                SetDataGridCellDecimal(gridPrice.Cells[cIndex], amountDeposit);
-                SetDataGridCellDecimal(gridDiff.Cells[cIndex], -totalDiff);
+                foreach (RequestDataDetail ReqDetail in lst)
+                {
+                    ConstructionBaseInfo inf = null;
+                    if (m_dicConstructionBaseInfo.TryGetValue(ReqDetail.ConstructionCode, out inf) == false)
+                    {
+                        return;
+                    }
+
+                    // 本工事の場合
+                    if (ReqDetail.ConstructionKind == 0)
+                    {
+                        // 工事件名は、請求データから（編集可）
+                        dgv1[4, trow].Value = ReqData.ConstructionName;
+                        dgv1[4, trow].ReadOnly = false;
+                        dgv1[3, trow].Value = "本工事";
+                        dgv1[1, trow].Value = ((int)dgvKind.BodyMainConstruction).ToString();
+                        dgv1[dgv1.ColumnCount - 1, trow].Value = ReqData.Note;
+                        dgv1[dgv1.ColumnCount - 1, trow].ReadOnly = (m_bEdit == true ? (false) : (true));
+
+                    }
+                    else
+                    {
+                        string str;
+
+                        // 工事件名は、退避した工事件名から（編集不可）
+                        m_dicConstructionName.TryGetValue(ReqDetail.ConstructionCode, out str);
+                        dgv1[4, trow].Value = str;
+                        dgv1[3, trow].Value = "増減工事";
+                        dgv1[1, trow].Value = ((int)dgvKind.BodySubConstruction).ToString();
+                    }
+
+                    dgv1[2,trow].Value = ReqDetail.ConstructionCode;
+                    dgv1[6, trow].Value = "請求金額";
+                    dgv1[6, trow + 1].Value = "消費税";
+                    dgv1[1, trow + 1].Value = ((int)dgvKind.Body).ToString();
+
+                    dgv1[6, trow].Style.ForeColor = Color.Black;
+                    dgv1[6, trow+1].Style.ForeColor = Color.Black;
+
+                    if (trow > 13)
+                    {
+                        dgv1.Rows[trow].Visible = true;
+                        dgv1.Rows[trow+1].Visible = true;
+                    }
+
+                    // 税抜受注決定金額
+                    nAmount = CommonMotions.IntRoundDown(inf.OrdersDecisionPrice, 0);
+                    setAmount(5, trow, nAmount);
+
+                    // 消費税
+                    nAmount = CommonMotions.IntRoundDown(inf.OrdersDecisionPriceInTax - inf.OrdersDecisionPrice, 0);
+                    setAmount(5, trow + 1, nAmount);
+
+                    m_nMaxRowNo = trow + 1;
+
+                    trow += 2;
+                }
             }
-            catch (Exception ex)
+
+        }
+        #endregion
+
+        #region フッタ部の設定
+        private void SetRequestDispDataFooter()
+        {
+            int i;
+
+            int trow = 30;
+
+            int nTotalAmount = 0;
+            int nDepositAmount = 0;
+            int nGapAmount = 0;
+
+            for (i = 0; i < m_lstRequestHead.Count; i++)
             {
-                logger.ErrorFormat("システムエラー：{0}：{1}", CommonMotions.GetMethodName(), ex.Message);
+                int tcol = i + 8;
+
+                DepositDataDetail DepDetail = m_lstDepDataDetail[i];
+                RequestHead ReqHead = m_lstRequestHead[i];
+
+                // 空データはスルー
+                if (DepDetail.TargetDate == string.Empty)
+                {
+                    continue;
+                }
+
+                dgv1[tcol, trow].Value = m_lstDepositDate[i].ToString("yyyy/MM/dd");
+
+                nDepositAmount += DepDetail.DepositAmount;
+                nGapAmount += (DepDetail.DepositAmount - ReqHead.RequestTotalAmount);
+
+                setAmount(tcol, trow + 1, DepDetail.DepositAmount);
+                setAmount(tcol, trow + 2, DepDetail.DepositAmount - ReqHead.RequestTotalAmount);
+
+                if (m_lstDepositState[i] == (int)DepositState.Done)
+                {
+                    dgv1[tcol, trow + 3].Value = "確認済";
+                }
             }
+
+            setAmount(7, trow + 1, nDepositAmount);
+            setAmount(7, trow + 2, nGapAmount);
+
+            nTotalAmount = GetTotalRequestAmount();
+            setAmount(dgv1.ColumnCount - 2, trow + 1, nTotalAmount - nDepositAmount);
+            setAmount(dgv1.ColumnCount - 2, trow + 2, -nGapAmount);
+
         }
+        #endregion
 
-        /// <summary>
-        /// 増減工事行表示設定
-        /// </summary>
-        /// <param name="m_LstChldContructionData"></param>
-        /// <param name="m_HtChldConstructionDetail"></param>
-        private void SetChildConstructionInfo()
+        #region 請求金額合計の取得
+        private int GetTotalRequestAmount()
         {
-            try
+            int i;
+            int RequestAmount = 0;
+
+            for (i = 0; i < m_nMaxOrderNo; i++)
             {
-                int cIndex;
+                int nState = m_lstOrderState[i];
 
-                // 増減工事の数分繰り返し
-                foreach (var info in m_LstChldContructionData)
+                if (nState == (int)ApprovalState.End)
                 {
-                    int rowIndex = m_LstChldContructionData.IndexOf(info);
+                    RequestHead ReqHead = m_lstRequestHead[i];
+                    RequestAmount += (ReqHead.RequestAmount + ReqHead.TaxAmount);
+                }
+            }
+            return RequestAmount;
+        }
+        #endregion
 
-                    if (m_ChildConstructionRowCount <= rowIndex)
+        #region 請求回目のデータ設定
+        private void SetRequestDispDataOrder()
+        {
+
+            for (int i = 0; i < m_nMaxOrderNo; i++)
+            {
+                int tcol = i + 8;
+                int trow = 6;
+                int nState = (int)ApprovalState.Entry;
+
+                Dictionary<int, List<RequestDataDetail>> dic = m_lstRequestDataDetail[i];
+
+                RequestHead ReqHead = m_lstRequestHead[i];
+
+                dgv1.Columns[tcol].HeaderCell.Style.ForeColor = Color.Black;
+
+                // 既に１度以上ＤＢに登録されている
+                if (ReqHead.RequestNo > 0)
+                {
+                    nState = GetApprovalState(ReqHead.ReqConstructionCode, ReqHead.OrderNo);
+
+                    // 請求月と承認状態の設定
+                    SetRequestMonthAndApprovalState(ReqHead.OrderNo, ReqHead.RequestMonth, nState);
+
+                }
+                else
+                {
+                    // 請求月と承認状態の設定
+                    SetRequestMonthAndApprovalState(i+1, 0, nState);
+                }
+
+                m_lstOrderState.Add(nState);
+
+                while(true){
+                    if (dgv1[2, trow].Value == null)
                     {
-                        // 増減工事行が足りない場合は行を追加
-                        AddChildConstructionInfoRow(rowIndex);
+                        break;
                     }
 
-                    var gridRowBillPrice = GetDataGridViewRowObject(RowSectionIndex.ChildConstruction, RowKind.BillPrice, rowIndex);
-                    var gridRowTaxPrice = GetDataGridViewRowObject(RowSectionIndex.ChildConstruction, RowKind.TaxPrice, rowIndex);
+                    string str = dgv1[2, trow].Value.ToString();
 
-                    // 各行の文字色を設定
-                    gridRowBillPrice.DefaultCellStyle.ForeColor = Color.Black;
-                    gridRowTaxPrice.DefaultCellStyle.ForeColor = Color.Black;
+                    int key = int.Parse(str);
 
-                    // 工事番号
-                    cIndex = GetColumnIndexNum(ColumnIndex.ConstructionCode);
-                    gridRowBillPrice.Cells[cIndex].Value = info.ConstructionCode;
-                    gridRowTaxPrice.Cells[cIndex].Value = info.ConstructionCode;
+                    List<RequestDataDetail> lst = null;
 
-                    if (m_DicChldConstructionDetail.ContainsKey(info.ConstructionCode))
+                    dic.TryGetValue(key, out lst);
+
+                    for (int j = 0; j < lst.Count; j++)
                     {
-                        var detail = m_DicChldConstructionDetail[info.ConstructionCode] as Dictionary<int,string>;
+                        setAmount(tcol, trow, lst[j].RequestAmount);
+                        setAmount(tcol, trow + 1, lst[j].TaxAmount);
 
-                        // 工事名
-                        if (detail.ContainsKey((int)ConstructionBaseInfoDetail.DetailDataNo.ConstructionName))
+                        if (nState == (int)ApprovalState.Entry)
                         {
-                            cIndex = GetColumnIndexNum(ColumnIndex.ConstructionName);
-                            gridRowBillPrice.Cells[cIndex].Value = detail[(int)ConstructionBaseInfoDetail.DetailDataNo.ConstructionName] as string;
+                            dgv1[tcol, trow].ReadOnly = (m_bEdit == true ? (false):(true));
+                            dgv1[tcol, trow + 1].ReadOnly = (m_bEdit == true ? (false) : (true));
                         }
-
+                        trow += 2;
                     }
 
-                    // 工事金額
-                    cIndex = GetColumnIndexNum(ColumnIndex.ConstructionPrice);
-                    double ordersDecisionPrice = 0;
-                    double taxPrice = 0;
-                    if (m_DicChldConstructionLedger.ContainsKey(info.ConstructionCode))
-                    {
-                        var ledger = m_DicChldConstructionLedger[info.ConstructionCode] as ConstructionLedger;
-                        ordersDecisionPrice = ledger.OrdersDecisionPrice;
-                        taxPrice = Math.Truncate(ledger.OrdersDecisionPrice * m_TaxRate);
-                    }
-                    SetDataGridCellDecimal(gridRowBillPrice.Cells[cIndex], ordersDecisionPrice);
-                    SetDataGridCellDecimal(gridRowTaxPrice.Cells[cIndex], taxPrice);
-
                 }
             }
-            catch (Exception ex)
+        }
+        #endregion
+
+        #region 請求月および申請状況の設定
+        private void SetRequestMonthAndApprovalState(int nOrderNo, int nRequestMonth, int nState)
+        {
+            string[] StateString = new string[] { "入力中", "申請中", "承認中", "保留", "不承認", "承認済" };
+
+            int tcol = nOrderNo + 7;
+
+            if (nState == (int)ApprovalState.Entry)
             {
-                logger.ErrorFormat("システムエラー：{0}：{1}", CommonMotions.GetMethodName(), ex.Message);
+                dgv1[tcol, 0].Value = StateString[nState];
+                dgv1[tcol, 0].Style.Alignment = DataGridViewContentAlignment.MiddleCenter;
+
+                dgv1[tcol, 1].Value = "";
             }
+            else
+            {
+                if (nRequestMonth > 0)
+                {
+                    int yyyy = CommonMotions.cnvTruncate((double)nRequestMonth / 100);
+                    int mm = nRequestMonth % 100;
+                    dgv1[tcol, 0].Value = string.Format("{0}/{1}", yyyy, mm);
+                    dgv1[tcol, 0].Style.Alignment = DataGridViewContentAlignment.MiddleCenter;
+                }
+
+                dgv1[tcol, 1].Value = StateString[nState];
+                dgv1[tcol, 1].Style.Alignment = DataGridViewContentAlignment.MiddleCenter;
+            }
         }
+        #endregion
 
-        /// <summary>
-        /// 本工事セクションおよび増減工事セクションの、すべての自動計算カラムを計算する
-        /// </summary>
-        private void SetAutoCalcRow()
+        #region 請求月コンボの設定
+        private void SetRequestMonth()
         {
-            try
+            int yyyymm;
+            int nState;
+            int now_yyyymm;
+
+            int key;
+            string val;
+            KeyValuePair<int, string> keyval;
+            RequestHead ReqHead;
+
+            yyyymm = 0;
+            now_yyyymm = 0;
+
+            for (int i = m_nMaxOrderNo-1; i>=0; i--)
             {
-                // 本工事セクション
-                if (m_DicRequestDataDetail.ContainsKey(m_ConstructionCode))
+                // 請求ヘッダの取得
+                ReqHead = m_lstRequestHead[i];
+
+                // 受付状態を取得
+                nState = m_lstOrderState[i];
+
+                // 最終承認済以外は対象外
+                if(nState != (int)ApprovalState.End){
+                    continue;
+                }
+
+                if (yyyymm < ReqHead.RequestMonth)
                 {
-                    foreach (RowKind kind in s_HtRowSections[RowSectionIndex.OriginalConstruction])
-                    {
-                        var gridRow = GetDataGridViewRowObject(RowSectionIndex.OriginalConstruction, kind);
-                        SetAutoCalcCell(gridRow);
+                    yyyymm = ReqHead.RequestMonth;
+                    break;
+                }
+            }
 
-                    }
+            DateTime dt = DateTime.Today;
+            List<KeyValuePair<int, string>> lst = new List<KeyValuePair<int, string>>();
+
+            // 先月から3カ月後まで
+            for (int i = -1; i < 4; i++)
+            {
+                DateTime wk = dt.AddMonths(i);
+
+                key = int.Parse(wk.ToString("yyyyMM"));
+
+                if(i==0)
+                {
+                    now_yyyymm = key;
                 }
 
-                // 増減工事セクション
-                foreach (int constCode in m_LstConstructionLink)
+                // 最終承認済の請求月以上の年月だけ追加
+                if (key >= yyyymm)
                 {
-                    foreach (RowKind kind in s_HtRowSections[RowSectionIndex.ChildConstruction])
-                    {
-                        var gridRow = GetDataGridViewRowObject(RowSectionIndex.ChildConstruction, kind, m_LstConstructionLink.IndexOf(constCode));
-                        SetAutoCalcCell(gridRow);
-                    }
+                    val = wk.ToString("yyyy/MM");
+
+                    keyval = new KeyValuePair<int, string>(key, val);
+
+                    lst.Add(keyval);
                 }
             }
-            catch (Exception ex)
+
+            cbReqMonth.ValueMember = "Key";
+            cbReqMonth.DisplayMember = "Value";
+
+            // コンボボックス初期表示
+            ComboBoxAction.InitDataSetCombBox(cbReqMonth, lst, false);
+
+            // 最新の請求ヘッダ、受付状態の取得
+            ReqHead = m_lstRequestHead[m_nMaxOrderNo-1];
+            nState = m_lstOrderState[m_nMaxOrderNo-1];
+
+            if (ReqHead.RequestNo != 0)
             {
-                logger.ErrorFormat("システムエラー：{0}：{1}", CommonMotions.GetMethodName(), ex.Message);
+                cbReqMonth.SelectedValue = ReqHead.RequestMonth;
             }
+            else
+            {
+                cbReqMonth.SelectedValue = now_yyyymm;
+            }
+
+            // 直近受付が最終承認済の場合
+            if (nState == (int)ApprovalState.End)
+            {
+                // 請求年月は変更不可
+                cbReqMonth.Enabled = false;
+            }
+
         }
+        #endregion
 
-        /// <summary>
-        /// 指定行の自動計算カラムを計算する
-        /// </summary>
-        /// <param name="row"></param>
-        private void SetAutoCalcCell(DataGridViewRow row)
+        #region 申請状態の取得
+        private int GetApprovalState(int nConstructionCode, int nOrderNo)
         {
-            try
+            int nState = (int)ApprovalState.Entry;
+
+            List<ProcessApproval> lst = null;
+
+            if (m_dicProcessApproval.TryGetValue(nOrderNo, out lst) == false)
             {
-                var sectionIndex = (RowSectionIndex)row.Cells[GetColumnIndexNum(ColumnIndex.SectionIndex)].Value;
-                var rowKind = (RowKind)row.Cells[GetColumnIndexNum(ColumnIndex.RowKind)].Value;
-                var constCode = (int)row.Cells[GetColumnIndexNum(ColumnIndex.ConstructionCode)].Value;
+                return nState;
+            }
 
-                if (m_DicRequestDataDetail.ContainsKey(constCode))
+            for (int i = 0; i < lst.Count; i++)
+            {
+                ProcessApproval pap = lst[i];
+
+                if (pap.SeqNo == 1)
                 {
-                    double total = 0;
-                    foreach (var orderNo in m_DicRequestDataDetail[constCode].Keys)
-                    {
-                        int colIndex = GetColumnIndexNum(ColumnIndex.RequestInfo, orderNo);
-                        switch (rowKind)
-                        {
-                            case RowKind.BillPrice:
-                                m_DicRequestDataDetail[constCode][orderNo].BillPrice = Convert.ToInt32(row.Cells[colIndex].Value);
-                                total += m_DicRequestDataDetail[constCode][orderNo].BillPrice;
-                                break;
-                            case RowKind.TaxPrice:
-                                m_DicRequestDataDetail[constCode][orderNo].TaxPrice = Convert.ToInt32(row.Cells[colIndex].Value);
-                                total += m_DicRequestDataDetail[constCode][orderNo].TaxPrice;
-                                break;
-                            case RowKind.AmountPrice:
-                                m_DicRequestDataDetail[constCode][orderNo].AmountBlance = Convert.ToInt32(row.Cells[colIndex].Value);
-                                total += m_DicRequestDataDetail[constCode][orderNo].AmountBlance;
-                                break;
-                            default:
-                                break;
-                        }
+                    if( nState < (int)ApprovalState.Apply){
+                        nState = (int)ApprovalState.Apply;  
                     }
+                    continue;
+                }
 
-                    // 合計列
-                    int totalColIndex = GetColumnIndexNum(ColumnIndex.Total);
-                    SetDataGridCellDecimal(row.Cells[totalColIndex], total);
+                ApprovalMaster apm = new ApprovalMaster();
+                m_dicApprovalMaster.TryGetValue(pap.PersonCode, out apm);
 
-                    // 残り列
-                    int amountColIndex = GetColumnIndexNum(ColumnIndex.Amount);
-                    if (rowKind != RowKind.AmountPrice)
+                // 保留の場合
+                if (pap.ApprovalStatus == 1)
+                {
+                    if (nState < (int)ApprovalState.Pending)
                     {
-                        // 未入金分以外
-                        // 工事金額を取得
-                        int constPriceColIndex = GetColumnIndexNum(ColumnIndex.ConstructionPrice);
-                        double constPrice = Convert.ToDouble(row.Cells[constPriceColIndex].Value ?? 0);
+                        nState = (int)ApprovalState.Pending;
+                    }
+                    continue;
+                }
 
-                        // 残り列に残り金額をセット
-                        SetDataGridCellDecimal(row.Cells[amountColIndex], constPrice - total);
+                // 承認の場合
+                if (pap.ApprovalStatus == 2)
+                {
+                    // 最終権限者の場合
+                    if (apm.ApprovalAuthority == 1)
+                    {
+                        // 承認済確定
+                        nState = (int)ApprovalState.End;
+
+                        // 最終承認者の承認があれば他は見なくてよい。
+                        break;
+
                     }
                     else
                     {
-                        var gridRowDiff = GetDataGridViewRowObject(RowSectionIndex.DepositInfo, RowKind.DifferencePrice);
-                        double diffPrice = Convert.ToDouble(gridRowDiff.Cells[totalColIndex].Value ?? 0);
+                        if (nState < (int)ApprovalState.Approval)
+                        {
+                            nState = (int)ApprovalState.Approval;
+                        }
+                    }
+                    continue;
+                }
 
-                        // 残り列に未入金残り金額をセット
-                        SetDataGridCellDecimal(row.Cells[amountColIndex], diffPrice - total);
-
+                // 非承認の場合
+                if (pap.ApprovalStatus == 3)
+                {
+                    if (nState < (int)ApprovalState.Dismissal)
+                    {
+                        nState = (int)ApprovalState.Dismissal;
                     }
+                    continue;
                 }
+
             }
-            catch (Exception ex)
+            return nState;
+        }
+        #endregion
+
+        #region [回数追加]ボタンの有効無効判定
+        private bool GetbtnAddEnabled()
+        {
+            // 編集可能でない場合
+            if (m_bEdit == false)
             {
-                logger.ErrorFormat("システムエラー：{0}：{1}", CommonMotions.GetMethodName(), ex.Message);
+                return false;
             }
+
+            // 入金が完了している場合
+            if (m_ConstructionLedger.ComplateFlg == 1)
+            {
+                return false;
+            }
+
+            // 直近の状態が承認完了以外の場合
+            if (m_lstOrderState[m_nMaxOrderNo - 1] != (int)ApprovalState.End)
+            {
+                return false;
+            }
+
+            // 分割払いの場合
+            if (m_BaseConstructionBaseInfo.BillingSplitFlg == 1)
+            {
+
+                return true;
+            }
+            
+            return false;
         }
+        #endregion
 
-        /// <summary>
-        /// 合計セクション表示設定
-        /// </summary>
-        private void SetTotalInfo()
+        #region 数値編集可能セル判定
+        private bool isEditNumCell(int tcol, int trow)
         {
-            try
+
+            bool ret = false;
+
+            // 編集回目であることかつ未入金分～最大工事の消費税まで
+            if ((tcol == m_nMaxOrderNo + 7)&&((trow >= 6 )&&( trow <=  m_nMaxRowNo )))
             {
-                // 工事金額列
-                SetTotalInfoColumn(ColumnIndex.ConstructionPrice);
+                return true;
+            }
+            return ret;
+        }
+        #endregion
 
-                // 請求回数分繰り返し
-                foreach (var record in m_LstRequestTotalData)
+        #region 編集タイプの取得
+        private int GetEditType(int tcol, int trow)
+        {
+            int ret = (int)EditType.NotEdit;
+
+            // 列チェック（工事名と対象回目以外、コメント以外の列は編集対象外
+            if ((tcol != 4)&&( tcol != m_nMaxOrderNo + 7)&&(tcol != dgv1.ColumnCount-1)) 
+            {
+                return ret;
+            }
+
+            // 請求件名は対象
+            if ((tcol == 4) && (trow == 0))
+            {
+                return (int)EditType.Name;
+            }
+
+            // 列が対象回目かつ行が未入金分～最大行まで
+            if(( tcol == m_nMaxOrderNo + 7)&&(( trow >= 5 )&&( trow <= m_nMaxRowNo)))
+            {
+                return (int)EditType.Amount;
+            }
+
+            if(( tcol == 4 )||(tcol == dgv1.ColumnCount-1))
+            {
+                if (dgv1[3, trow].Value == null)
                 {
-                    // 請求明細列
-                    SetTotalInfoColumn(ColumnIndex.RequestInfo, m_LstRequestTotalData.IndexOf(record) + 1);
+                    return ret;
                 }
 
-                SetTotalSectionInfo();
+                if (int.Parse(dgv1[1, trow].Value.ToString()) == (int)dgvKind.BodyMainConstruction)
+                {
+                    return (int)EditType.Name;
+                }
+                else
+                {
+                    return ret;
+                }
             }
-            catch (Exception ex)
-            {
-                logger.ErrorFormat("システムエラー：{0}：{1}", CommonMotions.GetMethodName(), ex.Message);
-            }
+
+            return ret;
         }
+        #endregion
 
+
+        #endregion
+
+        #region 請求回数追加関連
+
+        #region 請求回数追加
         /// <summary>
-        /// 合計セクションの合計および残り列表示設定
+        /// 請求回数追加
         /// </summary>
-        private void SetTotalSectionInfo()
+        private void AddRequest()
         {
+            int tcol = 0;
+
+            if (m_nMaxOrderNo == 15)
+            {
+                return;
+            }
+
             try
             {
-                double totalBillPrice = 0;
-                double totalNonTaxedPrice = 0;
-                double totalTaxPrice = 0;
-                double totalAmount = 0;
+                tcol = m_nMaxOrderNo + 7;
 
-                var gridRowBillPrice = GetDataGridViewRowObject(RowSectionIndex.Total, RowKind.BillPrice);
-                var gridRowNonTaxedPrice = GetDataGridViewRowObject(RowSectionIndex.Total, RowKind.NonTaxedPrice);
-                var gridRowTaxPrice = GetDataGridViewRowObject(RowSectionIndex.Total, RowKind.TaxPrice);
-                var gridRowAmount = GetDataGridViewRowObject(RowSectionIndex.Total, RowKind.AmountPrice);
+                for (int i = 5; i <= m_nMaxRowNo; i++)
+                {
+                    dgv1[tcol, i].ReadOnly = true;
+                }
 
-                int cIndex;
+                //// 請求回数を追加
+                AddRequestOrder();
 
-                // 請求回数分繰り返し
-                foreach (var record in m_LstRequestTotalData)
+                tcol = m_nMaxOrderNo + 7;
+
+                dgv1.Columns[tcol].Visible = true;
+
+                for (int i = 5; i <= m_nMaxRowNo; i++)
                 {
-                    // 合計計算
-                    cIndex = GetColumnIndexNum(ColumnIndex.RequestInfo, m_LstRequestTotalData.IndexOf(record) + 1);
-                    totalBillPrice += Convert.ToDouble(gridRowBillPrice.Cells[cIndex].Value);
-                    totalNonTaxedPrice += Convert.ToDouble(gridRowNonTaxedPrice.Cells[cIndex].Value);
-                    totalTaxPrice += Convert.ToDouble(gridRowTaxPrice.Cells[cIndex].Value);
-                    totalAmount += Convert.ToDouble(gridRowAmount.Cells[cIndex].Value);
+                    dgv1[tcol, i].ReadOnly = (m_bEdit == true ? (false) : (true));
                 }
 
-                // 合計列
-                cIndex = GetColumnIndexNum(ColumnIndex.Total);
-                SetDataGridCellDecimal(gridRowBillPrice.Cells[cIndex], totalBillPrice);
-                SetDataGridCellDecimal(gridRowNonTaxedPrice.Cells[cIndex], totalNonTaxedPrice);
-                SetDataGridCellDecimal(gridRowTaxPrice.Cells[cIndex], totalTaxPrice);
-                SetDataGridCellDecimal(gridRowAmount.Cells[cIndex], totalAmount);
+                m_lstOrderState.Add((int)ApprovalState.Entry);
+                dgv1[tcol, 0].Style.Alignment = DataGridViewContentAlignment.MiddleCenter;
+                dgv1[tcol, 0].Value = "入力中";
+                cbReqMonth.Enabled = (m_bEdit == true ? (true) : (false));
+                txtOrderer.ReadOnly = (m_bEdit == true ? (false) : (true));
 
-                // 残り列
-                int constPriceIndex = GetColumnIndexNum(ColumnIndex.ConstructionPrice);
-                cIndex = GetColumnIndexNum(ColumnIndex.Amount);
-                SetDataGridCellDecimal(gridRowNonTaxedPrice.Cells[cIndex], Convert.ToDouble(gridRowNonTaxedPrice.Cells[constPriceIndex].Value) - totalNonTaxedPrice);
-                SetDataGridCellDecimal(gridRowTaxPrice.Cells[cIndex], Convert.ToDouble(gridRowTaxPrice.Cells[constPriceIndex].Value) - totalTaxPrice);
+                lblReqOrder.Text = string.Format("{0}回目", m_nMaxOrderNo);
 
-                double amountBalance = Convert.ToDouble(GetDataGridViewRowObject(RowSectionIndex.OriginalConstruction, RowKind.AmountPrice).Cells[cIndex].Value);
-                SetDataGridCellDecimal(gridRowAmount.Cells[cIndex], amountBalance);
-
+                dgv1.Refresh();
             }
             catch (Exception ex)
             {
@@ -991,525 +2004,775 @@
                 logger.ErrorFormat("システムエラー：{0}：{1}", CommonMotions.GetMethodName(), ex.Message);
             }
         }
+        #endregion
 
-        /// <summary>
-        /// 合計行列表示設定
-        /// </summary>
-        /// <param name="colIndex"></param>
-        /// <param name="count"></param>
-        private void SetTotalInfoColumn(ColumnIndex colIndex, int count = 1)
+        #region 請求回の追加
+        private void AddRequestOrder()
         {
-            // カラムインデックス取得
-            int cIndex = GetColumnIndexNum(colIndex, count);
+            int nOldMaxOrderNo = m_nMaxOrderNo;
 
-            SetTotalInfoColumn(cIndex);
+            // 請求回数を加算
+            m_nMaxOrderNo++;
+
+            RequestHead ReqHeadFrom = m_lstRequestHead[nOldMaxOrderNo - 1];
+
+            RequestHead ReqHeadTo = new RequestHead();
+
+            ReqHeadTo.ReqConstructionCode = m_ConstructionCode;           // 請求工事番号
+
+            // 請求Noは登録時に採番
+
+            // 受付番号は最大受付番号に準拠                                      
+            ReqHeadTo.OrderNo = m_nMaxOrderNo;
+
+            // 請求年月は登録時に決定（初期値）      
+
+            // 発注者区分、発注者コード、発注者名、工事件名は引き継ぐ
+            ReqHeadTo.OrderersDivision = m_BaseConstructionBaseInfo.OrderersDivision;   // 発注者区分   
+            ReqHeadTo.OrderersCode = m_BaseConstructionBaseInfo.OrderersCode;           // 発注者コード
+            ReqHeadTo.OrderersName = ReqHeadFrom.OrderersName;                          // 発注者名
+            ReqHeadTo.ReqConstructionName = ReqHeadFrom.ReqConstructionName;            // 工事件名
+
+            // 請求金額関係は全て0（初期値）
+            // 備考は初期値
+            // 割当済フラグも初期値
+            // 請求書Noも初期値
+
+            // 請求ヘッダリストに追加
+            m_lstRequestHead.Add(ReqHeadTo);
+
+            Dictionary<int, RequestData> dicDataForm = m_lstRequestData[nOldMaxOrderNo - 1];
+            Dictionary<int, RequestData> dicDataTo = new Dictionary<int, RequestData>();
+            CopyRequestDataDic(dicDataForm, ref dicDataTo);
+
+            m_lstRequestData.Add(dicDataTo);
+
+            Dictionary<int, List<RequestDataDetail>> dicDetailFrom = m_lstRequestDataDetail[nOldMaxOrderNo - 1];
+            Dictionary<int, List<RequestDataDetail>> dicDetailTo = new Dictionary<int, List<RequestDataDetail>>();
+            CopyRequestDetailDic(dicDetailFrom, ref dicDetailTo);
+
+            m_lstRequestDataDetail.Add(dicDetailTo);
+
+            return;
         }
+        #endregion
 
-        /// <summary>
-        /// 合計行列表示設定
-        /// </summary>
-        /// <param name="cIndex"></param>
-        private void SetTotalInfoColumn(int cIndex)
-        { 
-            try
+        #region 請求データの複写
+        private void CopyRequestDataDic(Dictionary<int, RequestData> dicDataForm, ref Dictionary<int, RequestData> dicDataTo)
+        {
+            List<int> lstKey = new List<int>(dicDataForm.Keys);
+
+            foreach (int nMainConstructionCode in lstKey)
             {
-                // DataGridViewRowのオブジェクトを取得
-                var gridRowBillPrice = GetDataGridViewRowObject(RowSectionIndex.Total, RowKind.BillPrice);
-                var gridRowNonTaxed = GetDataGridViewRowObject(RowSectionIndex.Total, RowKind.NonTaxedPrice);
-                var gridRowTaxPrice = GetDataGridViewRowObject(RowSectionIndex.Total, RowKind.TaxPrice);
+                RequestData ReqDataFrom = null;
 
-                // 税抜き価格と消費税額を計算
-                double nonTaxedPrice = Convert.ToDouble(GetDataGridViewRowObject(RowSectionIndex.OriginalConstruction, RowKind.BillPrice).Cells[cIndex].Value);
-                double taxPrice = Convert.ToDouble(GetDataGridViewRowObject(RowSectionIndex.OriginalConstruction, RowKind.TaxPrice).Cells[cIndex].Value);
-                for (int childRow = 0; childRow < m_ChildConstructionRowCount; childRow++)
+                if (dicDataForm.TryGetValue(nMainConstructionCode, out ReqDataFrom) == true)
                 {
-                    nonTaxedPrice += Convert.ToDouble(GetDataGridViewRowObject(RowSectionIndex.ChildConstruction, RowKind.BillPrice, childRow).Cells[cIndex].Value ?? 0.0);
-                    taxPrice += Convert.ToDouble(GetDataGridViewRowObject(RowSectionIndex.ChildConstruction, RowKind.TaxPrice, childRow).Cells[cIndex].Value ?? 0.0);
+                    RequestData ReqDataTo = new RequestData();
+
+                    // 請求Noは登録時に採番
+
+                    // 本工事番号、工事件名、請負金額は引き継ぐ
+                    ReqDataTo.MainConstructionCode = ReqDataFrom.MainConstructionCode;
+                    ReqDataTo.ConstructionName = ReqDataFrom.ConstructionName;
+                    ReqDataTo.ContractAmount = ReqDataFrom.ContractAmount;
+
+                    dicDataTo.Add(nMainConstructionCode, ReqDataTo);
+
                 }
+            }
+            return;
+        }
+        #endregion
 
-                // 行に表示設定
-                SetDataGridCellDecimal(gridRowNonTaxed.Cells[cIndex], nonTaxedPrice);
-                SetDataGridCellDecimal(gridRowTaxPrice.Cells[cIndex], taxPrice);
-                SetDataGridCellDecimal(gridRowBillPrice.Cells[cIndex], nonTaxedPrice + taxPrice);
+        #region 請求データ明細の複写
+        private void CopyRequestDetailDic(Dictionary<int, List<RequestDataDetail>> dicDetailFrom, ref Dictionary<int, List<RequestDataDetail>> dicDetailTo)
+        {
 
-                // 処理中の列が工事金額列以外であれば以下の処理
-                if (GetColumnIndexNum(ColumnIndex.ConstructionPrice) != cIndex)
+            List<int> lstKey = new List<int>(dicDetailFrom.Keys);
+
+            foreach (int nMainConstructionCode in lstKey)
+            {
+                List<RequestDataDetail> lstDetailFrom = null;
+
+                if (dicDetailFrom.TryGetValue(nMainConstructionCode, out lstDetailFrom) == true)
                 {
-                    // 未入金分
-                    var gridRowAmount = GetDataGridViewRowObject(RowSectionIndex.Total, RowKind.AmountPrice);
+                    List<RequestDataDetail> lstDetailTo = new List<RequestDataDetail>();
 
-                    SetDataGridCellDecimal(gridRowAmount.Cells[cIndex], Convert.ToDouble(GetDataGridViewRowObject(RowSectionIndex.OriginalConstruction, RowKind.AmountPrice).Cells[cIndex].Value ?? 0.0));
-                    gridRowAmount.Cells[cIndex].Value = Convert.ToDouble(GetDataGridViewRowObject(RowSectionIndex.OriginalConstruction, RowKind.AmountPrice).Cells[cIndex].Value ?? 0.0);
+                    foreach (RequestDataDetail ReqDetailFrom in lstDetailFrom)
+                    {
+                        RequestDataDetail ReqDetailTo = new RequestDataDetail();
 
-                    // ヘッダセクションの請求書金額
-                    var gridRowBillTotalPrice = GetDataGridViewRowObject(RowSectionIndex.Header, RowKind.RequestSheetPrice);
-                    SetDataGridCellDecimal(gridRowBillTotalPrice.Cells[cIndex], nonTaxedPrice + taxPrice);
+                        // 請求Noは登録時に採番
 
+                        // 本工事番号、工事番号、工事区分は引き継ぐ
+                        ReqDetailTo.MainConstructionCode = ReqDetailFrom.MainConstructionCode;
+                        ReqDetailTo.ConstructionCode = ReqDetailFrom.ConstructionCode;
+                        ReqDetailTo.ConstructionKind = ReqDetailFrom.ConstructionKind;
+
+                        lstDetailTo.Add(ReqDetailTo);
+                    }
+
+                    dicDetailTo.Add(nMainConstructionCode, lstDetailTo);
                 }
-
             }
-            catch (Exception ex)
-            {
-                logger.ErrorFormat("システムエラー：{0}：{1}", CommonMotions.GetMethodName(), ex.Message);
-            }
         }
-        
-        /// <summary>
-        /// 承認状態を確認する
-        /// </summary>
-        /// <param name="lstProcApproval"></param>
-        /// <param name="dicApprovalMaster"></param>
-        /// <returns></returns>
-        private RequestApprovalStatus CheckApprovalStatus(List<ProcessApproval> lstProcApproval, Dictionary<int,ApprovalMaster> dicApprovalMaster)
+        #endregion
+
+        #endregion
+
+        #region データ登録関連
+
+        #region データ登録
+        public bool AcceptData()
         {
-            // 「入力中」で初期化する
-            RequestApprovalStatus stat = RequestApprovalStatus.NowInput;
+            SetDispData();
 
-            try
+            SaveDispData();
+
+            m_bDirty = false;
+
+            return true;
+        }
+        #endregion
+
+        #region 表示データをオブジェクトに反映
+        private void SetDispData()
+        {
+            // 請求ヘッダ反映
+            SetRequestHead();
+
+            // 請求データ、請求データ明細の反映
+            SetRequestData();
+
+            return;
+        }
+        #endregion
+
+        #region 請求ヘッダをオブジェクトに反映
+        private void SetRequestHead()
+        {
+            int tcol = m_nMaxOrderNo + 7;
+
+            // 請求ヘッダ取得
+            RequestHead ReqHead = m_lstRequestHead[m_nMaxOrderNo - 1];
+
+            ReqHead.ReqConstructionCode = m_ConstructionCode;                               // 請求工事番号
+            ReqHead.OrderNo = m_nMaxOrderNo;                                                // 受付番号
+            ReqHead.OrderersName = txtOrderer.Text.Trim();                                  // 請求先名
+            ReqHead.RequestMonth = int.Parse(cbReqMonth.SelectedValue.ToString());          // 請求月
+            ReqHead.ReqConstructionName = dgv1[4, 0].Value.ToString();                      // 請求件名
+
+            ReqHead.RequestTotalAmount = CommonMotions.cnvInt(dgv1[tcol, 2].Value);         // 請求金額合計
+            ReqHead.RequestAmount = CommonMotions.cnvInt(dgv1[tcol, 3].Value);              // 請求金額
+            ReqHead.TaxAmount = CommonMotions.cnvInt(dgv1[tcol, 4].Value);                  // 消費税
+            ReqHead.UnpaidAmount = CommonMotions.cnvInt(dgv1[tcol, 5].Value);               // 未入金
+
+            return;
+        }
+        #endregion
+
+        #region 請求データをオブジェクトに反映
+        private void SetRequestData()
+        {
+
+            Dictionary<int, RequestData> dicData = m_lstRequestData[m_nMaxOrderNo - 1];
+            Dictionary<int, List<RequestDataDetail>> dicDetail = m_lstRequestDataDetail[m_nMaxOrderNo - 1];
+
+            int tcol = m_nMaxOrderNo + 7;
+            int trow = 6;
+            int nIndex = 0;
+            int nMainConstructionCode;
+
+            RequestData ReqData = null ;
+            List<RequestDataDetail> lstDetail = null;
+          
+            int[] nAmounts = new int[] { 0,0,0,0,0,0,0 } ;
+
+            int nRequestTotal = 0;
+            int nTaxTotal = 0;
+            int nContractAmount = 0;
+            int nPaidAmount =0;
+
+            while (true)
             {
-                // 承認データをすべて参照する
-                foreach (var procApproval in lstProcApproval)
+                if(dgv1[2,trow].Value == null)
                 {
+                    break;
+                }
 
-                    if ((procApproval.ApprovalStatus == (int)CommonDefine.ApprovalStatus.Approval)
-                         && dicApprovalMaster.ContainsKey(procApproval.PersonCode)
-                         && dicApprovalMaster[procApproval.PersonCode].ApprovalAuthority == 1)
+                int nKind = int.Parse(dgv1[1,trow].Value.ToString());
+
+                // 区分がボディ（本工事）の場合
+                if (nKind == (int)dgvKind.BodyMainConstruction)
+                {
+                    // 前本工事がある場合
+                    if (ReqData != null)
                     {
-                        // 承認ステータスが「承認」で承認者が最終決裁者の場合、「承認済み」とし、ループを離脱する
-                        stat = RequestApprovalStatus.Approval;
-                        break;
+                        // 請求データの請求金額０～６と消費税は最後に設定
+                        ReqData.RequestAmount0 = nAmounts[0];                                       // 請求金額０（本工事）
+                        ReqData.RequestAmount1 = nAmounts[1];                                       // 請求金額１
+                        ReqData.RequestAmount2 = nAmounts[2];                                       // 請求金額２
+                        ReqData.RequestAmount3 = nAmounts[3];                                       // 請求金額３
+                        ReqData.RequestAmount4 = nAmounts[4];                                       // 請求金額４
+                        ReqData.RequestAmount5 = nAmounts[5];                                       // 請求金額５
+                        ReqData.RequestAmount6 = nAmounts[6];                                       // 請求金額６
+                        ReqData.TaxAmount = nTaxTotal;                                              // 消費税
+
+                        ReqData.UnclaimedAmount = nContractAmount - (nPaidAmount + nRequestTotal);    // 請求金額残
+
+                        nAmounts = new int[] { 0, 0, 0, 0, 0, 0, 0 };
+                        nRequestTotal = 0;
+                        nTaxTotal = 0;
                     }
-                    else if (procApproval.ApprovalStatus == (int)CommonDefine.ApprovalStatus.NotApproval)
+
+                    nMainConstructionCode = int.Parse(dgv1[2,trow].Value.ToString());
+
+                    dicData.TryGetValue(nMainConstructionCode, out ReqData);
+                    dicDetail.TryGetValue(nMainConstructionCode, out lstDetail);
+
+                    ReqData.ConstructionName = dgv1[4, trow].Value.ToString().Trim();           // 工事件名
+
+                    nContractAmount = GetContractAmount(nMainConstructionCode);
+                    nPaidAmount = GetPaidAmount(m_nMaxOrderNo, nMainConstructionCode);
+
+                    ReqData.ContractAmount = nContractAmount;                                   // 請負金額
+                    ReqData.PaidAmount = nPaidAmount;                                           // 請求済金額
+
+                    ReqData.Note = dgv1[dgv1.ColumnCount - 1, trow].Value.ToString();           // 備考
+
+                    // 先頭の本工事の場合
+                    if (trow == 6)
                     {
-                        // 不承認
-                        stat = RequestApprovalStatus.NotApproval;
+                        // 最初の本工事に未入金分は載せる
+                        ReqData.UnpaidAmount = CommonMotions.cnvInt(dgv1[tcol, 5].Value);       // 未入金
                     }
-                    else if ((procApproval.ApprovalStatus == (int)CommonDefine.ApprovalStatus.Pending)
-                        && (stat > RequestApprovalStatus.Pending))
+
+                    nIndex = 0;
+                }
+
+                RequestDataDetail ReqDetail = lstDetail[nIndex];
+
+                int nAmount = CommonMotions.cnvInt(dgv1[tcol, trow].Value);
+                int nTax = CommonMotions.cnvInt(dgv1[tcol, trow + 1].Value);
+
+                // 増減工事が6個未満(
+                if (lstDetail.Count < 8)
+                {
+                    nAmounts[nIndex] = nAmount; 
+                }
+                else
+                {
+                    if (nIndex > 0)
                     {
-                        // 保留
-                        stat = RequestApprovalStatus.Pending;
+                        nAmounts[1] += nAmount;
                     }
-                    else if ((procApproval.ApprovalStatus == (int)CommonDefine.ApprovalStatus.Approval)
-                        && (stat > RequestApprovalStatus.NowApproval))
+                    else
                     {
-                        // 承認中
-                        stat = RequestApprovalStatus.NowApproval;
+                        nAmounts[0] = nAmount;
                     }
-                    else if ((procApproval.ApprovalStatus == (int)CommonDefine.ApprovalStatus.Petition)
-                        && (stat > RequestApprovalStatus.Petition))
-                    {
-                        // 申請中
-                        stat = RequestApprovalStatus.Petition;
-                    }
                 }
+
+                //////////////////////
+                // 請求データ明細
+                //////////////////////
+
+                ReqDetail.RequestAmount = nAmount;          // 請求金額
+                ReqDetail.TaxAmount = nTax;                 // 消費税
+
+                // 請求データ、消費税は請求データ用に合算していく
+                nRequestTotal += nAmount;
+                nTaxTotal += nTax;                          
+
+                // 行は2行ずつ加算
+                trow += 2;
+
+                // 要素は1つずつ加算
+                nIndex++;
+
             }
-            catch (Exception ex)
+
+            // 前本工事がある場合
+            if (ReqData != null)
             {
-                logger.ErrorFormat("システムエラー：{0}：{1}", CommonMotions.GetMethodName(), ex.Message);
+                // 請求データの請求金額０～６と消費税は最後に設定
+                ReqData.RequestAmount0 = nAmounts[0];                                   // 請求金額０（本工事）
+                ReqData.RequestAmount1 = nAmounts[1];                                   // 請求金額１
+                ReqData.RequestAmount2 = nAmounts[2];                                   // 請求金額２
+                ReqData.RequestAmount3 = nAmounts[3];                                   // 請求金額３
+                ReqData.RequestAmount4 = nAmounts[4];                                   // 請求金額４
+                ReqData.RequestAmount5 = nAmounts[5];                                   // 請求金額５
+                ReqData.RequestAmount6 = nAmounts[6];                                   // 請求金額６
+                ReqData.TaxAmount = nTaxTotal;                                          // 消費税
+                ReqData.UnclaimedAmount = nContractAmount - (nPaidAmount + nRequestTotal);    // 請求金額残
             }
-            return stat;
+
+            return;
         }
+        #endregion
 
-        /// <summary>
-        /// 請求明細列を表示設定
-        /// </summary>
-        /// <param name="reqIndex"></param>
-        private void SetRequestInfoColumn(int reqIndex)
+        #region 請負金額の取得
+        private int GetContractAmount(int nMainConstructionCode)
         {
-            try
+            int nContractAmount = 0;
+
+            Dictionary<int, List<RequestDataDetail>> dicDataDetail = m_lstRequestDataDetail[m_nMaxOrderNo-1];
+
+            List<RequestDataDetail> lstReqDetail = null;
+            if (dicDataDetail.TryGetValue(nMainConstructionCode, out lstReqDetail) == false)
             {
-                int cIndex;
-                int orderNo = m_LstRequestTotalData[reqIndex].OrderNo;
+                return nContractAmount;
+            }
 
-                // 列が足りない場合は追加する
-                if (reqIndex + 1 > m_RequestColumnCount)
-                {
-                    cIndex = GetColumnIndexNum(ColumnIndex.Amount);
-                    DataGridViewColumn colObj = new DataGridViewTextBoxColumn();
-                    colObj.ReadOnly = true;
-                    colObj.Width = 120;
-                    dgv1.Columns.Insert(cIndex, colObj);
-                    m_RequestColumnCount++;
-                    dgv1.Columns[cIndex].HeaderText = string.Format("{0}回目", reqIndex + 1);
-                }
-                else
-                {
-                    cIndex = GetColumnIndexNum(ColumnIndex.RequestInfo, reqIndex + 1);
-                }
-                dgv1.Columns[cIndex].HeaderCell.Style.ForeColor = Color.Black;
+            foreach (RequestDataDetail ReqDetail in lstReqDetail)
+            {
+                ConstructionBaseInfo Info = null;
+                m_dicConstructionBaseInfo.TryGetValue(ReqDetail.ConstructionCode, out Info);
 
-                var requestTotalData = m_LstRequestTotalData[reqIndex];
+                nContractAmount += CommonMotions.cnvInt(Info.OrdersDecisionPrice);
+            }
 
-                // 請求書作成日
-                if (requestTotalData.BillCreationDate != DateTime.MinValue)
+            return nContractAmount;
+        }
+        #endregion
+
+        #region 請求済み金額の取得
+        private int GetPaidAmount(int nMaxOrderNo, int MainConstructionCode)
+        {
+            int nPaidAmount = 0;
+            RequestData ReqData = null;
+
+            if( m_nMaxOrderNo > 1 ){
+                // 直前の請求データをみればよい
+                Dictionary<int, RequestData> dicData = m_lstRequestData[m_nMaxOrderNo-2];
+
+                if (dicData.TryGetValue(MainConstructionCode, out ReqData) == true)
                 {
-                    var gridRowRequestCreateDate = GetDataGridViewRowObject(RowSectionIndex.Header, RowKind.RequestSheetCreateDate);
-                    gridRowRequestCreateDate.Cells[cIndex].Value = requestTotalData.BillCreationDate.ToShortDateString();
-                    gridRowRequestCreateDate.Cells[cIndex].Style.Alignment = DataGridViewContentAlignment.MiddleCenter;
+                    nPaidAmount += ReqData.PaidAmount;
+                    nPaidAmount += ReqData.RequestAmount0;
+                    nPaidAmount += ReqData.RequestAmount1;
+                    nPaidAmount += ReqData.RequestAmount2;
+                    nPaidAmount += ReqData.RequestAmount3;
+                    nPaidAmount += ReqData.RequestAmount4;
+                    nPaidAmount += ReqData.RequestAmount5;
+                    nPaidAmount += ReqData.RequestAmount6;
                 }
+            }
 
-                // 承認状態
-                var gridRowApprovalStatus = GetDataGridViewRowObject(RowSectionIndex.Header, RowKind.ApprobalStatus);
-                RequestApprovalStatus stat = RequestApprovalStatus.NowInput;
-                if (m_DicProcessApproval.ContainsKey(orderNo))
+            return nPaidAmount;
+        }
+        #endregion
+
+        #region データの保存
+        private bool SaveDispData()
+        {
+            int nRequestNo = 0;
+            bool bAdd = false;
+
+            IORequestHead ioReqHead = new IORequestHead();
+            IORequestData ioReqData = new IORequestData();
+            IORequestDataDetail ioReqDetail = new IORequestDataDetail();
+            IOConstructionLedgerExcute ioLdgExcute = new IOConstructionLedgerExcute();
+
+            ioReqHead.beginTran();
+            ioReqData.beginTran();
+            ioReqDetail.beginTran();
+            ioLdgExcute.beginTran();
+
+            RequestHead ReqHead = m_lstRequestHead[m_nMaxOrderNo - 1];
+
+            try{
+                string sql;
+
+                nRequestNo = ReqHead.RequestNo;
+
+                if (nRequestNo != 0)
                 {
-                    stat = CheckApprovalStatus(m_DicProcessApproval[orderNo], m_DicApprovalMaster);
-                }
-                gridRowApprovalStatus.Cells[cIndex].Value = s_DictApprovalStatusString[stat];
-                gridRowApprovalStatus.Cells[cIndex].Style.Alignment = DataGridViewContentAlignment.MiddleCenter;
+                    // 請求Noの要素である請求月を求める
+                    int nMonth = CommonMotions.cnvTruncate((double)nRequestNo / 1000);
 
-                // 本工事行
-                if (m_DicRequestDataDetail.ContainsKey(m_ConstructionCode))        // 本工事分の明細があることを確認
-                {
-                    RequestDataDetail detail;
-                    if (m_DicRequestDataDetail[m_ConstructionCode].ContainsKey(orderNo))
+                    // 請求月が一致してない場合は、データを再登録
+                    if (nMonth != ReqHead.RequestMonth)
                     {
-                        detail = m_DicRequestDataDetail[m_ConstructionCode][orderNo];
-                    }
-                    else
-                    {
-                        detail = m_DicRequestDataDetail[m_ConstructionCode][orderNo] = new RequestDataDetail();
-                        detail.RequestNo = m_RequestData.RequestNo;
-                        detail.ConstructionCode = m_ConstructionCode;
-                        detail.OrderNo = orderNo;
-                        detail.ConstructionKind = 0;
-                    }
+                        // 当該受付回目の請求データ明細を削除
+                        sql = ioReqDetail.CreatePrimarykeyString(nRequestNo);
+                        if (ioReqDetail.DeleteAction(sql) == false)
+                        {
+                            ioReqHead.rollback();
+                            ioReqData.rollback();
+                            ioReqDetail.rollback();
+                            ioLdgExcute.rollback();
+                            return false;
+                        }
 
-                    // 請求金額
-                    var gridRowOrgBillPrice = GetDataGridViewRowObject(RowSectionIndex.OriginalConstruction, RowKind.BillPrice);
-                    SetDataGridCellDecimal(gridRowOrgBillPrice.Cells[cIndex], (double)detail.BillPrice);
-                    gridRowOrgBillPrice.Cells[cIndex].ReadOnly = (stat == RequestApprovalStatus.Approval) ? true : false;
+                        // 当該受付回目の請求データを削除
+                        sql = ioReqData.CreatePrimarykeyString(nRequestNo);
+                        if (ioReqData.DeleteAction(sql) == false)
+                        {
+                            ioReqHead.rollback();
+                            ioReqData.rollback();
+                            ioReqDetail.rollback();
+                            ioLdgExcute.rollback();
+                            return false;
+                        }
 
-                    // 消費税
-                    var gridRowOrgTaxPrice = GetDataGridViewRowObject(RowSectionIndex.OriginalConstruction, RowKind.TaxPrice);
-                    SetDataGridCellDecimal(gridRowOrgTaxPrice.Cells[cIndex], (double)detail.TaxPrice);
-                    gridRowOrgTaxPrice.Cells[cIndex].ReadOnly = (stat == RequestApprovalStatus.Approval) ? true : false;
+                        // 請求ヘッダを削除
+                        sql = ioReqHead.CreatePrimarykeyString(nRequestNo);
+                        if (ioReqHead.DeleteAction(sql) == false)
+                        {
+                            ioReqHead.rollback();
+                            ioReqData.rollback();
+                            ioReqDetail.rollback();
+                            ioLdgExcute.rollback();
+                            return false;
+                        }
 
-                    // 未入金分
-                    var gridRowOrgAmount = GetDataGridViewRowObject(RowSectionIndex.OriginalConstruction, RowKind.AmountPrice);
-                    SetDataGridCellDecimal(gridRowOrgAmount.Cells[cIndex], (double)detail.AmountBlance);
-                    gridRowOrgAmount.Cells[cIndex].ReadOnly = (stat == RequestApprovalStatus.Approval) ? true : false;
+                        nRequestNo = 0;
+                    }
+                }
 
+                // ＤＢ未登録の場合
+                if (nRequestNo == 0)
+                {
+                    // 請求Noを採番
+                    nRequestNo = ioReqHead.NumberingRequestNo(ReqHead.RequestMonth);
+
+                    bAdd = true;
                 }
 
-                // 増減工事行
-                foreach (int constCode in m_LstConstructionLink)
+                // 更新の場合
+                if (bAdd == false)
                 {
-                    Dictionary<int, RequestDataDetail> dicRequestDataDetail;
-                    if (m_DicRequestDataDetail.ContainsKey(constCode))
-                    {
-                        dicRequestDataDetail = m_DicRequestDataDetail[constCode];
+                    // 請求ヘッダの更新
+                    sql = ioReqHead.CreatePrimarykeyString(nRequestNo);
+                    if( ioReqHead.UpdateAction(sql, ReqHead) == false){
+                        ioReqHead.rollback();
+                        ioReqData.rollback();
+                        ioReqDetail.rollback();
+                        ioLdgExcute.rollback();
+                        return false;
                     }
-                    else
+
+                    // 当該受付回目の請求データ明細を削除
+                    sql = ioReqDetail.CreatePrimarykeyString(nRequestNo);
+                    if (ioReqDetail.DeleteAction(sql) == false)
                     {
-                        dicRequestDataDetail = m_DicRequestDataDetail[constCode] = new Dictionary<int, RequestDataDetail>();
+                        ioReqHead.rollback();
+                        ioReqData.rollback();
+                        ioReqDetail.rollback();
+                        ioLdgExcute.rollback();
+                        return false;
                     }
 
-                    RequestDataDetail detail;
-                    if (dicRequestDataDetail.ContainsKey(orderNo))
+                    // 当該受付回目の請求データを削除
+                    sql = ioReqData.CreatePrimarykeyString(nRequestNo);
+                    if (ioReqData.DeleteAction(sql) == false)
                     {
-                        detail = dicRequestDataDetail[orderNo];
+                        ioReqHead.rollback();
+                        ioReqData.rollback();
+                        ioReqDetail.rollback();
+                        ioLdgExcute.rollback();
+                        return false;
                     }
-                    else
-                    {
-                        detail = dicRequestDataDetail[orderNo] = new RequestDataDetail();
-                        detail.RequestNo = m_RequestData.RequestNo;
-                        detail.ConstructionCode = constCode;
-                        detail.OrderNo = orderNo;
-                        detail.ConstructionKind = 1;
+
+                }
+                else
+                {
+                    // 請求ヘッダの追加
+                    ReqHead.RequestNo = nRequestNo;
+                    if(ioReqHead.InsertAction(ReqHead) == false){
+                        ioReqHead.rollback();
+                        ioReqData.rollback();
+                        ioReqDetail.rollback();
+                        ioLdgExcute.rollback();
+                        return false;
                     }
+                }
 
-                    // 請求金額
-                    var gridRowChldBillPrice = GetDataGridViewRowObject(RowSectionIndex.ChildConstruction, RowKind.BillPrice, m_LstConstructionLink.IndexOf(constCode));
-                    SetDataGridCellDecimal(gridRowChldBillPrice.Cells[cIndex], (double)detail.BillPrice);
-                    gridRowChldBillPrice.Cells[cIndex].ReadOnly = (stat == RequestApprovalStatus.Approval) ? true : false;
+                // 請求データ以下は常に追加
 
-                    // 消費税
-                    var gridRowChldTaxPrice = GetDataGridViewRowObject(RowSectionIndex.ChildConstruction, RowKind.TaxPrice, m_LstConstructionLink.IndexOf(constCode));
-                    SetDataGridCellDecimal(gridRowChldTaxPrice.Cells[cIndex], (double)detail.TaxPrice);
-                    gridRowChldTaxPrice.Cells[cIndex].ReadOnly = (stat == RequestApprovalStatus.Approval) ? true : false;
+                // 請求データをリストに設定
+                List<RequestData> lstData = new List<RequestData>();
+                SetRequestDataList(nRequestNo, ref lstData);
 
+                // 請求データの追加
+                if (ioReqData.InsertAction(lstData) == false)
+                {
+                    ioReqHead.rollback();
+                    ioReqData.rollback();
+                    ioReqDetail.rollback();
+                    ioLdgExcute.rollback();
+                    return false;
                 }
 
-                // OrderNoで入金明細があるかを確認
-                var depositDetail = m_DicDepositDataDetail.ContainsKey(orderNo) ? m_DicDepositDataDetail[orderNo] : new DepositDataDetail();
+                // 請求データ明細リストに設定
+                List<RequestDataDetail> lstDetail = new List<RequestDataDetail>();
+                SetRequestDataDetailList(nRequestNo, ref lstDetail);
 
-                if (m_DicDepositDataDetail.ContainsKey(orderNo))
+                // 請求データ明細の追加
+                if (ioReqDetail.InsertAction(lstDetail) == false)
                 {
-                    // あったら入金データを取得
-                    var depositData = new DepositData();
-                    if (GetDepositData(depositDetail.OrderersDivision,
-                                        depositDetail.OrderersCode,
-                                        depositDetail.TargetDate,
-                                        depositDetail.SeqNo,
-                                        ref depositData))
-                    {
-                        // 取得できたら表示設定
+                    ioReqHead.rollback();
+                    ioReqData.rollback();
+                    ioReqDetail.rollback();
+                    ioLdgExcute.rollback();
+                    return false;
+                }
 
-                        // 入金日
-                        var gridRowDepositDate = GetDataGridViewRowObject(RowSectionIndex.DepositInfo, RowKind.DepositDate);
-                        gridRowDepositDate.Cells[cIndex].Value = depositData.DepositDate.ToShortDateString();
+                // 詳細台帳へ請求金額の反映
+                if (UpdateRequestAmount(ref ioLdgExcute, ReqHead) == false)
+                {
+                    ioReqHead.rollback();
+                    ioReqData.rollback();
+                    ioReqDetail.rollback();
+                    ioLdgExcute.rollback();
 
-                    }
-
-                    // 入金金額
-                    var gridRowDepositPrice = GetDataGridViewRowObject(RowSectionIndex.DepositInfo, RowKind.DepositPrice);
-                    SetDataGridCellDecimal(gridRowDepositPrice.Cells[cIndex], (double)depositDetail.DepositAmount);
-
-                    // 差額
-                    var gridRowDepositDiff = GetDataGridViewRowObject(RowSectionIndex.DepositInfo, RowKind.DifferencePrice);
-                    SetDataGridCellDecimal(gridRowDepositDiff.Cells[cIndex], (double)depositDetail.CarryAmount);
-
-                    // 入金確認
-                    var gridRowDepositCheck = GetDataGridViewRowObject(RowSectionIndex.DepositInfo, RowKind.DepositCheck);
-                    gridRowDepositCheck.Cells[cIndex].Value = depositDetail.ApprovalEndFlg ? "確認済" : "";
-                    gridRowDepositCheck.Cells[cIndex].Style.Alignment = DataGridViewContentAlignment.MiddleCenter;
+                    return false;
                 }
 
+                // コミット
+                ioReqHead.commit();
+                ioReqData.commit();
+                ioReqDetail.commit();
+                ioLdgExcute.commit();
             }
             catch (Exception ex)
             {
                 logger.ErrorFormat("システムエラー：{0}：{1}", CommonMotions.GetMethodName(), ex.Message);
             }
+            finally
+            {
+                ioReqHead.close();
+                ioReqHead = null;
+                ioReqData.close();
+                ioReqData = null;
+                ioReqDetail.close();
+                ioReqDetail = null;
+                ioLdgExcute.close();
+                ioLdgExcute = null;
+            }
 
+            return true;
         }
+        #endregion
 
-        /// <summary>
-        /// DataGridViewCellに数値を表示設定する
-        /// </summary>
-        /// <param name="cell"></param>
-        /// <param name="value"></param>
-        private void SetDataGridCellDecimal(DataGridViewCell cell, double value)
+        #region 請求データリストの設定
+        private void SetRequestDataList(int nRequestNo, ref List<RequestData> lst)
         {
-            try
+
+            Dictionary<int, RequestData> dic = m_lstRequestData[m_nMaxOrderNo - 1];
+
+            List<int> lstKey = new List<int>(dic.Keys);
+
+            foreach (int nMainConstructionCode in lstKey)
             {
-                if (cell != null)
+                RequestData ReqData = null;
+
+                if (dic.TryGetValue(nMainConstructionCode, out ReqData) == true)
                 {
-                    cell.Value = value;
-                    cell.Style.Format = "#,0";
-                    cell.Style.ForeColor = (value < 0) ? Color.Red : Color.Black;
-                    cell.Style.Alignment = DataGridViewContentAlignment.MiddleRight;
+                    ReqData.RequestNo = nRequestNo;
+                    lst.Add(ReqData);
                 }
             }
-            catch (Exception ex)
-            {
-                logger.ErrorFormat("システムエラー：{0}：{1}", CommonMotions.GetMethodName(), ex.Message);
-            }
 
+            return;
         }
+        #endregion
 
-        /// <summary>
-        /// 請求回数追加
-        /// </summary>
-        private void AddRequest()
+        #region 請求データ明細リストの設定
+        private void SetRequestDataDetailList(int nRequestNo, ref List<RequestDataDetail> lst)
         {
-            try
-            {
-                // 請求合計データを追加
-                var totalData = new RequestTotalData();
-                totalData.RequestNo = m_RequestData.RequestNo;
-                totalData.OrderNo = m_LstRequestTotalData.Count + 1;
-                totalData.OrderersDivision = m_RequestData.OrderersDivision;
-                totalData.OrderersCode = m_RequestData.OrderersCode;
-                totalData.BillCreationDate = DateTime.MinValue;
 
-                m_LstRequestTotalData.Add(totalData);
+            Dictionary<int, List<RequestDataDetail>> dic = m_lstRequestDataDetail[m_nMaxOrderNo - 1];
 
-                // 請求明細データの追加の対象となる工事番号を収集
-                List<int> lstConstCodes = new List<int>();
-                lstConstCodes.Add(m_ConstructionCode);
-                lstConstCodes.AddRange(m_LstConstructionLink);
+            List<int> lstKey = new List<int>(dic.Keys);
 
-                // 請求明細データを追加
-                foreach (int code in lstConstCodes)
+            foreach (int nMainConstructionCode in lstKey)
+            {
+                List<RequestDataDetail> lstDetail = null;
+
+                if (dic.TryGetValue(nMainConstructionCode, out lstDetail) == true)
                 {
-                    if (!m_DicRequestDataDetail.ContainsKey(code))
+                    foreach (RequestDataDetail ReqDetail in lstDetail)
                     {
-                        m_DicRequestDataDetail[code] = new Dictionary<int, RequestDataDetail>();
+                        ReqDetail.RequestNo = nRequestNo;
+                        lst.Add(ReqDetail);
                     }
-
-                    var detail = new RequestDataDetail();
-                    detail.RequestNo = m_RequestData.RequestNo;
-                    detail.OrderNo = totalData.OrderNo;
-                    detail.ConstructionCode = code;
-                    detail.ConstructionKind = (code == m_ConstructionCode) ? 0 : 1;
-
-                    m_DicRequestDataDetail[code][detail.OrderNo] = detail;
                 }
+            }
 
-                // 追加した請求明細列表示
-                SetRequestInfoColumn(totalData.OrderNo - 1);
-
-                // 自動計算セル表示
-                SetAutoCalcRow();
-
-                // 合計セクション表示
-                SetTotalInfoColumn(ColumnIndex.RequestInfo, m_LstRequestTotalData.Count());
-
-                // 合計セクション合計列および残り列表示
-                SetTotalSectionInfo();
-
-            }
-            catch (Exception ex)
-            {
-                logger.ErrorFormat("システムエラー：{0}：{1}", CommonMotions.GetMethodName(), ex.Message);
-            }
+            return;
         }
+        #endregion
 
-        /// <summary>
-        /// 登録処理
-        /// </summary>
-        private bool AcceptData()
+        #region 詳細台帳の請求金額の更新
+        private bool UpdateRequestAmount(ref IOConstructionLedgerExcute ioLdgExcute, RequestHead ReqHead)
         {
-            bool ret;
+            string sql = "" ;
 
-            var reqDB = new IORequestData();
-            var reqTotalDB = new IORequestTotalData();
-            var reqDetailDB = new IORequestDataDetail();
+            IOConstructionLedgerDetail ioLdgDetail = new IOConstructionLedgerDetail();
+            List<ConstructionLedgerDetail> lstDetail = new List<ConstructionLedgerDetail>();
 
-            ret = true;
-
             try
             {
-                // ---------- 行インデックス ----------------
-                // 工事金額列インデックス
-                int constPriceColIndex = GetColumnIndexNum(ColumnIndex.ConstructionPrice);
+                // 請求金額の行番号を取得
+                sql = ioLdgDetail.CreatePrimarykeyString(m_nLeaderConstructionCode,(int)FrmConstructionLedger.DataGroup.BillingAmount);
+                if (ioLdgDetail.SelectAction(sql, ref lstDetail) == false)
+                {
+                    return false;
+                }
 
-                // 合計列インデックス
-                int totalColIndex = GetColumnIndexNum(ColumnIndex.Total);
+                // 詳細台帳がない場合は終了
+                if (lstDetail.Count == 0)
+                {
+                    return true;
+                }
 
-                // 残り列インデックス
-                int amountColIndex = GetColumnIndexNum(ColumnIndex.Amount);
+                int yyyy = 0;
+                int mm = 0;
+                DateTime dt = DateTime.MinValue;
 
+                ConstructionLedgerExcute LdgExcute = null;
 
-                // ---------- 行オブジェクト ----------------
-                var billPriceRow = GetDataGridViewRowObject(RowSectionIndex.Total, RowKind.BillPrice);
-                var nonTaxedRow = GetDataGridViewRowObject(RowSectionIndex.Total, RowKind.NonTaxedPrice);
-                var taxPriceRow = GetDataGridViewRowObject(RowSectionIndex.Total, RowKind.TaxPrice);
-                var amountRow = GetDataGridViewRowObject(RowSectionIndex.Total, RowKind.AmountPrice);
-                var orgAmountRow = GetDataGridViewRowObject(RowSectionIndex.OriginalConstruction, RowKind.AmountPrice);
+                List<ConstructionLedgerExcute> lstExcute = new List<ConstructionLedgerExcute>();
 
-                // 更新用データ収集処理
-                m_RequestData.AmountPaid = 0;
-                m_RequestData.PricePaid = 0;
-                m_RequestData.TaxPricePaid = 0;
-                m_RequestData.AmountBlance = 0;
-                int totalAmountPaid = 0;
-                int totalPricePaid = 0;
-                int totalTaxPaid = 0;
-
-                foreach (var totalData in m_LstRequestTotalData)
+                // 旧請求年月が指定されている場合は、一旦旧請求金額を差し引く
+                if( m_nOldRequestMonth != 0)
                 {
-                    int cIndex = GetColumnIndexNum(ColumnIndex.RequestInfo, m_LstRequestTotalData.IndexOf(totalData) + 1);
+                    yyyy = CommonMotions.cnvTruncate((double)m_nOldRequestMonth / 100);
+                    mm = m_nOldRequestMonth % 100;
 
-                    // 承認データチェック
-                    RequestApprovalStatus stat = RequestApprovalStatus.NowInput;
-                    if (m_DicProcessApproval.ContainsKey(totalData.OrderNo))
+                    dt = new DateTime( yyyy, mm, 1);
+
+                    sql = ioLdgExcute.CreatePrimarykeyString(m_nLeaderConstructionCode, lstDetail[0].GroupCount, lstDetail[0].LineCount);
+                    sql += string.Format(" AND TargetMonth = STR_TO_DATE('{0}', '%Y%m%d') ", dt.ToString("yyyyMMdd"));
+
+                    if (ioLdgExcute.SelectAction(sql, ref lstExcute) == false)
                     {
-                        stat = CheckApprovalStatus(m_DicProcessApproval[totalData.OrderNo], m_DicApprovalMaster);
+                        return false;
                     }
 
-                    if (stat < RequestApprovalStatus.NowInput)
+                    // 旧請求年月があってレコードなしはありえない
+                    if(lstExcute.Count == 0)
                     {
-                        // 請求済金額
-                        m_RequestData.AmountPaid += Convert.ToInt32(billPriceRow.Cells[cIndex].Value);
+                        return false;
+                    }
 
-                        // 請求済工事金額
-                        m_RequestData.PricePaid += Convert.ToInt32(nonTaxedRow.Cells[cIndex].Value);
+                    LdgExcute = lstExcute[0];
 
-                        // 請求済消費税金額
-                        m_RequestData.TaxPricePaid += Convert.ToInt32(taxPriceRow.Cells[cIndex].Value);
-
-                        // 未入金額
-                        m_RequestData.AmountBlance -= Convert.ToInt32(orgAmountRow.Cells[cIndex].Value);
+                    // 請求金額から旧請求金額を差し引いた金額で更新
+                    LdgExcute.PaymentAmount -= (double)m_nOldRequestAmount;
+                    sql = ioLdgExcute.CreatePrimarykeyString( LdgExcute.ConstructionCode, LdgExcute.GroupCount, LdgExcute.LineCount, LdgExcute.ColumnCount);
+                    if( ioLdgExcute.UpdateAction(sql, LdgExcute) == false)
+                    {
+                        return false;
                     }
 
-                    // 請求合計データ
-                    totalData.BillTotalPrice = Convert.ToInt32(billPriceRow.Cells[cIndex].Value);
-                    totalData.BillPrice = Convert.ToInt32(nonTaxedRow.Cells[cIndex].Value);
-                    totalData.TaxPrice = Convert.ToInt32(taxPriceRow.Cells[cIndex].Value);
-                    totalData.AmountBlance = Convert.ToInt32(amountRow.Cells[cIndex].Value);
-                    totalData.AmountPaid = (totalAmountPaid += Convert.ToInt32(billPriceRow.Cells[cIndex].Value));
-                    totalData.PricePaid = (totalPricePaid += Convert.ToInt32(nonTaxedRow.Cells[cIndex].Value));
-                    totalData.TaxPricePaid = (totalTaxPaid += Convert.ToInt32(taxPriceRow.Cells[cIndex].Value));
-                    totalData.PriceBalance = Convert.ToInt32(nonTaxedRow.Cells[constPriceColIndex].Value) - totalPricePaid;
-                    totalData.TaxBalance = Convert.ToInt32(taxPriceRow.Cells[constPriceColIndex].Value) - totalTaxPaid;
+                    // リストをクリア
+                    lstExcute.Clear();
+                }
 
-                    // 請求合計データテーブル更新および追加処理
-                    if (m_DicReqTotalRec.ContainsKey(totalData))
+                // 請求ヘッダより請求月を求める
+                yyyy = CommonMotions.cnvTruncate((double)ReqHead.RequestMonth / 100);
+                mm = ReqHead.RequestMonth % 100;
+                dt = new DateTime( yyyy, mm, 1);
+
+                // 当該月の請求金額のレコードがあるか取得してみる
+                sql = ioLdgExcute.CreatePrimarykeyString(m_nLeaderConstructionCode, lstDetail[0].GroupCount, lstDetail[0].LineCount);
+                sql += string.Format(" AND TargetMonth = STR_TO_DATE('{0}', '%Y%m%d') ", dt.ToString("yyyyMMdd"));
+                if (ioLdgExcute.SelectAction(sql, ref lstExcute) == false)
+                {
+                    return false;
+                }
+
+                // レコードが存在する場合
+                if (lstExcute.Count > 0)
+                {
+                    LdgExcute = lstExcute[0];
+                    
+                    // 請求金額を加算して更新
+                    LdgExcute.PaymentAmount += ReqHead.RequestAmount;
+                    sql = ioLdgExcute.CreatePrimarykeyString(LdgExcute.ConstructionCode, LdgExcute.GroupCount, LdgExcute.LineCount, LdgExcute.ColumnCount);
+                    if (ioLdgExcute.UpdateAction(sql, LdgExcute) == false)
                     {
-                        // データ読み込み時に存在したレコードなら更新
-                        reqTotalDB.UpdateAction("", totalData);
+                        return false;
                     }
-                    else
-                    {
-                        // データ読み込み時に存在しなかったレコードなら追加
-                        reqTotalDB.InsertAction(totalData);
-                        m_DicReqTotalRec[totalData] = true;
-                    }
+                }
+                else
+                {
+                    // 工事詳細台帳実行データを設定
+                    LdgExcute = new ConstructionLedgerExcute();
 
-                    foreach (var constCode in m_DicRequestDataDetail.Keys)
+                    LdgExcute.ConstructionCode = m_nLeaderConstructionCode;
+                    LdgExcute.GroupCount = lstDetail[0].GroupCount;
+                    LdgExcute.LineCount = lstDetail[0].LineCount;
+                    LdgExcute.ColumnCount = CalcTargetMonthToColumn(dt);
+                    LdgExcute.PaymentAmount = ReqHead.RequestAmount;
+                    LdgExcute.TargetMonth = dt;
+
+                    // レコードを挿入
+                    if (ioLdgExcute.InsertAction(LdgExcute) == false)
                     {
-                        if (m_DicReqDetailRec.ContainsKey(m_DicRequestDataDetail[constCode][totalData.OrderNo]))
-                        {
-                            // データ読み込み時に存在したレコードなら更新
-                            reqDetailDB.UpdateAction("", m_DicRequestDataDetail[constCode][totalData.OrderNo]);
-                        }
-                        else
-                        {
-                            // データ読み込み時に存在しなかったレコードなら追加
-                            reqDetailDB.InsertAction(m_DicRequestDataDetail[constCode][totalData.OrderNo]);
-                            m_DicReqDetailRec[m_DicRequestDataDetail[constCode][totalData.OrderNo]] = true;
-                        }
+                        return false;
                     }
-
                 }
 
-                // 請求残工事金額
-                m_RequestData.PriceBalance = Convert.ToInt32(nonTaxedRow.Cells[constPriceColIndex].Value) - m_RequestData.PricePaid;
 
-                // 請求残消費税金額
-                m_RequestData.TaxBalance = Convert.ToInt32(taxPriceRow.Cells[constPriceColIndex].Value) - m_RequestData.TaxPricePaid;
+            }
+            catch (Exception ex)
+            {
+                logger.ErrorFormat("システムエラー：{0}：{1}", CommonMotions.GetMethodName(), ex.Message);
+            }
+            finally
+            {
+                ioLdgDetail.close();
+                ioLdgDetail = null;
+            }
+         
+            return true;
+        }
+        #endregion
 
-                // 未入金額
-                m_RequestData.AmountBlance += Convert.ToInt32(orgAmountRow.Cells[amountColIndex].Value) + Convert.ToInt32(orgAmountRow.Cells[totalColIndex].Value);
+        #region 請求月のカラム位置を算出
+        private int CalcTargetMonthToColumn(DateTime dtTarget)
+        {
+            int tcol = -1;
 
-                // 請求データが登録されていない場合はレコード作成
-                if (isEmptyConstructionBaseInfo)
+            IOConstructionLedgerExcute ioExcute;
+
+            ioExcute = new IOConstructionLedgerExcute();
+
+            try
+            {
+                string sql = ioExcute.CreatePrimarykeyString(m_nLeaderConstructionCode);
+                sql += " AND ColumnCount = 27";
+
+                List<ConstructionLedgerExcute> lstExcute = new List<ConstructionLedgerExcute>();
+
+                if (ioExcute.SelectAction(sql, ref lstExcute) == false)
                 {
-                    // 請求データ追加処理
-                    reqDB.InsertAction(m_RequestData);
-                } else
-                {
-                    // 請求データ更新処理
-                    reqDB.UpdateAction("", m_RequestData);
+                    return tcol;
                 }
 
-                reqDB.commit();
-                reqTotalDB.commit();
-                reqDetailDB.commit();
+                tcol = ClsChangeLedgerData.CalcTargetMonthToColumn(lstExcute[0].TargetMonth, dtTarget);
 
             }
             catch (Exception ex)
             {
                 logger.ErrorFormat("システムエラー：{0}：{1}", CommonMotions.GetMethodName(), ex.Message);
-
-                ret = false;
             }
             finally
             {
-                reqDB.close();
-                reqTotalDB.close();
-                reqDetailDB.close();
-                reqDB = null;
-                reqTotalDB = null;
-                reqDetailDB = null;
+                ioExcute.close();
+                ioExcute = null;
             }
 
-            return ret;
+            return tcol;
+        }
+        #endregion
 
-        }
+        #endregion
+
         #region データベースアクセスメソッド
 
         #region 工事基本情報
@@ -1696,7 +2959,7 @@
         /// </summary>
         /// <param name="lstChldConstructionCode"></param>
         /// <returns></returns>
-        private bool GetConstructionLink(ref List<int> lstChldConstructionCode)
+        private bool GetConstructionLink(int nConstructionCode, int nLinkType, ref List<int> lstChldConstructionCode)
         {
             var sbDB = new IOConstructionLink();
             try
@@ -1705,10 +2968,10 @@
                 var wrk = new List<ConstructionLink>();
 
                 // 工事増減情報取得SQL
-                string strSQL = sbDB.CreatePrimarykeyString(m_ConstructionCode);
+                string strSQL = sbDB.CreatePrimarykeyString(nConstructionCode);
 
                 // ソート条件を設定
-                strSQL += " ORDER BY FLUCTUATIONCODE";
+                strSQL += string.Format(" AND LinkType = {0} ORDER BY FLUCTUATIONCODE", nLinkType);
 
                 // 工事増減情報取得
                 if (!sbDB.SelectAction(strSQL, ref wrk)) return false;
@@ -1736,6 +2999,50 @@
         }
         #endregion
 
+        #region 工事リンク情報
+
+        private bool GetConstructionLinkFromFluctuationCode(int FluctuationCode, int LinkType, ref int ConstructionCode)
+        {
+            var sbDB = new IOConstructionLink();
+            try
+            {
+                // 工事増減情報取得クラス領域
+                var wrk = new List<ConstructionLink>();
+
+                // 工事増減情報取得SQL
+                string strSQL = string.Format("FLUCTUATIONCODE = {0}", FluctuationCode);
+
+                // ソート条件を設定
+                strSQL += string.Format(" AND LinkType = {0}", LinkType);
+
+                // 工事増減情報取得
+                if (!sbDB.SelectAction(strSQL, ref wrk)) return false;
+
+                // 工事増減情報をリストにセット
+                foreach (var detail in wrk)
+                {
+                    ConstructionCode = detail.ConstructionCode;
+
+                    break;
+                }
+
+            }
+            catch (Exception ex)
+            {
+                logger.ErrorFormat("システムエラー：{0}：{1}", CommonMotions.GetMethodName(), ex.Message);
+                return false;
+            }
+            finally
+            {
+                sbDB.close();
+                sbDB = null;
+            }
+
+            return true;
+        }
+
+        #endregion
+
         #region 工事詳細台帳データ
         /// <summary>
         /// 工事詳細台帳データを工事詳細台帳データテーブルから工事番号をキーに取得する関数
@@ -1830,21 +3137,21 @@
         /// <returns>true：成功 false：失敗</returns>
         private bool GetRequestData(ref RequestData data)
         {
-            var sbDB = new IORequestData();
+            //var sbDB = new IORequestData();
             try
             {
-                // 請求データ取得クラス領域
-                var wrk = new List<RequestData>();
+                //// 請求データ取得クラス領域
+                //var wrk = new List<RequestData>();
 
-                // 請求データ取得SQL
-                string strSQL = sbDB.CreateSubkeyString(m_ConstructionCode);
+                //// 請求データ取得SQL
+                //string strSQL = sbDB.CreateSubkeyString(m_ConstructionCode);
 
-                // 請求データ取得
-                if (!sbDB.SelectAction(strSQL, ref wrk)) return false;
+                //// 請求データ取得
+                //if (!sbDB.SelectAction(strSQL, ref wrk)) return false;
 
-                if (wrk.Count != 1) return false;
+                //if (wrk.Count != 1) return false;
 
-                data = wrk[0];
+                //data = wrk[0];
             }
             catch (Exception ex)
             {
@@ -1853,8 +3160,8 @@
             }
             finally
             {
-                sbDB.close();
-                sbDB = null;
+                //sbDB.close();
+                //sbDB = null;
             }
 
             return true;
@@ -1866,39 +3173,39 @@
         /// 請求データに登録する情報を工事基本情報から取得
         /// </summary>
         /// <param name="data"></param>
-        private bool GetRequestDataFromConstructionBase(ref RequestData data)
-        {
-            var sbDB = new IOConstructionBaseInfo();
+        //private bool GetRequestDataFromConstructionBase(ref RequestData data)
+        //{
+        //    var sbDB = new IOConstructionBaseInfo();
 
-            try
-            {
-                // 工事基本情報取得クラス領域
-                List<ConstructionBaseInfo> wrk = new List<ConstructionBaseInfo>();
+        //    try
+        //    {
+        //        // 工事基本情報取得クラス領域
+        //        List<ConstructionBaseInfo> wrk = new List<ConstructionBaseInfo>();
 
-                // 工事基本情報取得SQL
-                string strSQL = string.Format(" where ConstructionCode = {0} ", data.RequestNo);
+        //        // 工事基本情報取得SQL
+        //        string strSQL = string.Format(" where ConstructionCode = {0} ", data.RequestNo);
 
-                // 読み込み
-                if (!sbDB.SelectAction(strSQL, ref wrk)) return false;
+        //        // 読み込み
+        //        if (!sbDB.SelectAction(strSQL, ref wrk)) return false;
 
-                foreach(ConstructionBaseInfo info in wrk)
-                {
-                    data.OrderersDivision = info.OrderersDivision;
-                    data.OrderersCode = info.OrderersCode;
-                }
-            }
-            catch (Exception ex)
-            {
-                logger.ErrorFormat("システムエラー：{0}：{1}", CommonMotions.GetMethodName(), ex.Message);
-                return false;
-            }
-            finally
-            {
-                sbDB.close();
-                sbDB = null;
-            }
-            return true;
-        }
+        //        foreach(ConstructionBaseInfo info in wrk)
+        //        {
+        //            data.OrderersDivision = info.OrderersDivision;
+        //            data.OrderersCode = info.OrderersCode;
+        //        }
+        //    }
+        //    catch (Exception ex)
+        //    {
+        //        logger.ErrorFormat("システムエラー：{0}：{1}", CommonMotions.GetMethodName(), ex.Message);
+        //        return false;
+        //    }
+        //    finally
+        //    {
+        //        sbDB.close();
+        //        sbDB = null;
+        //    }
+        //    return true;
+        //}
         #endregion
 
         #region 請求合計データ
@@ -1908,44 +3215,44 @@
         /// <param name="RequestNo">請求No</param>
         /// <param name="data"></param>
         /// <returns>true：成功 false：失敗</returns>
-        private bool GetRequestTotalDatas(int RequestNo, ref List<RequestTotalData> data)
-        {
-            var sbDB = new IORequestTotalData();
-            try
-            {
-                // 請求合計データ取得クラス領域
-                var wrk = new List<RequestTotalData>();
+        //private bool GetRequestTotalDatas(int RequestNo, ref List<RequestTotalData> data)
+        //{
+        //    var sbDB = new IORequestTotalData();
+        //    try
+        //    {
+        //        // 請求合計データ取得クラス領域
+        //        var wrk = new List<RequestTotalData>();
 
-                // 請求合計データ取得SQL
-                string strSQL = sbDB.CreatePrimarykeyString(RequestNo);
+        //        // 請求合計データ取得SQL
+        //        string strSQL = sbDB.CreatePrimarykeyString(RequestNo);
 
-                // ソート条件を追加
-                strSQL += " ORDER BY REQUESTNO, ORDERNO";
+        //        // ソート条件を追加
+        //        strSQL += " ORDER BY REQUESTNO, ORDERNO";
 
-                // 請求合計データ取得
-                if (!sbDB.SelectAction(strSQL, ref wrk)) return false;
+        //        // 請求合計データ取得
+        //        if (!sbDB.SelectAction(strSQL, ref wrk)) return false;
 
-                foreach (var record in wrk)
-                {
-                    m_DicReqTotalRec[record] = true;
-                }
-                data = wrk;
+        //        foreach (var record in wrk)
+        //        {
+        //            m_DicReqTotalRec[record] = true;
+        //        }
+        //        data = wrk;
 
-            }
-            catch (Exception ex)
-            {
-                logger.ErrorFormat("システムエラー：{0}：{1}", CommonMotions.GetMethodName(), ex.Message);
-                return false;
-            }
-            finally
-            {
-                sbDB.close();
-                sbDB = null;
-            }
+        //    }
+        //    catch (Exception ex)
+        //    {
+        //        logger.ErrorFormat("システムエラー：{0}：{1}", CommonMotions.GetMethodName(), ex.Message);
+        //        return false;
+        //    }
+        //    finally
+        //    {
+        //        sbDB.close();
+        //        sbDB = null;
+        //    }
 
-            return true;
+        //    return true;
 
-        }
+        //}
         #endregion
 
         #region 請求明細データ
@@ -1955,49 +3262,49 @@
         /// <param name="RequestNo"></param>
         /// <param name="data"></param>
         /// <returns></returns>
-        private bool GetRequestDataDetails(int RequestNo, ref Dictionary<int,Dictionary<int,RequestDataDetail>> datas)
-        {
-            var sbDB = new IORequestDataDetail();
-            try
-            {
-                // 請求明細データ取得クラス領域
-                var wrk = new List<RequestDataDetail>();
+        //private bool GetRequestDataDetails(int RequestNo, ref Dictionary<int,Dictionary<int,RequestDataDetail>> datas)
+        //{
+        //    var sbDB = new IORequestDataDetail();
+        //    try
+        //    {
+        //        // 請求明細データ取得クラス領域
+        //        var wrk = new List<RequestDataDetail>();
 
-                // 請求明細データ取得SQL
-                string strSQL = sbDB.CreatePrimarykeyString(RequestNo);
+        //        // 請求明細データ取得SQL
+        //        string strSQL = sbDB.CreatePrimarykeyString(RequestNo);
 
-                // ソート条件を追加
-                strSQL += " ORDER BY REQUESTNO, ORDERNO, CONSTRUCTIONCODE";
+        //        // ソート条件を追加
+        //        strSQL += " ORDER BY REQUESTNO, ORDERNO, CONSTRUCTIONCODE";
 
-                // 請求明細データ取得
-                if (!sbDB.SelectAction(strSQL, ref wrk)) return false;
+        //        // 請求明細データ取得
+        //        if (!sbDB.SelectAction(strSQL, ref wrk)) return false;
 
-                // 取得したデータをハッシュテーブルにセット
-                foreach (var detail in wrk)
-                {
-                    if (!datas.ContainsKey(detail.ConstructionCode))
-                    {
-                        datas[detail.ConstructionCode] = new Dictionary<int, RequestDataDetail>();
-                    }
-                    datas[detail.ConstructionCode][detail.OrderNo] = detail;
-                    m_DicReqDetailRec[detail] = true;
-                }
+        //        // 取得したデータをハッシュテーブルにセット
+        //        foreach (var detail in wrk)
+        //        {
+        //            if (!datas.ContainsKey(detail.ConstructionCode))
+        //            {
+        //                datas[detail.ConstructionCode] = new Dictionary<int, RequestDataDetail>();
+        //            }
+        //            datas[detail.ConstructionCode][detail.OrderNo] = detail;
+        //            m_DicReqDetailRec[detail] = true;
+        //        }
 
-            }
-            catch (Exception ex)
-            {
-                logger.ErrorFormat("システムエラー：{0}：{1}", CommonMotions.GetMethodName(), ex.Message);
-                return false;
-            }
-            finally
-            {
-                sbDB.close();
-                sbDB = null;
-            }
+        //    }
+        //    catch (Exception ex)
+        //    {
+        //        logger.ErrorFormat("システムエラー：{0}：{1}", CommonMotions.GetMethodName(), ex.Message);
+        //        return false;
+        //    }
+        //    finally
+        //    {
+        //        sbDB.close();
+        //        sbDB = null;
+        //    }
 
-            return true;
+        //    return true;
 
-        }
+        //}
         #endregion
 
         #region 承認データ
@@ -2018,6 +3325,8 @@
                 // 承認データ取得SQL
                 string strSQL = sbDB.CreatePrimarykeyString(constructionCode, 5);
 
+                strSQL += " Order By OrderNo, SeqNo";
+
                 // 承認データ取得
                 if (!sbDB.SelectAction(strSQL, ref wrk)) return false;
 
@@ -2142,7 +3451,7 @@
         /// <param name="requestNo"></param>
         /// <param name="htDepositDataDetail"></param>
         /// <returns></returns>
-        private bool GetDepositDataDetail(int requestNo, ref Dictionary<int,DepositDataDetail> datas)
+        private bool GetDepositDataDetail(int nRequestNo, ref List<DepositDataDetail> lstDepData)
         {
             var sbDB = new IODepositDataDetail();
             try
@@ -2151,16 +3460,11 @@
                 var wrk = new List<DepositDataDetail>();
 
                 // 入金明細データ取得SQL
-                string strSQL = sbDB.CreateSubkeyString(requestNo);
+                string strSQL = sbDB.CreateSubkeyString(nRequestNo);
 
                 // 入金明細データ取得
-                if (!sbDB.SelectAction(strSQL, ref wrk)) return false;
+                if (!sbDB.SelectAction(strSQL, ref lstDepData)) return false;
 
-                // 入金明細データをハッシュテーブルにセット
-                foreach (var detail in wrk)
-                {
-                    datas[detail.OrderNo] = detail;
-                }
             }
             catch (Exception ex)
             {
@@ -2220,6 +3524,67 @@
         }
         #endregion
 
+        #region 承認データの登録
+        private bool SetProcessApproval(int nStatus)
+        {
+            IOProcessApproval   ioPrcApp = new IOProcessApproval();
+
+            string sql = "";
+            ProcessApproval PrcApp = new ProcessApproval();
+
+            try
+            {
+                sql = string.Format(" WHERE ConstructionCode = {0}", m_ConstructionCode);
+                sql += string.Format(" AND ApprovalCode = {0}", m_ApprovalCode);
+                sql += string.Format(" AND OrderNo = {0}", m_OrderNo);
+                sql += " AND SeqNo > 1";
+                sql += string.Format(" AND PersonCode = {0} ", CommonMotions.LoginUserData.PersonCode );
+
+                List<ProcessApproval> lstPrcApp = new List<ProcessApproval>();
+
+                if( ioPrcApp.SelectAction(sql, ref lstPrcApp ) == false)
+                {
+                    return false;
+                }
+
+                if( lstPrcApp.Count > 0 ){
+                    PrcApp.ConstructionCode = lstPrcApp[0].ConstructionCode;
+                    PrcApp.ApprovalCode = lstPrcApp[0].ApprovalCode;
+                    PrcApp.OrderNo = lstPrcApp[0].OrderNo;
+                    PrcApp.SeqNo = lstPrcApp[0].SeqNo;
+                }
+                else{
+                    PrcApp.ConstructionCode = m_ConstructionCode;                      // 工事番号
+                    PrcApp.ApprovalCode = m_ApprovalCode;	                            // 承認機能番号
+                    PrcApp.OrderNo = m_OrderNo;	                                    // 受付番号
+
+                    sql = ioPrcApp.CreatePrimarykeyString(m_ConstructionCode, m_ApprovalCode, m_OrderNo);
+                    PrcApp.SeqNo = ioPrcApp.SelectMaxSeqNoCount(sql) + 1;             // 枝番
+
+                }
+
+                PrcApp.PersonCode = CommonMotions.LoginUserData.PersonCode;        // 申請・承認者コード
+                PrcApp.PetitionApprovalDate = DateTime.Now;	                    // 承認日付
+                PrcApp.ApprovalStatus = nStatus;
+
+                // 承認データの登録
+                ClsApprovalPermission.CreatePetitionApproval(PrcApp);
+
+                return true ;
+            }
+            catch (Exception ex)
+            {
+                logger.ErrorFormat("システムエラー：{0}：{1}", CommonMotions.GetMethodName(), ex.Message);
+                return false;
+            }
+            finally
+            {
+                ioPrcApp.close();
+                ioPrcApp = null;
+            }
+        }
         #endregion
+
+        #endregion
     }
 }
Index: branches/src/ProcessManagement/ProcessManagement/Forms/DataEntry/Request/RequestSummaryList/FrmRequestSummaryList.cs
===================================================================
--- branches/src/ProcessManagement/ProcessManagement/Forms/DataEntry/Request/RequestSummaryList/FrmRequestSummaryList.cs	(revision 59)
+++ branches/src/ProcessManagement/ProcessManagement/Forms/DataEntry/Request/RequestSummaryList/FrmRequestSummaryList.cs	(revision 60)
@@ -48,6 +48,10 @@
             ���v,
         }
 
+        /// <summary>
+        /// �Q�ƃt���O
+        /// </summary>
+        private bool m_EditLock = false;
 
         /// <summary>
         /// �\���J�����idgvCompany�j
@@ -161,19 +165,6 @@
         }
 
         /// <summary>
-        /// ���p���[�U�[�^�C�v
-        /// </summary>
-        public enum UserType
-        {
-            Soumu = 0,
-            Koji,
-            Sekinin,
-            Boss,
-            Eigyo,
-            Sonota,
-        }
-
-        /// <summary>
         /// �\���{�^�������Ŏ擾����f�[�^����
         /// </summary>
         private enum ClickGetData
@@ -269,9 +260,6 @@
         /// </summary>
         private List<KeyValuePair<int, string>> m_KyouryokuKinDb = new List<KeyValuePair<int, string>>();
 
-        // ���[�U�[����
-        private UserType m_userType = UserType.Sonota;
-
         /// <summary>
         ///  ��ԍ�
         /// </summary>
@@ -322,6 +310,13 @@
             set { m_DataAddtionButton = value; }
         }
 
+        // ���[�U�[���
+        private ClsSecurityPermission.UserInfo m_UserInfo = new ClsSecurityPermission.UserInfo()
+        {
+            m_Type = CommonDefine.SecurityRankPos.NormalAuthority,
+            m_GeneralAffairsFlg = 0,
+            m_SecRange = ClsSecurityPermission.SecRangeType.InCharge
+        };
         #endregion
 
         #region �R���X�g���N�^
@@ -345,6 +340,17 @@
         }
         #endregion
 
+        #region �v���p�e�B
+        /// <summary>
+        /// �Q�ƃt���O
+        /// </summary>
+        public bool EditLock
+        {
+            get { return m_EditLock; }
+            set { m_EditLock = value; }
+        }
+        #endregion
+
         #region �~�{�^��
         /// <summary>
         /// �~�{�^����������
@@ -393,7 +399,7 @@
 
                 // �������Ȃ�
                 if ((m_Select_DataCount == 0 && dgv.Rows.Count == 0)
-                    || (m_userType == UserType.Sonota || m_userType == UserType.Eigyo))
+                    || (m_EditLock))
                 {
                     return;
                 }
@@ -432,8 +438,8 @@
             // �R���{�{�b�N�X�Z�b�g
             LoadTargetMonth(ref m_Payday);
 
-            // ���[�U�[����
-            CheckSecurity();
+            // ���[�U�����ݒ�
+            ClsSecurityPermission.SetUserType(m_UserInfo);
 
             // �����\��
             InitDataLoad();
@@ -445,10 +451,17 @@
             InitDisplayStyle(dgvProject);
 
             // ����S���҂̏ꍇ�́A�����\���͌���P��
-            if (m_userType == UserType.Koji)
+            if (m_UserInfo.m_Type == CommonDefine.SecurityRankPos.NormalAuthority)
             {
                 rdbProject.Checked = true;
+                rdbCompany.Checked = false;
             }
+            // �����S���́A�����\���͋ƎҒP��
+            if (m_UserInfo.m_GeneralAffairsFlg == 1)
+            {
+                rdbProject.Checked = false;
+                rdbCompany.Checked = true;
+            }
             m_viewTarget = rdbCompany.Checked == true ? 0 : 1;
 
             showView();
@@ -462,7 +475,6 @@
         }
         #endregion
 
-
         #region �t�H�[��KeyDown
         /// <summary>
         /// Entry�L�[�ł̈ړ�����
@@ -496,10 +508,6 @@
         /// <param name="e"></param>
         private void btnShowView_Click(object sender, EventArgs e)
         {
-            // ���֌W
-            if (m_userType == UserType.Sonota)
-                return;
-
             if (m_bChengeAns == true)
             {
                 if (MessageBox.Show("�f�[�^�ɕύX������܂��A�o�^�����ɑΏۂ�ύX���Ă�낵���ł����H�B", "�m�F"
@@ -640,7 +648,7 @@
                 sql.AppendLine("ifnull(Pdd.CNSTRPRICEEXIST,-1) as CNSTRPRICEEXIST, ");
                 sql.AppendLine("ifnull(Pdd.ApprovalPersonCode,0) as ApprovalPersonCode, ");
                 sql.AppendLine("ifnull(Picm.SealPrintName,'') as TantoNM, ");
-                sql.AppendLine(" DATE_FORMAT(ifnull(Pdd.ApprovalDate,'2001-01-01'), '%Y/%m/%d') as ApprovalDate, "); // 2001.01.01�͖��ݒ�l
+                sql.AppendLine(" DATE_FORMAT(ifnull(Pdd.ApprovalDate,'2001/01/01'), '%Y/%m/%d') as ApprovalDate, "); // 2001.01.01�͖��ݒ�l
                 sql.AppendLine(" ifnull(Pdd.ApprovalEndFlg,0) as ApprovalEndFlg, ");
                 sql.AppendLine(" ifnull(Cbi.SalesPersonCode,0) as SalesPersonCode, ");          /*�c�ƒS����*/
                 sql.AppendLine(" ifnull(Cbi.ConstructionPersonCode,0) as ConstructionPersonCode, ");   /*�H���S����*/
@@ -648,11 +656,11 @@
                 sql.AppendLine(" ifnull(Cbi.ConstructionInstructor,0) as ConstructionInstructor, ");    /*�H���w����*/
                 sql.AppendLine("  Picm2.DepartmentCode, ");         /*�H���S���ҕ����R�[�h*/
                 sql.AppendLine(" case ifnull(Cbi.PurchaseOrderMailingDate,'') 	when '' then '' ");
-                sql.AppendLine("												when '2001-01-01' then '�~'   ");
+                sql.AppendLine("												when '2001/01/01' then '�~'   ");
                 sql.AppendLine("												else '��'  ");
                 sql.AppendLine(" end as PurchaseOrderMailingDate,  ");
                 sql.AppendLine(" case ifnull(Cbi.PurchaseOrderReturnDate,'') 	when '' then '' ");
-                sql.AppendLine("												when '2001-01-01' then '�~'   ");
+                sql.AppendLine("												when '2001/01/01' then '�~'   ");
                 sql.AppendLine("												else '��'  ");
                 sql.AppendLine(" end as PurchaseOrderReturnDate,  ");
                 sql.AppendLine(" case ifnull(Pa.PERSONCODE,0) when 0 then case Bdd.CONSTRUCTIONCODE when 0 then '' ");
@@ -719,7 +727,7 @@
                     sql.AppendLine("order by Bdd.CONSTRUCTIONCODE,Scm.DISPLAYORDER,Bdd.SEQNO,Bdd.LINECOUNT ");
                 }
 
-                // �f�[�^�擾
+                // �f�[�^�擾�@���v�E���v���v�Z����ׁA�S�Ẵf�[�^���擾����
                 if (!IoBd.ExecuteReader(sql.ToString(), ref arData)) return false;
 
                 // �f�[�^�\��
@@ -823,7 +831,8 @@
                             }
                             else
                             {
-                                if (SekininApproval == false && m_userType == UserType.Sekinin)
+                                // ���F�Җ����F�ŏ������A�����҂̏ꍇ
+                                if (SekininApproval == false && (m_UserInfo.m_Type == CommonDefine.SecurityRankPos.LimitedAuthority || m_UserInfo.m_Type == CommonDefine.SecurityRankPos.FreeAuthority))
                                 {
                                     if (CommonMotions.LoginUserData.PersonCode == pair.ApprovalPerson)
                                     {
@@ -859,12 +868,12 @@
                             //�S���ҏ��F�ݒ�
                             dgv.Rows[icnt].Cells[(int)DispColumn.TantoShoninCode].Value = KojiTantoCode;
                             dgv.Rows[icnt].Cells[(int)DispColumn.TantoShonin].Value = KojiTanto;
-                        dgv.Rows[icnt].Cells[(int)DispColumn.TantoShonin].Style.ForeColor = Color.Gray;
+                            dgv.Rows[icnt].Cells[(int)DispColumn.TantoShonin].Style.ForeColor = Color.Gray;
 
-                        // �S���Җ����F�f�[�^
-                        int iDefaultDataCount = 0;
-                            if (!SetDefaultShonin(dgv, icnt, ConstrDepartmentCode, ref iDefaultDataCount)) return false;
-                        iShoninMaxCount = iShoninMaxCount < iDefaultDataCount ? iDefaultDataCount : iShoninMaxCount;
+                            // �S���Җ����F�f�[�^
+                            int iDefaultDataCount = 0;
+                                if (!SetDefaultShonin(dgv, icnt, ConstrDepartmentCode, ref iDefaultDataCount)) return false;
+                            iShoninMaxCount = iShoninMaxCount < iDefaultDataCount ? iDefaultDataCount : iShoninMaxCount;
                         }
                         else
                         {
@@ -875,51 +884,82 @@
 
                     }
 
-                    // ���e�X�g�p
-                    if (CommonMotions.LoginUserData.PersonCode == 88889988)
-                    {
-                        dgv.Rows[icnt].Cells[(int)DispColumn.TantoShonin].Value = "�e�X�g";
-                    }
-
                     dgv.Rows[icnt].Cells[(int)DispColumn.Bikou].Value = CommonMotions.cnvString(work[(int)ClickGetData.Bikou]);
 
                     // �����ɂ���ĕ\����\��
                     // �����l�͉�
+                    dgv.Rows[icnt].Visible = true;
                     dgv.Rows[icnt].Cells[(int)DispColumn.RowVisible].Value = 1;
 
                     // �s���ȊO
                     if (CommonMotions.cnvInt(work[(int)ClickGetData.CONSTRUCTIONCODE]) != 0)
-                    { 
-                        switch (m_userType)
+                    {
+                        // �s���ȊO�͈�U�s���ɂ���
+                        dgv.Rows[icnt].Visible = false;
+                        dgv.Rows[icnt].Cells[(int)DispColumn.RowVisible].Value = 0;
+
+                        // �����S��
+                        if (m_UserInfo.m_GeneralAffairsFlg == 1)
                         {
-                            case UserType.Eigyo:
-                                if (CommonMotions.LoginUserData.PersonCode != CommonMotions.cnvInt(work[(int)ClickGetData.SalesPersonCode]))
+                            // �ی�敪�͈͂Ɋ֌W�Ȃ��S�����̎Q�Ƃ��\�Ƃ��A�ҏW�\���ڂ͑���������͗��݂̂Ƃ���B
+                            dgv.Rows[icnt].Visible = true;
+                            dgv.Rows[icnt].Cells[(int)DispColumn.RowVisible].Value = 1;
+                        }
+                        // ���ʌ����̏ꍇ
+                        else if (m_UserInfo.m_Type == CommonDefine.SecurityRankPos.SpecialAuthority)
+                        {
+                            // �ی�敪�͈͂Ɋ֌W�Ȃ��S�����̎Q�Ƃ��\�Ƃ��A����������͗��ȊO�͕ҏW�\�Ƃ���B
+                            dgv.Rows[icnt].Visible = true;
+                            dgv.Rows[icnt].Cells[(int)DispColumn.RowVisible].Value = 1;
+                        }
+                        // �������A�����҂̏ꍇ
+                        else if (m_UserInfo.m_Type == CommonDefine.SecurityRankPos.LimitedAuthority || m_UserInfo.m_Type == CommonDefine.SecurityRankPos.FreeAuthority)
+                        {
+                            // �Q�ƕ����ɂ��邩�̃`�F�b�N
+                            foreach (PersonDepartmentMaster RefDepRec in CommonMotions.LoginUserDepartment)
+                            {
+                                // ������������ێ����镔���̍H���̂ݕ\������
+                                if (RefDepRec.DepartmentCode != CommonMotions.cnvInt(work[(int)ClickGetData.DepartmentCode]))
                                 {
-                                    dgv.Rows[icnt].Visible = false;
-                                    dgv.Rows[icnt].Cells[(int)DispColumn.RowVisible].Value = 0;
+                                    dgv.Rows[icnt].Visible = true;
+                                    dgv.Rows[icnt].Cells[(int)DispColumn.RowVisible].Value = 1;
                                 }
-                                break;
-                            case UserType.Koji:
-                                if (CommonMotions.LoginUserData.PersonCode != CommonMotions.cnvInt(work[(int)ClickGetData.ConstructionPersonCode])
-                                    && CommonMotions.LoginUserData.PersonCode != CommonMotions.cnvInt(work[(int)ClickGetData.ConstrSubPersonCode])
-                                    && CommonMotions.LoginUserData.PersonCode != CommonMotions.cnvInt(work[(int)ClickGetData.ConstructionInstructor]))
+                            }
+                        }
+                        // �S���҂̏ꍇ
+                        else if (m_UserInfo.m_Type == CommonDefine.SecurityRankPos.NormalAuthority)
+                        {
+                            if (m_UserInfo.m_SecRange == ClsSecurityPermission.SecRangeType.InCharge)
+                            {
+                                // �c�ƒS��
+                                if (CommonMotions.LoginUserData.PersonCode == CommonMotions.cnvInt(work[(int)ClickGetData.SalesPersonCode]))
                                 {
-                                    dgv.Rows[icnt].Visible = false;
-                                    dgv.Rows[icnt].Cells[(int)DispColumn.RowVisible].Value = 0;
+                                    dgv.Rows[icnt].Visible = true;
+                                    dgv.Rows[icnt].Cells[(int)DispColumn.RowVisible].Value = 1;
                                 }
-                                break;
-                            case UserType.Sekinin:
-                                // ������������ێ����镔���̍H���̂ݕ\������@���w�H���S���ҕ��������O�C�����[�U���������x
-                                if (CommonMotions.LoginUserData.DepartmentCode != CommonMotions.cnvInt(work[(int)ClickGetData.DepartmentCode]))
+                                // �H���S��
+                                if (CommonMotions.LoginUserData.PersonCode == CommonMotions.cnvInt(work[(int)ClickGetData.ConstructionPersonCode])
+                                    || CommonMotions.LoginUserData.PersonCode == CommonMotions.cnvInt(work[(int)ClickGetData.ConstrSubPersonCode])
+                                    || CommonMotions.LoginUserData.PersonCode == CommonMotions.cnvInt(work[(int)ClickGetData.ConstructionInstructor]))
                                 {
-                                    dgv.Rows[icnt].Visible = false;
-                                    dgv.Rows[icnt].Cells[(int)DispColumn.RowVisible].Value = 0;
+                                    dgv.Rows[icnt].Visible = true;
+                                    dgv.Rows[icnt].Cells[(int)DispColumn.RowVisible].Value = 1;
                                 }
-                                break;
-                            case UserType.Sonota:
-                                dgv.Rows[icnt].Visible = false;
-                                dgv.Rows[icnt].Cells[(int)DispColumn.RowVisible].Value = 0;
-                                break;
+                            }
+                            else if (m_UserInfo.m_SecRange == ClsSecurityPermission.SecRangeType.OneDepartment)
+                            {
+                                // �Q�ƕ����ɂ��邩�̃`�F�b�N
+                                foreach (PersonDepartmentMaster RefDepRec in CommonMotions.LoginUserDepartment)
+                                {
+                                    // ������������ێ����镔���̍H���̂ݕ\������
+                                    if (RefDepRec.DepartmentCode != CommonMotions.cnvInt(work[(int)ClickGetData.DepartmentCode]))
+                                    {
+                                        dgv.Rows[icnt].Visible = true;
+                                        dgv.Rows[icnt].Cells[(int)DispColumn.RowVisible].Value = 1;
+                                    }
+                                }
+                            }
+
                         }
                     }
 
@@ -928,8 +968,9 @@
                         // �ŏI���F�҂ɂ���ď��F����Ă���ꍇ�́A�S���ڕҏW�s��
                         dgv.Rows[icnt].ReadOnly = true;
                     }
-                    else if ((ApprovalPerson == true && m_userType == UserType.Koji)
-                        || (SekininApproval == true && m_userType == UserType.Sekinin))
+                    else if ((ApprovalPerson == true && m_UserInfo.m_Type == CommonDefine.SecurityRankPos.NormalAuthority)
+                          || (SekininApproval == true && m_UserInfo.m_Type == CommonDefine.SecurityRankPos.LimitedAuthority)
+                          || (SekininApproval == true && m_UserInfo.m_Type == CommonDefine.SecurityRankPos.FreeAuthority))
                     {
                         // �H���S���҂��S���ҏ��F�����s���Ă���ꍇ�A�܂��́@�ӔC�҂����g�̏��F�����s���Ă���ꍇ�́A�H���S�����͗��ҏW�s��
                         dgv.Rows[icnt].Cells[(int)DispColumn.KojiSeikyu].ReadOnly = true;
@@ -3351,8 +3392,8 @@
             else if (e.ColumnIndex >= (int)DispColumn.TantoShonin && e.ColumnIndex < (int)DispColumn.Bikou && TargetRowtype == 0)
             {
                 // ���F��
-                // ���F�o���Ȃ��l���ɂ͔������Ȃ�
-                if (m_userType == UserType.Eigyo || m_userType == UserType.Soumu || m_userType == UserType.Sonota)
+                // ���F�o���Ȃ��l���i�����S���j�ɂ͔������Ȃ�
+                if (m_UserInfo.m_GeneralAffairsFlg == 1)
                 {
                     return;
                 }
Index: branches/src/ProcessManagement/ProcessManagement/Forms/DataEntry/Request/RequestSummaryList/FrmRequestSummaryList.designer.cs
===================================================================
--- branches/src/ProcessManagement/ProcessManagement/Forms/DataEntry/Request/RequestSummaryList/FrmRequestSummaryList.designer.cs	(revision 59)
+++ branches/src/ProcessManagement/ProcessManagement/Forms/DataEntry/Request/RequestSummaryList/FrmRequestSummaryList.designer.cs	(revision 60)
@@ -30,8 +30,6 @@
         {
             System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle1 = new System.Windows.Forms.DataGridViewCellStyle();
             System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle27 = new System.Windows.Forms.DataGridViewCellStyle();
-            System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle28 = new System.Windows.Forms.DataGridViewCellStyle();
-            System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle58 = new System.Windows.Forms.DataGridViewCellStyle();
             System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle2 = new System.Windows.Forms.DataGridViewCellStyle();
             System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle3 = new System.Windows.Forms.DataGridViewCellStyle();
             System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle4 = new System.Windows.Forms.DataGridViewCellStyle();
@@ -57,6 +55,8 @@
             System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle24 = new System.Windows.Forms.DataGridViewCellStyle();
             System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle25 = new System.Windows.Forms.DataGridViewCellStyle();
             System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle26 = new System.Windows.Forms.DataGridViewCellStyle();
+            System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle28 = new System.Windows.Forms.DataGridViewCellStyle();
+            System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle58 = new System.Windows.Forms.DataGridViewCellStyle();
             System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle29 = new System.Windows.Forms.DataGridViewCellStyle();
             System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle30 = new System.Windows.Forms.DataGridViewCellStyle();
             System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle31 = new System.Windows.Forms.DataGridViewCellStyle();
@@ -92,7 +92,6 @@
             this.btnDeleteProject = new System.Windows.Forms.Button();
             this.btnDeleteCompany = new System.Windows.Forms.Button();
             this.btnAddCompany = new System.Windows.Forms.Button();
-            this.btnOther = new System.Windows.Forms.Button();
             this.btnAddProject = new System.Windows.Forms.Button();
             this.panel1 = new System.Windows.Forms.Panel();
             this.label10 = new System.Windows.Forms.Label();
@@ -111,7 +110,6 @@
             this.label3 = new System.Windows.Forms.Label();
             this.label4 = new System.Windows.Forms.Label();
             this.dgvCompany = new ProcessManagement.Forms.CustomControls.DataGridViewEX();
-            this.dgvProject = new ProcessManagement.Forms.CustomControls.DataGridViewEX();
             this.Column135 = new System.Windows.Forms.DataGridViewTextBoxColumn();
             this.Column133 = new System.Windows.Forms.DataGridViewTextBoxColumn();
             this.Column71 = new System.Windows.Forms.DataGridViewTextBoxColumn();
@@ -198,6 +196,7 @@
             this.Column112 = new System.Windows.Forms.DataGridViewTextBoxColumn();
             this.Column20 = new System.Windows.Forms.DataGridViewTextBoxColumn();
             this.Column64 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.dgvProject = new ProcessManagement.Forms.CustomControls.DataGridViewEX();
             this.Column136 = new System.Windows.Forms.DataGridViewTextBoxColumn();
             this.Column134 = new System.Windows.Forms.DataGridViewTextBoxColumn();
             this.dataGridViewTextBoxColumn1 = new System.Windows.Forms.DataGridViewTextBoxColumn();
@@ -341,7 +340,7 @@
             this.btnDeleteProject.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(255)))), ((int)(((byte)(255)))), ((int)(((byte)(128)))));
             this.btnDeleteProject.Font = new System.Drawing.Font("ＭＳ 明朝", 12F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(128)));
             this.btnDeleteProject.ForeColor = System.Drawing.Color.Black;
-            this.btnDeleteProject.Location = new System.Drawing.Point(683, 803);
+            this.btnDeleteProject.Location = new System.Drawing.Point(513, 803);
             this.btnDeleteProject.Margin = new System.Windows.Forms.Padding(4);
             this.btnDeleteProject.Name = "btnDeleteProject";
             this.btnDeleteProject.Size = new System.Drawing.Size(154, 38);
@@ -356,7 +355,7 @@
             this.btnDeleteCompany.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(255)))), ((int)(((byte)(128)))), ((int)(((byte)(255)))));
             this.btnDeleteCompany.Font = new System.Drawing.Font("ＭＳ 明朝", 12F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(128)));
             this.btnDeleteCompany.ForeColor = System.Drawing.Color.Black;
-            this.btnDeleteCompany.Location = new System.Drawing.Point(361, 803);
+            this.btnDeleteCompany.Location = new System.Drawing.Point(191, 803);
             this.btnDeleteCompany.Margin = new System.Windows.Forms.Padding(4);
             this.btnDeleteCompany.Name = "btnDeleteCompany";
             this.btnDeleteCompany.Size = new System.Drawing.Size(154, 38);
@@ -371,7 +370,7 @@
             this.btnAddCompany.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(128)))), ((int)(((byte)(255)))), ((int)(((byte)(128)))));
             this.btnAddCompany.Font = new System.Drawing.Font("ＭＳ 明朝", 12F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(128)));
             this.btnAddCompany.ForeColor = System.Drawing.Color.Black;
-            this.btnAddCompany.Location = new System.Drawing.Point(199, 803);
+            this.btnAddCompany.Location = new System.Drawing.Point(29, 803);
             this.btnAddCompany.Margin = new System.Windows.Forms.Padding(4);
             this.btnAddCompany.Name = "btnAddCompany";
             this.btnAddCompany.Size = new System.Drawing.Size(154, 38);
@@ -380,20 +379,6 @@
             this.btnAddCompany.UseVisualStyleBackColor = false;
             this.btnAddCompany.Click += new System.EventHandler(this.btnAddCompany_Click);
             // 
-            // btnOther
-            // 
-            this.btnOther.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left)));
-            this.btnOther.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(128)))), ((int)(((byte)(255)))), ((int)(((byte)(255)))));
-            this.btnOther.Font = new System.Drawing.Font("ＭＳ 明朝", 12F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(128)));
-            this.btnOther.ForeColor = System.Drawing.Color.Black;
-            this.btnOther.Location = new System.Drawing.Point(38, 803);
-            this.btnOther.Margin = new System.Windows.Forms.Padding(4);
-            this.btnOther.Name = "btnOther";
-            this.btnOther.Size = new System.Drawing.Size(154, 38);
-            this.btnOther.TabIndex = 54;
-            this.btnOther.Text = "その他画面";
-            this.btnOther.UseVisualStyleBackColor = false;
-            // 
             // btnAddProject
             // 
             this.btnAddProject.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left)));
@@ -400,7 +385,7 @@
             this.btnAddProject.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(255)))), ((int)(((byte)(128)))), ((int)(((byte)(128)))));
             this.btnAddProject.Font = new System.Drawing.Font("ＭＳ 明朝", 12F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(128)));
             this.btnAddProject.ForeColor = System.Drawing.Color.Black;
-            this.btnAddProject.Location = new System.Drawing.Point(522, 803);
+            this.btnAddProject.Location = new System.Drawing.Point(352, 803);
             this.btnAddProject.Margin = new System.Windows.Forms.Padding(4);
             this.btnAddProject.Name = "btnAddProject";
             this.btnAddProject.Size = new System.Drawing.Size(154, 38);
@@ -760,139 +745,6 @@
             this.dgvCompany.CellValueChanged += new System.Windows.Forms.DataGridViewCellEventHandler(this.DataGridView_CellValueChanged);
             this.dgvCompany.CurrentCellDirtyStateChanged += new System.EventHandler(this.DataGridView_CurrentCellDirtyStateChanged);
             // 
-            // dgvProject
-            // 
-            this.dgvProject.AllowUserToAddRows = false;
-            this.dgvProject.AllowUserToDeleteRows = false;
-            this.dgvProject.AllowUserToResizeRows = false;
-            this.dgvProject.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom) 
-            | System.Windows.Forms.AnchorStyles.Left) 
-            | System.Windows.Forms.AnchorStyles.Right)));
-            this.dgvProject.BackgroundColor = System.Drawing.Color.FromArgb(((int)(((byte)(224)))), ((int)(((byte)(224)))), ((int)(((byte)(224)))));
-            this.dgvProject.BorderStyle = System.Windows.Forms.BorderStyle.Fixed3D;
-            dataGridViewCellStyle28.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleCenter;
-            dataGridViewCellStyle28.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(192)))), ((int)(((byte)(255)))), ((int)(((byte)(192)))));
-            dataGridViewCellStyle28.Font = new System.Drawing.Font("ＭＳ 明朝", 11.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(128)));
-            dataGridViewCellStyle28.WrapMode = System.Windows.Forms.DataGridViewTriState.True;
-            this.dgvProject.ColumnHeadersDefaultCellStyle = dataGridViewCellStyle28;
-            this.dgvProject.ColumnHeadersHeight = 45;
-            this.dgvProject.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.DisableResizing;
-            this.dgvProject.Columns.AddRange(new System.Windows.Forms.DataGridViewColumn[] {
-            this.Column136,
-            this.Column134,
-            this.dataGridViewTextBoxColumn1,
-            this.Column63,
-            this.Column35,
-            this.Project_Column1,
-            this.Column90,
-            this.Column51,
-            this.Project_Column2,
-            this.Project_Column3,
-            this.Project_Column4,
-            this.Project_Column5,
-            this.Project_Column6,
-            this.Project_Column7,
-            this.Project_Column8,
-            this.Project_Column9,
-            this.Project_Column10,
-            this.Project_Column11,
-            this.Project_Column12,
-            this.Project_Column13,
-            this.Project_Column14,
-            this.Project_Column15,
-            this.Project_Column16,
-            this.Project_Column17,
-            this.Project_Column18,
-            this.Project_Column19,
-            this.Column100,
-            this.KyouryokuKin_Pro,
-            this.Project_Column21,
-            this.Project_Column22,
-            this.Project_Column23,
-            this.Column50,
-            this.Project_Column24,
-            this.Column78,
-            this.Column52,
-            this.Project_Column25,
-            this.Column79,
-            this.Column113,
-            this.Column114,
-            this.Column53,
-            this.Project_Column26,
-            this.Column81,
-            this.Column115,
-            this.Column116,
-            this.Column54,
-            this.Project_Column27,
-            this.Column82,
-            this.Column117,
-            this.Column118,
-            this.Column55,
-            this.Project_Column28,
-            this.Column83,
-            this.Column119,
-            this.Column120,
-            this.Column56,
-            this.Project_Column29,
-            this.Column84,
-            this.Column121,
-            this.Column122,
-            this.Column57,
-            this.Project_Column30,
-            this.Column80,
-            this.Column123,
-            this.Column124,
-            this.Column58,
-            this.Project_Column31,
-            this.Column85,
-            this.Column125,
-            this.Column126,
-            this.Column59,
-            this.Project_Column32,
-            this.Column86,
-            this.Column127,
-            this.Column128,
-            this.Column60,
-            this.Project_Column33,
-            this.Column87,
-            this.Column129,
-            this.Column130,
-            this.Column61,
-            this.Project_Column34,
-            this.Column88,
-            this.Column131,
-            this.Column132,
-            this.Column21,
-            this.Column77});
-            dataGridViewCellStyle58.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleLeft;
-            dataGridViewCellStyle58.BackColor = System.Drawing.SystemColors.Window;
-            dataGridViewCellStyle58.Font = new System.Drawing.Font("ＭＳ 明朝", 11.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(128)));
-            dataGridViewCellStyle58.ForeColor = System.Drawing.SystemColors.ControlText;
-            dataGridViewCellStyle58.SelectionBackColor = System.Drawing.Color.LightSeaGreen;
-            dataGridViewCellStyle58.SelectionForeColor = System.Drawing.SystemColors.HighlightText;
-            dataGridViewCellStyle58.WrapMode = System.Windows.Forms.DataGridViewTriState.False;
-            this.dgvProject.DefaultCellStyle = dataGridViewCellStyle58;
-            this.dgvProject.EditMode = System.Windows.Forms.DataGridViewEditMode.EditOnEnter;
-            this.dgvProject.EnableHeadersVisualStyles = false;
-            this.dgvProject.Location = new System.Drawing.Point(30, 141);
-            this.dgvProject.Margin = new System.Windows.Forms.Padding(4);
-            this.dgvProject.MultiSelect = false;
-            this.dgvProject.Name = "dgvProject";
-            this.dgvProject.RowHeadersVisible = false;
-            this.dgvProject.RowHeadersWidth = 20;
-            this.dgvProject.RowHeadersWidthSizeMode = System.Windows.Forms.DataGridViewRowHeadersWidthSizeMode.DisableResizing;
-            this.dgvProject.RowTemplate.Height = 21;
-            this.dgvProject.SelectionMode = System.Windows.Forms.DataGridViewSelectionMode.CellSelect;
-            this.dgvProject.Size = new System.Drawing.Size(1522, 655);
-            this.dgvProject.TabIndex = 57;
-            this.dgvProject.Visible = false;
-            this.dgvProject.CellBeginEdit += new System.Windows.Forms.DataGridViewCellCancelEventHandler(this.DataGridView_CellBeginEdit);
-            this.dgvProject.CellDoubleClick += new System.Windows.Forms.DataGridViewCellEventHandler(this.DataGridView_CellDoubleClick);
-            this.dgvProject.CellFormatting += new System.Windows.Forms.DataGridViewCellFormattingEventHandler(this.DataGridView_CellFormatting);
-            this.dgvProject.CellValidated += new System.Windows.Forms.DataGridViewCellEventHandler(this.DataGridView_CellValidated);
-            this.dgvProject.CellValueChanged += new System.Windows.Forms.DataGridViewCellEventHandler(this.DataGridView_CellValueChanged);
-            this.dgvProject.CurrentCellDirtyStateChanged += new System.EventHandler(this.DataGridView_CurrentCellDirtyStateChanged);
-            // 
             // Column135
             // 
             this.Column135.HeaderText = "CompanyDispOrder";
@@ -1472,6 +1324,139 @@
             this.Column64.Name = "Column64";
             this.Column64.Visible = false;
             // 
+            // dgvProject
+            // 
+            this.dgvProject.AllowUserToAddRows = false;
+            this.dgvProject.AllowUserToDeleteRows = false;
+            this.dgvProject.AllowUserToResizeRows = false;
+            this.dgvProject.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom) 
+            | System.Windows.Forms.AnchorStyles.Left) 
+            | System.Windows.Forms.AnchorStyles.Right)));
+            this.dgvProject.BackgroundColor = System.Drawing.Color.FromArgb(((int)(((byte)(224)))), ((int)(((byte)(224)))), ((int)(((byte)(224)))));
+            this.dgvProject.BorderStyle = System.Windows.Forms.BorderStyle.Fixed3D;
+            dataGridViewCellStyle28.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleCenter;
+            dataGridViewCellStyle28.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(192)))), ((int)(((byte)(255)))), ((int)(((byte)(192)))));
+            dataGridViewCellStyle28.Font = new System.Drawing.Font("ＭＳ 明朝", 11.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(128)));
+            dataGridViewCellStyle28.WrapMode = System.Windows.Forms.DataGridViewTriState.True;
+            this.dgvProject.ColumnHeadersDefaultCellStyle = dataGridViewCellStyle28;
+            this.dgvProject.ColumnHeadersHeight = 45;
+            this.dgvProject.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.DisableResizing;
+            this.dgvProject.Columns.AddRange(new System.Windows.Forms.DataGridViewColumn[] {
+            this.Column136,
+            this.Column134,
+            this.dataGridViewTextBoxColumn1,
+            this.Column63,
+            this.Column35,
+            this.Project_Column1,
+            this.Column90,
+            this.Column51,
+            this.Project_Column2,
+            this.Project_Column3,
+            this.Project_Column4,
+            this.Project_Column5,
+            this.Project_Column6,
+            this.Project_Column7,
+            this.Project_Column8,
+            this.Project_Column9,
+            this.Project_Column10,
+            this.Project_Column11,
+            this.Project_Column12,
+            this.Project_Column13,
+            this.Project_Column14,
+            this.Project_Column15,
+            this.Project_Column16,
+            this.Project_Column17,
+            this.Project_Column18,
+            this.Project_Column19,
+            this.Column100,
+            this.KyouryokuKin_Pro,
+            this.Project_Column21,
+            this.Project_Column22,
+            this.Project_Column23,
+            this.Column50,
+            this.Project_Column24,
+            this.Column78,
+            this.Column52,
+            this.Project_Column25,
+            this.Column79,
+            this.Column113,
+            this.Column114,
+            this.Column53,
+            this.Project_Column26,
+            this.Column81,
+            this.Column115,
+            this.Column116,
+            this.Column54,
+            this.Project_Column27,
+            this.Column82,
+            this.Column117,
+            this.Column118,
+            this.Column55,
+            this.Project_Column28,
+            this.Column83,
+            this.Column119,
+            this.Column120,
+            this.Column56,
+            this.Project_Column29,
+            this.Column84,
+            this.Column121,
+            this.Column122,
+            this.Column57,
+            this.Project_Column30,
+            this.Column80,
+            this.Column123,
+            this.Column124,
+            this.Column58,
+            this.Project_Column31,
+            this.Column85,
+            this.Column125,
+            this.Column126,
+            this.Column59,
+            this.Project_Column32,
+            this.Column86,
+            this.Column127,
+            this.Column128,
+            this.Column60,
+            this.Project_Column33,
+            this.Column87,
+            this.Column129,
+            this.Column130,
+            this.Column61,
+            this.Project_Column34,
+            this.Column88,
+            this.Column131,
+            this.Column132,
+            this.Column21,
+            this.Column77});
+            dataGridViewCellStyle58.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleLeft;
+            dataGridViewCellStyle58.BackColor = System.Drawing.SystemColors.Window;
+            dataGridViewCellStyle58.Font = new System.Drawing.Font("ＭＳ 明朝", 11.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(128)));
+            dataGridViewCellStyle58.ForeColor = System.Drawing.SystemColors.ControlText;
+            dataGridViewCellStyle58.SelectionBackColor = System.Drawing.Color.LightSeaGreen;
+            dataGridViewCellStyle58.SelectionForeColor = System.Drawing.SystemColors.HighlightText;
+            dataGridViewCellStyle58.WrapMode = System.Windows.Forms.DataGridViewTriState.False;
+            this.dgvProject.DefaultCellStyle = dataGridViewCellStyle58;
+            this.dgvProject.EditMode = System.Windows.Forms.DataGridViewEditMode.EditOnEnter;
+            this.dgvProject.EnableHeadersVisualStyles = false;
+            this.dgvProject.Location = new System.Drawing.Point(30, 141);
+            this.dgvProject.Margin = new System.Windows.Forms.Padding(4);
+            this.dgvProject.MultiSelect = false;
+            this.dgvProject.Name = "dgvProject";
+            this.dgvProject.RowHeadersVisible = false;
+            this.dgvProject.RowHeadersWidth = 20;
+            this.dgvProject.RowHeadersWidthSizeMode = System.Windows.Forms.DataGridViewRowHeadersWidthSizeMode.DisableResizing;
+            this.dgvProject.RowTemplate.Height = 21;
+            this.dgvProject.SelectionMode = System.Windows.Forms.DataGridViewSelectionMode.CellSelect;
+            this.dgvProject.Size = new System.Drawing.Size(1522, 655);
+            this.dgvProject.TabIndex = 57;
+            this.dgvProject.Visible = false;
+            this.dgvProject.CellBeginEdit += new System.Windows.Forms.DataGridViewCellCancelEventHandler(this.DataGridView_CellBeginEdit);
+            this.dgvProject.CellDoubleClick += new System.Windows.Forms.DataGridViewCellEventHandler(this.DataGridView_CellDoubleClick);
+            this.dgvProject.CellFormatting += new System.Windows.Forms.DataGridViewCellFormattingEventHandler(this.DataGridView_CellFormatting);
+            this.dgvProject.CellValidated += new System.Windows.Forms.DataGridViewCellEventHandler(this.DataGridView_CellValidated);
+            this.dgvProject.CellValueChanged += new System.Windows.Forms.DataGridViewCellEventHandler(this.DataGridView_CellValueChanged);
+            this.dgvProject.CurrentCellDirtyStateChanged += new System.EventHandler(this.DataGridView_CurrentCellDirtyStateChanged);
+            // 
             // Column136
             // 
             this.Column136.HeaderText = "CompanyDispOrder";
@@ -2065,7 +2050,6 @@
             this.Controls.Add(this.panel1);
             this.Controls.Add(this.btnAddProject);
             this.Controls.Add(this.groupBoxEx1);
-            this.Controls.Add(this.btnOther);
             this.Controls.Add(this.btnAddCompany);
             this.Controls.Add(this.btnDeleteCompany);
             this.Controls.Add(this.btnDeleteProject);
@@ -2112,7 +2096,6 @@
         private System.Windows.Forms.Button btnDeleteProject;
         private System.Windows.Forms.Button btnDeleteCompany;
         private System.Windows.Forms.Button btnAddCompany;
-        private System.Windows.Forms.Button btnOther;
         private System.Windows.Forms.Button btnShowView;
         private CustomControls.GroupBoxEx groupBoxEx1;
         private CustomControls.DataGridViewEX dgvProject;
Index: branches/src/ProcessManagement/ProcessManagement/Forms/DataEntry/Request/RequestSummaryList/FrmRequestSummaryListAuxiliary.cs
===================================================================
--- branches/src/ProcessManagement/ProcessManagement/Forms/DataEntry/Request/RequestSummaryList/FrmRequestSummaryListAuxiliary.cs	(revision 59)
+++ branches/src/ProcessManagement/ProcessManagement/Forms/DataEntry/Request/RequestSummaryList/FrmRequestSummaryListAuxiliary.cs	(revision 60)
@@ -42,124 +42,6 @@
         #region �v���p�e�B
         #endregion
 
-
-        #region �Z�L�����e�B����
-        /// <summary>
-        /// �Z�L�����e�B����
-        /// </summary>
-        /// <param name="strSQL"></param>
-        private void CheckSecurity()
-        {
-            try
-            {
-                // �V�X�e�������ɂ���ăf�[�^�A�N�Z�X�ɐ���������
-                if (CommonMotions.LoginUserData.SecurityManagement == CommonDefine.AdminSecurityManagement
-                 || CommonMotions.LoginUserData.SecurityManagement == CommonDefine.SystemManageDiv[(int)CommonDefine.SysManaDivNo.PresidentAuthority].Key)
-                {
-                    // �ō��@���Ǘ��ҁE�V�X�e���Ǘ��ҁi���ׂđΏہj
-                    m_userType = UserType.Boss;
-                }
-                else if (CommonMotions.LoginUserData.SecurityManagement == CommonDefine.SystemManageDiv[(int)CommonDefine.SysManaDivNo.SupervisorAuthority].Key
-                      || CommonMotions.LoginUserData.SecurityManagement == CommonDefine.SystemManageDiv[(int)CommonDefine.SysManaDivNo.SuperiorAuthority].Key)
-                {
-                    // �����ӔC�ҁE�������i�@�\�����j
-                    // �������̂�
-                    m_userType = UserType.Sekinin;
-
-                    // ������
-                    if (CommonMotions.LoginUserData.DepartmentCode == CommonDefine.s_GeneralAffairsDevision)
-                    {
-                        m_userType = UserType.Soumu;
-                    }
-
-                }
-                else if (CommonMotions.LoginUserData.SecurityManagement == CommonDefine.SystemManageDiv[(int)CommonDefine.SysManaDivNo.UserAuthority].Key)
-                {
-                    // ��ʁi�@�\�����j
-                    // ������
-                    if (CommonMotions.LoginUserData.DepartmentCode == CommonDefine.s_GeneralAffairsDevision)
-                    {
-                        m_userType = UserType.Soumu;
-                    }
-                    else
-                    {
-                        // ���f�[�^�̂�
-                        m_userType = UserType.Sonota;
-                        CheckSalesPerson(ref m_userType);
-                    }
-                }
-            }
-            catch (Exception ex)
-            {
-                logger.ErrorFormat("�V�X�e���G���[�F{0}�F{1}", ex.Message);
-            }
-        }
-
-        /// <summary>
-        /// �c��or�H���S���҂���������
-        /// </summary>
-        /// <returns></returns>
-        private void CheckSalesPerson(ref UserType myType)
-        {
-            IOBillingData IoBd = new IOBillingData();
-            ArrayList arData = new ArrayList();
-
-            StringBuilder sql;
-
-            try
-            {
-                // �I��Ώی��̑ޔ�
-                m_Select_TargetDate = CommonMotions.cnvInt(cmbTargetMonth.SelectedValue);
-
-                // SQL�쐬
-                sql = new StringBuilder();
-                sql.AppendLine("select   ");
-                sql.AppendLine(" ifnull(Cbi.SalesPersonCode,0) as  SalesPersonCode, ");
-                sql.AppendLine(" ifnull(Cbi.ConstructionPersonCode,0) as ConstructionPersonCode, ");
-                sql.AppendLine(" ifnull(Cbi.ConstrSubPersonCode,0) as ConstrSubPersonCode,    ");
-                sql.AppendLine(" ifnull(Cbi.ConstructionInstructor,0) as ConstructionInstructor ");
-                sql.AppendLine("from BillingData as Bd left join (BillingDataDetail as Bdd left join ConstructionBaseInfo as Cbi on Bdd.CONSTRUCTIONCODE = Cbi.CONSTRUCTIONCODE)  ");
-                sql.AppendLine("					on Bd.COMPANYCODE = BdD.COMPANYCODE   ");
-                sql.AppendLine("                    and Bd.TARGETDATE = BdD.TARGETDATE   ");
-                sql.AppendLine("                    and Bd.SEQNO = BdD.SEQNO  ");
-                sql.AppendFormat("where Bd.TARGETDATE = {0} ", m_Select_TargetDate);
-                sql.AppendLine("group by Cbi.SalesPersonCode ,Cbi.ConstructionPersonCode,Cbi.ConstrSubPersonCode,Cbi.ConstructionInstructor ");
-
-                // �f�[�^�擾
-                if (!IoBd.ExecuteReader(sql.ToString(), ref arData)) throw new Exception("�S���Ҋm�F�f�[�^�擾���s");
-
-                foreach (object[] work in arData)
-                {
-                    if (CommonMotions.cnvInt(work[0]) == CommonMotions.LoginUserData.PersonCode)
-                    {
-                        myType = UserType.Eigyo;
-                    }
-
-                    if (CommonMotions.cnvInt(work[1]) == CommonMotions.LoginUserData.PersonCode
-                    || CommonMotions.cnvInt(work[2]) == CommonMotions.LoginUserData.PersonCode
-                    || CommonMotions.cnvInt(work[3]) == CommonMotions.LoginUserData.PersonCode)
-                    {
-                        myType = UserType.Koji;
-                        break;
-                    }
-                }
-
-            }
-            catch (Exception ex)
-            {
-                logger.ErrorFormat("�V�X�e���G���[�F{0}�F{1}", CommonMotions.GetMethodName(), ex.Message);
-            }
-            finally
-            {
-                IoBd = null;
-            }
-
-        }
-
-        #endregion
-
-
-
         #region �����l
         /// <summary>
         /// �����l
@@ -503,6 +385,7 @@
             }
         }
         #endregion
+
         #region �{�^��������s��
         /// <summary>
         /// �{�^��������s���i�f�[�^�����ɂ��ω��j
@@ -509,9 +392,6 @@
         /// </summary>
         private void controlButton_DataCount()
         {
-            if (m_userType == UserType.Soumu || m_userType == UserType.Eigyo || m_userType == UserType.Sonota)
-                return;
-
             DataGridView dgv = getShowingView();
 
             DataGridViewRow[] Rows = dgv.Rows.Cast<DataGridViewRow>().Where(x => CommonMotions.cnvInt(x.Cells[(int)DispColumn.RowType].Value) == 0
@@ -527,8 +407,8 @@
                 btnAddProject.Enabled = true;
                 btnDeleteProject.Enabled = true;
             }
+        }
 
-        }
         /// <summary>
         /// �{�^��������s��
         /// </summary>
@@ -537,36 +417,39 @@
             try
             {
                 // ���[�U���̃{�^������
-                switch (m_userType)
+                // �����S��
+                if (m_UserInfo.m_GeneralAffairsFlg == 1)
                 {
-                    case UserType.Soumu:
-                        btnAddCompany.Enabled = true;
-                        btnDeleteCompany.Enabled = true;
-                        btnAddProject.Enabled = false;
-                        btnDeleteProject.Enabled = false;
-                        break;
-                    case UserType.Koji:
-                    case UserType.Sekinin:
-                        btnAddCompany.Enabled = false;
-                        btnDeleteCompany.Enabled = false;
-                        btnAddProject.Enabled = true;
-                        btnDeleteProject.Enabled = true;
-                        break;
-                    case UserType.Boss:
-                        btnAddCompany.Enabled = true;
-                        btnDeleteCompany.Enabled = true;
-                        btnAddProject.Enabled = true;
-                        btnDeleteProject.Enabled = true;
-                        break;
-                    case UserType.Eigyo:
-                    case UserType.Sonota:
-                        btnAddCompany.Enabled = false;
-                        btnDeleteCompany.Enabled = false;
-                        btnAddProject.Enabled = false;
-                        btnDeleteProject.Enabled = false;
-                        break;
+                    btnAddCompany.Enabled = true;
+                    btnDeleteCompany.Enabled = true;
+                    btnAddProject.Enabled = true;
+                    btnDeleteProject.Enabled = true;
+                }
+                // �S���҂̏ꍇ
+                else if (m_UserInfo.m_Type == CommonDefine.SecurityRankPos.NormalAuthority)
+                {
+                    btnAddCompany.Enabled = false;
+                    btnDeleteCompany.Enabled = false;
+                    btnAddProject.Enabled = true;
+                    btnDeleteProject.Enabled = true;
+                }
+                // �������A�����҂̏ꍇ
+                else if (m_UserInfo.m_Type == CommonDefine.SecurityRankPos.LimitedAuthority || m_UserInfo.m_Type == CommonDefine.SecurityRankPos.FreeAuthority)
+                {
+                    btnAddCompany.Enabled = false;
+                    btnDeleteCompany.Enabled = false;
+                    btnAddProject.Enabled = true;
+                    btnDeleteProject.Enabled = true;
 
                 }
+                // ���ʌ����̏ꍇ
+                else if (m_UserInfo.m_Type == CommonDefine.SecurityRankPos.SpecialAuthority)
+                {
+                    btnAddCompany.Enabled = true;
+                    btnDeleteCompany.Enabled = true;
+                    btnAddProject.Enabled = true;
+                    btnDeleteProject.Enabled = true;
+                }
 
                 // �\���`�����u����v�̏ꍇ�A�񊈐�
                 if (m_viewTarget != 0)
@@ -582,6 +465,7 @@
         }
         #endregion
 
+        #region �f�[�^�O���b�h�r���[�̑���s�؂�ւ�
         /// <summary>
         /// �f�[�^�O���b�h�r���[�̑���s�؂�ւ�
         /// </summary>
@@ -588,29 +472,42 @@
         /// <param name="dgv"></param>
         private void DataGridView_ReadOnlyChange(DataGridView dgv)
         {
-            switch (m_userType)
+            // ���ʌ����̏ꍇ
+            if (m_UserInfo.m_Type == CommonDefine.SecurityRankPos.SpecialAuthority)
             {
-                case UserType.Boss:
-                    break;
-                case UserType.Soumu:
-
-                    dgv.Columns[(int)DispColumn.KojiSeikyu].ReadOnly = true;
-                    dgv.Columns[(int)DispColumn.KojiNebiki].ReadOnly = true;
-                    dgv.Columns[(int)DispColumn.KojiSousai].ReadOnly = true;
-                    dgv.Columns[(int)DispColumn.KojiKosoku].ReadOnly = true;
-                    dgv.Columns[(int)DispColumn.KojiKanamono].ReadOnly = true;
-                    dgv.Columns[(int)DispColumn.KojiSannhaiZei].ReadOnly = true;
-                    dgv.Columns[(int)DispColumn.KyoryokuUmu].ReadOnly = true;
-                    break;
-                case UserType.Koji:
-                case UserType.Sekinin:
+                return;
+            }
+            // �����S��
+            if (m_UserInfo.m_GeneralAffairsFlg == 1)
+            {
+                dgv.Columns[(int)DispColumn.KojiSeikyu].ReadOnly = true;
+                dgv.Columns[(int)DispColumn.KojiNebiki].ReadOnly = true;
+                dgv.Columns[(int)DispColumn.KojiSousai].ReadOnly = true;
+                dgv.Columns[(int)DispColumn.KojiKosoku].ReadOnly = true;
+                dgv.Columns[(int)DispColumn.KojiKanamono].ReadOnly = true;
+                dgv.Columns[(int)DispColumn.KojiSannhaiZei].ReadOnly = true;
+                dgv.Columns[(int)DispColumn.KyoryokuUmu].ReadOnly = true;
+            }
+            // �S���҂̏ꍇ
+            else
+            {
+                if (m_UserInfo.m_Type == CommonDefine.SecurityRankPos.NormalAuthority)
+                {
                     dgv.Columns[(int)DispColumn.SomuSeikyu].ReadOnly = true;
                     dgv.Columns[(int)DispColumn.SomuKosoku].ReadOnly = true;
                     dgv.Columns[(int)DispColumn.SomuKanamono].ReadOnly = true;
                     dgv.Columns[(int)DispColumn.SomuSannhaiZei].ReadOnly = true;
-                    break;
-                case UserType.Sonota:
-                case UserType.Eigyo:
+                }
+                // �������A�����҂̏ꍇ
+                else if (m_UserInfo.m_Type == CommonDefine.SecurityRankPos.LimitedAuthority || m_UserInfo.m_Type == CommonDefine.SecurityRankPos.FreeAuthority)
+                {
+                    dgv.Columns[(int)DispColumn.SomuSeikyu].ReadOnly = true;
+                    dgv.Columns[(int)DispColumn.SomuKosoku].ReadOnly = true;
+                    dgv.Columns[(int)DispColumn.SomuKanamono].ReadOnly = true;
+                    dgv.Columns[(int)DispColumn.SomuSannhaiZei].ReadOnly = true;
+                }
+                else
+                {
                     dgv.Columns[(int)DispColumn.KojiSeikyu].ReadOnly = true;
                     dgv.Columns[(int)DispColumn.KojiNebiki].ReadOnly = true;
                     dgv.Columns[(int)DispColumn.KojiSousai].ReadOnly = true;
@@ -623,10 +520,10 @@
                     dgv.Columns[(int)DispColumn.SomuKanamono].ReadOnly = true;
                     dgv.Columns[(int)DispColumn.SomuSannhaiZei].ReadOnly = true;
                     dgv.Columns[(int)DispColumn.Bikou].ReadOnly = true;
-                    break;
+                }
             }
-
         }
+        #endregion
 
         #region ���ݕ\������Ă���ꗗ��Ԃ�
         /// <summary>
@@ -778,19 +675,28 @@
                 int iKosoku = 0, iKanamono = 0, iSanpai = 0;////�����㓙���U�p
                 string KojiTanto = "", KojiTantoCode="";
 
-                switch (m_userType)
+                // ���ʌ����̏ꍇ
+                if (m_UserInfo.m_Type == CommonDefine.SecurityRankPos.SpecialAuthority)
                 {
-                    case UserType.Koji:
-                        PersonCharge = 1;
-                        break;
-                    case UserType.Sekinin:
-                        PersonCharge = 2;
-                        break;
-                    case UserType.Boss:
-                        PersonCharge = 3;
-                        break;
+                    PersonCharge = 3;
                 }
+                // �������A�����҂̏ꍇ
+                else if (m_UserInfo.m_Type == CommonDefine.SecurityRankPos.LimitedAuthority || m_UserInfo.m_Type == CommonDefine.SecurityRankPos.FreeAuthority)
+                {
+                    PersonCharge = 2;
+                }
+                // �S���҂̏ꍇ
+                else if (m_UserInfo.m_Type == CommonDefine.SecurityRankPos.NormalAuthority)
+                {
+                    PersonCharge = 1;
+                }
 
+                // �����S��
+                if (m_UserInfo.m_GeneralAffairsFlg == 1)
+                {
+                    PersonCharge = 3;
+                }
+
                 //�w�b�_���
                 constructionFieldNameHeader.CompanyCode = iCompanyCode;
                 constructionFieldNameHeader.CompanyName = CommonMotions.cnvString(dgv.CurrentRow.Cells[m_CompanyNM_Column].ToolTipText);
@@ -1066,17 +972,17 @@
                                     }
 
                                     // ���e�X�g�p
-                                    if (CommonMotions.LoginUserData.PersonCode == 88889988)
-                                    {
-                                        dgv.Rows[MakeIndex].Cells[(int)DispColumn.TantoShonin].Value = "�e�X�g";
-                                    }
-                                    else
-                                    { 
+                                    //if (CommonMotions.LoginUserData.PersonCode == 88889988)
+                                    //{
+                                    //    dgv.Rows[MakeIndex].Cells[(int)DispColumn.TantoShonin].Value = "�e�X�g";
+                                    //}
+                                    //else
+                                    //{ 
                                         //�S���ҏ��F�ݒ�
                                         dgv.Rows[MakeIndex].Cells[(int)DispColumn.TantoShoninCode].Value = KojiTantoCode;
                                         dgv.Rows[MakeIndex].Cells[(int)DispColumn.TantoShonin].Value = KojiTanto;
                                         dgv.Rows[MakeIndex].Cells[(int)DispColumn.TantoShonin].Style.ForeColor = Color.Gray;
-                                    }
+                                    //}
 
                                     ////�����㓙���U �ŏ��̒ǉ����Ɋ��U��
                                     if (iKosoku > 0)
@@ -1184,6 +1090,7 @@
             }
         }
         #endregion
+
         #region �s�ԍ��擾
         /// <summary>
         /// �s�ԍ��擾
Index: branches/src/ProcessManagement/ProcessManagement/Forms/DataEntry/Request/SalesConfirm/FrmSalesConfirm.Designer.cs
===================================================================
--- branches/src/ProcessManagement/ProcessManagement/Forms/DataEntry/Request/SalesConfirm/FrmSalesConfirm.Designer.cs	(nonexistent)
+++ branches/src/ProcessManagement/ProcessManagement/Forms/DataEntry/Request/SalesConfirm/FrmSalesConfirm.Designer.cs	(revision 60)
@@ -0,0 +1,1152 @@
+﻿namespace ProcessManagement.Forms.DataEntry
+{
+    partial class FrmSalesConfirm
+    {
+        /// <summary>
+        /// 必要なデザイナー変数です。
+        /// </summary>
+        private System.ComponentModel.IContainer components = null;
+
+        /// <summary>
+        /// 使用中のリソースをすべてクリーンアップします。
+        /// </summary>
+        /// <param name="disposing">マネージ リソースが破棄される場合 true、破棄されない場合は false です。</param>
+        protected override void Dispose(bool disposing)
+        {
+            if (disposing && (components != null))
+            {
+                components.Dispose();
+            }
+            base.Dispose(disposing);
+        }
+
+        #region Windows フォーム デザイナーで生成されたコード
+
+        /// <summary>
+        /// デザイナー サポートに必要なメソッドです。このメソッドの内容を
+        /// コード エディターで変更しないでください。
+        /// </summary>
+        private void InitializeComponent()
+        {
+            System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle1 = new System.Windows.Forms.DataGridViewCellStyle();
+            System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle2 = new System.Windows.Forms.DataGridViewCellStyle();
+            System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle3 = new System.Windows.Forms.DataGridViewCellStyle();
+            System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle4 = new System.Windows.Forms.DataGridViewCellStyle();
+            System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle5 = new System.Windows.Forms.DataGridViewCellStyle();
+            System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle6 = new System.Windows.Forms.DataGridViewCellStyle();
+            System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle7 = new System.Windows.Forms.DataGridViewCellStyle();
+            System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle8 = new System.Windows.Forms.DataGridViewCellStyle();
+            System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle9 = new System.Windows.Forms.DataGridViewCellStyle();
+            System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle10 = new System.Windows.Forms.DataGridViewCellStyle();
+            System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle11 = new System.Windows.Forms.DataGridViewCellStyle();
+            System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle12 = new System.Windows.Forms.DataGridViewCellStyle();
+            System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle13 = new System.Windows.Forms.DataGridViewCellStyle();
+            System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle14 = new System.Windows.Forms.DataGridViewCellStyle();
+            System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle15 = new System.Windows.Forms.DataGridViewCellStyle();
+            System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle16 = new System.Windows.Forms.DataGridViewCellStyle();
+            System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle17 = new System.Windows.Forms.DataGridViewCellStyle();
+            System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle18 = new System.Windows.Forms.DataGridViewCellStyle();
+            System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle19 = new System.Windows.Forms.DataGridViewCellStyle();
+            System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle20 = new System.Windows.Forms.DataGridViewCellStyle();
+            System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle21 = new System.Windows.Forms.DataGridViewCellStyle();
+            System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle22 = new System.Windows.Forms.DataGridViewCellStyle();
+            System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle23 = new System.Windows.Forms.DataGridViewCellStyle();
+            System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle24 = new System.Windows.Forms.DataGridViewCellStyle();
+            System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle25 = new System.Windows.Forms.DataGridViewCellStyle();
+            this.label3 = new System.Windows.Forms.Label();
+            this.panel1 = new System.Windows.Forms.Panel();
+            this.label7 = new System.Windows.Forms.Label();
+            this.label6 = new System.Windows.Forms.Label();
+            this.numericUpDown2 = new System.Windows.Forms.NumericUpDown();
+            this.label5 = new System.Windows.Forms.Label();
+            this.comboBox3 = new System.Windows.Forms.ComboBox();
+            this.label4 = new System.Windows.Forms.Label();
+            this.comboBox2 = new System.Windows.Forms.ComboBox();
+            this.label2 = new System.Windows.Forms.Label();
+            this.dgvMaster = new System.Windows.Forms.DataGridView();
+            this.EditStatus = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.No = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.OrderersDivision = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.OrderersCode = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.SeqNo = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.LineCount = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.OrderersName = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.DepositDate = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.DepositAmountCash = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.DepositAmountBill = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.RequestNo = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.OrderNo = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.ConstructionName = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.ConstructionName_Raw = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.PaymentSchedule = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.BillCreationDate = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.BillPrice = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.TaxPrice = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.DepositAmount = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.DiscountAmount = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.CnstrPrice = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.Fees = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.OtherAdjustments = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.CarryAmount = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.PersonName = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.PersonCode = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.PersonDate = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.ApprovalName_1 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.ApprovalCode_1 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.ApprovalAuthority_1 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.ApprovalDate_1 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.ApprovalOrder_1 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.ApprovalName_2 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.ApprovalCode_2 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.ApprovalAuthority_2 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.ApprovalDate_2 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.ApprovalOrder_2 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.ApprovalName_3 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.ApprovalCode_3 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.ApprovalAuthority_3 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.ApprovalDate_3 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.ApprovalOrder_3 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.ApprovalName_4 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.ApprovalCode_4 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.ApprovalAuthority_4 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.ApprovalDate_4 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.ApprovalOrder_4 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.ApprovalName_5 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.ApprovalCode_5 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.ApprovalAuthority_5 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.ApprovalDate_5 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.ApprovalOrder_5 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.ApprovalName_6 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.ApprovalCode_6 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.ApprovalAuthority_6 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.ApprovalDate_6 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.ApprovalOrder_6 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.ApprovalName_7 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.ApprovalCode_7 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.ApprovalAuthority_7 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.ApprovalDate_7 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.ApprovalOrder_7 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.ApprovalName_8 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.ApprovalCode_8 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.ApprovalAuthority_8 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.ApprovalDate_8 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.ApprovalOrder_8 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.ApprovalName_9 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.ApprovalCode_9 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.ApprovalAuthority_9 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.ApprovalDate_9 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.ApprovalOrder_9 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.ApprovalName_10 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.ApprovalCode_10 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.ApprovalAuthority_10 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.ApprovalDate_10 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.ApprovalOrder_10 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.btnEnd = new System.Windows.Forms.Button();
+            this.groupBoxEx1 = new ProcessManagement.Forms.CustomControls.GroupBoxEx();
+            this.comboBox1 = new System.Windows.Forms.ComboBox();
+            this.label1 = new System.Windows.Forms.Label();
+            this.radioButton2 = new System.Windows.Forms.RadioButton();
+            this.radioButton1 = new System.Windows.Forms.RadioButton();
+            this.panel1.SuspendLayout();
+            ((System.ComponentModel.ISupportInitialize)(this.numericUpDown2)).BeginInit();
+            ((System.ComponentModel.ISupportInitialize)(this.dgvMaster)).BeginInit();
+            this.groupBoxEx1.SuspendLayout();
+            this.SuspendLayout();
+            // 
+            // label3
+            // 
+            this.label3.Anchor = System.Windows.Forms.AnchorStyles.Top;
+            this.label3.BackColor = System.Drawing.Color.White;
+            this.label3.Font = new System.Drawing.Font("ＭＳ Ｐゴシック", 11.25F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(128)));
+            this.label3.Location = new System.Drawing.Point(561, 8);
+            this.label3.Margin = new System.Windows.Forms.Padding(4, 0, 4, 0);
+            this.label3.Name = "label3";
+            this.label3.Size = new System.Drawing.Size(292, 34);
+            this.label3.TabIndex = 3;
+            this.label3.Text = "売　上　確　認";
+            this.label3.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
+            // 
+            // panel1
+            // 
+            this.panel1.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Left) 
+            | System.Windows.Forms.AnchorStyles.Right)));
+            this.panel1.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(128)))), ((int)(((byte)(255)))), ((int)(((byte)(255)))));
+            this.panel1.Controls.Add(this.groupBoxEx1);
+            this.panel1.Controls.Add(this.label7);
+            this.panel1.Controls.Add(this.label6);
+            this.panel1.Controls.Add(this.numericUpDown2);
+            this.panel1.Controls.Add(this.label5);
+            this.panel1.Controls.Add(this.comboBox3);
+            this.panel1.Controls.Add(this.label4);
+            this.panel1.Controls.Add(this.comboBox2);
+            this.panel1.Controls.Add(this.label2);
+            this.panel1.Location = new System.Drawing.Point(7, 50);
+            this.panel1.Name = "panel1";
+            this.panel1.Size = new System.Drawing.Size(1399, 61);
+            this.panel1.TabIndex = 6;
+            // 
+            // label7
+            // 
+            this.label7.AutoSize = true;
+            this.label7.Location = new System.Drawing.Point(190, 25);
+            this.label7.Name = "label7";
+            this.label7.Size = new System.Drawing.Size(24, 15);
+            this.label7.TabIndex = 30;
+            this.label7.Text = "期";
+            // 
+            // label6
+            // 
+            this.label6.AutoSize = true;
+            this.label6.Location = new System.Drawing.Point(97, 25);
+            this.label6.Name = "label6";
+            this.label6.Size = new System.Drawing.Size(24, 15);
+            this.label6.TabIndex = 29;
+            this.label6.Text = "第";
+            // 
+            // numericUpDown2
+            // 
+            this.numericUpDown2.Font = new System.Drawing.Font("ＭＳ 明朝", 12F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(128)));
+            this.numericUpDown2.Location = new System.Drawing.Point(126, 21);
+            this.numericUpDown2.Maximum = new decimal(new int[] {
+            12,
+            0,
+            0,
+            0});
+            this.numericUpDown2.Minimum = new decimal(new int[] {
+            1,
+            0,
+            0,
+            0});
+            this.numericUpDown2.Name = "numericUpDown2";
+            this.numericUpDown2.Size = new System.Drawing.Size(58, 23);
+            this.numericUpDown2.TabIndex = 28;
+            this.numericUpDown2.TextAlign = System.Windows.Forms.HorizontalAlignment.Center;
+            this.numericUpDown2.Value = new decimal(new int[] {
+            1,
+            0,
+            0,
+            0});
+            this.numericUpDown2.ValueChanged += new System.EventHandler(this.numericUpDown2_ValueChanged);
+            // 
+            // label5
+            // 
+            this.label5.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(255)))), ((int)(((byte)(255)))), ((int)(((byte)(128)))));
+            this.label5.BorderStyle = System.Windows.Forms.BorderStyle.Fixed3D;
+            this.label5.CausesValidation = false;
+            this.label5.Font = new System.Drawing.Font("ＭＳ 明朝", 11.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(128)));
+            this.label5.Location = new System.Drawing.Point(815, 17);
+            this.label5.Name = "label5";
+            this.label5.Size = new System.Drawing.Size(76, 30);
+            this.label5.TabIndex = 27;
+            this.label5.Text = "担当者";
+            this.label5.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
+            // 
+            // comboBox3
+            // 
+            this.comboBox3.BackColor = System.Drawing.Color.WhiteSmoke;
+            this.comboBox3.DisplayMember = "Value";
+            this.comboBox3.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
+            this.comboBox3.DropDownWidth = 120;
+            this.comboBox3.FlatStyle = System.Windows.Forms.FlatStyle.Popup;
+            this.comboBox3.Font = new System.Drawing.Font("ＭＳ 明朝", 12F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(128)));
+            this.comboBox3.FormattingEnabled = true;
+            this.comboBox3.Location = new System.Drawing.Point(902, 20);
+            this.comboBox3.Name = "comboBox3";
+            this.comboBox3.Size = new System.Drawing.Size(194, 24);
+            this.comboBox3.TabIndex = 26;
+            this.comboBox3.ValueMember = "Key";
+            this.comboBox3.SelectedIndexChanged += new System.EventHandler(this.comboBox3_SelectedIndexChanged);
+            // 
+            // label4
+            // 
+            this.label4.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(255)))), ((int)(((byte)(255)))), ((int)(((byte)(128)))));
+            this.label4.BorderStyle = System.Windows.Forms.BorderStyle.Fixed3D;
+            this.label4.CausesValidation = false;
+            this.label4.Font = new System.Drawing.Font("ＭＳ 明朝", 11.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(128)));
+            this.label4.Location = new System.Drawing.Point(524, 17);
+            this.label4.Name = "label4";
+            this.label4.Size = new System.Drawing.Size(69, 30);
+            this.label4.TabIndex = 25;
+            this.label4.Text = "部署";
+            this.label4.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
+            // 
+            // comboBox2
+            // 
+            this.comboBox2.BackColor = System.Drawing.Color.WhiteSmoke;
+            this.comboBox2.DisplayMember = "Value";
+            this.comboBox2.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
+            this.comboBox2.DropDownWidth = 120;
+            this.comboBox2.FlatStyle = System.Windows.Forms.FlatStyle.Popup;
+            this.comboBox2.Font = new System.Drawing.Font("ＭＳ 明朝", 12F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(128)));
+            this.comboBox2.FormattingEnabled = true;
+            this.comboBox2.Location = new System.Drawing.Point(608, 20);
+            this.comboBox2.Name = "comboBox2";
+            this.comboBox2.Size = new System.Drawing.Size(194, 24);
+            this.comboBox2.TabIndex = 24;
+            this.comboBox2.ValueMember = "Key";
+            this.comboBox2.SelectedIndexChanged += new System.EventHandler(this.comboBox2_SelectedIndexChanged);
+            // 
+            // label2
+            // 
+            this.label2.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(255)))), ((int)(((byte)(255)))), ((int)(((byte)(128)))));
+            this.label2.BorderStyle = System.Windows.Forms.BorderStyle.Fixed3D;
+            this.label2.CausesValidation = false;
+            this.label2.Font = new System.Drawing.Font("ＭＳ 明朝", 11.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(128)));
+            this.label2.Location = new System.Drawing.Point(5, 17);
+            this.label2.Name = "label2";
+            this.label2.Size = new System.Drawing.Size(80, 30);
+            this.label2.TabIndex = 6;
+            this.label2.Text = "営業期";
+            this.label2.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
+            // 
+            // dgvMaster
+            // 
+            this.dgvMaster.AllowUserToAddRows = false;
+            this.dgvMaster.Anchor = ((System.Windows.Forms.AnchorStyles)((((System.Windows.Forms.AnchorStyles.Top | System.Windows.Forms.AnchorStyles.Bottom) 
+            | System.Windows.Forms.AnchorStyles.Left) 
+            | System.Windows.Forms.AnchorStyles.Right)));
+            dataGridViewCellStyle1.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleCenter;
+            dataGridViewCellStyle1.BackColor = System.Drawing.SystemColors.Control;
+            dataGridViewCellStyle1.Font = new System.Drawing.Font("ＭＳ 明朝", 11.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(128)));
+            dataGridViewCellStyle1.ForeColor = System.Drawing.SystemColors.WindowText;
+            dataGridViewCellStyle1.SelectionBackColor = System.Drawing.SystemColors.Highlight;
+            dataGridViewCellStyle1.SelectionForeColor = System.Drawing.SystemColors.HighlightText;
+            dataGridViewCellStyle1.WrapMode = System.Windows.Forms.DataGridViewTriState.True;
+            this.dgvMaster.ColumnHeadersDefaultCellStyle = dataGridViewCellStyle1;
+            this.dgvMaster.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize;
+            this.dgvMaster.Columns.AddRange(new System.Windows.Forms.DataGridViewColumn[] {
+            this.EditStatus,
+            this.No,
+            this.OrderersDivision,
+            this.OrderersCode,
+            this.SeqNo,
+            this.LineCount,
+            this.OrderersName,
+            this.DepositDate,
+            this.DepositAmountCash,
+            this.DepositAmountBill,
+            this.RequestNo,
+            this.OrderNo,
+            this.ConstructionName,
+            this.ConstructionName_Raw,
+            this.PaymentSchedule,
+            this.BillCreationDate,
+            this.BillPrice,
+            this.TaxPrice,
+            this.DepositAmount,
+            this.DiscountAmount,
+            this.CnstrPrice,
+            this.Fees,
+            this.OtherAdjustments,
+            this.CarryAmount,
+            this.PersonName,
+            this.PersonCode,
+            this.PersonDate,
+            this.ApprovalName_1,
+            this.ApprovalCode_1,
+            this.ApprovalAuthority_1,
+            this.ApprovalDate_1,
+            this.ApprovalOrder_1,
+            this.ApprovalName_2,
+            this.ApprovalCode_2,
+            this.ApprovalAuthority_2,
+            this.ApprovalDate_2,
+            this.ApprovalOrder_2,
+            this.ApprovalName_3,
+            this.ApprovalCode_3,
+            this.ApprovalAuthority_3,
+            this.ApprovalDate_3,
+            this.ApprovalOrder_3,
+            this.ApprovalName_4,
+            this.ApprovalCode_4,
+            this.ApprovalAuthority_4,
+            this.ApprovalDate_4,
+            this.ApprovalOrder_4,
+            this.ApprovalName_5,
+            this.ApprovalCode_5,
+            this.ApprovalAuthority_5,
+            this.ApprovalDate_5,
+            this.ApprovalOrder_5,
+            this.ApprovalName_6,
+            this.ApprovalCode_6,
+            this.ApprovalAuthority_6,
+            this.ApprovalDate_6,
+            this.ApprovalOrder_6,
+            this.ApprovalName_7,
+            this.ApprovalCode_7,
+            this.ApprovalAuthority_7,
+            this.ApprovalDate_7,
+            this.ApprovalOrder_7,
+            this.ApprovalName_8,
+            this.ApprovalCode_8,
+            this.ApprovalAuthority_8,
+            this.ApprovalDate_8,
+            this.ApprovalOrder_8,
+            this.ApprovalName_9,
+            this.ApprovalCode_9,
+            this.ApprovalAuthority_9,
+            this.ApprovalDate_9,
+            this.ApprovalOrder_9,
+            this.ApprovalName_10,
+            this.ApprovalCode_10,
+            this.ApprovalAuthority_10,
+            this.ApprovalDate_10,
+            this.ApprovalOrder_10});
+            this.dgvMaster.EnableHeadersVisualStyles = false;
+            this.dgvMaster.Location = new System.Drawing.Point(8, 117);
+            this.dgvMaster.Name = "dgvMaster";
+            this.dgvMaster.RowHeadersWidth = 24;
+            this.dgvMaster.RowTemplate.Height = 21;
+            this.dgvMaster.Size = new System.Drawing.Size(1399, 474);
+            this.dgvMaster.TabIndex = 7;
+            // 
+            // EditStatus
+            // 
+            this.EditStatus.HeaderText = "■編集状態";
+            this.EditStatus.Name = "EditStatus";
+            this.EditStatus.Visible = false;
+            // 
+            // No
+            // 
+            dataGridViewCellStyle2.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleRight;
+            this.No.DefaultCellStyle = dataGridViewCellStyle2;
+            this.No.HeaderText = "No.";
+            this.No.Name = "No";
+            this.No.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable;
+            this.No.Width = 40;
+            // 
+            // OrderersDivision
+            // 
+            this.OrderersDivision.HeaderText = "■発注者区分";
+            this.OrderersDivision.Name = "OrderersDivision";
+            this.OrderersDivision.Visible = false;
+            // 
+            // OrderersCode
+            // 
+            this.OrderersCode.HeaderText = "■発注者コード";
+            this.OrderersCode.Name = "OrderersCode";
+            this.OrderersCode.Visible = false;
+            // 
+            // SeqNo
+            // 
+            this.SeqNo.HeaderText = "■連番";
+            this.SeqNo.Name = "SeqNo";
+            this.SeqNo.Visible = false;
+            // 
+            // LineCount
+            // 
+            this.LineCount.HeaderText = "■行番号";
+            this.LineCount.Name = "LineCount";
+            this.LineCount.Visible = false;
+            // 
+            // OrderersName
+            // 
+            this.OrderersName.HeaderText = "請求先名";
+            this.OrderersName.Name = "OrderersName";
+            this.OrderersName.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable;
+            this.OrderersName.Width = 200;
+            // 
+            // DepositDate
+            // 
+            this.DepositDate.HeaderText = "入金日";
+            this.DepositDate.Name = "DepositDate";
+            this.DepositDate.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable;
+            this.DepositDate.Width = 120;
+            this.DepositDate.Visible = false;
+            // 
+            // DepositAmountCash
+            // 
+            dataGridViewCellStyle3.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleRight;
+            this.DepositAmountCash.DefaultCellStyle = dataGridViewCellStyle3;
+            this.DepositAmountCash.HeaderText = "入金金額\r\n（振込）";
+            this.DepositAmountCash.Name = "DepositAmountCash";
+            this.DepositAmountCash.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable;
+            this.DepositAmountCash.Width = 140;
+            // 
+            // DepositAmountBill
+            // 
+            dataGridViewCellStyle4.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleRight;
+            this.DepositAmountBill.DefaultCellStyle = dataGridViewCellStyle4;
+            this.DepositAmountBill.HeaderText = "入金金額\r\n（手形）";
+            this.DepositAmountBill.Name = "DepositAmountBill";
+            this.DepositAmountBill.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable;
+            this.DepositAmountBill.Width = 140;
+            // 
+            // RequestNo
+            // 
+            this.RequestNo.HeaderText = "■請求No";
+            this.RequestNo.Name = "RequestNo";
+            this.RequestNo.Visible = false;
+            // 
+            // OrderNo
+            // 
+            this.OrderNo.HeaderText = "■受付番号";
+            this.OrderNo.Name = "OrderNo";
+            this.OrderNo.Visible = false;
+            // 
+            // ConstructionName
+            // 
+            this.ConstructionName.HeaderText = "現場名";
+            this.ConstructionName.Name = "ConstructionName";
+            this.ConstructionName.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable;
+            this.ConstructionName.Width = 400;
+            // 
+            // ConstructionName_Raw
+            // 
+            this.ConstructionName_Raw.HeaderText = "■現場名 (DB登録値)";
+            this.ConstructionName_Raw.Name = "ConstructionName_Raw";
+            this.ConstructionName_Raw.Visible = false;
+            // 
+            // PaymentSchedule
+            // 
+            dataGridViewCellStyle5.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleCenter;
+            this.PaymentSchedule.DefaultCellStyle = dataGridViewCellStyle5;
+            this.PaymentSchedule.HeaderText = "入金\r\n予定日";
+            this.PaymentSchedule.Name = "PaymentSchedule";
+            this.PaymentSchedule.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable;
+            this.PaymentSchedule.Visible = false;
+            this.PaymentSchedule.Width = 120;
+            // 
+            // BillCreationDate
+            // 
+            dataGridViewCellStyle6.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleCenter;
+            this.BillCreationDate.DefaultCellStyle = dataGridViewCellStyle6;
+            this.BillCreationDate.HeaderText = "請求日";
+            this.BillCreationDate.Name = "BillCreationDate";
+            this.BillCreationDate.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable;
+            this.BillCreationDate.Width = 120;
+            this.BillCreationDate.Visible = false;
+            // 
+            // BillPrice
+            // 
+            dataGridViewCellStyle7.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleRight;
+            this.BillPrice.DefaultCellStyle = dataGridViewCellStyle7;
+            this.BillPrice.HeaderText = "請求金額\r\n（税抜）";
+            this.BillPrice.Name = "BillPrice";
+            this.BillPrice.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable;
+            this.BillPrice.Width = 140;
+            this.BillPrice.Visible = false;
+            // 
+            // TaxPrice
+            // 
+            dataGridViewCellStyle8.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleRight;
+            this.TaxPrice.DefaultCellStyle = dataGridViewCellStyle8;
+            this.TaxPrice.HeaderText = "請求金額\r\n（消費税）";
+            this.TaxPrice.Name = "TaxPrice";
+            this.TaxPrice.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable;
+            this.TaxPrice.Width = 140;
+            this.TaxPrice.Visible = false;
+            // 
+            // DepositAmount
+            // 
+            dataGridViewCellStyle9.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleRight;
+            this.DepositAmount.DefaultCellStyle = dataGridViewCellStyle9;
+            this.DepositAmount.HeaderText = "入金金額";
+            this.DepositAmount.Name = "DepositAmount";
+            this.DepositAmount.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable;
+            this.DepositAmount.Width = 140;
+            // 
+            // DiscountAmount
+            // 
+            dataGridViewCellStyle10.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleRight;
+            this.DiscountAmount.DefaultCellStyle = dataGridViewCellStyle10;
+            this.DiscountAmount.HeaderText = "値引金額";
+            this.DiscountAmount.Name = "DiscountAmount";
+            this.DiscountAmount.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable;
+            this.DiscountAmount.Width = 140;
+            // 
+            // CnstrPrice
+            // 
+            dataGridViewCellStyle11.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleRight;
+            this.CnstrPrice.DefaultCellStyle = dataGridViewCellStyle11;
+            this.CnstrPrice.HeaderText = "協力金";
+            this.CnstrPrice.Name = "CnstrPrice";
+            this.CnstrPrice.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable;
+            this.CnstrPrice.Width = 140;
+            // 
+            // Fees
+            // 
+            dataGridViewCellStyle12.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleRight;
+            this.Fees.DefaultCellStyle = dataGridViewCellStyle12;
+            this.Fees.HeaderText = "手数料";
+            this.Fees.Name = "Fees";
+            this.Fees.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable;
+            this.Fees.Width = 140;
+            // 
+            // OtherAdjustments
+            // 
+            dataGridViewCellStyle13.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleRight;
+            this.OtherAdjustments.DefaultCellStyle = dataGridViewCellStyle13;
+            this.OtherAdjustments.HeaderText = "その他調整";
+            this.OtherAdjustments.Name = "OtherAdjustments";
+            this.OtherAdjustments.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable;
+            this.OtherAdjustments.Width = 140;
+            // 
+            // CarryAmount
+            // 
+            dataGridViewCellStyle14.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleRight;
+            this.CarryAmount.DefaultCellStyle = dataGridViewCellStyle14;
+            this.CarryAmount.HeaderText = "次回繰越";
+            this.CarryAmount.Name = "CarryAmount";
+            this.CarryAmount.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable;
+            this.CarryAmount.Width = 140;
+            // 
+            // PersonName
+            // 
+            dataGridViewCellStyle15.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleCenter;
+            this.PersonName.DefaultCellStyle = dataGridViewCellStyle15;
+            this.PersonName.HeaderText = "担当者\r\n承認";
+            this.PersonName.Name = "PersonName";
+            this.PersonName.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable;
+            this.PersonName.Width = 110;
+            // 
+            // PersonCode
+            // 
+            this.PersonCode.HeaderText = "■担当者コード";
+            this.PersonCode.Name = "PersonCode";
+            this.PersonCode.Visible = false;
+            // 
+            // PersonDate
+            // 
+            this.PersonDate.HeaderText = "■担当者日付";
+            this.PersonDate.Name = "PersonDate";
+            this.PersonDate.Visible = false;
+            // 
+            // ApprovalName_1
+            // 
+            dataGridViewCellStyle16.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleCenter;
+            this.ApprovalName_1.DefaultCellStyle = dataGridViewCellStyle16;
+            this.ApprovalName_1.HeaderText = "承認者1\r\n承認";
+            this.ApprovalName_1.Name = "ApprovalName_1";
+            this.ApprovalName_1.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable;
+            this.ApprovalName_1.Visible = false;
+            this.ApprovalName_1.Width = 110;
+            // 
+            // ApprovalCode_1
+            // 
+            this.ApprovalCode_1.HeaderText = "■承認者コード_1";
+            this.ApprovalCode_1.Name = "ApprovalCode_1";
+            this.ApprovalCode_1.Visible = false;
+            // 
+            // ApprovalAuthority_1
+            // 
+            this.ApprovalAuthority_1.HeaderText = "■承認権限区分_1";
+            this.ApprovalAuthority_1.Name = "ApprovalAuthority_1";
+            this.ApprovalAuthority_1.Visible = false;
+            // 
+            // ApprovalDate_1
+            // 
+            this.ApprovalDate_1.HeaderText = "■承認日付_1";
+            this.ApprovalDate_1.Name = "ApprovalDate_1";
+            this.ApprovalDate_1.Visible = false;
+            // 
+            // ApprovalOrder_1
+            // 
+            this.ApprovalOrder_1.HeaderText = "■承認順番_1";
+            this.ApprovalOrder_1.Name = "ApprovalOrder_1";
+            this.ApprovalOrder_1.Visible = false;
+            // 
+            // ApprovalName_2
+            // 
+            dataGridViewCellStyle17.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleCenter;
+            this.ApprovalName_2.DefaultCellStyle = dataGridViewCellStyle17;
+            this.ApprovalName_2.HeaderText = "承認者2\r\n承認";
+            this.ApprovalName_2.Name = "ApprovalName_2";
+            this.ApprovalName_2.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable;
+            this.ApprovalName_2.Visible = false;
+            this.ApprovalName_2.Width = 110;
+            // 
+            // ApprovalCode_2
+            // 
+            this.ApprovalCode_2.HeaderText = "■承認者コード_2";
+            this.ApprovalCode_2.Name = "ApprovalCode_2";
+            this.ApprovalCode_2.Visible = false;
+            // 
+            // ApprovalAuthority_2
+            // 
+            this.ApprovalAuthority_2.HeaderText = "■承認権限区分_2";
+            this.ApprovalAuthority_2.Name = "ApprovalAuthority_2";
+            this.ApprovalAuthority_2.Visible = false;
+            // 
+            // ApprovalDate_2
+            // 
+            this.ApprovalDate_2.HeaderText = "■承認日付_2";
+            this.ApprovalDate_2.Name = "ApprovalDate_2";
+            this.ApprovalDate_2.Visible = false;
+            // 
+            // ApprovalOrder_2
+            // 
+            this.ApprovalOrder_2.HeaderText = "■承認順番_2";
+            this.ApprovalOrder_2.Name = "ApprovalOrder_2";
+            this.ApprovalOrder_2.Visible = false;
+            // 
+            // ApprovalName_3
+            // 
+            dataGridViewCellStyle18.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleCenter;
+            this.ApprovalName_3.DefaultCellStyle = dataGridViewCellStyle18;
+            this.ApprovalName_3.HeaderText = "承認者3\r\n承認";
+            this.ApprovalName_3.Name = "ApprovalName_3";
+            this.ApprovalName_3.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable;
+            this.ApprovalName_3.Visible = false;
+            this.ApprovalName_3.Width = 110;
+            // 
+            // ApprovalCode_3
+            // 
+            this.ApprovalCode_3.HeaderText = "■承認者コード_3";
+            this.ApprovalCode_3.Name = "ApprovalCode_3";
+            this.ApprovalCode_3.Visible = false;
+            // 
+            // ApprovalAuthority_3
+            // 
+            this.ApprovalAuthority_3.HeaderText = "■承認権限区分_3";
+            this.ApprovalAuthority_3.Name = "ApprovalAuthority_3";
+            this.ApprovalAuthority_3.Visible = false;
+            // 
+            // ApprovalDate_3
+            // 
+            this.ApprovalDate_3.HeaderText = "■承認日付_3";
+            this.ApprovalDate_3.Name = "ApprovalDate_3";
+            this.ApprovalDate_3.Visible = false;
+            // 
+            // ApprovalOrder_3
+            // 
+            this.ApprovalOrder_3.HeaderText = "■承認順番_3";
+            this.ApprovalOrder_3.Name = "ApprovalOrder_3";
+            this.ApprovalOrder_3.Visible = false;
+            // 
+            // ApprovalName_4
+            // 
+            dataGridViewCellStyle19.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleCenter;
+            this.ApprovalName_4.DefaultCellStyle = dataGridViewCellStyle19;
+            this.ApprovalName_4.HeaderText = "承認者4\r\n承認";
+            this.ApprovalName_4.Name = "ApprovalName_4";
+            this.ApprovalName_4.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable;
+            this.ApprovalName_4.Visible = false;
+            this.ApprovalName_4.Width = 110;
+            // 
+            // ApprovalCode_4
+            // 
+            this.ApprovalCode_4.HeaderText = "■承認者コード_4";
+            this.ApprovalCode_4.Name = "ApprovalCode_4";
+            this.ApprovalCode_4.Visible = false;
+            // 
+            // ApprovalAuthority_4
+            // 
+            this.ApprovalAuthority_4.HeaderText = "■承認権限区分_4";
+            this.ApprovalAuthority_4.Name = "ApprovalAuthority_4";
+            this.ApprovalAuthority_4.Visible = false;
+            // 
+            // ApprovalDate_4
+            // 
+            this.ApprovalDate_4.HeaderText = "■承認日付_4";
+            this.ApprovalDate_4.Name = "ApprovalDate_4";
+            this.ApprovalDate_4.Visible = false;
+            // 
+            // ApprovalOrder_4
+            // 
+            this.ApprovalOrder_4.HeaderText = "■承認順番_4";
+            this.ApprovalOrder_4.Name = "ApprovalOrder_4";
+            this.ApprovalOrder_4.Visible = false;
+            // 
+            // ApprovalName_5
+            // 
+            dataGridViewCellStyle20.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleCenter;
+            this.ApprovalName_5.DefaultCellStyle = dataGridViewCellStyle20;
+            this.ApprovalName_5.HeaderText = "承認者5\r\n承認";
+            this.ApprovalName_5.Name = "ApprovalName_5";
+            this.ApprovalName_5.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable;
+            this.ApprovalName_5.Visible = false;
+            this.ApprovalName_5.Width = 110;
+            // 
+            // ApprovalCode_5
+            // 
+            this.ApprovalCode_5.HeaderText = "■承認者コード_5";
+            this.ApprovalCode_5.Name = "ApprovalCode_5";
+            this.ApprovalCode_5.Visible = false;
+            // 
+            // ApprovalAuthority_5
+            // 
+            this.ApprovalAuthority_5.HeaderText = "■承認権限区分_5";
+            this.ApprovalAuthority_5.Name = "ApprovalAuthority_5";
+            this.ApprovalAuthority_5.Visible = false;
+            // 
+            // ApprovalDate_5
+            // 
+            this.ApprovalDate_5.HeaderText = "■承認日付_5";
+            this.ApprovalDate_5.Name = "ApprovalDate_5";
+            this.ApprovalDate_5.Visible = false;
+            // 
+            // ApprovalOrder_5
+            // 
+            this.ApprovalOrder_5.HeaderText = "■承認順番_5";
+            this.ApprovalOrder_5.Name = "ApprovalOrder_5";
+            this.ApprovalOrder_5.Visible = false;
+            // 
+            // ApprovalName_6
+            // 
+            dataGridViewCellStyle21.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleCenter;
+            this.ApprovalName_6.DefaultCellStyle = dataGridViewCellStyle21;
+            this.ApprovalName_6.HeaderText = "承認者6\r\n承認";
+            this.ApprovalName_6.Name = "ApprovalName_6";
+            this.ApprovalName_6.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable;
+            this.ApprovalName_6.Visible = false;
+            this.ApprovalName_6.Width = 110;
+            // 
+            // ApprovalCode_6
+            // 
+            this.ApprovalCode_6.HeaderText = "■承認者コード_6";
+            this.ApprovalCode_6.Name = "ApprovalCode_6";
+            this.ApprovalCode_6.Visible = false;
+            // 
+            // ApprovalAuthority_6
+            // 
+            this.ApprovalAuthority_6.HeaderText = "■承認権限区分_6";
+            this.ApprovalAuthority_6.Name = "ApprovalAuthority_6";
+            this.ApprovalAuthority_6.Visible = false;
+            // 
+            // ApprovalDate_6
+            // 
+            this.ApprovalDate_6.HeaderText = "■承認日付_6";
+            this.ApprovalDate_6.Name = "ApprovalDate_6";
+            this.ApprovalDate_6.Visible = false;
+            // 
+            // ApprovalOrder_6
+            // 
+            this.ApprovalOrder_6.HeaderText = "■承認順番_6";
+            this.ApprovalOrder_6.Name = "ApprovalOrder_6";
+            this.ApprovalOrder_6.Visible = false;
+            // 
+            // ApprovalName_7
+            // 
+            dataGridViewCellStyle22.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleCenter;
+            this.ApprovalName_7.DefaultCellStyle = dataGridViewCellStyle22;
+            this.ApprovalName_7.HeaderText = "承認者7\r\n承認";
+            this.ApprovalName_7.Name = "ApprovalName_7";
+            this.ApprovalName_7.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable;
+            this.ApprovalName_7.Visible = false;
+            this.ApprovalName_7.Width = 110;
+            // 
+            // ApprovalCode_7
+            // 
+            this.ApprovalCode_7.HeaderText = "■承認者コード_7";
+            this.ApprovalCode_7.Name = "ApprovalCode_7";
+            this.ApprovalCode_7.Visible = false;
+            // 
+            // ApprovalAuthority_7
+            // 
+            this.ApprovalAuthority_7.HeaderText = "■承認権限区分_7";
+            this.ApprovalAuthority_7.Name = "ApprovalAuthority_7";
+            this.ApprovalAuthority_7.Visible = false;
+            // 
+            // ApprovalDate_7
+            // 
+            this.ApprovalDate_7.HeaderText = "■承認日付_7";
+            this.ApprovalDate_7.Name = "ApprovalDate_7";
+            this.ApprovalDate_7.Visible = false;
+            // 
+            // ApprovalOrder_7
+            // 
+            this.ApprovalOrder_7.HeaderText = "■承認順番_7";
+            this.ApprovalOrder_7.Name = "ApprovalOrder_7";
+            this.ApprovalOrder_7.Visible = false;
+            // 
+            // ApprovalName_8
+            // 
+            dataGridViewCellStyle23.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleCenter;
+            this.ApprovalName_8.DefaultCellStyle = dataGridViewCellStyle23;
+            this.ApprovalName_8.HeaderText = "承認者8\r\n承認";
+            this.ApprovalName_8.Name = "ApprovalName_8";
+            this.ApprovalName_8.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable;
+            this.ApprovalName_8.Visible = false;
+            this.ApprovalName_8.Width = 110;
+            // 
+            // ApprovalCode_8
+            // 
+            this.ApprovalCode_8.HeaderText = "■承認者コード_8";
+            this.ApprovalCode_8.Name = "ApprovalCode_8";
+            this.ApprovalCode_8.Visible = false;
+            // 
+            // ApprovalAuthority_8
+            // 
+            this.ApprovalAuthority_8.HeaderText = "■承認権限区分_8";
+            this.ApprovalAuthority_8.Name = "ApprovalAuthority_8";
+            this.ApprovalAuthority_8.Visible = false;
+            // 
+            // ApprovalDate_8
+            // 
+            this.ApprovalDate_8.HeaderText = "■承認日付_8";
+            this.ApprovalDate_8.Name = "ApprovalDate_8";
+            this.ApprovalDate_8.Visible = false;
+            // 
+            // ApprovalOrder_8
+            // 
+            this.ApprovalOrder_8.HeaderText = "■承認順番_8";
+            this.ApprovalOrder_8.Name = "ApprovalOrder_8";
+            this.ApprovalOrder_8.Visible = false;
+            // 
+            // ApprovalName_9
+            // 
+            dataGridViewCellStyle24.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleCenter;
+            this.ApprovalName_9.DefaultCellStyle = dataGridViewCellStyle24;
+            this.ApprovalName_9.HeaderText = "承認者9\r\n承認";
+            this.ApprovalName_9.Name = "ApprovalName_9";
+            this.ApprovalName_9.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable;
+            this.ApprovalName_9.Visible = false;
+            this.ApprovalName_9.Width = 110;
+            // 
+            // ApprovalCode_9
+            // 
+            this.ApprovalCode_9.HeaderText = "■承認者コード_9";
+            this.ApprovalCode_9.Name = "ApprovalCode_9";
+            this.ApprovalCode_9.Visible = false;
+            // 
+            // ApprovalAuthority_9
+            // 
+            this.ApprovalAuthority_9.HeaderText = "■承認権限区分_9";
+            this.ApprovalAuthority_9.Name = "ApprovalAuthority_9";
+            this.ApprovalAuthority_9.Visible = false;
+            // 
+            // ApprovalDate_9
+            // 
+            this.ApprovalDate_9.HeaderText = "■承認日付_9";
+            this.ApprovalDate_9.Name = "ApprovalDate_9";
+            this.ApprovalDate_9.Visible = false;
+            // 
+            // ApprovalOrder_9
+            // 
+            this.ApprovalOrder_9.HeaderText = "■承認順番_9";
+            this.ApprovalOrder_9.Name = "ApprovalOrder_9";
+            this.ApprovalOrder_9.Visible = false;
+            // 
+            // ApprovalName_10
+            // 
+            dataGridViewCellStyle25.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleCenter;
+            this.ApprovalName_10.DefaultCellStyle = dataGridViewCellStyle25;
+            this.ApprovalName_10.HeaderText = "承認者10\r\n承認";
+            this.ApprovalName_10.Name = "ApprovalName_10";
+            this.ApprovalName_10.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable;
+            this.ApprovalName_10.Visible = false;
+            this.ApprovalName_10.Width = 110;
+            // 
+            // ApprovalCode_10
+            // 
+            this.ApprovalCode_10.HeaderText = "■承認者コード_10";
+            this.ApprovalCode_10.Name = "ApprovalCode_10";
+            this.ApprovalCode_10.Visible = false;
+            // 
+            // ApprovalAuthority_10
+            // 
+            this.ApprovalAuthority_10.HeaderText = "■承認権限区分_10";
+            this.ApprovalAuthority_10.Name = "ApprovalAuthority_10";
+            this.ApprovalAuthority_10.Visible = false;
+            // 
+            // ApprovalDate_10
+            // 
+            this.ApprovalDate_10.HeaderText = "■承認日付_10";
+            this.ApprovalDate_10.Name = "ApprovalDate_10";
+            this.ApprovalDate_10.Visible = false;
+            // 
+            // ApprovalOrder_10
+            // 
+            this.ApprovalOrder_10.HeaderText = "■承認順番_10";
+            this.ApprovalOrder_10.Name = "ApprovalOrder_10";
+            this.ApprovalOrder_10.Visible = false;
+            // 
+            // btnEnd
+            // 
+            this.btnEnd.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right)));
+            this.btnEnd.BackColor = System.Drawing.Color.Magenta;
+            this.btnEnd.Font = new System.Drawing.Font("ＭＳ 明朝", 12F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(128)));
+            this.btnEnd.ForeColor = System.Drawing.Color.Black;
+            this.btnEnd.Location = new System.Drawing.Point(1287, 597);
+            this.btnEnd.Name = "btnEnd";
+            this.btnEnd.Size = new System.Drawing.Size(120, 30);
+            this.btnEnd.TabIndex = 20;
+            this.btnEnd.Text = "終　了";
+            this.btnEnd.UseVisualStyleBackColor = false;
+            this.btnEnd.Click += new System.EventHandler(this.btnEnd_Click);
+            // 
+            // groupBoxEx1
+            // 
+            this.groupBoxEx1.BorderColor = System.Drawing.Color.Black;
+            this.groupBoxEx1.Controls.Add(this.comboBox1);
+            this.groupBoxEx1.Controls.Add(this.label1);
+            this.groupBoxEx1.Controls.Add(this.radioButton2);
+            this.groupBoxEx1.Controls.Add(this.radioButton1);
+            this.groupBoxEx1.Location = new System.Drawing.Point(223, 13);
+            this.groupBoxEx1.Name = "groupBoxEx1";
+            this.groupBoxEx1.Size = new System.Drawing.Size(281, 38);
+            this.groupBoxEx1.TabIndex = 31;
+            this.groupBoxEx1.TabStop = false;
+            // 
+            // comboBox1
+            // 
+            this.comboBox1.BackColor = System.Drawing.Color.WhiteSmoke;
+            this.comboBox1.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
+            this.comboBox1.DropDownWidth = 120;
+            this.comboBox1.FlatStyle = System.Windows.Forms.FlatStyle.Popup;
+            this.comboBox1.Font = new System.Drawing.Font("ＭＳ 明朝", 12F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(128)));
+            this.comboBox1.FormattingEnabled = true;
+            this.comboBox1.Location = new System.Drawing.Point(164, 7);
+            this.comboBox1.Name = "comboBox1";
+            this.comboBox1.Size = new System.Drawing.Size(59, 24);
+            this.comboBox1.TabIndex = 32;
+            this.comboBox1.SelectedIndexChanged += new System.EventHandler(this.comboBox1_SelectedIndexChanged);
+            // 
+            // label1
+            // 
+            this.label1.AutoSize = true;
+            this.label1.Location = new System.Drawing.Point(229, 12);
+            this.label1.Name = "label1";
+            this.label1.Size = new System.Drawing.Size(24, 15);
+            this.label1.TabIndex = 0;
+            this.label1.Text = "月";
+            // 
+            // radioButton2
+            // 
+            this.radioButton2.AutoSize = true;
+            this.radioButton2.Location = new System.Drawing.Point(80, 10);
+            this.radioButton2.Name = "radioButton2";
+            this.radioButton2.Size = new System.Drawing.Size(76, 19);
+            this.radioButton2.TabIndex = 23;
+            this.radioButton2.TabStop = true;
+            this.radioButton2.Text = "月指定";
+            this.radioButton2.UseVisualStyleBackColor = true;
+            this.radioButton2.CheckedChanged += new System.EventHandler(this.radioButton2_CheckedChanged);
+            // 
+            // radioButton1
+            // 
+            this.radioButton1.AutoSize = true;
+            this.radioButton1.Location = new System.Drawing.Point(15, 10);
+            this.radioButton1.Name = "radioButton1";
+            this.radioButton1.Size = new System.Drawing.Size(59, 19);
+            this.radioButton1.TabIndex = 22;
+            this.radioButton1.TabStop = true;
+            this.radioButton1.Text = "通年";
+            this.radioButton1.UseVisualStyleBackColor = true;
+            this.radioButton1.CheckedChanged += new System.EventHandler(this.radioButton1_CheckedChanged);
+            // 
+            // FrmSalesConfirm
+            // 
+            this.AutoScaleDimensions = new System.Drawing.SizeF(9F, 15F);
+            this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
+            this.BackColor = System.Drawing.Color.Black;
+            this.ClientSize = new System.Drawing.Size(1417, 633);
+            this.Controls.Add(this.btnEnd);
+            this.Controls.Add(this.dgvMaster);
+            this.Controls.Add(this.panel1);
+            this.Controls.Add(this.label3);
+            this.Font = new System.Drawing.Font("ＭＳ 明朝", 11.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(128)));
+            this.Margin = new System.Windows.Forms.Padding(4);
+            this.Name = "FrmSalesConfirm";
+            this.FormClosing += new System.Windows.Forms.FormClosingEventHandler(this.FrmSelectPayment_FormClosing);
+            this.Load += new System.EventHandler(this.FrmSalesConfirm_Load);
+            this.panel1.ResumeLayout(false);
+            this.panel1.PerformLayout();
+            ((System.ComponentModel.ISupportInitialize)(this.numericUpDown2)).EndInit();
+            ((System.ComponentModel.ISupportInitialize)(this.dgvMaster)).EndInit();
+            this.groupBoxEx1.ResumeLayout(false);
+            this.groupBoxEx1.PerformLayout();
+            this.ResumeLayout(false);
+
+        }
+
+        #endregion
+
+        private System.Windows.Forms.Label label3;
+        private System.Windows.Forms.Panel panel1;
+        private System.Windows.Forms.Label label2;
+        private System.Windows.Forms.DataGridView dgvMaster;
+        private System.Windows.Forms.Button btnEnd;
+        private System.Windows.Forms.DataGridViewTextBoxColumn EditStatus;
+        private System.Windows.Forms.DataGridViewTextBoxColumn No;
+        private System.Windows.Forms.DataGridViewTextBoxColumn OrderersDivision;
+        private System.Windows.Forms.DataGridViewTextBoxColumn OrderersCode;
+        private System.Windows.Forms.DataGridViewTextBoxColumn SeqNo;
+        private System.Windows.Forms.DataGridViewTextBoxColumn LineCount;
+        private System.Windows.Forms.DataGridViewTextBoxColumn OrderersName;
+        private System.Windows.Forms.DataGridViewTextBoxColumn DepositDate;
+        private System.Windows.Forms.DataGridViewTextBoxColumn DepositAmountCash;
+        private System.Windows.Forms.DataGridViewTextBoxColumn DepositAmountBill;
+        private System.Windows.Forms.DataGridViewTextBoxColumn RequestNo;
+        private System.Windows.Forms.DataGridViewTextBoxColumn OrderNo;
+        private System.Windows.Forms.DataGridViewTextBoxColumn ConstructionName;
+        private System.Windows.Forms.DataGridViewTextBoxColumn ConstructionName_Raw;
+        private System.Windows.Forms.DataGridViewTextBoxColumn PaymentSchedule;
+        private System.Windows.Forms.DataGridViewTextBoxColumn BillCreationDate;
+        private System.Windows.Forms.DataGridViewTextBoxColumn BillPrice;
+        private System.Windows.Forms.DataGridViewTextBoxColumn TaxPrice;
+        private System.Windows.Forms.DataGridViewTextBoxColumn DepositAmount;
+        private System.Windows.Forms.DataGridViewTextBoxColumn DiscountAmount;
+        private System.Windows.Forms.DataGridViewTextBoxColumn CnstrPrice;
+        private System.Windows.Forms.DataGridViewTextBoxColumn Fees;
+        private System.Windows.Forms.DataGridViewTextBoxColumn OtherAdjustments;
+        private System.Windows.Forms.DataGridViewTextBoxColumn CarryAmount;
+        private System.Windows.Forms.DataGridViewTextBoxColumn PersonName;
+        private System.Windows.Forms.DataGridViewTextBoxColumn PersonCode;
+        private System.Windows.Forms.DataGridViewTextBoxColumn PersonDate;
+        private System.Windows.Forms.DataGridViewTextBoxColumn ApprovalName_1;
+        private System.Windows.Forms.DataGridViewTextBoxColumn ApprovalCode_1;
+        private System.Windows.Forms.DataGridViewTextBoxColumn ApprovalAuthority_1;
+        private System.Windows.Forms.DataGridViewTextBoxColumn ApprovalDate_1;
+        private System.Windows.Forms.DataGridViewTextBoxColumn ApprovalOrder_1;
+        private System.Windows.Forms.DataGridViewTextBoxColumn ApprovalName_2;
+        private System.Windows.Forms.DataGridViewTextBoxColumn ApprovalCode_2;
+        private System.Windows.Forms.DataGridViewTextBoxColumn ApprovalAuthority_2;
+        private System.Windows.Forms.DataGridViewTextBoxColumn ApprovalDate_2;
+        private System.Windows.Forms.DataGridViewTextBoxColumn ApprovalOrder_2;
+        private System.Windows.Forms.DataGridViewTextBoxColumn ApprovalName_3;
+        private System.Windows.Forms.DataGridViewTextBoxColumn ApprovalCode_3;
+        private System.Windows.Forms.DataGridViewTextBoxColumn ApprovalAuthority_3;
+        private System.Windows.Forms.DataGridViewTextBoxColumn ApprovalDate_3;
+        private System.Windows.Forms.DataGridViewTextBoxColumn ApprovalOrder_3;
+        private System.Windows.Forms.DataGridViewTextBoxColumn ApprovalName_4;
+        private System.Windows.Forms.DataGridViewTextBoxColumn ApprovalCode_4;
+        private System.Windows.Forms.DataGridViewTextBoxColumn ApprovalAuthority_4;
+        private System.Windows.Forms.DataGridViewTextBoxColumn ApprovalDate_4;
+        private System.Windows.Forms.DataGridViewTextBoxColumn ApprovalOrder_4;
+        private System.Windows.Forms.DataGridViewTextBoxColumn ApprovalName_5;
+        private System.Windows.Forms.DataGridViewTextBoxColumn ApprovalCode_5;
+        private System.Windows.Forms.DataGridViewTextBoxColumn ApprovalAuthority_5;
+        private System.Windows.Forms.DataGridViewTextBoxColumn ApprovalDate_5;
+        private System.Windows.Forms.DataGridViewTextBoxColumn ApprovalOrder_5;
+        private System.Windows.Forms.DataGridViewTextBoxColumn ApprovalName_6;
+        private System.Windows.Forms.DataGridViewTextBoxColumn ApprovalCode_6;
+        private System.Windows.Forms.DataGridViewTextBoxColumn ApprovalAuthority_6;
+        private System.Windows.Forms.DataGridViewTextBoxColumn ApprovalDate_6;
+        private System.Windows.Forms.DataGridViewTextBoxColumn ApprovalOrder_6;
+        private System.Windows.Forms.DataGridViewTextBoxColumn ApprovalName_7;
+        private System.Windows.Forms.DataGridViewTextBoxColumn ApprovalCode_7;
+        private System.Windows.Forms.DataGridViewTextBoxColumn ApprovalAuthority_7;
+        private System.Windows.Forms.DataGridViewTextBoxColumn ApprovalDate_7;
+        private System.Windows.Forms.DataGridViewTextBoxColumn ApprovalOrder_7;
+        private System.Windows.Forms.DataGridViewTextBoxColumn ApprovalName_8;
+        private System.Windows.Forms.DataGridViewTextBoxColumn ApprovalCode_8;
+        private System.Windows.Forms.DataGridViewTextBoxColumn ApprovalAuthority_8;
+        private System.Windows.Forms.DataGridViewTextBoxColumn ApprovalDate_8;
+        private System.Windows.Forms.DataGridViewTextBoxColumn ApprovalOrder_8;
+        private System.Windows.Forms.DataGridViewTextBoxColumn ApprovalName_9;
+        private System.Windows.Forms.DataGridViewTextBoxColumn ApprovalCode_9;
+        private System.Windows.Forms.DataGridViewTextBoxColumn ApprovalAuthority_9;
+        private System.Windows.Forms.DataGridViewTextBoxColumn ApprovalDate_9;
+        private System.Windows.Forms.DataGridViewTextBoxColumn ApprovalOrder_9;
+        private System.Windows.Forms.DataGridViewTextBoxColumn ApprovalName_10;
+        private System.Windows.Forms.DataGridViewTextBoxColumn ApprovalCode_10;
+        private System.Windows.Forms.DataGridViewTextBoxColumn ApprovalAuthority_10;
+        private System.Windows.Forms.DataGridViewTextBoxColumn ApprovalDate_10;
+        private System.Windows.Forms.DataGridViewTextBoxColumn ApprovalOrder_10;
+        private System.Windows.Forms.Label label5;
+        private System.Windows.Forms.ComboBox comboBox3;
+        private System.Windows.Forms.Label label4;
+        private System.Windows.Forms.ComboBox comboBox2;
+        private System.Windows.Forms.Label label1;
+        private System.Windows.Forms.RadioButton radioButton2;
+        private System.Windows.Forms.RadioButton radioButton1;
+        private System.Windows.Forms.NumericUpDown numericUpDown2;
+        private System.Windows.Forms.Label label7;
+        private System.Windows.Forms.Label label6;
+        private CustomControls.GroupBoxEx groupBoxEx1;
+        private System.Windows.Forms.ComboBox comboBox1;
+    }
+}
+
Index: branches/src/ProcessManagement/ProcessManagement/Forms/DataEntry/Request/SalesConfirm/FrmSalesConfirm.cs
===================================================================
--- branches/src/ProcessManagement/ProcessManagement/Forms/DataEntry/Request/SalesConfirm/FrmSalesConfirm.cs	(nonexistent)
+++ branches/src/ProcessManagement/ProcessManagement/Forms/DataEntry/Request/SalesConfirm/FrmSalesConfirm.cs	(revision 60)
@@ -0,0 +1,3189 @@
+﻿using System;
+using System.Collections.Generic;
+using System.ComponentModel;
+using System.Data;
+using System.Drawing;
+using System.Linq;
+using System.Text;
+using System.Threading.Tasks;
+using System.Windows.Forms;
+using System.Collections;
+
+using log4net;
+using log4net.Appender;
+using log4net.Repository.Hierarchy;
+
+using ProcessManagement.Common;
+using ProcessManagement.DB.IOAccess;
+using ProcessManagement.DataModel;
+using ProcessManagement.DB.Core;
+using ProcessManagement.Forms.Master;
+using ProcessManagement.Forms.DataEntry;
+using ProcessManagement.Forms.CustomControls;
+using ProcessManagement.Forms.ControlsAction;
+using ProcessManagement.Forms.SubForms;
+using System.Reflection;
+
+/// <summary>
+/// 「売上確認」画面
+/// </summary>
+namespace ProcessManagement.Forms.DataEntry
+{
+    public partial class FrmSalesConfirm : Form
+    {
+        /// <summary>
+        /// ロガー
+        /// </summary>
+        private static readonly log4net.ILog logger = log4net.LogManager.GetLogger(System.Reflection.MethodBase.GetCurrentMethod().DeclaringType);
+
+        /// <summary>
+        /// 承認状態
+        /// </summary>
+        public enum ApprovalStatus
+        {
+            None = 0,
+            InCharge,
+            InApproval,
+            Approved,
+        }
+
+        /// <summary>
+        /// 合計行の見出し
+        /// </summary>
+        private enum TotalRows
+        {
+            小計 = 1,
+            入金金額,
+            調整後金額,
+            差額,
+        }
+
+        /// <summary>
+        /// 表示カラム ※■は非表示セル
+        /// </summary>
+        private enum DispColumn
+        {
+            RowType = 0,                                                        // ■編集状態
+            No,                                                                 // No
+            OrderersDivision,                                                   // ■発注先区分
+            OrderersCode,                                                       // ■発注者コード
+            SeqNo,                                                              // ■連番
+            LineCount,                                                          // ■行番号
+            OrderersName,                                                       // 請求先名
+            DepositDate,                                                        // 入金日
+            DepositAmountCash,                                                  // 入金金額 (振込み)
+            DepositAmountBill,                                                  // 入金金額 (手形)
+            RequestNo,                                                          // ■請求No.
+            OrderNo,                                                            // ■受付番号
+            ConstructionName,                                                   // 現場名
+            ConstructionName_Raw,                                               // ■現場名 (DB登録値)
+            PaymentSchedule,                                                    // 入金予定日
+            BillCreationDate,                                                   // 請求日
+            BillPrice,                                                          // 請求金額 (税抜)
+            TaxPrice,                                                           // 請求金額 (消費税)
+            DepositAmount,                                                      // 入金金額
+            DiscountAmount,                                                     // 値引金額
+            CnstrPrice,                                                         // 協力金
+            Fees,                                                               // 手数料
+            OtherAdjustments,                                                   // その他調整
+            CarryAmount,                                                        // 次回繰越
+            PersonName,                                                         // 担当者承認
+            PersonCode,                                                         // ■担当者コード
+            PersonDate,                                                         // ■担当者日付
+            ApprovalName_1,                                                     // 承認者１承認
+            ApprovalCode_1,                                                     // ■承認者コード_1
+            ApprovalAuthority_1,                                                // ■承認権限区分_1
+            ApprovalDate_1,                                                     // ■承認日付_1
+            ApprovalOrder_1,                                                    // ■承認順番_1
+            ApprovalName_2,                                                     // 承認者２承認
+            ApprovalCode_2,                                                     // ■承認者コード_2
+            ApprovalAuthority_2,                                                // ■承認権限区分_2
+            ApprovalDate_2,                                                     // ■承認日付_2
+            ApprovalOrder_2,                                                    // ■承認順番_2
+            ApprovalName_3,                                                     // 承認者３承認
+            ApprovalCode_3,                                                     // ■承認者コード_3
+            ApprovalAuthority_3,                                                // ■承認権限区分_3
+            ApprovalDate_3,                                                     // ■承認日付_3
+            ApprovalOrder_3,                                                    // ■承認順番_3
+            ApprovalName_4,                                                     // 承認者４承認
+            ApprovalCode_4,                                                     // ■承認者コード_4
+            ApprovalAuthority_4,                                                // ■承認権限区分_4
+            ApprovalDate_4,                                                     // ■承認日付_4
+            ApprovalOrder_4,                                                    // ■承認順番_4
+            ApprovalName_5,                                                     // 承認者５承認
+            ApprovalCode_5,                                                     // ■承認者コード_5
+            ApprovalAuthority_5,                                                // ■承認権限区分_5
+            ApprovalDate_5,                                                     // ■承認日付_5
+            ApprovalOrder_5,                                                    // ■承認順番_5
+            ApprovalName_6,                                                     // 承認者６承認
+            ApprovalCode_6,                                                     // ■承認者コード_6
+            ApprovalAuthority_6,                                                // ■承認権限区分_6
+            ApprovalDate_6,                                                     // ■承認日付_6
+            ApprovalOrder_6,                                                    // ■承認順番_6
+            ApprovalName_7,                                                     // 承認者７承認
+            ApprovalCode_7,                                                     // ■承認者コード_7
+            ApprovalAuthority_7,                                                // ■承認権限区分_7
+            ApprovalDate_7,                                                     // ■承認日付_7
+            ApprovalOrder_7,                                                    // ■承認順番_7
+            ApprovalName_8,                                                     // 承認者８承認
+            ApprovalCode_8,                                                     // ■承認者コード_8
+            ApprovalAuthority_8,                                                // ■承認権限区分_8
+            ApprovalDate_8,                                                     // ■承認日付_8
+            ApprovalOrder_8,                                                    // ■承認順番_8
+            ApprovalName_9,                                                     // 承認者９承認
+            ApprovalCode_9,                                                     // ■承認者コード_9
+            ApprovalAuthority_9,                                                // ■承認権限区分_9
+            ApprovalDate_9,                                                     // ■承認日付_9
+            ApprovalOrder_9,                                                    // ■承認順番_9
+            ApprovalName_10,                                                    // 承認者１０承認
+            ApprovalCode_10,                                                    // ■承認者コード_10
+            ApprovalAuthority_10,                                               // ■承認権限区分_10
+            ApprovalDate_10,                                                    // ■承認日付_10
+            ApprovalOrder_10,                                                   // ■承認順番_10
+        }
+
+        /// <summary>
+        /// 取得するデータ項目
+        /// </summary>
+        private enum ClickGetData
+        {
+            OrderersDivision = 0,
+            OrderersCode,
+            TargetDate,
+            SeqNo,
+            DepositDate,
+            DepositAmountCash,
+            DepositAmountBill,
+            CorporateStatusName,
+            CorporateStatusPoint,
+            OrderersName1,
+            OrderersName2,
+            LineCount,
+            RequestNo,
+            OrderNo,
+            DepositAmount,
+            DiscountAmount,
+            CnstrPrice,
+            Fees,
+            OtherAdjustments,
+            CarryAmount,
+            ApprovalPersonCode,
+            ApprovalDate,
+            ApprovalEndFlg,
+            PersonName,
+            DepartmentCode,
+            BillCreationDate,
+            BillPrice,
+            TaxPrice,
+            ConstructionCode,
+            ConstructionPersonCode,
+            ConstrSubPersonCode,
+            ConstructionInstructor,
+            DetailNo,
+            //ReqConstructionName,
+            DetailString,
+            ApprovalPersonName1,
+            ApprovalPerson1,
+            ApprovalAuthority1,
+            ApprovalDate1,
+            ApprovalPersonName2,
+            ApprovalPerson2,
+            ApprovalAuthority2,
+            ApprovalDate2,
+            ApprovalPersonName3,
+            ApprovalPerson3,
+            ApprovalAuthority3,
+            ApprovalDate3,
+            ApprovalPersonName4,
+            ApprovalPerson4,
+            ApprovalAuthority4,
+            ApprovalDate4,
+            ApprovalPersonName5,
+            ApprovalPerson5,
+            ApprovalAuthority5,
+            ApprovalDate5,
+            ApprovalPersonName6,
+            ApprovalPerson6,
+            ApprovalAuthority6,
+            ApprovalDate6,
+            ApprovalPersonName7,
+            ApprovalPerson7,
+            ApprovalAuthority7,
+            ApprovalDate7,
+            ApprovalPersonName8,
+            ApprovalPerson8,
+            ApprovalAuthority8,
+            ApprovalDate8,
+            ApprovalPersonName9,
+            ApprovalPerson9,
+            ApprovalAuthority9,
+            ApprovalDate9,
+            ApprovalPersonName10,
+            ApprovalPerson10,
+            ApprovalAuthority10,
+            ApprovalDate10
+        }
+
+        /// <summary>
+        /// 承認情報
+        /// </summary>
+        private class ApproveData
+        {
+            public int Key { get; set; }
+            public string Value { get; set; }
+            public int Order { get; set; }
+            public int ApprovalAuthority { get; set; }
+        }
+
+        /// <summary>
+        /// 請求先キー
+        /// </summary>
+        private class OrderersKey
+        {
+            public int OrderersDivision;
+            public int OrderersCode;
+        }
+
+        /// <summary>
+        /// 入金請求先情報
+        /// </summary>
+        private class DepositOrderer
+        {
+            public bool Added = false;
+            private bool deleted = false;
+            public bool Deleted
+            {
+                get { return deleted && Deposits.All(d => d.Deleted); }
+                set
+                {
+                    deleted = value;
+                    foreach (var deposit in Deposits)
+                    {
+                        deposit.Deleted = value;
+                    }
+                }
+            }
+            public int No;
+            public int OrderersDivision;
+            public int OrderersCode;
+            public string OrderersName;
+            public List<Deposit> Deposits = new List<Deposit>();
+            public List<Deposit> VisibleDeposits
+            {
+                get { return Deposits.Where(d => !d.Deleted).ToList(); }
+            }
+            public List<DepositDetail> DepositDetails = new List<DepositDetail>();
+            public List<DepositDetail> VisibleDepositDetails
+            {
+                get { return DepositDetails.Where(dd => dd.Visible && !dd.Deleted).ToList(); }
+            }
+            public int Size
+            {
+                get { return Math.Max(Math.Max(VisibleDeposits.Count, VisibleDepositDetails.Count), 1); }
+            }
+            public Deposit FindDepositBySeqNo(int seqNo)
+            {
+                return Deposits.Find(d => d.SeqNo == seqNo);
+            }
+            public DepositDetail FindDepositDetailByLineCount(int lineCount)
+            {
+                return DepositDetails.Find(dd => dd.LineCount == lineCount);
+            }
+            public int GetNextSeqNo()
+            {
+                if (Deposits.Count == 0)
+                    return 1;
+                return Deposits.Max(d => d.SeqNo) + 1;
+            }
+            public int GetNextLineCount()
+            {
+                if (DepositDetails.Count == 0)
+                    return 1;
+                return DepositDetails.Max(dd => dd.LineCount) + 1;
+            }
+            public bool HasApprovedByStaff
+            {
+                get
+                {
+                    if (DepositDetails.Count == 0)
+                        return false;
+                    return DepositDetails.Any(dd => dd.IsApprovedByStaff);
+                }
+            }
+            public bool HasApprovedByApprover
+            {
+                get
+                {
+                    if (DepositDetails.Count == 0)
+                        return false;
+                    return DepositDetails.Any(dd => dd.IsApprovedByApprover);
+                }
+            }
+            public bool HasApprovedByLastApprover
+            {
+                get
+                {
+                    if (DepositDetails.Count == 0)
+                        return false;
+                    return DepositDetails.Any(dd => dd.IsApprovedByLastApprover);
+                }
+            }
+        }
+
+        /// <summary>
+        /// 入金情報
+        /// </summary>
+        private class Deposit
+        {
+            public bool Added = false;
+            public bool Editted = false;
+            public bool Deleted = false;
+            public int SeqNo;
+            public string DepositDate;
+            public int? DepositAmountCash;
+            public int? DepositAmountBill;
+            public bool CanRemove
+            {
+                get
+                {
+                    // 追加行かつ未入力の場合
+                    return Added
+                        && string.IsNullOrEmpty(DepositDate)
+                        && !DepositAmountCash.HasValue
+                        && !DepositAmountBill.HasValue;
+                }
+            }
+        }
+
+        /// <summary>
+        /// 入金明細情報
+        /// </summary>
+        private class DepositDetail
+        {
+            public bool Added = false;
+            public bool Editted = false;
+            public bool Deleted = false;
+            public bool Visible;
+            public int SeqNo;
+            public int LineCount;
+            public int RequestNo;
+            public int OrderNo;
+            public string ConstructionName;
+            public string ConstructionNameRow;
+            //public string PaymentSchedule;
+            public string BillCreationDate;
+            public int BillPrice;
+            public int TaxPrice;
+            public int DepositAmount;
+            public int DiscountAmount;
+            public int CnstrPrice;
+            public int Fees;
+            public int OtherAdjustments;
+            public int CarryAmount;
+            public string ApprovalPersonName;
+            public int ApprovalPersonCode;
+            public string ApprovalDate;
+            public int ApprovalEndFlg;
+            public int DepartmentCode;
+            public int ConstructionCode;
+            public int ConstructionPersonCode;
+            public int ConstrSubPersonCode;
+            public int ConstructionInstructor;
+            public ApprovalStatus Status = ApprovalStatus.None;
+            public bool UpperApprovalInUser = false;
+            public List<DepositApproval> DepositApprovals = new List<DepositApproval>();
+            public bool IsApprovedByStaff
+            {
+                get { return !string.IsNullOrEmpty(ApprovalDate); }
+            }
+            public bool IsApprovedByApprover
+            {
+                get
+                {
+                    if (DepositApprovals.Count == 0)
+                        return false;
+                    return DepositApprovals.First().ApprovalDate != "";
+                }
+            }
+            public bool IsApprovedByLastApprover
+            {
+                get
+                {
+                    if (DepositApprovals.Count == 0)
+                        return false;
+                    return DepositApprovals.Last().ApprovalDate != "";
+                }
+            }
+        }
+
+        /// <summary>
+        /// 入金確認承認情報
+        /// </summary>
+        private class DepositApproval
+        {
+            public bool Added = false;
+            public bool Editted = false;
+            public int ApprovalNo;
+            public int ApprovalPerson;
+            public string ApprovalPersonName;
+            public int ApprovalAuthority;
+            public string ApprovalDate;
+        }
+
+        private List<DepositOrderer> depositOrderers;
+
+        /// <summary>編集フラグ</summary>
+        private bool isDirty = false;
+
+        /// <summary>編集前のセルの内容</summary>
+        private string oldCellValue = "";
+
+        /// <summary>データ表示の対象営業期</summary>
+        private int m_Select_TargetBusinessPeriod = 0;
+
+        /// <summary>データ表示の対象月</summary>
+        private int m_Select_TargetDate = 0;
+
+        /// <summary>データ表示の対象部署</summary>
+        private int m_Select_TargetDepartment = 0;
+
+        /// <summary>データ表示の対象担当者</summary>
+        private int m_Select_TargetPerson = 0;
+
+        /// <summary>終了ボタン押下フラグ</summary>
+        private bool m_CloseingProcessOff = false;
+
+        /// <summary>データ表示の対象期間</summary>
+        private int m_TargetPeriod = 2;
+
+        // ユーザー情報
+        private ClsSecurityPermission.UserInfo m_UserInfo = new ClsSecurityPermission.UserInfo()
+        {
+            m_Type = CommonDefine.SecurityRankPos.NormalAuthority,
+            m_GeneralAffairsFlg = 0,
+            m_SecRange = ClsSecurityPermission.SecRangeType.InCharge
+        };
+
+        // 部署コンボボックス用リスト
+        public List<KeyValuePair<int, String>> listDepartment = new List<KeyValuePair<int, String>>();
+
+        // 担当者コンボボックス用リスト
+        public List<KeyValuePair<int, String>> listPerson = new List<KeyValuePair<int, String>>();
+
+        /// <summary>
+        /// コンストラクタ
+        /// </summary>
+        public FrmSalesConfirm()
+        {
+            InitializeComponent();
+        }
+
+        /// <summary>
+        /// フォームロードイベント
+        /// </summary>
+        /// <param name="sender"></param>
+        /// <param name="e"></param>
+        private void FrmSalesConfirm_Load(object sender, EventArgs e)
+        {
+            try
+            {
+                // 対象月コンボBOX設定
+                //IODepositData IoDd = new IODepositData();
+                //string now = DateTime.UtcNow.ToString("yyyy/MM");
+                //List<DepositData> lstDd = new List<DepositData>();
+                //List<string> lstDate = new List<string>();
+
+                //IoDd.SelectAction(" group by TargetDate order by TargetDate desc", ref lstDd);
+
+                //foreach (DepositData DdInfo in lstDd)
+                //{
+                //    lstDate.Add(DdInfo.TargetDate.Insert(4, "/"));
+                //}
+                //if (lstDate.IndexOf(now) < 0)
+                //{
+                //    lstDate.Insert(0, now);
+                //}
+
+                //comboBox1.Items.AddRange(lstDate.ToArray());
+
+                //////////////////////////////////////////////////////////////////////////////
+                // ■画面表示時のイベントを停止
+                //////////////////////////////////////////////////////////////////////////////
+
+                radioButton1.CheckedChanged -= new System.EventHandler(this.radioButton1_CheckedChanged);
+                comboBox1.SelectedIndexChanged -= new System.EventHandler(this.comboBox1_SelectedIndexChanged);
+                comboBox2.SelectedIndexChanged -= new System.EventHandler(this.comboBox2_SelectedIndexChanged);
+                comboBox3.SelectedIndexChanged -= new System.EventHandler(this.comboBox3_SelectedIndexChanged);
+                numericUpDown2.ValueChanged -= new System.EventHandler(this.numericUpDown2_ValueChanged);
+
+
+                ///////////////////////////////////////////////////////////////////////////
+                // ■表示条件設定
+                ///////////////////////////////////////////////////////////////////////////
+
+                // 営業期
+                int iBusinessPeriod = CommonMotions.SystemMasterData.BusinessPeriod;
+
+                // 最大営業期（現在の営業期）
+                numericUpDown2.Maximum = iBusinessPeriod;
+                // 最小営業期（現在の営業期-過去年数）
+                numericUpDown2.Minimum = iBusinessPeriod - m_TargetPeriod;
+                // 初期値は最大営業期
+                numericUpDown2.Value = iBusinessPeriod;
+
+
+                // 対象月
+                comboBox1.Items.Add("　");
+
+                for (int iMonthCount = 1; iMonthCount < 13; iMonthCount++)
+                {
+                    comboBox1.Items.Add(iMonthCount);
+                }
+                comboBox1.SelectedIndex = 0;
+
+                // 部署
+                this.listDepartment = getDepartmentList(0);
+
+                comboBox2.DataSource = listDepartment;
+                comboBox2.SelectedIndex = 0;
+
+                // 担当者
+                this.listPerson = getPersonList(0);
+
+                comboBox3.DataSource = listPerson;
+                comboBox3.SelectedIndex = 0;
+
+                // イベントを停止させているため、強制的に非活性にする
+                comboBox1.Enabled = false;
+                // 初期フォーカスはラジオボタン（通年）
+                radioButton1.Checked = true;
+
+                ///////////////////////////////////////////////////////////////////////////
+                // ■一覧表示設定
+                ///////////////////////////////////////////////////////////////////////////
+
+                // ユーザ権限設定
+                ClsSecurityPermission.SetUserType(m_UserInfo);
+
+                // ちらつきを抑えるため、ダブルバッファリングを有効にする。
+                dgvMaster.GetType().InvokeMember("DoubleBuffered", BindingFlags.NonPublic | BindingFlags.Instance | BindingFlags.SetProperty,
+                    null, dgvMaster, new object[] { true });
+
+                // 一覧のヘッダ色を設定する
+                SetGridHeaderColor();
+
+                // 一覧表示情報を取得する
+                DisplayData();
+
+
+            }
+            catch (Exception ex)
+            {
+                logger.ErrorFormat("システムエラー：{0}：{1}", CommonMotions.GetMethodName(), ex.Message);
+            }
+            finally
+            {
+                radioButton1.CheckedChanged += new System.EventHandler(this.radioButton1_CheckedChanged);
+                comboBox1.SelectedIndexChanged += new System.EventHandler(this.comboBox1_SelectedIndexChanged);
+                comboBox2.SelectedIndexChanged += new System.EventHandler(this.comboBox2_SelectedIndexChanged);
+                comboBox3.SelectedIndexChanged += new System.EventHandler(this.comboBox3_SelectedIndexChanged);
+                numericUpDown2.ValueChanged += new System.EventHandler(this.numericUpDown2_ValueChanged);
+            }
+        }
+
+        /// <summary>
+        /// 部署情報取得
+        /// </summary>
+        /// <param name="sender"></param>
+        /// <param name="e"></param>
+        private List<KeyValuePair<int, String>> getDepartmentList(int iPersonCode)
+        {
+            var listDepartment = new List<KeyValuePair<int, String>>();
+
+            listDepartment.Add(new KeyValuePair<int, String>(0, "すべて"));
+
+            var listResultSQL = new ArrayList();
+            listResultSQL = getDepartmentListQuery(iPersonCode);
+
+            foreach (object[] result in listResultSQL)
+            {
+                int iDepartmentCode = CommonMotions.cnvInt(result[0]);
+                String strDepartmentName = CommonMotions.cnvString(result[1]);
+                listDepartment.Add(new KeyValuePair<int, String>(iDepartmentCode, strDepartmentName));
+            }
+
+            return listDepartment;
+
+        }
+
+        /// <summary>
+        /// 部署情報取得SQL実行
+        /// </summary>
+        /// <param name="sender"></param>
+        /// <param name="e"></param>
+        private ArrayList getDepartmentListQuery(int iPersonCode)
+        {
+            try
+            {
+                var sql = new StringBuilder();
+
+                sql.Append("SELECT ");
+                sql.Append("DEPM.DepartmentCode ");                                          // 部署マスタ．部署コード
+                sql.Append(",DEPM.DepartmentString ");                                          // 部署マスタ．部署名
+                sql.Append("FROM ");
+                sql.Append("departmentmaster DEPM ");                                          // 部署マスタ
+
+                /////////////////////////////////////////////////////////////////////////////
+                // 検索条件(動的)START
+                /////////////////////////////////////////////////////////////////////////////
+                if (!iPersonCode.Equals(0))
+                {
+                    sql.Append("INNER JOIN personinchargemaster PERIM ");                      // 担当者マスタ
+                    sql.Append("ON DEPM.DepartmentCode = PERIM.DepartmentCode ");             // 担当者マスタ．部署コード = 部署マスタ．部署コード
+                    sql.AppendFormat("AND PERIM.PersonCode = {0} ", iPersonCode);             // 担当者マスタ．担当者コード = 画面．担当者コード（隠し項目）
+                }
+                /////////////////////////////////////////////////////////////////////////////
+                // 検索条件(動的)END
+                /////////////////////////////////////////////////////////////////////////////
+
+                sql.Append("WHERE ");
+                sql.Append("DEPM.DeleteFlg = 0 ");                                          // 部署マスタ．削除フラグ = 0
+                sql.Append("ORDER BY  ");
+                sql.Append("DEPM.DisplayOrder ASC");                                          // 部署マスタ．表示順（昇順）
+
+                var depDb = new IODepositData();
+                var data = new ArrayList();
+                if (!depDb.ExecuteReader(sql.ToString(), ref data)) return new ArrayList();
+                return data;
+            }
+            catch (Exception ex)
+            {
+                logger.ErrorFormat("システムエラー：{0}：{1}", CommonMotions.GetMethodName(), ex.Message);
+                return new ArrayList();
+            }
+
+        }
+
+        /// <summary>
+        /// 担当者情報取得
+        /// </summary>
+        /// <param name="sender"></param>
+        /// <param name="e"></param>
+        private List<KeyValuePair<int, String>> getPersonList(int iDepartmentCode)
+        {
+            var listDepartment = new List<KeyValuePair<int, String>>();
+
+            listDepartment.Add(new KeyValuePair<int, String>(0, "すべて"));
+
+            var listResultSQL = new ArrayList();
+            listResultSQL = getPersonListQuery(iDepartmentCode);
+
+            foreach (object[] result in listResultSQL)
+            {
+                int iPersonCode = CommonMotions.cnvInt(result[0]);
+                String strPersonName = CommonMotions.cnvString(result[1]);
+                listDepartment.Add(new KeyValuePair<int, String>(iPersonCode, strPersonName));
+            }
+
+            return listDepartment;
+
+        }
+
+        /// <summary>
+        /// 担当者情報取得SQL実行
+        /// </summary>
+        /// <param name="sender"></param>
+        /// <param name="e"></param>
+        private ArrayList getPersonListQuery(int iDepartmentCode)
+        {
+            try
+            {
+                var sql = new StringBuilder();
+
+                sql.Append("SELECT ");
+                sql.Append("PERIM.PersonCode ");                                          // 担当者マスタ．担当者コード
+                sql.Append(",PERIM.PersonName ");                                          // 担当者マスタ．担当者名
+                sql.Append("FROM ");
+                sql.Append("personinchargemaster PERIM ");                                          // 担当者マスタ
+                sql.Append("WHERE ");
+                sql.Append("PERIM.DeleteFlg = 0 ");                                          // 部署マスタ．削除フラグ = 0
+
+                /////////////////////////////////////////////////////////////////////////////
+                // 検索条件(動的)START
+                /////////////////////////////////////////////////////////////////////////////
+                if (!iDepartmentCode.Equals(0))
+                {
+                    sql.AppendFormat("AND PERIM.DepartmentCode = {0} ", iDepartmentCode);             // 担当者マスタ．担当者コード = 画面．担当者コード（隠し項目）
+                }
+                /////////////////////////////////////////////////////////////////////////////
+                // 検索条件(動的)END
+                /////////////////////////////////////////////////////////////////////////////
+
+                sql.Append("ORDER BY  ");
+                sql.Append("PERIM.DisplayOrder ASC");                                          // 部署マスタ．表示順（昇順）
+
+                var depDb = new IODepositData();
+                var data = new ArrayList();
+                if (!depDb.ExecuteReader(sql.ToString(), ref data)) return new ArrayList();
+                return data;
+            }
+            catch (Exception ex)
+            {
+                logger.ErrorFormat("システムエラー：{0}：{1}", CommonMotions.GetMethodName(), ex.Message);
+                return new ArrayList();
+            }
+
+        }
+
+        /// <summary>
+        /// 発注者追加ボタン押下時のイベント
+        /// </summary>
+        /// <param name="sender"></param>
+        /// <param name="e"></param>
+        private void btnAddCmp_Click(object sender, EventArgs e)
+        {
+            try
+            {
+                ResetTargetDate();
+                var f = new FrmSelectRequest(FrmSelectRequest.OpenMode.AddCmp);
+                f.FormClosed += new FormClosedEventHandler(NotifyAddCmp_FormClosed);
+                f.ShowDialog(this);
+            }
+            catch (Exception ex)
+            {
+                logger.ErrorFormat("システムエラー：{0}：{1}", CommonMotions.GetMethodName(), ex.Message);
+            }
+        }
+
+        /// <summary>
+        /// 発注者削除ボタン押下時のイベント
+        /// </summary>
+        /// <param name="sender"></param>
+        /// <param name="e"></param>
+        private void btnDelCmp_Click(object sender, EventArgs e)
+        {
+            try
+            {
+                ResetTargetDate();
+                if (dgvMaster.RowCount <= 0)
+                    return;
+                var depositOrderer = FindDepositOrderer(dgvMaster.CurrentCell.RowIndex);
+                if (depositOrderer.DepositDetails.Count > 0)
+                {
+                    MessageBox.Show("すでに現場が登録されているため、削除できません。", "削除エラー", MessageBoxButtons.OK, MessageBoxIcon.Error);
+                    return;
+                }
+                // 保存前のものは削除する
+                if (depositOrderer.Added)
+                    depositOrderers.Remove(depositOrderer);
+                // 保存済みのものは削除フラグを付与
+                else
+                    depositOrderer.Deleted = true;
+                RemoveDepositOrdererRows(depositOrderer);
+                isDirty = true;
+            }
+            catch (Exception ex)
+            {
+                logger.ErrorFormat("システムエラー：{0}：{1}", CommonMotions.GetMethodName(), ex.Message);
+            }
+        }
+
+        /// <summary>
+        /// 現場追加ボタン押下時のイベント
+        /// </summary>
+        /// <param name="sender"></param>
+        /// <param name="e"></param>
+        private void btnAddFld_Click(object sender, EventArgs e)
+        {
+            try
+            {
+                ResetTargetDate();
+                if (dgvMaster.RowCount <= 0)
+                    return;
+                // 現場が不明の場合のみ追加可能
+                if (!IsUnknownRow(dgvMaster.CurrentCell.RowIndex))
+                {
+                    MessageBox.Show("不明以外の行が選択されています。", "登録エラー", MessageBoxButtons.OK, MessageBoxIcon.Error);
+                    return;
+                }
+                var depositOrderer = FindDepositOrderer(dgvMaster.CurrentCell.RowIndex);
+                var f = new FrmSelectRegField();
+                f.m_OrderersDivision = depositOrderer.OrderersDivision;
+                f.m_OrderersCode = depositOrderer.OrderersCode;
+                foreach (var depositDetail in depositOrderer.VisibleDepositDetails)
+                {
+                    f.m_lstMyField.Add(new FrmSelectRegField.MyFieldData()
+                    {
+                        OrderersDivision = depositOrderer.OrderersDivision,
+                        OrderersCode = depositOrderer.OrderersCode,
+                        RequestNo = depositDetail.RequestNo,
+                        OrderNo = depositDetail.OrderNo,
+                        ConstructionName = depositDetail.ConstructionName,
+                        ConstructionName_Raw = depositDetail.ConstructionNameRow,
+                        BillCreationDate = depositDetail.BillCreationDate,
+                        BillPrice = depositDetail.BillPrice,
+                        TaxPrice = depositDetail.TaxPrice,
+                        DepositAmount = depositDetail.DepositAmount,
+                        PersonCode = depositDetail.ApprovalPersonCode,
+                        DeleteFlg = false,
+                        ReadOnly = depositDetail.IsApprovedByStaff,
+                    });
+                }
+                // 不明行を渡す必要がある
+                var unknownIndex = DetectUnknownIndex(dgvMaster.CurrentCell.RowIndex);
+                var unknownCell = dgvMaster.Rows[unknownIndex].Cells;
+                f.m_lstMyField.Add(new FrmSelectRegField.MyFieldData()
+                {
+                    OrderersDivision = depositOrderer.OrderersDivision,
+                    OrderersCode = depositOrderer.OrderersCode,
+                    ConstructionName = CommonMotions.cnvString(unknownCell[(int)DispColumn.ConstructionName].Value),
+                    ConstructionName_Raw = CommonMotions.cnvString(unknownCell[(int)DispColumn.ConstructionName_Raw].Value),
+                    DepositAmount = CommonMotions.cnvInt(unknownCell[(int)DispColumn.DepositAmount].Value),
+                    ReadOnly = true,
+                });
+                f.FormClosed += new FormClosedEventHandler(NotifyAddFld_FormClosed);
+                f.ShowDialog(this);
+            }
+            catch (Exception ex)
+            {
+                logger.ErrorFormat("システムエラー：{0}：{1}", CommonMotions.GetMethodName(), ex.Message);
+            }
+        }
+
+        /// <summary>
+        /// 表示ボタン押下時のイベント
+        /// </summary>
+        /// <param name="sender"></param>
+        /// <param name="e"></param>
+        private void btnShow_Click(object sender, EventArgs e)
+        {
+            try
+            {
+                if (isDirty)
+                {
+                    if (MessageBox.Show("データに変更があります、登録せずに対象を変更してよろしいですか？。", "確認", MessageBoxButtons.YesNo, MessageBoxIcon.Warning) == DialogResult.No)
+                    {
+                        return;
+                    }
+                }
+                dgvMaster.CellDoubleClick -= DataGridView_DoubleCellClick;
+                dgvMaster.CellEnter -= DataGridView_CellEnter;
+                dgvMaster.CellValueChanged -= DataGridView_CellValueChanged;
+                // グリッド表示
+                DisplayData();
+            }
+            catch (Exception ex)
+            {
+                logger.ErrorFormat("システムエラー：{0}：{1}", CommonMotions.GetMethodName(), ex.Message);
+            }
+            finally
+            {
+                dgvMaster.CellDoubleClick += DataGridView_DoubleCellClick;
+                dgvMaster.CellEnter += DataGridView_CellEnter;
+                dgvMaster.CellValueChanged += DataGridView_CellValueChanged;
+            }
+        }
+
+        /// <summary>
+        /// ×ボタン押下時のイベント
+        /// </summary>
+        /// <param name="sender"></param>
+        /// <param name="e"></param>
+        private void FrmSelectPayment_FormClosing(object sender, FormClosingEventArgs e)
+        {
+            try
+            {
+                if (m_CloseingProcessOff) return;
+
+                if (isDirty)
+                {
+                    if (MessageBox.Show("データに変更があります、登録せずに終了してよろしいですか？。", "終了確認"
+                                    , MessageBoxButtons.YesNo, MessageBoxIcon.Warning) == DialogResult.No)
+                    {
+                        e.Cancel = true;
+                        return;
+                    }
+                }
+
+                // 前プロセスに戻る
+                ClsExcute.BackProcess();
+            }
+            catch (Exception ex)
+            {
+                logger.ErrorFormat("システムエラー：{0}：{1}", CommonMotions.GetMethodName(), ex.Message);
+            }
+        }
+
+        /// <summary>
+        /// 終了ボタンクリック時のイベント
+        /// </summary>
+        /// <param name="sender"></param>
+        /// <param name="e"></param>
+        private void btnEnd_Click(object sender, EventArgs e)
+        {
+            try
+            {
+                if (isDirty && MessageBox.Show("データに変更があります、登録せずに終了してよろしいですか？。", "終了確認", MessageBoxButtons.YesNo, MessageBoxIcon.Warning) == DialogResult.No)
+                    return;
+
+                // 前プロセスに戻る
+                ClsExcute.BackProcess();
+
+                // クローズ処理をOFFにする。
+                m_CloseingProcessOff = true;
+
+                Close();
+            }
+            catch (Exception ex)
+            {
+                logger.ErrorFormat("システムエラー：{0}：{1}", CommonMotions.GetMethodName(), ex.Message);
+            }
+        }
+
+        /// <summary>
+        /// 登録ボタンクリック時のイベント
+        /// </summary>
+        /// <param name="sender"></param>
+        /// <param name="e"></param>
+        private void Registration_Click(object sender, EventArgs e)
+        {
+            dgvMaster.CellDoubleClick -= DataGridView_DoubleCellClick;
+            dgvMaster.CellEnter -= DataGridView_CellEnter;
+            dgvMaster.CellValueChanged -= DataGridView_CellValueChanged;
+            var ioDepositData = new IODepositData();
+            var ioDepositDataDetail = new IODepositDataDetail();
+            var ioDepositApprovalInfo = new IODepositApprovalInfo();
+            var ioRequestHead = new IORequestHead();
+            try
+            {
+                ResetTargetDate();
+                if (MessageBox.Show("表示中のデータを登録します。", "登録確認", MessageBoxButtons.YesNo, MessageBoxIcon.Question) != DialogResult.Yes)
+                    return;
+                if (!isDirty)
+                    return;
+                // 入力内容をチェック
+                foreach (var depositOrderer in depositOrderers)
+                {
+                    foreach (var deposit in depositOrderer.VisibleDeposits)
+                    {
+                        // 入金日入力済みで入金金額が入力されていない
+                        if (!string.IsNullOrEmpty(deposit.DepositDate)
+                            && !deposit.DepositAmountCash.HasValue
+                            && !deposit.DepositAmountBill.HasValue)
+                        {
+                            MessageBox.Show("入金日が登録されている行に入金金額が入力されていません。", "登録エラー", MessageBoxButtons.OK, MessageBoxIcon.Error);
+                            return;
+                        }
+                        // 入金金額入力済みで入金日が入力されていない
+                        if (string.IsNullOrEmpty(deposit.DepositDate)
+                            && (deposit.DepositAmountCash.HasValue
+                            || deposit.DepositAmountBill.HasValue))
+                        {
+                            MessageBox.Show("入金金額が登録されている行に入金日が入力されていません。", "登録エラー", MessageBoxButtons.OK, MessageBoxIcon.Error);
+                            return;
+                        }
+                    }
+                }
+
+                ioDepositData.connect();
+                ioDepositData.beginTran();
+                ioDepositDataDetail.connect();
+                ioDepositDataDetail.beginTran();
+                ioDepositApprovalInfo.connect();
+                ioDepositApprovalInfo.beginTran();
+                ioRequestHead.connect();
+                ioRequestHead.beginTran();
+
+                // 登録処理
+                foreach (var depositOrderer in depositOrderers)
+                {
+                    // 入金データの登録
+                    foreach (var deposit in depositOrderer.Deposits)
+                    {
+                        // 削除処理
+                        if (deposit.Deleted)
+                        {
+                            var sql = String.Format(" where OrderersDivision = {0} and OrderersCode = {1} and TargetDate = {2} and SeqNo = {3} ",
+                                depositOrderer.OrderersDivision, depositOrderer.OrderersCode, m_Select_TargetDate, deposit.SeqNo);
+                            if (!ioDepositData.DeleteAction(sql))
+                                throw new Exception();
+                            continue;
+                        }
+                        var depositData = new DepositData()
+                        {
+                            OrderersDivision = depositOrderer.OrderersDivision,
+                            OrderersCode = depositOrderer.OrderersCode,
+                            TargetDate = m_Select_TargetDate.ToString(),
+                            SeqNo = deposit.SeqNo,
+                            DepositDate = DateTime.Parse(deposit.DepositDate),
+                            DepositAmountCash = deposit.DepositAmountCash.GetValueOrDefault(0),
+                            DepositAmountBill = deposit.DepositAmountBill.GetValueOrDefault(0),
+                        };
+                        // 登録処理
+                        if (deposit.Added)
+                        {
+                            if (!ioDepositData.InsertAction(depositData))
+                                throw new Exception();
+                        }
+                        // 更新処理
+                        else if (deposit.Editted)
+                        {
+                            var sql = String.Format(" where OrderersDivision = {0} and OrderersCode = {1} and TargetDate = {2} and SeqNo = {3} ",
+                                depositData.OrderersDivision, depositData.OrderersCode, depositData.TargetDate, depositData.SeqNo);
+                            if (!ioDepositData.UpdateAction(sql, depositData))
+                                throw new Exception();
+                        }
+                    }
+                    // 入金明細データの登録
+                    foreach (var depositDetail in depositOrderer.DepositDetails)
+                    {
+                        // 削除処理
+                        if (depositDetail.Deleted)
+                        {
+                            var sql = String.Format(" where OrderersDivision = {0} and OrderersCode = {1} and TargetDate = {2} and SeqNo = {3} and LineCount = {4} ",
+                                depositOrderer.OrderersDivision, depositOrderer.OrderersCode, m_Select_TargetDate, depositDetail.SeqNo, depositDetail.LineCount);
+                            if (!ioDepositDataDetail.DeleteAction(sql))
+                                throw new Exception();
+                            // 入金確認承認データもあわせて削除
+                            if (!ioDepositApprovalInfo.DeleteAction(sql))
+                                throw new Exception();
+                            // 入金明細データを削除した場合は、対応する請求合計データを割当未とする
+                            //sql = string.Format(" where RequestNo = {0} and OrderNo = {1} ",
+                            //    depositDetail.RequestNo, depositDetail.OrderNo);
+                            //var lstRtd = new List<RequestTotalData>();
+                            //if (!ioRequestTotalData.SelectAction(sql, ref lstRtd))
+                            //    throw new Exception();
+                            //foreach (var rtd in lstRtd)
+                            //{
+                            //    rtd.AssignedFlg = false;
+                            //    if (!ioRequestTotalData.UpdateAction("", rtd))
+                            //        throw new Exception();
+                            //}
+                            continue;
+                        }
+                        var depositDataDetail = new DepositDataDetail()
+                        {
+                            OrderersDivision = depositOrderer.OrderersDivision,
+                            OrderersCode = depositOrderer.OrderersCode,
+                            TargetDate = m_Select_TargetDate.ToString(),
+                            SeqNo = depositDetail.SeqNo,
+                            LineCount = depositDetail.LineCount,
+                            RequestNo = depositDetail.RequestNo,
+                            OrderNo = depositDetail.OrderNo,
+                            DepositAmount = depositDetail.DepositAmount,
+                            DiscountAmount = depositDetail.DiscountAmount,
+                            CnstrPrice = depositDetail.CnstrPrice,
+                            Fees = depositDetail.Fees,
+                            OtherAdjustments = depositDetail.OtherAdjustments,
+                            CarryAmount = depositDetail.CarryAmount,
+                            ApprovalPersonCode = depositDetail.ApprovalPersonCode,
+                        };
+                        var approvalDate = new DateTime(2000, 1, 1);
+                        if (DateTime.TryParse(depositDetail.ApprovalDate, out approvalDate))
+                        {
+                            depositDataDetail.ApprovalDate = approvalDate;
+                        }
+
+                        // 登録処理
+                        if (depositDetail.Added)
+                        {
+                            if (!ioDepositDataDetail.InsertAction(depositDataDetail))
+                                throw new Exception();
+                            // 入金明細データを追加した場合は、対応する請求合計データを割当済みとする
+                            //var sql = string.Format(" where RequestNo = {0} and OrderNo = {1} ",
+                            //    depositDataDetail.RequestNo, depositDataDetail.OrderNo);
+                            //var lstRtd = new List<RequestTotalData>();
+                            //if (!ioRequestTotalData.SelectAction(sql, ref lstRtd))
+                            //    throw new Exception();
+                            //foreach (var rtd in lstRtd)
+                            //{
+                            //    rtd.AssignedFlg = true;
+                            //    if (!ioRequestTotalData.UpdateAction("", rtd))
+                            //        throw new Exception();
+                            //}
+                            // 入金確認承認データの登録
+                            foreach (var approval in depositDetail.DepositApprovals)
+                            {
+                                var da = new DepositApprovalInfo()
+                                {
+                                    OrderersDivision = depositOrderer.OrderersDivision,
+                                    OrderersCode = depositOrderer.OrderersCode,
+                                    TargetDate = m_Select_TargetDate.ToString(),
+                                    SeqNo = depositDetail.SeqNo,
+                                    LineCount = depositDetail.LineCount,
+                                    ApprovalNo = approval.ApprovalNo,
+                                    ApprovalPerson = approval.ApprovalPerson,
+                                    ApprovalPersonName = approval.ApprovalPersonName,
+                                    ApprovalAuthority = approval.ApprovalAuthority,
+                                };
+                                DateTime ad = new DateTime(2000, 1, 1);
+                                if (DateTime.TryParse(approval.ApprovalDate, out ad))
+                                {
+                                    da.ApprovalDate = ad;
+                                }
+                                if (!ioDepositApprovalInfo.InsertAction(da))
+                                    throw new Exception();
+                            }
+                        }
+                        // 更新処理
+                        else
+                        {
+                            if (depositDetail.Editted)
+                            {
+                                if (!ioDepositDataDetail.UpdateAction("", depositDataDetail))
+                                    throw new Exception();
+                            }
+                            // 入金確認承認データの更新
+                            foreach (var approval in depositDetail.DepositApprovals)
+                            {
+                                if (approval.Editted)
+                                {
+                                    var da = new DepositApprovalInfo()
+                                    {
+                                        OrderersDivision = depositOrderer.OrderersDivision,
+                                        OrderersCode = depositOrderer.OrderersCode,
+                                        TargetDate = m_Select_TargetDate.ToString(),
+                                        SeqNo = depositDetail.SeqNo,
+                                        LineCount = depositDetail.LineCount,
+                                        ApprovalNo = approval.ApprovalNo,
+                                        ApprovalPerson = approval.ApprovalPerson,
+                                        ApprovalPersonName = approval.ApprovalPersonName,
+                                        ApprovalAuthority = approval.ApprovalAuthority,
+                                    };
+                                    DateTime ad = new DateTime(2000, 1, 1);
+                                    if (DateTime.TryParse(approval.ApprovalDate, out ad))
+                                    {
+                                        da.ApprovalDate = ad;
+                                    }
+                                    var sql = string.Format(" where OrderersDivision = {0} and OrderersCode = {1} and TargetDate = {2} and SeqNo = {3} and LineCount = {4} and ApprovalNo = {5}",
+                                        da.OrderersDivision, da.OrderersCode, da.TargetDate, da.SeqNo, da.LineCount, da.ApprovalNo);
+                                    if (!ioDepositApprovalInfo.UpdateAction(sql, da))
+                                        throw new Exception();
+                                }
+                            }
+                        }
+                    }
+                }
+
+                ioDepositData.commit();
+                ioDepositDataDetail.commit();
+                ioDepositApprovalInfo.commit();
+                ioRequestHead.commit();
+
+                // グリッド表示
+                DisplayData();
+            }
+            catch (Exception ex)
+            {
+                ioDepositData.rollback();
+                ioDepositDataDetail.rollback();
+                ioDepositApprovalInfo.rollback();
+                ioRequestHead.rollback();
+                logger.ErrorFormat("システムエラー：{0}：{1}", CommonMotions.GetMethodName(), ex.Message);
+            }
+            finally
+            {
+                dgvMaster.CellDoubleClick += DataGridView_DoubleCellClick;
+                dgvMaster.CellEnter += DataGridView_CellEnter;
+                dgvMaster.CellValueChanged += DataGridView_CellValueChanged;
+                ioDepositData.close();
+                ioDepositDataDetail.close();
+                ioDepositApprovalInfo.close();
+                ioRequestHead.close();
+            }
+        }
+
+        /// <summary>
+        /// セルダブルクリックイベント
+        /// </summary>
+        /// <param name="sender"></param>
+        /// <param name="e"></param>
+        private void DataGridView_DoubleCellClick(object sender, DataGridViewCellEventArgs e)
+        {
+            dgvMaster.CellDoubleClick -= DataGridView_DoubleCellClick;
+            dgvMaster.CellEnter -= DataGridView_CellEnter;
+            dgvMaster.CellValueChanged -= DataGridView_CellValueChanged;
+            try
+            {
+                //// 承認セル以外は無視
+                //if ((e.ColumnIndex == (int)DispColumn.PersonName) ||
+                //    (e.ColumnIndex == (int)DispColumn.ApprovalName_1) ||
+                //    (e.ColumnIndex == (int)DispColumn.ApprovalName_2) ||
+                //    (e.ColumnIndex == (int)DispColumn.ApprovalName_3) ||
+                //    (e.ColumnIndex == (int)DispColumn.ApprovalName_4) ||
+                //    (e.ColumnIndex == (int)DispColumn.ApprovalName_5) ||
+                //    (e.ColumnIndex == (int)DispColumn.ApprovalName_6) ||
+                //    (e.ColumnIndex == (int)DispColumn.ApprovalName_7) ||
+                //    (e.ColumnIndex == (int)DispColumn.ApprovalName_8) ||
+                //    (e.ColumnIndex == (int)DispColumn.ApprovalName_9) ||
+                //    (e.ColumnIndex == (int)DispColumn.ApprovalName_10))
+                //{
+                //    var cells = dgvMaster.Rows[e.RowIndex].Cells;
+                //    // 自分以外のセルは編集不可
+                //    if (CommonMotions.cnvInt(dgvMaster[e.ColumnIndex + 1, e.RowIndex].Value) != CommonMotions.LoginUserData.PersonCode)
+                //        return;
+                //    var depositOrderer = FindDepositOrderer(e.RowIndex);
+                //    var depositDetail = depositOrderer.FindDepositDetailByLineCount(CommonMotions.cnvInt(cells[(int)DispColumn.LineCount].Value));
+                //    // 担当者承認
+                //    if (e.ColumnIndex == (int)DispColumn.PersonName)
+                //    {
+                //        // 現場が不明な場合は承認不可
+                //        if (IsUnknownRow(e.RowIndex))
+                //        {
+                //            MessageBox.Show("現場が選択されていません。", "登録エラー", MessageBoxButtons.OK, MessageBoxIcon.Error);
+                //            return;
+                //        }
+                //        // 上位が承認済みの場合は編集不可
+                //        if (!depositDetail.IsApprovedByApprover)
+                //        {
+                //            if (!depositDetail.IsApprovedByStaff)
+                //                depositDetail.ApprovalDate = DateTime.Now.ToString("yyyy-MM-dd");
+                //            else
+                //                depositDetail.ApprovalDate = "";
+                //            depositDetail.Editted = true;
+                //        }
+                //    }
+                //    else
+                //    {
+                //        if (depositDetail.DepositApprovals.Count == 0)
+                //            return;
+                //        // 承認者に含まれるか確認
+                //        var approvalIndex = depositDetail.DepositApprovals.FindIndex(a => a.ApprovalPerson == CommonMotions.LoginUserData.PersonCode);
+                //        if (approvalIndex < 0)
+                //            return;
+                //        // 最終承認以外の場合
+                //        if (approvalIndex != depositDetail.DepositApprovals.Count - 1)
+                //        {
+                //            // 下位の承認者が承認済みかつ上位の承認者が未承認
+                //            var lower = true;
+                //            var i = 0;
+                //            var enableEdit = true;
+                //            foreach (var a in depositDetail.DepositApprovals)
+                //            {
+                //                if (a.ApprovalPerson == CommonMotions.LoginUserData.PersonCode)
+                //                {
+                //                    lower = false;
+                //                    approvalIndex = i;
+                //                }
+                //                else
+                //                {
+                //                    if (lower)
+                //                    {
+                //                        if (a.ApprovalDate == "")
+                //                        {
+                //                            enableEdit = false;
+                //                            break;
+                //                        }
+                //                    }
+                //                    else
+                //                    {
+                //                        if (a.ApprovalDate != "")
+                //                        {
+                //                            enableEdit = false;
+                //                            break;
+                //                        }
+                //                    }
+                //                }
+                //                i++;
+                //            }
+                //            if (!enableEdit)
+                //            {
+                //                if (approvalIndex != 0 && depositDetail.DepositApprovals[approvalIndex - 1].ApprovalDate == "")
+                //                {
+                //                    MessageBox.Show("直前の承認が実施されていないため、承認できません。", "登録エラー", MessageBoxButtons.OK, MessageBoxIcon.Error);
+                //                }
+                //                return;
+                //            }
+                //        }
+                //        var approval = depositDetail.DepositApprovals.ElementAt(approvalIndex);
+                //        // 未承認 → 承認
+                //        if (approval.ApprovalDate == "")
+                //        {
+                //            if (CalculateDifference(depositOrderer) != 0)
+                //            {
+                //                // 差額の確認
+                //                if (MessageBox.Show("入金金額と調整金額が一致しませんが承認してよろしいですか？。", "確認", MessageBoxButtons.YesNo, MessageBoxIcon.Warning) == DialogResult.No)
+                //                    return;
+                //            }
+                //            approval.ApprovalDate = DateTime.Now.ToString("yyyy-MM-dd");
+                //        }
+                //        // 承認 → 未承認
+                //        else
+                //        {
+                //            approval.ApprovalDate = "";
+                //        }
+                //        approval.Editted = true;
+                //    }
+                //    var headerIndex = DetectHeaderIndex(e.RowIndex);
+                //    UpdateDepositOrdererRows(depositOrderer, headerIndex);
+                //    isDirty = true;
+                //}
+            }
+            catch (Exception ex)
+            {
+                logger.ErrorFormat("システムエラー：{0}：{1}", CommonMotions.GetMethodName(), ex.Message);
+            }
+            finally
+            {
+                dgvMaster.CellDoubleClick += DataGridView_DoubleCellClick;
+                dgvMaster.CellEnter += DataGridView_CellEnter;
+                dgvMaster.CellValueChanged += DataGridView_CellValueChanged;
+            }
+        }
+
+        /// <summary>
+        /// セル編集開始時のイベント
+        /// </summary>
+        /// <param name="sender"></param>
+        /// <param name="e"></param>
+        private void DataGridView_CellEnter(object sender, DataGridViewCellEventArgs e)
+        {
+            try
+            {
+                //if (dgvMaster.RowCount == 0)
+                //    return;
+                //oldCellValue = CommonMotions.cnvString(dgvMaster[e.ColumnIndex, e.RowIndex].Value);
+            }
+            catch (Exception ex)
+            {
+                logger.ErrorFormat("システムエラー：{0}：{1}", CommonMotions.GetMethodName(), ex.Message);
+            }
+        }
+
+        /// <summary>
+        /// セル編集完了時のイベント
+        /// </summary>
+        /// <param name="sender"></param>
+        /// <param name="e"></param>
+        private void DataGridView_CellValueChanged(object sender, DataGridViewCellEventArgs e)
+        {
+            dgvMaster.CellDoubleClick -= DataGridView_DoubleCellClick;
+            dgvMaster.CellEnter -= DataGridView_CellEnter;
+            dgvMaster.CellValueChanged -= DataGridView_CellValueChanged;
+            try
+            {
+                //if (dgvMaster.RowCount == 0)
+                //    return;
+                //var cells = dgvMaster.Rows[e.RowIndex].Cells;
+                //var cellValue = CommonMotions.cnvString(cells[e.ColumnIndex].Value);
+                //if (oldCellValue == cellValue)
+                //    return;
+                //var key = GetOrderersKey(e.RowIndex);
+                //var depositOrderer = FindDepositOrderer(key.OrderersDivision, key.OrderersCode);
+                //// 入金情報を編集
+                //if (e.ColumnIndex == (int)DispColumn.DepositAmountCash
+                //    || e.ColumnIndex == (int)DispColumn.DepositAmountBill
+                //    || e.ColumnIndex == (int)DispColumn.DepositDate)
+                //{
+                //    var deposit = depositOrderer.FindDepositBySeqNo(CommonMotions.cnvInt(cells[(int)DispColumn.SeqNo].Value));
+                //    if (deposit == null)
+                //    {
+                //        deposit = new Deposit()
+                //        {
+                //            Added = true,
+                //            SeqNo = depositOrderer.GetNextSeqNo(),
+                //        };
+                //        depositOrderer.Deposits.Add(deposit);
+                //    }
+                //    switch (e.ColumnIndex)
+                //    {
+                //        case (int)DispColumn.DepositAmountCash:
+                //            if (cellValue != "")
+                //                deposit.DepositAmountCash = CommonMotions.cnvInt(cellValue);
+                //            else
+                //                deposit.DepositAmountCash = null;
+                //            break;
+                //        case (int)DispColumn.DepositAmountBill:
+                //            if (cellValue != "")
+                //                deposit.DepositAmountBill = CommonMotions.cnvInt(cellValue);
+                //            else
+                //                deposit.DepositAmountBill = null;
+                //            break;
+                //        case (int)DispColumn.DepositDate:
+                //            DateTime dt;
+                //            if (DateTime.TryParse(cellValue, out dt))
+                //                deposit.DepositDate = dt.ToString("yyyy/MM/dd");
+                //            else
+                //                deposit.DepositDate = "";
+                //            break;
+                //    }
+                //    if (string.IsNullOrEmpty(deposit.DepositDate)
+                //        && !deposit.DepositAmountCash.HasValue
+                //        && !deposit.DepositAmountBill.HasValue)
+                //        deposit.Deleted = true;
+                //    deposit.Editted = true;
+                //    if (deposit.CanRemove)
+                //        depositOrderer.Deposits.Remove(deposit);
+                //}
+                //// 入金明細金額を編集
+                //else if (e.ColumnIndex == (int)DispColumn.DepositAmount
+                //    || e.ColumnIndex == (int)DispColumn.DiscountAmount
+                //    || e.ColumnIndex == (int)DispColumn.CnstrPrice
+                //    || e.ColumnIndex == (int)DispColumn.Fees
+                //    || e.ColumnIndex == (int)DispColumn.OtherAdjustments
+                //    || e.ColumnIndex == (int)DispColumn.CarryAmount)
+                //{
+                //    var depositDetail = depositOrderer.FindDepositDetailByLineCount(CommonMotions.cnvInt(cells[(int)DispColumn.LineCount].Value));
+                //    var amount = CommonMotions.cnvInt(cellValue);
+                //    switch (e.ColumnIndex)
+                //    {
+                //        case (int)DispColumn.DepositAmount:
+                //            depositDetail.DepositAmount = amount;
+                //            break;
+                //        case (int)DispColumn.DiscountAmount:
+                //            depositDetail.DiscountAmount = amount;
+                //            break;
+                //        case (int)DispColumn.CnstrPrice:
+                //            depositDetail.CnstrPrice = amount;
+                //            break;
+                //        case (int)DispColumn.Fees:
+                //            depositDetail.Fees = amount;
+                //            break;
+                //        case (int)DispColumn.OtherAdjustments:
+                //            depositDetail.OtherAdjustments = amount;
+                //            break;
+                //        case (int)DispColumn.CarryAmount:
+                //            depositDetail.CarryAmount = amount;
+                //            break;
+                //    }
+                //    depositDetail.Editted = true;
+                //}
+                //var headerIndex = DetectHeaderIndex(e.RowIndex);
+                //UpdateDepositOrdererRows(depositOrderer, headerIndex);
+                //dgvMaster.CurrentCell = dgvMaster[e.ColumnIndex, e.RowIndex];
+                //isDirty = true;
+            }
+            catch (Exception ex)
+            {
+                logger.ErrorFormat("システムエラー：{0}：{1}", CommonMotions.GetMethodName(), ex.Message);
+            }
+            finally
+            {
+                dgvMaster.CellDoubleClick += DataGridView_DoubleCellClick;
+                dgvMaster.CellEnter += DataGridView_CellEnter;
+                dgvMaster.CellValueChanged += DataGridView_CellValueChanged;
+            }
+        }
+
+        /// <summary>
+        /// 発注者追加ダイアログクローズ通知
+        /// </summary>
+        /// <param name="sender"></param>
+        /// <param name="e"></param>
+        private void NotifyAddCmp_FormClosed(object sender, FormClosedEventArgs e)
+        {
+            try
+            {
+                dgvMaster.CellDoubleClick -= DataGridView_DoubleCellClick;
+                dgvMaster.CellEnter -= DataGridView_CellEnter;
+                dgvMaster.CellValueChanged -= DataGridView_CellValueChanged;
+                var f = (FrmSelectRequest)sender;
+                // 発注者追加あり
+                if (f.m_AddCmpData.isEdit)
+                {
+                    foreach (var h in depositOrderers)
+                    {
+                        if (h.Deleted)
+                            continue;
+                        // 表示済みの発注者の場合は何もしない
+                        if (h.OrderersDivision == f.m_AddCmpData.OrderersDivision
+                            && h.OrderersCode == f.m_AddCmpData.OrderersCode)
+                        {
+                            return;
+                        }
+                    }
+                    // データに追加
+                    var depositOrderer = new DepositOrderer();
+                    depositOrderer.Added = true;
+                    if (depositOrderers.Count == 0)
+                        depositOrderer.No = 1;
+                    else
+                        depositOrderer.No = depositOrderers.Last().No + 1;
+                    depositOrderer.OrderersDivision = f.m_AddCmpData.OrderersDivision;
+                    depositOrderer.OrderersCode = f.m_AddCmpData.OrderersCode;
+                    depositOrderer.OrderersName = f.m_AddCmpData.OrderersName;
+                    depositOrderers.Add(depositOrderer);
+                    AddDepositOrdererRows(depositOrderer, dgvMaster.Rows.Count);
+                    isDirty = true;
+                }
+            }
+            catch (Exception ex)
+            {
+                logger.ErrorFormat("システムエラー：{0}：{1}", CommonMotions.GetMethodName(), ex.Message);
+            }
+            finally
+            {
+                dgvMaster.CellDoubleClick += DataGridView_DoubleCellClick;
+                dgvMaster.CellEnter += DataGridView_CellEnter;
+                dgvMaster.CellValueChanged += DataGridView_CellValueChanged;
+            }
+        }
+
+        /// <summary>
+        /// 現場登録ダイアログクローズ通知
+        /// </summary>
+        /// <param name="sender"></param>
+        /// <param name="e"></param>
+        private void NotifyAddFld_FormClosed(object sender, FormClosedEventArgs e)
+        {
+            try
+            {
+                dgvMaster.CellDoubleClick -= DataGridView_DoubleCellClick;
+                dgvMaster.CellEnter -= DataGridView_CellEnter;
+                dgvMaster.CellValueChanged -= DataGridView_CellValueChanged;
+                var f = (FrmSelectRegField)sender;
+                if (f.EndButton != DialogResult.OK)
+                    return;
+                var headerIndex = DetectHeaderIndex(dgvMaster.CurrentRow.Index);
+                var depositOrderer = FindDepositOrderer(dgvMaster.CurrentRow.Index);
+                foreach (var item in f.m_lstMyField)
+                {
+                    if (item.ConstructionName == "不明" && item.ConstructionName_Raw == "")
+                        continue;
+                    // 担当データのみを対象とする
+                    if (item.PersonCode != CommonMotions.LoginUserData.PersonCode)
+                        continue;
+                    var depositDetail = depositOrderer.DepositDetails.Find(d =>
+                        d.ConstructionName == item.ConstructionName && d.ConstructionNameRow == item.ConstructionName_Raw
+                    );
+                    // 追加・更新
+                    if (!item.DeleteFlg)
+                    {
+                        // 追加
+                        if (depositDetail == null)
+                        {
+                            depositDetail = new DepositDetail()
+                            {
+                                Added = true,
+                                Visible = true,
+                                SeqNo = 1,
+                                LineCount = depositOrderer.GetNextLineCount(),
+                                RequestNo = item.RequestNo,
+                                OrderNo = item.OrderNo,
+                                ConstructionName = item.ConstructionName,
+                                ConstructionNameRow = item.ConstructionName_Raw,
+                                DepartmentCode = item.DepartmentCode,
+                                BillCreationDate = item.BillCreationDate,
+                                BillPrice = item.BillPrice,
+                                TaxPrice = item.TaxPrice,
+                                DepositAmount = item.DepositAmount,
+                                ApprovalPersonCode = item.PersonCode,
+                                ApprovalPersonName = CommonMotions.LoginUserData.SealPrintName,
+                                ApprovalDate = "",
+                            };
+                            var defaultApproves = new List<ApproveData>();
+                            if (!SelectDefaultApprove(depositDetail.DepartmentCode, ref defaultApproves))
+                                return;
+                            foreach (var approve in defaultApproves)
+                            {
+                                var da = new DepositApproval()
+                                {
+                                    Added = true,
+                                    ApprovalPersonName = approve.Value,
+                                    ApprovalPerson = approve.Key,
+                                    ApprovalDate = "",
+                                    ApprovalNo = approve.Order,
+                                };
+                                depositDetail.DepositApprovals.Add(da);
+                            }
+                            depositOrderer.DepositDetails.Add(depositDetail);
+                        }
+                        // 更新
+                        else
+                        {
+                            depositDetail.BillPrice = item.BillPrice;
+                            depositDetail.TaxPrice = item.TaxPrice;
+                            depositDetail.DepositAmount = item.DepositAmount;
+                        }
+                    }
+                    // 削除
+                    else
+                    {
+                        if (depositDetail != null)
+                        {
+                            if (depositDetail.Added)
+                            {
+                                // 未存在のデータは削除
+                                depositOrderer.DepositDetails.Remove(depositDetail);
+                            }
+                            else
+                            {
+                                // 存在するデータは削除フラグを立てる
+                                depositDetail.Deleted = true;
+                            }
+                        }
+                    }
+                }
+                UpdateDepositOrdererRows(depositOrderer, headerIndex);
+                isDirty = true;
+            }
+            catch (Exception ex)
+            {
+                logger.ErrorFormat("システムエラー：{0}：{1}", CommonMotions.GetMethodName(), ex.Message);
+            }
+            finally
+            {
+                dgvMaster.CellDoubleClick += DataGridView_DoubleCellClick;
+                dgvMaster.CellEnter += DataGridView_CellEnter;
+                dgvMaster.CellValueChanged += DataGridView_CellValueChanged;
+            }
+        }
+
+        /// <summary>
+        /// 対象月コンボボックスを表示時点の設定月に戻す。
+        /// </summary>
+        private void ResetTargetDate()
+        {
+            var selectedDate = m_Select_TargetDate.ToString().Insert(4, "/");
+            numericUpDown2.Value = CommonMotions.cnvInt(selectedDate);
+        }
+
+        /// <summary>
+        /// 入金請求先一覧を取得する。
+        /// </summary>
+        /// <returns></returns>
+        private List<DepositOrderer> SelectDepositOrderers()
+        {
+            var depositData = SelectDepositDataAll().OfType<object[]>()
+                .GroupBy(d =>
+                {
+                    return string.Format("{0} {1}",
+                        CommonMotions.cnvInt(d[(int)ClickGetData.OrderersDivision]),
+                        CommonMotions.cnvInt(d[(int)ClickGetData.OrderersCode]));
+                });
+            var data = new List<DepositOrderer>();
+            var no = 1;
+            foreach (var deposits in depositData)
+            {
+                var orderer = deposits.First();
+                // 請求先情報
+                var o = new DepositOrderer();
+                o.OrderersDivision = CommonMotions.cnvInt(orderer[(int)ClickGetData.OrderersDivision]);
+                o.OrderersCode = CommonMotions.cnvInt(orderer[(int)ClickGetData.OrderersCode]);
+                o.OrderersName = ToOrdererName(CommonMotions.cnvInt(orderer[(int)ClickGetData.CorporateStatusPoint]),
+                                        CommonMotions.cnvString(orderer[(int)ClickGetData.CorporateStatusName]),
+                                        CommonMotions.cnvString(orderer[(int)ClickGetData.OrderersName1]),
+                                        CommonMotions.cnvString(orderer[(int)ClickGetData.OrderersName2]));
+                // 表示権限がない場合は次へ
+                if (!CheckOrdererPermission(o))
+                {
+                    continue;
+                }
+                o.No = no;
+                no++;
+                o.Deposits = new List<Deposit>();
+                o.DepositDetails = new List<DepositDetail>();
+                // 入金データ情報
+                foreach (var deposit in deposits)
+                {
+                    var d = new Deposit();
+                    d.SeqNo = CommonMotions.cnvInt(deposit[(int)ClickGetData.SeqNo]);
+                    d.DepositDate = CommonMotions.cnvString(deposit[(int)ClickGetData.DepositDate]);
+                    d.DepositAmountCash = CommonMotions.cnvInt(deposit[(int)ClickGetData.DepositAmountCash]);
+                    d.DepositAmountBill = CommonMotions.cnvInt(deposit[(int)ClickGetData.DepositAmountBill]);
+                    o.Deposits.Add(d);
+                }
+                // 入金明細データ
+                var details = SelectDepositDetailData(o.OrderersDivision, o.OrderersCode).OfType<object[]>();
+                foreach (var detail in details)
+                {
+                    var dd = new DepositDetail();
+                    dd.SeqNo = CommonMotions.cnvInt(detail[(int)ClickGetData.SeqNo]);
+                    dd.LineCount = CommonMotions.cnvInt(detail[(int)ClickGetData.LineCount]);
+                    dd.RequestNo = CommonMotions.cnvInt(detail[(int)ClickGetData.RequestNo]);
+                    dd.OrderNo = CommonMotions.cnvInt(detail[(int)ClickGetData.OrderNo]);
+                    dd.ConstructionNameRow = CommonMotions.cnvString(detail[(int)ClickGetData.DetailString]);
+                    dd.ConstructionName = dd.ConstructionNameRow;
+                    if (dd.OrderNo > 1)
+                    {
+                        dd.ConstructionName += "（" + dd.OrderNo + "回目）";
+                    }
+                    // 入金予定日未実装
+                    dd.BillCreationDate = CommonMotions.cnvString(detail[(int)ClickGetData.BillCreationDate]);
+                    dd.BillPrice = CommonMotions.cnvInt(detail[(int)ClickGetData.BillPrice]);
+                    dd.TaxPrice = CommonMotions.cnvInt(detail[(int)ClickGetData.TaxPrice]);
+                    dd.DepositAmount = CommonMotions.cnvInt(detail[(int)ClickGetData.DepositAmount]);
+                    dd.DiscountAmount = CommonMotions.cnvInt(detail[(int)ClickGetData.DiscountAmount]);
+                    dd.CnstrPrice = CommonMotions.cnvInt(detail[(int)ClickGetData.CnstrPrice]);
+                    dd.Fees = CommonMotions.cnvInt(detail[(int)ClickGetData.Fees]);
+                    dd.OtherAdjustments = CommonMotions.cnvInt(detail[(int)ClickGetData.OtherAdjustments]);
+                    dd.CarryAmount = CommonMotions.cnvInt(detail[(int)ClickGetData.CarryAmount]);
+                    dd.ApprovalPersonCode = CommonMotions.cnvInt(detail[(int)ClickGetData.ApprovalPersonCode]);
+                    dd.ApprovalEndFlg = CommonMotions.cnvInt(detail[(int)ClickGetData.ApprovalEndFlg]);
+                    dd.ApprovalPersonName = CommonMotions.cnvString(detail[(int)ClickGetData.PersonName]);
+                    dd.DepartmentCode = CommonMotions.cnvInt(detail[(int)ClickGetData.DepartmentCode]);
+                    dd.ConstructionCode = CommonMotions.cnvInt(detail[(int)ClickGetData.ConstructionCode]);
+                    dd.ConstructionPersonCode = CommonMotions.cnvInt(detail[(int)ClickGetData.ConstructionPersonCode]);
+                    dd.ConstrSubPersonCode = CommonMotions.cnvInt(detail[(int)ClickGetData.ConstrSubPersonCode]);
+                    dd.ConstructionInstructor = CommonMotions.cnvInt(detail[(int)ClickGetData.ConstructionInstructor]);
+                    dd.DepositApprovals = new List<DepositApproval>();
+                    dd.Visible = CheckPermission(dd.DepartmentCode, dd.ConstructionPersonCode, dd.ConstrSubPersonCode, dd.ConstructionInstructor);
+                    dd.ApprovalDate = "";
+                    if (CommonMotions.cnvString(detail[(int)ClickGetData.ApprovalDate]) != "0001-01-01")
+                        dd.ApprovalDate = CommonMotions.cnvString(detail[(int)ClickGetData.ApprovalDate]);
+                    // 担当者承認済みの場合
+                    if (dd.IsApprovedByStaff)
+                    {
+                        var depositApprovals = new List<DepositApprovalInfo>();
+                        if (!SelectApprove(o.OrderersDivision, o.OrderersCode, dd.SeqNo, dd.LineCount, ref depositApprovals))
+                            return null;
+                        var detectApproval = false;
+                        var detectNonApproval = false;
+                        var upperApprovalInUser = false;
+                        foreach (var appInfo in depositApprovals)
+                        {
+                            var da = new DepositApproval()
+                            {
+                                ApprovalNo = appInfo.ApprovalNo,
+                                ApprovalPersonName = appInfo.ApprovalPersonName,
+                                ApprovalPerson = appInfo.ApprovalPerson,
+                                ApprovalAuthority = appInfo.ApprovalAuthority,
+                                ApprovalDate = "",
+                            };
+                            if (appInfo.ApprovalDate != DateTime.MinValue)
+                                da.ApprovalDate = appInfo.ApprovalDate.ToString("yyyy-MM-dd");
+                            dd.DepositApprovals.Add(da);
+                        }
+                        // 承認状態を設定
+                        if (!detectApproval)
+                            dd.Status = ApprovalStatus.InCharge;
+                        else if (detectNonApproval)
+                            dd.Status = ApprovalStatus.InApproval;
+                        else
+                            dd.Status = ApprovalStatus.Approved;
+                        dd.UpperApprovalInUser = upperApprovalInUser;
+                    }
+                    // 担当者未承認
+                    else
+                    {
+                        var defaultApproves = new List<ApproveData>();
+                        if (!SelectDefaultApprove(dd.DepartmentCode, ref defaultApproves))
+                            return null;
+                        foreach (var approve in defaultApproves)
+                        {
+                            var da = new DepositApproval()
+                            {
+                                Added = true,
+                                ApprovalPersonName = approve.Value,
+                                ApprovalPerson = approve.Key,
+                                ApprovalDate = "",
+                                ApprovalNo = approve.Order,
+                            };
+                            dd.DepositApprovals.Add(da);
+                        }
+                    }
+                    o.DepositDetails.Add(dd);
+                }
+                data.Add(o);
+            }
+            return data;
+        }
+
+        /// <summary>
+        /// 入金データを取得する。
+        /// </summary>
+        /// <returns></returns>
+        private ArrayList SelectDepositDataAll()
+        {
+            try
+            {
+                var sql = new StringBuilder();
+                //sql.Append("SELECT ");
+                //sql.Append("DEP.ORDERERSDIVISION ");
+                //sql.Append(",DEP.ORDERERSCODE ");
+                //sql.Append(",DEP.TARGETDATE ");
+                //sql.Append(",DEP.SEQNO ");
+                //sql.Append(",DATE_FORMAT(DEP.DEPOSITDATE,'%Y/%m/%d') AS DEPOSITDATE ");
+                //sql.Append(",DEP.DEPOSITAMOUNTCASH ");
+                //sql.Append(",DEP.DEPOSITAMOUNTBILL ");
+                //sql.Append(",ORD.CORPORATESTATUSNAME ");
+                //sql.Append(",ORD.CORPORATESTATUSPOINT ");
+                //sql.Append(",ORD.ORDERERSNAME1 ");
+                //sql.Append(",ORD.ORDERERSNAME2 ");
+                //sql.Append("FROM ");
+                //sql.Append("DEPOSITDATA DEP ");
+                //sql.Append("INNER JOIN DEPOSITDATADETAIL DTL ON ");
+                //sql.Append("DEP.ORDERERSDIVISION = DTL.ORDERERSDIVISION ");
+                //sql.Append("AND	DEP.ORDERERSCODE = DTL.ORDERERSCODE ");
+                //sql.Append("AND DEP.TARGETDATE = DTL.TARGETDATE ");
+                //sql.Append("AND DTL.SEQNO = 1 ");
+                //sql.Append("LEFT JOIN ORDERERSMASTER ORD ON ");
+                //sql.Append("DEP.ORDERERSDIVISION = ORD.ORDERCOTEGORY ");
+                //sql.Append("AND DEP.ORDERERSCODE = ORD.ORDERERSCODE ");
+                //sql.Append("WHERE ");
+                //sql.Append("DTL.REQUESTNO IS NOT NULL ");
+                //sql.Append("ORDER BY  ");
+                //sql.Append("ORD.DISPLAYORDER ASC,DEP.DEPOSITDATE DESC,DEP.SEQNO ASC ");
+
+                sql.Append("SELECT DISTINCT ");
+                sql.Append("DEP.ORDERERSDIVISION ");
+                sql.Append(",DEP.ORDERERSCODE ");
+                sql.Append(",DEP.TARGETDATE ");
+                sql.Append(",DEP.SEQNO ");
+                sql.Append(",DATE_FORMAT(DEP.DEPOSITDATE,'%Y/%m/%d') AS DEPOSITDATE ");
+                sql.Append(",DEP.DEPOSITAMOUNTCASH ");
+                sql.Append(",DEP.DEPOSITAMOUNTBILL ");
+                sql.Append(",ORD.CORPORATESTATUSNAME ");
+                sql.Append(",ORD.CORPORATESTATUSPOINT ");
+                sql.Append(",ORD.ORDERERSNAME1 ");
+                sql.Append(",ORD.ORDERERSNAME2 ");
+                sql.Append("FROM ");
+                sql.Append("DEPOSITDATA DEP ");
+                sql.Append("INNER JOIN DEPOSITDATADETAIL DTL ON ");
+                sql.Append("DEP.ORDERERSDIVISION = DTL.ORDERERSDIVISION ");
+                sql.Append("AND DEP.ORDERERSCODE = DTL.ORDERERSCODE ");
+                sql.Append("AND DEP.TARGETDATE = DTL.TARGETDATE ");
+                sql.Append("AND DTL.SEQNO = 1 ");
+
+                //sql.Append("AND DTL.APPROVALENDFLG = 1 ");
+                // ↑後で増やす(承認完了フラグ)
+
+                /////////////////////////////////////////////////////////////////////////////
+                //　検索条件(動的)START
+                /////////////////////////////////////////////////////////////////////////////
+
+                // 営業期
+                sql.AppendFormat("AND DEP.BusinessPeriod = {0} ", m_Select_TargetBusinessPeriod);
+
+                // 対象月
+                if (!m_Select_TargetDate.Equals(0))
+                {
+                    sql.AppendFormat("AND SUBSTRING( DEP.TARGETDATE, 5 ) = {0} ", m_Select_TargetDate.ToString("00"));
+                }
+
+                // 担当者
+                if (!m_Select_TargetPerson.Equals(0))
+                {
+                    sql.AppendFormat("AND DTL.APPROVALPERSONCODE = {0} ", m_Select_TargetPerson);
+                }
+
+                // 部署
+                if (!m_Select_TargetDepartment.Equals(0))
+                {
+                    sql.Append("INNER JOIN personinchargemaster PERIM ");
+                    sql.Append("ON DTL.APPROVALPERSONCODE = PERIM.PersonCode ");
+                    sql.AppendFormat("AND PERIM.DepartmentCode = {0} ", m_Select_TargetDepartment);
+                }
+                /////////////////////////////////////////////////////////////////////////////
+                //　検索条件(動的)END
+                /////////////////////////////////////////////////////////////////////////////
+
+                sql.Append("INNER JOIN( ");
+                sql.Append("SELECT ");
+                sql.Append("ORDERERSDIVISION ");
+                sql.Append(",ORDERERSCODE");
+                sql.Append(",SUM(DEPOSITAMOUNT) AS DEPOSITAMOUNT_SUM ");
+                sql.Append("FROM ");
+                sql.Append("depositdata ");
+                sql.Append("GROUP BY ");
+                sql.Append("ORDERERSDIVISION ");
+                sql.Append(",ORDERERSCODE ");
+                sql.Append(") AS AMOUNT ");
+                sql.Append("ON AMOUNT.ORDERERSDIVISION = DEP.ORDERERSDIVISION ");
+                sql.Append("AND AMOUNT.ORDERERSCODE = DEP.ORDERERSCODE ");
+                sql.Append("LEFT JOIN ORDERERSMASTER ORD ON ");
+                sql.Append("DEP.ORDERERSDIVISION = ORD.ORDERCOTEGORY ");
+                sql.Append("AND DEP.ORDERERSCODE = ORD.ORDERERSCODE ");
+                sql.Append("WHERE ");
+                sql.Append("DTL.REQUESTNO IS NOT NULL ");
+
+                sql.Append("ORDER BY  ");
+                sql.Append("AMOUNT.DEPOSITAMOUNT_SUM DESC, DEP.DEPOSITDATE DESC");
+
+                //sql.Append("select ");
+                //sql.Append("Dep.OrderersDivision, ");
+                //sql.Append("Dep.OrderersCode, ");
+                //sql.Append("Dep.TargetDate, ");
+                //sql.Append("Dep.SeqNo, ");
+                //sql.Append("DATE_FORMAT(Dep.DepositDate, '%Y/%m/%d') as DepositDate, ");
+                //sql.Append("Dep.DepositAmountCash, ");
+                //sql.Append("Dep.DepositAmountBill, ");
+                //sql.Append("OdrM.CorporateStatusName, ");
+                //sql.Append("OdrM.CorporateStatusPoint, ");
+                //sql.Append("OdrM.OrderersName1, ");
+                //sql.Append("OdrM.OrderersName2 ");
+                //sql.Append("from DepositData Dep ");
+                //sql.Append("left outer join OrderersMaster as OdrM ");
+                //sql.Append("on OdrM. OrderCotegory = Dep.OrderersDivision and OdrM.OrderersCode = Dep.OrderersCode ");
+                //sql.Append("order by OdrM.DisplayOrder asc, Dep.DepositDate desc, Dep.SeqNo asc");
+
+                var depDb = new IODepositData();
+                var data = new ArrayList();
+                if (!depDb.ExecuteReader(sql.ToString(), ref data)) return new ArrayList();
+                return data;
+            }
+            catch (Exception ex)
+            {
+                logger.ErrorFormat("システムエラー：{0}：{1}", CommonMotions.GetMethodName(), ex.Message);
+                return new ArrayList();
+            }
+        }
+
+        /// <summary>
+        /// 入金明細データを取得する。
+        /// </summary>
+        /// <param name="orderersDivision"></param>
+        /// <param name="orderersCode"></param>
+        /// <returns></returns>
+        //private ArrayList SelectDepositDetailData(int orderersDivision, int orderersCode, int targetDate)
+        private ArrayList SelectDepositDetailData(int orderersDivision, int orderersCode)
+        {
+            try
+            {
+                var sql = new StringBuilder();
+                //sql.Append("select ");
+                //sql.Append("DepD.OrderersDivision, ");
+                //sql.Append("DepD.OrderersCode, ");
+                //sql.Append("DepD.TargetDate, ");
+                //sql.Append("DepD.SeqNo, ");
+
+                //sql.Append("null as DepositDate, ");
+                //sql.Append("null, ");
+                //sql.Append("null, ");
+                //sql.Append("null, ");
+                //sql.Append("null, ");
+                //sql.Append("null, ");
+                //sql.Append("null, ");
+
+                //sql.Append("DepD.LineCount, ");
+                //sql.Append("ifnull(DepD.RequestNo, 0) as RequestNo, ");
+                //sql.Append("ifnull(DepD.OrderNo, 0) as OrderNo, ");
+                //sql.Append("DepD.DepositAmount, ");
+                //sql.Append("ifnull(DepD.DiscountAmount, 0) as DiscountAmount, ");
+                //sql.Append("ifnull(DepD.CnstrPrice, 0) as CnstrPrice, ");
+                //sql.Append("ifnull(DepD.Fees, 0) as Fees, ");
+                //sql.Append("ifnull(DepD.OtherAdjustments, 0) as OtherAdjustments, ");
+                //sql.Append("ifnull(DepD.CarryAmount, 0) as CarryAmount, ");
+                //sql.Append("ifnull(DepD.ApprovalPersonCode, 0) as ApprovalPersonCode, ");
+                //sql.Append("ifnull(DepD.ApprovalDate, 0) as ApprovalDate, ");
+                //sql.Append("DepD.ApprovalEndFlg, ");
+                //sql.Append("PicM.SealPrintName, ");
+                //sql.Append("PicM2.DepartmentCode, ");
+                ////sql.Append("DATE_FORMAT(ReqT.BillCreationDate, '%Y/%m/%d') as BillCreationDate, ");
+                //sql.Append("'' as BillCreationDate, ");
+                ////sql.Append("ReqT.BillPrice, ");
+                ////sql.Append("ReqT.TaxPrice, ");
+                //sql.Append("0, ");
+                //sql.Append("0, ");
+                //sql.Append("Cbi.ConstructionCode, ");
+                //sql.Append("Cbi.ConstructionPersonCode, ");
+                //sql.Append("Cbi.ConstrSubPersonCode, ");
+                //sql.Append("Cbi.ConstructionInstructor, ");
+                //sql.Append("CbiD.DetailNo, ");
+                //sql.Append("CbiD.DetailString ");
+                //sql.Append("from DepositDataDetail DepD ");
+                //sql.Append("inner join PersonInChargeMaster as PicM ");
+                //sql.Append("on PicM.PersonCode = DepD.ApprovalPersonCode ");
+                ///////////////////////////////////////////////////////////////////////////////
+                ////　検索条件(動的)START
+                ///////////////////////////////////////////////////////////////////////////////
+                //// 担当者
+                //if (!m_Select_TargetPerson.Equals(0))
+                //{
+                //    sql.AppendFormat("AND PicM.PersonCode = {0} ", m_Select_TargetPerson);
+                //}
+
+                //// 部署
+                //if (!m_Select_TargetDepartment.Equals(0))
+                //{
+                //    sql.AppendFormat("AND PicM.DepartmentCode = {0} ", m_Select_TargetDepartment);
+                //}
+
+                //sql.Append("inner join DEPOSITDATA Dep ");
+                //sql.Append("on DepD.ORDERERSDIVISION = Dep.ORDERERSDIVISION ");
+                //sql.Append("and DepD.ORDERERSCODE = Dep.ORDERERSCODE ");
+                //sql.Append("and DepD.TARGETDATE = Dep.TARGETDATE ");
+                //sql.Append("and DepD.SEQNO = Dep.SEQNO ");
+
+                //// 営業期
+                //sql.AppendFormat("AND Dep.BusinessPeriod = {0} ", m_Select_TargetBusinessPeriod);
+
+                //// 対象月
+                //if (!m_Select_TargetDate.Equals(0))
+                //{
+                //    sql.AppendFormat("AND SUBSTRING( Dep.TARGETDATE, 5 ) = {0} ", m_Select_TargetDate.ToString("00"));
+                //}
+                ///////////////////////////////////////////////////////////////////////////////
+                ////　検索条件(動的)END
+                ///////////////////////////////////////////////////////////////////////////////
+                ////sql.Append("left outer join RequestTotalData as ReqT on ReqT.RequestNo = DepD.RequestNo and ReqT.OrderNo = DepD.OrderNo ");
+                //sql.Append("left outer join ConstructionBaseInfo as Cbi on Cbi.ConstructionCode = ReqT.RequestNo ");
+                //sql.Append("left outer join ConstructionBaseInfoDetail as CbiD on CbiD.ConstructionCode = Cbi.ConstructionCode and CbiD.DetailNo = 2 ");
+                //sql.Append("left outer join ConstructionBaseInfo as Cbi2 on Cbi2.ConstructionCode = Cbi.ConstructionCode ");
+                //sql.Append("left outer join PersonInChargeMaster as PicM2 on PicM2.PersonCode = Cbi2.ConstructionPersonCode ");
+                //sql.Append("left outer join ApprovalMaster as Am on Am.DepartmentCode = PicM2.DepartmentCode and Am.ApprovalCode = 3 and Am.ApprovalAuthority = 1 ");
+                //sql.AppendFormat("where DepD.OrderersDivision = {0} and DepD.OrderersCode = {1} and DepD.RequestNo is not null ", orderersDivision, orderersCode);
+                //sql.Append("group by ");
+                //sql.Append("DepD.OrderersDivision, ");
+                //sql.Append("DepD.OrderersCode, ");
+                //sql.Append("DepD.TargetDate, ");
+                //sql.Append("DepD.SeqNo, ");
+                //sql.Append("DepD.LineCount, ");
+                //sql.Append("DepD.RequestNo, ");
+                //sql.Append("DepD.OrderNo, ");
+                //sql.Append("DepD.DepositAmount, ");
+                //sql.Append("DepD.DiscountAmount, ");
+                //sql.Append("DepD.CnstrPrice, ");
+                //sql.Append("DepD.Fees, ");
+                //sql.Append("DepD.OtherAdjustments, ");
+                //sql.Append("DepD.CarryAmount, ");
+                //sql.Append("DepD.ApprovalPersonCode, ");
+                //sql.Append("DepD.ApprovalDate, ");
+                //sql.Append("DepD.ApprovalEndFlg, ");
+                //sql.Append("PicM.SealPrintName, ");
+                //sql.Append("PicM2.DepartmentCode, ");
+                //sql.Append("ReqT.BillCreationDate, ");
+                //sql.Append("ReqT.BillPrice, ");
+                //sql.Append("ReqT.TaxPrice, ");
+                //sql.Append("Cbi.ConstructionCode, ");
+                //sql.Append("Cbi.ConstructionPersonCode, ");
+                //sql.Append("Cbi.ConstrSubPersonCode, ");
+                //sql.Append("Cbi.ConstructionInstructor, ");
+                //sql.Append("CbiD.DetailNo, ");
+                //sql.Append("CbiD.DetailString ");
+                //sql.Append("order by DepD.OrderersDivision, DepD.OrderersCode, DepD.SeqNo, DepD.LineCount, DepD.RequestNo desc, DepD.OrderNo desc ");
+                sql.Append("SELECT ");
+                sql.Append("DepD.OrderersDivision, ");
+                sql.Append("DepD.OrderersCode, ");
+                sql.Append("DepD.TargetDate, ");
+                sql.Append("DepD.SeqNo, ");
+
+                sql.Append("null as DepositDate, ");
+                sql.Append("null, ");
+                sql.Append("null, ");
+                sql.Append("null, ");
+                sql.Append("null, ");
+                sql.Append("null, ");
+                sql.Append("null, ");
+
+                sql.Append("DepD.LineCount, ");
+                sql.Append("ifnull(DepD.RequestNo, 0) as RequestNo, ");
+                sql.Append("ifnull(DepD.OrderNo, 0) as OrderNo, ");
+                sql.Append("DepD.DepositAmount, ");
+                sql.Append("ifnull(DepD.DiscountAmount, 0) as DiscountAmount, ");
+                sql.Append("ifnull(DepD.CnstrPrice, 0) as CnstrPrice, ");
+                sql.Append("ifnull(DepD.Fees, 0) as Fees, ");
+                sql.Append("ifnull(DepD.OtherAdjustments, 0) as OtherAdjustments, ");
+                sql.Append("ifnull(DepD.CarryAmount, 0) as CarryAmount, ");
+                sql.Append("ifnull(DepD.ApprovalPersonCode, 0) as ApprovalPersonCode, ");
+                sql.Append("ifnull(DepD.ApprovalDate, 0) as ApprovalDate, ");
+                sql.Append("DepD.ApprovalEndFlg, ");
+                sql.Append("PicM.SealPrintName, ");
+                sql.Append("0, ");                                  //sql.Append("PicM2.DepartmentCode, ");
+                sql.Append("'' as BillCreationDate, ");             //sql.Append("DATE_FORMAT(ReqT.BillCreationDate, '%Y/%m/%d') as BillCreationDate, ");
+                sql.Append("0, ");                                  //sql.Append("ReqT.BillPrice, ");
+                sql.Append("0, ");                                  //sql.Append("ReqT.TaxPrice, ");
+                sql.Append("0, ");                                  //sql.Append("Cbi.ConstructionCode, ");
+                sql.Append("0, ");                                  //sql.Append("Cbi.ConstructionPersonCode, ");
+                sql.Append("0, ");                                  //sql.Append("Cbi.ConstrSubPersonCode, ");
+                sql.Append("0, ");                                  //sql.Append("Cbi.ConstructionInstructor, ");
+                sql.Append("0, ");                                 //sql.Append("CbiD.DetailNo, ");
+                sql.Append("ReqH.ReqConstructionName as DetailString ");           //sql.Append("CbiD.DetailString ");
+                sql.Append("FROM ");
+                sql.Append("DepositDataDetail AS DepD ");
+                sql.Append("INNER JOIN PersonInChargeMaster AS PicM ");
+                sql.Append("ON PicM.PersonCode = DepD.ApprovalPersonCode ");
+                /////////////////////////////////////////////////////////////////////////////
+                //　検索条件(動的)START
+                /////////////////////////////////////////////////////////////////////////////
+                // 担当者
+                if (!m_Select_TargetPerson.Equals(0))
+                {
+                    sql.AppendFormat("AND PicM.PersonCode = {0} ", m_Select_TargetPerson);
+                }
+
+                // 部署
+                if (!m_Select_TargetDepartment.Equals(0))
+                {
+                    sql.AppendFormat("AND PicM.DepartmentCode = {0} ", m_Select_TargetDepartment);
+                }
+
+                sql.Append("INNER join DEPOSITDATA Dep ");
+                sql.Append("ON DepD.ORDERERSDIVISION = Dep.ORDERERSDIVISION ");
+                sql.Append("AND DepD.ORDERERSCODE = Dep.ORDERERSCODE ");
+                sql.Append("AND DepD.TARGETDATE = Dep.TARGETDATE ");
+                sql.Append("AND DepD.SEQNO = Dep.SEQNO ");
+
+                // 営業期
+                sql.AppendFormat("AND Dep.BusinessPeriod = {0} ", m_Select_TargetBusinessPeriod);
+
+                // 対象月
+                if (!m_Select_TargetDate.Equals(0))
+                {
+                    sql.AppendFormat("AND SUBSTRING( Dep.TARGETDATE, 5 ) = {0} ", m_Select_TargetDate.ToString("00"));
+                }
+                /////////////////////////////////////////////////////////////////////////////
+                //　検索条件(動的)END
+                /////////////////////////////////////////////////////////////////////////////
+                //sql.Append("left outer join RequestTotalData as ReqT on ReqT.RequestNo = DepD.RequestNo and ReqT.OrderNo = DepD.OrderNo ");
+                sql.Append("LEFT OUTER JOIN RequestHead AS ReqH ON DepD.RequestNo = ReqH.RequestNo ");
+                //sql.Append("left outer join ConstructionBaseInfo as Cbi on Cbi.ConstructionCode = ReqT.RequestNo ");
+                //sql.Append("left outer join ConstructionBaseInfoDetail as CbiD on CbiD.ConstructionCode = Cbi.ConstructionCode and CbiD.DetailNo = 2 ");
+                //sql.Append("left outer join ConstructionBaseInfo as Cbi2 on Cbi2.ConstructionCode = Cbi.ConstructionCode ");
+                //sql.Append("left outer join PersonInChargeMaster as PicM2 on PicM2.PersonCode = Cbi2.ConstructionPersonCode ");
+                //sql.Append("left outer join ApprovalMaster as Am on Am.DepartmentCode = PicM2.DepartmentCode and Am.ApprovalCode = 3 and Am.ApprovalAuthority = 1 ");
+                sql.Append("LEFT OUTER JOIN ApprovalMaster AS Am ON PicM.DepartmentCode = Am.DepartmentCode AND Am.ApprovalCode = 3 AND Am.ApprovalAuthority = 1 ");
+                sql.AppendFormat("WHERE DepD.OrderersDivision = {0} and DepD.OrderersCode = {1} and DepD.RequestNo IS NOT NULL ", orderersDivision, orderersCode);
+                sql.Append("GROUP BY ");
+                sql.Append("DepD.OrderersDivision, ");
+                sql.Append("DepD.OrderersCode, ");
+                sql.Append("DepD.TargetDate, ");
+                sql.Append("DepD.SeqNo, ");
+                sql.Append("DepD.LineCount, ");
+                sql.Append("DepD.RequestNo, ");
+                sql.Append("DepD.OrderNo, ");
+                sql.Append("DepD.DepositAmount, ");
+                sql.Append("DepD.DiscountAmount, ");
+                sql.Append("DepD.CnstrPrice, ");
+                sql.Append("DepD.Fees, ");
+                sql.Append("DepD.OtherAdjustments, ");
+                sql.Append("DepD.CarryAmount, ");
+                sql.Append("DepD.ApprovalPersonCode, ");
+                sql.Append("DepD.ApprovalDate, ");
+                sql.Append("DepD.ApprovalEndFlg, ");
+                sql.Append("PicM.SealPrintName, ");
+                sql.Append("ReqH.ReqConstructionName ");
+                //sql.Append("PicM2.DepartmentCode, ");
+                //sql.Append("ReqT.BillCreationDate, ");
+                //sql.Append("ReqT.BillPrice, ");
+                //sql.Append("ReqT.TaxPrice, ");
+                //sql.Append("Cbi.ConstructionCode, ");
+                //sql.Append("Cbi.ConstructionPersonCode, ");
+                //sql.Append("Cbi.ConstrSubPersonCode, ");
+                //sql.Append("Cbi.ConstructionInstructor, ");
+                //sql.Append("CbiD.DetailNo, ");
+                //sql.Append("CbiD.DetailString ");
+                sql.Append("ORDER BY DepD.OrderersDivision, DepD.OrderersCode, DepD.SeqNo, DepD.LineCount, DepD.RequestNo DESC, DepD.OrderNo DESC ");
+                var depDb = new IODepositData();
+                var data = new ArrayList();
+                if (!depDb.ExecuteReader(sql.ToString(), ref data)) return new ArrayList();
+                return data;
+            }
+            catch (Exception ex)
+            {
+                logger.ErrorFormat("システムエラー：{0}：{1}", CommonMotions.GetMethodName(), ex.Message);
+                return new ArrayList();
+            }
+        }
+
+        /// <summary>
+        /// 入金確認承認データより、承認者を取得する。
+        /// </summary>
+        /// <param name="orderersDivision"></param>
+        /// <param name="orderersCode"></param>
+        /// <param name="seqNo"></param>
+        /// <param name="lineCount"></param>
+        /// <param name="depositApprovals"></param>
+        /// <returns></returns>
+        private bool SelectApprove(int orderersDivision, int orderersCode, int seqNo, int lineCount, ref List<DepositApprovalInfo> depositApprovals)
+        {
+            IODepositApprovalInfo ioDai = new IODepositApprovalInfo();
+            try
+            {
+                var sql = string.Format(" where OrderersDivision = {0} and OrderersCode = {1} and TargetDate = {2} and SeqNo = {3} and LineCount = {4} order by ApprovalNo",
+                    orderersDivision, orderersCode, m_Select_TargetDate.ToString(), seqNo, lineCount);
+                if (!ioDai.SelectAction(sql, ref depositApprovals))
+                    return false;
+                return true;
+            }
+            catch (Exception ex)
+            {
+                logger.ErrorFormat("システムエラー：{0}：{1}", CommonMotions.GetMethodName(), ex.Message);
+                return false;
+            }
+            finally
+            {
+                ioDai = null;
+            }
+        }
+
+        /// <summary>
+        /// 業者行の内容を更新する。
+        /// </summary>
+        /// <param name="depositOrderer"></param>
+        /// <param name="position"></param>
+        private void UpdateDepositOrdererRows(DepositOrderer depositOrderer, int position)
+        {
+            dgvMaster.SuspendLayout();
+            var x = dgvMaster.FirstDisplayedScrollingColumnIndex;
+            var y = dgvMaster.FirstDisplayedScrollingRowIndex;
+            try
+            {
+                RemoveDepositOrdererRows(depositOrderer);
+                AddDepositOrdererRows(depositOrderer, position);
+            }
+            catch (Exception ex)
+            {
+                logger.ErrorFormat("システムエラー：{0}：{1}", CommonMotions.GetMethodName(), ex.Message);
+            }
+            finally
+            {
+                dgvMaster.FirstDisplayedScrollingColumnIndex = x;
+                dgvMaster.FirstDisplayedScrollingRowIndex = y;
+                dgvMaster.ResumeLayout();
+            }
+        }
+
+        /// <summary>
+        /// 業者行を削除する。
+        /// </summary>
+        /// <param name="depositOrderer"></param>
+        private void RemoveDepositOrdererRows(DepositOrderer depositOrderer)
+        {
+            for (var i = dgvMaster.RowCount - 1; i >= 0; i--)
+            {
+                var cells = dgvMaster.Rows[i].Cells;
+                if (CommonMotions.cnvInt(cells[(int)DispColumn.OrderersDivision].Value) == depositOrderer.OrderersDivision
+                    && CommonMotions.cnvInt(cells[(int)DispColumn.OrderersCode].Value) == depositOrderer.OrderersCode)
+                {
+                    dgvMaster.Rows.RemoveAt(i);
+                }
+            }
+        }
+
+        /// <summary>
+        /// 業者行を追加する。
+        /// </summary>
+        /// <param name="depositOrderer"></param>
+        /// <param name="position"></param>
+        private void AddDepositOrdererRows(DepositOrderer depositOrderer, int position)
+        {
+            try
+            {
+                if (depositOrderer.Deleted)
+                    return;
+                // 明細行を作成
+                dgvMaster.Rows.Insert(position, depositOrderer.Size);
+                // いったんすべての行をReadOnlyにしておく
+                for (var i = position; i < position + depositOrderer.Size; i++)
+                    dgvMaster.Rows[i].ReadOnly = true;
+                var ordererRow = dgvMaster.Rows[position];
+                // 請求先情報の表示
+                ordererRow.Cells[(int)DispColumn.No].Value = depositOrderer.No;
+                ordererRow.Cells[(int)DispColumn.OrderersDivision].Value = depositOrderer.OrderersDivision;
+                ordererRow.Cells[(int)DispColumn.OrderersCode].Value = depositOrderer.OrderersCode;
+                ordererRow.Cells[(int)DispColumn.OrderersName].Value = depositOrderer.OrderersName;
+                if (depositOrderer.VisibleDepositDetails.Count == 0)
+                {
+                    ordererRow.Cells[(int)DispColumn.DepositDate].ReadOnly = false;
+                    ordererRow.Cells[(int)DispColumn.DepositAmountCash].ReadOnly = false;
+                    ordererRow.Cells[(int)DispColumn.DepositAmountBill].ReadOnly = false;
+                }
+                // 入金情報の表示
+                var index = 0;
+                foreach (var deposit in depositOrderer.VisibleDeposits)
+                {
+                    var row = dgvMaster.Rows[position + index];
+                    row.Cells[(int)DispColumn.OrderersDivision].Value = depositOrderer.OrderersDivision;
+                    row.Cells[(int)DispColumn.OrderersCode].Value = depositOrderer.OrderersCode;
+                    row.Cells[(int)DispColumn.SeqNo].Value = deposit.SeqNo;
+                    row.Cells[(int)DispColumn.DepositDate].Value = deposit.DepositDate;
+                    if (deposit.DepositAmountCash.HasValue)
+                        SetPrice(row.Cells, (int)DispColumn.DepositAmountCash, deposit.DepositAmountCash.Value);
+                    if (deposit.DepositAmountBill.HasValue)
+                        SetPrice(row.Cells, (int)DispColumn.DepositAmountBill, deposit.DepositAmountBill.Value);
+                    // 編集設定
+                    if (CanEditDeposit(depositOrderer))
+                    {
+                        row.Cells[(int)DispColumn.DepositDate].ReadOnly = false;
+                        row.Cells[(int)DispColumn.DepositAmountCash].ReadOnly = false;
+                        row.Cells[(int)DispColumn.DepositAmountBill].ReadOnly = false;
+                    }
+                    index++;
+                }
+                index = 0;
+                foreach (var depositDetail in depositOrderer.VisibleDepositDetails)
+                {
+                    var row = dgvMaster.Rows[position + index];
+                    row.Cells[(int)DispColumn.OrderersDivision].Value = depositOrderer.OrderersDivision;
+                    row.Cells[(int)DispColumn.OrderersCode].Value = depositOrderer.OrderersCode;
+                    row.Cells[(int)DispColumn.RequestNo].Value = depositDetail.RequestNo;
+                    row.Cells[(int)DispColumn.LineCount].Value = depositDetail.LineCount;
+                    row.Cells[(int)DispColumn.OrderNo].Value = depositDetail.OrderNo;
+                    row.Cells[(int)DispColumn.ConstructionName].Value = depositDetail.ConstructionName;
+                    row.Cells[(int)DispColumn.ConstructionName_Raw].Value = depositDetail.ConstructionNameRow;
+                    // TODO 入金予定日
+                    row.Cells[(int)DispColumn.BillCreationDate].Value = depositDetail.BillCreationDate;
+                    SetPrice(row.Cells, (int)DispColumn.BillPrice, depositDetail.BillPrice);
+                    SetPrice(row.Cells, (int)DispColumn.TaxPrice, depositDetail.TaxPrice);
+                    SetPrice(row.Cells, (int)DispColumn.DepositAmount, depositDetail.DepositAmount);
+                    SetPrice(row.Cells, (int)DispColumn.DiscountAmount, depositDetail.DiscountAmount);
+                    SetPrice(row.Cells, (int)DispColumn.CnstrPrice, depositDetail.CnstrPrice);
+                    SetPrice(row.Cells, (int)DispColumn.Fees, depositDetail.Fees);
+                    SetPrice(row.Cells, (int)DispColumn.OtherAdjustments, depositDetail.OtherAdjustments);
+                    SetPrice(row.Cells, (int)DispColumn.CarryAmount, depositDetail.CarryAmount);
+                    row.Cells[(int)DispColumn.PersonCode].Value = depositDetail.ApprovalPersonCode;
+                    row.Cells[(int)DispColumn.PersonName].Value = depositDetail.ApprovalPersonName;
+                    // 担当者未承認
+                    if (!depositDetail.IsApprovedByStaff)
+                    {
+                        row.Cells[(int)DispColumn.PersonName].Style.ForeColor = Color.Gray;
+                        row.Cells[(int)DispColumn.PersonDate].Value = "";
+                    }
+                    var j = (int)DispColumn.ApprovalName_1;
+                    foreach (var depositeApproval in depositDetail.DepositApprovals)
+                    {
+                        row.Cells[j].Value = depositeApproval.ApprovalPersonName;
+                        row.Cells[j + 1].Value = depositeApproval.ApprovalPerson;
+                        if (depositeApproval.ApprovalDate == "")
+                            row.Cells[j].Style.ForeColor = Color.Gray;
+                        dgvMaster.Columns[j].Visible = true;
+                        j += 5;
+                    }
+                    if (CanEditDepositDetail(depositDetail))
+                    {
+                        row.Cells[(int)DispColumn.DepositAmount].ReadOnly = false;
+                        row.Cells[(int)DispColumn.DiscountAmount].ReadOnly = false;
+                        row.Cells[(int)DispColumn.CnstrPrice].ReadOnly = false;
+                        row.Cells[(int)DispColumn.Fees].ReadOnly = false;
+                        row.Cells[(int)DispColumn.OtherAdjustments].ReadOnly = false;
+                        row.Cells[(int)DispColumn.CarryAmount].ReadOnly = false;
+                    }
+                    index++;
+                }
+                //AddUnknownRow(depositOrderer, position);
+                AddBlankRow(depositOrderer, position);
+                AddTotalRow(depositOrderer, position);
+            }
+            catch (Exception ex)
+            {
+                logger.ErrorFormat("システムエラー：{0}：{1}", CommonMotions.GetMethodName(), ex.Message);
+            }
+        }
+
+        /// <summary>
+        /// データを表示する。
+        /// </summary>
+        private void DisplayData()
+        {
+            try
+            {
+                //// 選択対象月の退避
+                //m_Select_TargetDate = CommonMotions.cnvInt(CommonMotions.cnvString(numericUpDown2.Value).Replace("/", ""));
+                //depositOrderers = new List<DepositOrderer>();
+                //dgvMaster.Rows.Clear();
+                //// データの取得
+                //depositOrderers = SelectDepositOrderers();
+                //// 請求先単位で設定を行う。
+                //dgvMaster.SuspendLayout();
+                //for (var i = (int)DispColumn.ApprovalName_1; i <= (int)DispColumn.ApprovalName_10; i += 5)
+                //    dgvMaster.Columns[i].Visible = false;
+                //foreach (var deposit in depositOrderers)
+                //{
+                //    AddDepositOrdererRows(deposit, dgvMaster.RowCount);
+                //}
+                //isDirty = false;
+                //ControlButton();
+
+                ///////////////////////////////////////////////////////////////////////////////////////
+                // 表示条件の取得
+                ///////////////////////////////////////////////////////////////////////////////////////
+
+                //　営業期
+                m_Select_TargetBusinessPeriod = CommonMotions.cnvInt(numericUpDown2.Value);
+
+                //　対象月（月指定が選択されているかつ空白以外の場合のみ）
+                if (radioButton2.Checked && !CommonMotions.cnvInt(comboBox1.SelectedItem).Equals("　"))
+                {
+                    m_Select_TargetDate = CommonMotions.cnvInt(comboBox1.SelectedItem);
+                }
+                else
+                {
+                    m_Select_TargetDate = 0;
+                }
+
+                //　部署
+                m_Select_TargetDepartment = CommonMotions.cnvInt(comboBox2.SelectedValue);
+
+                //  担当者
+                m_Select_TargetPerson = CommonMotions.cnvInt(comboBox3.SelectedValue); ;
+
+                ///////////////////////////////////////////////////////////////////////////////////////////
+                // データの取得
+                ///////////////////////////////////////////////////////////////////////////////////////////
+
+                depositOrderers = new List<DepositOrderer>();
+                dgvMaster.Rows.Clear();
+
+                depositOrderers = SelectDepositOrderers();
+
+                // 請求先単位で設定を行う。
+                dgvMaster.SuspendLayout();
+                for (var i = (int)DispColumn.ApprovalName_1; i <= (int)DispColumn.ApprovalName_10; i += 5)
+                    dgvMaster.Columns[i].Visible = false;
+                foreach (var deposit in depositOrderers)
+                {
+                    AddDepositOrdererRows(deposit, dgvMaster.RowCount);
+                }
+                isDirty = false;
+                ControlButton();
+            }
+            catch (Exception ex)
+            {
+                logger.ErrorFormat("システムエラー：{0}：{1}", CommonMotions.GetMethodName(), ex.Message);
+            }
+            finally
+            {
+                dgvMaster.ResumeLayout();
+                if (dgvMaster.Rows.Count > 0)
+                {
+                    dgvMaster.FirstDisplayedScrollingRowIndex = 0;
+                    dgvMaster.FirstDisplayedScrollingColumnIndex = 1;
+                    dgvMaster.CurrentCell = dgvMaster[1, 0];
+                }
+            }
+        }
+
+        /// <summary>
+        /// 不明行かを判定する。
+        /// </summary>
+        /// <param name="index"></param>
+        /// <returns></returns>
+        private bool IsUnknownRow(int index)
+        {
+            //            var cells = dgvMaster.Rows[index].Cells;
+            //            return CommonMotions.cnvString(cells[(int)DispColumn.ConstructionName].Value) == "不明"
+            //                && CommonMotions.cnvString(cells[(int)DispColumn.ConstructionName_Raw].Value) == "";
+            return false;
+        }
+
+        /// <summary>
+        /// 空白行かを判定する。
+        /// </summary>
+        /// <param name="index"></param>
+        /// <returns></returns>
+        private bool IsBlankRow(int index)
+        {
+            var cells = dgvMaster.Rows[index].Cells;
+            return CommonMotions.cnvString(cells[(int)DispColumn.SeqNo]) == ""
+                && CommonMotions.cnvString(cells[(int)DispColumn.LineCount]) == ""
+                && CommonMotions.cnvString(cells[(int)DispColumn.ConstructionName].Value) == ""
+                && CommonMotions.cnvString(cells[(int)DispColumn.ConstructionName_Raw].Value) == "";
+        }
+
+        /// <summary>
+        /// 不明行の設定を行う。
+        /// </summary>
+        /// <param name="index"></param>
+        private void AddUnknownRow(DepositOrderer depositOrderer, int index)
+        {
+            // 不明行金額の計算
+            var depositAmountCash = 0;
+            var depositAmountBill = 0;
+            foreach (var deposit in depositOrderer.Deposits)
+            {
+                depositAmountCash += deposit.DepositAmountCash.GetValueOrDefault(0);
+                depositAmountBill += deposit.DepositAmountBill.GetValueOrDefault(0);
+            }
+            var depositAmount = 0;
+            foreach (var depositDetail in depositOrderer.DepositDetails)
+            {
+                depositAmount += depositDetail.DepositAmount;
+            }
+            var unknownAmount = (depositAmountCash + depositAmountBill) - depositAmount;
+            if (unknownAmount <= 0)
+                return;
+            // 不明行は入金明細の一番下に作成する
+            var unknownIndex = index + depositOrderer.VisibleDepositDetails.Count;
+            // 入金明細が入金より多い場合は不明行を追加
+            if (depositOrderer.VisibleDepositDetails.Count >= depositOrderer.VisibleDeposits.Count)
+            {
+                dgvMaster.Rows.Insert(unknownIndex);
+                dgvMaster.Rows[unknownIndex].ReadOnly = true;
+            }
+            var row = dgvMaster.Rows[unknownIndex];
+            row.Cells[(int)DispColumn.OrderersDivision].Value = depositOrderer.OrderersDivision;
+            row.Cells[(int)DispColumn.OrderersCode].Value = depositOrderer.OrderersCode;
+            //row.Cells[(int)DispColumn.ConstructionName].Value = "不明";
+            // 編集設定
+            var readOnly = !CanEditDeposit(depositOrderer);
+            row.Cells[(int)DispColumn.DepositDate].ReadOnly = readOnly;
+            row.Cells[(int)DispColumn.DepositAmountCash].ReadOnly = readOnly;
+            row.Cells[(int)DispColumn.DepositAmountBill].ReadOnly = readOnly;
+            SetPrice(row.Cells, (int)DispColumn.DepositAmount, unknownAmount);
+        }
+
+        private int CalculateDifference(DepositOrderer depositOrderer)
+        {
+            var depositAmountCash = 0;
+            var depositAmountBill = 0;
+            foreach (var deposit in depositOrderer.Deposits)
+            {
+                depositAmountCash += deposit.DepositAmountCash.GetValueOrDefault(0);
+                depositAmountBill += deposit.DepositAmountBill.GetValueOrDefault(0);
+            }
+            var depositAmount = 0;
+            foreach (var depositDetail in depositOrderer.DepositDetails)
+            {
+                depositAmount += depositDetail.DepositAmount;
+            }
+            return depositAmountCash + depositAmountBill - depositAmount;
+        }
+
+        /// <summary>
+        /// 合計行の設定を行う。
+        /// </summary>
+        /// <param name="index"></param>
+        private void AddTotalRow(DepositOrderer depositOrderer, int index)
+        {
+            var depositAmountCash = 0;
+            var depositAmountBill = 0;
+            foreach (var deposit in depositOrderer.Deposits)
+            {
+                depositAmountCash += deposit.DepositAmountCash.GetValueOrDefault(0);
+                depositAmountBill += deposit.DepositAmountBill.GetValueOrDefault(0);
+            }
+            var billPrice = 0;
+            var taxPrice = 0;
+            var depositAmount = 0;
+            var discountAmount = 0;
+            var cnstrPrice = 0;
+            var fees = 0;
+            var otherAdjustments = 0;
+            var carryAmount = 0;
+            foreach (var depositDetail in depositOrderer.DepositDetails)
+            {
+                billPrice += depositDetail.BillPrice;
+                taxPrice += depositDetail.TaxPrice;
+                depositAmount += depositDetail.DepositAmount;
+                discountAmount += depositDetail.DiscountAmount;
+                cnstrPrice += depositDetail.CnstrPrice;
+                fees += depositDetail.Fees;
+                otherAdjustments += depositDetail.OtherAdjustments;
+                carryAmount += depositDetail.CarryAmount;
+            }
+            var headerIndex = DetectHeaderIndex(index);
+            var headerCells = dgvMaster.Rows[headerIndex].Cells;
+            var subtotalIndex = dgvMaster.RowCount;
+            for (var i = headerIndex; i < dgvMaster.RowCount; i++)
+            {
+                var cells = dgvMaster.Rows[i].Cells;
+                if (CommonMotions.cnvInt(headerCells[(int)DispColumn.OrderersDivision].Value) != CommonMotions.cnvInt(cells[(int)DispColumn.OrderersDivision].Value)
+                    || CommonMotions.cnvInt(headerCells[(int)DispColumn.OrderersCode].Value) != CommonMotions.cnvInt(cells[(int)DispColumn.OrderersCode].Value))
+                {
+                    subtotalIndex = i;
+                    break;
+                }
+            }
+            dgvMaster.Rows.Insert(subtotalIndex, 4);
+            // 小計
+            dgvMaster.Rows[subtotalIndex].DefaultCellStyle.BackColor = Color.Coral;
+            dgvMaster.Rows[subtotalIndex].ReadOnly = true;
+            var subtotalCells = dgvMaster.Rows[subtotalIndex].Cells;
+            subtotalCells[(int)DispColumn.OrderersDivision].Value = depositOrderer.OrderersDivision;
+            subtotalCells[(int)DispColumn.OrderersCode].Value = depositOrderer.OrderersCode;
+            subtotalCells[(int)DispColumn.OrderersName].Value = "小計";
+            SetPrice(subtotalCells, (int)DispColumn.DepositAmountCash, depositAmountCash);
+            SetPrice(subtotalCells, (int)DispColumn.DepositAmountBill, depositAmountBill);
+            SetPrice(subtotalCells, (int)DispColumn.BillPrice, billPrice);
+            SetPrice(subtotalCells, (int)DispColumn.TaxPrice, taxPrice);
+            SetPrice(subtotalCells, (int)DispColumn.DepositAmount, depositAmount);
+            SetPrice(subtotalCells, (int)DispColumn.DiscountAmount, discountAmount);
+            SetPrice(subtotalCells, (int)DispColumn.CnstrPrice, cnstrPrice);
+            SetPrice(subtotalCells, (int)DispColumn.Fees, fees);
+            SetPrice(subtotalCells, (int)DispColumn.OtherAdjustments, otherAdjustments);
+            SetPrice(subtotalCells, (int)DispColumn.CarryAmount, carryAmount);
+            // 入金金額
+            dgvMaster.Rows[subtotalIndex + 1].DefaultCellStyle.BackColor = Color.Yellow;
+            dgvMaster.Rows[subtotalIndex + 1].ReadOnly = true;
+            var depositCells = dgvMaster.Rows[subtotalIndex + 1].Cells;
+            depositCells[(int)DispColumn.OrderersDivision].Value = depositOrderer.OrderersDivision;
+            depositCells[(int)DispColumn.OrderersCode].Value = depositOrderer.OrderersCode;
+            depositCells[(int)DispColumn.OrderersName].Value = "入金金額";
+            SetPrice(depositCells, (int)DispColumn.DepositAmountCash, depositAmountCash + depositAmountBill);
+            // 調整後金額
+            dgvMaster.Rows[subtotalIndex + 2].DefaultCellStyle.BackColor = Color.PaleTurquoise;
+            dgvMaster.Rows[subtotalIndex + 2].ReadOnly = true;
+            var adjustmentCells = dgvMaster.Rows[subtotalIndex + 2].Cells;
+            adjustmentCells[(int)DispColumn.OrderersDivision].Value = depositOrderer.OrderersDivision;
+            adjustmentCells[(int)DispColumn.OrderersCode].Value = depositOrderer.OrderersCode;
+            adjustmentCells[(int)DispColumn.OrderersName].Value = "調整後金額";
+            SetPrice(adjustmentCells, (int)DispColumn.DepositAmountCash, depositAmount);
+            // 差額
+            dgvMaster.Rows[subtotalIndex + 3].DefaultCellStyle.BackColor = Color.Chartreuse;
+            dgvMaster.Rows[subtotalIndex + 3].ReadOnly = true;
+            var differentCells = dgvMaster.Rows[subtotalIndex + 3].Cells;
+            differentCells[(int)DispColumn.OrderersDivision].Value = depositOrderer.OrderersDivision;
+            differentCells[(int)DispColumn.OrderersCode].Value = depositOrderer.OrderersCode;
+            differentCells[(int)DispColumn.OrderersName].Value = "差額";
+            SetPrice(differentCells, (int)DispColumn.DepositAmountCash, depositAmountCash + depositAmountBill - depositAmount);
+        }
+
+        private int DetectHeaderIndex(int index)
+        {
+            for (var i = index; i >= 0; i--)
+            {
+                if (CommonMotions.cnvString(dgvMaster.Rows[i].Cells[(int)DispColumn.OrderersName].Value) != "")
+                {
+                    return i;
+                }
+            }
+            return 0;
+        }
+
+        private int DetectHeaderIndex(DepositOrderer depositOrderer)
+        {
+            for (var i = 0; i < dgvMaster.RowCount; i++)
+            {
+                var cells = dgvMaster.Rows[i].Cells;
+                if (CommonMotions.cnvInt(cells[(int)DispColumn.OrderersDivision]) == depositOrderer.OrderersDivision
+                    && CommonMotions.cnvInt(cells[(int)DispColumn.OrderersCode]) == depositOrderer.OrderersCode)
+                {
+                    return i;
+                }
+            }
+            return 0;
+        }
+
+        private int DetectUnknownIndex(int index)
+        {
+            var headerIndex = DetectHeaderIndex(index);
+            for (var i = headerIndex; i < dgvMaster.Rows.Count; i++)
+            {
+                var constructionName = CommonMotions.cnvString(dgvMaster.Rows[i].Cells[(int)DispColumn.ConstructionName].Value);
+                if (constructionName == "" || constructionName == "不明")
+                {
+                    return i;
+                }
+            }
+            return 0;
+        }
+
+        private void SetPrice(DataGridViewCellCollection cells, int index, int price)
+        {
+            cells[index].Value = price.ToString("#,0");
+            cells[index].Style.ForeColor = Color.Black;
+            if (price < 0)
+            {
+                cells[index].Style.ForeColor = Color.Red;
+            }
+        }
+
+        private string ToOrdererName(int corporateStatusPoint, string corporateStatusName, string orderersName1, string orderersName2)
+        {
+            // 発注者名１△発注者名２
+            if (corporateStatusPoint == 0)
+            {
+                if (orderersName2 == "")
+                {
+                    return orderersName1;
+                }
+                return orderersName1 + "　" + orderersName2;
+            }
+            // 法人格名称△発注者名１△発注者名２
+            else if (corporateStatusPoint == 1)
+            {
+                if (orderersName2 == "")
+                {
+                    return corporateStatusName + "　" + orderersName1;
+                }
+                return corporateStatusName + orderersName1 + orderersName2;
+            }
+            // 発注者名１△法人格名称△発注者名２
+            if (orderersName2 == "")
+            {
+                return orderersName1 + "　" + corporateStatusName;
+            }
+            return orderersName1 + corporateStatusName + orderersName2;
+        }
+
+        /// <summary>
+        /// DataGridヘッダ色表示
+        /// </summary>
+        private void SetGridHeaderColor()
+        {
+            // ヘッダ色、-1:非表示、0:自動計算、1:総務、2：工事
+            int[] mc = {
+                -1,                     // ■編集状態
+                0,                      // No
+                -1,                     // ■発注先区分
+                -1,                     // ■発注者コード
+                -1,                     // ■連番
+                -1,                     // ■行番号
+                0,                      // 請求先名
+                1,                      // 入金日
+                1,                      // 入金金額 (振込み)
+                1,                      // 入金金額 (手形)
+                -1,                     // 請求No.
+                -1,                     // 受付番号
+                0,                      // 現場名
+                -1,                     // ■現場名 (DB登録値)
+                0,                      // 入金予定日
+                0,                      // 請求日
+                0,                      // 請求金額 (税抜)
+                0,                      // 請求金額 (消費税)
+                2,                      // 入金金額
+                2,                      // 値引金額
+                2,                      // 協力金
+                2,                      // 手数料
+                2,                      // その他調整
+                2,                      // 次回繰越
+                0,                      // 担当者承認
+                -1,                     // ■担当者コード
+                -1,                     // ■担当者日付
+                0,                      // 承認者１承認
+                -1,                     // ■承認者コード_1
+                -1,                     // ■承認権限区分_1
+                -1,                     // ■承認日付_1
+                -1,                     // ■承認順番_1
+                0,                      // 承認者２承認
+                -1,                     // ■承認者コード_2
+                -1,                     // ■承認権限区分_2
+                -1,                     // ■承認日付_2
+                -1,                     // ■承認順番_2
+                0,                      // 承認者３承認
+                -1,                     // ■承認者コード_3
+                -1,                     // ■承認権限区分_3
+                -1,                     // ■承認日付_3
+                -1,                     // ■承認順番_3
+                0,                      // 承認者４承認
+                -1,                     // ■承認者コード_4
+                -1,                     // ■承認権限区分_4
+                -1,                     // ■承認日付_4
+                -1,                     // ■承認順番_4
+                0,                      // 承認者５承認
+                -1,                     // ■承認者コード_5
+                -1,                     // ■承認権限区分_5
+                -1,                     // ■承認日付_5
+                -1,                     // ■承認順番_5
+                0,                      // 承認者６承認
+                -1,                     // ■承認者コード_6
+                -1,                     // ■承認権限区分_6
+                -1,                     // ■承認日付_6
+                -1,                     // ■承認順番_6
+                0,                      // 承認者７承認
+                -1,                     // ■承認者コード_7
+                -1,                     // ■承認権限区分_7
+                -1,                     // ■承認日付_7
+                -1,                     // ■承認順番_7
+                0,                      // 承認者８承認
+                -1,                     // ■承認者コード_8
+                -1,                     // ■承認権限区分_8
+                -1,                     // ■承認日付_8
+                -1,                     // ■承認順番_8
+                0,                      // 承認者９承認
+                -1,                     // ■承認者コード_9
+                -1,                     // ■承認権限区分_9
+                -1,                     // ■承認日付_9
+                -1,                     // ■承認順番_9
+                0,                      // 承認者１０承認
+                -1,                     // ■承認者コード_10
+                -1,                     // ■承認権限区分_10
+                -1,                     // ■承認日付_10
+                -1,                     // ■承認順番_10
+            };
+
+            dgvMaster.Font = new System.Drawing.Font("ＭＳ 明朝", 11.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(128)));
+            dgvMaster.ColumnHeadersHeight = dgvMaster.ColumnHeadersHeight + 10;
+
+            // ヘッダーセルの値の設定
+            for (int i = 0; i < 77; i++)
+            {
+                // ヘッダーセルの色を設定
+                // 総務
+                if (mc[i] == 1)
+                {
+                    dgvMaster.Columns[i].HeaderCell.Style.BackColor = Color.Coral;
+                }
+                // 工事担当者
+                else if (mc[i] == 2)
+                {
+                    dgvMaster.Columns[i].HeaderCell.Style.BackColor = Color.SkyBlue;
+                }
+                // 表示・自動計算
+                else
+                {
+                    dgvMaster.Columns[i].HeaderCell.Style.BackColor = Color.PaleGreen;
+                }
+            }
+        }
+
+        /// <summary>
+        /// 表示権限のチェックを実施する。
+        /// </summary>
+        /// <param name="orderer"></param>
+        /// <returns></returns>
+        private bool CheckOrdererPermission(DepositOrderer orderer)
+        {
+            try
+            {
+                // 全部署対象
+                if (m_UserInfo.m_SecRange == ClsSecurityPermission.SecRangeType.AllDepartment)
+                {
+                    return true;
+                }
+                var ioPdm = new IOMPersonDepartment();
+                var arDataPdm = new ArrayList();
+                var sql = new StringBuilder();
+                sql.Append("select count(*) from ConstructionBaseInfo Cbi ");
+                sql.Append("inner join PersonInChargeMaster PicM on PicM.PersonCode = Cbi.ConstructionPersonCode ");
+                sql.Append("inner join PersonDepartmentMaster PdM on PdM.DepartmentCode = PicM.DepartmentCode ");
+                sql.AppendFormat("where Cbi.OrderersDivision = {0} ", orderer.OrderersDivision);
+                sql.AppendFormat("and Cbi.OrderersCode = {0} ", orderer.OrderersCode);
+                sql.AppendFormat("and PdM.PersonCode = {0} ", CommonMotions.LoginUserData.PersonCode);
+                sql.AppendFormat("and PdM.DepartmentCode = {0} ", CommonMotions.LoginUserData.DepartmentCode);
+                // 自部門のみ表示の場合
+                if (m_UserInfo.m_SecRange == ClsSecurityPermission.SecRangeType.OneDepartment)
+                {
+                    sql.Append("and Pdm.AffiliationFlg = 1 ");
+                }
+                // 担当分のみ対象の場合
+                else if (m_UserInfo.m_SecRange == ClsSecurityPermission.SecRangeType.InCharge)
+                {
+                    sql.AppendFormat("and (Cbi.ConstructionPersonCode = {0} ", CommonMotions.LoginUserData.PersonCode);
+                    sql.AppendFormat("or Cbi.ConstrSubPersonCode = {0} ", CommonMotions.LoginUserData.PersonCode);
+                    sql.AppendFormat("or Cbi.ConstructionInstructor = {0}) ", CommonMotions.LoginUserData.PersonCode);
+                }
+                if (!ioPdm.ExecuteReader(sql.ToString(), ref arDataPdm))
+                    return false;
+                return CommonMotions.cnvInt(((object[])arDataPdm[0])[0]) > 0;
+            }
+            catch (Exception ex)
+            {
+                logger.ErrorFormat("システムエラー：{0}：{1}", CommonMotions.GetMethodName(), ex.Message);
+                return false;
+            }
+        }
+
+        /// <summary>
+        /// 表示権限のチェックを実施する。
+        /// </summary>
+        /// <param name="DepartmentCode"></param>
+        /// <param name="ConstructionPersonCode"></param>
+        /// <param name="ConstrSubPersonCode"></param>
+        /// <param name="ConstructionInstructor"></param>
+        /// <returns></returns>
+        private bool CheckPermission(int DepartmentCode, int ConstructionPersonCode, int ConstrSubPersonCode, int ConstructionInstructor)
+        {
+            try
+            {
+                // 全部署対象
+                if (m_UserInfo.m_SecRange == ClsSecurityPermission.SecRangeType.AllDepartment)
+                {
+                    return true;
+                }
+
+                // 複数部署対象、または自部署のみ対象
+                else if ((m_UserInfo.m_SecRange == ClsSecurityPermission.SecRangeType.MultiDepartment) || (m_UserInfo.m_SecRange == ClsSecurityPermission.SecRangeType.OneDepartment))
+                {
+                    var ioPdm = new IOMPersonDepartment();
+                    var arDataPdm = new ArrayList();
+                    var sql = new StringBuilder();
+                    sql.AppendLine("select Pdm.DepartmentCode ");
+                    sql.AppendLine("from PersonDepartmentMaster as Pdm ");
+                    sql.AppendFormat("where Pdm.PersonCode = {0} ", CommonMotions.LoginUserData.PersonCode);
+                    if (m_UserInfo.m_SecRange == ClsSecurityPermission.SecRangeType.OneDepartment)
+                    {
+                        sql.AppendLine("and Pdm.AffiliationFlg = 1 ");
+                    }
+                    if (!ioPdm.ExecuteReader(sql.ToString(), ref arDataPdm))
+                        return false;
+                    foreach (object[] work in arDataPdm)
+                    {
+                        if (CommonMotions.cnvInt(work[0]) == DepartmentCode)
+                        {
+                            return true;
+                        }
+                    }
+                    return false;
+                }
+                // 担当分のみ対象
+                else
+                {
+                    if ((CommonMotions.LoginUserData.PersonCode == ConstructionPersonCode) ||
+                        (CommonMotions.LoginUserData.PersonCode == ConstrSubPersonCode) ||
+                        (CommonMotions.LoginUserData.PersonCode == ConstructionInstructor))
+                    {
+                        return true;
+                    }
+                    else
+                    {
+                        return false;
+                    }
+                }
+            }
+            catch (Exception ex)
+            {
+                logger.ErrorFormat("システムエラー：{0}：{1}", CommonMotions.GetMethodName(), ex.Message);
+                return false;
+            }
+        }
+
+        /// <summary>
+        /// 担当未承認の承認者リスト
+        /// </summary>
+        /// <param name="departmentCode"></param>
+        /// <param name="approves"></param>
+        /// <returns></returns>
+        private bool SelectDefaultApprove(int departmentCode, ref List<ApproveData> approves)
+        {
+            var IoAm = new IOMApproval();
+            var arDataAm = new ArrayList();
+            var sql = new StringBuilder();
+            try
+            {
+                sql.AppendLine("select Am.APPROVALPERSON, Picm.SealPrintName,Am.ApprovalAuthority ");
+                sql.AppendLine("from ApprovalMaster as Am left join PersonInChargeMaster as Picm on Am.APPROVALPERSON = Picm.PERSONCODE ");
+                sql.AppendLine("where Am.APPROVALCODE = 98 ");
+                sql.AppendFormat("and Am.DepartmentCode = {0} ", departmentCode);
+                sql.AppendLine("order by Am.SEQNO desc ");
+
+                if (!IoAm.ExecuteReader(sql.ToString(), ref arDataAm)) return false;
+                approves = new List<ApproveData>();
+                int Order = 1;
+                foreach (object[] work in arDataAm)
+                {
+                    approves.Add(new ApproveData()
+                    {
+                        Key = CommonMotions.cnvInt(work[0]),
+                        Value = CommonMotions.cnvString(work[1]),
+                        Order = Order,
+                        ApprovalAuthority = CommonMotions.cnvInt(work[2])
+                    });
+                    Order++;
+                }
+
+                return true;
+            }
+            catch (Exception ex)
+            {
+                logger.ErrorFormat("システムエラー：{0}：{1}", CommonMotions.GetMethodName(), ex.Message);
+                return false;
+            }
+            finally
+            {
+                IoAm = null;
+            }
+        }
+
+        private bool CanEditDeposit(DepositOrderer depositOrderer)
+        {
+            // 担当者の場合
+            if (m_UserInfo.m_Type == CommonDefine.SecurityRankPos.NormalAuthority)
+            {
+                // 承認済みなら編集不可
+                if (depositOrderer.HasApprovedByApprover)
+                    return false;
+            }
+            // 所属長、統括者の場合
+            else if (m_UserInfo.m_Type == CommonDefine.SecurityRankPos.LimitedAuthority || m_UserInfo.m_Type == CommonDefine.SecurityRankPos.FreeAuthority)
+            {
+                if (depositOrderer.HasApprovedByLastApprover)
+                    return false;
+            }
+            // 特別権限の場合
+            else if (m_UserInfo.m_Type == CommonDefine.SecurityRankPos.SpecialAuthority)
+            {
+                if (depositOrderer.HasApprovedByLastApprover)
+                    return false;
+            }
+            return m_UserInfo.CanEditDeposit;
+        }
+
+        private bool CanEditDepositDetail(DepositDetail depositDetail)
+        {
+            // 担当者の場合
+            if (m_UserInfo.m_Type == CommonDefine.SecurityRankPos.NormalAuthority)
+            {
+                // 承認済みなら編集不可
+                if (depositDetail.IsApprovedByStaff || depositDetail.IsApprovedByApprover)
+                    return false;
+            }
+            // 所属長、統括者の場合
+            else if (m_UserInfo.m_Type == CommonDefine.SecurityRankPos.LimitedAuthority || m_UserInfo.m_Type == CommonDefine.SecurityRankPos.FreeAuthority)
+            {
+                // 上位の承認者でなければ編集不可
+                if (!IsUpperLevelApprover(depositDetail))
+                    return false;
+            }
+            // 特別権限の場合
+            else if (m_UserInfo.m_Type == CommonDefine.SecurityRankPos.SpecialAuthority)
+            {
+                if (depositDetail.IsApprovedByLastApprover)
+                    return false;
+            }
+            return m_UserInfo.CanEditDepositDetail;
+        }
+
+        private bool IsUpperLevelApprover(DepositDetail depositDetail)
+        {
+            if (depositDetail.DepositApprovals.Count == 0)
+                return true;
+            var lastApproverIndex = depositDetail.DepositApprovals.FindLastIndex(da => da.ApprovalDate != "");
+            var myIndex = depositDetail.DepositApprovals.FindLastIndex(da => da.ApprovalPerson == CommonMotions.LoginUserData.PersonCode);
+            return myIndex > lastApproverIndex;
+        }
+
+        /// <summary>
+        /// 編集用空白行追加
+        /// </summary>
+        /// <param name="index"></param>
+        private void AddBlankRow(DepositOrderer depositOrderer, int index)
+        {
+            var headerIndex = DetectHeaderIndex(index);
+            var headerCells = dgvMaster.Rows[headerIndex].Cells;
+            var blankIndex = dgvMaster.RowCount;
+            for (var i = headerIndex; i < dgvMaster.RowCount; i++)
+            {
+                var cells = dgvMaster.Rows[i].Cells;
+                if (CommonMotions.cnvInt(headerCells[(int)DispColumn.OrderersDivision].Value) != CommonMotions.cnvInt(cells[(int)DispColumn.OrderersDivision].Value)
+                    || CommonMotions.cnvInt(headerCells[(int)DispColumn.OrderersCode].Value) != CommonMotions.cnvInt(cells[(int)DispColumn.OrderersCode].Value))
+                {
+                    blankIndex = i;
+                    break;
+                }
+            }
+            dgvMaster.Rows.Insert(blankIndex);
+            var row = dgvMaster.Rows[blankIndex];
+            row.ReadOnly = true;
+            row.Cells[(int)DispColumn.OrderersDivision].Value = headerCells[(int)DispColumn.OrderersDivision].Value;
+            row.Cells[(int)DispColumn.OrderersCode].Value = headerCells[(int)DispColumn.OrderersCode].Value;
+            var readOnly = !CanEditDeposit(depositOrderer);
+            row.Cells[(int)DispColumn.DepositDate].ReadOnly = readOnly;
+            row.Cells[(int)DispColumn.DepositAmountCash].ReadOnly = readOnly;
+            row.Cells[(int)DispColumn.DepositAmountBill].ReadOnly = readOnly;
+        }
+
+        /// <summary>
+        /// ボタン制御
+        /// </summary>
+        private void ControlButton()
+        {
+        }
+
+        /// <summary>
+        /// 入金請求先情報を取得する。
+        /// </summary>
+        /// <param name="index"></param>
+        /// <returns></returns>
+        private DepositOrderer FindDepositOrderer(int index)
+        {
+            var cells = dgvMaster.Rows[index].Cells;
+            var orderersDivision = CommonMotions.cnvInt(cells[(int)DispColumn.OrderersDivision].Value);
+            var orderersCode = CommonMotions.cnvInt(cells[(int)DispColumn.OrderersCode].Value);
+            return FindDepositOrderer(orderersDivision, orderersCode);
+        }
+
+        /// <summary>
+        /// 入金請求先情報を取得する。
+        /// </summary>
+        /// <param name="orderersDivision"></param>
+        /// <param name="orderersCode"></param>
+        /// <returns></returns>
+        private DepositOrderer FindDepositOrderer(int orderersDivision, int orderersCode)
+        {
+            return depositOrderers.Find(dh => !dh.Deleted && dh.OrderersDivision == orderersDivision && dh.OrderersCode == orderersCode);
+        }
+
+        /// <summary>
+        /// 対象の行の請求先キーを取得する。
+        /// </summary>
+        /// <param name="index"></param>
+        /// <returns></returns>
+        private OrderersKey GetOrderersKey(int index)
+        {
+            var cells = dgvMaster.Rows[index].Cells;
+            return new OrderersKey()
+            {
+                OrderersDivision = CommonMotions.cnvInt(cells[(int)DispColumn.OrderersDivision].Value),
+                OrderersCode = CommonMotions.cnvInt(cells[(int)DispColumn.OrderersCode].Value),
+            };
+        }
+        /// <summary>
+        /// ラジオボタン（通年）選択時
+        /// </summary>
+        /// <param name="index"></param>
+        /// <returns></returns>
+        private void radioButton1_CheckedChanged(object sender, EventArgs e)
+        {
+            comboBox1.Enabled = false;
+
+            if (radioButton1.Checked)
+            {
+                DisplayData();
+            }
+        }
+
+        /// <summary>
+        /// ラジオボタン（月指定）選択時
+        /// </summary>
+        /// <param name="index"></param>
+        /// <returns></returns>
+        private void radioButton2_CheckedChanged(object sender, EventArgs e)
+        {
+            comboBox1.Enabled = true;
+        }
+
+        /// <summary>
+        /// 表示条件．営業期設定時
+        /// </summary>
+        /// <param name="index"></param>
+        /// <returns></returns>
+        private void numericUpDown2_ValueChanged(object sender, EventArgs e)
+        {
+            DisplayData();
+
+        }
+
+        /// <summary>
+        /// 表示条件．対象月設定時
+        /// </summary>
+        /// <param name="index"></param>
+        /// <returns></returns>
+        private void comboBox1_SelectedIndexChanged(object sender, EventArgs e)
+        {
+            if (!CommonMotions.cnvString(comboBox1.SelectedItem).Equals("　"))
+            {
+                DisplayData();
+            }
+        }
+
+        /// <summary>
+        /// 表示条件．部署設定時
+        /// </summary>
+        /// <param name="index"></param>
+        /// <returns></returns>
+        private void comboBox2_SelectedIndexChanged(object sender, EventArgs e)
+        {
+            // 一覧再取得
+            DisplayData();
+
+            // 担当者再取得
+            this.listPerson = getPersonList(CommonMotions.cnvInt(comboBox2.SelectedValue));
+
+            comboBox3.SelectedIndexChanged -= new System.EventHandler(this.comboBox3_SelectedIndexChanged);
+
+            comboBox3.DataSource = listPerson;
+            comboBox3.SelectedIndex = 0;
+
+            comboBox3.SelectedIndexChanged += new System.EventHandler(this.comboBox3_SelectedIndexChanged);
+
+
+        }
+
+        /// <summary>
+        /// 表示条件．担当者設定時
+        /// </summary>
+        /// <param name="index"></param>
+        /// <returns></returns>
+        private void comboBox3_SelectedIndexChanged(object sender, EventArgs e)
+        {
+            // 一覧再取得
+            DisplayData();
+
+            // 部署再取得
+            this.listDepartment = getDepartmentList(CommonMotions.cnvInt(comboBox3.SelectedValue));
+
+            comboBox2.SelectedIndexChanged -= new System.EventHandler(this.comboBox2_SelectedIndexChanged);
+
+            comboBox2.DataSource = listDepartment;
+            comboBox2.SelectedIndex = 0;
+
+            comboBox2.SelectedIndexChanged += new System.EventHandler(this.comboBox2_SelectedIndexChanged);
+
+        }
+
+
+
+    }
+}
\ No newline at end of file
Index: branches/src/ProcessManagement/ProcessManagement/Forms/DataEntry/Request/SalesConfirm/FrmSalesConfirm.resx
===================================================================
--- branches/src/ProcessManagement/ProcessManagement/Forms/DataEntry/Request/SalesConfirm/FrmSalesConfirm.resx	(nonexistent)
+++ branches/src/ProcessManagement/ProcessManagement/Forms/DataEntry/Request/SalesConfirm/FrmSalesConfirm.resx	(revision 60)
@@ -0,0 +1,351 @@
+﻿<?xml version="1.0" encoding="utf-8"?>
+<root>
+  <!-- 
+    Microsoft ResX Schema 
+    
+    Version 2.0
+    
+    The primary goals of this format is to allow a simple XML format 
+    that is mostly human readable. The generation and parsing of the 
+    various data types are done through the TypeConverter classes 
+    associated with the data types.
+    
+    Example:
+    
+    ... ado.net/XML headers & schema ...
+    <resheader name="resmimetype">text/microsoft-resx</resheader>
+    <resheader name="version">2.0</resheader>
+    <resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
+    <resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
+    <data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
+    <data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
+    <data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
+        <value>[base64 mime encoded serialized .NET Framework object]</value>
+    </data>
+    <data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
+        <value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
+        <comment>This is a comment</comment>
+    </data>
+                
+    There are any number of "resheader" rows that contain simple 
+    name/value pairs.
+    
+    Each data row contains a name, and value. The row also contains a 
+    type or mimetype. Type corresponds to a .NET class that support 
+    text/value conversion through the TypeConverter architecture. 
+    Classes that don't support this are serialized and stored with the 
+    mimetype set.
+    
+    The mimetype is used for serialized objects, and tells the 
+    ResXResourceReader how to depersist the object. This is currently not 
+    extensible. For a given mimetype the value must be set accordingly:
+    
+    Note - application/x-microsoft.net.object.binary.base64 is the format 
+    that the ResXResourceWriter will generate, however the reader can 
+    read any of the formats listed below.
+    
+    mimetype: application/x-microsoft.net.object.binary.base64
+    value   : The object must be serialized with 
+            : System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
+            : and then encoded with base64 encoding.
+    
+    mimetype: application/x-microsoft.net.object.soap.base64
+    value   : The object must be serialized with 
+            : System.Runtime.Serialization.Formatters.Soap.SoapFormatter
+            : and then encoded with base64 encoding.
+
+    mimetype: application/x-microsoft.net.object.bytearray.base64
+    value   : The object must be serialized into a byte array 
+            : using a System.ComponentModel.TypeConverter
+            : and then encoded with base64 encoding.
+    -->
+  <xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
+    <xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
+    <xsd:element name="root" msdata:IsDataSet="true">
+      <xsd:complexType>
+        <xsd:choice maxOccurs="unbounded">
+          <xsd:element name="metadata">
+            <xsd:complexType>
+              <xsd:sequence>
+                <xsd:element name="value" type="xsd:string" minOccurs="0" />
+              </xsd:sequence>
+              <xsd:attribute name="name" use="required" type="xsd:string" />
+              <xsd:attribute name="type" type="xsd:string" />
+              <xsd:attribute name="mimetype" type="xsd:string" />
+              <xsd:attribute ref="xml:space" />
+            </xsd:complexType>
+          </xsd:element>
+          <xsd:element name="assembly">
+            <xsd:complexType>
+              <xsd:attribute name="alias" type="xsd:string" />
+              <xsd:attribute name="name" type="xsd:string" />
+            </xsd:complexType>
+          </xsd:element>
+          <xsd:element name="data">
+            <xsd:complexType>
+              <xsd:sequence>
+                <xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
+                <xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
+              </xsd:sequence>
+              <xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
+              <xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
+              <xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
+              <xsd:attribute ref="xml:space" />
+            </xsd:complexType>
+          </xsd:element>
+          <xsd:element name="resheader">
+            <xsd:complexType>
+              <xsd:sequence>
+                <xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
+              </xsd:sequence>
+              <xsd:attribute name="name" type="xsd:string" use="required" />
+            </xsd:complexType>
+          </xsd:element>
+        </xsd:choice>
+      </xsd:complexType>
+    </xsd:element>
+  </xsd:schema>
+  <resheader name="resmimetype">
+    <value>text/microsoft-resx</value>
+  </resheader>
+  <resheader name="version">
+    <value>2.0</value>
+  </resheader>
+  <resheader name="reader">
+    <value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
+  </resheader>
+  <resheader name="writer">
+    <value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
+  </resheader>
+  <metadata name="EditStatus.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="No.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="OrderersDivision.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="OrderersCode.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="SeqNo.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="LineCount.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="OrderersName.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="DepositDate.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="DepositAmountCash.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="DepositAmountBill.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="RequestNo.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="OrderNo.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="ConstructionName.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="ConstructionName_Raw.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="PaymentSchedule.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="BillCreationDate.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="BillPrice.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="TaxPrice.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="DepositAmount.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="DiscountAmount.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="CnstrPrice.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="Fees.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="OtherAdjustments.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="CarryAmount.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="PersonName.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="PersonCode.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="PersonDate.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="ApprovalName_1.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="ApprovalCode_1.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="ApprovalAuthority_1.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="ApprovalDate_1.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="ApprovalOrder_1.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="ApprovalName_2.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="ApprovalCode_2.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="ApprovalAuthority_2.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="ApprovalDate_2.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="ApprovalOrder_2.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="ApprovalName_3.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="ApprovalCode_3.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="ApprovalAuthority_3.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="ApprovalDate_3.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="ApprovalOrder_3.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="ApprovalName_4.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="ApprovalCode_4.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="ApprovalAuthority_4.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="ApprovalDate_4.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="ApprovalOrder_4.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="ApprovalName_5.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="ApprovalCode_5.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="ApprovalAuthority_5.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="ApprovalDate_5.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="ApprovalOrder_5.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="ApprovalName_6.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="ApprovalCode_6.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="ApprovalAuthority_6.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="ApprovalDate_6.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="ApprovalOrder_6.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="ApprovalName_7.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="ApprovalCode_7.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="ApprovalAuthority_7.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="ApprovalDate_7.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="ApprovalOrder_7.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="ApprovalName_8.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="ApprovalCode_8.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="ApprovalAuthority_8.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="ApprovalDate_8.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="ApprovalOrder_8.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="ApprovalName_9.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="ApprovalCode_9.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="ApprovalAuthority_9.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="ApprovalDate_9.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="ApprovalOrder_9.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="ApprovalName_10.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="ApprovalCode_10.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="ApprovalAuthority_10.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="ApprovalDate_10.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+  <metadata name="ApprovalOrder_10.UserAddedColumn" type="System.Boolean, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
+    <value>True</value>
+  </metadata>
+</root>
\ No newline at end of file
Index: branches/src/ProcessManagement/ProcessManagement/Forms/DataEntry/Request/SelectPayment/FrmSelectPayment.Designer.cs
===================================================================
--- branches/src/ProcessManagement/ProcessManagement/Forms/DataEntry/Request/SelectPayment/FrmSelectPayment.Designer.cs	(revision 59)
+++ branches/src/ProcessManagement/ProcessManagement/Forms/DataEntry/Request/SelectPayment/FrmSelectPayment.Designer.cs	(revision 60)
@@ -59,6 +59,11 @@
             this.comboBox1 = new System.Windows.Forms.ComboBox();
             this.label2 = new System.Windows.Forms.Label();
             this.dgvMaster = new System.Windows.Forms.DataGridView();
+            this.btnAddCmp = new System.Windows.Forms.Button();
+            this.btnDelCmp = new System.Windows.Forms.Button();
+            this.btnAddFld = new System.Windows.Forms.Button();
+            this.Registration = new System.Windows.Forms.Button();
+            this.btnEnd = new System.Windows.Forms.Button();
             this.EditStatus = new System.Windows.Forms.DataGridViewTextBoxColumn();
             this.No = new System.Windows.Forms.DataGridViewTextBoxColumn();
             this.OrderersDivision = new System.Windows.Forms.DataGridViewTextBoxColumn();
@@ -136,11 +141,6 @@
             this.ApprovalAuthority_10 = new System.Windows.Forms.DataGridViewTextBoxColumn();
             this.ApprovalDate_10 = new System.Windows.Forms.DataGridViewTextBoxColumn();
             this.ApprovalOrder_10 = new System.Windows.Forms.DataGridViewTextBoxColumn();
-            this.btnAddCmp = new System.Windows.Forms.Button();
-            this.btnDelCmp = new System.Windows.Forms.Button();
-            this.btnAddFld = new System.Windows.Forms.Button();
-            this.Registration = new System.Windows.Forms.Button();
-            this.btnEnd = new System.Windows.Forms.Button();
             this.panel1.SuspendLayout();
             ((System.ComponentModel.ISupportInitialize)(this.dgvMaster)).BeginInit();
             this.SuspendLayout();
@@ -311,6 +311,76 @@
             this.dgvMaster.Size = new System.Drawing.Size(1399, 474);
             this.dgvMaster.TabIndex = 7;
             // 
+            // btnAddCmp
+            // 
+            this.btnAddCmp.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left)));
+            this.btnAddCmp.BackColor = System.Drawing.Color.Orange;
+            this.btnAddCmp.Font = new System.Drawing.Font("ＭＳ 明朝", 12F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(128)));
+            this.btnAddCmp.ForeColor = System.Drawing.Color.Black;
+            this.btnAddCmp.Location = new System.Drawing.Point(8, 597);
+            this.btnAddCmp.Name = "btnAddCmp";
+            this.btnAddCmp.Size = new System.Drawing.Size(120, 30);
+            this.btnAddCmp.TabIndex = 15;
+            this.btnAddCmp.Text = "発注者追加";
+            this.btnAddCmp.UseVisualStyleBackColor = false;
+            this.btnAddCmp.Click += new System.EventHandler(this.btnAddCmp_Click);
+            // 
+            // btnDelCmp
+            // 
+            this.btnDelCmp.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left)));
+            this.btnDelCmp.BackColor = System.Drawing.Color.Red;
+            this.btnDelCmp.Font = new System.Drawing.Font("ＭＳ 明朝", 12F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(128)));
+            this.btnDelCmp.ForeColor = System.Drawing.Color.Black;
+            this.btnDelCmp.Location = new System.Drawing.Point(134, 597);
+            this.btnDelCmp.Name = "btnDelCmp";
+            this.btnDelCmp.Size = new System.Drawing.Size(120, 30);
+            this.btnDelCmp.TabIndex = 16;
+            this.btnDelCmp.Text = "発注者削除";
+            this.btnDelCmp.UseVisualStyleBackColor = false;
+            this.btnDelCmp.Click += new System.EventHandler(this.btnDelCmp_Click);
+            // 
+            // btnAddFld
+            // 
+            this.btnAddFld.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left)));
+            this.btnAddFld.BackColor = System.Drawing.Color.Aquamarine;
+            this.btnAddFld.Font = new System.Drawing.Font("ＭＳ 明朝", 12F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(128)));
+            this.btnAddFld.ForeColor = System.Drawing.Color.Black;
+            this.btnAddFld.Location = new System.Drawing.Point(260, 597);
+            this.btnAddFld.Name = "btnAddFld";
+            this.btnAddFld.Size = new System.Drawing.Size(120, 30);
+            this.btnAddFld.TabIndex = 17;
+            this.btnAddFld.Text = "現場追加";
+            this.btnAddFld.UseVisualStyleBackColor = false;
+            this.btnAddFld.Click += new System.EventHandler(this.btnAddFld_Click);
+            // 
+            // Registration
+            // 
+            this.Registration.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right)));
+            this.Registration.BackColor = System.Drawing.Color.GreenYellow;
+            this.Registration.Font = new System.Drawing.Font("ＭＳ 明朝", 12F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(128)));
+            this.Registration.ForeColor = System.Drawing.Color.Black;
+            this.Registration.Location = new System.Drawing.Point(1161, 597);
+            this.Registration.Name = "Registration";
+            this.Registration.Size = new System.Drawing.Size(120, 30);
+            this.Registration.TabIndex = 19;
+            this.Registration.Text = "登　録";
+            this.Registration.UseVisualStyleBackColor = false;
+            this.Registration.Click += new System.EventHandler(this.Registration_Click);
+            // 
+            // btnEnd
+            // 
+            this.btnEnd.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right)));
+            this.btnEnd.BackColor = System.Drawing.Color.Magenta;
+            this.btnEnd.Font = new System.Drawing.Font("ＭＳ 明朝", 12F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(128)));
+            this.btnEnd.ForeColor = System.Drawing.Color.Black;
+            this.btnEnd.Location = new System.Drawing.Point(1287, 597);
+            this.btnEnd.Name = "btnEnd";
+            this.btnEnd.Size = new System.Drawing.Size(120, 30);
+            this.btnEnd.TabIndex = 20;
+            this.btnEnd.Text = "終　了";
+            this.btnEnd.UseVisualStyleBackColor = false;
+            this.btnEnd.Click += new System.EventHandler(this.btnEnd_Click);
+            // 
             // EditStatus
             // 
             this.EditStatus.HeaderText = "■編集状態";
@@ -414,6 +484,7 @@
             this.PaymentSchedule.HeaderText = "入金\r\n予定日";
             this.PaymentSchedule.Name = "PaymentSchedule";
             this.PaymentSchedule.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable;
+            this.PaymentSchedule.Visible = false;
             this.PaymentSchedule.Width = 120;
             // 
             // BillCreationDate
@@ -858,76 +929,6 @@
             this.ApprovalOrder_10.Name = "ApprovalOrder_10";
             this.ApprovalOrder_10.Visible = false;
             // 
-            // btnAddCmp
-            // 
-            this.btnAddCmp.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left)));
-            this.btnAddCmp.BackColor = System.Drawing.Color.Orange;
-            this.btnAddCmp.Font = new System.Drawing.Font("ＭＳ 明朝", 12F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(128)));
-            this.btnAddCmp.ForeColor = System.Drawing.Color.Black;
-            this.btnAddCmp.Location = new System.Drawing.Point(8, 597);
-            this.btnAddCmp.Name = "btnAddCmp";
-            this.btnAddCmp.Size = new System.Drawing.Size(120, 30);
-            this.btnAddCmp.TabIndex = 15;
-            this.btnAddCmp.Text = "発注者追加";
-            this.btnAddCmp.UseVisualStyleBackColor = false;
-            this.btnAddCmp.Click += new System.EventHandler(this.btnAddCmp_Click);
-            // 
-            // btnDelCmp
-            // 
-            this.btnDelCmp.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left)));
-            this.btnDelCmp.BackColor = System.Drawing.Color.Red;
-            this.btnDelCmp.Font = new System.Drawing.Font("ＭＳ 明朝", 12F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(128)));
-            this.btnDelCmp.ForeColor = System.Drawing.Color.Black;
-            this.btnDelCmp.Location = new System.Drawing.Point(134, 597);
-            this.btnDelCmp.Name = "btnDelCmp";
-            this.btnDelCmp.Size = new System.Drawing.Size(120, 30);
-            this.btnDelCmp.TabIndex = 16;
-            this.btnDelCmp.Text = "発注者削除";
-            this.btnDelCmp.UseVisualStyleBackColor = false;
-            this.btnDelCmp.Click += new System.EventHandler(this.btnDelCmp_Click);
-            // 
-            // btnAddFld
-            // 
-            this.btnAddFld.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left)));
-            this.btnAddFld.BackColor = System.Drawing.Color.Aquamarine;
-            this.btnAddFld.Font = new System.Drawing.Font("ＭＳ 明朝", 12F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(128)));
-            this.btnAddFld.ForeColor = System.Drawing.Color.Black;
-            this.btnAddFld.Location = new System.Drawing.Point(260, 597);
-            this.btnAddFld.Name = "btnAddFld";
-            this.btnAddFld.Size = new System.Drawing.Size(120, 30);
-            this.btnAddFld.TabIndex = 17;
-            this.btnAddFld.Text = "現場追加";
-            this.btnAddFld.UseVisualStyleBackColor = false;
-            this.btnAddFld.Click += new System.EventHandler(this.btnAddFld_Click);
-            // 
-            // Registration
-            // 
-            this.Registration.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right)));
-            this.Registration.BackColor = System.Drawing.Color.GreenYellow;
-            this.Registration.Font = new System.Drawing.Font("ＭＳ 明朝", 12F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(128)));
-            this.Registration.ForeColor = System.Drawing.Color.Black;
-            this.Registration.Location = new System.Drawing.Point(1161, 597);
-            this.Registration.Name = "Registration";
-            this.Registration.Size = new System.Drawing.Size(120, 30);
-            this.Registration.TabIndex = 19;
-            this.Registration.Text = "登　録";
-            this.Registration.UseVisualStyleBackColor = false;
-            this.Registration.Click += new System.EventHandler(this.Registration_Click);
-            // 
-            // btnEnd
-            // 
-            this.btnEnd.Anchor = ((System.Windows.Forms.AnchorStyles)((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Right)));
-            this.btnEnd.BackColor = System.Drawing.Color.Magenta;
-            this.btnEnd.Font = new System.Drawing.Font("ＭＳ 明朝", 12F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(128)));
-            this.btnEnd.ForeColor = System.Drawing.Color.Black;
-            this.btnEnd.Location = new System.Drawing.Point(1287, 597);
-            this.btnEnd.Name = "btnEnd";
-            this.btnEnd.Size = new System.Drawing.Size(120, 30);
-            this.btnEnd.TabIndex = 20;
-            this.btnEnd.Text = "終　了";
-            this.btnEnd.UseVisualStyleBackColor = false;
-            this.btnEnd.Click += new System.EventHandler(this.btnEnd_Click);
-            // 
             // FrmSelectPayment
             // 
             this.AutoScaleDimensions = new System.Drawing.SizeF(9F, 15F);
Index: branches/src/ProcessManagement/ProcessManagement/Forms/DataEntry/Request/SelectPayment/FrmSelectPayment.cs
===================================================================
--- branches/src/ProcessManagement/ProcessManagement/Forms/DataEntry/Request/SelectPayment/FrmSelectPayment.cs	(revision 59)
+++ branches/src/ProcessManagement/ProcessManagement/Forms/DataEntry/Request/SelectPayment/FrmSelectPayment.cs	(revision 60)
@@ -37,32 +37,6 @@
         private static readonly log4net.ILog logger = log4net.LogManager.GetLogger(System.Reflection.MethodBase.GetCurrentMethod().DeclaringType);
 
         /// <summary>
-        /// 利用ユーザータイプ
-        /// </summary>
-        public enum UserType
-        {
-            /// <summary>特別権限</summary>
-            PresidentAuthority,
-            /// <summary>統括者権限</summary>
-            SupervisorAuthority,
-            /// <summary>所属長権限</summary>
-            SuperiorAuthority,
-            /// <summary>一般権限</summary>
-            Staff,
-        }
-
-        /// <summary>
-        /// 保護区分
-        /// </summary>
-        public enum SecRangeType
-        {
-            AllDepartment = 1,
-            MultiDepartment = 2,
-            OneDepartment = 3,
-            InCharge = 4,
-        }
-
-        /// <summary>
         /// 承認状態
         /// </summary>
         public enum ApprovalStatus
@@ -261,24 +235,6 @@
         }
 
         /// <summary>
-        /// ユーザ情報
-        /// </summary>
-        private class UserInfo
-        {
-            public UserType m_Type { get; set; }            // 権限
-            public int m_GeneralAffairsFlg { get; set; }    // 総務業務フラグ
-            public SecRangeType m_SecRange { get; set; }    // 保護区分
-            public bool CanEditDeposit
-            {
-                get { return m_GeneralAffairsFlg == 1; }
-            }
-            public bool CanEditDepositDetail
-            {
-                get { return m_GeneralAffairsFlg == 0; }
-            }
-        }
-
-        /// <summary>
         /// 請求先キー
         /// </summary>
         private class OrderersKey
@@ -487,11 +443,11 @@
         private bool m_CloseingProcessOff = false;
 
         // ユーザー情報
-        private UserInfo m_UserInfo = new UserInfo()
+        private ClsSecurityPermission.UserInfo m_UserInfo = new ClsSecurityPermission.UserInfo()
         {
-            m_Type = UserType.Staff,
+            m_Type = CommonDefine.SecurityRankPos.NormalAuthority,
             m_GeneralAffairsFlg = 0,
-            m_SecRange = SecRangeType.InCharge
+            m_SecRange = ClsSecurityPermission.SecRangeType.InCharge
         };
 
         /// <summary>
@@ -532,7 +488,7 @@
                 comboBox1.SelectedIndex = lstDate.IndexOf(now);
 
                 // ユーザ権限設定
-                SetUserType();
+                ClsSecurityPermission.SetUserType(m_UserInfo);
 
                 // ちらつきを抑えるため、ダブルバッファリングを有効にする。
                 dgvMaster.GetType().InvokeMember("DoubleBuffered", BindingFlags.NonPublic | BindingFlags.Instance | BindingFlags.SetProperty,
@@ -758,7 +714,109 @@
             }
         }
 
+        #region 入金情報掲示板データ登録
         /// <summary>
+        /// 入金情報掲示板データ登録
+        /// </summary>
+        /// <returns></returns>
+        private bool MessageBoardEntry(DepositOrderer depositOder)
+        {
+            IOMessageBoardData mbdDB = new IOMessageBoardData();
+            IOMessageBoardTerget mbtDB = new IOMessageBoardTerget();
+            try
+            {
+                mbdDB.connect();
+                mbdDB.beginTran();
+
+                mbtDB.connect();
+                mbtDB.beginTran();
+
+                List<MessageBoardData> list = new List<MessageBoardData>();
+                MessageBoardData data = new MessageBoardData();
+
+                // キーコードセット
+                data.RecordNumber = mbtDB.SelectMaxMessageBoardTergetKeyCount("", false) + 1;
+                data.BranchNumber = 0;
+                string strWhere = mbdDB.CreatePrimarykeyString(data.RecordNumber, data.BranchNumber);
+
+                // 送信者セット
+                data.FromCode = CommonMotions.LoginUserData.PersonCode;
+                data.FromName = CommonMotions.LoginUserData.PersonName;
+
+                data.MessageTitle = string.Format("入金確認（{0}）", depositOder.OrderersName);
+                data.MessageContent = string.Format("{0}様より入金がありました。\r\n", depositOder.OrderersName);
+                data.MessageContent += "入金内容の確認をよろしくお願いします。";
+
+                // リンク情報
+                data.LinkType = 0;
+                data.LinkMessage = "";
+                data.LinkCode = "";
+
+                // メッセージ色セット
+                data.MessageColor = String.Format("0x{0:X2}{1:X2}{2:X2}", Color.White.R
+                                                                        , Color.White.G
+                                                                        , Color.White.B);
+                data.BackColor = String.Format("0x{0:X2}{1:X2}{2:X2}", Color.Green.R
+                                                                        , Color.Green.G
+                                                                        , Color.Green.B);
+                data.WritingDate = DateTime.Now;
+                data.PersonCode = CommonMotions.LoginUserData.PersonCode;
+                data.ShareFlag = 1;
+
+                list.Add(data);
+                // データ登録
+                if (!mbdDB.InsertAction(list, false))
+                {
+                    MessageBox.Show("登録に失敗しました。", "登録エラー", MessageBoxButtons.OK, MessageBoxIcon.Error);
+                    mbdDB.rollback();
+                    mbtDB.rollback();
+                    return false;
+                }
+
+                string strMBT = mbtDB.CreatePrimarykeyString(data.RecordNumber, data.BranchNumber);
+                mbtDB.DeleteAction(strMBT, false);
+                // 対象者書込み
+                int icnt = 0;
+
+                List<MessageBoardTerget> terList = new List<MessageBoardTerget>();
+                MessageBoardTerget wrkTer = new MessageBoardTerget();
+
+                // キーコードセット
+                wrkTer.RecordNumber = data.RecordNumber;
+                wrkTer.BranchNumber = data.BranchNumber;
+                wrkTer.SeqNum = ++icnt;
+                wrkTer.ToCode = 99999999;
+                wrkTer.ToName = "全　　員";
+
+                terList.Add(wrkTer);
+
+                // データ登録
+                if (!mbtDB.InsertAction(terList, false))
+                {
+                    mbdDB.rollback();
+                    mbtDB.rollback();
+                    return false;
+                }
+
+                mbdDB.commit();
+                mbtDB.commit();
+
+                return true;
+            }
+            catch (Exception ex)
+            {
+                logger.ErrorFormat("システムエラー：{0}：{1}", CommonMotions.GetMethodName(), ex.Message);
+                return false;
+            }
+            finally
+            {
+                mbdDB.close(); mbdDB = null;
+                mbtDB.close(); mbtDB = null;
+            }
+        }
+        #endregion
+
+        /// <summary>
         /// 登録ボタンクリック時のイベント
         /// </summary>
         /// <param name="sender"></param>
@@ -771,7 +829,7 @@
             var ioDepositData = new IODepositData();
             var ioDepositDataDetail = new IODepositDataDetail();
             var ioDepositApprovalInfo = new IODepositApprovalInfo();
-            var ioRequestTotalData = new IORequestTotalData();
+            var ioRequestHead = new IORequestHead();
             try
             {
                 ResetTargetDate();
@@ -809,8 +867,8 @@
                 ioDepositDataDetail.beginTran();
                 ioDepositApprovalInfo.connect();
                 ioDepositApprovalInfo.beginTran();
-                ioRequestTotalData.connect();
-                ioRequestTotalData.beginTran();
+                ioRequestHead.connect();
+                ioRequestHead.beginTran();
 
                 // 登録処理
                 foreach (var depositOrderer in depositOrderers)
@@ -827,6 +885,7 @@
                                 throw new Exception();
                             continue;
                         }
+
                         var depositData = new DepositData()
                         {
                             OrderersDivision = depositOrderer.OrderersDivision,
@@ -833,15 +892,28 @@
                             OrderersCode = depositOrderer.OrderersCode,
                             TargetDate = m_Select_TargetDate.ToString(),
                             SeqNo = deposit.SeqNo,
+                            BusinessPeriod = CommonMotions.SystemMasterData.BusinessPeriod,
                             DepositDate = DateTime.Parse(deposit.DepositDate),
+                            DepositAmount = deposit.DepositAmountCash.GetValueOrDefault(0) + deposit.DepositAmountBill.GetValueOrDefault(0), 
                             DepositAmountCash = deposit.DepositAmountCash.GetValueOrDefault(0),
                             DepositAmountBill = deposit.DepositAmountBill.GetValueOrDefault(0),
                         };
+
                         // 登録処理
                         if (deposit.Added)
                         {
                             if (!ioDepositData.InsertAction(depositData))
+                            {
                                 throw new Exception();
+                            }
+                            else
+                            {
+                                    // 総務担当
+                                    if (m_UserInfo.m_GeneralAffairsFlg == 1)
+                                    {
+                                        MessageBoardEntry(depositOrderer);
+                                    }
+                            }
                         }
                         // 更新処理
                         else if (deposit.Editted)
@@ -868,13 +940,13 @@
                             // 入金明細データを削除した場合は、対応する請求合計データを割当未とする
                             sql = string.Format(" where RequestNo = {0} and OrderNo = {1} ",
                                 depositDetail.RequestNo, depositDetail.OrderNo);
-                            var lstRtd = new List<RequestTotalData>();
-                            if (!ioRequestTotalData.SelectAction(sql, ref lstRtd))
+                            var lstRtd = new List<RequestHead>();
+                            if (!ioRequestHead.SelectAction(sql, ref lstRtd))
                                 throw new Exception();
                             foreach (var rtd in lstRtd)
                             {
-                                rtd.AssignedFlg = false;
-                                if (!ioRequestTotalData.UpdateAction("", rtd))
+                                rtd.AssignedFlg = 0;
+                                if (!ioRequestHead.UpdateAction("", rtd))
                                     throw new Exception();
                             }
                             continue;
@@ -910,13 +982,13 @@
                             // 入金明細データを追加した場合は、対応する請求合計データを割当済みとする
                             var sql = string.Format(" where RequestNo = {0} and OrderNo = {1} ",
                                 depositDataDetail.RequestNo, depositDataDetail.OrderNo);
-                            var lstRtd = new List<RequestTotalData>();
-                            if (!ioRequestTotalData.SelectAction(sql, ref lstRtd))
+                            var lstRtd = new List<RequestHead>();
+                            if (!ioRequestHead.SelectAction(sql, ref lstRtd))
                                 throw new Exception();
                             foreach (var rtd in lstRtd)
                             {
-                                rtd.AssignedFlg = true;
-                                if (!ioRequestTotalData.UpdateAction("", rtd))
+                                rtd.AssignedFlg = 1;
+                                if (!ioRequestHead.UpdateAction("", rtd))
                                     throw new Exception();
                             }
                             // 入金確認承認データの登録
@@ -986,7 +1058,7 @@
                 ioDepositData.commit();
                 ioDepositDataDetail.commit();
                 ioDepositApprovalInfo.commit();
-                ioRequestTotalData.commit();
+                ioRequestHead.commit();
 
                 // グリッド表示
                 DisplayData();
@@ -996,7 +1068,7 @@
                 ioDepositData.rollback();
                 ioDepositDataDetail.rollback();
                 ioDepositApprovalInfo.rollback();
-                ioRequestTotalData.rollback();
+                ioRequestHead.rollback();
                 logger.ErrorFormat("システムエラー：{0}：{1}", CommonMotions.GetMethodName(), ex.Message);
             }
             finally
@@ -1007,7 +1079,7 @@
                 ioDepositData.close();
                 ioDepositDataDetail.close();
                 ioDepositApprovalInfo.close();
-                ioRequestTotalData.close();
+                ioRequestHead.close();
             }
         }
 
@@ -1647,81 +1719,59 @@
             try
             {
                 var sql = new StringBuilder();
-                sql.Append("select ");
-                sql.Append("DepD.OrderersDivision, ");
-                sql.Append("DepD.OrderersCode, ");
-                sql.Append("DepD.TargetDate, ");
-                sql.Append("DepD.SeqNo, ");
-
-                sql.Append("null as DepositDate, ");
-                sql.Append("null, ");
-                sql.Append("null, ");
-                sql.Append("null, ");
-                sql.Append("null, ");
-                sql.Append("null, ");
-                sql.Append("null, ");
-
-                sql.Append("DepD.LineCount, ");
-                sql.Append("ifnull(DepD.RequestNo, 0) as RequestNo, ");
-                sql.Append("ifnull(DepD.OrderNo, 0) as OrderNo, ");
-                sql.Append("DepD.DepositAmount, ");
-                sql.Append("ifnull(DepD.DiscountAmount, 0) as DiscountAmount, ");
-                sql.Append("ifnull(DepD.CnstrPrice, 0) as CnstrPrice, ");
-                sql.Append("ifnull(DepD.Fees, 0) as Fees, ");
-                sql.Append("ifnull(DepD.OtherAdjustments, 0) as OtherAdjustments, ");
-                sql.Append("ifnull(DepD.CarryAmount, 0) as CarryAmount, ");
-                sql.Append("ifnull(DepD.ApprovalPersonCode, 0) as ApprovalPersonCode, ");
-                sql.Append("ifnull(DepD.ApprovalDate, 0) as ApprovalDate, ");
-                sql.Append("DepD.ApprovalEndFlg, ");
-                sql.Append("PicM.SealPrintName, ");
-                sql.Append("PicM2.DepartmentCode, ");
-                sql.Append("DATE_FORMAT(ReqT.BillCreationDate, '%Y/%m/%d') as BillCreationDate, ");
-                sql.Append("ReqT.BillPrice, ");
-                sql.Append("ReqT.TaxPrice, ");
-                sql.Append("Cbi.ConstructionCode, ");
-                sql.Append("Cbi.ConstructionPersonCode, ");
-                sql.Append("Cbi.ConstrSubPersonCode, ");
-                sql.Append("Cbi.ConstructionInstructor, ");
-                sql.Append("CbiD.DetailNo, ");
-                sql.Append("CbiD.DetailString ");
-                sql.Append("from DepositDataDetail DepD ");
-                sql.Append("left outer join PersonInChargeMaster as PicM on PicM.PersonCode = DepD.ApprovalPersonCode ");
-                sql.Append("left outer join RequestTotalData as ReqT on ReqT.RequestNo = DepD.RequestNo and ReqT.OrderNo = DepD.OrderNo ");
-                sql.Append("left outer join ConstructionBaseInfo as Cbi on Cbi.ConstructionCode = ReqT.RequestNo ");
-                sql.Append("left outer join ConstructionBaseInfoDetail as CbiD on CbiD.ConstructionCode = Cbi.ConstructionCode and CbiD.DetailNo = 2 ");
-                sql.Append("left outer join ConstructionBaseInfo as Cbi2 on Cbi2.ConstructionCode = Cbi.ConstructionCode ");
-                sql.Append("left outer join PersonInChargeMaster as PicM2 on PicM2.PersonCode = Cbi2.ConstructionPersonCode ");
-                sql.Append("left outer join ApprovalMaster as Am on Am.DepartmentCode = PicM2.DepartmentCode and Am.ApprovalCode = 3 and Am.ApprovalAuthority = 1 ");
-                sql.AppendFormat("where DepD.OrderersDivision = {0} and DepD.OrderersCode = {1} and DepD.TargetDate = {2} ", orderersDivision, orderersCode, m_Select_TargetDate);
-                sql.Append("group by ");
-                sql.Append("DepD.OrderersDivision, ");
-                sql.Append("DepD.OrderersCode, ");
-                sql.Append("DepD.TargetDate, ");
-                sql.Append("DepD.SeqNo, ");
-                sql.Append("DepD.LineCount, ");
-                sql.Append("DepD.RequestNo, ");
-                sql.Append("DepD.OrderNo, ");
-                sql.Append("DepD.DepositAmount, ");
-                sql.Append("DepD.DiscountAmount, ");
-                sql.Append("DepD.CnstrPrice, ");
-                sql.Append("DepD.Fees, ");
-                sql.Append("DepD.OtherAdjustments, ");
-                sql.Append("DepD.CarryAmount, ");
-                sql.Append("DepD.ApprovalPersonCode, ");
-                sql.Append("DepD.ApprovalDate, ");
-                sql.Append("DepD.ApprovalEndFlg, ");
-                sql.Append("PicM.SealPrintName, ");
-                sql.Append("PicM2.DepartmentCode, ");
-                sql.Append("ReqT.BillCreationDate, ");
-                sql.Append("ReqT.BillPrice, ");
-                sql.Append("ReqT.TaxPrice, ");
-                sql.Append("Cbi.ConstructionCode, ");
-                sql.Append("Cbi.ConstructionPersonCode, ");
-                sql.Append("Cbi.ConstrSubPersonCode, ");
-                sql.Append("Cbi.ConstructionInstructor, ");
-                sql.Append("CbiD.DetailNo, ");
-                sql.Append("CbiD.DetailString ");
-                sql.Append("order by DepD.OrderersDivision, DepD.OrderersCode, DepD.SeqNo, DepD.LineCount, DepD.RequestNo, DepD.OrderNo ");
+                sql.Append("SELECT");
+                sql.Append(" DepD.OrderersDivision");
+                sql.Append(" ,DepD.OrderersCode");
+                sql.Append(" ,DepD.TargetDate");
+                sql.Append(" ,DepD.SeqNo");
+                sql.Append(" ,null as DepositDate");
+                sql.Append(" ,null");
+                sql.Append(" ,null");
+                sql.Append(" ,null");
+                sql.Append(" ,null");
+                sql.Append(" ,null");
+                sql.Append(" ,null");
+                sql.Append(" ,DepD.LineCount");
+                sql.Append(" ,ifnull(DepD.RequestNo, 0) as RequestNo");
+                sql.Append(" ,0 as OrderNo");
+                sql.Append(" ,DepD.DepositAmount");
+                sql.Append(" ,ifnull(DepD.DiscountAmount, 0) as DiscountAmount");
+                sql.Append(" ,ifnull(DepD.CnstrPrice, 0) as CnstrPrice");
+                sql.Append(" ,ifnull(DepD.Fees, 0) as Fees");
+                sql.Append(" ,ifnull(DepD.OtherAdjustments, 0) as OtherAdjustments");
+                sql.Append(" ,ifnull(DepD.CarryAmount, 0) as CarryAmount");
+                sql.Append(" ,ifnull(DepD.ApprovalPersonCode, 0) as ApprovalPersonCode");
+                sql.Append(" ,ifnull(DepD.ApprovalDate, 0) as ApprovalDate");
+                sql.Append(" ,DepD.ApprovalEndFlg");
+                sql.Append(" ,PicM.SealPrintName");
+                sql.Append(" ,PicM2.DepartmentCode");
+                sql.Append(" ,DATE_FORMAT(InvD.CretateDate, '%Y/%m/%d') as BillCreationDate");
+                sql.Append(" ,ReqH.RequestAmount as BillPrice");
+                sql.Append(" ,ReqH.TaxAmount as TaxPrice");
+                sql.Append(" ,Cbi.ConstructionCode");
+                sql.Append(" ,Cbi.ConstructionPersonCode");
+                sql.Append(" ,Cbi.ConstrSubPersonCode");
+                sql.Append(" ,Cbi.ConstructionInstructor");
+                sql.Append(" ,0");
+                sql.Append(" ,ReqH.ReqConstructionName");
+                sql.Append(" FROM");
+                sql.Append(" DepositDataDetail DepD");
+                sql.Append(" LEFT OUTER JOIN PersonInChargeMaster PicM ON");
+                sql.Append(" DepD.ApprovalPersonCode = PicM.PersonCode");
+                sql.Append(" LEFT OUTER JOIN RequestHead ReqH ON");
+                sql.Append(" DepD.RequestNo = ReqH.RequestNo");
+                sql.Append(" LEFT OUTER JOIN ConstructionBaseInfo Cbi ON");
+                sql.Append(" ReqH.ReqConstructionCode = Cbi.ConstructionCode");
+                sql.Append(" LEFT OUTER JOIN PersonInChargeMaster PicM2 ON");
+                sql.Append(" Cbi.ConstructionPersonCode = PicM2.PersonCode");
+                sql.Append(" LEFT OUTER JOIN InvoiceData InvD ON");
+                sql.Append(" ReqH.InvoiceNo = InvD.InvoiceNo");
+                sql.Append(" WHERE");
+                sql.AppendFormat(" DepD.OrderersDivision = {0}", orderersDivision);
+                sql.AppendFormat(" AND DepD.OrderersCode = {0}", orderersCode);
+                sql.AppendFormat(" AND DepD.TargetDate = {0}", m_Select_TargetDate);
+                sql.Append(" ORDER BY");
+                sql.Append(" DepD.RequestNo");
                 var depDb = new IODepositData();
                 var data = new ArrayList();
                 if (!depDb.ExecuteReader(sql.ToString(), ref data)) return new ArrayList();
@@ -2332,7 +2382,7 @@
             try
             {
                 // 全部署対象
-                if (m_UserInfo.m_SecRange == SecRangeType.AllDepartment)
+                if (m_UserInfo.m_SecRange == ClsSecurityPermission.SecRangeType.AllDepartment)
                 {
                     return true;
                 }
@@ -2347,12 +2397,12 @@
                 sql.AppendFormat("and PdM.PersonCode = {0} ", CommonMotions.LoginUserData.PersonCode);
                 sql.AppendFormat("and PdM.DepartmentCode = {0} ", CommonMotions.LoginUserData.DepartmentCode);
                 // 自部門のみ表示の場合
-                if (m_UserInfo.m_SecRange == SecRangeType.OneDepartment)
+                if (m_UserInfo.m_SecRange == ClsSecurityPermission.SecRangeType.OneDepartment)
                 {
                     sql.Append("and Pdm.AffiliationFlg = 1 ");
                 }
                 // 担当分のみ対象の場合
-                else if (m_UserInfo.m_SecRange == SecRangeType.InCharge)
+                else if (m_UserInfo.m_SecRange == ClsSecurityPermission.SecRangeType.InCharge)
                 {
                     sql.AppendFormat("and (Cbi.ConstructionPersonCode = {0} ", CommonMotions.LoginUserData.PersonCode);
                     sql.AppendFormat("or Cbi.ConstrSubPersonCode = {0} ", CommonMotions.LoginUserData.PersonCode);
@@ -2382,13 +2432,13 @@
             try
             {
                 // 全部署対象
-                if (m_UserInfo.m_SecRange == SecRangeType.AllDepartment)
+                if (m_UserInfo.m_SecRange == ClsSecurityPermission.SecRangeType.AllDepartment)
                 {
                     return true;
                 }
 
                 // 複数部署対象、または自部署のみ対象
-                else if ((m_UserInfo.m_SecRange == SecRangeType.MultiDepartment) || (m_UserInfo.m_SecRange == SecRangeType.OneDepartment))
+                else if ((m_UserInfo.m_SecRange == ClsSecurityPermission.SecRangeType.MultiDepartment) || (m_UserInfo.m_SecRange == ClsSecurityPermission.SecRangeType.OneDepartment))
                 {
                     var ioPdm = new IOMPersonDepartment();
                     var arDataPdm = new ArrayList();
@@ -2396,7 +2446,7 @@
                     sql.AppendLine("select Pdm.DepartmentCode ");
                     sql.AppendLine("from PersonDepartmentMaster as Pdm ");
                     sql.AppendFormat("where Pdm.PersonCode = {0} ", CommonMotions.LoginUserData.PersonCode);
-                    if (m_UserInfo.m_SecRange == SecRangeType.OneDepartment)
+                    if (m_UserInfo.m_SecRange == ClsSecurityPermission.SecRangeType.OneDepartment)
                     {
                         sql.AppendLine("and Pdm.AffiliationFlg = 1 ");
                     }
@@ -2483,7 +2533,7 @@
         private bool CanEditDeposit(DepositOrderer depositOrderer)
         {
             // 担当者の場合
-            if (m_UserInfo.m_Type == UserType.Staff)
+            if (m_UserInfo.m_Type == CommonDefine.SecurityRankPos.NormalAuthority)
             {
                 // 承認済みなら編集不可
                 if (depositOrderer.HasApprovedByApprover)
@@ -2490,13 +2540,13 @@
                     return false;
             }
             // 所属長、統括者の場合
-            else if (m_UserInfo.m_Type == UserType.SuperiorAuthority || m_UserInfo.m_Type == UserType.SupervisorAuthority)
+            else if (m_UserInfo.m_Type == CommonDefine.SecurityRankPos.LimitedAuthority || m_UserInfo.m_Type == CommonDefine.SecurityRankPos.FreeAuthority)
             {
                 if (depositOrderer.HasApprovedByLastApprover)
                     return false;
             }
             // 特別権限の場合
-            else if (m_UserInfo.m_Type == UserType.PresidentAuthority)
+            else if (m_UserInfo.m_Type == CommonDefine.SecurityRankPos.SpecialAuthority)
             {
                 if (depositOrderer.HasApprovedByLastApprover)
                     return false;
@@ -2507,7 +2557,7 @@
         private bool CanEditDepositDetail(DepositDetail depositDetail)
         {
             // 担当者の場合
-            if (m_UserInfo.m_Type == UserType.Staff)
+            if (m_UserInfo.m_Type == CommonDefine.SecurityRankPos.NormalAuthority)
             {
                 // 承認済みなら編集不可
                 if (depositDetail.IsApprovedByStaff || depositDetail.IsApprovedByApprover)
@@ -2514,7 +2564,7 @@
                     return false;
             }
             // 所属長、統括者の場合
-            else if (m_UserInfo.m_Type == UserType.SuperiorAuthority || m_UserInfo.m_Type == UserType.SupervisorAuthority)
+            else if (m_UserInfo.m_Type == CommonDefine.SecurityRankPos.LimitedAuthority || m_UserInfo.m_Type == CommonDefine.SecurityRankPos.FreeAuthority)
             {
                 // 上位の承認者でなければ編集不可
                 if (!IsUpperLevelApprover(depositDetail))
@@ -2521,7 +2571,7 @@
                     return false;
             }
             // 特別権限の場合
-            else if (m_UserInfo.m_Type == UserType.PresidentAuthority)
+            else if (m_UserInfo.m_Type == CommonDefine.SecurityRankPos.SpecialAuthority)
             {
                 if (depositDetail.IsApprovedByLastApprover)
                     return false;
@@ -2567,63 +2617,6 @@
             row.Cells[(int)DispColumn.DepositAmountCash].ReadOnly = readOnly;
             row.Cells[(int)DispColumn.DepositAmountBill].ReadOnly = readOnly;
         }
-
-        /// <summary>
-        /// ユーザタイプ判定
-        /// </summary>
-        private void SetUserType()
-        {
-            IOMSecurity IoSm = new IOMSecurity();
-            ArrayList arDataSm = new ArrayList();
-            StringBuilder sql = new StringBuilder();
-
-            try
-            {
-                // システム管理者・特別権限
-                if (CommonMotions.LoginUserData.SecurityManagement == CommonDefine.AdminSecurityManagement
-                 || CommonMotions.LoginUserData.SecurityManagement == CommonDefine.SystemManageDiv[(int)CommonDefine.SysManaDivNo.PresidentAuthority].Key)
-                {
-                    // 特別権限
-                    m_UserInfo.m_Type = UserType.PresidentAuthority;
-                }
-                // 統括者権限
-                else if (CommonMotions.LoginUserData.SecurityManagement == CommonDefine.SystemManageDiv[(int)CommonDefine.SysManaDivNo.SupervisorAuthority].Key)
-                {
-                    // 統括者権限
-                    m_UserInfo.m_Type = UserType.SupervisorAuthority;
-
-                }
-                // 所属長権限
-                else if (CommonMotions.LoginUserData.SecurityManagement == CommonDefine.SystemManageDiv[(int)CommonDefine.SysManaDivNo.SuperiorAuthority].Key)
-                {
-                    // 統括者権限
-                    m_UserInfo.m_Type = UserType.SuperiorAuthority;
-
-                }
-                // 一般権限
-                else if (CommonMotions.LoginUserData.SecurityManagement == CommonDefine.SystemManageDiv[(int)CommonDefine.SysManaDivNo.UserAuthority].Key)
-                {
-                    // 一般権限
-                    m_UserInfo.m_Type = UserType.Staff;
-                }
-
-                sql.AppendLine("select Sm.SecRange, Sm.GeneralAffairs ");
-                sql.AppendLine("from SecurityMaster as Sm ");
-                sql.AppendFormat("where Sm.SecCode = {0} ", CommonMotions.LoginUserData.SecCode);
-
-                if (!IoSm.ExecuteReader(sql.ToString(), ref arDataSm)) return;
-
-                foreach (object[] work in arDataSm)
-                {
-                    m_UserInfo.m_SecRange = (SecRangeType)CommonMotions.cnvInt(work[0]);
-                    m_UserInfo.m_GeneralAffairsFlg = CommonMotions.cnvInt(work[1]);
-                }
-            }
-            catch (Exception ex)
-            {
-                logger.ErrorFormat("システムエラー：{0}：{1}", ex.Message);
-            }
-        }
         
         /// <summary>
         /// ボタン制御
Index: branches/src/ProcessManagement/ProcessManagement/Forms/Master/Material/MaterialTypesMaster/FrmMaterialTypesMaster.designer.cs
===================================================================
--- branches/src/ProcessManagement/ProcessManagement/Forms/Master/Material/MaterialTypesMaster/FrmMaterialTypesMaster.designer.cs	(nonexistent)
+++ branches/src/ProcessManagement/ProcessManagement/Forms/Master/Material/MaterialTypesMaster/FrmMaterialTypesMaster.designer.cs	(revision 60)
@@ -0,0 +1,255 @@
+﻿using ProcessManagement.Forms.CustomControls;
+
+namespace ProcessManagement.Forms.Master
+{
+    partial class FrmMaterialTypesMaster
+    {
+        /// <summary>
+        /// 必要なデザイナ変数です。
+        /// </summary>
+        private System.ComponentModel.IContainer components = null;
+
+        /// <summary>
+        /// 使用中のリソースをすべてクリーンアップします。
+        /// </summary>
+        /// <param name="disposing">マネージ リソースが破棄される場合 true、破棄されない場合は false です。</param>
+        protected override void Dispose(bool disposing)
+        {
+            if (disposing && (components != null))
+            {
+                components.Dispose();
+            }
+            base.Dispose(disposing);
+        }
+
+        #region Windows フォーム デザイナで生成されたコード
+
+        /// <summary>
+        /// デザイナ サポートに必要なメソッドです。このメソッドの内容を
+        /// コード エディタで変更しないでください。
+        /// </summary>
+        private void InitializeComponent()
+        {
+            System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle1 = new System.Windows.Forms.DataGridViewCellStyle();
+            System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle2 = new System.Windows.Forms.DataGridViewCellStyle();
+            System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle3 = new System.Windows.Forms.DataGridViewCellStyle();
+            this.btnDataEntry = new System.Windows.Forms.Button();
+            this.btnLineEntry = new System.Windows.Forms.Button();
+            this.btnLineDelete = new System.Windows.Forms.Button();
+            this.btnEnd = new System.Windows.Forms.Button();
+            this.label1 = new System.Windows.Forms.Label();
+            this.btnDispDown = new System.Windows.Forms.Button();
+            this.btnDispUp = new System.Windows.Forms.Button();
+            this.dgvMaster = new ProcessManagement.Forms.CustomControls.DataGridViewEX();
+            this.Column5 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.Column4 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.Column1 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.Column2 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            this.Column3 = new System.Windows.Forms.DataGridViewTextBoxColumn();
+            ((System.ComponentModel.ISupportInitialize)(this.dgvMaster)).BeginInit();
+            this.SuspendLayout();
+            // 
+            // btnDataEntry
+            // 
+            this.btnDataEntry.BackColor = System.Drawing.Color.Green;
+            this.btnDataEntry.ForeColor = System.Drawing.Color.White;
+            this.btnDataEntry.Location = new System.Drawing.Point(8, 289);
+            this.btnDataEntry.Name = "btnDataEntry";
+            this.btnDataEntry.Size = new System.Drawing.Size(120, 30);
+            this.btnDataEntry.TabIndex = 1;
+            this.btnDataEntry.Text = "登　録";
+            this.btnDataEntry.UseVisualStyleBackColor = false;
+            this.btnDataEntry.Click += new System.EventHandler(this.btnDataEntry_Click);
+            // 
+            // btnLineEntry
+            // 
+            this.btnLineEntry.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(128)))), ((int)(((byte)(255)))), ((int)(((byte)(128)))));
+            this.btnLineEntry.Location = new System.Drawing.Point(133, 289);
+            this.btnLineEntry.Name = "btnLineEntry";
+            this.btnLineEntry.Size = new System.Drawing.Size(120, 30);
+            this.btnLineEntry.TabIndex = 2;
+            this.btnLineEntry.Text = "行追加";
+            this.btnLineEntry.UseVisualStyleBackColor = false;
+            this.btnLineEntry.Click += new System.EventHandler(this.btnLineEntry_Click);
+            // 
+            // btnLineDelete
+            // 
+            this.btnLineDelete.BackColor = System.Drawing.Color.Red;
+            this.btnLineDelete.ForeColor = System.Drawing.Color.White;
+            this.btnLineDelete.Location = new System.Drawing.Point(259, 289);
+            this.btnLineDelete.Name = "btnLineDelete";
+            this.btnLineDelete.Size = new System.Drawing.Size(120, 30);
+            this.btnLineDelete.TabIndex = 3;
+            this.btnLineDelete.Text = "行削除";
+            this.btnLineDelete.UseVisualStyleBackColor = false;
+            this.btnLineDelete.Click += new System.EventHandler(this.btnLineDelete_Click);
+            // 
+            // btnEnd
+            // 
+            this.btnEnd.BackColor = System.Drawing.Color.Blue;
+            this.btnEnd.ForeColor = System.Drawing.Color.White;
+            this.btnEnd.Location = new System.Drawing.Point(385, 289);
+            this.btnEnd.Name = "btnEnd";
+            this.btnEnd.Size = new System.Drawing.Size(120, 30);
+            this.btnEnd.TabIndex = 4;
+            this.btnEnd.Text = "終　了";
+            this.btnEnd.UseVisualStyleBackColor = false;
+            this.btnEnd.Click += new System.EventHandler(this.btnEnd_Click);
+            // 
+            // label1
+            // 
+            this.label1.BackColor = System.Drawing.Color.FromArgb(((int)(((byte)(255)))), ((int)(((byte)(255)))), ((int)(((byte)(128)))));
+            this.label1.BorderStyle = System.Windows.Forms.BorderStyle.Fixed3D;
+            this.label1.ForeColor = System.Drawing.Color.Black;
+            this.label1.Location = new System.Drawing.Point(120, 8);
+            this.label1.Name = "label1";
+            this.label1.Size = new System.Drawing.Size(292, 34);
+            this.label1.TabIndex = 6;
+            this.label1.Text = "資　材　種　類　登　録";
+            this.label1.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
+            // 
+            // btnDispDown
+            // 
+            this.btnDispDown.Font = new System.Drawing.Font("ＭＳ 明朝", 20.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(128)));
+            this.btnDispDown.Location = new System.Drawing.Point(490, 164);
+            this.btnDispDown.Name = "btnDispDown";
+            this.btnDispDown.Size = new System.Drawing.Size(40, 40);
+            this.btnDispDown.TabIndex = 22;
+            this.btnDispDown.Text = "▼";
+            this.btnDispDown.UseVisualStyleBackColor = true;
+            this.btnDispDown.Click += new System.EventHandler(this.btnDispDown_Click);
+            // 
+            // btnDispUp
+            // 
+            this.btnDispUp.Font = new System.Drawing.Font("ＭＳ 明朝", 20.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(128)));
+            this.btnDispUp.Location = new System.Drawing.Point(490, 118);
+            this.btnDispUp.Name = "btnDispUp";
+            this.btnDispUp.Size = new System.Drawing.Size(40, 40);
+            this.btnDispUp.TabIndex = 21;
+            this.btnDispUp.Text = "▲";
+            this.btnDispUp.UseVisualStyleBackColor = true;
+            this.btnDispUp.Click += new System.EventHandler(this.btnDispUp_Click);
+            // 
+            // dgvMaster
+            // 
+            this.dgvMaster.AllowUserToAddRows = false;
+            this.dgvMaster.AllowUserToDeleteRows = false;
+            this.dgvMaster.AllowUserToResizeColumns = false;
+            this.dgvMaster.AllowUserToResizeRows = false;
+            this.dgvMaster.BorderStyle = System.Windows.Forms.BorderStyle.Fixed3D;
+            dataGridViewCellStyle1.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleCenter;
+            dataGridViewCellStyle1.BackColor = System.Drawing.SystemColors.Control;
+            dataGridViewCellStyle1.Font = new System.Drawing.Font("ＭＳ 明朝", 12F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(128)));
+            dataGridViewCellStyle1.ForeColor = System.Drawing.SystemColors.WindowText;
+            dataGridViewCellStyle1.SelectionBackColor = System.Drawing.SystemColors.Highlight;
+            dataGridViewCellStyle1.SelectionForeColor = System.Drawing.SystemColors.HighlightText;
+            dataGridViewCellStyle1.WrapMode = System.Windows.Forms.DataGridViewTriState.True;
+            this.dgvMaster.ColumnHeadersDefaultCellStyle = dataGridViewCellStyle1;
+            this.dgvMaster.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.DisableResizing;
+            this.dgvMaster.Columns.AddRange(new System.Windows.Forms.DataGridViewColumn[] {
+            this.Column5,
+            this.Column4,
+            this.Column1,
+            this.Column2,
+            this.Column3});
+            this.dgvMaster.Location = new System.Drawing.Point(8, 48);
+            this.dgvMaster.Name = "dgvMaster";
+            this.dgvMaster.RowHeadersWidth = 24;
+            this.dgvMaster.RowHeadersWidthSizeMode = System.Windows.Forms.DataGridViewRowHeadersWidthSizeMode.DisableResizing;
+            this.dgvMaster.RowTemplate.Height = 21;
+            this.dgvMaster.SelectionMode = System.Windows.Forms.DataGridViewSelectionMode.CellSelect;
+            this.dgvMaster.Size = new System.Drawing.Size(474, 235);
+            this.dgvMaster.TabIndex = 0;
+            this.dgvMaster.CellClick += new System.Windows.Forms.DataGridViewCellEventHandler(this.dgvMaster_CellClick);
+            this.dgvMaster.CellDoubleClick += new System.Windows.Forms.DataGridViewCellEventHandler(this.dgvMaster_CellDoubleClick);
+            this.dgvMaster.CellEnter += new System.Windows.Forms.DataGridViewCellEventHandler(this.dgvMaster_CellEnter);
+            this.dgvMaster.CellValueChanged += new System.Windows.Forms.DataGridViewCellEventHandler(this.dgvMaster_CellValueChanged);
+            this.dgvMaster.PreviewKeyDown += new System.Windows.Forms.PreviewKeyDownEventHandler(this.dgvMaster_PreviewKeyDown);
+            // 
+            // Column5
+            // 
+            this.Column5.HeaderText = "RowState";
+            this.Column5.Name = "Column5";
+            this.Column5.Visible = false;
+            // 
+            // Column4
+            // 
+            this.Column4.HeaderText = "DeleteFlg";
+            this.Column4.Name = "Column4";
+            this.Column4.Visible = false;
+            // 
+            // Column1
+            // 
+            dataGridViewCellStyle2.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleCenter;
+            dataGridViewCellStyle2.Font = new System.Drawing.Font("ＭＳ 明朝", 12F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(128)));
+            this.Column1.DefaultCellStyle = dataGridViewCellStyle2;
+            this.Column1.HeaderText = "№";
+            this.Column1.Name = "Column1";
+            this.Column1.ReadOnly = true;
+            this.Column1.Resizable = System.Windows.Forms.DataGridViewTriState.False;
+            this.Column1.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable;
+            this.Column1.Width = 80;
+            // 
+            // Column2
+            // 
+            this.Column2.HeaderText = "キー項目";
+            this.Column2.Name = "Column2";
+            this.Column2.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable;
+            this.Column2.Visible = false;
+            // 
+            // Column3
+            // 
+            dataGridViewCellStyle3.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleLeft;
+            dataGridViewCellStyle3.Font = new System.Drawing.Font("ＭＳ 明朝", 12F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(128)));
+            this.Column3.DefaultCellStyle = dataGridViewCellStyle3;
+            this.Column3.HeaderText = "資材種類";
+            this.Column3.Name = "Column3";
+            this.Column3.Resizable = System.Windows.Forms.DataGridViewTriState.False;
+            this.Column3.SortMode = System.Windows.Forms.DataGridViewColumnSortMode.NotSortable;
+            this.Column3.Width = 350;
+            // 
+            // FrmMaterialTypesMaster
+            // 
+            this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.None;
+            this.BackColor = System.Drawing.Color.Black;
+            this.ClientSize = new System.Drawing.Size(538, 327);
+            this.Controls.Add(this.btnDispDown);
+            this.Controls.Add(this.btnDispUp);
+            this.Controls.Add(this.label1);
+            this.Controls.Add(this.btnDataEntry);
+            this.Controls.Add(this.btnLineEntry);
+            this.Controls.Add(this.btnLineDelete);
+            this.Controls.Add(this.btnEnd);
+            this.Controls.Add(this.dgvMaster);
+            this.Font = new System.Drawing.Font("ＭＳ 明朝", 12F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(128)));
+            this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.Fixed3D;
+            this.KeyPreview = true;
+            this.MaximizeBox = false;
+            this.Name = "FrmMaterialTypesMaster";
+            this.ShowIcon = false;
+            this.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen;
+            this.FormClosing += new System.Windows.Forms.FormClosingEventHandler(this.FrmMaterialTypesMaster_FormClosing);
+            this.Load += new System.EventHandler(this.FrmMaterialTypesMaster_Load);
+            this.KeyDown += new System.Windows.Forms.KeyEventHandler(this.FrmMaterialTypesMaster_KeyDown);
+            ((System.ComponentModel.ISupportInitialize)(this.dgvMaster)).EndInit();
+            this.ResumeLayout(false);
+
+        }
+
+        #endregion
+
+        private DataGridViewEX dgvMaster;
+        private System.Windows.Forms.Button btnDataEntry;
+        private System.Windows.Forms.Button btnLineEntry;
+        private System.Windows.Forms.Button btnLineDelete;
+        private System.Windows.Forms.Button btnEnd;
+        private System.Windows.Forms.Label label1;
+        private System.Windows.Forms.Button btnDispDown;
+        private System.Windows.Forms.Button btnDispUp;
+        private System.Windows.Forms.DataGridViewTextBoxColumn Column5;
+        private System.Windows.Forms.DataGridViewTextBoxColumn Column4;
+        private System.Windows.Forms.DataGridViewTextBoxColumn Column1;
+        private System.Windows.Forms.DataGridViewTextBoxColumn Column2;
+        private System.Windows.Forms.DataGridViewTextBoxColumn Column3;
+    }
+}
\ No newline at end of file
Index: branches/src/ProcessManagement/ProcessManagement/Forms/SubForms/FrmRequestPrint.Designer.cs
===================================================================
--- branches/src/ProcessManagement/ProcessManagement/Forms/SubForms/FrmRequestPrint.Designer.cs	(revision 59)
+++ branches/src/ProcessManagement/ProcessManagement/Forms/SubForms/FrmRequestPrint.Designer.cs	(revision 60)
@@ -35,21 +35,31 @@
             this.lblMessageB = new System.Windows.Forms.Label();
             this.dateTimePicker1 = new System.Windows.Forms.DateTimePicker();
             this.groupBox1 = new System.Windows.Forms.GroupBox();
-            this.radioButton2 = new System.Windows.Forms.RadioButton();
-            this.radioButton1 = new System.Windows.Forms.RadioButton();
+            this.rdNoChange = new System.Windows.Forms.RadioButton();
+            this.rdChange = new System.Windows.Forms.RadioButton();
+            this.groupBox2 = new System.Windows.Forms.GroupBox();
+            this.rdNoPrint = new System.Windows.Forms.RadioButton();
+            this.rdPrint = new System.Windows.Forms.RadioButton();
+            this.groupBox3 = new System.Windows.Forms.GroupBox();
+            this.txtComment5 = new System.Windows.Forms.TextBox();
+            this.txtComment4 = new System.Windows.Forms.TextBox();
+            this.txtComment3 = new System.Windows.Forms.TextBox();
+            this.txtComment2 = new System.Windows.Forms.TextBox();
+            this.txtComment1 = new System.Windows.Forms.TextBox();
+            this.lblNowState = new System.Windows.Forms.Label();
+            this.lblChgState = new System.Windows.Forms.Label();
+            this.lblProgressNameA = new System.Windows.Forms.Label();
             this.lblProgressNameB = new System.Windows.Forms.Label();
-            this.lblProgressNameA = new System.Windows.Forms.Label();
-            this.label4 = new System.Windows.Forms.Label();
-            this.label3 = new System.Windows.Forms.Label();
-            this.label2 = new System.Windows.Forms.Label();
-            this.groupBox2 = new System.Windows.Forms.GroupBox();
-            this.radioButton3 = new System.Windows.Forms.RadioButton();
-            this.radioButton4 = new System.Windows.Forms.RadioButton();
+            this.lblGuide = new System.Windows.Forms.Label();
+            this.lblArrow = new System.Windows.Forms.Label();
+            this.groupBox4 = new System.Windows.Forms.GroupBox();
+            this.lblOrderersName = new System.Windows.Forms.Label();
             this.label1 = new System.Windows.Forms.Label();
-            this.cmbOrderNo = new System.Windows.Forms.ComboBox();
             this.panel1.SuspendLayout();
             this.groupBox1.SuspendLayout();
             this.groupBox2.SuspendLayout();
+            this.groupBox3.SuspendLayout();
+            this.groupBox4.SuspendLayout();
             this.SuspendLayout();
             // 
             // btnExecProc1
@@ -97,7 +107,7 @@
             this.panel1.Controls.Add(this.btnCancel);
             this.panel1.Controls.Add(this.btnExecProc1);
             this.panel1.Controls.Add(this.btnExecProc2);
-            this.panel1.Location = new System.Drawing.Point(20, 429);
+            this.panel1.Location = new System.Drawing.Point(20, 629);
             this.panel1.Name = "panel1";
             this.panel1.Size = new System.Drawing.Size(620, 60);
             this.panel1.TabIndex = 3;
@@ -105,10 +115,10 @@
             // lblMessageB
             // 
             this.lblMessageB.AutoSize = true;
-            this.lblMessageB.Font = new System.Drawing.Font("ＭＳ 明朝", 15.75F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(128)));
-            this.lblMessageB.Location = new System.Drawing.Point(97, 405);
+            this.lblMessageB.Font = new System.Drawing.Font("ＭＳ 明朝", 14.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(128)));
+            this.lblMessageB.Location = new System.Drawing.Point(121, 602);
             this.lblMessageB.Name = "lblMessageB";
-            this.lblMessageB.Size = new System.Drawing.Size(539, 21);
+            this.lblMessageB.Size = new System.Drawing.Size(492, 19);
             this.lblMessageB.TabIndex = 4;
             this.lblMessageB.Text = "【印刷のみ】、【保存のみ】を選択してください。";
             // 
@@ -115,7 +125,7 @@
             // dateTimePicker1
             // 
             this.dateTimePicker1.Font = new System.Drawing.Font("ＭＳ 明朝", 15.75F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(128)));
-            this.dateTimePicker1.Location = new System.Drawing.Point(204, 62);
+            this.dateTimePicker1.Location = new System.Drawing.Point(312, 18);
             this.dateTimePicker1.Name = "dateTimePicker1";
             this.dateTimePicker1.Size = new System.Drawing.Size(179, 28);
             this.dateTimePicker1.TabIndex = 5;
@@ -124,152 +134,233 @@
             // groupBox1
             // 
             this.groupBox1.BackColor = System.Drawing.Color.WhiteSmoke;
-            this.groupBox1.Controls.Add(this.radioButton2);
-            this.groupBox1.Controls.Add(this.radioButton1);
+            this.groupBox1.Controls.Add(this.lblArrow);
+            this.groupBox1.Controls.Add(this.lblGuide);
             this.groupBox1.Controls.Add(this.lblProgressNameB);
             this.groupBox1.Controls.Add(this.lblProgressNameA);
-            this.groupBox1.Controls.Add(this.label4);
-            this.groupBox1.Controls.Add(this.label3);
-            this.groupBox1.Controls.Add(this.label2);
-            this.groupBox1.Location = new System.Drawing.Point(16, 193);
+            this.groupBox1.Controls.Add(this.lblChgState);
+            this.groupBox1.Controls.Add(this.lblNowState);
+            this.groupBox1.Controls.Add(this.rdNoChange);
+            this.groupBox1.Controls.Add(this.rdChange);
+            this.groupBox1.Font = new System.Drawing.Font("ＭＳ 明朝", 14.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(128)));
+            this.groupBox1.Location = new System.Drawing.Point(17, 179);
             this.groupBox1.Name = "groupBox1";
-            this.groupBox1.Size = new System.Drawing.Size(620, 200);
+            this.groupBox1.Size = new System.Drawing.Size(620, 212);
             this.groupBox1.TabIndex = 6;
             this.groupBox1.TabStop = false;
             this.groupBox1.Text = "工事の進捗状態";
             // 
-            // radioButton2
+            // rdNoChange
             // 
-            this.radioButton2.AutoSize = true;
-            this.radioButton2.Location = new System.Drawing.Point(175, 29);
-            this.radioButton2.Name = "radioButton2";
-            this.radioButton2.Size = new System.Drawing.Size(143, 25);
-            this.radioButton2.TabIndex = 12;
-            this.radioButton2.Text = "変更しない";
-            this.radioButton2.UseVisualStyleBackColor = true;
+            this.rdNoChange.AutoSize = true;
+            this.rdNoChange.Location = new System.Drawing.Point(175, 29);
+            this.rdNoChange.Name = "rdNoChange";
+            this.rdNoChange.Size = new System.Drawing.Size(132, 23);
+            this.rdNoChange.TabIndex = 12;
+            this.rdNoChange.Text = "変更しない";
+            this.rdNoChange.UseVisualStyleBackColor = true;
             // 
-            // radioButton1
+            // rdChange
             // 
-            this.radioButton1.AutoSize = true;
-            this.radioButton1.Checked = true;
-            this.radioButton1.Location = new System.Drawing.Point(326, 29);
-            this.radioButton1.Name = "radioButton1";
-            this.radioButton1.Size = new System.Drawing.Size(120, 25);
-            this.radioButton1.TabIndex = 13;
-            this.radioButton1.TabStop = true;
-            this.radioButton1.Text = "変更する";
-            this.radioButton1.UseVisualStyleBackColor = true;
-            this.radioButton1.CheckedChanged += new System.EventHandler(this.radioButton1_CheckedChanged);
+            this.rdChange.AutoSize = true;
+            this.rdChange.Checked = true;
+            this.rdChange.Location = new System.Drawing.Point(334, 29);
+            this.rdChange.Name = "rdChange";
+            this.rdChange.Size = new System.Drawing.Size(111, 23);
+            this.rdChange.TabIndex = 13;
+            this.rdChange.TabStop = true;
+            this.rdChange.Text = "変更する";
+            this.rdChange.UseVisualStyleBackColor = true;
+            this.rdChange.CheckedChanged += new System.EventHandler(this.radioButton1_CheckedChanged);
             // 
-            // lblProgressNameB
+            // groupBox2
             // 
-            this.lblProgressNameB.BackColor = System.Drawing.Color.White;
-            this.lblProgressNameB.BorderStyle = System.Windows.Forms.BorderStyle.Fixed3D;
-            this.lblProgressNameB.FlatStyle = System.Windows.Forms.FlatStyle.Popup;
-            this.lblProgressNameB.Font = new System.Drawing.Font("ＭＳ 明朝", 15.75F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(128)));
-            this.lblProgressNameB.Location = new System.Drawing.Point(204, 148);
-            this.lblProgressNameB.Name = "lblProgressNameB";
-            this.lblProgressNameB.Size = new System.Drawing.Size(360, 30);
-            this.lblProgressNameB.TabIndex = 7;
-            this.lblProgressNameB.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
+            this.groupBox2.BackColor = System.Drawing.Color.WhiteSmoke;
+            this.groupBox2.Controls.Add(this.rdNoPrint);
+            this.groupBox2.Controls.Add(this.rdPrint);
+            this.groupBox2.Controls.Add(this.dateTimePicker1);
+            this.groupBox2.Location = new System.Drawing.Point(16, 67);
+            this.groupBox2.Name = "groupBox2";
+            this.groupBox2.Size = new System.Drawing.Size(620, 101);
+            this.groupBox2.TabIndex = 7;
+            this.groupBox2.TabStop = false;
+            this.groupBox2.Text = "請求日";
             // 
+            // rdNoPrint
+            // 
+            this.rdNoPrint.AutoSize = true;
+            this.rdNoPrint.Location = new System.Drawing.Point(175, 58);
+            this.rdNoPrint.Name = "rdNoPrint";
+            this.rdNoPrint.Size = new System.Drawing.Size(363, 23);
+            this.rdNoPrint.TabIndex = 14;
+            this.rdNoPrint.Text = "印字しない（　　年　　月　　日）";
+            this.rdNoPrint.UseVisualStyleBackColor = true;
+            this.rdNoPrint.CheckedChanged += new System.EventHandler(this.radioButton3_CheckedChanged);
+            // 
+            // rdPrint
+            // 
+            this.rdPrint.AutoSize = true;
+            this.rdPrint.Checked = true;
+            this.rdPrint.Location = new System.Drawing.Point(175, 22);
+            this.rdPrint.Name = "rdPrint";
+            this.rdPrint.Size = new System.Drawing.Size(111, 23);
+            this.rdPrint.TabIndex = 15;
+            this.rdPrint.TabStop = true;
+            this.rdPrint.Text = "印字する";
+            this.rdPrint.UseVisualStyleBackColor = true;
+            // 
+            // groupBox3
+            // 
+            this.groupBox3.BackColor = System.Drawing.Color.WhiteSmoke;
+            this.groupBox3.Controls.Add(this.txtComment5);
+            this.groupBox3.Controls.Add(this.txtComment4);
+            this.groupBox3.Controls.Add(this.txtComment3);
+            this.groupBox3.Controls.Add(this.txtComment2);
+            this.groupBox3.Controls.Add(this.txtComment1);
+            this.groupBox3.Location = new System.Drawing.Point(17, 394);
+            this.groupBox3.Name = "groupBox3";
+            this.groupBox3.Size = new System.Drawing.Size(621, 200);
+            this.groupBox3.TabIndex = 14;
+            this.groupBox3.TabStop = false;
+            this.groupBox3.Text = "コメント";
+            // 
+            // txtComment5
+            // 
+            this.txtComment5.Location = new System.Drawing.Point(17, 161);
+            this.txtComment5.MaxLength = 60;
+            this.txtComment5.Name = "txtComment5";
+            this.txtComment5.Size = new System.Drawing.Size(587, 26);
+            this.txtComment5.TabIndex = 4;
+            // 
+            // txtComment4
+            // 
+            this.txtComment4.Location = new System.Drawing.Point(17, 127);
+            this.txtComment4.MaxLength = 60;
+            this.txtComment4.Name = "txtComment4";
+            this.txtComment4.Size = new System.Drawing.Size(587, 26);
+            this.txtComment4.TabIndex = 3;
+            // 
+            // txtComment3
+            // 
+            this.txtComment3.Location = new System.Drawing.Point(17, 94);
+            this.txtComment3.MaxLength = 60;
+            this.txtComment3.Name = "txtComment3";
+            this.txtComment3.Size = new System.Drawing.Size(587, 26);
+            this.txtComment3.TabIndex = 2;
+            // 
+            // txtComment2
+            // 
+            this.txtComment2.Location = new System.Drawing.Point(17, 61);
+            this.txtComment2.MaxLength = 60;
+            this.txtComment2.Name = "txtComment2";
+            this.txtComment2.Size = new System.Drawing.Size(587, 26);
+            this.txtComment2.TabIndex = 1;
+            // 
+            // txtComment1
+            // 
+            this.txtComment1.Location = new System.Drawing.Point(17, 27);
+            this.txtComment1.MaxLength = 60;
+            this.txtComment1.Name = "txtComment1";
+            this.txtComment1.Size = new System.Drawing.Size(587, 26);
+            this.txtComment1.TabIndex = 0;
+            // 
+            // lblNowState
+            // 
+            this.lblNowState.AutoSize = true;
+            this.lblNowState.Font = new System.Drawing.Font("ＭＳ 明朝", 14.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(128)));
+            this.lblNowState.Location = new System.Drawing.Point(54, 70);
+            this.lblNowState.Name = "lblNowState";
+            this.lblNowState.Size = new System.Drawing.Size(135, 19);
+            this.lblNowState.TabIndex = 15;
+            this.lblNowState.Text = "現在進捗状態";
+            // 
+            // lblChgState
+            // 
+            this.lblChgState.AutoSize = true;
+            this.lblChgState.Font = new System.Drawing.Font("ＭＳ 明朝", 14.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(128)));
+            this.lblChgState.Location = new System.Drawing.Point(33, 140);
+            this.lblChgState.Name = "lblChgState";
+            this.lblChgState.Size = new System.Drawing.Size(156, 19);
+            this.lblChgState.TabIndex = 16;
+            this.lblChgState.Text = "実行後進捗状態";
+            // 
             // lblProgressNameA
             // 
             this.lblProgressNameA.BackColor = System.Drawing.Color.White;
             this.lblProgressNameA.BorderStyle = System.Windows.Forms.BorderStyle.Fixed3D;
             this.lblProgressNameA.FlatStyle = System.Windows.Forms.FlatStyle.Popup;
-            this.lblProgressNameA.Font = new System.Drawing.Font("ＭＳ 明朝", 15.75F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(128)));
-            this.lblProgressNameA.Location = new System.Drawing.Point(204, 69);
+            this.lblProgressNameA.Font = new System.Drawing.Font("ＭＳ 明朝", 14.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(128)));
+            this.lblProgressNameA.Location = new System.Drawing.Point(195, 64);
             this.lblProgressNameA.Name = "lblProgressNameA";
             this.lblProgressNameA.Size = new System.Drawing.Size(360, 30);
-            this.lblProgressNameA.TabIndex = 8;
+            this.lblProgressNameA.TabIndex = 17;
+            this.lblProgressNameA.Text = "請求準備";
             this.lblProgressNameA.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
             // 
-            // label4
+            // lblProgressNameB
             // 
-            this.label4.AutoSize = true;
-            this.label4.Font = new System.Drawing.Font("ＭＳ 明朝", 15.75F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(128)));
-            this.label4.Location = new System.Drawing.Point(33, 153);
-            this.label4.Name = "label4";
-            this.label4.Size = new System.Drawing.Size(171, 21);
-            this.label4.TabIndex = 9;
-            this.label4.Text = "実行後進捗状態";
+            this.lblProgressNameB.BackColor = System.Drawing.Color.White;
+            this.lblProgressNameB.BorderStyle = System.Windows.Forms.BorderStyle.Fixed3D;
+            this.lblProgressNameB.FlatStyle = System.Windows.Forms.FlatStyle.Popup;
+            this.lblProgressNameB.Font = new System.Drawing.Font("ＭＳ 明朝", 14.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(128)));
+            this.lblProgressNameB.Location = new System.Drawing.Point(195, 134);
+            this.lblProgressNameB.Name = "lblProgressNameB";
+            this.lblProgressNameB.Size = new System.Drawing.Size(360, 30);
+            this.lblProgressNameB.TabIndex = 18;
+            this.lblProgressNameB.Text = "請求完了";
+            this.lblProgressNameB.TextAlign = System.Drawing.ContentAlignment.MiddleCenter;
             // 
-            // label3
+            // lblGuide
             // 
-            this.label3.AutoSize = true;
-            this.label3.Font = new System.Drawing.Font("ＭＳ 明朝", 24F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(128)));
-            this.label3.Location = new System.Drawing.Point(368, 107);
-            this.label3.Name = "label3";
-            this.label3.Size = new System.Drawing.Size(32, 33);
-            this.label3.TabIndex = 10;
-            this.label3.Text = "⇓";
+            this.lblGuide.AutoSize = true;
+            this.lblGuide.BackColor = System.Drawing.Color.WhiteSmoke;
+            this.lblGuide.Font = new System.Drawing.Font("ＭＳ 明朝", 14.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(128)));
+            this.lblGuide.Location = new System.Drawing.Point(59, 181);
+            this.lblGuide.Name = "lblGuide";
+            this.lblGuide.Size = new System.Drawing.Size(513, 19);
+            this.lblGuide.TabIndex = 19;
+            this.lblGuide.Text = "現在、請求準備の一括案件のみ請求完了となります。";
             // 
-            // label2
+            // lblArrow
             // 
-            this.label2.AutoSize = true;
-            this.label2.Font = new System.Drawing.Font("ＭＳ 明朝", 15.75F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(128)));
-            this.label2.Location = new System.Drawing.Point(56, 74);
-            this.label2.Name = "label2";
-            this.label2.Size = new System.Drawing.Size(148, 21);
-            this.label2.TabIndex = 11;
-            this.label2.Text = "現在進捗状態";
+            this.lblArrow.AutoSize = true;
+            this.lblArrow.Font = new System.Drawing.Font("ＭＳ 明朝", 24F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(128)));
+            this.lblArrow.Location = new System.Drawing.Point(362, 97);
+            this.lblArrow.Name = "lblArrow";
+            this.lblArrow.Size = new System.Drawing.Size(32, 33);
+            this.lblArrow.TabIndex = 20;
+            this.lblArrow.Text = "⇓";
             // 
-            // groupBox2
+            // groupBox4
             // 
-            this.groupBox2.BackColor = System.Drawing.Color.WhiteSmoke;
-            this.groupBox2.Controls.Add(this.radioButton3);
-            this.groupBox2.Controls.Add(this.radioButton4);
-            this.groupBox2.Controls.Add(this.dateTimePicker1);
-            this.groupBox2.Location = new System.Drawing.Point(16, 57);
-            this.groupBox2.Name = "groupBox2";
-            this.groupBox2.Size = new System.Drawing.Size(620, 130);
-            this.groupBox2.TabIndex = 7;
-            this.groupBox2.TabStop = false;
-            this.groupBox2.Text = "請求日";
+            this.groupBox4.BackColor = System.Drawing.Color.WhiteSmoke;
+            this.groupBox4.Controls.Add(this.lblOrderersName);
+            this.groupBox4.Controls.Add(this.label1);
+            this.groupBox4.Location = new System.Drawing.Point(16, 0);
+            this.groupBox4.Name = "groupBox4";
+            this.groupBox4.Size = new System.Drawing.Size(620, 60);
+            this.groupBox4.TabIndex = 17;
+            this.groupBox4.TabStop = false;
             // 
-            // radioButton3
+            // lblOrderersName
             // 
-            this.radioButton3.AutoSize = true;
-            this.radioButton3.Location = new System.Drawing.Point(175, 99);
-            this.radioButton3.Name = "radioButton3";
-            this.radioButton3.Size = new System.Drawing.Size(396, 25);
-            this.radioButton3.TabIndex = 14;
-            this.radioButton3.Text = "印字しない（　　年　　月　　日）";
-            this.radioButton3.UseVisualStyleBackColor = true;
-            this.radioButton3.CheckedChanged += new System.EventHandler(this.radioButton3_CheckedChanged);
+            this.lblOrderersName.BackColor = System.Drawing.Color.White;
+            this.lblOrderersName.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle;
+            this.lblOrderersName.Location = new System.Drawing.Point(112, 21);
+            this.lblOrderersName.Name = "lblOrderersName";
+            this.lblOrderersName.Size = new System.Drawing.Size(485, 26);
+            this.lblOrderersName.TabIndex = 17;
+            this.lblOrderersName.TextAlign = System.Drawing.ContentAlignment.MiddleLeft;
             // 
-            // radioButton4
-            // 
-            this.radioButton4.AutoSize = true;
-            this.radioButton4.Checked = true;
-            this.radioButton4.Location = new System.Drawing.Point(175, 29);
-            this.radioButton4.Name = "radioButton4";
-            this.radioButton4.Size = new System.Drawing.Size(120, 25);
-            this.radioButton4.TabIndex = 15;
-            this.radioButton4.TabStop = true;
-            this.radioButton4.Text = "印字する";
-            this.radioButton4.UseVisualStyleBackColor = true;
-            // 
             // label1
             // 
             this.label1.AutoSize = true;
-            this.label1.Location = new System.Drawing.Point(12, 21);
+            this.label1.Location = new System.Drawing.Point(15, 25);
             this.label1.Name = "label1";
-            this.label1.Size = new System.Drawing.Size(102, 21);
-            this.label1.TabIndex = 9;
-            this.label1.Text = "作成対象";
+            this.label1.Size = new System.Drawing.Size(93, 19);
+            this.label1.TabIndex = 16;
+            this.label1.Text = "請求先名";
             // 
-            // cmbOrderNo
-            // 
-            this.cmbOrderNo.BackColor = System.Drawing.Color.White;
-            this.cmbOrderNo.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
-            this.cmbOrderNo.FormattingEnabled = true;
-            this.cmbOrderNo.Location = new System.Drawing.Point(121, 21);
-            this.cmbOrderNo.Name = "cmbOrderNo";
-            this.cmbOrderNo.Size = new System.Drawing.Size(161, 29);
-            this.cmbOrderNo.TabIndex = 10;
-            // 
             // FrmRequestPrint
             // 
             this.AcceptButton = this.btnExecProc1;
@@ -276,14 +367,14 @@
             this.AutoScaleDimensions = new System.Drawing.SizeF(96F, 96F);
             this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Dpi;
             this.BackColor = System.Drawing.Color.White;
-            this.ClientSize = new System.Drawing.Size(652, 488);
-            this.Controls.Add(this.cmbOrderNo);
-            this.Controls.Add(this.label1);
+            this.ClientSize = new System.Drawing.Size(652, 698);
+            this.Controls.Add(this.groupBox4);
+            this.Controls.Add(this.groupBox3);
             this.Controls.Add(this.groupBox2);
             this.Controls.Add(this.groupBox1);
             this.Controls.Add(this.lblMessageB);
             this.Controls.Add(this.panel1);
-            this.Font = new System.Drawing.Font("ＭＳ 明朝", 15.75F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(128)));
+            this.Font = new System.Drawing.Font("ＭＳ 明朝", 14.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(128)));
             this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedSingle;
             this.KeyPreview = true;
             this.MaximizeBox = false;
@@ -299,6 +390,10 @@
             this.groupBox1.PerformLayout();
             this.groupBox2.ResumeLayout(false);
             this.groupBox2.PerformLayout();
+            this.groupBox3.ResumeLayout(false);
+            this.groupBox3.PerformLayout();
+            this.groupBox4.ResumeLayout(false);
+            this.groupBox4.PerformLayout();
             this.ResumeLayout(false);
             this.PerformLayout();
 
@@ -313,17 +408,25 @@
         private System.Windows.Forms.Label lblMessageB;
         private System.Windows.Forms.DateTimePicker dateTimePicker1;
         private System.Windows.Forms.GroupBox groupBox1;
-        private System.Windows.Forms.RadioButton radioButton2;
-        private System.Windows.Forms.RadioButton radioButton1;
+        private System.Windows.Forms.RadioButton rdNoChange;
+        private System.Windows.Forms.RadioButton rdChange;
+        private System.Windows.Forms.GroupBox groupBox2;
+        private System.Windows.Forms.RadioButton rdNoPrint;
+        private System.Windows.Forms.RadioButton rdPrint;
+        private System.Windows.Forms.GroupBox groupBox3;
+        private System.Windows.Forms.TextBox txtComment5;
+        private System.Windows.Forms.TextBox txtComment4;
+        private System.Windows.Forms.TextBox txtComment3;
+        private System.Windows.Forms.TextBox txtComment2;
+        private System.Windows.Forms.TextBox txtComment1;
+        private System.Windows.Forms.Label lblGuide;
         private System.Windows.Forms.Label lblProgressNameB;
         private System.Windows.Forms.Label lblProgressNameA;
-        private System.Windows.Forms.Label label4;
-        private System.Windows.Forms.Label label3;
-        private System.Windows.Forms.Label label2;
-        private System.Windows.Forms.GroupBox groupBox2;
-        private System.Windows.Forms.RadioButton radioButton3;
-        private System.Windows.Forms.RadioButton radioButton4;
+        private System.Windows.Forms.Label lblChgState;
+        private System.Windows.Forms.Label lblNowState;
+        private System.Windows.Forms.Label lblArrow;
+        private System.Windows.Forms.GroupBox groupBox4;
+        private System.Windows.Forms.Label lblOrderersName;
         private System.Windows.Forms.Label label1;
-        private System.Windows.Forms.ComboBox cmbOrderNo;
     }
 }
\ No newline at end of file
Index: branches/src/ProcessManagement/ProcessManagement/Forms/SubForms/FrmRequestPrint.cs
===================================================================
--- branches/src/ProcessManagement/ProcessManagement/Forms/SubForms/FrmRequestPrint.cs	(revision 59)
+++ branches/src/ProcessManagement/ProcessManagement/Forms/SubForms/FrmRequestPrint.cs	(revision 60)
@@ -53,6 +53,7 @@
         enum enumSheetName
         {
             Cover = 0,
+            List,
             Detail,
         }
 
@@ -62,11 +63,13 @@
         private static readonly Dictionary<enumSheetName,string> s_DicSheetName = new Dictionary<enumSheetName, string>()
         {
             { enumSheetName.Cover, "請求書（表紙）" },
+            { enumSheetName.List, "請求書（一覧）" },
             { enumSheetName.Detail, "請求書（内訳）" },
         };
         #endregion
 
         #region 変数
+
         /// <summary>
         /// 終了状態フラグ
         /// </summary>
@@ -125,7 +128,7 @@
         /// <summary>
         /// 請求合計データ
         /// </summary>
-        private List<RequestTotalData> m_LstRequestTotalData = new List<RequestTotalData>();
+//        private List<RequestTotalData> m_LstRequestTotalData = new List<RequestTotalData>();
 
         /// <summary>
         /// ツールチップ
@@ -147,6 +150,28 @@
         /// </summary>
         private int m_SelectOrderIndex = 0;
 
+        /// <summary>
+        /// 請求書No
+        /// </summary>
+        private int m_nInvoiceNo = 0;
+
+        /// <summary>
+        /// 請求書データ
+        /// </summary>
+        private InvoiceData m_InvData = new InvoiceData();
+
+        /// <summary>
+        /// 請求書ヘッダ
+        /// </summary>
+        private List<RequestHead> m_lstReqHead = new List<RequestHead>();
+
+        /// <summary>
+        /// 請求書データ
+        /// </summary>
+        private Dictionary<int, List<RequestData>> m_dicReqData = new Dictionary<int, List<RequestData>>();
+
+        private Dictionary<int, ConstructionBaseInfo> m_dicConstructionBaseInfo = new Dictionary<int, ConstructionBaseInfo>();
+        
         // *-----* 共通処理設定 *-----*
         /// <summary>
         /// サブフォームフラグ
@@ -200,6 +225,15 @@
             set { m_bDatePrintFlg = value; }
         }
 
+        /// <summary>
+        /// 設計書No
+        /// </summary>
+        public int InvoiceNo
+        {
+            get { return m_nInvoiceNo; }
+            set { m_nInvoiceNo = value; }
+        }
+
         // *-----* 共通処理設定 *-----*
         /// <summary>
         /// サブフォームフラグ
@@ -288,16 +322,21 @@
             if (!StatusChange()) return;
 
             // 日付印刷をしない
-            if (radioButton3.Checked) m_bDatePrintFlg = false;
+            if (rdNoPrint.Checked) m_bDatePrintFlg = false;
 
             // 選択日付取得
             m_ExcuteDate = dateTimePicker1.Value;
 
-            // 工事基本情報を更新する
-            UpdateConstructionBaseInfo();
+            // 請求書データの反映
+            EntryInvoiceData();
 
-            // 非同期で印刷処理を実行する
-            m_SelectOrderIndex = cmbOrderNo.SelectedIndex;
+            // 工事の進捗状態に「変更する」が選択されている場合
+            if (rdChange.Checked)
+            {
+                // 工事基本情報を更新する
+                UpdateConstructionBaseInfo();
+            }
+
             await Task.Run(() =>
             {
                 // 印刷処理
@@ -320,7 +359,7 @@
             // 保存先指定ダイアログの表示
             FrmSaveFilePath frm = new FrmSaveFilePath();
             frm.SaveType = (int)CommonDefine.SaveFileType.ExcelFile;
-            frm.ShowDialog();
+            frm.ShowDialog(this);
             if (frm.EndButton == DialogResult.Cancel)
             {
                 return;
@@ -331,16 +370,22 @@
             if (!StatusChange()) return;
 
             // 日付印刷をしない
-            if (radioButton3.Checked) m_bDatePrintFlg = false;
+            if (rdNoPrint.Checked) m_bDatePrintFlg = false;
             
             // 選択日付取得
             m_ExcuteDate = dateTimePicker1.Value;
 
-            // 工事基本情報を更新する
-            UpdateConstructionBaseInfo();
+            // 請求書データの反映
+            EntryInvoiceData();
 
+            // 工事の進捗状態に「変更する」が選択されている場合
+            if (rdChange.Checked)
+            {
+                // 工事基本情報を更新する
+                UpdateConstructionBaseInfo();
+            }
+
             // 非同期で印刷処理を実行する
-            m_SelectOrderIndex = cmbOrderNo.SelectedIndex;
             await Task.Run(() =>
             {
                 // 印刷処理
@@ -360,7 +405,7 @@
         /// <param name="e"></param>
         private void radioButton3_CheckedChanged(object sender, EventArgs e)
         {
-            if (radioButton3.Checked)
+            if (rdNoPrint.Checked)
             {
                 dateTimePicker1.Visible = false;
             }
@@ -380,13 +425,23 @@
         private void radioButton1_CheckedChanged(object sender, EventArgs e)
         {
             // 工事進捗変更
-            if (radioButton1.Checked)
-            {   // 変更する
-                m_dispControl[(int)Dispcount.ProgressStatusB].Text = CommonDefine.ProjectsStatus[m_ProgressStatus];
+            if (rdChange.Checked)
+            {
+                lblNowState.Enabled = true;
+                lblChgState.Enabled = true;
+                lblProgressNameA.Enabled = true;
+                lblProgressNameB.Enabled = true;
+                lblGuide.Enabled = true;
+                lblArrow.Enabled = true;
             }
             else
-            {   // 変更しない
-                m_dispControl[(int)Dispcount.ProgressStatusB].Text = CommonDefine.ProjectsStatus[m_ConstructionBaseInfo.ConstructionStatusFlg];
+            {
+                lblNowState.Enabled = false;
+                lblChgState.Enabled = false;
+                lblProgressNameA.Enabled = false;
+                lblProgressNameB.Enabled = false;
+                lblGuide.Enabled = false;
+                lblArrow.Enabled = false;
             }
         }
         #endregion
@@ -400,10 +455,10 @@
             m_dispControl[(int)Dispcount.ExeCuteDate] = dateTimePicker1;
             m_dispControl[(int)Dispcount.ProgressStatusA] = lblProgressNameA;
             m_dispControl[(int)Dispcount.ProgressStatusB] = lblProgressNameB;
-            m_dispControl[(int)Dispcount.radioButtonA1] = radioButton1;
-            m_dispControl[(int)Dispcount.radioButtonA2] = radioButton2;
-            m_dispControl[(int)Dispcount.radioButtonB1] = radioButton4;
-            m_dispControl[(int)Dispcount.radioButtonB2] = radioButton3;
+            m_dispControl[(int)Dispcount.radioButtonA1] = rdChange;
+            m_dispControl[(int)Dispcount.radioButtonA2] = rdNoChange;
+            m_dispControl[(int)Dispcount.radioButtonB1] = rdPrint;
+            m_dispControl[(int)Dispcount.radioButtonB2] = rdNoPrint;
         }
         #endregion
 
@@ -416,7 +471,7 @@
         {
             try
             {
-                if (!lblProgressNameA.Text.Equals(lblProgressNameB.Text))
+                if (rdChange.Checked == true)
                 {
                     if (MessageBox.Show("工事案件の進捗状態が変わります、よろしいですか？",
                                         "進捗状態変更確認",
@@ -465,103 +520,283 @@
         /// <returns></returns>
         private bool DisplayData()
         {
-            var lstReqTotalData = new List<RequestTotalData>();
-
             try
             {
                 bool bRet = true;
 
-                // 工事基本情報を取得
-                if (!GetConstructionBaseInfo(m_ConstructionCode, ref m_ConstructionBaseInfo))
-                {
+                // 請求書データの取得
+                if( GetInvoiceData() == false){
                     return false;
                 }
 
-                // 増減工事情報を取得
-                if (!GetConstructionLink(m_ConstructionCode, ref m_LstConstructionLink))
-                {
+                // 本工事の工事情報の取得
+                if( GetMainConstructionBaseInfo() == false){
                     return false;
                 }
 
-                List<int> lstConstCodes = new List<int>();
-                lstConstCodes.Add(m_ConstructionCode);
-                lstConstCodes.AddRange(m_LstConstructionLink);
-
-                // 工事基本情報明細を取得
-                if (!GetConstructionBaseInfoDetail(lstConstCodes, ref m_DicConstructionBaseInfoDetail))
+                if (m_InvData.RequestDate == DateTime.MinValue)
                 {
-                    return false;
+                    // 初期時間セット
+                    dateTimePicker1.Value = m_ExcuteDate;
                 }
+                else
+                {
+                    dateTimePicker1.Value = m_InvData.CretateDate;
+                }
 
-                // 請求データを取得
-                if (!GetRequestData(m_ConstructionCode, ref m_RequestData))
+                lblOrderersName.Text = m_InvData.RequestName;
+
+                txtComment1.Text = m_InvData.Comment1;
+                txtComment2.Text = m_InvData.Comment2;
+                txtComment3.Text = m_InvData.Comment3;
+                txtComment4.Text = m_InvData.Comment4;
+                txtComment5.Text = m_InvData.Comment5;
+
+                // ToolTipの設定
+                SetToolTip();
+
+                return bRet;
+            }
+            catch (Exception ex)
+            {
+                logger.ErrorFormat("システムエラー：{0}：{1}", CommonMotions.GetMethodName(), ex.Message);
+                return false;
+            }
+        }
+        #endregion
+
+        #region ToolTipの設定
+        private void SetToolTip()
+        {
+            // ToolTipが表示されるまでの時間
+            ToolTip1.InitialDelay = 0;
+            // ToolTipが表示されている時に、別のToolTipを表示するまでの時間
+            ToolTip1.ReshowDelay = 1000;
+            // ToolTipを表示する時間
+            ToolTip1.AutoPopDelay = 10000;
+            // フォームがアクティブでない時はToolTipを表示しない
+            ToolTip1.ShowAlways = false;
+
+            // 文字セット
+            ToolTip1.SetToolTip(dateTimePicker1, "請求日が表示されている日付と違う場合は、変更してください。");
+            ToolTip1.SetToolTip(rdPrint, "請求日を請求書へ「印刷する」場合は、こちらを選択してください。");
+            ToolTip1.SetToolTip(rdNoPrint, "請求日を請求書へ「印刷せずに空白」で印刷する場合は、こちらを選択してください。");
+
+            ToolTip1.SetToolTip(rdChange, "工事進捗状態を変更して次の処理へ進む場合は、こちらを選択してください。");
+            ToolTip1.SetToolTip(rdNoChange, "工事進捗進捗を現在の状態から変更しない場合は、こちらを選択してください。");
+        }
+        #endregion
+
+        #region 請求書データの取得
+        /// <summary>
+        /// 請求書データの取得
+        /// </summary>
+        private bool GetInvoiceData()
+        {
+            IOInvoiceData ioInvData = new IOInvoiceData();
+            IORequestHead ioReqHead = new IORequestHead();
+            IORequestData ioReqData = new IORequestData();
+
+            try
+            {
+                string sql = "";
+
+                // 請求書データの取得
+                sql = ioInvData.CreatePrimarykeyString(m_nInvoiceNo);
+                if (ioInvData.SelectAction(sql, ref m_InvData) == false)
                 {
                     return false;
                 }
 
-                // 請求合計データを取得
-                if (!GetRequestTotalData(m_RequestNo, ref m_LstRequestTotalData))
+                // 請求ヘッダの取得
+                sql = string.Format(" WHERE InvoiceNo = {0} ORDER BY ReqConstructionCode", m_nInvoiceNo);
+                if (ioReqHead.SelectAction(sql, ref m_lstReqHead) == false)
                 {
                     return false;
                 }
 
-                // 作成対象のコンボボックスリストを初期化
-                cmbOrderNo.Items.Clear();
-                foreach (var reqTotalData in m_LstRequestTotalData)
+                foreach (RequestHead ReqHead in m_lstReqHead)
                 {
-                    // 請求回数分
-                    cmbOrderNo.Items.Add(string.Format("{0}回目", reqTotalData.OrderNo));
+                    // 請求ヘッダの取得
+                    sql = string.Format(" WHERE RequestNo = {0} ORDER BY MainConstructionCode", ReqHead.RequestNo);
+                    List<RequestData> lstReqData = new List<RequestData>();
+                    if (ioReqData.SelectAction(sql, ref lstReqData) == false)
+                    {
+                        return false;
+                    }
+
+                    m_dicReqData.Add(ReqHead.RequestNo, lstReqData);
+
                 }
-                cmbOrderNo.SelectedIndex = 0;
 
-                // 初期時間セット
-                dateTimePicker1.Value = m_ExcuteDate;
+                return true;
+            }
+            catch (Exception ex)
+            {
+                logger.ErrorFormat("システムエラー：{0}：{1}", CommonMotions.GetMethodName(), ex.Message);
 
-                // ----- 状態を工事基本情報より取る
-                // 現在進捗状態
-                m_dispControl[(int)Dispcount.ProgressStatusA].Text = CommonDefine.ProjectsStatus[m_ConstructionBaseInfo.ConstructionStatusFlg];
+                return false;
+            }
+            finally
+            {
+                ioInvData.close();
+                ioInvData = null;
+                ioReqHead.close();
+                ioReqHead = null;
+                ioReqData.close();
+                ioReqData = null;
+            }
 
-                // 実行後進捗状態
-                if (m_ConstructionBaseInfo.ConstructionStatusFlg == 8)
+        }
+        #endregion
+
+        #region 工事基本情報の追加
+        private void AddConstructionBaseInfoDic(ConstructionBaseInfo Info)
+        {
+            ConstructionBaseInfo wrk = null;
+
+            if (m_dicConstructionBaseInfo.TryGetValue(Info.ConstructionCode, out wrk) == false)
+            {
+                m_dicConstructionBaseInfo.Add(Info.ConstructionCode, Info);
+            }
+        }
+        #endregion
+
+        #region 工事基本情報の取得
+        /// <summary>
+        /// 工事基本情報の取得
+        /// </summary>
+        private bool GetMainConstructionBaseInfo()
+        {
+            IOConstructionBaseInfo ioInfo = new IOConstructionBaseInfo();
+
+            foreach (RequestHead ReqHead in m_lstReqHead)
+            {
+                string sql = ioInfo.CreatePrimarykeyString(ReqHead.ReqConstructionCode);
+                ConstructionBaseInfo info = new ConstructionBaseInfo();
+                if (ioInfo.SelectAction(sql, ref info) == false)
                 {
-                    // 現在の進捗状態が施工完了の場合
-                    radioButton1.Checked = true;
-                    m_dispControl[(int)Dispcount.ProgressStatusB].Text = CommonDefine.ProjectsStatus[m_ProgressStatus];
+                    return false;
                 }
-                else
+
+                AddConstructionBaseInfoDic(info);
+            }
+
+            List<int> lstKey = new List<int>(m_dicReqData.Keys);
+            try
+            {
+                foreach (int nRequestNo in lstKey)
                 {
-                    // 施工完了以外の場合
-                    radioButton2.Checked = true;
-                    radioButton1.Enabled = false;
-                    m_dispControl[(int)Dispcount.ProgressStatusB].Text = m_dispControl[(int)Dispcount.ProgressStatusA].Text;
+                    List<RequestData> lstReqData = null;
+
+                    if (m_dicReqData.TryGetValue(nRequestNo, out lstReqData) == false)
+                    {
+                        return false;
+                    }
+
+                    foreach (RequestData ReqData in lstReqData)
+                    {
+                        string sql = ioInfo.CreatePrimarykeyString(ReqData.MainConstructionCode);
+                        ConstructionBaseInfo info = new ConstructionBaseInfo();
+                        if (ioInfo.SelectAction(sql, ref info) == false)
+                        {
+                            return false;
+                        }
+
+                        AddConstructionBaseInfoDic(info);
+                    }
+
                 }
 
-                // ----- ToolTipの設定を行う
-                // ToolTipが表示されるまでの時間
-                ToolTip1.InitialDelay = 0;
-                // ToolTipが表示されている時に、別のToolTipを表示するまでの時間
-                ToolTip1.ReshowDelay = 1000;
-                // ToolTipを表示する時間
-                ToolTip1.AutoPopDelay = 10000;
-                // フォームがアクティブでない時はToolTipを表示しない
-                ToolTip1.ShowAlways = false;
+                return true;
+            }
+            catch (Exception ex)
+            {
+                logger.ErrorFormat("システムエラー：{0}：{1}", CommonMotions.GetMethodName(), ex.Message);
 
-                // 文字セット
-                ToolTip1.SetToolTip(dateTimePicker1, "請求日が表示されている日付と違う場合は、変更してください。");
-                ToolTip1.SetToolTip(radioButton4, "請求日を請求書へ「印刷する」場合は、こちらを選択してください。");
-                ToolTip1.SetToolTip(radioButton3, "請求日を請求書へ「印刷せずに空白」で印刷する場合は、こちらを選択してください。");
+                return false;
+            }
+            finally
+            {
+                ioInfo.close();
+                ioInfo = null;
+            }
 
-                ToolTip1.SetToolTip(radioButton1, "工事進捗状態を変更して次の処理へ進む場合は、こちらを選択してください。");
-                ToolTip1.SetToolTip(radioButton2, "工事進捗進捗を現在の状態から変更しない場合は、こちらを選択してください。");
-                
-                return bRet;
+        }
+        #endregion
+
+        #region 請求書データの反映
+        private void EntryInvoiceData()
+        {
+            int nTotalAmount = 0;
+            int nTaxAmount = 0;
+
+            foreach (RequestHead ReqHead in m_lstReqHead)
+            {
+                nTotalAmount += ReqHead.RequestTotalAmount;
+                nTaxAmount += ReqHead.TaxAmount;
             }
+
+            m_InvData.TotalAmount = nTotalAmount;
+            m_InvData.TaxAmount = nTaxAmount;
+
+            if (rdPrint.Checked == true)
+            {
+                m_InvData.CretateDate = dateTimePicker1.Value;
+            }
+            else
+            {
+                m_InvData.CretateDate = DateTime.MinValue;
+            }
+
+            m_InvData.Comment1 = txtComment1.Text;
+            m_InvData.Comment2 = txtComment2.Text;
+            m_InvData.Comment3 = txtComment3.Text;
+            m_InvData.Comment4 = txtComment4.Text;
+            m_InvData.Comment5 = txtComment5.Text;
+
+            if (rdChange.Checked == true)
+            {
+                m_InvData.CompleteFlg = 1;
+
+                if (UpdateInvoiceData() == false)
+                {
+                    return;
+                }
+            }
+
+        }
+        #endregion
+
+        #region 請求書データ更新
+        private bool UpdateInvoiceData()
+        {
+            IOInvoiceData ioInvData = new IOInvoiceData();
+
+            try
+            {
+                string sql = ioInvData.CreatePrimarykeyString( m_InvData.InvoiceNo );
+                if (ioInvData.UpdateAction(sql, m_InvData) == false)
+                {
+                    return false;
+                }
+
+                return true;
+            }
             catch (Exception ex)
             {
                 logger.ErrorFormat("システムエラー：{0}：{1}", CommonMotions.GetMethodName(), ex.Message);
+
                 return false;
             }
+            finally
+            {
+                ioInvData.close();
+                ioInvData = null;
+            }
+
         }
+        
         #endregion
 
         #region 工事データ更新
@@ -571,28 +806,132 @@
         /// <returns></returns>
         private bool UpdateConstructionBaseInfo()
         {
-            var lstReqTotalData = new List<RequestTotalData>();
-            IOConstructionBaseInfo cbDB = new IOConstructionBaseInfo();
+
+            IOConstructionBaseInfo ioInfo = new IOConstructionBaseInfo();
+            IOConstructionProgressDate ioPrgDate = new IOConstructionProgressDate();
+
+            List<int> lstKeyInfo = new List<int>(m_dicConstructionBaseInfo.Keys);
+
+            Dictionary<int, int> dicCodeWork = new Dictionary<int, int>();
+
+            // トランザクション開始
+            ioInfo.beginTran();
+            ioPrgDate.beginTran();
+
+            string sql = "";
+
             try
             {
-                bool bUpdate = false;
+                foreach (int nConstructionCode in lstKeyInfo)
+                {
+                    int nOldStatus = 0;
+                    ConstructionBaseInfo Info = null;
 
-                string strSQL = cbDB.CreatePrimarykeyString(m_RequestNo);
-                ConstructionBaseInfo DataRec = new ConstructionBaseInfo();
-                if (!cbDB.SelectAction(strSQL, ref DataRec)) return false;
-                
-                // 進捗状態
-                if (radioButton1.Checked)
+                    // 工事基本情報の取得
+                    if (m_dicConstructionBaseInfo.TryGetValue(nConstructionCode, out Info) == false)
+                    {
+                        ioInfo.rollback();
+                        ioPrgDate.rollback();
+                        return false;
+                    }
+
+                    nOldStatus = Info.ConstructionStatusFlg;
+
+                    // 工事状態が「請求準備」ではない場合は、対象外
+                    if (nOldStatus != (int)CommonDefine.StatNumArray.Status9)
+                    {
+                        continue;
+                    }
+
+                    // 工事状態フラグを「請求完了」に変更
+                    Info.ConstructionStatusFlg = (int)CommonDefine.StatNumArray.Status10;
+
+                    // 工事基本情報を更新
+                    sql = ioInfo.CreatePrimarykeyString(nConstructionCode);
+                    if (ioInfo.UpdateAction(sql, Info) == false)
+                    {
+                        ioInfo.rollback();
+                        ioPrgDate.rollback();
+                        return false;
+                    }
+
+                    // 既にデータが存在しないか一度検索しておく
+                    sql = ioPrgDate.CreatePrimarykeyString(nConstructionCode, Info.ConstructionStatusFlg);
+                    List<ConstructionProgressDate> lstPrgDate = new List<ConstructionProgressDate>();
+                    if (ioPrgDate.SelectAction(sql, ref lstPrgDate) == false)
+                    {
+                        ioInfo.rollback();
+                        ioPrgDate.rollback();
+                        return false;
+                    }
+
+                    // データがある場合は、当該データを削除する
+                    if (lstPrgDate.Count > 0)
+                    {
+                        // 該当データを削除
+                        sql = ioPrgDate.CreatePrimarykeyString(nConstructionCode, Info.ConstructionStatusFlg);
+                        if (ioPrgDate.DeleteAction(sql) == false)
+                        {
+                            ioInfo.rollback();
+                            ioPrgDate.rollback();
+                            return false;
+                        }
+                    }
+
+                    // 案件進捗日付データの構築
+                    ConstructionProgressDate PrgDate = new ConstructionProgressDate();
+
+                    // 案件進捗日付データの設定
+                    PrgDate.ConstructionCode = nConstructionCode;
+                    PrgDate.ConstructionStatusFlg = (int)CommonDefine.StatNumArray.Status10;
+                    PrgDate.PreviousStatusFlg = nOldStatus;
+                    PrgDate.ChangeDate = DateTime.Now;
+                    PrgDate.ChangePersonCode = CommonMotions.LoginUserData.PersonCode;
+
+                    // 案件進捗日付データを挿入
+                    if (ioPrgDate.InsertAction(PrgDate) == false)
+                    {
+                        ioInfo.rollback();
+                        ioPrgDate.rollback();
+                        return false;
+                    }
+
+                    // 対象工事が結合（子）工事の場合
+                    if (Info.JoinFlg == (int)CommonDefine.BaseInfoJoinFlg.JoinChildren)
+                    {
+                        // 結合（親）工事番号の取得
+                        int nParentCode = GetJoinParentConstructionCode(nConstructionCode);
+
+                        int nChildCode = 0;
+
+                        // 親工事番号が登録されていない場合は登録する
+                        if (dicCodeWork.TryGetValue(nParentCode, out nChildCode) == false)
+                        {
+                            // 結合（親）の工事状態を更新するために工事番号を退避
+                            dicCodeWork.Add(nParentCode, nConstructionCode);
+                        }
+                    }
+
+                }
+
+                List<int> lstKeyLink = new List<int>(dicCodeWork.Keys);
+
+                foreach (int nParentCode in lstKeyLink)
                 {
-                    DataRec.ConstructionStatusFlg = m_ProgressStatus;
-                    bUpdate = true;
+                    int nChildCode = 0;
+
+                    if (dicCodeWork.TryGetValue(nParentCode, out nChildCode) == true)
+                    {
+                        // 結合（親）の工事状態を変更
+                        ClsChangeBaseInfoData.SetParentConstrStatus(ioInfo, nChildCode);
+                    }
                 }
 
-                // 変化なしは処理しない
-                if (!bUpdate) return true;
+                // DBコミット
+                ioInfo.commit();
+                ioPrgDate.commit();
 
-                if (!cbDB.UpdateAction(strSQL, DataRec)) return false;
-
+                return true;
             }
             catch (Exception ex)
             {
@@ -601,10 +940,11 @@
             }
             finally
             {
-                cbDB.close(); cbDB = null;
+                ioInfo.close(); 
+                ioInfo = null;
+                ioPrgDate.close();
+                ioPrgDate = null;
             }
-
-            return true;
         }
 
         #endregion
@@ -619,21 +959,21 @@
         /// <returns></returns>
         private bool GetRequestData(int constCode, ref RequestData data)
         {
-            var cbDB = new IORequestData();
+            //var cbDB = new IORequestData();
             try
             {
-                // 請求データ取得クラス領域
-                var wrk = new List<RequestData>();
+                //// 請求データ取得クラス領域
+                //var wrk = new List<RequestData>();
 
-                // 請求データ取得SQL
-                string strSQL = cbDB.CreateSubkeyString(constCode);
+                //// 請求データ取得SQL
+                //string strSQL = cbDB.CreateSubkeyString(constCode);
 
-                // 請求データ取得
-                if (!cbDB.SelectAction(strSQL, ref wrk)) return false;
+                //// 請求データ取得
+                //if (!cbDB.SelectAction(strSQL, ref wrk)) return false;
 
-                if (wrk.Count != 1) return false;
+                //if (wrk.Count != 1) return false;
 
-                data = wrk[0];
+                //data = wrk[0];
             }
             catch (Exception ex)
             {
@@ -642,7 +982,7 @@
             }
             finally
             {
-                cbDB.close(); cbDB = null;
+                //cbDB.close(); cbDB = null;
             }
 
             return true;
@@ -656,38 +996,38 @@
         /// <param name="requestNo"></param>
         /// <param name="datas"></param>
         /// <returns></returns>
-        private bool GetRequestTotalData(int requestNo, ref List<RequestTotalData> datas)
-        {
-            var cbDB = new IORequestTotalData();
-            try
-            {
-                // 請求書合計データ取得クラス領域
-                var wrk = new List<RequestTotalData>();
+        //private bool GetRequestTotalData(int requestNo, ref List<RequestTotalData> datas)
+        //{
+        //    var cbDB = new IORequestTotalData();
+        //    try
+        //    {
+        //        // 請求書合計データ取得クラス領域
+        //        var wrk = new List<RequestTotalData>();
 
-                // 請求書合計データ取得SQL
-                string strSQL = cbDB.CreatePrimarykeyString(requestNo);
+        //        // 請求書合計データ取得SQL
+        //        string strSQL = cbDB.CreatePrimarykeyString(requestNo);
 
-                // ソート条件追加
-                strSQL += " ORDER BY REQUESTNO, ORDERNO";
+        //        // ソート条件追加
+        //        strSQL += " ORDER BY REQUESTNO, ORDERNO";
 
-                // 請求書合計データ取得
-                if (!cbDB.SelectAction(strSQL, ref wrk)) return false;
+        //        // 請求書合計データ取得
+        //        if (!cbDB.SelectAction(strSQL, ref wrk)) return false;
 
-                // 請求書合計データ取得クラス領域
-                datas = wrk;
+        //        // 請求書合計データ取得クラス領域
+        //        datas = wrk;
 
-            }
-            catch (Exception ex)
-            {
-                logger.ErrorFormat("システムエラー：{0}：{1}", CommonMotions.GetMethodName(), ex.Message);
-                return false;
-            }
-            finally
-            {
-                cbDB.close(); cbDB = null;
-            }
-            return true;
-        }
+        //    }
+        //    catch (Exception ex)
+        //    {
+        //        logger.ErrorFormat("システムエラー：{0}：{1}", CommonMotions.GetMethodName(), ex.Message);
+        //        return false;
+        //    }
+        //    finally
+        //    {
+        //        cbDB.close(); cbDB = null;
+        //    }
+        //    return true;
+        //}
 
         #endregion
 
@@ -703,21 +1043,21 @@
             var cbDB = new IORequestDataDetail();
             try
             {
-                // 請求明細データ取得クラス領域
-                var wrk = new List<RequestDataDetail>();
+                //// 請求明細データ取得クラス領域
+                //var wrk = new List<RequestDataDetail>();
 
-                // 請求明細データ取得SQL
-                string strSQL = cbDB.CreatePrimarykeyString(requestNo);
+                //// 請求明細データ取得SQL
+                //string strSQL = cbDB.CreatePrimarykeyString(requestNo);
 
-                // 請求明細データ取得
-                if (!cbDB.SelectAction(strSQL, ref wrk)) return false;
+                //// 請求明細データ取得
+                //if (!cbDB.SelectAction(strSQL, ref wrk)) return false;
 
-                foreach (var record in wrk)
-                {
-                    if (!datas.ContainsKey(record.ConstructionCode))
-                        datas[record.ConstructionCode] = new Dictionary<int, RequestDataDetail>();
-                    datas[record.ConstructionCode][record.OrderNo] = record;
-                }
+                //foreach (var record in wrk)
+                //{
+                //    if (!datas.ContainsKey(record.ConstructionCode))
+                //        datas[record.ConstructionCode] = new Dictionary<int, RequestDataDetail>();
+                //    datas[record.ConstructionCode][record.OrderNo] = record;
+                //}
             }
             catch (Exception ex)
             {
@@ -770,6 +1110,43 @@
         }
         #endregion
 
+        #region 結合親工事番号の取得
+        private int GetJoinParentConstructionCode(int nConstructionCode)
+        {
+            int nParentCode = -1;
+            IOConstructionLink ioLink = new IOConstructionLink();
+
+            try
+            {
+                string sql = string.Format(" WHERE FluctuationCode = {0} AND LinkType = 1 ", nConstructionCode);
+                List<ConstructionLink> lstWork = new List<ConstructionLink>();
+
+                if (ioLink.SelectAction(sql, ref lstWork) == false)
+                {
+                    return nParentCode;
+                }
+
+                foreach (ConstructionLink Link in lstWork)
+                {
+                    nParentCode = Link.ConstructionCode;
+                    break;
+                }
+                return nParentCode;
+            }
+            catch (Exception ex)
+            {
+                logger.ErrorFormat("システムエラー：{0}：{1}", CommonMotions.GetMethodName(), ex.Message);
+                return -1;
+            }
+            finally
+            {
+                ioLink.close(); 
+                ioLink = null;
+            }
+
+        }
+        #endregion
+
         #region 工事基本情報明細
         /// <summary>
         /// 工事基本情報明細を工事基本情報明細テーブルから工事番号をキーに取得する関数
@@ -913,20 +1290,6 @@
         {
             try
             {
-                // 請求明細データ取得
-                var dicReqDetail = new Dictionary<int, Dictionary<int, RequestDataDetail>>();
-                if (!GetRequestDataDetail(m_RequestNo,ref dicReqDetail))
-                {
-                    return;
-                }
-
-                // 工事詳細台帳データ取得
-                var constLedger = new ConstructionLedger();
-                if (!GetConstructionLedger(m_ConstructionCode, ref constLedger))
-                {
-                    return;
-                }
-
                 // 印刷クラス
                 m_UsedExcel = new UsedExcel();
 
@@ -943,13 +1306,56 @@
                     return;
                 }
 
-                // 内訳印刷
-                rtAns = PrintDetail(dicReqDetail, constLedger);
+                // 一覧印刷
+                rtAns = PrintList();
                 if (rtAns != CommonDefine.RetunAnswer.Answer0)
                 {
                     return;
                 }
 
+
+                //private Dictionary<int, List<RequestData>> m_dicReqData = new Dictionary<int, List<RequestData>>();
+
+
+                foreach (RequestHead ReqHead in m_lstReqHead)
+                {
+                    List<RequestData> lstReqData = null;
+                    if (m_dicReqData.TryGetValue(ReqHead.RequestNo, out lstReqData) == false)
+                    {
+                        return;
+                    }
+
+                    foreach (RequestData ReqData in lstReqData)
+                    {
+                        ConstructionBaseInfo Info = null;
+
+                        if (m_dicConstructionBaseInfo.TryGetValue(ReqData.MainConstructionCode, out Info) == false)
+                        {
+                            return;
+                        }
+
+                        int nRequestAmount = ReqData.RequestAmount0;
+                        nRequestAmount += ReqData.RequestAmount1;
+                        nRequestAmount += ReqData.RequestAmount2;
+                        nRequestAmount += ReqData.RequestAmount3;
+                        nRequestAmount += ReqData.RequestAmount4;
+                        nRequestAmount += ReqData.RequestAmount5;
+                        nRequestAmount += ReqData.RequestAmount6;
+
+                        if (nRequestAmount == 0)
+                        {
+                            continue;
+                        }
+
+                        rtAns = PrintDetail( ReqHead, ReqData, Info );
+                        if (rtAns != CommonDefine.RetunAnswer.Answer0)
+                        {
+                            return;
+                        }
+                    }
+
+                }
+
                 if (bPrint)
                 {
                     // 印刷処理
@@ -981,6 +1387,7 @@
         }
         #endregion
 
+        #region Excelファイル保存処理
         /// <summary>
         /// Excelファイル保存処理
         /// </summary>
@@ -994,7 +1401,7 @@
                 if (CommonMotions.ChkDirPath(filePath, true))
                 {
                     // ファイル名を作成
-                    string wrkFile = m_DicConstructionBaseInfoDetail[m_ConstructionCode][(int)ConstructionBaseInfoDetail.DetailDataNo.OrderersName] + "様 請求書";
+                    string wrkFile = m_InvData.RequestName + "様 請求書";
 
                     // ファイル名に使用できない文字を取り除く
                     foreach (var badCh in m_UsedExcel.ExcelBadCharcter)
@@ -1017,7 +1424,9 @@
             }
 
         }
+        #endregion
 
+        #region 請求書(表紙)作成
         /// <summary>
         /// 請求書(表紙)作成
         /// </summary>
@@ -1026,40 +1435,43 @@
         {
             try
             {
-                // 請求書表紙シートの取得
+                //// 請求書表紙シートの取得
                 m_UsedExcel.ExcelSheetGet(s_DicSheetName[enumSheetName.Cover]);
 
-                // ページ縦・横セット
-                m_UsedExcel.ExcelFitCountSet(2, 1);
+                //// ③ 請求日(4行目 K列)
+                if (m_bDatePrintFlg == true)
+                {
+                    ExcelPrintData reqDate = new ExcelPrintData();
+                    reqDate.AddPrintData("K", 3, dateTimePicker1.Value.ToString("yyyy年MM月dd日")).ExcelCellSet(m_UsedExcel);
+                }
+                else
+                {
+                    ExcelPrintData reqDate = new ExcelPrintData();
+                    reqDate.AddPrintData("K", 3, "　　年　　月　　日").ExcelCellSet(m_UsedExcel);
+                }
 
-                // ① 施工開始日(4行目 M列)
-                ExcelPrintData startDate = new ExcelPrintData();
-                startDate.AddPrintData("L", 3, m_ConstructionBaseInfo.ConstructionStartingDate.ToString("yyyy年MM月dd日")).ExcelCellSet(m_UsedExcel);
-
-                // ② 施工終了日(5行目 M列)
-                ExcelPrintData endDate = new ExcelPrintData();
-                endDate.AddPrintData("L", 4, m_ConstructionBaseInfo.ConstructionCompletionDate.ToString("yyyy年MM月dd日")).ExcelCellSet(m_UsedExcel);
-
-                // ③ 請求日(7行目 K列)
-                ExcelPrintData reqDate = new ExcelPrintData();
-                reqDate.AddPrintData("K", 6, radioButton4.Checked ? dateTimePicker1.Value.ToString("yyyy年MM月dd日") : "　　年　　月　　日").ExcelCellSet(m_UsedExcel);
-
-                // ④ 請求先名称(9行目 D列)
+                //// ④ 請求先名称(6行目 D列)
                 ExcelPrintData nameData = new ExcelPrintData();
-                nameData.AddPrintData("D", 8, m_DicConstructionBaseInfoDetail[m_ConstructionCode][(int)ConstructionBaseInfoDetail.DetailDataNo.OrderersName]).ExcelCellSet(m_UsedExcel);
+                nameData.AddPrintData("D", 5, m_InvData.RequestName).ExcelCellSet(m_UsedExcel);
 
-                // ⑤ 請求金額(14行目 G列)
+                //// ⑤ 請求金額(11行目 G列)
                 ExcelPrintData priceData = new ExcelPrintData();
-                priceData.AddPrintData("G", 13, m_LstRequestTotalData[m_SelectOrderIndex].BillTotalPrice.ToString("#,#")).ExcelCellSet(m_UsedExcel);
+                priceData.AddPrintData("G", 10, m_InvData.TotalAmount.ToString("#,0")).ExcelCellSet(m_UsedExcel);
 
-                // ⑥ 消費税(15行目 J列)
+                //// ⑥ 消費税(12行目 J列)
                 ExcelPrintData taxData = new ExcelPrintData();
-                taxData.AddPrintData("J", 14, m_LstRequestTotalData[m_SelectOrderIndex].TaxPrice.ToString("#,#")).ExcelCellSet(m_UsedExcel);
+                taxData.AddPrintData("J", 11, m_InvData.TaxAmount.ToString("#,0")).ExcelCellSet(m_UsedExcel);
 
-                // ⑦ 工事件名(17行目 G列)
-                ExcelPrintData constNameData = new ExcelPrintData();
-                constNameData.AddPrintData("G", 16, m_DicConstructionBaseInfoDetail[m_ConstructionCode][(int)ConstructionBaseInfoDetail.DetailDataNo.ConstructionName]).ExcelCellSet(m_UsedExcel);
+                string[] comment = new string[]{ m_InvData.Comment1, m_InvData.Comment2, m_InvData.Comment3, m_InvData.Comment4, m_InvData.Comment5 };
 
+                for( int i=0; i<5; i++ )
+                {
+                    //// ⑦ コメント1(14行目 G列)
+                    ExcelPrintData constNameData = new ExcelPrintData();
+                    constNameData.AddPrintData("G", 13+i, comment[i]).ExcelCellSet(m_UsedExcel);
+
+                }
+
                 return CommonDefine.RetunAnswer.Answer0;
             }
             catch (Exception ex)
@@ -1068,141 +1480,192 @@
                 return CommonDefine.RetunAnswer.Answer1;
             }
         }
+        #endregion
 
+        #region 請求書(一覧)作成
         /// <summary>
-        /// 請求書(内訳)作成
+        /// 請求書(一覧)作成
         /// </summary>
-        /// <param name="dicReqDetail"></param>
-        /// <param name="constLedger"></param>
-        /// <param name="lstConstLink"></param>
         /// <returns></returns>
-        private CommonDefine.RetunAnswer PrintDetail(Dictionary<int,Dictionary<int,RequestDataDetail>> dicReqDetail, ConstructionLedger constLedger)
+        private CommonDefine.RetunAnswer PrintList()
         {
             try
             {
-                // 請求書内訳シートの取得
-                m_UsedExcel.ExcelSheetGet(s_DicSheetName[enumSheetName.Detail]);
+                int trow = 3;
+                ExcelPrintData ExcelPrnData = null;
 
-                // ページ縦・横セット
-                m_UsedExcel.ExcelFitCountSet(2, 1);
+                //// 請求書表紙シートの取得
+                m_UsedExcel.ExcelSheetGet(s_DicSheetName[enumSheetName.List]);
 
-                // ------------------------------- 工事名 -------------------------------
-                // ① 工事件名
-                ExcelPrintData constNameData = new ExcelPrintData();
-                constNameData.AddPrintData("C", 2, m_DicConstructionBaseInfoDetail[m_ConstructionCode][(int)ConstructionBaseInfoDetail.DetailDataNo.ConstructionName]).ExcelCellSet(m_UsedExcel);
+                List<int> lstKey = new List<int>(m_dicReqData.Keys);
 
-                // ------------------------------- 名称列 -------------------------------
-                ExcelPrintData nameDatas = new ExcelPrintData();
+                foreach (int nReqNo in lstKey)
+                {
+                    List<RequestData> lstData = null;
 
-                // 増減工事情報
-                foreach (int childConstCode in m_LstConstructionLink)
-                {
-                    if (m_DicConstructionBaseInfoDetail.ContainsKey(childConstCode))
+                    if (m_dicReqData.TryGetValue(nReqNo, out lstData) == false)
                     {
-                        // ⑤ 工事件名
-                        nameDatas.AddPrintData("B", 10 + m_LstConstructionLink.IndexOf(childConstCode), m_DicConstructionBaseInfoDetail[childConstCode][(int)ConstructionBaseInfoDetail.DetailDataNo.ConstructionName]);
+                        continue;
                     }
-                }
-                nameDatas.ExcelCellSet(m_UsedExcel);
 
-                // ------------------------------- 仕様列 -------------------------------
-                ExcelPrintData spaceData1 = new ExcelPrintData();
+                    foreach (RequestData ReqData in lstData)
+                    {
+                        ConstructionBaseInfo Info = null;
 
-                // 増減工事情報
-                // ６行に満たない場合は、残り行は空白とする
-                for (int i = 0; i < (6 - m_LstConstructionLink.Count); i++)
-                {
-                    spaceData1.AddPrintData("C", 15 - i, "");
-                    spaceData1.AddPrintData("D", 15 - i, "");
-                    spaceData1.AddPrintData("E", 15 - i, "");
-                }
-                spaceData1.ExcelCellSet(m_UsedExcel);
+                        if (m_dicConstructionBaseInfo.TryGetValue(ReqData.MainConstructionCode, out Info) == false)
+                        {
+                            continue;
+                        }
 
-                // ------------------------------- 仕様列 -------------------------------
-                // ⑪ 消費税率
-                ExcelPrintData taxData = new ExcelPrintData();
-                taxData.AddPrintData("C", 24, string.Format("{0}%", CommonMotions.SystemMasterData.ConsumptionTax)).ExcelCellSet(m_UsedExcel);
+                        ExcelPrnData = new ExcelPrintData();
+                        ExcelPrnData.AddPrintData("B", trow, ReqData.ConstructionName);             // 工事件名
+                        ExcelPrnData.AddPrintData("C", trow, Info.ConstructionPeriodStart.ToString("yyyy/MM/dd"));        // 工期開始
+                        ExcelPrnData.AddPrintData("C", trow + 1, "～");
+                        ExcelPrnData.AddPrintData("C", trow + 2, Info.ConstructionPeriodEnd.ToString("yyyy/MM/dd"));      // 工期終了
 
+                        int nAmount = ReqData.RequestAmount0;
+                        nAmount += ReqData.RequestAmount1;
+                        nAmount += ReqData.RequestAmount2;
+                        nAmount += ReqData.RequestAmount3;
+                        nAmount += ReqData.RequestAmount4;
+                        nAmount += ReqData.RequestAmount5;
+                        nAmount += ReqData.RequestAmount6;
+                        nAmount += ReqData.TaxAmount;
+                        nAmount += ReqData.UnpaidAmount;
 
-                // ------------------------------- 金額列 -------------------------------
-                // 金額列
-                ExcelPrintData priceData = new ExcelPrintData();
+                        ExcelPrnData.AddPrintData("D", trow, nAmount.ToString("#,0"));       // 請求金額
 
-                // ② 請負金額
-                priceData.AddPrintData("G", 5, constLedger.OrdersDecisionPrice);
+                        ExcelPrnData.AddPrintData("E", trow, ReqData.Note);                                             // 備考
+                        ExcelPrnData.ExcelCellSet(m_UsedExcel);
 
-                // ④ 見積もり金額
-                priceData.AddPrintData("G", 9, dicReqDetail[m_ConstructionCode][m_SelectOrderIndex + 1].BillPrice);
+                        trow += 3;
 
-                // 増減工事情報
-                foreach (int childConstCode in m_LstConstructionLink)
-                {
-                    if (dicReqDetail.ContainsKey(childConstCode))
-                    {
-                        // ⑥ 見積金額
-                        priceData.AddPrintData("G", 10 + m_LstConstructionLink.IndexOf(childConstCode), dicReqDetail[childConstCode][m_SelectOrderIndex + 1].BillPrice);
                     }
                 }
 
-                // ⑦ 今回ご請求分
-                priceData.AddPrintData("G", 17, m_LstRequestTotalData[m_SelectOrderIndex].BillPrice);
+                return CommonDefine.RetunAnswer.Answer0;
+            }
+            catch (Exception ex)
+            {
+                logger.ErrorFormat("システムエラー：{0}：{1}", CommonMotions.GetMethodName(), ex.Message);
+                return CommonDefine.RetunAnswer.Answer1;
+            }
+        }
+        #endregion
 
-                if (dicReqDetail[m_ConstructionCode][m_SelectOrderIndex + 1].AmountBlance != 0)
+        #region 請求書(内訳)作成
+        /// <summary>
+        /// 請求書(内訳)作成
+        /// </summary>
+        /// <param name="dicReqDetail"></param>
+        /// <param name="constLedger"></param>
+        /// <param name="lstConstLink"></param>
+        /// <returns></returns>
+        private CommonDefine.RetunAnswer PrintDetail(RequestHead ReqHead, RequestData ReqData, ConstructionBaseInfo Info)
+        {
+            try
+            {
+                // 請求書内訳シートの取得
+                m_UsedExcel.ExcelSheetGet(s_DicSheetName[enumSheetName.Detail]);
+
+                ExcelPrintData ExcelPrnData = null;
+
+                // ------------------------------- 工事名 -------------------------------
+                // ① 工事件名
+                ExcelPrnData = new ExcelPrintData();
+                ExcelPrnData.AddPrintData("C", 2, ReqData.ConstructionName).ExcelCellSet(m_UsedExcel);
+
+                // ------------------------------- 請負金額 -------------------------------
+                ExcelPrnData = new ExcelPrintData();
+                ExcelPrnData.AddPrintData("G", 5, ReqData.ContractAmount.ToString("#,0")).ExcelCellSet(m_UsedExcel); 
+
+                // ------------------------------- 前回ご請求分 -------------------------------
+                // 分割払いの場合
+                if (Info.BillingSplitFlg == (int)CommonDefine.BaseInfoBillingSplitFlg.SplitBilling)
                 {
-                    // ⑨ 未入金分
-                    priceData.AddPrintData("G", 21, dicReqDetail[m_ConstructionCode][m_SelectOrderIndex + 1].AmountBlance);
+                    ExcelPrnData = new ExcelPrintData();
+                    ExcelPrnData.AddPrintData("B", 7, "前回ご請求済分");
+                    ExcelPrnData.AddPrintData("C", 7, "前回請求書参照※増減補正済み");
+                    ExcelPrnData.AddPrintData("D", 7, "1");
+                    ExcelPrnData.AddPrintData("E", 7, "式");
+                    ExcelPrnData.AddPrintData("G", 7, ReqData.PaidAmount.ToString("#,0"));
+                    ExcelPrnData.ExcelCellSet(m_UsedExcel);
                 }
-                else
-                {
-                    // ⑨ 未入金分が０の場合は空白行とする
-                    ExcelPrintData spaceData2 = new ExcelPrintData();
-                    spaceData2.AddPrintData("B", 21, "").ExcelCellSet(m_UsedExcel);
-                }
 
-                // ⑩ 小計
-                int partTotal = m_LstRequestTotalData[m_SelectOrderIndex].BillPrice + m_LstRequestTotalData[m_SelectOrderIndex].AmountBlance;
-                priceData.AddPrintData("G", 23, partTotal);
+                int nTotalAmount = 0;
 
-                // ⑫ 消費税
-                priceData.AddPrintData("G", 24, m_LstRequestTotalData[m_SelectOrderIndex].TaxPrice);
+                // ------------------------------- 見積金額（本工事） -------------------------------
+                ExcelPrnData = new ExcelPrintData();
+                ExcelPrnData.AddPrintData("G", 9, ReqData.RequestAmount0.ToString("#,0"));
+                ExcelPrnData.ExcelCellSet(m_UsedExcel);
 
-                // ⑬ 税込合計金額
-                priceData.AddPrintData("G", 25, m_LstRequestTotalData[m_SelectOrderIndex].BillTotalPrice);
+                nTotalAmount += ReqData.RequestAmount0;
+ 
+                // ------------------------------- 見積金額（増減工事） -------------------------------
+                int[] nAmount = new int[] { ReqData.RequestAmount1, ReqData.RequestAmount2, ReqData.RequestAmount3, ReqData.RequestAmount4, ReqData.RequestAmount5, ReqData.RequestAmount6 };
+                string[] strTitle = new string[] { "増減工事１", "増減工事２", "増減工事３", "増減工事４", "増減工事５", "増減工事６" };
 
-                // 一括請求時は次を印刷対象外とする
-                if (m_ConstructionBaseInfo.BillingSplitFlg != 0)
+                for (int i = 0; i < 6; i++)
                 {
-                    if (m_SelectOrderIndex != 0)
+                    if (nAmount[i] > 0)
                     {
-                        // ③ 請求済金額
-                        priceData.AddPrintData("G", 7, m_LstRequestTotalData[m_SelectOrderIndex - 1].PricePaid);
+                        ExcelPrnData = new ExcelPrintData();
+                        ExcelPrnData.AddPrintData("B", 10 + i, strTitle[i]);
+                        ExcelPrnData.AddPrintData("C", 10 + i, "追加増減見積もり参照");
+                        ExcelPrnData.AddPrintData("D", 10 + i, "1");
+                        ExcelPrnData.AddPrintData("E", 10 + i, "式");
+                        ExcelPrnData.AddPrintData("G", 10 + i, nAmount[i].ToString("#,0"));
+                        ExcelPrnData.ExcelCellSet(m_UsedExcel);
+
+                        nTotalAmount += nAmount[i];
                     }
+                }
 
-                    // ⑧ 請負金額残額
-                    priceData.AddPrintData("G", 19, m_LstRequestTotalData[m_SelectOrderIndex].PriceBalance);
+                // ------------------------------- 今回ご請求分 -------------------------------
+                ExcelPrnData = new ExcelPrintData();
+                ExcelPrnData.AddPrintData("G", 17, nTotalAmount.ToString("#,0"));
+                ExcelPrnData.ExcelCellSet(m_UsedExcel);
+
+                // ------------------------------- 請負金額残金 -------------------------------
+                // 分割払いの場合
+                if (Info.BillingSplitFlg == (int)CommonDefine.BaseInfoBillingSplitFlg.SplitBilling)
+                {
+                    ExcelPrnData = new ExcelPrintData();
+                    ExcelPrnData.AddPrintData("B", 19, "請負金額残金");
+                    ExcelPrnData.AddPrintData("D", 19, "1");
+                    ExcelPrnData.AddPrintData("E", 19, "式");
+                    ExcelPrnData.AddPrintData("G", 19, ReqData.UnclaimedAmount.ToString("#,0"));
+                    ExcelPrnData.ExcelCellSet(m_UsedExcel);
                 }
-                else
+
+                // ------------------------------- 未入金分 -------------------------------
+                if (ReqData.UnpaidAmount > 0)
                 {
-                    // 一括払いの場合は空白行とする
-                    ExcelPrintData spaceData3 = new ExcelPrintData();
+                    ExcelPrnData = new ExcelPrintData();
+                    ExcelPrnData.AddPrintData("B", 21, "未入金分");
+                    ExcelPrnData.AddPrintData("G", 21, ReqData.UnpaidAmount.ToString("#,0"));
+                    ExcelPrnData.ExcelCellSet(m_UsedExcel);
 
-                    // ③ 請求済金額
-                    spaceData3.AddPrintData("B", 7, "");
-                    spaceData3.AddPrintData("C", 7, "");
-                    spaceData3.AddPrintData("D", 7, "");
-                    spaceData3.AddPrintData("E", 7, "");
-                    spaceData3.ExcelCellSet(m_UsedExcel);
-
-                    // ⑧ 請負金額残額
-                    ExcelPrintData spaceData4 = new ExcelPrintData();
-                    spaceData4.AddPrintData("B", 19, "");
-                    spaceData4.AddPrintData("D", 19, "");
-                    spaceData4.AddPrintData("E", 19, "");
-                    spaceData4.ExcelCellSet(m_UsedExcel);
+                    nTotalAmount += ReqData.UnpaidAmount;
                 }
 
-                priceData.ExcelCellSet(m_UsedExcel);
+                // ------------------------------- 小計 -------------------------------
+                ExcelPrnData = new ExcelPrintData();
+                ExcelPrnData.AddPrintData("G", 23, nTotalAmount.ToString("#,0"));
+                ExcelPrnData.ExcelCellSet(m_UsedExcel);
 
+                // ------------------------------- 消費税 -------------------------------
+                ExcelPrnData = new ExcelPrintData();
+                ExcelPrnData.AddPrintData("C", 24, string.Format("{0}%",CommonMotions.SystemMasterData.ConsumptionTax));
+                ExcelPrnData.AddPrintData("G", 24, ReqData.TaxAmount.ToString("#,0"));
+                ExcelPrnData.ExcelCellSet(m_UsedExcel);
+                nTotalAmount += ReqData.TaxAmount;
+
+                // ------------------------------- 税込金額合計 -------------------------------
+                ExcelPrnData = new ExcelPrintData();
+                ExcelPrnData.AddPrintData("G", 25, nTotalAmount.ToString("#,0"));
+                ExcelPrnData.ExcelCellSet(m_UsedExcel);
+
                 return CommonDefine.RetunAnswer.Answer0;
             }
             catch (Exception ex)
@@ -1212,7 +1675,9 @@
             }
 
         }
+        #endregion
 
+        #region Excelデータ出力用内部クラス定義
         /// <summary>
         /// Excelデータ出力用内部クラス定義
         /// </summary>
@@ -1272,6 +1737,7 @@
                 return res;
             }
 
+            #region データ追加
             /// <summary>
             /// データ追加
             /// </summary>
@@ -1283,7 +1749,9 @@
             {
                 return AddPrintData(s_IndexOfExcelColumn[colName], rowNo, data);
             }
+            #endregion
 
+            #region データ追加
             /// <summary>
             /// データ追加
             /// </summary>
@@ -1305,7 +1773,9 @@
 
                 return this;
             }
+            #endregion
 
+            #region UsedExcelオブジェクトにデータをセットする
             /// <summary>
             /// UsedExcelオブジェクトにデータをセットする
             /// </summary>
@@ -1340,7 +1810,10 @@
                 usedExcel.ExcelCellSet(startCell, objCells, endCell);
 
             }
+            #endregion
         }
+        #endregion
 
+
     }
 }
Index: branches/src/ProcessManagement/ProcessManagement/Forms/ZMenu/FrmMenu.cs
===================================================================
--- branches/src/ProcessManagement/ProcessManagement/Forms/ZMenu/FrmMenu.cs	(revision 59)
+++ branches/src/ProcessManagement/ProcessManagement/Forms/ZMenu/FrmMenu.cs	(revision 60)
@@ -564,7 +564,7 @@
                                                                 { (int)ClsExcute.MaintenanceExecuteNo.SaleSalesGraphData,
                                                                     0,
                                                                     0,
-                                                                    0
+                                                                    (int)ClsExcute.MaintenanceExecuteNo.SalesConfirm
                                                                 },
         };
         #endregion
@@ -2448,13 +2448,22 @@
                                 #region 請求書入力（出来高）
                                 // 請求書入力（出来高）→分割
                                 NowPoint = ClsExcute.NextProcess((int)ClsExcute.ProcessExecuteNo.RequestInput);
-                                ClsExcute.ProcControlPara[NowPoint].IntExecParameter.Add((int)FrmConstructionDiag.SelectConstructionType.SeparateBilling);
+
+                                ClsExcute.ProcControlPara[NowPoint].IntExecParameter.Add(0);                   // 工事番号（ダミー）
+                                ClsExcute.ProcControlPara[NowPoint].IntExecParameter.Add(0);                   // 承認機能番号（ダミー）
+                                ClsExcute.ProcControlPara[NowPoint].IntExecParameter.Add(0);                   // 受付番号（ダミー）
+                                ClsExcute.ProcControlPara[NowPoint].IntExecParameter.Add((int)FrmConstructionDiag.SelectConstructionType.SeparateBilling);   // 分割払い
+                                ClsExcute.ProcControlPara[NowPoint].BoolExecParameter.Add(false);               // ----- 直接表示フラグ
                                 break;
                                 #endregion
                             case 3:
                                 break;
-                            case 5:
+                            case 5:                         // 請求書印刷
+                                #region 請求書印刷
+                                // 請求書印刷
+                                NowPoint = ClsExcute.NextProcess((int)ClsExcute.ProcessExecuteNo.RequestPrint);
                                 break;
+                                #endregion
                             case 7:
                                 break;
                             case 9:
@@ -2487,13 +2496,21 @@
                                 #region 請求書入力（完了後）
                                 // 請求書入力→一括
                                 NowPoint = ClsExcute.NextProcess((int)ClsExcute.ProcessExecuteNo.RequestInput);
-                                ClsExcute.ProcControlPara[NowPoint].IntExecParameter.Add((int)FrmConstructionDiag.SelectConstructionType.CombinedOrder);
+                                ClsExcute.ProcControlPara[NowPoint].IntExecParameter.Add(0);                   // 工事番号（ダミー）
+                                ClsExcute.ProcControlPara[NowPoint].IntExecParameter.Add(0);                   // 承認機能番号（ダミー）
+                                ClsExcute.ProcControlPara[NowPoint].IntExecParameter.Add(0);                   // 受付番号（ダミー）
+                                ClsExcute.ProcControlPara[NowPoint].IntExecParameter.Add((int)FrmConstructionDiag.SelectConstructionType.CombinedOrder);   // 一括払い
+                                ClsExcute.ProcControlPara[NowPoint].BoolExecParameter.Add(false);               // ----- 直接表示フラグ
                                 break;
                                 #endregion
                             case 3:
                                 break;
-                            case 5:
+                            case 5:                 // 請求書印刷
+                                #region 請求書印刷
+                                // 請求書印刷
+                                NowPoint = ClsExcute.NextProcess((int)ClsExcute.ProcessExecuteNo.RequestPrint);
                                 break;
+                                #endregion
                             case 7:
                                 break;
                             case 9:
Index: branches/src/ProcessManagement/ProcessManagement/Forms/ZMenu/FrmMenuAuxiliary.cs
===================================================================
--- branches/src/ProcessManagement/ProcessManagement/Forms/ZMenu/FrmMenuAuxiliary.cs	(revision 59)
+++ branches/src/ProcessManagement/ProcessManagement/Forms/ZMenu/FrmMenuAuxiliary.cs	(revision 60)
@@ -1483,7 +1483,7 @@
                 strSQL += " A.ApprovalLimitDates,";
                 strSQL += " A.PERSONCODE,";
                 strSQL += " C.PERSONNAME,";
-                strSQL += " D.DETAILSTRING,";
+                strSQL += " CASE A.ORDERNO WHEN 1 THEN D.DETAILSTRING ELSE CONCAT(D.DETAILSTRING, '(', CAST( A.ORDERNO AS CHAR), ')') END, ";
                 strSQL += " C.DEPARTMENTCODE,";
                 strSQL += " E.APPROVALPERSON,";
                 strSQL += " E.DISPLAYORDER,";
@@ -1524,7 +1524,7 @@
                 //    }
                 //}
 
-                strSQL += " ORDER BY A.APPROVALCODE DESC, A.PETITIONAPPROVALDATE DESC, A.PERSONCODE ASC, E.DISPLAYORDER DESC";
+                strSQL += " ORDER BY A.APPROVALCODE DESC, A.ORDERNO DESC, A.CONSTRUCTIONCODE DESC, A.PETITIONAPPROVALDATE DESC, A.PERSONCODE ASC, E.DISPLAYORDER DESC";
                 if (!paDB.ExecuteReader(strSQL, ref arData)) return false;
 
                 //if (arData.Count == 0) return false;
@@ -1640,11 +1640,13 @@
                 ArrayList BufferList = new ArrayList();
                 object[] objfirst = (object[])arData[0];
                 int BreakApprovalCode = CommonMotions.cnvInt(objfirst[(int)ApprovalDataList.ApprovalCode]);
+                int BreakOrderNo = CommonMotions.cnvInt(objfirst[(int)ApprovalDataList.OrderNo]);
                 int BreakConstructionCode = CommonMotions.cnvInt(objfirst[(int)ApprovalDataList.ConstructionCode]);
 
                 foreach (object[] objLoopRec in arData)
                 {
                     if (BreakApprovalCode == CommonMotions.cnvInt(objLoopRec[(int)ApprovalDataList.ApprovalCode])
+                        && BreakOrderNo == CommonMotions.cnvInt(objLoopRec[(int)ApprovalDataList.OrderNo])
                         && BreakConstructionCode == CommonMotions.cnvInt(objLoopRec[(int)ApprovalDataList.ConstructionCode]))
                     {
                         BufferList.Add(objLoopRec);
@@ -1656,6 +1658,7 @@
 
                     // ブレイクキー更新
                     BreakApprovalCode = CommonMotions.cnvInt(objLoopRec[(int)ApprovalDataList.ApprovalCode]);
+                    BreakOrderNo = CommonMotions.cnvInt(objLoopRec[(int)ApprovalDataList.OrderNo]);
                     BreakConstructionCode = CommonMotions.cnvInt(objLoopRec[(int)ApprovalDataList.ConstructionCode]);
                     BufferList.Clear();
                     BufferList.Add(objLoopRec);
Index: branches/src/ProcessManagement/ProcessManagement/ProcessManagement.csproj
===================================================================
--- branches/src/ProcessManagement/ProcessManagement/ProcessManagement.csproj	(revision 59)
+++ branches/src/ProcessManagement/ProcessManagement/ProcessManagement.csproj	(revision 60)
@@ -142,6 +142,7 @@
     <Compile Include="DataModel\DepositApprovalInfo.cs" />
     <Compile Include="DataModel\DepositData.cs" />
     <Compile Include="DataModel\DepositDataDetail.cs" />
+    <Compile Include="DataModel\InvoiceData.cs" />
     <Compile Include="DataModel\MaterialInfo.cs" />
     <Compile Include="DataModel\MaterialItemMaster.cs" />
     <Compile Include="DataModel\MaterialKindMaster.cs" />
@@ -176,7 +177,7 @@
     <Compile Include="DataModel\RequestData.cs" />
     <Compile Include="DataModel\RequestDataDetail.cs" />
     <Compile Include="DataModel\RequestGridKeys.cs" />
-    <Compile Include="DataModel\RequestTotalData.cs" />
+    <Compile Include="DataModel\RequestHead.cs" />
     <Compile Include="DataModel\SubContractorJobCategory.cs" />
     <Compile Include="DataModel\SubContractorJobILink.cs" />
     <Compile Include="DataModel\SuppliersMaster.cs" />
@@ -192,6 +193,7 @@
     <Compile Include="DB\IOAccess\IODepositApprovalInfo.cs" />
     <Compile Include="DB\IOAccess\IODepositData.cs" />
     <Compile Include="DB\IOAccess\IODepositDataDetail.cs" />
+    <Compile Include="DB\IOAccess\IOInvoiceData.cs" />
     <Compile Include="DB\IOAccess\IOMaterialInfo.cs" />
     <Compile Include="DB\IOAccess\IOMaterialItem.cs" />
     <Compile Include="DB\IOAccess\IOMaterialRecordInfo.cs" />
@@ -206,7 +208,7 @@
     <Compile Include="DB\IOAccess\IOProcessApprovalDetail.cs" />
     <Compile Include="DB\IOAccess\IORequestData.cs" />
     <Compile Include="DB\IOAccess\IORequestDataDetail.cs" />
-    <Compile Include="DB\IOAccess\IORequestTotalData.cs" />
+    <Compile Include="DB\IOAccess\IORequestHead.cs" />
     <Compile Include="DB\MySql\MySqlProcess.cs" />
     <Compile Include="Forms\DataEntry\ConstructionBaseInfo\DataChange.cs">
       <SubType>Form</SubType>
@@ -507,6 +509,18 @@
     <Compile Include="Forms\DataEntry\Request\FrmSelectRequest.Designer.cs">
       <DependentUpon>FrmSelectRequest.cs</DependentUpon>
     </Compile>
+    <Compile Include="Forms\DataEntry\Request\RequestEntry\FrmEntryReqSelOrderer.cs">
+      <SubType>Form</SubType>
+    </Compile>
+    <Compile Include="Forms\DataEntry\Request\RequestEntry\FrmEntryReqSelOrderer.Designer.cs">
+      <DependentUpon>FrmEntryReqSelOrderer.cs</DependentUpon>
+    </Compile>
+    <Compile Include="Forms\DataEntry\Request\RequestEntry\FrmEntryReqSelRequest.cs">
+      <SubType>Form</SubType>
+    </Compile>
+    <Compile Include="Forms\DataEntry\Request\RequestEntry\FrmEntryReqSelRequest.Designer.cs">
+      <DependentUpon>FrmEntryReqSelRequest.cs</DependentUpon>
+    </Compile>
     <Compile Include="Forms\DataEntry\Request\RequestInput\FrmRequestInput.cs">
       <SubType>Form</SubType>
     </Compile>
@@ -516,9 +530,6 @@
     <Compile Include="Forms\DataEntry\Request\RequestInput\FrmRequestInputAuxiliary.cs">
       <SubType>Form</SubType>
     </Compile>
-    <Compile Include="Forms\DataEntry\Request\RequestInput\FrmRequestInputDefinitions.cs">
-      <SubType>Form</SubType>
-    </Compile>
     <Compile Include="Forms\DataEntry\Request\RequestInput\ProcessControl.cs">
       <SubType>Form</SubType>
     </Compile>
@@ -531,6 +542,12 @@
     <Compile Include="Forms\DataEntry\Request\RequestSummaryList\FrmRequestSummaryListAuxiliary.cs">
       <SubType>Form</SubType>
     </Compile>
+    <Compile Include="Forms\DataEntry\Request\SalesConfirm\FrmSalesConfirm.cs">
+      <SubType>Form</SubType>
+    </Compile>
+    <Compile Include="Forms\DataEntry\Request\SalesConfirm\FrmSalesConfirm.Designer.cs">
+      <DependentUpon>FrmSalesConfirm.cs</DependentUpon>
+    </Compile>
     <Compile Include="Forms\DataEntry\Request\SelectPayment\FrmSelectPayment.cs">
       <SubType>Form</SubType>
     </Compile>
@@ -1208,6 +1225,12 @@
     <EmbeddedResource Include="Forms\DataEntry\Request\FrmSelectRequest.resx">
       <DependentUpon>FrmSelectRequest.cs</DependentUpon>
     </EmbeddedResource>
+    <EmbeddedResource Include="Forms\DataEntry\Request\RequestEntry\FrmEntryReqSelOrderer.resx">
+      <DependentUpon>FrmEntryReqSelOrderer.cs</DependentUpon>
+    </EmbeddedResource>
+    <EmbeddedResource Include="Forms\DataEntry\Request\RequestEntry\FrmEntryReqSelRequest.resx">
+      <DependentUpon>FrmEntryReqSelRequest.cs</DependentUpon>
+    </EmbeddedResource>
     <EmbeddedResource Include="Forms\DataEntry\Request\RequestInput\FrmRequestInput.resx">
       <DependentUpon>FrmRequestInput.cs</DependentUpon>
     </EmbeddedResource>
@@ -1214,6 +1237,9 @@
     <EmbeddedResource Include="Forms\DataEntry\Request\RequestSummaryList\FrmRequestSummaryList.resx">
       <DependentUpon>FrmRequestSummaryList.cs</DependentUpon>
     </EmbeddedResource>
+    <EmbeddedResource Include="Forms\DataEntry\Request\SalesConfirm\FrmSalesConfirm.resx">
+      <DependentUpon>FrmSalesConfirm.cs</DependentUpon>
+    </EmbeddedResource>
     <EmbeddedResource Include="Forms\DataEntry\Request\SelectPayment\FrmSelectPayment.resx">
       <DependentUpon>FrmSelectPayment.cs</DependentUpon>
     </EmbeddedResource>
@@ -1464,8 +1490,6 @@
       <DependentUpon>Resources.resx</DependentUpon>
       <DesignTime>True</DesignTime>
     </Compile>
-    <None Include="DB\Core\ABaseDBProcess.cs.bak" />
-    <None Include="DB\Core\DBCommon.cs.bak" />
     <None Include="ProcessManage001.doc">
       <CopyToOutputDirectory>Always</CopyToOutputDirectory>
     </None>
Index: branches/src/ProcessManagement/ProcessManagement/ProcessManagement.csproj.user
===================================================================
--- branches/src/ProcessManagement/ProcessManagement/ProcessManagement.csproj.user	(revision 59)
+++ branches/src/ProcessManagement/ProcessManagement/ProcessManagement.csproj.user	(revision 60)
@@ -3,7 +3,7 @@
   <PropertyGroup>
     <ReferencePath>
     </ReferencePath>
-    <ProjectView>ProjectFiles</ProjectView>
+    <ProjectView>ShowAllFiles</ProjectView>
   </PropertyGroup>
   <PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'Debug|AnyCPU'">
     <StartArguments>/NOCHECK</StartArguments>
Index: branches/src/ProcessManagement/ProcessManagement/ProcessManagement.xml
===================================================================
--- branches/src/ProcessManagement/ProcessManagement/ProcessManagement.xml	(revision 59)
+++ branches/src/ProcessManagement/ProcessManagement/ProcessManagement.xml	(revision 60)
@@ -2,7 +2,7 @@
 <ProcessManagement>
   <!-- ＤＢ接続情報 -->
   <DBConnect>
-    <DBServer>192.168.10.17</DBServer>
+    <DBServer>203.137.94.208</DBServer>
     <DBUser>pmana</DBUser>
     <Password>manager</Password>
     <Database>processmanagement</Database>
Index: branches/src/ProcessManagement/ProcessManagement/RequestSheet.xlsx
===================================================================
Cannot display: file marked as a binary type.
svn:mime-type = application/octet-stream
Index: branches/src/ProcessManagement/ProcessManagement.v12.suo
===================================================================
Cannot display: file marked as a binary type.
svn:mime-type = application/octet-stream
