ASSIGNCOPY(self->searchText, _txt);
}
- (id)searchText {
+ if (self->searchText == nil)
+ [self setSearchText:[[[self context] request] formValueForKey:@"search"]];
return self->searchText;
}
if ([s length] == 0)
return nil;
+ // TODO: just use qualifier vars
qs = [NSString stringWithFormat:
@"(sn isCaseInsensitiveLike: '%@*') OR "
@"(givenname isCaseInsensitiveLike: '%@*') OR "
NSArray *records;
EOQualifier *q;
- if (self->filteredRecords)
+ if (self->filteredRecords != nil)
return self->filteredRecords;
records = [[self clientObject] fetchCoreInfos];
+2005-02-22 Helge Hess <helge.hess@opengroupware.org>
+
+ * UIxMailMainFrame.m: added ability not to generate the HTML frame
+ (v0.9.120)
+
2005-02-20 Helge Hess <helge.hess@opengroupware.org>
* moved UIxMailSizeFormatter to MailPartViewers (v0.9.119)
NSString *rootURL;
NSString *userRootURL;
id item;
- BOOL hideFolderTree;
+ struct {
+ int hideFolderTree:1;
+ int hideFrame:1;
+ int reserved:30;
+ } mmfFlags;
}
- (NSString *)rootURL;
}
- (void)setHideFolderTree:(BOOL)_flag {
- self->hideFolderTree = _flag;
+ self->mmfFlags.hideFolderTree = _flag ? 1 : 0;
}
- (BOOL)hideFolderTree {
- return self->hideFolderTree;
+ return self->mmfFlags.hideFolderTree ? YES : NO;
+}
+
+- (void)setHideFrame:(BOOL)_flag {
+ self->mmfFlags.hideFrame = _flag ? 1 : 0;
+}
+- (BOOL)hideFrame {
+ return self->mmfFlags.hideFrame ? YES : NO;
}
- (void)setTitle:(NSString *)_value {
# version file
-SUBMINOR_VERSION:=119
+SUBMINOR_VERSION:=120
# v0.9.100 requires libNGMime v4.5.213
# v0.9.99 requires libNGMime v4.5.212
/* generic stuff */
+function ml_stripActionInURL(url) {
+ if (url[url.length - 1] != '/') {
+ var i;
+
+ i = url.lastIndexOf("/");
+ if (i != -1) url = url.substring(0, i);
+ }
+ if (url[url.length - 1] != '/') // ensure trailing slash
+ url = url + "/";
+ return url;
+}
+
function escapeHTML(s) {
s = s.replace(/&/g, "&");
s = s.replace(/</g, "<");
var lastKeyPress = null;
var submitAfterMS = 500;
+function ml_reloadTableView(searchtext, elementid) {
+ var http = createHTTPClient();
+
+ if (http) {
+ var viewURL, url;
+ var hasQueryPara;
+
+ viewURL = this.location.href;
+ hasQueryPara = viewURL.indexOf("?") == -1 ? false : true;
+ url = viewURL.replace(/\/tb\.view/, "/tb.view?noframe=1");
+ url = url + (hasQueryPara ? "&search=" : "?search=") + searchtext;
+
+ http.open("GET", url, false);
+ http.send(null);
+ if (http.status != 200) {
+ alert("Could not reload view.");
+ }
+ else {
+ var tv;
+
+ tv = document.getElementById(elementid)
+ tv.innerHTML = http.responseText;
+ }
+ }
+}
+
function ml_reloadSearchIfFieldChanged() {
if (field) {
if (field.value != firstValue) {
// TODO: we should just reload the tableview, not the whole page
- document.pageform.submit();
+ //document.pageform.submit();
+ ml_reloadTableView(field.value, "cl_tableview_reloadroot");
}
}
}
+2005-02-22 Helge Hess <helge.hess@opengroupware.org>
+
+ * UIxMailContactList.m: hide frame if "noframe" query parameter is set
+ (v0.9.7)
+
2005-02-18 Helge Hess <helge.hess@opengroupware.org>
* mailercontacts.js: added some function to allow inline editing of
UIxMailContactList.m \
UIxMailContactEditor.m \
+
MailerContactsUI_RESOURCE_FILES += \
Version \
product.plist \
@implementation UIxMailContactList
+/* frame */
+
+- (BOOL)hideFrame {
+ return [[[[self context] request] formValueForKey:@"noframe"] boolValue];
+}
+
/* title */
- (NSString *)objectTitle {
# version file
-SUBMINOR_VERSION:=6
+SUBMINOR_VERSION:=7
# v0.9.5 requires MailerUI v0.9.116
/* edit field */
-function cl_stripActionInURL(url) {
- if (url[url.length - 1] != '/') {
- var i;
-
- i = url.lastIndexOf("/");
- if (i != -1) url = url.substring(0, i);
- }
- if (url[url.length - 1] != '/') // ensure trailing slash
- url = url + "/";
- return url;
-}
-
function cl_saveFieldValue(sender, keyName) {
var http = createHTTPClient();
var url = window.location.href;
var content;
- url = cl_stripActionInURL(url);
+ url = ml_stripActionInURL(url);
url = url + recordID + "/patchOneField";
// TODO: confuses SOPE?!: url = url + "?jsonly=1"
protectedBy = "View";
pageName = "UIxMailContactList";
};
+ "tb.tableview" = { /* same like above without the frame */
+ protectedBy = "View";
+ pageName = "UIxMailContactListPart";
+ };
+
"tb.compose" = {
protectedBy = "View";
actionClass = "UIxMailEditorAction";
+2005-02-22 Helge Hess <helge.hess@opengroupware.org>
+
+ * UIxMailMainFrame.wox: removed debug code, use new SOPE container tag
+ to allow for frameless pages
+
2005-02-21 Marcus Mueller <znek@mulle-kybernetik.com>
* UIxTimeDateControl.wox: disable time control on demand
xmlns:label="OGo:label"
className="UIxMailMainFrame"
title="panelTitle"
+ hideFrame="hideFrame"
>
<!--
TODO: had a form like this:
var:queryDictionary="queryParameters"
-->
+<var:if condition="hideFrame" const:negate="YES">
<style>
span.cl_inline {
width: 100%;
</td>
</tr>
</table>
+</var:if>
+ <div id="cl_tableview_reloadroot">
<div class="embedwhite_out">
- <div class="embedwhite_in">
+ <div class="embedwhite_in" id="cl_tableview">
<table border="0" width="100%" cellspacing="0" cellpadding="1">
<tr class="tableview">
</table>
</div>
</div>
+ </div>
+<var:if condition="hideFrame" const:negate="YES">
<script language="JavaScript">
document.pageform.search.focus();
</script>
+</var:if>
</var:component>
<?xml version="1.0" standalone="yes"?>
+<container xmlns="http://www.w3.org/1999/xhtml"
+ xmlns:var="http://www.skyrix.com/od/binding"
+ xmlns:const="http://www.skyrix.com/od/constant"
+ xmlns:rsrc="OGo:url"
+ xmlns:label="OGo:label"
+>
+ <var:if condition="hideFrame" const:negate="YES">
<html xmlns="http://www.w3.org/1999/xhtml"
xmlns:var="http://www.skyrix.com/od/binding"
xmlns:const="http://www.skyrix.com/od/constant"
</td>
</tr>
</table>
-
-
- <!-- debugging -->
- <var:if condition="isUIxDebugEnabled">
- <table border="0" width="100%">
- <tr>
- <td colspan="2">
- <hr />
- <table border="0" style="font-size: 9pt;">
- <tr>
- <td valign="top">clientObject:</td>
- <td valign="top"><var:string value="clientObject" /></td>
- </tr>
- <tr>
- <td valign="top">IMAP4-URL:</td>
- <td valign="top"><var:string
- value="clientObject.imap4URL.absoluteString" /></td>
- </tr>
- <tr>
- <td valign="top">traversal stack:</td>
- <td valign="top">
- <var:foreach list="context.objectTraversalStack" item="item">
- <var:string value="item" /><br />
- </var:foreach>
- </td>
- </tr>
- <tr>
- <td valign="top">traversal path:</td>
- <td valign="top">
- <var:foreach list="context.soRequestTraversalPath"
- item="item" const:separator=" => ">
- <var:string value="item" />
- </var:foreach>
- </td>
- </tr>
- <tr>
- <td valign="top">request type:</td>
- <td valign="top"><var:string value="context.soRequestType"/>
- </td>
- </tr>
- <tr>
- <td valign="top">path info:</td>
- <td valign="top"><var:string value="context.pathInfo"/></td>
- </tr>
- <tr>
- <td valign="top">rootURL:</td>
- <td valign="top"><var:string value="context.rootURL"/></td>
- </tr>
- <tr>
- <td valign="top">active user:</td>
- <td valign="top"><var:string value="context.activeUser"/></td>
- </tr>
- </table>
- </td>
- </tr>
- </table>
- </var:if>
</form>
</body>
</html>
+ </var:if>
+
+ <var:if condition="hideFrame">
+ <var:component-content/>
+ </var:if>
+</container>