From f71583152a52b4d07161af92d286306ba4397988 Mon Sep 17 00:00:00 2001
From: einhverfr <einhverfr@4979c152-3d1c-0410-bac9-87ea11338e46>
Date: Sat, 8 Dec 2007 09:07:43 +0000
Subject: More customer/vendor search enhancements

git-svn-id: https://ledger-smb.svn.sourceforge.net/svnroot/ledger-smb/trunk@1966 4979c152-3d1c-0410-bac9-87ea11338e46
---
 sql/Pg-database.sql | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

(limited to 'sql/Pg-database.sql')

diff --git a/sql/Pg-database.sql b/sql/Pg-database.sql
index 3e51a356..2b82eb8e 100644
--- a/sql/Pg-database.sql
+++ b/sql/Pg-database.sql
@@ -426,6 +426,8 @@ CREATE TABLE entity_credit_account (
     startdate date DEFAULT CURRENT_DATE,
     enddate date,
     threshold numeric default 0,
+    employee_id int references employee_entity(employee_id),
+    primary_contact int references person(id),
     PRIMARY KEY(entity_id, meta_number)
 );
 -- notes are from entity_note
@@ -614,7 +616,7 @@ CREATE TABLE ar (
   on_hold bool default false,
   reverse bool default false,
   approved bool default true,
-  credit_account int references entity_credit_account(id) not null,
+  entity_credit_account int references entity_credit_account(id) not null,
   description text
 );
 
@@ -650,7 +652,7 @@ CREATE TABLE ap (
   reverse bool default false,
   terms int2 DEFAULT 0,
   description text,
-  credit_account int references entity_credit_account(id)
+  entity_credit_account int references entity_credit_account(id)
 );
 
 COMMENT ON COLUMN ap.entity_id IS $$ Used to be customer_id, but customer is now metadata. You need to push to entity $$;
-- 
cgit v1.2.3

lder.debian.org/killed?h=master'>tree</a><a href='/notmuch/commit/tags/57/96/165979470556.18492.960118879067129240@wilder.debian.org/killed?h=master'>commit</a><a class='active' href='/notmuch/diff/tags/57/96/165979470556.18492.960118879067129240@wilder.debian.org/killed?h=master'>diff</a></td><td class='form'><form class='right' method='get' action='/notmuch/log/tags/57/96/165979470556.18492.960118879067129240@wilder.debian.org/killed'>
<input type='hidden' name='h' value='master'/><select name='qt'>
<option value='grep'>log msg</option>
<option value='author'>author</option>
<option value='committer'>committer</option>
<option value='range'>range</option>
</select>
<input class='txt' type='search' size='10' name='q' value=''/>
<input type='submit' value='search'/>
</form>
</td></tr></table>
<div class='path'>path: <a href='/notmuch/diff/?h=master'>root</a>/<a href='/notmuch/diff/tags?h=master'>tags</a>/<a href='/notmuch/diff/tags/57?h=master'>57</a>/<a href='/notmuch/diff/tags/57/96?h=master'>96</a>/<a href='/notmuch/diff/tags/57/96/165979470556.18492.960118879067129240@wilder.debian.org?h=master'>165979470556.18492.960118879067129240@wilder.debian.org</a>/<a href='/notmuch/diff/tags/57/96/165979470556.18492.960118879067129240@wilder.debian.org/killed?h=master'>killed</a></div><div class='content'><div class='cgit-panel'><b>diff options</b><form method='get'><input type='hidden' name='h' value='master'/><table><tr><td colspan='2'/></tr><tr><td class='label'>context:</td><td class='ctrl'><select name='context' onchange='this.form.submit();'><option value='1'>1</option><option value='2'>2</option><option value='3' selected='selected'>3</option><option value='4'>4</option><option value='5'>5</option><option value='6'>6</option><option value='7'>7</option><option value='8'>8</option><option value='9'>9</option><option value='10'>10</option><option value='15'>15</option><option value='20'>20</option><option value='25'>25</option><option value='30'>30</option><option value='35'>35</option><option value='40'>40</option></select></td></tr><tr><td class='label'>space:</td><td class='ctrl'><select name='ignorews' onchange='this.form.submit();'><option value='0' selected='selected'>include</option><option value='1'>ignore</option></select></td></tr><tr><td class='label'>mode:</td><td class='ctrl'><select name='dt' onchange='this.form.submit();'><option value='0' selected='selected'>unified</option><option value='1'>ssdiff</option><option value='2'>stat only</option></select></td></tr><tr><td/><td class='ctrl'><noscript><input type='submit' value='reload'/></noscript></td></tr></table></form></div><div class='diffstat-header'><a href='/notmuch/diff/?h=master'>Diffstat</a> (limited to 'tags/57/96/165979470556.18492.960118879067129240@wilder.debian.org/killed')</div><table summary='diffstat' class='diffstat'>