summaryrefslogtreecommitdiff
path: root/demos/time-tracker/protected/App_Data/SQLite/projects.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/projects.xml
parentddc0de38f64e5834ce04f0407a8416172b596655 (diff)
Add TDataSourceConfig, TSqlMapConfig, TActiveRecordConfig
Diffstat (limited to 'demos/time-tracker/protected/App_Data/SQLite/projects.xml')
-rw-r--r--demos/time-tracker/protected/App_Data/SQLite/projects.xml28
1 files changed, 14 insertions, 14 deletions
diff --git a/demos/time-tracker/protected/App_Data/SQLite/projects.xml b/demos/time-tracker/protected/App_Data/SQLite/projects.xml
index e5f52887..f28f7a47 100644
--- a/demos/time-tracker/protected/App_Data/SQLite/projects.xml
+++ b/demos/time-tracker/protected/App_Data/SQLite/projects.xml
@@ -21,8 +21,8 @@
INSERT INTO projects
(Name, Description, CreationDate, EstimateDuration, CompletionDate, CreatorID, ManagerID)
VALUES
- (#Name#, #Description#, php('date', 'Y-m-d H:i:s'), #EstimateDuration#,
- #CompletionDate, typeHandler=DateTime#,
+ (#Name#, #Description#, strftime('%s', 'now'), #EstimateDuration#,
+ #CompletionDate, typeHandler=DateTime#,
#CreatorUserName#, #ManagerUserName#)
<selectKey property="ID" type="post" resultClass="int">
select LAST_INSERT_ROWID() as value
@@ -30,7 +30,7 @@
</insert>
<select id="GetProjectByID" parameterClass="integer" resultMap="project-result">
- SELECT
+ SELECT
projects.ProjectID as ProjectID,
projects.Name as Name,
projects.Description as Description,
@@ -43,8 +43,8 @@
FROM projects
LEFT JOIN categories ON projects.ProjectID = categories.ProjectID
LEFT JOIN time_entry ON categories.CategoryID = time_entry.CategoryID
- WHERE
- projects.ProjectID = #value#
+ WHERE
+ projects.ProjectID = #value#
AND Disabled = 0
GROUP BY
projects.ProjectID
@@ -53,7 +53,7 @@
</select>
<select id="GetAllProjects" resultMap="project-result">
- SELECT
+ SELECT
projects.ProjectID as ProjectID,
projects.Name as Name,
projects.Description as Description,
@@ -66,7 +66,7 @@
FROM projects
LEFT JOIN categories ON projects.ProjectID = categories.ProjectID
LEFT JOIN time_entry ON categories.CategoryID = time_entry.CategoryID
- WHERE
+ WHERE
Disabled = 0
GROUP BY
projects.ProjectID
@@ -79,7 +79,7 @@
</select>
<select id="GetProjectsByManagerName" resultMap="project-result">
- SELECT
+ SELECT
projects.ProjectID as ProjectID,
projects.Name as Name,
projects.Description as Description,
@@ -92,8 +92,8 @@
FROM projects
LEFT JOIN categories ON projects.ProjectID = categories.ProjectID
LEFT JOIN time_entry ON categories.CategoryID = time_entry.CategoryID
- WHERE
- Disabled = 0
+ WHERE
+ Disabled = 0
AND projects.ManagerID = #value#
GROUP BY
projects.ProjectID
@@ -102,7 +102,7 @@
</select>
<select id="GetProjectsByUserName" resultMap="project-result">
- SELECT
+ SELECT
projects.ProjectID as ProjectID,
projects.Name as Name,
projects.Description as Description,
@@ -116,7 +116,7 @@
LEFT JOIN categories ON projects.ProjectID = categories.ProjectID
LEFT JOIN time_entry ON categories.CategoryID = time_entry.CategoryID,
project_members
- WHERE
+ WHERE
project_members.ProjectID = projects.ProjectID
AND project_members.UserID = #value#
AND projects.Disabled = 0
@@ -146,13 +146,13 @@
<update id="UpdateProject" parameterClass="ProjectRecord">
UPDATE projects
- SET
+ SET
CompletionDate = #CompletionDate, typeHandler=DateTime#,
Description = #Description#,
EstimateDuration = #EstimateDuration#,
ManagerId =#ManagerUserName#,
Name = #Name#
- WHERE
+ WHERE
ProjectID = #ID#
</update>