projects
/
Pman.Core
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
d03e79a
)
fix holiday
author
Alan
<alan@roojs.com>
Tue, 9 Apr 2024 06:43:19 +0000
(14:43 +0800)
committer
Alan
<alan@roojs.com>
Tue, 9 Apr 2024 06:43:19 +0000
(14:43 +0800)
DataObjects/Core_holiday.php
patch
|
blob
|
history
diff --git
a/DataObjects/Core_holiday.php
b/DataObjects/Core_holiday.php
index
3a2e9d5
..
76e0b8b
100644
(file)
--- a/
DataObjects/Core_holiday.php
+++ b/
DataObjects/Core_holiday.php
@@
-73,13
+73,9
@@
class Pman_Core_DataObjects_Core_holiday extends DB_DataObject
$fmt = substr($matches[1], 0, 4) . "-" . substr($matches[1], 4, 2) . "-" . substr($matches[1], 6, 2);
$end_dt = date('Y-m-d', strtotime($fmt));
}
$fmt = substr($matches[1], 0, 4) . "-" . substr($matches[1], 4, 2) . "-" . substr($matches[1], 6, 2);
$end_dt = date('Y-m-d', strtotime($fmt));
}
-<<<<<<< Updated upstream
-
-=======
if(preg_match('/^SUMMARY[^:]*:(.*)/', $line, $matches)){
$name = trim($matches[1]);
}
if(preg_match('/^SUMMARY[^:]*:(.*)/', $line, $matches)){
$name = trim($matches[1]);
}
->>>>>>> Stashed changes
}
if(empty($start_dt) || empty($end_dt)){
}
if(empty($start_dt) || empty($end_dt)){
@@
-95,15
+91,13
@@
class Pman_Core_DataObjects_Core_holiday extends DB_DataObject
$d->holiday_date = date('Y-m-d', $i);
if (!$d->count()) {
$d->insert();
$d->holiday_date = date('Y-m-d', $i);
if (!$d->count()) {
$d->insert();
-<<<<<<< Updated upstream
-=======
+
} else {
$d->find(true);
$dd = clone($d);
$d->name = $name;
$d->update($dd);
} else {
$d->find(true);
$dd = clone($d);
$d->name = $name;
$d->update($dd);
->>>>>>> Stashed changes
- }
+ }
}
}