I need to suppress the page header when there are no records in the detail section.I have used
onLastRecord
at page header->section expert->suppress.it works fine but issue is when there is only one record in the detail section.then page header is suppress how can i avoid this?
I think your question requires more detail.
Anyway, based on what I have understood, I would suggest any of these ways to sort out this issue.
Add a count() function formula to the suppress section. Find details here.
Add a condition like OnLastRecord or {GROUP FIELD NAME} <> Next({GROUP FIELD NAME}). Find details here.
Check for IsNull({table.field}) of a non-null field.
Check whether the DisctinctCount of the PK field is null.
Related
Please tell me how to read Issue Fields like resolveProjectID & resolveTaskID:
****.workfront.com/attask/api/OPTASK/search?id=5bf801f101b144a12aabb51f2c068caa
returns:
{"data":
[{"ID":"5bf801f101b144a12aabb51f2c068caa",
"name":"test-dev-issue","objCode":"OPTASK",
"plannedCompletionDate":"2018-11-27T00:00:00:000+0200",
"status":"NEW",
"primaryAssignment":null}]
}
According to the API-Explorer guide (https://support.workfront.com/hc/en-us/articles/220633507-API-Explorer), resolveProjectID & resolveTaskID should be located within OPTASK fields. I couldn't find anything helpful yet within their documentation.
Thank you!
The search you're executing will work, but if you know the ID of the record you're retrieving then you should call it directly (/api/v9.0/OPTASK/5bf801f101b144a12aabb51f2c068caa).
The return value is, by default, a small set of fields providing some basic data. If you want more fields, add a parameter (fields=).
I want to get event entries by their description (data).
I know how to get the event entry with a certain description, however I want to get an entry whith a description which contains a string (not equals to it).
That, I don't know how to do.
Please help :)
According to my answer here: https://stackoverflow.com/a/34119006/5089204 you should be able to retrieve EventRecords.
Dealing with these events is a quite complex issue... Each event has its own internal structure. The common properties are bundled in EventRecord, but the specific data must be taken from the internal details. Use the ToXml() method of an EventRecord...
In order to get the right events you must define an EventLogQuery. You must know the Provider's name and specify the filter.
Try the following: Open eventvwr and there the Windows-System queue. Right click one event, open the "Details" and choose the "XML-View". Look over different events and you will find, that they are quite differing.
But: You'll find everything you need there: First the "Provider Name" and the "EventId", these two are most important for the `EventLogQuery'.
Now go to the "define a user filter on the current protocoll"-action and type in some values. Then switch to the filter's XML and you'll learn how to define the correct query.
I'm sorry, there is no "easy and general" approach :-)
I did some changes one of the method on accounting report in OpenERP. My problem now is how can i make some item invisible or delete? In particular, I want to hide the "Liability" and its balance on the report.
I tried something like this on get_lines method:
for report in lines:
if report["name"].lower().replace(" ","") == 'liability':
del report["name"]
del report["balance"]
but when i tried to generate Balance sheet report. It says:
(<type 'exceptions.KeyError'>,KeyError('name',), <traceback object at 0x7f6c4c2903f8>)
Any help is much appreciated.
This is an error that raises when you try to access object key that doesn't exist. In your case "name".
Error you have is "logical" error, simply go into debug and see what you get in report variable inside loop.
Moreover, to change report content (and by report I think you mean pdf output right?) you need to override .rml file. I think you are changing report parser here, which is also ok if you know what you are doing.
Here you can find RML documentation: http://www.reportlab.com/docs/rml2pdf-userguide.pdf
So, to sum: to change report output content override or replace parser, to change structure, hide/add fields override existing report (.rml file) or create entirely new report.
Hope it helped :)
This might not be the good (or perhaps the weirdest) solution to the problem but after reading about .rml and i can't still comprehend this is what i did. Instead of trying to delete report["name"] and report["balance"] i just set it's value into a white space. This time it's no longer shown on the report.
When a user login , the user will be redirect to a user profile page, which has a My account field set.
the field set has 2 fields, "Username: ", "Email address:". those 2 fields are generated by drupal.
those 2 field contained in a form which has a id ("user_profile_form") . I want to change the order of those 2 fields.
I have tried to intercept 'user_profile_form' , inside hook_form_alter.
code as follow:
$form['account']['name']['#weight'] = 1;
but that did not success, drupal did not even rendering the 'name' field, so no username: showed on browser.
What you did is absolutely correct, and probably did work. You can change the weight of the fields with the method described above.
The username field is not always rendered. The reason is that a persmission is required: change own username. If that perm is not set, you wont be allowed to alter you username and the field wont be shown.
Info on debugging.
Your info alone is not quite enough to debug. From what you describe, you are doing the right thing, but other modules could be making things a bit tricky for you. The devel module is quite good when it comes to debugging, ti defines two functions I use a lot when debugging:
dpm() pretty prints the variable to the message area using krumo.
dd() Prints / saves a variable to a log file. Useful when you can't view messages on the screen.
I would suggest that you look at the $form variable before and after you alter it.
Things that could make it go wrong:
Did you remember to pass the $form variable by reference using the & notation?
Is another module altering your form after you?
Are you checking for the correct form id, so you alter the correct form?
These are some pointers, before you bring more info, all I can do is guess to what your problem exactly can be. I did something like this a few days ago so I know what you describe shouldn't be a problem.
I'm trying to create an img link manually with php in the header field of a view, in drupal 6. I need to read the value of one of the filters, but can't find the right variable to read. I thought I could print_r($view->filters) but it didn't give me anything, and I eventually found out that isset($view) is false.
Am I looking the wrong way?
The context I'm writing in is the header field of the view, with php code as input format. Do I have to "enable" the $view variable for reading in this context somehow?
OK I found it, it was really easy:
$pa_view = views_get_current_view();
$pa_nr = $pa_view->display['default']->display_options['filters']['field_nummer_value']['value']['value'];