<?xml version="1.0" encoding="UTF-8"?>
<!-- Evolutility - (c) 2012 Olivier Giulieri - www.evolutility.org  -->
<form label="To Do"  xmlns="http://www.evolutility.com">
<data entity="task" entities="tasks" 
dbtable="EVOL_ToDo" dborder="PriorityID, duedate" icon="todo.gif"   
dbcolumnlead="title" 
  splogin="EvoSP_Login @login, @password" 
  sppaging="EvoSP_PagedItem @SQLselect, @SQLtable, @SQLfrom, @SQLwhere, @SQLorderby, @SQLpk, @pageid, @pagesize" />
	<panel label="Task" width="62" >
		<field type="text" required="1" label="Title" cssclass="FieldMain" maxlength="255" dbcolumn="title" dbcolumnread="title" width="100" search="1" searchlist="1" searchadv="1" />
		<field type="date" label="Due Date" maxlength="10" dbcolumn="duedate" dbcolumnread="duedate"
			   width="40"  search="1" searchlist="1" searchadv="1"  />
		<field type="lov" required="1" label="Priority" dbcolumn="PriorityID" dbcolumnread="Priority" width="60"  dbtablelov="EVOL_ToDoPriority" dborderlov="id" search="2" searchlist="2" searchadv="2"/>
	</panel>
	<panel label="Status" width="38">
		<field type="lov" label="Category" dbcolumn="CategoryID" dbcolumnread="Category" width="100"  dbtablelov="EVOL_ToDoCategory" dborderlov="name" search="1" searchlist="1" searchadv="1"  />
		<field type="boolean" label="Complete" labellist="C." dbcolumn="Complete" dbcolumnread="Complete" width="50"  search="1" searchlist="1" searchadv="1"  img="checkb.gif"/>
	</panel>
	<panel label="Notes" width="100">
		<field type="textmultiline" label="" labeledit="Notes" labellist="Notes" maxlength="1000" dbcolumn="notes" dbcolumnread="notes" required="0" 
			   width="100" height="6" search="0" searchlist="0" searchadv="1" />
  </panel>
     <queries label="Selections">
        <query label="Urgent tasks" dbwhere="t.complete=0 AND categoryid&lt;3" url="asap" />
        <query label="Open tasks due in less than a week" dbwhere="t.complete=0 AND (datediff(Day,getdate(),duedate)&lt;7 AND datediff(Day,getdate(),duedate)&gt;-1)" url="thisweek" />
        <query label="Open tasks due in less than a month" dbwhere="t.complete=0 AND (datediff(m,getdate(),duedate)&lt;7 AND datediff(m,getdate(),duedate)&gt;-1)" url="thismonth" />
        <query label="Business and Finances tasks" dbwhere="categoryid in (4,6)" url="biz" />
        <query label="Open tasks" dbwhere="t.complete=0" url="open" />
        <query label="Completed tasks" dbwhere="t.complete=1" url="closed" />
    </queries>
</form> 
