Quality Center Filters and Favorites Action - hp-quality-center

I am trying to change the filters in the display of the current user in the Defects module.
I have set the "tdc.BUGFactory.Filter" object with my filter and i can access the data, but i cannot force it to be displayed to the user! any idea on how to do that?
If i use a SQL command to store it in the common settings table, would it be possible to call an action to load the "Favorites" view i created to the user?
Thanks,
Achraf
================================================================
I found the answer, however stackoverflow doesn't allow me to post it:
I fonud the answer through SQA Forums, to force a filter you use the following
Set defectFilter = tDConenction.BugFactory.Filter ' Example to set a filter criteria
defectFilter.Field ("BG_DETECION_DATE") = "[Today]"
SetDefectsFilter defectFilter.Text
Set defectFilter = Nothing
There is also a function called GetDefectsFilter() which gets the current filter

Related

Understand Dynamic Links Firebase

I would like to understand better Firebase Dynamic Links because i am very new to this subject.
What i would like to know :
FirebaseDynamicLinks.instance.getInitialLink() is supposed to return "only" the last dynamic link created with the "initial" url (before it was shorten) ?
Or why FirebaseDynamicLinks.instance.getInitialLink() doesn't take a String url as a parameter ?
FirebaseDynamicLinks.instance.getDynamicLink(String url) doesn't read custom parameters if the url was shorten, so how can we retrieve custom parameters from a shorten link ?
My use case is quite simple, i am trying to share an object through messages in my application, so i want to save the dynamic link in my database and be able to read it to run a query according to specific parameters.
FirebaseDynamicLinks.instance.getInitialLink() returns the link that opened the app and if the app was not opened by a dynamic link, then it will return null.
Future<PendingDynamicLinkData?> getInitialLink()
Attempts to retrieve the dynamic link which launched the app.
This method always returns a Future. That Future completes to null if
there is no pending dynamic link or any call to this method after the
the first attempt.
https://pub.dev/documentation/firebase_dynamic_links/latest/firebase_dynamic_links/FirebaseDynamicLinks/getInitialLink.html
FirebaseDynamicLinks.instance.getInitialLink() does not accept a string url as parameter because it is just meant to return the link that opened the app.
Looks like there's no straightforward answer to getting the query parameters back from a shortened link. Take a look at this discussion to see if any of the workarounds fit your use case.

PrismTabbedPage created dynamicly with each tab having its own parameters

I'm setting up a PrismTabbedPage dynamically in Xamarin.Forms. I have a content page PrismContentPageProfile which shows the profile of a given Id. The Id I want to pass with a parameter. Problem is that each initialize is having all the parameters.
await NavigationService.NavigateAsync("NavigationPage/PrismTabbedPage1?createTab=PrismContentPageProfile?Id=Michel&createTab=PrismContentPageProfile?Id=Erik");
I expect to tabs. One for the profileId Michel and one for Erik. Problem is that the paramters in the Initialize look like this on each page:
{?createTab=PrismContentPageProfile%3FId%3DMichel&createTab=PrismContentPageProfile%3FId%3DErik}
As I don't know which tab I am, I don't know which profile to load.
I hoped that calling:
await NavigationService.NavigateAsync("NavigationPage/PrismTabbedPage1?createTab=PrismContentPageProfile?Id=Michel&createTab=PrismContentPageProfile?Id=Erik");
would result in different parameters on each page. Id=Michel on the first page, Id=Erik on the second.
Or, if that is not possible, that I know which tab index I am. Then I can read the related parameter.

Cannot add new correlated record to new created record

When I create new record in Google AppMaker and then try to add correlated record to this new one I get this warning in console:
com.google.apps.appmaker.client.datasource.AbstractModelDataSource
WARNING: Could not find element with key RecordKey{key=private$7,
model key=...
Both datasources are set to:
Manual save mode
Automatically load data
The problem doesn't appear when I refresh the page or try to add correlated record to other existing record.
Anybody knows what could be a reason for this error?
App Maker doesn't allow to have unsaved changes on both ends of relation, most likely it is a reason, why you recieve error message in the first case. But in theory it should work once you save one of the relation ends (first save one of the records and then link them and save again):
var countryDs = app.datasources.Country;
var capitalDs = app.datasources.Capital;
countryDs.createItem();
countryDs.item.Name = 'United States';
countryDs.saveChanges(function() {
capitalDs.createItem();
capitalDs.item.Name = 'Washington, D.C.';
capitalDs.item.Country = countryDs.item;
capitalDs.saveChanges();
});
OK, I fixed it.
I have two forms. First to create item. Second to edit data. In the first form page need to be set to:
On Detach: Clear Changes To Datasource.
Datasources need to be set to autosave.

Contact form 7 plugin wordpress - How to send email of filled values only

I have a form that has some optional fields but if a user doesn't fill them out the label of the input will be sent in the email and they will be empty. so for example if a user doesn't enter a city field the email will say City:
Is there a way to set conditionals where if a user doesn't enter optional fields the label wont be sent?
http://wordpress.org/plugins/contact-form-7/
Short answer: yes, but.
Long answer: Wpcf7 has events for on send and others that you can hook into to extract and manipulate the data it has at the time. It's not a well documented aspect of the plug in, because it's really intended for the developer themselves to use, but you can write add_hook commands into your functions . php file and then use your own functions to change the output.
I think the send hook is called "wpcf7_send" so you can write a function like this:
function beforesend($obj) {
//manipulation of message here
}
add_hook('wpcf7_send', 'beforesend');
It's only a starting point but by exploring a bit you can find the hook names, and class structures you need.

Programicatlly visit (all) ASP.Net page(s) in a website?

In the Security model for out ASP.Net website (.Net 3.5) we store the page name:
page.GetType().Name
as the primary key in a database table to be able to lookup if a user has access to a certain page. The first time a page is visited this record is created automatically in the database.
We have exported these database statements to insert scripts, but each time a new page gets created we have to update the scripts, not a huge issue, but I would like to find an automated way to do this.
I created an attribute that I tagged a few pages with and then wrote a small process to get all the objects that have this attribute, through the reflection create an instance and insert the record using the same code to for page records mentioned above:
IEnumerable<Type> viewsecurityPages = Assembly.GetExecutingAssembly().GetTypes().Where(t => t.IsDefined(typeof(ViewSecurityAttribute),false));
foreach (Type t in viewsecurityPages)
{
object obj = Activator.CreateInstance(t, false);
//clip..(This code just checks if the record already exists in the DB)
if (feature == null)
{
Attribute attb = Attribute.GetCustomAttribute(t, typeof(ViewSecurityAttribute));
if (attb != null)
{
CreateSecurableFeatureForPage((Page)obj, uow, attb.ToString());
}
}
}
The issue is that page.GetType().Name when the page goes through the actual page cycle process is something like this:
search_accounts_aspx
but when I used the activator method above it returns:
Accounts
So the records don't match the in the security table. Is there anyway to programtically "visit" a webpage so that it goes through the actual page lifecycle and I would get back the correct value from the Name parameter?
Any help/reference will be greatly appreciated.
Interesting problem...
Of course there's a (too obvious?) way to programmatically visit the page... use System.Net.HttpWebRequest. Of course, that requires the URI and not just a handle to the object. This is a "how do we get there from here?" problem.
My suggestions would be to simply create another attribute (or use that same one) which stores the identifier you need. Then it will be the same either way you access it, right?
Alternatively... why not just use a 3rd party web spider/crawler to crawl your site and hit all the pages? There are several free options. Or am I missing something?

Resources