The project manager returns an error on the main page unless every user is added to every single project. It should return a list of just the projects the user is assigned to.
:ERROR MESSAGE:
org.ofbiz.widget.screen.ScreenRenderException: Error rendering screen [component://common/widget/CommonScreens.xml#GlobalDecorator]: java.lang.IllegalArgumentException: Error running Groovy script at location [component://projectmgr/webapp/projectmgr/WEB-INF/actions/ListCurrentProjects.groovy]: org.ofbiz.service.ServiceAuthException: You have no access to the project#: 10040 (Error running Groovy script at location [component://projectmgr/webapp/projectmgr/WEB-INF/actions/ListCurrentProjects.groovy]: org.ofbiz.service.ServiceAuthException: You have no access to the project#: 10040)
It defeats the point.
Mansour:
Pierre,
The patch seems to restrict access to this scree to "PROJECTMGR_ADMIN".
I am not sure if this issue is to be resolved in the screen or making the service returns projects the user has access to.
I appreciate your help here.
Pierre:
Hi Mansour,
You are right. The patch indeed does that and returns a blank screen for
users other than with access 'PROJECTMGR_ADMIN. Other users can look at
projects which will show projects the user is a member of.
jleroux:
I did not test all, but because of ListCurrentProjects.groovy, it seems to me that this is a better solution
I added the CommonAsk label to help lambda users better understand the situation (by asking :p)
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1714415 13f79535-47bb-0310-9956-ffa450edef68
org.ofbiz.common.login.LoginServices.userLogin is returning ERROR when a username or password is incorrect. It should return FAILURE instead of error. The error causes stack track to be printed to the log. The stack trace makes watching the log for actual errors difficult. This is especially hard when running and analyzing the log after a full test run, of in my case, a custom set of test cases.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1714244 13f79535-47bb-0310-9956-ffa450edef68
The demo data set (in location /framework/entity/data/TenantDemoData.xml) contains elements to load the tenants DEMO1 and DEMO2 into the implemented OFBiz setup.
This data set is intended to be loaded into the master tables when a user wants to explore multity tenancy. However, when a user also wants/needs to load demo data into the tenant DEMO1 or DEMO2 OFBiz also tries to upload the demo setup data for each tenant. This is not allowed as tenants do not have access to tables:
# Tenant
# Tenantdatasource
# etc
jleroux: (based on a Pierre's comment)
With
./ant create-tenant
and
./ant load-tenant-data-readers
We provide enough tools to explore the opportunity to demonstrate the multi-tenancy aspects of OFBiz.
Moreover OFBIZ-6720 will be used to rewrite the multi-tenant support page in wiki. We will then see if we should not remove old ant tenant related targets now useless
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1714085 13f79535-47bb-0310-9956-ffa450edef68
Removes useless commented out code in UtilCodec.java
Replaces a tab by spaces in ContextFilter.java
Removes useless line and replaces tabs by spaces in OFBizSolrContextFilter.java (annoying in compare)
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1713991 13f79535-47bb-0310-9956-ffa450edef68
Currently many EntityUtilProperties requests have the .properties extension in the parameters for the resource, but this is not needed as it is stripped later on.
jleroux: I found 5 others, replaced also
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1713985 13f79535-47bb-0310-9956-ffa450edef68
As explained in OFBIZ-6669 last comments, contrary to what I did in ContentWorker class, when I before did the work on *ContentWrapper classes I did not use the sanitizer but only an encoder (either HTML or URL).
Because I wrongly supposed that only plain text was used there and certainly my lazy mind thought it was easier because of the URL encoderType to also handle.
When the encoderType is HTML, we now use the sanitizer in *ContentWrapper classes, and ContentWorker.java has also been adapted.
For that I enhanced the UtilCodec class. The sanitizer is only used when HTML is requested, else the sanitize() method simply calls the encode() method.
I removed the content.sanitize property in content.properties and added a sanitizer.permissive.policy property in the new owasp.properties (in base config) with some explanations. This allows for more configuration.
I changed the line 85 in productsummary.ftl to use an HTML content wrapper, same in minilastviewedcategories.ftl.
To be totally complete, we should change *lines like* in productsummary.ftl line 85 to use an HTML content wrapper.
Not easy to spot but anyway those not done will simply not totally show well, without any security impacts.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1713634 13f79535-47bb-0310-9956-ffa450edef68
Currently only a list of geoPoints is shown. The user experience will improve when we not only show that, but a map as well.
jleroux:
I refactored the js scripts in party editGeoLocation.ftl and added webtools GeoLocation.ftl into a new common GoogleGeoLocation.ftl template now included in both party editGeoLocation.ftl and webtools GeoLocation.ftl
I also removed trailing blanks in common GeoLocation.ftl template.
I also added a French label
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1713627 13f79535-47bb-0310-9956-ffa450edef68
SimpleContentViewHandler will return mime type 'text/html' for all DataResource values without a specified mimeTypeId. Changing to DataResourceWorker.getMimeType will allow determining the mimeTypeId by file extension
Fixing the mime type will allow the browsers to display content inline if UtilHttp is updated aswell. All unknown extensions will be set to octet-stream causing the browser to prompt for download
jleroux: after some discussions, this finally uses a content-disposition-type property in requestHandler.properties to allow more flexibility for users (see UtilHttp.setContentDisposition() method). Beware "inline" is less secure. For this reason, Gareth forced the "dangerous" text/html mime type to application/octet-stream in SimpleContentViewHandler class. This to prevent possible static XSS attacks. See the Jira issue for more details.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1712835 13f79535-47bb-0310-9956-ffa450edef68
Actually this worked perfectly well, I just used size instead of height in the hyperlink definition. Better to not set anything and use default value which are committed uncommented here
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1712411 13f79535-47bb-0310-9956-ffa450edef68
The ProductStore has the defaultLocaleString and the defaultCurrencyUomId but does not have a defaultTimeZoneString. What happens when a store is selected (from e-commerce or the POS) is that it will look to the user for a lastTimeZone and if that is not set, it would simply revert to the TimeZone.getDefault() (so the timezone based on the server).
The trouble we had was that you may have an application server that is running in a completely different timezone than what is desired for the store.
jleroux: see comments in the Jira issue for the modifications I did
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1712347 13f79535-47bb-0310-9956-ffa450edef68
It doesn't work because of the way the renderFormatHeaderRowOpen is called causes the FOP renderer to create more than one <fo:table-header>.
The 1st patch adds renderFormatHeaderOpen and renderFormatHeaderClose to separately generate <fo:table-header> for FOP and <thead> for html.
The 2nd patch adds the new list form widget header methods to the deprecated HtmlFormRenderer needed by EmailServices.java to handle OFBIZ-6360 until replaced with MacroFormRender.
The 3rd patch handles the other FormRenderers FOP, Text, Xml. This issue is still a work in process.
jleroux: there is this "FIXME: this is an hack to avoid FOP rendering errors for empty lists (fo:table-body cannot be null)" in code
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1710727 13f79535-47bb-0310-9956-ffa450edef68
This patch adds the new list form widget header methods to the deprecated HtmlFormRenderer needed by EmailServices.java to handle OFBIZ-6360 until replaced with MacroFormRender.
jleroux: completes r1710527
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1710528 13f79535-47bb-0310-9956-ffa450edef68
It doesn't work because of the way the renderFormatHeaderRowOpen is called causes the FOP renderer to create more than one <fo:table-header>.
This patch adds renderFormatHeaderOpen and renderFormatHeaderClose to separately generate <fo:table-header> for FOP and <thead> for html.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1710527 13f79535-47bb-0310-9956-ffa450edef68
This patch adds code to Paginator to account for the entryList being instanceOf List and extracts from the context.results object the original listSize.
jleroux, important note from OFBIZ-6423 which depends on OFBIZ-6422: it is necessary to assign a value (true makes sense) to override-list-size attribute so that FormRenderer.renderItemRows sets the lowIndex correctly, because once the results of performFindList are displayed, otherwise pages > 0 are rendered as empty.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1710413 13f79535-47bb-0310-9956-ffa450edef68
I was testing at catalog/control/FindProduct. I just changed ProductForms.xml#ListProducts service-name from performFind to performFindList. Then upon initially visiting the page the error is displayed.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1710348 13f79535-47bb-0310-9956-ffa450edef68
A form widget with auto-entity-fields for OrderItem will render the quantity fields as text find fields but the prices as range find fields. The quantity find field should match the price range find capability.
This patch adds "fixed-point" to the condition that renders RangeFindField for induceFieldInfoFromEntityField, with support RangeFindField rendering for currency-precise fields also.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1710177 13f79535-47bb-0310-9956-ffa450edef68
Remove javolution reference from multiple java source files and a few
BIRT reports. I had to replace the FastList with a LinkedList in
SolrProductSearch.getSideDeepCategories(..) because it uses the
implementation methods getLast() and removeFirst()
REF https://issues.apache.org/jira/browse/OFBIZ-5169
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1710122 13f79535-47bb-0310-9956-ffa450edef68
Instead of a quiet S/R action, this was an unexpected pain in the ass. A considerable number of forms:
EmployeeForms.xml
EmploymentForms.xml
EmplPositionForms.xml
GlobalHRSettingForms.xml
RecruitmentForms.xml
QuoteForms.xml
PartyForms.xml
StoreForms.xml
ContactForms.xml
FixedAssetForms.xml
TaskForms.xml
scrumForms.xml
TaskForms.xml
contained a large number of fields with
tooltip="${uiLabelMap.CommonRequired}"
but no
required-field="true"
Of course display and display-entity should not be concerned, I spotted a number of them in the lot.
I also removed a bunch of harcoded * at end of labels (those followed by required-field="true"* and spotted a number of others }*" who still need to be carefully reviewed to see if required=true is not missing there :/
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1709882 13f79535-47bb-0310-9956-ffa450edef68
jleroux: after a cursory review, I simply did the chunk related to exampleName by hand, it needed more work. I also removed some trailing blanks.
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1709872 13f79535-47bb-0310-9956-ffa450edef68
I've been working on Jgrowl integration for a project. (https://github.com/stanlemon/jGrowl)
This allowS to display system's messages in a popup at the top of the windows even if you scroll. This is also useful for ajax call because there is no need to scroll to the top of the screen to view message.
Message can stick to the screen until it is intentionally closed by the user or not.
jleroux? as already explained in the Jira: to have it working in trunk HEAD I had to make some changes
I put the jgrowl loading in GlobalActions rather than GlobalDecorator
in showjGrowl() js function
I Added a test for if (contentMessages.length) because of an error in lookups
I did some formatting in function showjGrowl()
I used jQuery instead of $ (same for expandAllP() and expandAll() functions)
git-svn-id: https://svn.apache.org/repos/asf/ofbiz/trunk@1709679 13f79535-47bb-0310-9956-ffa450edef68