[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Phpgroupware-cvs] phpgwapi/templates/default addressbook-js-frameset.tp
From: |
Alejandro Borges (lex) <address@hidden> |
Subject: |
[Phpgroupware-cvs] phpgwapi/templates/default addressbook-js-frameset.tpl, 1.1.2.1, 1.1.2.2 |
Date: |
Tue, 02 Dec 2003 22:49:55 +0000 |
Update of /cvsroot/phpgroupware/phpgwapi/templates/default
In directory subversions:/tmp/cvs-serv3651/templates/default
Modified Files:
Tag: Version-0_9_16-branch
addressbook-js-frameset.tpl
Log Message:
Fixes jsaddressbook further....
Index: addressbook-js-frameset.tpl
===================================================================
RCS file:
/cvsroot/phpgroupware/phpgwapi/templates/default/Attic/addressbook-js-frameset.tpl,v
retrieving revision 1.1.2.1
retrieving revision 1.1.2.2
diff -C2 -d -r1.1.2.1 -r1.1.2.2
*** addressbook-js-frameset.tpl 13 Sep 2003 07:30:08 -0000 1.1.2.1
--- addressbook-js-frameset.tpl 2 Dec 2003 22:49:53 -0000 1.1.2.2
***************
*** 1,143 ****
! <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
! <html>
! <head>
! <meta http-equiv="CONTENT-TYPE"
! content="text/html; charset={charset}">
! <title>{title}</title>
! <STYLE TYPE="text/css">
! SELECT { font-size: {widget_font_size}; }
! INPUT{ font-size: {widget_font_size}; }
! TEXTAREA { font-size: {widget_font_size}; color: blue }
! body { margin-top: 0px; margin-right: 0px; margin-left: 0px;
font-family: Arial, Helvetica, san-serif }
! </STYLE>
! <script language="javascript">
! //Variable declarations
! // All these are data expected to be here by the mainframe or
the secondary frame at
! //an undetermined time
! var toselectbox_name;
! var toselectbox_email;
! var toselectbox_keys;
! var ccselectbox_name;
! var ccselectbox_email;
! var ccselectbox_keys;
! var bccselectbox_name;
! var bccselectbox_email;
! var bccselectbox_keys;
! var mainfirsttimeflag;
! //This last var is an array populated just before the window
closes (upon done)
! //this is filled with a simple array filled with the selected
contact ids
! //the mainframe then calls the update_caller event which we
implement bellow
! //that, if the php framework required it, will call a callback
function in
! //its opener. This is the way to get the selected contact id's
in javascript
! //
! var finally_selected_contact_ids;
! mainfirsttimeflag=1;
! //@function set_destboxes
! //@param getvars The string of GET style http variables
! //@discussion
! //This function tells the secondary frame to go and set the
data for the destination boxes
! //The acutal values of the destination boxes where converted to
get style vars
! //by a call to option2get method of the selectMover js object
in selectboxes.js
! function set_destboxes(getvars)
! {
! //alert("{set_destboxes_link}"+getvars);
!
window.secondaryframe.location="{set_destboxes_link}"+getvars;
! }
! //@function destboxes_set
! //@discussion
! //Upon loading the resultiong arrays from the set_destboxes
call, the php backend
! //will output an onLoad event which calls this function. Before
that, it will have sent
! //three arrays, one per destination box. This arrays hold
names, emails and addressbook
! //entry id's respectivly per destination box.
! //Obviously, the index to each of the arrays elements directly
relate
! //the email with the id and the name. So, the email of the
addressbook entry
! // Whose fullname is toselectbox_name[i], is in
toselectbox_email[i]...and
! //so is the corresponding key in toselectbox_key[i]
! //When this frameset receives this event, it will initialize
its arrays
! //and call the mainframe so it can update itself with this
newly gotten data
! function destboxes_set()
! {
!
!
window.toselectbox_name=window.secondaryframe.toselectbox_name;
!
window.toselectbox_email=window.secondaryframe.toselectbox_email;
!
window.toselectbox_keys=window.secondaryframe.toselectbox_keys;
!
window.ccselectbox_name=window.secondaryframe.ccselectbox_name;
!
window.ccselectbox_email=window.secondaryframe.ccselectbox_email;
!
window.ccselectbox_keys=window.secondaryframe.ccselectbox_keys;
!
window.bccselectbox_name=window.secondaryframe.bccselectbox_name;
!
window.bccselectbox_email=window.secondaryframe.bccselectbox_email;
!
window.bccselectbox_keys=window.secondaryframe.bccselectbox_keys;
! window.mainframe.event_destboxes_saved();
! }
! //show userdata event variables
! var userdata;
! var userdata_width;
! var userdata_height;
! //@function get_user_data
! //@param usertofetch This should be a nameselect[0]=id string
allways
! //@discussion will tell the secondary frame to go and call the
get_userdata
! //public method of the uijsaddressbook php class. This class
will get the id
! //from the nameselect var and will query the backend for us. It
will then urlencode
! //the generated record (it formats it with spaces and all) and
send it back to us in the
! //userdata variable.
! function get_user_data(usertofetch)
! {
!
window.secondaryframe.location="{get_user_data_link}"+usertofetch;
! }
! //@function userdata_got
! //@discussion
! //Upon loading the data got from the get_userdata call to the
php uijsaddressbook class,
! //the secondary frame's body tag will have an call to this
function in its onLoad event
! //This will call us. The contents of the resulting document in
the secondary frame will
! //already have a urlencoded string representing the userdata
the way we want to show it
! //Also, the userdata_height and width will be set in as
variables in the secondary frame
! //This two variables are used by the mainframe's
event_userdata_got function
! //to dynamically set the size of the userdata textbox.
! function userdata_got()
! {
! window.userdata=window.secondaryframe.userdata;
!
window.userdata_rows=window.secondaryframe.userdata_rows;
!
window.userdata_cols=window.secondaryframe.userdata_cols;
! window.mainframe.event_userdata_got();
! }
! //@function forget_destboxes
! //@discussion will direct the secondary frame to the forget_all
public
! //phpgw method in the uijsaddressbook class
! //This will cause the php backend to forget everything in cache
! function forget_destboxes()
! {
! window.secondaryframe.location="{forget_all_link}";
! }
! //@function all_forgoten
! //@discussion Upon forgeting all, the php backend will output
just a call to this function
! //we let know the mainframe that all has been forgoten by
calling the corresponding event function
! //in it
! function all_forgoten()
! {
! window.mainframe.event_all_forgoten();
! }
! //@function update_opener
! //@discussion In the final moment, finally_selected_contact_ids
is populated
! //with a flat array that has all the selected contact id's. If
the php framework
! //decides so (through the ui constructor's parameter), it will
set the template
! //variable please_update_opener to 1, so the if bellow will
evaluate to 1 and
! //will call a jsaddybook_closing(array) method in the opener,
! //to which it will send the finally_selected_contact_ids array
with the
! //ids that were selected.
! function update_opener()
! {
! if({please_update_opener} == 1)
! {
! // alert('Updating
Opener'+window.finally_selected_contact_ids);
!
window.opener.jsaddybook_closing(window.finally_selected_contact_ids);
! }
! }
!
! </script>
! </head>
! <frameset cols="100%,0%">
! <FRAME NAME="mainframe" SRC="{mainframe_link}">
! <FRAME NAME="secondaryframe" SRC="{set_destboxes_link}">
! </frameset>
! </html
!
--- 1,143 ----
! <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
! <html>
! <head>
! <meta http-equiv="CONTENT-TYPE"
! content="text/html; charset={charset}">
! <title>{title}</title>
! <STYLE TYPE="text/css">
! SELECT { font-size: {widget_font_size}; }
! INPUT{ font-size: {widget_font_size}; }
! TEXTAREA { font-size: {widget_font_size}; color: blue }
! body { margin-top: 0px; margin-right: 0px; margin-left: 0px;
font-family: Arial, Helvetica, san-serif }
! </STYLE>
! <script language="javascript">
! //Variable declarations
! // All these are data expected to be here by the mainframe or
the secondary frame at
! //an undetermined time
! var toselectbox_name;
! var toselectbox_email;
! var toselectbox_keys;
! var ccselectbox_name;
! var ccselectbox_email;
! var ccselectbox_keys;
! var bccselectbox_name;
! var bccselectbox_email;
! var bccselectbox_keys;
! var mainfirsttimeflag;
! //This last var is an array populated just before the window
closes (upon done)
! //this is filled with a simple array filled with the selected
contact ids
! //the mainframe then calls the update_caller event which we
implement bellow
! //that, if the php framework required it, will call a callback
function in
! //its opener. This is the way to get the selected contact id's
in javascript
! //
! var finally_selected_contact_ids;
! mainfirsttimeflag=1;
! //@function set_destboxes
! //@param getvars The string of GET style http variables
! //@discussion
! //This function tells the secondary frame to go and set the
data for the destination boxes
! //The acutal values of the destination boxes where converted to
get style vars
! //by a call to option2get method of the selectMover js object
in selectboxes.js
! function set_destboxes(getvars)
! {
! //alert("{set_destboxes_link}"+getvars);
!
window.secondaryframe.location="{set_destboxes_link}"+getvars;
! }
! //@function destboxes_set
! //@discussion
! //Upon loading the resultiong arrays from the set_destboxes
call, the php backend
! //will output an onLoad event which calls this function. Before
that, it will have sent
! //three arrays, one per destination box. This arrays hold
names, emails and addressbook
! //entry id's respectivly per destination box.
! //Obviously, the index to each of the arrays elements directly
relate
! //the email with the id and the name. So, the email of the
addressbook entry
! // Whose fullname is toselectbox_name[i], is in
toselectbox_email[i]...and
! //so is the corresponding key in toselectbox_key[i]
! //When this frameset receives this event, it will initialize
its arrays
! //and call the mainframe so it can update itself with this
newly gotten data
! function destboxes_set()
! {
!
!
window.toselectbox_name=window.secondaryframe.toselectbox_name;
!
window.toselectbox_email=window.secondaryframe.toselectbox_email;
!
window.toselectbox_keys=window.secondaryframe.toselectbox_keys;
!
window.ccselectbox_name=window.secondaryframe.ccselectbox_name;
!
window.ccselectbox_email=window.secondaryframe.ccselectbox_email;
!
window.ccselectbox_keys=window.secondaryframe.ccselectbox_keys;
!
window.bccselectbox_name=window.secondaryframe.bccselectbox_name;
!
window.bccselectbox_email=window.secondaryframe.bccselectbox_email;
!
window.bccselectbox_keys=window.secondaryframe.bccselectbox_keys;
! window.mainframe.event_destboxes_saved();
! }
! //show userdata event variables
! var userdata;
! var userdata_width;
! var userdata_height;
! //@function get_user_data
! //@param usertofetch This should be a nameselect[0]=id string
allways
! //@discussion will tell the secondary frame to go and call the
get_userdata
! //public method of the uijsaddressbook php class. This class
will get the id
! //from the nameselect var and will query the backend for us. It
will then urlencode
! //the generated record (it formats it with spaces and all) and
send it back to us in the
! //userdata variable.
! function get_user_data(usertofetch)
! {
!
window.secondaryframe.location="{get_user_data_link}"+usertofetch;
! }
! //@function userdata_got
! //@discussion
! //Upon loading the data got from the get_userdata call to the
php uijsaddressbook class,
! //the secondary frame's body tag will have an call to this
function in its onLoad event
! //This will call us. The contents of the resulting document in
the secondary frame will
! //already have a urlencoded string representing the userdata
the way we want to show it
! //Also, the userdata_height and width will be set in as
variables in the secondary frame
! //This two variables are used by the mainframe's
event_userdata_got function
! //to dynamically set the size of the userdata textbox.
! function userdata_got()
! {
! window.userdata=window.secondaryframe.userdata;
!
window.userdata_rows=window.secondaryframe.userdata_rows;
!
window.userdata_cols=window.secondaryframe.userdata_cols;
! window.mainframe.event_userdata_got();
! }
! //@function forget_destboxes
! //@discussion will direct the secondary frame to the forget_all
public
! //phpgw method in the uijsaddressbook class
! //This will cause the php backend to forget everything in cache
! function forget_destboxes()
! {
! window.secondaryframe.location="{forget_all_link}";
! }
! //@function all_forgoten
! //@discussion Upon forgeting all, the php backend will output
just a call to this function
! //we let know the mainframe that all has been forgoten by
calling the corresponding event function
! //in it
! function all_forgoten()
! {
! window.mainframe.event_all_forgoten();
! }
! //@function update_opener
! //@discussion In the final moment, finally_selected_contact_ids
is populated
! //with a flat array that has all the selected contact id's. If
the php framework
! //decides so (through the ui constructor's parameter), it will
set the template
! //variable please_update_opener to 1, so the if bellow will
evaluate to 1 and
! //will call a jsaddybook_closing(array) method in the opener,
! //to which it will send the finally_selected_contact_ids array
with the
! //ids that were selected.
! function update_opener()
! {
! if({please_update_opener} == 1)
! {
! // alert('Updating
Opener'+window.finally_selected_contact_ids);
!
window.opener.jsaddybook_closing(window.finally_selected_contact_ids);
! }
! }
!
! </script>
! </head>
! <frameset cols="100%,0%">
! <FRAME NAME="mainframe" SRC="{mainframe_link}">
! <FRAME NAME="secondaryframe" SRC="{set_destboxes_link}">
! </frameset>
! </html
!
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Phpgroupware-cvs] phpgwapi/templates/default addressbook-js-frameset.tpl, 1.1.2.1, 1.1.2.2,
Alejandro Borges (lex) <address@hidden> <=
- Prev by Date:
[Phpgroupware-cvs] admin/inc hook_sidebox_menu.inc.php, 1.1.2.4, 1.1.2.5
- Next by Date:
[Phpgroupware-cvs] phpgwapi/inc class.bojsaddressbook.inc.php, 1.1.2.3, 1.1.2.4 class.contacts_sql.inc.php, 1.17.2.2.2.38, 1.17.2.2.2.39 class.uijsaddressbook.inc.php, 1.1.2.3, 1.1.2.4
- Previous by thread:
[Phpgroupware-cvs] admin/inc hook_sidebox_menu.inc.php, 1.1.2.4, 1.1.2.5
- Next by thread:
[Phpgroupware-cvs] phpgwapi/inc class.bojsaddressbook.inc.php, 1.1.2.3, 1.1.2.4 class.contacts_sql.inc.php, 1.17.2.2.2.38, 1.17.2.2.2.39 class.uijsaddressbook.inc.php, 1.1.2.3, 1.1.2.4
- Index(es):