summaryrefslogtreecommitdiff
path: root/demos/time-tracker/protected/App_Data/SQLite/time-entry.xml
diff options
context:
space:
mode:
authorwei <>2006-12-17 22:20:50 +0000
committerwei <>2006-12-17 22:20:50 +0000
commit2570226fbac3e26b1e94896b50d1db4bc1aa3308 (patch)
tree421108ccbdc0ef021e6af4fa35b1d6bcbc352b37 /demos/time-tracker/protected/App_Data/SQLite/time-entry.xml
parentddc0de38f64e5834ce04f0407a8416172b596655 (diff)
Add TDataSourceConfig, TSqlMapConfig, TActiveRecordConfig
Diffstat (limited to 'demos/time-tracker/protected/App_Data/SQLite/time-entry.xml')
-rw-r--r--demos/time-tracker/protected/App_Data/SQLite/time-entry.xml28
1 files changed, 14 insertions, 14 deletions
diff --git a/demos/time-tracker/protected/App_Data/SQLite/time-entry.xml b/demos/time-tracker/protected/App_Data/SQLite/time-entry.xml
index 1d7fec37..bb3c9e69 100644
--- a/demos/time-tracker/protected/App_Data/SQLite/time-entry.xml
+++ b/demos/time-tracker/protected/App_Data/SQLite/time-entry.xml
@@ -3,21 +3,21 @@
<insert id="AddNewTimeEntry" parameterClass="TimeEntryRecord">
INSERT INTO time_entry(
- EntryCreated,
- Duration,
- Description,
+ EntryCreated,
+ Duration,
+ Description,
CategoryID,
- EntryDate,
- CreatorID,
+ EntryDate,
+ CreatorID,
UserID
)
VALUES(
- php('date', 'Y-m-d H:i:s'),
- #Duration#,
- #Description#,
+ strftime('%s', 'now'),
+ #Duration#,
+ #Description#,
#Category.ID#,
- #ReportDate, typeHandler=DateTime#,
- #CreatorUserName#,
+ #ReportDate, typeHandler=DateTime#,
+ #CreatorUserName#,
#Username#
)
<selectKey property="ID" type="post" resultClass="int">
@@ -53,9 +53,9 @@
</resultMap>
<select id="GetTimeEntryByID" resultMap="time-entry-result">
- SELECT
+ SELECT
*
- FROM
+ FROM
time_entry
WHERE
EntryID = #value#
@@ -66,7 +66,7 @@
</delete>
<select id="GetAllTimeEntriesByProjectIdAndUser" resultMap="time-entry-category-result">
- SELECT
+ SELECT
time_entry.EntryID as EntryID,
time_entry.EntryCreated as EntryCreated,
time_entry.Duration as Duration,
@@ -82,7 +82,7 @@
time_entry.UserID = #username#
AND time_entry.CategoryID = categories.CategoryID
AND categories.ProjectID = #project#
- ORDER BY
+ ORDER BY
EntryID ASC
</select>