[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
SF.net SVN: ledger-smb: [2146] trunk
- Subject: SF.net SVN: ledger-smb: [2146] trunk
- From: ..hidden..
- Date: Wed, 14 May 2008 14:52:55 -0700
Revision: 2146
http://ledger-smb.svn.sourceforge.net/ledger-smb/?rev=2146&view=rev
Author: einhverfr
Date: 2008-05-14 14:52:10 -0700 (Wed, 14 May 2008)
Log Message:
-----------
Correcting vendor save issues
Modified Paths:
--------------
trunk/LedgerSMB/IS.pm
trunk/UI/Contact/contact.html
trunk/sql/modules/Company.sql
trunk/sql/modules/Location.sql
trunk/sql/modules/Payment.sql
trunk/sql/modules/Person.sql
Modified: trunk/LedgerSMB/IS.pm
===================================================================
--- trunk/LedgerSMB/IS.pm 2008-05-14 21:40:07 UTC (rev 2145)
+++ trunk/LedgerSMB/IS.pm 2008-05-14 21:52:10 UTC (rev 2146)
@@ -787,7 +787,7 @@
# get rest for the customer
my $query = qq|
SELECT c.customernumber, e.name, l.line_one as address1,
- l.line_two as address2, l.city_province AS city,
+ l.line_two as address2, l.city AS city,
'' as state, l.mail_code AS zipcode,
country.name as country,
'' as contact, '' as customerphone, '' as customerfax,
Modified: trunk/UI/Contact/contact.html
===================================================================
--- trunk/UI/Contact/contact.html 2008-05-14 21:40:07 UTC (rev 2145)
+++ trunk/UI/Contact/contact.html 2008-05-14 21:52:10 UTC (rev 2146)
@@ -533,6 +533,15 @@
</div>
<div>
<?lsmb PROCESS input element_data = {
+ label = text('Description:'),
+ name = "description"
+ value = description
+ type = "text"
+ size = "20"
+ } #' ?>
+ </div>
+ <div>
+ <?lsmb PROCESS input element_data = {
label = text('Contact Info:'),
name = "contact"
value = contact
Modified: trunk/sql/modules/Company.sql
===================================================================
--- trunk/sql/modules/Company.sql 2008-05-14 21:40:07 UTC (rev 2145)
+++ trunk/sql/modules/Company.sql 2008-05-14 21:52:10 UTC (rev 2146)
@@ -291,7 +291,7 @@
BEGIN
FOR out_row IN
SELECT l.id, l.line_one, l.line_two, l.line_three, l.city,
- l.state, c.name, lc.class
+ l.state, l.mail_code, c.name, lc.class
FROM location l
JOIN company_to_location ctl ON (ctl.location_id = l.id)
JOIN company cp ON (ctl.company_id = cp.id)
@@ -307,6 +307,7 @@
CREATE TYPE contact_list AS (
class text,
+ description text,
contact text
);
@@ -315,7 +316,7 @@
DECLARE out_row contact_list;
BEGIN
FOR out_row IN
- SELECT cl.class, c.contact
+ SELECT cl.class, c.description, c.contact
FROM company_to_contact c
JOIN contact_class cl ON (c.contact_class_id = cl.id)
WHERE company_id =
@@ -357,13 +358,14 @@
$$ LANGUAGE PLPGSQL;
CREATE OR REPLACE FUNCTION company__save_contact
-(in_entity_id int, in_contact_class int, in_contact text)
+(in_entity_id int, in_contact_class int, in_description text, in_contact text)
RETURNS INT AS
$$
DECLARE out_id int;
BEGIN
- INSERT INTO company_to_contact(company_id, contact_class_id, contact)
- SELECT id, in_contact_class, in_contact FROM company
+ INSERT INTO company_to_contact(company_id, contact_class_id,
+ description, contact)
+ SELECT id, in_contact_class, in_description, in_contact FROM company
WHERE entity_id = in_entity_id;
RETURN 1;
Modified: trunk/sql/modules/Location.sql
===================================================================
--- trunk/sql/modules/Location.sql 2008-05-14 21:40:07 UTC (rev 2145)
+++ trunk/sql/modules/Location.sql 2008-05-14 21:52:10 UTC (rev 2146)
@@ -131,6 +131,7 @@
line_three text,
city text,
state text,
+ mail_code text,
country text,
class text
);
Modified: trunk/sql/modules/Payment.sql
===================================================================
--- trunk/sql/modules/Payment.sql 2008-05-14 21:40:07 UTC (rev 2145)
+++ trunk/sql/modules/Payment.sql 2008-05-14 21:52:10 UTC (rev 2146)
@@ -606,6 +606,7 @@
line_three text,
city text,
state text,
+ mail_code text
country text,
class text
);
@@ -622,7 +623,7 @@
BEGIN
FOR out_row IN
SELECT l.id, l.line_one, l.line_two, l.line_three, l.city,
- l.state, c.name, lc.class
+ l.state, l.mail_code, c.name, lc.class
FROM location l
JOIN company_to_location ctl ON (ctl.location_id = l.id)
JOIN company cp ON (ctl.company_id = cp.id)
Modified: trunk/sql/modules/Person.sql
===================================================================
--- trunk/sql/modules/Person.sql 2008-05-14 21:40:07 UTC (rev 2145)
+++ trunk/sql/modules/Person.sql 2008-05-14 21:52:10 UTC (rev 2146)
@@ -86,7 +86,7 @@
BEGIN
FOR out_row IN
SELECT l.id, l.line_one, l.line_two, l.line_three, l.city,
- l.state, c.name, lc.class
+ l.state, l.mail_code, c.name, lc.class
FROM location l
JOIN person_to_location ctl ON (ctl.location_id = l.id)
JOIN person p ON (ctl.person_id = p.id)
@@ -106,7 +106,7 @@
DECLARE out_row RECORD;
BEGIN
FOR out_row IN
- SELECT cc.class, c.contact
+ SELECT cc.class, c.description, c.contact
FROM person_to_contact c
JOIN contact_class cc ON (c.contact_class_id = cc.id)
JOIN person p ON (c.person_id = p.id)
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.