Difference between revisions of "Freeside:1.9:Documentation:Developer/FS/UI/Web"

From Freeside
Jump to: navigation, search
(import from POD)
 
(import from POD)
Line 19: Line 19:
 
:Returns a list of fields for the SELECT portion of an SQL query.
 
:Returns a list of fields for the SELECT portion of an SQL query.
  
:As with [[Freeside:1.9:Documentation:Developer/#cust header|the cust header subroutine|#cust_header|the cust_header subroutine]], the fields returned are defined by the supplied customer fields setting, or if no customer fields setting is supplied, the <B>cust-fields</B> configuration value.
+
:As with [[#cust_header|the cust_header subroutine]], the fields returned are defined by the supplied customer fields setting, or if no customer fields setting is supplied, the <B>cust-fields</B> configuration value.
 
; cust_fields OBJECT [ CUST_FIELDS_VALUE ]
 
; cust_fields OBJECT [ CUST_FIELDS_VALUE ]
 
:Given an object that contains fields from cust_main (say, from a JOINed search. See httemplate/search/svc_* for examples), returns an array of customer information, or "(unlinked)" if this service is not linked to a customer.
 
:Given an object that contains fields from cust_main (say, from a JOINed search. See httemplate/search/svc_* for examples), returns an array of customer information, or "(unlinked)" if this service is not linked to a customer.
  
:As with [[Freeside:1.9:Documentation:Developer/#cust header|the cust header subroutine|#cust_header|the cust_header subroutine]], the fields returned are defined by the supplied customer fields setting, or if no customer fields setting is supplied, the <B>cust-fields</B> configuration value.
+
:As with [[#cust_header|the cust_header subroutine]], the fields returned are defined by the supplied customer fields setting, or if no customer fields setting is supplied, the <B>cust-fields</B> configuration value.
 
; cust_colors
 
; cust_colors
 
:Returns an array of subroutine references (or empty strings) for returning customer information colors.
 
:Returns an array of subroutine references (or empty strings) for returning customer information colors.
  
:As with [[Freeside:1.9:Documentation:Developer/#cust header|the cust header subroutine|#cust_header|the cust_header subroutine]], the fields returned are defined by the supplied customer fields setting, or if no customer fields setting is supplied, the <B>cust-fields</B> configuration value.
+
:As with [[#cust_header|the cust_header subroutine]], the fields returned are defined by the supplied customer fields setting, or if no customer fields setting is supplied, the <B>cust-fields</B> configuration value.
 
; cust_styles
 
; cust_styles
 
:Returns an array of customer information styles.
 
:Returns an array of customer information styles.
  
:As with [[Freeside:1.9:Documentation:Developer/#cust header|the cust header subroutine|#cust_header|the cust_header subroutine]], the fields returned are defined by the supplied customer fields setting, or if no customer fields setting is supplied, the <B>cust-fields</B> configuration value.
+
:As with [[#cust_header|the cust_header subroutine]], the fields returned are defined by the supplied customer fields setting, or if no customer fields setting is supplied, the <B>cust-fields</B> configuration value.
 
; cust_aligns
 
; cust_aligns
 
:Returns an array or scalar (depending on context) of customer information alignments.
 
:Returns an array or scalar (depending on context) of customer information alignments.
  
:As with [[Freeside:1.9:Documentation:Developer/#cust header|the cust header subroutine|#cust_header|the cust_header subroutine]], the fields returned are defined by the supplied customer fields setting, or if no customer fields setting is supplied, the <B>cust-fields</B> configuration value.
+
:As with [[#cust_header|the cust_header subroutine]], the fields returned are defined by the supplied customer fields setting, or if no customer fields setting is supplied, the <B>cust-fields</B> configuration value.
  
 
==POD ERRORS==
 
==POD ERRORS==

Revision as of 17:29, 3 October 2007

svc_url
Returns a service URL, first checking to see if there is a service-specific page to link to, otherwise to a generic service handling page. Options are passed as a list of name-value pairs, and include:
    • m - Mason request object ($m)
    • action - The action for which to construct "edit", "view", or "search"
    • ** part_svc - Service definition (see FS::part_svc)
    • ** svcdb - Service table
    • *** query - Query string
    • *** svc - FS::cust_svc or FS::svc_* object
    • ahref - Optional flag, if set true returns <A HREF="$url"> instead of just the URL.
  • Required fields
    • part_svc OR svcdb is required
      • query OR svc is required
cust_header [ CUST_FIELDS_VALUE ]
Returns an array of customer information headers according to the supplied customer fields value, or if no value is supplied, the cust-fields configuration value.
cust_sql_fields [ CUST_FIELDS_VALUE ]
Returns a list of fields for the SELECT portion of an SQL query.
As with the cust_header subroutine, the fields returned are defined by the supplied customer fields setting, or if no customer fields setting is supplied, the cust-fields configuration value.
cust_fields OBJECT [ CUST_FIELDS_VALUE ]
Given an object that contains fields from cust_main (say, from a JOINed search. See httemplate/search/svc_* for examples), returns an array of customer information, or "(unlinked)" if this service is not linked to a customer.
As with the cust_header subroutine, the fields returned are defined by the supplied customer fields setting, or if no customer fields setting is supplied, the cust-fields configuration value.
cust_colors
Returns an array of subroutine references (or empty strings) for returning customer information colors.
As with the cust_header subroutine, the fields returned are defined by the supplied customer fields setting, or if no customer fields setting is supplied, the cust-fields configuration value.
cust_styles
Returns an array of customer information styles.
As with the cust_header subroutine, the fields returned are defined by the supplied customer fields setting, or if no customer fields setting is supplied, the cust-fields configuration value.
cust_aligns
Returns an array or scalar (depending on context) of customer information alignments.
As with the cust_header subroutine, the fields returned are defined by the supplied customer fields setting, or if no customer fields setting is supplied, the cust-fields configuration value.

POD ERRORS

Hey! The above document had some coding errors, which are explained below:

Around line 46:
'=item' outside of any '=over'
Around line 58:
Expected '=item *'
Around line 60:
Expected '=item *'
Around line 62:
Expected '=item *'
Around line 64:
Expected '=item *'
Around line 66:
Expected '=item *'