|
CAF Noodle JavaScript | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES All Classes | ||||||||
SUMMARY: FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
Object | +--Noodle.Model | +--Noodle.Row.Model | +--Noodle.Page.Model
Base noodle page model methods.
Defined in page.js
Constructor Summary | |
Noodle.Page.Model
()
|
Method Summary | |
<static> Object
|
addNear(<element> near, <function> addToColumn, <function> addAsFloater)
Create container for new portlet. |
<static> Object
|
addPortlet(<string> portletID, <object> portlet, <element> near)
Create a new portlet and add it to this page. |
<static> Object
|
addRow(<element> near)
Create a new row and add it to this page. |
<static> Object
|
addTempPortlet(<object> portlet, <element> near)
Create a new temp portlet and add it to this page. |
<static> Object
|
allowDrop(<object> cur, <Draggable> drag, <Droppable> drop)
Returns true if draggable is droppable for this page. |
<static> void
|
attachPortletFinder()
Attach this page's portlet finder to the portlet-finder link. |
<static> Object
|
canEdit(layout)
True if current user can edit the page in any way (like moving portlets). |
<static> Object
|
canSave()
True if current user can save changes to the page. |
<static> void
|
changesMode()
Toggles page into changes mode. |
<static> Object
|
createDraggable()
Create noodle page model draggable item. |
<static> void
|
detachPortletFinder()
Detach this page's portlet finder from the portlet-finder link. |
<static> void
|
edit()
Toggles portlet into edit mode. |
<static> Object
|
getGeneralLayoutPropertiesHTML(<string> pfx)
Custom layout property-line html. |
<static> Object
|
getGrid(<boolean> calcRect)
Builds a structure of rows, columns, and portlets representing the non-floating portlets on the page. |
<static> Object
|
getLayoutXML()
Creates the new layout xml for this page. |
<static> Object
|
getMaximizedPortlet()
The maximized portlet's model, or null, if no maximized portlet. |
<static> Object
|
getPage()
Returns this page. |
<static> Object
|
getPortletFinderLink()
Returns the portlet-finder link element. |
<static> Object
|
getPropertiesModeLabel(<string> mode)
Localized label for specified mode. |
<static> Object
|
getPropertiesModes()
List the properties-modes the portlet has. |
<static> Object
|
getRows()
Array of all the "portlet-row" descendant divs in this page. |
<static> void
|
hidePortletFinder()
Hide the portlet-finder menu. |
<static> void
|
initialize()
Initialize noodle page model. |
<static> Object
|
isDirty()
True if the page is dirty. |
<static> Object
|
isFreeForm()
True if page is in free-form mode; false if page in columnar mode. |
<static> void
|
load()
Loads this page. |
<static> void
|
minimizeAll()
Minimize all portlets on this page. |
<static> void
|
onDrop(<object> cur, <Draggable> drag, <Droppable> drop)
Handles ondrop event for this page. |
<static> void
|
onDropActivate(<object> cur, <Draggable> drag, <Droppable> drop)
Handles ondragover event for this page. |
<static> void
|
onDropDeactivate(<object> cur, <Draggable> drag, <Droppable> drop)
Handles ondragout event for this page. |
<static> void
|
onDropHover(<object> cur, <Draggable> drag, <Droppable> drop)
Handles ondragmove event for this page. |
<static> void
|
onExpertMode(<string> mode, <string> oldMode)
Handles expert-mode change. |
<static> void
|
onUpdateMetadata(<event> event)
Handle update-metadata events for this page. |
<static> Object
|
parseLayoutXML(<string> xml)
Parse a layout object from the specified xml. |
<static> void
|
propertiesMode()
Toggles portlet into properties mode. |
<static> void
|
propertiesSubmit()
Submits metadata properties panel. |
<static> Object
|
propertiesValidate()
Validates metadata properties panel. |
<static> void
|
release()
Releases page model data structures. |
<static> void
|
removeTemp()
Removes temporary saved state of this page from user session. |
<static> void
|
requireScratch(<function> fn, <boolean> dirty)
Executes the specified function once the scratch page has been created. |
<static> void
|
restoreAll()
Restore (switch to normal from minimized or maximized) all portlets on this page. |
<static> void
|
revertAndReturn(<string> returnUrl)
Reverts this page and redirects to returnUrl. |
<static> void
|
save()
Saves this page. |
<static> void
|
saveAndReturn(<string> returnUrl)
Saves this page and redirects to returnUrl. |
<static> void
|
saveAs()
Displays a save-as dialog allowing the user to save this page as a new page. |
<static> void
|
saveTemp()
Temporarily Saves this page to the user session. |
<static> void
|
setDirty(<boolean> dirty)
Sets the page dirty/clean. |
<static> void
|
setLayout(layout)
Set noodle page model layout. |
<static> void
|
showPortletFinder()
Display the portlet-finder menu over the portlet-finder link. |
<static> Object
|
toggleMode(<string> mode)
Hides div for current mode, and creates div for specified mode. |
<static> void
|
view()
Toggles portlet into view mode. |
Constructor Detail |
Noodle.Page.Model()
Method Detail |
<static> Object addNear(<element> near, <function> addToColumn, <function> addAsFloater)
near
- Element near which to display new portlet.
addToColumn
- Callback for creating container in a column.
addAsFloater
- Callback for creating container as a floater.
<static> Object addPortlet(<string> portletID, <object> portlet, <element> near)
portletID
- ThingID of portlet to clone, or xtypeID of portlet to create.
portlet
- Inital portlet model object; specify at least the "name" property.
near
- Element near which to display new portlet.
<static> Object addRow(<element> near)
near
- Element near which to display new portlet.
<static> Object addTempPortlet(<object> portlet, <element> near)
portlet
- Inital portlet model object; specify at least the "name" property.
near
- Element near which to display new portlet.
<static> Object allowDrop(<object> cur, <Draggable> drag, <Droppable> drop)
cur
- Current drag operation data.
drag
- Daggable object.
drop
- Page droppable object.
<static> void attachPortletFinder()
<static> Object canEdit(layout)
<static> Object canSave()
<static> void changesMode()
<static> Object createDraggable()
<static> void detachPortletFinder()
<static> void edit()
<static> Object getGeneralLayoutPropertiesHTML(<string> pfx)
pfx
- Id prefix.
<static> Object getGrid(<boolean> calcRect)
calcRect
- True to calculate the positioning rectangle for each row, column, and portlet.
[ { rect: { Noodle.Page.Model.left = 0; Noodle.Page.Model.top = 0; Noodle.Page.Model.right = 800; Noodle.Page.Model.bottom = 600;}, element: <div class="portal-page|portlet-row">, columns: [ { rect: { Noodle.Page.Model.left = 0; Noodle.Page.Model.top = 0; Noodle.Page.Model.right = 400; Noodle.Page.Model.bottom = 600;}, elemnent: <td class="portlet-column">, rows: [], portlets: [ { rect: { Noodle.Page.Model.left = 0; Noodle.Page.Model.top = 0; Noodle.Page.Model.right = 400; Noodle.Page.Model.bottom = 200;}, element: <div class="portlet-container"> }, { rect: { Noodle.Page.Model.left = 0; Noodle.Page.Model.top = 200; Noodle.Page.Model.right = 400; Noodle.Page.Model.bottom = 500;}, element: <div class="portlet-container"> } ] }, { rect: { Noodle.Page.Model.left = 0; Noodle.Page.Model.top = 0; Noodle.Page.Model.right = 400; Noodle.Page.Model.bottom = 600;}, elemnent: <td class="portlet-column">, rows: [], portlets: [ { rect: { Noodle.Page.Model.left = 400; Noodle.Page.Model.top = 0; Noodle.Page.Model.right = 800; Noodle.Page.Model.bottom = 250;}, element: <div class="portlet-container"> } ] } ] } ]
<static> Object getLayoutXML()
<static> Object getMaximizedPortlet()
<static> Object getPage()
<static> Object getPortletFinderLink()
<static> Object getPropertiesModeLabel(<string> mode)
mode
- Mode.
<static> Object getPropertiesModes()
<static> Object getRows()
<static> void hidePortletFinder()
<static> void initialize()
<static> Object isDirty()
<static> Object isFreeForm()
<static> void load()
<static> void minimizeAll()
<static> void onDrop(<object> cur, <Draggable> drag, <Droppable> drop)
cur
- Current drag operation data.
drag
- Daggable object.
drop
- Page droppable object.
<static> void onDropActivate(<object> cur, <Draggable> drag, <Droppable> drop)
cur
- Current drag operation data.
drag
- Daggable object.
drop
- Page droppable object.
<static> void onDropDeactivate(<object> cur, <Draggable> drag, <Droppable> drop)
cur
- Current drag operation data.
drag
- Daggable object.
drop
- Page droppable object.
<static> void onDropHover(<object> cur, <Draggable> drag, <Droppable> drop)
cur
- Current drag operation data.
drag
- Daggable object.
drop
- Page droppable object.
<static> void onExpertMode(<string> mode, <string> oldMode)
mode
- New mode.
oldMode
- Old mode.
<static> void onUpdateMetadata(<event> event)
event
- Event.
<static> Object parseLayoutXML(<string> xml)
xml
- Layout xml (ie "<static> void propertiesMode()
<static> void propertiesSubmit()
<static> Object propertiesValidate()
<static> void release()
<static> void removeTemp()
<static> void requireScratch(<function> fn, <boolean> dirty)
fn
- Function to execute.
dirty
- True to dirty page (defaults to true).
<static> void restoreAll()
<static> void revertAndReturn(<string> returnUrl)
returnUrl
- Url to redirect; defaults to returnUrl page parameter.
<static> void save()
<static> void saveAndReturn(<string> returnUrl)
returnUrl
- Url to redirect; defaults to returnUrl page parameter.
<static> void saveAs()
<static> void saveTemp()
<static> void setDirty(<boolean> dirty)
dirty
- True to dirty page, false to clean (defaults to true).
<static> void setLayout(layout)
<static> void showPortletFinder()
<static> Object toggleMode(<string> mode)
mode
- New mode name.
<static> void view()
|
CAF Noodle JavaScript | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES All Classes | ||||||||
SUMMARY: FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |