リビジョン 33
セキュリティ区分変更
| trunk/src/ProcessManagement/ProcessManagement/Common/CommonDefine.cs | ||
|---|---|---|
| 62 | 62 |
|
| 63 | 63 |
#region システムセキュリティ定義 |
| 64 | 64 |
/// <summary> |
| 65 |
/// システム管理者パスワード
|
|
| 65 |
/// システム管理者コード
|
|
| 66 | 66 |
/// </summary> |
| 67 | 67 |
public static int AdminCode = 88889988; |
| 68 |
/// <summary> |
|
| 69 |
/// システム管理者名称 |
|
| 70 |
/// </summary> |
|
| 68 | 71 |
public static string AdminUser = "Admin"; |
| 72 |
/// <summary> |
|
| 73 |
/// システム管理者パスワード |
|
| 74 |
/// </summary> |
|
| 69 | 75 |
public static string AdminPass = "Admin"; |
| 76 |
/// <summary> |
|
| 77 |
/// システム管理者旧セキュリティコード |
|
| 78 |
/// </summary> |
|
| 70 | 79 |
public static int AdminSecurityManagement = -1; |
| 71 | 80 |
|
| 72 | 81 |
/// <summary> |
| 73 |
/// 機密管理番号 |
|
| 82 |
/// 旧機密管理番号
|
|
| 74 | 83 |
/// </summary> |
| 75 | 84 |
public enum SysManaDivNo |
| 76 | 85 |
{
|
| ... | ... | |
| 92 | 101 |
UserAuthority, |
| 93 | 102 |
} |
| 94 | 103 |
/// <summary> |
| 95 |
/// 機密管理区分 |
|
| 104 |
/// 旧機密管理区分
|
|
| 96 | 105 |
/// </summary> |
| 97 | 106 |
public static List<KeyValuePair<int, string>> SystemManageDiv = new List<KeyValuePair<int, string>>{
|
| 98 | 107 |
new KeyValuePair<int,string>(1,"最高責任者"), |
| 99 | 108 |
new KeyValuePair<int,string>(2,"統括責任者"), |
| 100 | 109 |
new KeyValuePair<int,string>(3,"所 属 長"), |
| 101 | 110 |
new KeyValuePair<int,string>(4,"一般使用者")}; |
| 111 |
/// <summary> |
|
| 112 |
/// 機密管理番号 |
|
| 113 |
/// </summary> |
|
| 114 |
public enum SecurityRankPos |
|
| 115 |
{
|
|
| 116 |
/// <summary> |
|
| 117 |
/// 特別権限 |
|
| 118 |
/// </summary> |
|
| 119 |
SpecialAuthority = 0, |
|
| 120 |
/// <summary> |
|
| 121 |
/// 統括者権限 |
|
| 122 |
/// </summary> |
|
| 123 |
FreeAuthority, |
|
| 124 |
/// <summary> |
|
| 125 |
/// 所属長権限 |
|
| 126 |
/// </summary> |
|
| 127 |
LimitedAuthority, |
|
| 128 |
/// <summary> |
|
| 129 |
/// 一般者権限 |
|
| 130 |
/// </summary> |
|
| 131 |
NormalAuthority, |
|
| 132 |
} |
|
| 133 |
/// <summary> |
|
| 134 |
/// 機密管理区分 |
|
| 135 |
/// </summary> |
|
| 136 |
public static List<KeyValuePair<int, string>> SecurityRankList = new List<KeyValuePair<int, string>>{
|
|
| 137 |
new KeyValuePair<int,string>(1,"特別権限"), |
|
| 138 |
new KeyValuePair<int,string>(2,"統括者権限"), |
|
| 139 |
new KeyValuePair<int,string>(3,"所属長権限"), |
|
| 140 |
new KeyValuePair<int,string>(4,"一般者権限")}; |
|
| 102 | 141 |
#region 旧機密区分名称 |
| 103 | 142 |
//public static List<KeyValuePair<int, string>> SecurityManagementDivision = new List<KeyValuePair<int, string>>{
|
| 104 | 143 |
// new KeyValuePair<int,string>(1,"最高機密管理者"), |
| ... | ... | |
| 106 | 145 |
// new KeyValuePair<int,string>(3,"機密管理者"), |
| 107 | 146 |
// new KeyValuePair<int,string>(4,"一般使用者")}; |
| 108 | 147 |
#endregion |
| 148 |
|
|
| 149 |
/// <summary> |
|
| 150 |
/// 機密区分範囲 |
|
| 151 |
/// </summary> |
|
| 152 |
public enum SecurityRangePos |
|
| 153 |
{
|
|
| 154 |
/// <summary> |
|
| 155 |
/// 全部署参照 |
|
| 156 |
/// </summary> |
|
| 157 |
AllPath = 0, |
|
| 158 |
/// <summary> |
|
| 159 |
/// 複数部署参照 |
|
| 160 |
/// </summary> |
|
| 161 |
Multiple, |
|
| 162 |
/// <summary> |
|
| 163 |
/// 自部署のみ |
|
| 164 |
/// </summary> |
|
| 165 |
Only, |
|
| 166 |
/// <summary> |
|
| 167 |
/// 自担当者のみ |
|
| 168 |
/// </summary> |
|
| 169 |
None, |
|
| 170 |
} |
|
| 171 |
public static List<KeyValuePair<int, string>> SecurityRangeList = new List<KeyValuePair<int, string>>{
|
|
| 172 |
new KeyValuePair<int,string>(1,"全部署対象"), |
|
| 173 |
new KeyValuePair<int,string>(2,"複数部署対象"), |
|
| 174 |
new KeyValuePair<int,string>(3,"自部署のみ対象"), |
|
| 175 |
new KeyValuePair<int,string>(4,"担当分のみ対象")}; |
|
| 109 | 176 |
#endregion |
| 110 | 177 |
|
| 111 | 178 |
#region エクセル使用時パス |
| ... | ... | |
| 161 | 228 |
#endregion |
| 162 | 229 |
|
| 163 | 230 |
#region 掲示板:関連定義 |
| 231 |
#region 掲示板グリッド返信文字 |
|
| 164 | 232 |
/// <summary> |
| 165 | 233 |
/// 掲示板グリッド返信文字 |
| 166 | 234 |
/// </summary> |
| ... | ... | |
| 187 | 255 |
/// 総務部コード(部署コード) |
| 188 | 256 |
/// </summary> |
| 189 | 257 |
public static int s_GeneralAffairsDevision = 4; |
| 258 |
#endregion |
|
| 190 | 259 |
|
| 260 |
#region メッセージリンク区分 |
|
| 191 | 261 |
/// <summary> |
| 192 | 262 |
/// メッセージリンク区分 |
| 193 | 263 |
/// </summary> |
| ... | ... | |
| 202 | 272 |
/// </summary> |
| 203 | 273 |
ConstructionInfo, |
| 204 | 274 |
} |
| 275 |
#endregion |
|
| 205 | 276 |
|
| 277 |
#region メッセージフラグ区分 |
|
| 206 | 278 |
/// <summary> |
| 207 | 279 |
/// メッセージフラグ区分 |
| 208 | 280 |
/// </summary> |
| ... | ... | |
| 218 | 290 |
Secretary, |
| 219 | 291 |
} |
| 220 | 292 |
#endregion |
| 293 |
#endregion |
|
| 221 | 294 |
|
| 222 | 295 |
#region 行動予定 会社行事名称・コード |
| 223 | 296 |
/// <summary> |
| ... | ... | |
| 1181 | 1254 |
/// <summary> |
| 1182 | 1255 |
/// 修正モード名称 |
| 1183 | 1256 |
/// </summary> |
| 1184 |
public static string EditModeStringNew = "新規"; |
|
| 1185 |
public static string EditModeStringEdit = "修正"; |
|
| 1257 |
public static string EditModeStringNew = "新 規"; |
|
| 1258 |
public static string EditModeStringEdit = "修 正"; |
|
| 1259 |
public static string EditModeStringRef = "参 照"; |
|
| 1186 | 1260 |
#endregion |
| 1187 | 1261 |
|
| 1188 | 1262 |
#region 1ページ初期行数 |
| ... | ... | |
| 1384 | 1458 |
CalcTarget, |
| 1385 | 1459 |
} |
| 1386 | 1460 |
#endregion |
| 1461 |
|
|
| 1462 |
#region 担当者対象部署マスタ:所属フラグ |
|
| 1463 |
/// <summary> |
|
| 1464 |
/// 担当者対象部署マスタ:所属フラグ |
|
| 1465 |
/// </summary> |
|
| 1466 |
public enum AffiliationFlg |
|
| 1467 |
{
|
|
| 1468 |
/// <summary> |
|
| 1469 |
/// 他部署 |
|
| 1470 |
/// </summary> |
|
| 1471 |
Ohter = 0, |
|
| 1472 |
/// <summary> |
|
| 1473 |
/// 所属部署 |
|
| 1474 |
/// </summary> |
|
| 1475 |
Affiliation, |
|
| 1476 |
} |
|
| 1477 |
#endregion |
|
| 1478 |
|
|
| 1479 |
#region 起動対象マスタ:データ編集フラグ |
|
| 1480 |
/// <summary> |
|
| 1481 |
/// 起動対象マスタ:データ編集フラグ |
|
| 1482 |
/// </summary> |
|
| 1483 |
public enum ProcessDataEdit |
|
| 1484 |
{
|
|
| 1485 |
/// <summary> |
|
| 1486 |
/// 参照 |
|
| 1487 |
/// </summary> |
|
| 1488 |
Reference = 0, |
|
| 1489 |
/// <summary> |
|
| 1490 |
/// 対象 |
|
| 1491 |
/// </summary> |
|
| 1492 |
Edit, |
|
| 1493 |
} |
|
| 1494 |
#endregion |
|
| 1495 |
|
|
| 1496 |
#region 保護区分マスタ:総務業務フラグ |
|
| 1497 |
/// <summary> |
|
| 1498 |
/// 保護区分マスタ:総務業務フラグ |
|
| 1499 |
/// </summary> |
|
| 1500 |
public enum GeneralAffairs |
|
| 1501 |
{
|
|
| 1502 |
/// <summary> |
|
| 1503 |
/// 総務以外 |
|
| 1504 |
/// </summary> |
|
| 1505 |
OtherDep = 0, |
|
| 1506 |
/// <summary> |
|
| 1507 |
/// 総務業務対象 |
|
| 1508 |
/// </summary> |
|
| 1509 |
GeneralDep, |
|
| 1510 |
} |
|
| 1511 |
#endregion |
|
| 1512 |
|
|
| 1513 |
#region 保護区分マスタ:総務業務名称 |
|
| 1514 |
/// <summary> |
|
| 1515 |
/// 保護区分マスタ:総務業務名称 |
|
| 1516 |
/// </summary> |
|
| 1517 |
public static List<KeyValuePair<int, string>> GeneralAffairsList = new List<KeyValuePair<int, string>>{
|
|
| 1518 |
new KeyValuePair<int,string>(0,"総務業務不可"), |
|
| 1519 |
new KeyValuePair<int,string>(1,"総務業務可能")}; |
|
| 1520 |
#endregion |
|
| 1387 | 1521 |
} |
| 1388 | 1522 |
} |
| trunk/src/ProcessManagement/ProcessManagement/Common/CommonMotions.cs | ||
|---|---|---|
| 50 | 50 |
private static SystemMaster m_systemMaster = new SystemMaster(); |
| 51 | 51 |
|
| 52 | 52 |
/// <summary> |
| 53 |
/// ログインユーザーデータ |
|
| 53 |
/// ログインユーザー担当者データ
|
|
| 54 | 54 |
/// </summary> |
| 55 | 55 |
private static PersonInChargeMaster m_LoginUserData = new PersonInChargeMaster(); |
| 56 | 56 |
|
| 57 | 57 |
/// <summary> |
| 58 |
/// システム起動チェック処理クラス
|
|
| 58 |
/// ログインユーザー参照部署データ
|
|
| 59 | 59 |
/// </summary> |
| 60 |
private static ClsSystemOnceExecute m_CheckProc = null;
|
|
| 61 |
|
|
| 60 |
private static List<PersonDepartmentMaster> m_LoginUserDepartment = new List<PersonDepartmentMaster>();
|
|
| 61 |
|
|
| 62 | 62 |
/// <summary> |
| 63 |
/// 建築工事費の構成
|
|
| 63 |
/// ログインユーザーセキュリティ区分
|
|
| 64 | 64 |
/// </summary> |
| 65 |
//private static Dictionary<int, string> m_StructureTypeName = new Dictionary<int, string>();
|
|
| 65 |
private static SecurityMaster m_LoginUserSecurity = new SecurityMaster();
|
|
| 66 | 66 |
|
| 67 | 67 |
/// <summary> |
| 68 |
/// ログインユーザー処理起動区分 |
|
| 69 |
/// </summary> |
|
| 70 |
private static List<ProcessExcute> m_LoginUserProcExe = new List<ProcessExcute>(); |
|
| 71 |
|
|
| 72 |
/// <summary> |
|
| 73 |
/// システム初回起動チェック処理クラス |
|
| 74 |
/// </summary> |
|
| 75 |
private static ClsSystemOnceExecute m_CheckProc = null; |
|
| 76 |
|
|
| 77 |
/// <summary> |
|
| 68 | 78 |
/// 製品ファイルバージョン格納エリア |
| 69 | 79 |
/// </summary> |
| 70 | 80 |
private static FileVersionInfo m_ProductVersionInfo = FileVersionInfo.GetVersionInfo(System.Reflection.Assembly.GetExecutingAssembly().Location); |
| ... | ... | |
| 103 | 113 |
} |
| 104 | 114 |
|
| 105 | 115 |
/// <summary> |
| 106 |
/// ログインユーザーデータ |
|
| 116 |
/// ログインユーザー担当者データ
|
|
| 107 | 117 |
/// </summary> |
| 108 | 118 |
public static PersonInChargeMaster LoginUserData |
| 109 | 119 |
{
|
| ... | ... | |
| 112 | 122 |
} |
| 113 | 123 |
|
| 114 | 124 |
/// <summary> |
| 115 |
/// 構成マスタ(大項目マスタ)
|
|
| 125 |
/// ログインユーザー参照部署データ
|
|
| 116 | 126 |
/// </summary> |
| 117 |
//public static Dictionary<int, string> StructureTypeName
|
|
| 118 |
//{
|
|
| 119 |
// get { return m_StructureTypeName; }
|
|
| 120 |
// set { m_StructureTypeName = value; }
|
|
| 121 |
//}
|
|
| 127 |
public static List<PersonDepartmentMaster> LoginUserDepartment
|
|
| 128 |
{
|
|
| 129 |
get { return m_LoginUserDepartment; }
|
|
| 130 |
set { m_LoginUserDepartment = value; }
|
|
| 131 |
} |
|
| 122 | 132 |
|
| 123 | 133 |
/// <summary> |
| 134 |
/// ログインユーザーセキュリティ区分 |
|
| 135 |
/// </summary> |
|
| 136 |
public static SecurityMaster LoginUserSecurity |
|
| 137 |
{
|
|
| 138 |
get { return m_LoginUserSecurity; }
|
|
| 139 |
set { m_LoginUserSecurity = value; }
|
|
| 140 |
} |
|
| 141 |
|
|
| 142 |
/// <summary> |
|
| 143 |
/// ログインユーザー処理起動区分 |
|
| 144 |
/// </summary> |
|
| 145 |
public static List<ProcessExcute> LoginUserProcExe |
|
| 146 |
{
|
|
| 147 |
get { return m_LoginUserProcExe; }
|
|
| 148 |
set { m_LoginUserProcExe = value; }
|
|
| 149 |
} |
|
| 150 |
|
|
| 151 |
/// <summary> |
|
| 124 | 152 |
/// 製品ファイルバージョン格納エリア |
| 125 | 153 |
/// </summary> |
| 126 | 154 |
public static FileVersionInfo ProductVersionInfo |
| ... | ... | |
| 135 | 163 |
{
|
| 136 | 164 |
get { return m_CheckProc; }
|
| 137 | 165 |
} |
| 166 |
|
|
| 138 | 167 |
#endregion |
| 139 | 168 |
|
| 140 | 169 |
#region 初期化 |
| 141 |
|
|
| 142 | 170 |
/// <summary> |
| 143 | 171 |
/// 初期化 |
| 144 | 172 |
/// </summary> |
| ... | ... | |
| 945 | 973 |
} |
| 946 | 974 |
} |
| 947 | 975 |
#endregion |
| 976 |
|
|
| 977 |
#region 補色を取得する |
|
| 978 |
/// <summary> |
|
| 979 |
/// 補色を取得する |
|
| 980 |
/// </summary> |
|
| 981 |
/// <param name="color"></param> |
|
| 982 |
/// <returns></returns> |
|
| 983 |
public static Color GetComplementaryColor(Color color) |
|
| 984 |
{
|
|
| 985 |
try |
|
| 986 |
{
|
|
| 987 |
byte r = (byte)~color.R; |
|
| 988 |
byte g = (byte)~color.G; |
|
| 989 |
byte b = (byte)~color.B; |
|
| 990 |
|
|
| 991 |
return Color.FromArgb(r, g, b); |
|
| 992 |
} |
|
| 993 |
catch (System.Exception ex) |
|
| 994 |
{
|
|
| 995 |
logger.ErrorFormat("システムエラー:{0}:{1}", GetMethodName(), ex.Message);
|
|
| 996 |
return color; |
|
| 997 |
} |
|
| 998 |
} |
|
| 948 | 999 |
#endregion |
| 949 | 1000 |
|
| 1001 |
#region 指定桁数の数値最大値を返す |
|
| 1002 |
/// <summary> |
|
| 1003 |
/// 指定桁数の数値最大値を返す |
|
| 1004 |
/// </summary> |
|
| 1005 |
/// <param name="NumLen"></param> |
|
| 1006 |
/// <returns></returns> |
|
| 1007 |
public static int CreateMaxNumeric(int NumLen) |
|
| 1008 |
{
|
|
| 1009 |
try |
|
| 1010 |
{
|
|
| 1011 |
string strNum = string.Empty; |
|
| 1012 |
for (int i = 0; i < NumLen; i++) |
|
| 1013 |
{
|
|
| 1014 |
strNum += "9"; |
|
| 1015 |
} |
|
| 1016 |
|
|
| 1017 |
return cnvInt(strNum); |
|
| 1018 |
} |
|
| 1019 |
catch (System.Exception ex) |
|
| 1020 |
{
|
|
| 1021 |
logger.ErrorFormat("システムエラー:{0}:{1}", GetMethodName(), ex.Message);
|
|
| 1022 |
return 0; |
|
| 1023 |
} |
|
| 1024 |
} |
|
| 1025 |
#endregion |
|
| 1026 |
|
|
| 1027 |
#endregion |
|
| 1028 |
|
|
| 950 | 1029 |
#region データチェックメソッド |
| 951 | 1030 |
#region ディレクトリの存在チェック |
| 952 | 1031 |
/// <summary> |
| ... | ... | |
| 1236 | 1315 |
} |
| 1237 | 1316 |
#endregion |
| 1238 | 1317 |
|
| 1239 |
#region セルが空かどうかをチェックする
|
|
| 1318 |
#region 対象が空かどうかをチェックする
|
|
| 1240 | 1319 |
/// <summary> |
| 1241 |
/// セルが空かどうかをチェックする
|
|
| 1320 |
/// 対象が空かどうかをチェックする
|
|
| 1242 | 1321 |
/// </summary> |
| 1243 | 1322 |
/// <param name="objCell"></param> |
| 1244 | 1323 |
/// <param name="iColumn"></param> |
| ... | ... | |
| 1943 | 2022 |
} |
| 1944 | 2023 |
#endregion |
| 1945 | 2024 |
|
| 1946 |
#region 経過時間を工数で返す
|
|
| 2025 |
#region 経過日数を工数で返す
|
|
| 1947 | 2026 |
/// <summary> |
| 1948 |
/// 経過時間を工数で返す
|
|
| 2027 |
/// 経過日数を工数で返す
|
|
| 1949 | 2028 |
/// </summary> |
| 1950 | 2029 |
/// <param name="StartDate"></param> |
| 1951 | 2030 |
/// <param name="CompDate"></param> |
| ... | ... | |
| 1954 | 2033 |
{
|
| 1955 | 2034 |
// 差分計算 |
| 1956 | 2035 |
TimeSpan DiffDate = CompDate - StartDate; |
| 2036 |
|
|
| 1957 | 2037 |
// 当日までなので+1日する |
| 1958 | 2038 |
TimeSpan wrkts = new TimeSpan(1, 0, 0, 0); |
| 1959 | 2039 |
DiffDate = DiffDate + wrkts; |
| 2040 |
|
|
| 1960 | 2041 |
// 工数の最小単位で割って10分の1にする |
| 1961 |
return (((double)DiffDate.Days) / CommonDefine.s_ManHourUnitDays) / 10; |
|
| 2042 |
//return (((double)DiffDate.Days) / CommonDefine.s_ManHourUnitDays) / 10; |
|
| 2043 |
// 日数から月数へ変換する |
|
| 2044 |
return ClsCalendar.cnvMonthFromDays(DiffDate.Days); |
|
| 1962 | 2045 |
} |
| 1963 | 2046 |
#endregion |
| 1964 | 2047 |
|
| ... | ... | |
| 2152 | 2235 |
} |
| 2153 | 2236 |
#endregion |
| 2154 | 2237 |
|
| 2238 |
#region 予算書・台帳給与金額計算処理 |
|
| 2239 |
/// <summary> |
|
| 2240 |
/// 予算書・台帳給与金額計算処理 |
|
| 2241 |
/// </summary> |
|
| 2242 |
public static void CalcPayValueData(double MonthryCost, double OrdersPrice, int workingCount, |
|
| 2243 |
ref double ExecutionAmount, ref double AmountConfigRate, |
|
| 2244 |
bool bSalaryCorrection = true) |
|
| 2245 |
{
|
|
| 2246 |
try |
|
| 2247 |
{
|
|
| 2248 |
// 受注金額が0の場合は1として計算する |
|
| 2249 |
if (OrdersPrice == 0) OrdersPrice = 1; |
|
| 2250 |
|
|
| 2251 |
// 日当計算 |
|
| 2252 |
double DairySalary =0; |
|
| 2253 |
if (bSalaryCorrection) |
|
| 2254 |
DairySalary = (MonthryCost * CommonDefine.s_SalaryCorrection) / CommonDefine.s_ManHourUnitMonth; |
|
| 2255 |
else |
|
| 2256 |
DairySalary = MonthryCost / CommonDefine.s_ManHourUnitMonth; |
|
| 2257 |
|
|
| 2258 |
// 給与支払総額 |
|
| 2259 |
int iInput = CommonMotions.cnvRound(DairySalary * workingCount); |
|
| 2260 |
|
|
| 2261 |
// 実行金額に給与支払総額をセットする |
|
| 2262 |
ExecutionAmount = iInput; |
|
| 2263 |
|
|
| 2264 |
// 金額構成率計算 |
|
| 2265 |
AmountConfigRate = (iInput / OrdersPrice) * 100.0; |
|
| 2266 |
|
|
| 2267 |
// 構成率が範囲外の場合は0にする |
|
| 2268 |
if (AmountConfigRate < -999.00 || 999.00 < AmountConfigRate) AmountConfigRate = 0; |
|
| 2269 |
} |
|
| 2270 |
catch (Exception ex) |
|
| 2271 |
{
|
|
| 2272 |
logger.ErrorFormat("システムエラー:{0}:{1}", CommonMotions.GetMethodName(), ex.Message);
|
|
| 2273 |
} |
|
| 2274 |
} |
|
| 2155 | 2275 |
#endregion |
| 2156 | 2276 |
|
| 2277 |
#region 給与取得SQL作成処理 |
|
| 2278 |
/// <summary> |
|
| 2279 |
/// 給与取得SQL作成処理 |
|
| 2280 |
/// </summary> |
|
| 2281 |
private static string GetSalaryValue(int PersonCode, DateTime GetData) |
|
| 2282 |
{
|
|
| 2283 |
try |
|
| 2284 |
{
|
|
| 2285 |
// SQL作成 |
|
| 2286 |
string strSQL = "SELECT A.MONTHLYSALARY, A.YEARSALARY, A.PERSONCODE, A.STARTDATE FROM PERSONSALARYMASTER A,"; |
|
| 2287 |
strSQL += " (SELECT PERSONCODE, MAX(STARTDATE) sDate FROM PERSONSALARYMASTER"; |
|
| 2288 |
strSQL += string.Format(" WHERE PERSONCODE = {0}", PersonCode);
|
|
| 2289 |
strSQL += string.Format(" AND TRUNC(STARTDATE) <= TO_DATE('{0}')", GetData.ToShortDateString());
|
|
| 2290 |
strSQL += " GROUP BY PERSONCODE) B"; |
|
| 2291 |
strSQL += " WHERE A.PERSONCODE = B.PERSONCODE AND A.STARTDATE = B.sDate"; |
|
| 2292 |
|
|
| 2293 |
return strSQL; |
|
| 2294 |
} |
|
| 2295 |
catch (Exception ex) |
|
| 2296 |
{
|
|
| 2297 |
logger.ErrorFormat("システムエラー:{0}:{1}", CommonMotions.GetMethodName(), ex.Message);
|
|
| 2298 |
return string.Empty; |
|
| 2299 |
} |
|
| 2300 |
} |
|
| 2301 |
#endregion |
|
| 2302 |
|
|
| 2303 |
#region 担当者給与金額取得処理(単独処理) |
|
| 2304 |
/// <summary> |
|
| 2305 |
/// 担当者給与金額取得処理(単独処理) |
|
| 2306 |
/// </summary> |
|
| 2307 |
public static bool GetSalaryValue(int PersonCode, ref double MonthryCost, ref double YearsCost, DateTime GetData) |
|
| 2308 |
{
|
|
| 2309 |
IOMPersonInCharge PersonDB = new IOMPersonInCharge(); |
|
| 2310 |
try |
|
| 2311 |
{
|
|
| 2312 |
// 初期値セット |
|
| 2313 |
MonthryCost = 0; |
|
| 2314 |
YearsCost = 0; |
|
| 2315 |
|
|
| 2316 |
// データ取得 |
|
| 2317 |
string strSQL = GetSalaryValue(PersonCode, GetData); |
|
| 2318 |
ArrayList arList = new ArrayList(); |
|
| 2319 |
if (!PersonDB.ExecuteReader(strSQL, ref arList)) return false; |
|
| 2320 |
object[] objGetData = (object[])arList[0]; |
|
| 2321 |
|
|
| 2322 |
// 取得値セット |
|
| 2323 |
MonthryCost = CommonMotions.cnvDouble(objGetData[0]); |
|
| 2324 |
YearsCost = CommonMotions.cnvDouble(objGetData[1]); |
|
| 2325 |
|
|
| 2326 |
return true; |
|
| 2327 |
} |
|
| 2328 |
catch (Exception ex) |
|
| 2329 |
{
|
|
| 2330 |
logger.ErrorFormat("システムエラー:{0}:{1}", CommonMotions.GetMethodName(), ex.Message);
|
|
| 2331 |
return false; |
|
| 2332 |
} |
|
| 2333 |
finally |
|
| 2334 |
{
|
|
| 2335 |
PersonDB.close(); PersonDB = null; |
|
| 2336 |
} |
|
| 2337 |
} |
|
| 2338 |
#endregion |
|
| 2339 |
|
|
| 2340 |
#region 担当者給与金額取得処理(セッションコネクト別) |
|
| 2341 |
/// <summary> |
|
| 2342 |
/// 担当者給与金額取得処理(セッションコネクト別) |
|
| 2343 |
/// </summary> |
|
| 2344 |
public static bool GetSalaryValue(IOMPersonInCharge PersonDB, int PersonCode, |
|
| 2345 |
ref double MonthryCost, ref double YearsCost, DateTime GetData) |
|
| 2346 |
{
|
|
| 2347 |
try |
|
| 2348 |
{
|
|
| 2349 |
// 初期値セット |
|
| 2350 |
MonthryCost = 0; |
|
| 2351 |
YearsCost = 0; |
|
| 2352 |
|
|
| 2353 |
// データ取得 |
|
| 2354 |
string strSQL = GetSalaryValue(PersonCode, GetData); |
|
| 2355 |
ArrayList arList = new ArrayList(); |
|
| 2356 |
if (!PersonDB.ExecuteReader(strSQL, ref arList, false)) return false; |
|
| 2357 |
object[] objGetData = (object[])arList[0]; |
|
| 2358 |
|
|
| 2359 |
// 取得値セット |
|
| 2360 |
MonthryCost = CommonMotions.cnvDouble(objGetData[0]); |
|
| 2361 |
YearsCost = CommonMotions.cnvDouble(objGetData[1]); |
|
| 2362 |
|
|
| 2363 |
return true; |
|
| 2364 |
} |
|
| 2365 |
catch (Exception ex) |
|
| 2366 |
{
|
|
| 2367 |
logger.ErrorFormat("システムエラー:{0}:{1}", CommonMotions.GetMethodName(), ex.Message);
|
|
| 2368 |
return false; |
|
| 2369 |
} |
|
| 2370 |
} |
|
| 2371 |
#endregion |
|
| 2372 |
|
|
| 2373 |
#region 与えられたキー値より機密管理区分データを取得する |
|
| 2374 |
/// <summary> |
|
| 2375 |
/// 与えられたキー値より機密管理区分データを取得する |
|
| 2376 |
/// </summary> |
|
| 2377 |
/// <param name="KeyValue"></param> |
|
| 2378 |
/// <returns></returns> |
|
| 2379 |
public static KeyValuePair<int, string> SearchSecurityRankList(int KeyValue) |
|
| 2380 |
{
|
|
| 2381 |
KeyValuePair<int, string> RetPairvalue = new KeyValuePair<int, string>(0, string.Empty); |
|
| 2382 |
try |
|
| 2383 |
{
|
|
| 2384 |
for (int i = 0; i < CommonDefine.SecurityRankList.Count; i++) |
|
| 2385 |
{
|
|
| 2386 |
if (CommonDefine.SecurityRankList[i].Key == KeyValue) |
|
| 2387 |
{
|
|
| 2388 |
RetPairvalue = CommonDefine.SecurityRankList[i]; |
|
| 2389 |
} |
|
| 2390 |
} |
|
| 2391 |
|
|
| 2392 |
return RetPairvalue; |
|
| 2393 |
} |
|
| 2394 |
catch (Exception ex) |
|
| 2395 |
{
|
|
| 2396 |
logger.ErrorFormat("システムエラー:{0}:{1}", CommonMotions.GetMethodName(), ex.Message);
|
|
| 2397 |
return RetPairvalue; |
|
| 2398 |
} |
|
| 2399 |
} |
|
| 2400 |
#endregion |
|
| 2401 |
|
|
| 2402 |
#region 与えられたキー値より機密区分範囲データを取得する |
|
| 2403 |
/// <summary> |
|
| 2404 |
/// 与えられたキー値より機密区分範囲データを取得する |
|
| 2405 |
/// </summary> |
|
| 2406 |
/// <param name="KeyValue"></param> |
|
| 2407 |
/// <returns></returns> |
|
| 2408 |
public static KeyValuePair<int, string> SearchSecurityRangeList(int KeyValue) |
|
| 2409 |
{
|
|
| 2410 |
KeyValuePair<int, string> RetPairvalue = new KeyValuePair<int, string>(0, string.Empty); |
|
| 2411 |
try |
|
| 2412 |
{
|
|
| 2413 |
for (int i = 0; i < CommonDefine.SecurityRangeList.Count; i++) |
|
| 2414 |
{
|
|
| 2415 |
if (CommonDefine.SecurityRangeList[i].Key == KeyValue) |
|
| 2416 |
{
|
|
| 2417 |
RetPairvalue = CommonDefine.SecurityRangeList[i]; |
|
| 2418 |
} |
|
| 2419 |
} |
|
| 2420 |
|
|
| 2421 |
return RetPairvalue; |
|
| 2422 |
} |
|
| 2423 |
catch (Exception ex) |
|
| 2424 |
{
|
|
| 2425 |
logger.ErrorFormat("システムエラー:{0}:{1}", CommonMotions.GetMethodName(), ex.Message);
|
|
| 2426 |
return RetPairvalue; |
|
| 2427 |
} |
|
| 2428 |
} |
|
| 2429 |
#endregion |
|
| 2430 |
|
|
| 2431 |
#endregion |
|
| 2432 |
|
|
| 2157 | 2433 |
#region Excel向け操作メソッド |
| 2158 | 2434 |
#region オブジェクト開放 |
| 2159 | 2435 |
/// <summary> |
| trunk/src/ProcessManagement/ProcessManagement/Common/Office/UsedExcel.cs | ||
|---|---|---|
| 321 | 321 |
} |
| 322 | 322 |
catch (Exception ex) |
| 323 | 323 |
{
|
| 324 |
logger.ErrorFormat("配列セットシステムエラー:{0}:{1}:{2}", ex.Message, FromColum, ToColum);
|
|
| 324 |
logger.ErrorFormat("配列セットシステムエラー:{0}:{1}:{2}", ex.Message, FromColum, ToColum);
|
|
| 325 | 325 |
} |
| 326 | 326 |
finally |
| 327 | 327 |
{
|
| ... | ... | |
| 359 | 359 |
} |
| 360 | 360 |
catch (Exception ex) |
| 361 | 361 |
{
|
| 362 |
logger.ErrorFormat("システムエラー:{0}:{1}:{2}:{3}", ex.Message, FromColum, ToColum, strData);
|
|
| 362 |
logger.ErrorFormat("システムエラー:{0}:{1}:{2}:{3}", ex.Message, FromColum, ToColum, strData);
|
|
| 363 | 363 |
} |
| 364 | 364 |
finally |
| 365 | 365 |
{
|
| ... | ... | |
| 475 | 475 |
} |
| 476 | 476 |
catch (Exception ex) |
| 477 | 477 |
{
|
| 478 |
logger.ErrorFormat("システムエラー:{0}:{1}:{2}", ex.Message, ToColum);
|
|
| 478 |
logger.ErrorFormat("システムエラー:{0}:{1}", ex.Message, ToColum);
|
|
| 479 | 479 |
} |
| 480 | 480 |
finally |
| 481 | 481 |
{
|
| ... | ... | |
| 511 | 511 |
} |
| 512 | 512 |
catch (Exception ex) |
| 513 | 513 |
{
|
| 514 |
logger.ErrorFormat("システムエラー:{0}:{1}:{2}", ex.Message, ToColum);
|
|
| 514 |
logger.ErrorFormat("システムエラー:{0}:{1}", ex.Message, ToColum);
|
|
| 515 | 515 |
} |
| 516 | 516 |
finally |
| 517 | 517 |
{
|
| trunk/src/ProcessManagement/ProcessManagement/Common/Process/ClsCalendar.cs | ||
|---|---|---|
| 128 | 128 |
} |
| 129 | 129 |
#endregion |
| 130 | 130 |
|
| 131 |
//#region 指定期間内の経過日数を1人月を上限に返す |
|
| 132 |
///// <summary> |
|
| 133 |
///// 指定期間内の経過日数を1人月を上限に返す |
|
| 134 |
///// </summary> |
|
| 135 |
///// <param name="startdate">開始日</param> |
|
| 136 |
///// <param name="Complatedate">終了日</param> |
|
| 137 |
///// <returns></returns> |
|
| 138 |
//public static int CalcPassedDaysCountToUnit(DateTime Startdate, DateTime Complatedate) |
|
| 139 |
//{
|
|
| 140 |
// try |
|
| 141 |
// {
|
|
| 142 |
// int passDay = CalcPassedDaysCount(Startdate, Complatedate); |
|
| 131 |
#region 日数を月数に変換して返す |
|
| 132 |
/// <summary> |
|
| 133 |
/// 日数を月数に変換して返す |
|
| 134 |
/// </summary> |
|
| 135 |
/// <param name="DateCount"></param> |
|
| 136 |
/// <returns></returns> |
|
| 137 |
public static double cnvMonthFromDays(int DateCount) |
|
| 138 |
{
|
|
| 139 |
try |
|
| 140 |
{
|
|
| 141 |
return (DateCount / CommonDefine.s_ManHourUnitMonth); |
|
| 142 |
} |
|
| 143 |
catch (Exception ex) |
|
| 144 |
{
|
|
| 145 |
logger.ErrorFormat("システムエラー:{0}:{1}", CommonMotions.GetMethodName(), ex.Message);
|
|
| 146 |
return 0; |
|
| 147 |
} |
|
| 148 |
} |
|
| 149 |
#endregion |
|
| 143 | 150 |
|
| 144 |
// int OneMonth = (int)(CommonDefine.s_ManHourUnitDays * 10.0); |
|
| 151 |
#region 差分の日数を返す |
|
| 152 |
/// <summary> |
|
| 153 |
/// 差分の日数を返す |
|
| 154 |
/// </summary> |
|
| 155 |
/// <returns></returns> |
|
| 156 |
public static int CalcDifferenceDate(DateTime OrgStDate, DateTime OrgEdDate, DateTime ChgStDate, DateTime ChgEdDate) |
|
| 157 |
{
|
|
| 158 |
try |
|
| 159 |
{
|
|
| 160 |
int iRet = 0; |
|
| 145 | 161 |
|
| 146 |
// //if (passDay > OneMonth) passDay = OneMonth; |
|
| 162 |
// ----- 当初日数 |
|
| 163 |
// 経過日数を求める |
|
| 164 |
TimeSpan tsOrgdays = OrgEdDate.Date - OrgStDate.Date; |
|
| 165 |
// 計算では当日の時間引くので+1する |
|
| 166 |
int OrgDays = (int)(tsOrgdays.Days + 1.0); |
|
| 147 | 167 |
|
| 148 |
// return passDay; |
|
| 149 |
// } |
|
| 150 |
// catch (Exception ex) |
|
| 151 |
// {
|
|
| 152 |
// logger.ErrorFormat("システムエラー:{0}:{1}", CommonMotions.GetMethodName(), ex.Message);
|
|
| 153 |
// return 0; |
|
| 154 |
// } |
|
| 155 |
//} |
|
| 156 |
//#endregion |
|
| 168 |
// ----- 変更日数 |
|
| 169 |
// 経過日数を求める |
|
| 170 |
TimeSpan tsChgdays = ChgEdDate.Date - ChgStDate.Date; |
|
| 171 |
// 計算では当日の時間引くので+1する |
|
| 172 |
int ChgDays = (int)(tsChgdays.Days + 1.0); |
|
| 173 |
|
|
| 174 |
// 差分計算 |
|
| 175 |
iRet = ChgDays - OrgDays; |
|
| 176 |
|
|
| 177 |
return iRet; |
|
| 178 |
} |
|
| 179 |
catch (Exception ex) |
|
| 180 |
{
|
|
| 181 |
logger.ErrorFormat("システムエラー:{0}:{1}", CommonMotions.GetMethodName(), ex.Message);
|
|
| 182 |
return 0; |
|
| 183 |
} |
|
| 184 |
} |
|
| 185 |
#endregion |
|
| 157 | 186 |
} |
| 158 | 187 |
} |
| trunk/src/ProcessManagement/ProcessManagement/Common/Process/ClsChangeBaseInfoData.cs | ||
|---|---|---|
| 60 | 60 |
try |
| 61 | 61 |
{
|
| 62 | 62 |
// 工事詳細台帳入力完了日をセットする |
| 63 |
if (!BaseDB.UpdateFeild(ConstrCode, (int)IOConstructionBaseInfo.TableColumn.LEDGERCOMPLATEDATE, SetDate)) return false;
|
|
| 63 |
if (!BaseDB.UpdateFeild(ConstrCode, (int)IOConstructionBaseInfo.TableColumn.LedgerComplateDate, SetDate)) return false;
|
|
| 64 | 64 |
|
| 65 | 65 |
return true; |
| 66 | 66 |
} |
| trunk/src/ProcessManagement/ProcessManagement/Common/Process/ClsChangeLedgerData.cs | ||
|---|---|---|
| 67 | 67 |
IOConstructionLedgerExcute LedgerExcuteDB = new IOConstructionLedgerExcute(); |
| 68 | 68 |
try |
| 69 | 69 |
{
|
| 70 |
List<int> ConstrCodeList = new List<int>(); |
|
| 71 |
|
|
| 70 | 72 |
// 一括処理で登録を行う |
| 71 | 73 |
CostDB.connect(); |
| 72 | 74 |
LedgerDB.connect(); |
| ... | ... | |
| 113 | 115 |
|
| 114 | 116 |
// 工事番号 |
| 115 | 117 |
int ConstructionCode = CommonMotions.cnvInt(wrkrec[0]); |
| 118 |
// 工事番号退避 |
|
| 119 |
ConstrCodeList.Add(ConstructionCode); |
|
| 116 | 120 |
|
| 117 | 121 |
// グループ番号 |
| 118 | 122 |
int DataType = i; |
| ... | ... | |
| 143 | 147 |
// DBコミット |
| 144 | 148 |
LedgerExcuteDB.commit(); |
| 145 | 149 |
|
| 150 |
// 工事詳細台帳の更新 |
|
| 151 |
foreach (int ConstrCode in ConstrCodeList) |
|
| 152 |
{
|
|
| 153 |
LedgerRecalculate(ConstrCode); |
|
| 154 |
} |
|
| 155 |
|
|
| 146 | 156 |
return true; |
| 147 | 157 |
} |
| 148 | 158 |
catch (System.Exception ex) |
| ... | ... | |
| 161 | 171 |
} |
| 162 | 172 |
#endregion |
| 163 | 173 |
|
| 174 |
#region 工事詳細台帳再計算処理 |
|
| 175 |
/// <summary> |
|
| 176 |
/// 工事詳細台帳再計算処理 |
|
| 177 |
/// </summary> |
|
| 178 |
/// <param name="ConstrCode"></param> |
|
| 179 |
private static void LedgerRecalculate(int ConstrCode) |
|
| 180 |
{
|
|
| 181 |
FrmConstructionLedger frm = new FrmConstructionLedger(); // 工事詳細台帳入力 |
|
| 182 |
try |
|
| 183 |
{
|
|
| 184 |
// 工事コードのセット |
|
| 185 |
frm.ConstructionCode = ConstrCode; |
|
| 186 |
|
|
| 187 |
// 見えない画面を出す |
|
| 188 |
frm.Hide(); |
|
| 189 |
|
|
| 190 |
// 再計算処理 |
|
| 191 |
bool bret = frm.RecalculateLedger; |
|
| 192 |
|
|
| 193 |
// 画面を閉じる |
|
| 194 |
frm.Close(); |
|
| 195 |
} |
|
| 196 |
catch (System.Exception ex) |
|
| 197 |
{
|
|
| 198 |
logger.ErrorFormat("システムエラー:{0}:{1}", CommonMotions.GetMethodName(), ex.Message);
|
|
| 199 |
} |
|
| 200 |
finally |
|
| 201 |
{
|
|
| 202 |
frm.Dispose(); frm = null; |
|
| 203 |
} |
|
| 204 |
} |
|
| 205 |
#endregion |
|
| 206 |
|
|
| 164 | 207 |
#region 工事詳細台帳より対象データを探して実行データの行番号・列番号を返す(交通費・購入品等のみ) |
| 165 | 208 |
/// <summary> |
| 166 | 209 |
/// 工事詳細台帳より対象データを探して実行データの行番号・列番号を返す(交通費・購入品等のみ) |
| ... | ... | |
| 452 | 495 |
/// <param name="TargetDate">対象日</param> |
| 453 | 496 |
/// <param name="bSetFlag">月一括セットフラグ</param> |
| 454 | 497 |
/// <returns></returns> |
| 455 |
public static bool CalculatePayment(int ConstrCode, DateTime TargetDate, bool bSetFlag = false)
|
|
| 498 |
public static bool CalculatePayment(ConstructionLedger LedgerRec, DateTime TargetDate, DateTime lasrDate)
|
|
| 456 | 499 |
{
|
| 457 |
IOConstructionLedger LedgerDB = new IOConstructionLedger(); |
|
| 458 | 500 |
IOConstructionLedgerDetail LedgerDeDB = new IOConstructionLedgerDetail(); |
| 459 | 501 |
IOConstructionLedgerExcute LedgerExDB = new IOConstructionLedgerExcute(); |
| 460 | 502 |
IOMPersonInCharge PersonDB = new IOMPersonInCharge(); |
| 461 | 503 |
FrmConstructionLedger frm = new FrmConstructionLedger(); |
| 462 | 504 |
try |
| 463 | 505 |
{
|
| 464 |
// 工事詳細台帳データ取得 |
|
| 465 |
List<ConstructionLedger> LedgerList = new List<ConstructionLedger>(); |
|
| 466 |
string LedgerSQL = LedgerDB.CreatePrimarykeyString(ConstrCode); |
|
| 467 |
if (!LedgerDB.SelectAction(LedgerSQL, ref LedgerList) || LedgerList.Count == 0) return false; |
|
| 468 |
|
|
| 469 | 506 |
// 工事詳細台帳明細データ取得 |
| 470 | 507 |
List<ConstructionLedgerDetail> DetailList = new List<ConstructionLedgerDetail>(); |
| 471 |
string DetailSQL = LedgerDeDB.CreatePrimarykeyString(ConstrCode);
|
|
| 508 |
string DetailSQL = LedgerDeDB.CreatePrimarykeyString(LedgerRec.ConstructionCode);
|
|
| 472 | 509 |
DetailSQL += string.Format(" AND OperatingFlg = {0}", (int)CommonDefine.SalaryOperateKind.Oparateing); // 対応中フラグ
|
| 510 |
DetailSQL += string.Format(" AND SALARYFLG != {0}", (int)CommonDefine.SalaryDevision.Noting); // 給与振分区分
|
|
| 473 | 511 |
DetailSQL += string.Format(" AND GROUPCOUNT IN ({0},{1},{2})",
|
| 474 |
(int)FrmConstructionLedger.DataGroup.Instructor, // 指導員給料 |
|
| 475 |
(int)FrmConstructionLedger.DataGroup.Assistant, // 副担当者給料 |
|
| 476 |
(int)FrmConstructionLedger.DataGroup.Payroll); // 担当者給料行 |
|
| 512 |
(int)FrmConstructionLedger.DataGroup.Instructor, // 指導員給料
|
|
| 513 |
(int)FrmConstructionLedger.DataGroup.Assistant, // 副担当者給料
|
|
| 514 |
(int)FrmConstructionLedger.DataGroup.Payroll); // 担当者給料行
|
|
| 477 | 515 |
|
| 478 |
if (!LedgerDeDB.SelectAction(DetailSQL, ref DetailList) || DetailList.Count == 0) return false;
|
|
| 516 |
if (!LedgerDeDB.SelectAction(DetailSQL, ref DetailList) || DetailList.Count == 0) return true;
|
|
| 479 | 517 |
|
| 480 | 518 |
// 対象月より書込みカラム位置を取得する |
| 481 |
int ColPoint = CalcTargetMonthToColumn(LedgerList[0].ConstructionStart, TargetDate); |
|
| 482 |
|
|
| 483 |
// 対象月の開始日・終了日を取得する |
|
| 484 |
DateTime dtStart = DateTimeUtil.BeginOfMonth(TargetDate); |
|
| 485 |
DateTime dtLast = DateTimeUtil.EndOfMonth(TargetDate); |
|
| 486 |
|
|
| 487 |
// 開始月は開始月を入れる |
|
| 488 |
if (LedgerList[0].ConstructionStart.Year == dtStart.Year |
|
| 489 |
&& LedgerList[0].ConstructionStart.Month == dtStart.Month) dtStart = LedgerList[0].ConstructionStart; |
|
| 490 |
|
|
| 491 |
// 当月は今日より大きい場合は今日を入れる |
|
| 492 |
if (DateTime.Now.Year == dtLast.Year |
|
| 493 |
&& DateTime.Now.Month == dtLast.Month |
|
| 494 |
&& DateTime.Now.Day < dtLast.Day) dtLast = DateTime.Now; |
|
| 495 |
|
|
| 496 |
// 終了月は終了日を入れる |
|
| 497 |
if (LedgerList[0].ConstructionEnd.Year == dtLast.Year |
|
| 498 |
&& LedgerList[0].ConstructionEnd.Month == dtLast.Month |
|
| 499 |
&& LedgerList[0].ConstructionEnd.Day < dtLast.Day) dtLast = LedgerList[0].ConstructionEnd; |
|
| 500 |
|
|
| 501 |
//// 稼働日数を取得する |
|
| 502 |
//int WorkingDay = ClsCalendar.CalcOperatingDaysCount(dtStart, dtLast); |
|
| 519 |
int ColPoint = CalcTargetMonthToColumn(LedgerRec.ConstructionStart, TargetDate); |
|
| 503 | 520 |
// 経過日数を取得する |
| 504 |
int WorkingDay = ClsCalendar.CalcPassedDaysCount(dtStart, dtLast); |
|
| 521 |
TimeSpan ts = TargetDate - lasrDate; |
|
| 522 |
int WorkingDay = ts.Days; |
|
| 505 | 523 |
|
| 506 | 524 |
LedgerExDB.connect(); LedgerExDB.beginTran(); |
| 507 | 525 |
PersonDB.connect(); PersonDB.beginTran(); |
| 508 | 526 |
|
| 509 |
bool LoopBreak = false; |
|
| 510 | 527 |
foreach (ConstructionLedgerDetail CurRec in DetailList) |
| 511 | 528 |
{
|
| 512 | 529 |
// コードが担当者ではない場合は処理しない |
| ... | ... | |
| 515 | 532 |
if (CurRec.CompanyCode == 0) continue; |
| 516 | 533 |
// 施工管理中担当者ではない場合は処理しない |
| 517 | 534 |
if (CurRec.OperatingFlg == (int)CommonDefine.SalaryOperateKind.Complate) continue; |
| 518 |
// 実行金額が無い場合は処理しない |
|
| 519 |
if (CurRec.ExecutionAmount == 0) continue; |
|
| 520 | 535 |
|
| 536 |
// 現在の値を取得する |
|
| 537 |
int NowValue = 0; |
|
| 538 |
string strExecout = "SELECT PAYMENTAMOUNT FROM CONSTRUCTIONLEDGEREXCUTE"; |
|
| 539 |
strExecout += LedgerExDB.CreatePrimarykeyString(CurRec.ConstructionCode, CurRec.GroupCount, CurRec.LineCount); |
|
| 540 |
strExecout += string.Format(" AND TargetMonth = TO_DATE('{0}')", DateTimeUtil.BeginOfMonth(TargetDate).ToShortDateString());
|
|
| 541 |
ArrayList arExecList = new ArrayList(); |
|
| 542 |
LedgerExDB.ExecuteReader(strExecout, ref arExecList, false); |
|
| 543 |
if (arExecList.Count != 0) |
|
| 544 |
{
|
|
| 545 |
object[] objRec = (object[])arExecList[0]; |
|
| 546 |
NowValue = CommonMotions.cnvInt(objRec[0]); |
|
| 547 |
} |
|
| 548 |
|
|
| 521 | 549 |
// 1日分の給与を取得する |
| 522 |
//double dSaraly = Get1DaysSalaryForOperating(PersonDB, CurRec.CompanyCode); |
|
| 523 | 550 |
double dSaraly = Get1DaysSalaryForFixed(PersonDB, CurRec.CompanyCode, CurRec.GroupCount); |
| 524 | 551 |
|
| 525 | 552 |
switch (CurRec.SalaryFlg) |
| ... | ... | |
| 527 | 554 |
case (int)CommonDefine.SalaryDevision.All: // 全日振分 |
| 528 | 555 |
// 指定日までの稼働日数を掛けた値をセットする |
| 529 | 556 |
dSaraly *= WorkingDay; |
| 557 |
// 元の値を加算する |
|
| 558 |
dSaraly += NowValue; |
|
| 530 | 559 |
break; |
| 531 | 560 |
case (int)CommonDefine.SalaryDevision.Noting: // 振分無 |
| 532 | 561 |
// 給与振分無 |
| 533 | 562 |
dSaraly = 0; |
| 534 |
LoopBreak = true; |
|
| 535 | 563 |
break; |
| 536 | 564 |
case (int)CommonDefine.SalaryDevision.DaysInput: // 日数入力 |
| 537 | 565 |
// 日当加算判定を行う |
| ... | ... | |
| 544 | 572 |
{
|
| 545 | 573 |
dSaraly = 0; |
| 546 | 574 |
} |
| 547 |
LoopBreak = true; |
|
| 548 | 575 |
break; |
| 549 | 576 |
default: |
| 550 | 577 |
break; |
| 551 | 578 |
} |
| 552 | 579 |
// 計算値が実行金額より大きい場合は処理しない |
| 553 |
if (CurRec.ExecutionAmount < dSaraly) continue; |
|
| 580 |
//if (CurRec.ExecutionAmount < dSaraly) continue;
|
|
| 554 | 581 |
|
| 555 | 582 |
DateTime ParaDate = new DateTime(TargetDate.Year, TargetDate.Month, 1); |
| 556 | 583 |
// 支払いデータ書込み |
| 557 | 584 |
if (!AddOrSetSalary(LedgerExDB |
| 558 |
, ConstrCode, CurRec.GroupCount, CurRec.LineCount, ColPoint, (int)dSaraly, ParaDate))
|
|
| 585 |
, LedgerRec.ConstructionCode, CurRec.GroupCount, CurRec.LineCount, ColPoint, (int)dSaraly, ParaDate))
|
|
| 559 | 586 |
{
|
| 560 | 587 |
LedgerExDB.rollback(); |
| 588 |
PersonDB.rollback(); |
|
| 561 | 589 |
return false; |
| 562 | 590 |
} |
| 563 | 591 |
} |
| ... | ... | |
| 567 | 595 |
bool bret = true; |
| 568 | 596 |
|
| 569 | 597 |
// 工事コードのセット |
| 570 |
frm.ConstructionCode = ConstrCode;
|
|
| 598 |
frm.ConstructionCode = LedgerRec.ConstructionCode;
|
|
| 571 | 599 |
|
| 572 | 600 |
// 見えない画面を出す |
| 573 | 601 |
frm.Hide(); |
| ... | ... | |
| 581 | 609 |
frm.Close(); |
| 582 | 610 |
|
| 583 | 611 |
// データ初期セット時に振分無・日数入力は次のループをしない |
| 584 |
if (bSetFlag && LoopBreak) bret = false; |
|
| 612 |
//if (bSetFlag && LoopBreak) bret = false;
|
|
| 585 | 613 |
|
| 586 | 614 |
return bret; |
| 587 | 615 |
} |
| ... | ... | |
| 592 | 620 |
} |
| 593 | 621 |
finally |
| 594 | 622 |
{
|
| 595 |
LedgerDB.close(); LedgerDB = null; |
|
| 596 | 623 |
LedgerDeDB.close(); LedgerDeDB = null; |
| 597 | 624 |
LedgerExDB.close(); LedgerExDB = null; |
| 598 | 625 |
PersonDB.close(); PersonDB = null; |
| ... | ... | |
| 637 | 664 |
} |
| 638 | 665 |
#endregion |
| 639 | 666 |
|
| 640 |
#region 平均稼働数より1日分の給与を取得する |
|
| 641 |
/// <summary> |
|
| 642 |
/// 平均稼働数より1日分の給与を取得する |
|
| 643 |
/// </summary> |
|
| 644 |
/// <param name="PersonCode"></param> |
|
| 645 |
/// <returns></returns> |
|
| 646 |
private static double Get1DaysSalaryForOperating(IOMPersonInCharge PersonDB, int PersonCode, int GroupCount) |
|
| 647 |
{
|
|
| 648 |
try |
|
| 649 |
{
|
|
| 650 |
int monthSalary = 0; |
|
| 651 |
if (GroupCount == (int)FrmConstructionLedger.DataGroup.Payroll) |
|
| 652 |
{ // 担当者給与の場合
|
|
| 653 |
// 担当者マスタより給与月額を取得する |
|
| 654 |
string strPerson = PersonDB.CreatePrimarykeyString(PersonCode); |
|
| 655 |
PersonInChargeMaster personRec = new PersonInChargeMaster(); |
|
| 656 |
PersonDB.SelectAction(strPerson, ref personRec, false); |
|
| 657 |
|
|
| 658 |
// 出勤補正値係数を掛ける |
|
| 659 |
monthSalary = CommonMotions.cnvRound(personRec.MonthlySalary * (double)CommonDefine.s_SalaryCorrection); |
|
| 660 |
} |
|
| 661 |
else if (GroupCount == (int)FrmConstructionLedger.DataGroup.Instructor) |
|
| 662 |
{
|
|
| 663 |
// 指導員月額を取得する |
|
| 664 |
monthSalary = CommonDefine.InstructorMonthryCost; |
|
| 665 |
} |
|
| 666 |
else if (GroupCount == (int)FrmConstructionLedger.DataGroup.Assistant) |
|
| 667 |
{
|
|
| 668 |
// 副担当者月額を取得する |
|
| 669 |
monthSalary = CommonDefine.AssistantMonthryCost; |
|
| 670 |
} |
|
| 671 |
|
|
| 672 |
// 計算値を月稼働日数で割る |
|
| 673 |
double daylySalary = monthSalary / CommonDefine.s_WorkingDaysOfMonth; |
|
| 674 |
|
|
| 675 |
return daylySalary; |
|
| 676 |
} |
|
| 677 |
catch (Exception ex) |
|
| 678 |
{
|
|
| 679 |
logger.ErrorFormat("システムエラー:{0}:{1}", CommonMotions.GetMethodName(), ex.Message);
|
|
| 680 |
return 0; |
|
| 681 |
} |
|
| 682 |
} |
|
| 683 |
#endregion |
|
| 684 |
|
|
| 685 | 667 |
#region 月工数より1日分の給与を取得する |
| 686 | 668 |
/// <summary> |
| 687 | 669 |
/// 月工数より1日分の給与を取得する |
| ... | ... | |
| 693 | 675 |
try |
| 694 | 676 |
{
|
| 695 | 677 |
int monthSalary = 0; |
| 696 |
|
|
| 678 |
|
|
| 697 | 679 |
if (GroupCount == (int)FrmConstructionLedger.DataGroup.Payroll) |
| 698 | 680 |
{ // 担当者給与の場合
|
| 699 |
// 担当者マスタより給与月額を取得する
|
|
| 700 |
string strPerson = PersonDB.CreatePrimarykeyString(PersonCode);
|
|
| 701 |
PersonInChargeMaster personRec = new PersonInChargeMaster();
|
|
| 702 |
PersonDB.SelectAction(strPerson, ref personRec, false);
|
|
| 681 |
double MonthryCost = 0;
|
|
| 682 |
double YearsCost = 0;
|
|
| 683 |
// 担当者給与金額取得処理(セッションコネクト別)
|
|
| 684 |
CommonMotions.GetSalaryValue(PersonDB, PersonCode, ref MonthryCost, ref YearsCost, DateTime.Today);
|
|
| 703 | 685 |
|
| 704 | 686 |
// 出勤補正値係数を掛ける |
| 705 |
monthSalary = CommonMotions.cnvRound(personRec.MonthlySalary * (double)CommonDefine.s_SalaryCorrection);
|
|
| 687 |
monthSalary = CommonMotions.cnvRound(MonthryCost * (double)CommonDefine.s_SalaryCorrection);
|
|
| 706 | 688 |
|
| 707 | 689 |
} |
| 708 | 690 |
else if (GroupCount == (int)FrmConstructionLedger.DataGroup.Instructor) |
| ... | ... | |
| 750 | 732 |
{
|
| 751 | 733 |
// キー作成 |
| 752 | 734 |
string strSQL = LedgerExDB.CreatePrimarykeyString(ConstrCode, GroupCount, LineCount, ColumnCount); |
| 753 |
strSQL += string.Format(" AND TargetMonth = TO_DATE('{0}','YYYY/MM/DD')", ColumnDate.ToShortDateString());
|
|
| 735 |
strSQL += string.Format(" AND TRUNC(TargetMonth) = TO_DATE('{0}','YYYY/MM/DD')", ColumnDate.ToShortDateString());
|
|
| 754 | 736 |
|
| 755 | 737 |
// データ読込み |
| 756 | 738 |
List<ConstructionLedgerExcute> LedgerExDBList = new List<ConstructionLedgerExcute>(); |
| ... | ... | |
| 766 | 748 |
LedgerExDBRec.TargetMonth = ColumnDate; // 対象年月 |
| 767 | 749 |
|
| 768 | 750 |
// データ作成 |
| 769 |
bool bSaccess = LedgerExDB.InsertAction(LedgerExDBRec, false);
|
|
| 751 |
if (!LedgerExDB.InsertAction(LedgerExDBRec, false)) return false;
|
|
| 770 | 752 |
|
| 771 |
if (bSaccess) return true; |
|
| 772 |
else return false; |
|
| 753 |
return true; |
|
| 773 | 754 |
} |
| 774 | 755 |
|
| 775 | 756 |
// データ更新 |
| trunk/src/ProcessManagement/ProcessManagement/Common/Process/ClsExcute.cs | ||
|---|---|---|
| 45 | 45 |
public enum ProcessExecuteNo |
| 46 | 46 |
{
|
| 47 | 47 |
MainMenu = 0, // 0:メニュー |
| 48 |
ConstructionList, // 1:工事情報一覧 |
|
| 49 |
ConstructionBaseInfo, // 2:工事情報入力 |
|
| 50 |
EstimateInput, // 3:積算見積入力 |
|
| 51 |
EstimatePrint, // 4:積算見積書印刷 |
|
| 52 |
EstimateBudget, // 5:積算予算書入力 |
|
| 53 |
ConstructionBudget, // 6:工事予算書入力 |
|
| 54 |
ApprovalDocumentList, // 7:承認申請一覧 |
|
| 55 |
ConstructionCopyList, // 8:工事案件コピー機能 |
|
| 56 |
PurchaseOrderEntry, // 9:注文書入力 |
|
| 57 |
PurchaseOrderPrint, // 10:注文書印刷 |
|
| 58 |
ConstructionLedgerList, // 11:工事詳細台帳一覧 |
|
| 59 |
ConstructionLedger, // 12:工事詳細台帳 |
|
| 60 |
TAndPCosts, // 13:交通費及び購入品入力 |
|
| 61 |
DRList, // 14:日報一覧 |
|
| 62 |
DRConstruction, // 15:工事日報入力 |
|
| 63 |
Proceedings, // 16:発注者打ち合わせ議事録入力 |
|
| 64 |
DailyReportList, // 17:日報一覧 |
|
| 65 |
DailyReport, // 18:日報全般 |
|
| 66 |
DepartmentExpenssList, // 19:部署別台帳まとめ一覧 |
|
| 67 |
ConstrLedgerPrsonList, // 20:工事詳細台帳一覧(個人指定) |
|
| 48 |
ConstructionList = 1, // 1:工事情報一覧 |
|
| 49 |
ConstructionBaseInfo = 2, // 2:工事情報入力 |
|
| 50 |
EstimateInput = 3, // 3:積算見積入力 |
|
| 51 |
EstimatePrint = 4, // 4:積算見積書印刷 |
|
| 52 |
EstimateBudget = 5, // 5:積算予算書入力 |
|
| 53 |
ConstructionBudget = 6, // 6:工事予算書入力 |
|
| 54 |
ApprovalDocumentList = 7, // 7:承認申請一覧 |
|
| 55 |
ConstructionCopyList = 8, // 8:工事案件コピー機能 |
|
| 56 |
PurchaseOrderEntry = 9, // 9:注文書入力 |
|
| 57 |
PurchaseOrderPrint = 10, // 10:注文書印刷 |
|
| 58 |
DepartmentExpenssList = 11, // 11:部署別台帳一覧 |
|
| 59 |
ConstructionLedgerList = 12, // 12:工事詳細台帳一覧 |
|
| 60 |
ConstructionLedger = 13, // 13:工事詳細台帳 |
|
| 61 |
TAndPCosts = 14, // 14:交通費及び購入品入力 |
|
| 62 |
DRList = 15, // 15:日報一覧 |
|
| 63 |
DRConstruction = 16, // 16:工事日報入力 |
|
| 64 |
Proceedings = 17, // 17:発注者打ち合わせ議事録入力 |
|
| 65 |
DailyReportList = 18, // 18:日報一覧 |
|
| 66 |
DailyReport = 19, // 19:日報全般 |
|
| 68 | 67 |
} |
| 69 | 68 |
#endregion |
| 70 | 69 |
|
| ... | ... | |
| 74 | 73 |
/// </summary> |
| 75 | 74 |
public enum MaintenanceExecuteNo |
| 76 | 75 |
{
|
| 77 |
System = 101, // 1:システム管理 |
|
| 78 |
Department, // 2:部署マスタ |
|
| 79 |
PersonInCharge, // 3:担当者 |
|
| 80 |
Component, // 4:大項目マスタ(構成マスタ) |
|
| 81 |
ConstructionItem, // 5:中項目マスタ(工種マスタ) |
|
| 82 |
ConstructionWork, // 6:小項目マスタ(作業マスタ) |
|
| 83 |
Unit, // 7:単位マスタ |
|
| 84 |
SubContractor, // 8:協力会社マスタ |
|
| 85 |
Orderers, // 9:発注者マスタ |
|
| 86 |
BusinessType, // 10:法人格マスタ |
|
| 87 |
Division, // 11:区分マスタ |
|
| 88 |
Expenses, // 12:経費率マスタ |
|
| 89 |
SubContractorItem, // 13:協力会社工種マスタ |
|
| 90 |
Calender, // 14:カレンダーマスタ |
|
| 91 |
VehicleMaster, // 15:車両マスタ |
|
| 92 |
TermMaster, // 16:期限マスタ |
|
| 93 |
SaleSalesGraphData, // 17:売上グラフデータ入力 |
|
| 94 |
ApprovalRoute, // 18:承認経路マスタ |
|
| 95 |
ConstructionType, // 19:工事種別マスタ |
|
| 96 |
ComponentLink, // 20:大・中項目関連マスタ |
|
| 97 |
AlwaysEmployment, // 21:常雇者マスタ |
|
| 98 |
Suppliers, // 22:仕入先マスタ |
|
| 99 |
SubContractorJobCategory, // 23:協力会社職種マスタ |
|
| 76 |
System = 101, // 101:システム管理 |
|
| 77 |
Department = 102, // 102:部署マスタ |
|
| 78 |
PersonInCharge = 103, // 103:担当者 |
|
| 79 |
Component = 104, // 104:大項目マスタ(構成マスタ) |
|
| 80 |
ConstructionItem = 105, // 105:中項目マスタ(工種マスタ) |
|
| 81 |
ConstructionWork = 106, // 106:小項目マスタ(作業マスタ) |
|
| 82 |
ComponentLink = 107, // 107:大・中項目関連マスタ |
|
| 83 |
Unit = 108, // 108:単位マスタ |
|
| 84 |
SubContractor = 109, // 109:協力会社マスタ |
|
| 85 |
Orderers = 110, // 110:発注者マスタ |
|
| 86 |
BusinessType = 111, // 111:法人格マスタ |
|
| 87 |
Division = 112, // 112:区分マスタ |
|
| 88 |
//Expenses = 113, // 113:経費率マスタ |
|
| 89 |
SubContractorItem = 114, // 114:協力会社工種マスタ |
|
| 90 |
Calender = 115, // 115:カレンダーマスタ |
|
| 91 |
VehicleMaster = 116, // 116:車両マスタ |
|
| 92 |
TermMaster = 117, // 117:期限マスタ |
|
| 93 |
SaleSalesGraphData = 118, // 118:売上グラフデータ入力 |
|
| 94 |
ApprovalRoute = 119, // 119:承認経路マスタ |
|
| 95 |
ConstructionType = 120, // 120:工事種別マスタ |
|
| 96 |
AlwaysEmployment = 121, // 121:常雇者マスタ |
|
| 97 |
Suppliers = 122, // 122:仕入先マスタ |
|
| 98 |
SubContractorJobCategory = 123, // 123:協力会社職種マスタ |
|
| 99 |
Security = 124, // 124:セキュリティ区分マスタ |
|
| 100 |
OrderDivision = 125, // 125:発注者区分登録 |
|
| 101 |
ConstructionExpenses = 126, // 126:施工経費区分登録 |
|
| 100 | 102 |
} |
| 101 | 103 |
#endregion |
| 102 | 104 |
|
| ... | ... | |
| 106 | 108 |
/// </summary> |
| 107 | 109 |
public enum SubFormExecuteNo |
| 108 | 110 |
{
|
| 109 |
MessageWriter = 201, // 1:掲示板入力(新バージョン)
|
|
| 110 |
MessageReader, // 2:掲示板読込
|
|
| 111 |
ActionSchdule, // 3:行動予定入力
|
|
| 112 |
VehicleSchdule, // 4:車両予約入力
|
|
| 113 |
ApprovalScreen, // 5:承認画面
|
|
| 114 |
SubconstractorDiag, // 6:協力会社検索画面
|
|
| 115 |
SuppliersDiag, // 7:仕入先検索
|
|
| 116 |
SubConJobDiag, // 8:協力会社職種検索画面
|
|
| 111 |
MessageWriter = 201, // 201:掲示板入力(新バージョン)
|
|
| 112 |
MessageReader = 202, // 202:掲示板読込
|
|
| 113 |
ActionSchdule = 203, // 203:行動予定入力
|
|
| 114 |
VehicleSchdule = 204, // 204:車両予約入力
|
|
| 115 |
ApprovalScreen = 205, // 205:承認画面
|
|
| 116 |
SubconstractorDiag = 206, // 206:協力会社検索画面
|
|
| 117 |
SuppliersDiag = 207, // 207:仕入先検索
|
|
| 118 |
SubConJobDiag = 208, // 208:協力会社職種検索画面
|
|
| 117 | 119 |
} |
| 118 | 120 |
#endregion |
| 119 | 121 |
|
| ... | ... | |
| 122 | 124 |
/// 処理名称一覧 |
| 123 | 125 |
/// </summary> |
| 124 | 126 |
public static Dictionary<int, string> ProcessExecuteName = new Dictionary<int, string>(){
|
| 125 |
{ 0, "メインメニュー"},
|
|
| 126 |
{ 1, "工事情報一覧-表示"},
|
|
| 127 |
{ 2, "工事情報-入力"},
|
|
| 128 |
{ 3, "積算見積書-入力"},
|
|
| 129 |
{ 4, "積算見積書-印刷"},
|
|
| 130 |
{ 5, "積算予算書-入力"},
|
|
| 131 |
{ 6, "工事予算書-入力"},
|
|
| 132 |
{ 7, "承認申請一覧-表示"},
|
|
| 133 |
{ 8, "工事案件コピー-機能"},
|
|
| 134 |
{ 9, "注文書-入力"},
|
|
| 135 |
{10, "注文書-印刷"},
|
|
| 136 |
{12, "工事詳細台帳-入力"},
|
|
| 137 |
{13, "交通費及び購入品等-入力"},
|
|
| 138 |
{14, "工事日報-一覧"},
|
|
| 139 |
{15, "工事日報-入力"},
|
|
| 127 |
{ (int)ProcessExecuteNo.MainMenu, "メインメニュー"},
|
|
| 128 |
{ (int)ProcessExecuteNo.ConstructionList, "工事情報一覧-表示"},
|
|
| 129 |
{ (int)ProcessExecuteNo.ConstructionBaseInfo, "工事情報-入力"},
|
|
| 130 |
{ (int)ProcessExecuteNo.EstimateInput, "積算見積書-入力"},
|
|
| 131 |
{ (int)ProcessExecuteNo.EstimatePrint, "積算見積書-印刷"},
|
|
| 132 |
{ (int)ProcessExecuteNo.EstimateBudget, "積算予算書-入力"},
|
|
| 133 |
{ (int)ProcessExecuteNo.ConstructionBudget, "工事予算書-入力"},
|
|
| 134 |
{ (int)ProcessExecuteNo.ApprovalDocumentList, "承認申請一覧-表示"},
|
|
| 135 |
{ (int)ProcessExecuteNo.ConstructionCopyList, "工事案件コピー-機能"},
|
|
| 136 |
{ (int)ProcessExecuteNo.PurchaseOrderEntry, "注文書-入力"},
|
|
| 137 |
{ (int)ProcessExecuteNo.PurchaseOrderPrint, "注文書-印刷"},
|
|
| 138 |
{ (int)ProcessExecuteNo.DepartmentExpenssList, "部署別台帳-一覧"},
|
|
| 139 |
{ (int)ProcessExecuteNo.ConstructionLedgerList, "工事詳細台帳-一覧"},
|
|
| 140 |
{ (int)ProcessExecuteNo.ConstructionLedger, "工事詳細台帳-入力"},
|
|
| 141 |
{ (int)ProcessExecuteNo.TAndPCosts, "交通費及び購入品等-入力"},
|
|
| 142 |
{ (int)ProcessExecuteNo.DRList, "工事日報-一覧"},
|
|
| 143 |
{ (int)ProcessExecuteNo.DRConstruction, "工事日報-入力"},
|
|
| 144 |
//{ (int)ProcessExecuteNo.Proceedings, "発注者打ち合わせ議事録-入力"},
|
|
| 145 |
//{ (int)ProcessExecuteNo.DailyReportList, "日報-一覧"},
|
|
| 146 |
//{ (int)ProcessExecuteNo.DailyReport, "日報全般"},
|
|
| 140 | 147 |
}; |
| 141 | 148 |
|
| 142 | 149 |
#endregion |
| 143 | 150 |
|
| 151 |
#region マスタメンテンナス処理名称 |
|
| 152 |
/// <summary> |
|
| 153 |
/// マスタメンテナンス処理名称一覧 |
|
| 154 |
/// </summary> |
|
| 155 |
public static Dictionary<int, string> MaintenanceExecuteName = new Dictionary<int, string>(){
|
|
| 156 |
{ (int)MaintenanceExecuteNo.System, "システム管理登録"}, // 101
|
|
| 157 |
{ (int)MaintenanceExecuteNo.Department, "部署登録"}, // 102
|
|
| 158 |
{ (int)MaintenanceExecuteNo.PersonInCharge, "担当者登録"}, // 103
|
|
| 159 |
{ (int)MaintenanceExecuteNo.Component, "大項目登録(構成登録)"}, // 104
|
|
| 160 |
{ (int)MaintenanceExecuteNo.ConstructionItem, "中項目登録(工種登録)"}, // 105
|
|
| 161 |
{ (int)MaintenanceExecuteNo.ConstructionWork, "小項目登録(作業登録)"}, // 106
|
|
| 162 |
{ (int)MaintenanceExecuteNo.ComponentLink, "大・中項目関連登録"}, // 107
|
|
| 163 |
{ (int)MaintenanceExecuteNo.Unit, "単位登録"}, // 108
|
|
| 164 |
{ (int)MaintenanceExecuteNo.SubContractor, "協力会社登録"}, // 109
|
|
| 165 |
{ (int)MaintenanceExecuteNo.Orderers, "発注者登録"}, // 110
|
|
| 166 |
{ (int)MaintenanceExecuteNo.BusinessType, "法人格登録"}, // 111
|
|
| 167 |
//{ (int)MaintenanceExecuteNo.Division, "区分登録"}, // 112
|
|
| 168 |
//{ (int)MaintenanceExecuteNo.Expenses, "経費率登録"}, // 113
|
|
| 169 |
{ (int)MaintenanceExecuteNo.SubContractorItem, "協力会社工種登録"}, // 114
|
|
| 170 |
{ (int)MaintenanceExecuteNo.Calender, "カレンダー登録"}, // 115
|
|
| 171 |
{ (int)MaintenanceExecuteNo.VehicleMaster, "車両登録"}, // 116
|
|
| 172 |
{ (int)MaintenanceExecuteNo.TermMaster, "期限登録"}, // 117
|
|
| 173 |
{ (int)MaintenanceExecuteNo.SaleSalesGraphData, "売上グラフデータ入力"}, // 118
|
|
| 174 |
{ (int)MaintenanceExecuteNo.ApprovalRoute, "承認経路登録"}, // 119
|
|
| 175 |
{ (int)MaintenanceExecuteNo.ConstructionType, "工事種別登録"}, // 120
|
|
| 176 |
{ (int)MaintenanceExecuteNo.AlwaysEmployment, "常雇者登録"}, // 121
|
|
| 177 |
{ (int)MaintenanceExecuteNo.Suppliers, "仕入先登録"}, // 122
|
|
| 178 |
{ (int)MaintenanceExecuteNo.SubContractorJobCategory, "協力会社職種登録"}, // 123
|
|
| 179 |
{ (int)MaintenanceExecuteNo.Security, "セキュリティ区分登録"}, // 124
|
|
| 180 |
{ (int)MaintenanceExecuteNo.OrderDivision, "発注者区分登録"}, // 125
|
|
| 181 |
{ (int)MaintenanceExecuteNo.ConstructionExpenses, "施工経費区分登録"}, // 126
|
|
| 182 |
}; |
|
| 183 |
#endregion |
|
| 184 |
|
|
| 144 | 185 |
#region 承認処理定義 |
| 145 | 186 |
/// <summary> |
| 146 | 187 |
/// 承認一覧 |
| ... | ... | |
| 339 | 380 |
case (int)ProcessExecuteNo.DRConstruction: // 15:工事日報入力 |
| 340 | 381 |
ProcessExecuteNo_DRConstruction(m_ProcControlPara[NowPoint]); |
| 341 | 382 |
break; |
| 342 |
|
|
| 383 |
|
|
| 343 | 384 |
case (int)ProcessExecuteNo.Proceedings: // 16:発注者打ち合わせ議事録入力 |
| 344 | 385 |
ProcessExecuteNo_Proceedings(m_ProcControlPara[NowPoint]); |
| 345 | 386 |
break; |
| ... | ... | |
| 356 | 397 |
ProcessExecuteNo_DepartmentExpenssList(m_ProcControlPara[NowPoint]); |
| 357 | 398 |
break; |
| 358 | 399 |
|
| 359 |
case (int)ProcessExecuteNo.ConstrLedgerPrsonList: // 20:工事詳細台帳一覧(個人指定) |
|
| 360 |
ProcessExecuteNo_ConstrLedgerPersonList(m_ProcControlPara[NowPoint]); |
|
| 361 |
break; |
|
| 362 |
|
|
| 363 | 400 |
#endregion |
| 364 | 401 |
|
| 365 | 402 |
#region マスタメンテ |
| ... | ... | |
| 394 | 431 |
case (int)MaintenanceExecuteNo.BusinessType: // 10:法人格マスタ |
| 395 | 432 |
MaintenanceExecuteNo_BusinessType(m_ProcControlPara[NowPoint]); |
| 396 | 433 |
break; |
| 397 |
case (int)MaintenanceExecuteNo.Division: // 11:区分マスタ |
|
| 398 |
MaintenanceExecuteNo_Division(m_ProcControlPara[NowPoint]); |
|
| 399 |
break; |
|
| 400 |
case (int)MaintenanceExecuteNo.Expenses: // 12:経費率マスタ |
|
| 401 |
MaintenanceExecuteNo_Expenses(m_ProcControlPara[NowPoint]); |
|
| 402 |
break; |
|
| 434 |
//case (int)MaintenanceExecuteNo.Division: // 11:区分マスタ
|
|
| 435 |
// MaintenanceExecuteNo_Division(m_ProcControlPara[NowPoint]);
|
|
| 436 |
// break;
|
|
| 437 |
//case (int)MaintenanceExecuteNo.Expenses: // 12:経費率マスタ
|
|
| 438 |
// MaintenanceExecuteNo_Expenses(m_ProcControlPara[NowPoint]);
|
|
| 439 |
// break;
|
|
| 403 | 440 |
case (int)MaintenanceExecuteNo.SubContractorItem: // 13:協力会社工種マスタ |
| 404 | 441 |
MaintenanceExecuteNo_SubContractorItem(m_ProcControlPara[NowPoint]); |
| 405 | 442 |
break; |
| ... | ... | |
| 433 | 470 |
case (int)MaintenanceExecuteNo.SubContractorJobCategory: // 23:協力会社職種マスタ |
| 434 | 471 |
MaintenanceExecuteNo_SubContractorJobCategory(m_ProcControlPara[NowPoint]); |
| 435 | 472 |
break; |
| 473 |
case (int)MaintenanceExecuteNo.Security: // 24:セキュリティ区分マスタ |
|
| 474 |
MaintenanceExecuteNo_Security(m_ProcControlPara[NowPoint]); |
|
| 475 |
break; |
|
| 476 |
case (int)MaintenanceExecuteNo.OrderDivision: // 125:発注者区分登録 |
|
| 477 |
MaintenanceExecuteNo_OrderDivision(m_ProcControlPara[NowPoint]); |
|
| 478 |
break; |
|
| 479 |
case (int)MaintenanceExecuteNo.ConstructionExpenses: // 126:施工経費区分登録 |
|
| 480 |
MaintenanceExecuteNo_ConstructionExpenses(m_ProcControlPara[NowPoint]); |
|
| 481 |
break; |
|
| 482 |
|
|
| 436 | 483 |
#endregion |
| 437 | 484 |
|
| 438 | 485 |
#region サブフォーム |
| ... | ... | |
| 440 | 487 |
case (int)SubFormExecuteNo.MessageWriter: // 1:掲示板入力(新バージョン) |
| 441 | 488 |
SubFormExecuteNo_MessageWriter(m_ProcControlPara[NowPoint]); |
| 442 | 489 |
break; |
| 443 |
|
|
| 490 |
|
|
| 444 | 491 |
case (int)SubFormExecuteNo.MessageReader: // 2:掲示板読込 |
| 445 | 492 |
SubFormExecuteNo_MessageReader(m_ProcControlPara[NowPoint]); |
| 446 | 493 |
break; |
| 447 |
|
|
| 494 |
|
|
| 448 | 495 |
case (int)SubFormExecuteNo.ActionSchdule: // 3:行動予定入力 |
| 449 | 496 |
SubFormExecuteNo_ActionSchdule(m_ProcControlPara[NowPoint]); |
| 450 | 497 |
break; |
| ... | ... | |
| 634 | 681 |
catch (Exception ex) |
| 635 | 682 |
{
|
| 636 | 683 |
logger.ErrorFormat("システムエラー:{0}:{1}", CommonMotions.GetMethodName(), ex.Message);
|
| 684 |
BackProcess(); |
|
| 637 | 685 |
} |
| 638 | 686 |
finally |
| 639 | 687 |
{
|
| ... | ... | |
| 658 | 706 |
ClsExcute.SubFormHandleList[ProcessNo].ProcessNo = ProcessNo; |
| 659 | 707 |
ClsExcute.SubFormHandleList[ProcessNo].SubFormHandle = (Form)frm; |
| 660 | 708 |
|
| 709 |
// 起動・編集フラグ |
|
| 710 |
int EditFlg = (int)CommonDefine.ProcessDataEdit.Reference; |
|
| 711 |
if (!ClsSecurityPermission.GetExecutePermission(ProcessNo, ref EditFlg)) |
|
| 712 |
{
|
|
| 713 |
BackProcess(); |
|
| 714 |
return; |
|
| 715 |
} |
|
| 716 |
if (EditFlg == (int)CommonDefine.ProcessDataEdit.Reference) frm.EditLock = true; |
|
| 717 |
|
|
| 661 | 718 |
// パラメータセット |
| 662 | 719 |
frm.ConstructionCode = CurrentPara.IntExecParameter[0]; |
| 663 | 720 |
// コピーデータ作成フラグセット |
| ... | ... | |
| 670 | 727 |
catch (Exception ex) |
| 671 | 728 |
{
|
| 672 | 729 |
logger.ErrorFormat("システムエラー:{0}:{1}", CommonMotions.GetMethodName(), ex.Message);
|
| 730 |
BackProcess(); |
|
| 673 | 731 |
} |
| 674 | 732 |
finally |
| 675 | 733 |
{
|
| ... | ... | |
| 694 | 752 |
ClsExcute.SubFormHandleList[ProcessNo].ProcessNo = ProcessNo; |
| 695 | 753 |
ClsExcute.SubFormHandleList[ProcessNo].SubFormHandle = (Form)frm; |
| 696 | 754 |
|
| 755 |
// 起動・編集フラグ |
|
| 756 |
int EditFlg = (int)CommonDefine.ProcessDataEdit.Reference; |
|
| 757 |
if (!ClsSecurityPermission.GetExecutePermission(ProcessNo, ref EditFlg)) |
|
| 758 |
{
|
|
| 759 |
BackProcess(); |
|
| 760 |
return; |
|
| 761 |
} |
|
| 762 |
if (EditFlg == (int)CommonDefine.ProcessDataEdit.Reference) frm.EditLock = true; |
|
| 763 |
|
|
| 697 | 764 |
// パラメータセット |
| 698 | 765 |
frm.ConstructionCode = CurrentPara.IntExecParameter[0]; |
| 699 | 766 |
|
| ... | ... | |
| 703 | 770 |
catch (Exception ex) |
| 704 | 771 |
{
|
| 705 | 772 |
logger.ErrorFormat("システムエラー:{0}:{1}", CommonMotions.GetMethodName(), ex.Message);
|
| 773 |
BackProcess(); |
|
| 706 | 774 |
} |
| 707 | 775 |
finally |
| 708 | 776 |
{
|
| ... | ... | |
| 727 | 795 |
ClsExcute.SubFormHandleList[ProcessNo].ProcessNo = ProcessNo; |
| 728 | 796 |
ClsExcute.SubFormHandleList[ProcessNo].SubFormHandle = (Form)frm; |
| 729 | 797 |
|
| 798 |
// 起動・編集フラグ |
|
| 799 |
int EditFlg = (int)CommonDefine.ProcessDataEdit.Reference; |
|
| 800 |
if (!ClsSecurityPermission.GetExecutePermission(ProcessNo, ref EditFlg)) |
|
| 801 |
{
|
|
| 802 |
BackProcess(); |
|
| 803 |
return; |
|
| 804 |
} |
|
| 805 |
if (EditFlg == (int)CommonDefine.ProcessDataEdit.Reference) frm.EditLock = true; |
|
| 806 |
|
|
| 730 | 807 |
// パラメータセット |
| 731 | 808 |
frm.ConstructionCode = CurrentPara.IntExecParameter[0]; |
| 732 | 809 |
|
| ... | ... | |
| 737 | 814 |
catch (Exception ex) |
| 738 | 815 |
{
|
| 739 | 816 |
logger.ErrorFormat("システムエラー:{0}:{1}", CommonMotions.GetMethodName(), ex.Message);
|
| 817 |
BackProcess(); |
|
| 740 | 818 |
} |
| 741 | 819 |
finally |
| 742 | 820 |
{
|
| ... | ... | |
| 761 | 839 |
ClsExcute.SubFormHandleList[ProcessNo].ProcessNo = ProcessNo; |
| 762 | 840 |
ClsExcute.SubFormHandleList[ProcessNo].SubFormHandle = (Form)frm; |
| 763 | 841 |
|
| 842 |
// 起動・編集フラグ |
|
| 843 |
int EditFlg = (int)CommonDefine.ProcessDataEdit.Reference; |
|
| 844 |
if (!ClsSecurityPermission.GetExecutePermission(ProcessNo, ref EditFlg)) |
|
| 845 |
{
|
|
| 846 |
BackProcess(); |
|
| 847 |
return; |
|
| 848 |
} |
|
| 849 |
if (EditFlg == (int)CommonDefine.ProcessDataEdit.Reference) frm.EditLock = true; |
|
| 850 |
|
|
| 764 | 851 |
// パラメータセット |
| 765 | 852 |
frm.ConstructionCode = CurrentPara.IntExecParameter[0]; |
| 766 | 853 |
|
| ... | ... | |
| 770 | 857 |
catch (Exception ex) |
| 771 | 858 |
{
|
| 772 | 859 |
logger.ErrorFormat("システムエラー:{0}:{1}", CommonMotions.GetMethodName(), ex.Message);
|
| 860 |
BackProcess(); |
|
| 773 | 861 |
} |
| 774 | 862 |
finally |
| 775 | 863 |
{
|
| ... | ... | |
| 778 | 866 |
} |
| 779 | 867 |
#endregion |
| 780 | 868 |
|
| 781 |
#region 積算予算書印刷 |
|
| 782 |
/// <summary> |
|
| 783 |
/// 積算予算書印刷 |
|
| 784 |
/// </summary> |
|
| 785 |
/// <returns></returns> |
|
| 786 |
public static void ProcessExecuteNo_EstimateBudgetPrint(ProcessParameter CurrentPara) |
|
| 787 |
{
|
|
他の形式にエクスポート: Unified diff