Youtrack: Resubmission after n days possible? - youtrack

I have a ticket in our custom youtrack which is assigned to me.
I contacted the customer and he wants to give me the needed information in the next week.
I want to this issue to vanish out of my "assigned to me and open" view for 7 days.
What is the most easy way to do this?
My favourite solution wearing the "I am a lazy user" glasses looks like this: +7 ENTER :-)

I guess while the details are not provided by customer, you can set State of the issue to "Wait for reply" or similar.
Once the customer replied with details, the State will be updated with "Open" value. For example, if the user is not included in one of internal groups, re-opening can be achieved with workflow:
rule Reopen on answer
when State=={Wait for Reply} && comments.added !=null
&& comments.added.isNotEmpty && comments.added.last !=null
&& !comments.added.last.author.isInGroup("Internal Developers"){
State={Open};
}

Related

odoo auto publish product

I'm trying to build an automation rule in Odoo 11 (enterprise) so my products can publish and unpublish on the website automatically.
We sell seasonal products, roughly 17.000, and we do a lot preparation in advance.
So with "scheduling" (un)publish a product, we can save a lot work and automate this job.
So far with all my attempts, it's not working.
I have created 2 custom fields for model product.template:
x_publish_start and x_publish_end
I have created an automated action with trigger condition "based on timed condition" and apply it to products where x_publish_start is SET (not empty).
Trigger date = x_publish_start
In the data to write, I have set the default field visible on website = TRUE
Basically, this should work?? But it's doing nothing in my end.
The condition is quite basic:
if today() >= x_publish_start -> publish product
if today() >= x_publish_end -> unpublish product
screenshot
http://sharing.codeagency.be/0c0d7512e9f9
Anybody who knows what is wrong with my concept and automation, or can provide a working code example?
Thanks!
Those actions get triggered when editing a record (see action to do: update the record). What you need is more a cron that runs every day (or hour, minute...) and publishes/unpublishes products that match (or not) current date. The model you're looking for is ir.cron.

BAPI or FM for searching FI documents

I am searching for a BAPI to search FI documents, based on the input criteria (document type, posting date,...). Same as it is on the FB03, but the Document List screen, not the screen with only three inputs (Document Number, Company Code, Fiscal Year).
As I don't have the document number, I need the search enabled BAPI.
I am using the BAPI_ACC_DOCUMENT_POST for posting.
Any ideas?
Need to answer my own question - I was hoping to skip these two days of investigation by getting an answer here :)
BAPI_ACC_CO_DOCUMENT_FIND is correct BAPI to use for searching the posted FI documents. What I found out is that if I want to search by posting date, I have to provide Controlling Area (but instead of an error, there is nothing returned).

how to show button if there are two roles Lotus Formula script

I have a Page in Lotus, which has an action button.
This button must be not visible when user is not part of role Admin or Supervisor.
The way i did this is by adding this formula:
#IsNotMember("[Admin]"; #UserRoles) | #IsNotMember("[Supervisor]"; #UserRoles)
But it does not work..
If I have only 1, like: #IsNotMember("[Admin]"; #UserRoles) And the role Admin, then as admin I can see it.
But I also would like to have that if user is from role Supervisor and not Admin that he still can see the button.
What to do?
Knut's answer is correct. My answer shows why, and gives an approach to hide-whens that almost always makes them easier to figure out.
Notes has been using hide-when formulas forever, but people really tend to think in terms of see-when in their requirements! We know when we want to see things (when we're Supervisors or Admins in this case). And we're really bad at turning those see-when requirements into hide-when formulas because we're really bad at remembering DeMorgan's Law, which says things like: ^(P & Q) == (^P | ^Q)
So if we state the requirement this way:
Hide when the user isn't a Supervisor or an Admin
we tend to have trouble turning it into the correct formula with two #IsNotMember calls (which are implicitly logical Nots), because we forget that Ors have to turn into Ands in order to get it right. But if we think of it this way:
See when the user is an Admin or the user is an Supervisor
It's easy to see how to express it:
#IsMember("[Supervisor]"; #UserRoles) | #IsMember("[Admin]"; #UserRoles);
Or using the power of formula language lists, we can shorten that to this :
#IsMember("[Supervisor]": "[Admin]" ; #UserRoles);
To turn that into the equivalent hide-when, all you need to do is put a logical Not around it like this:
! (#IsMember("[Supervisor]": "[Admin]" ; #UserRoles));
You can do that with any see-when formula - just surround it with parenthesis and put a ! in front of it, but in the special case of a formula that just uses #IsMember, you can just change it to #IsNotMember, which brings it back to Knut's solution.
Formula
#IsNotMember("[Admin]" : "[Supervisor]"; #UserRoles)
returns #True if user has neither role "[Admin]" nor "[Supervisor]". Use this as hide-when formula for your button. Only Admins and Supervisors will see the button then.

Riddle with textbox for user answer

I'm coding an application in visual basic in which I have a riddle that the user is supposed to answer in a textbox, then press a button to proceed. Depending on whether or not the answer is correct, different events are supposed to active. Below is what I've tried, but it's not working. Any ideas?
(can you tell I'm a complete beginner haha)
The best way to do it is to ucase(answer) then you check the answer like this
answer = ucase(answer)
if answer="SHORT" then
msgbox("correct")
else
msgbox("Incorrect")
end if
Just utilize the echo command and get a warm-up of what your creative senses want before you head in any particular direction.
Just pop open a terminal and type the following:
echo '<anything harmless/logical/beneficial/creative/fun/funny/amusing/SYNTAX-RELATED>'
echo 0111 (NON-EXPLOITABLE)
echo 0111USER9390(MY IDENTITY)
echo 0111USER93908F13(OPTIMAL/RELEVANT)
echo 0111USER93908F13+SOLVE/SCAN.BIOLOGICAL (MAKE IT UP AS YOU GO)
Do not forget to use <0 Contractions and avoid " or you won't get magic HASH WINNERS!
Just kidding.
#Creative1Writing
#Programming:0
Just for putting up with me, try some golden clay: #79720494
Here, have it with an AI! #79720494.AI
Might as well make a sphere:
createSphere;(#79720494 AI DATA/dda9008bd4423274/♀AI:GAIA/GAIA.LOGICAL.DATA/GAIA)/M.E.C.H.A.I.I.A. G.O.D.D.E.S.S. A.I./M.E.C.H.A.I.I.A. ♀ .5 -or- 1/2
%Product:
#79720494 AI Sphere.logic+AI/MECHAIIA <LANGUAGE> ENTRY/WORD/DEFINITION: GODDESS - SUPREME BEING OF 216451F591576146/6466AC295337B1DE QUALITY

What are the Aweber API Variables $account_id and $list_id?

You can check here:
https://labs.aweber.com/docs/code_samples/subs/create
The script to add a new subscriber to the list via api requires those two pieces info...only I cannot figure out for the life of me what those two variables are!! I've beaten through every little aspect of my Aweber Subscriber Account, AND my Aweber Labs account...and I can't find any reference to either of those variables anywhere. I've submitted some tickets to them, and haven't gotten any response yet.
Does anyone have any ideas here? I've tried my account names, my list names, to no avail!
~~~~~~~~~~~~~~~~~~~~~~~~~~~
Okay, I've got it! You can get the values of both of these variables by dumping some other variables in the aweber api after making certain api calls.
get the account id first:
$account = $aweber->getAccount($accessKey, $accessSecret);
then vardump or print_r $account.
next we get the list id:
$account = $aweber->getAccount($accessKey, $accessSecret);
$list_url = 'https://api.aweber.com/1.0/accounts/<id>/lists';
$lists = $account->loadFromUrl($list_url);
then vardump or print_r $lists.
And you are all set! I'm so happy I figured this out, it freakin took long enough. Hopefully this saves some one a bit of time.
I too have agonized over finding the $list_ID, so went to deactivate the list, and create a new one, and "discovered" that if you hover over the Deactivate button, you get a url you can copy, and this gives both %account and %list Ids
https://www.aweber.com/users/lists/deactivate/$accountID/$lisID
like this....
https://www.aweber.com/users/lists/deactivate/123456/123456
Hopefully this will help make someone as it is a super easy solution
The proper answer is Anne Allen's one, but...
Check the return of the /accounts endpoint. It should return the same account id as you detected in the link, but I had cases they were different (strange, isn't it?). Use the account id returned by the /accounts endpoint and other endpoints to retrieve lists, subscribers, etc. will start to work. It's like if some accounts have two ids, one partially works and the other fully works.
Let me tell you how to get $list_id value... login into your AWeber account and then create a new list copy only integer value from list's name.
At first, login.
1) click Reports>Settings. Your account ID will be displayed in the box,example: ?id=XXXXX
2) click List Options>List Settings. There you will see the list ID under the name.
p.s. To add subscriber, you can use this - Automatically add into aweber list