cdtj

Members
  • Content count

    579
  • Joined

  • Last visited

  • Days Won

    14

cdtj last won the day on June 19

cdtj had the most liked content!

Community Reputation

19 Good

6 Followers

About cdtj

  • Rank
    Level 7 Contributor
  • Birthday 06/09/1988

Profile Information

  • Gender
  • Location
    pdm_halt
  • Interests
    looking for the fulltime job or remote one

Contact Methods

  • Skype
    cdtj71

Recent Profile Visitors

763 profile views
  1. hi, i think that you can publish new flag and define data partion to prevent any updates, condition could be like: id=0 OR (z_some_type = 0 OR z_some_type is NULL). Other question how you'll manage that flag. Regards, cdtj
  2. hi, we don't use tickets and kds linking in our env, so I'm not sure what type of relation is used in your scenario. Regarding to cr factory there is attributes like: avoided_by_kd or solved_by_kd. For example you can create condition macro with followed code: send_wait(0, top_object(), "call_attr", "kdlinks", "sync_fetch", "STATIC", format("cr = '%s' AND link_type = 1", persistent_id), -1, 0); if (msg[1] == 0) { // ticket haven't related documents set_return_data(FALSE); } else { set_return_data(TRUE); } And use it in status transition. Regards, cdtj
  3. Really strange, updated code: function zEditCr(value) { rs.data("<a href=\"#\" onclick=\"showEdit('" + crPersid + "');\">" + value + "</a>"); } <PDM_MACRO name=lsWrite text="var crPersid = \"@{list.persistent_id:}\";"> <PDM_MACRO name=lsCol hdr="ref_num" attr="ref_num" fmtfunc="zEditCr"> showEdit is a function used in a Right click menu.
  4. Glad to help you but I want to warn that "SET.<attriubte>" is actual attribute that will be posted into DB. KEY.<attr>, CBX.<attr> or <attr>_combo_name are affects only visible side. Have you tried to click Save button with empty fields? If error appear it's ok but if not you'll need to debug the code and find a way to nullify SET.<attr>s too.
  5. I have updated my previous post, check it out.
  6. hi, yeah, in lsCol you need to replace "link=yes" with fmtfunc, which should have url with OP=UPDATE, should be something like this: function zEditCr(value) { rs.data("<a href=\"#\" onclick=\"showEdit('" + crPersid + "');\">" + value + "</a>"); } <PDM_MACRO name=lsWrite text="var crPersid = \"@{list.persistent_id:}\";"> <PDM_MACRO name=lsCol hdr="ref_num" attr="ref_num" fmtfunc="zEditCr"> Regards, cdtj
  7. error could appear in browser's console, you can check it by pressing F12, also you can try to execute code manually from console, type: ahdframe.zEmptyAsgnGrp(); or ahdframe.jq("[name=SET.assignee]").val(""); ahdframe.jq("[name=assignee_combo_name]").val(""); and post results here. Regards, cdtj
  8. check this one: function zCancelOnCopy() { if (location.href.indexOf('METHOD=copy_cr') > 0) { <PDM_IF "$args.z_value" == "Not ok" || "$args.z_value" == ""> alert('Some message'); detailCancel(); </PDM_IF> } } then add this into <body> onload: <body class="detailro" onload="loadActions();zCancelOnCopy();" onunload="unloadActions();">
  9. could you step by step explain your scenario? how the attribute should affect on copying functionality
  10. hi, this can be achieved using javascript: function zEmptyAsgnGrp() { jq("[name=SET.assignee]").val(""); jq("[name=assignee_combo_name]").val(""); jq("[name=SET.group]").val(""); jq("[name=group_combo_name]").val(""); } then add zEmptyAsgnGrp(); to <body> onload area. Regards, cdtj
  11. hm, i think that bettor to disable copying functionality for specified situation instead of cancelling it. If i understand your goal, you want to disable copying of ticket if some value selected? It's easy if value can't be changed and you're on detail form in read-mode but slighty harder if it should be disabled on-the-go after selecting value in edit mode. BUT: if you want to go "canceling way" you can try to call parent.window.close(); or detailCancel(); Regards, cdtj
  12. So, you have Dropdown input which haven't <Empty> value in copied ticket? I think this might be caused due field mandatory. You can manually define dropdown and force add empty value in this way: var z_attr_val; var z_attr_req = true; // make required // We need this switch to fetch header from value, if header doesn't match value switch ("$args.z_attr") { case "Value1_value" : z_attr_val = "Value1_hdr";break; case "Value2_value" : z_attr_val = "Value2_hdr";break; } detailDropdown("Header", "z_attr", "pri", 1, 20, z_attr_req, "", "$args.z_attr", "no", "z_attr", "$args.z_attr", "","","no","","", z_attr_val, "<Empty>", "", "Value1_hdr", "Value1_value", "Value2_hdr", "Value2_value" );
  13. Hi, as I know there is 2 ways: 1. using JavaScript, find function called copy_form_<factory_name>, then modify content in this way: function copy_from_cr() { var exceptions = new Array(); exceptions.push("SET.attr1"); exceptions.push("SET.attr2"); exceptions.push("SET.attr3"); detailCopyEditForm(exceptions); } where attr1, attr2, attr3 should be excluded attributes. I havent tested it. 2. using SPL (I have tested this in my env): Open: NX_ROOT\bopcfg\majic\tmplcopy_site.spl and find copy method for decided factory, than nullify attribute you want to be empty in this way: cr::copy_cr_site(...) { object old, new, alg, gl; old = argv[0]; new = argv[1]; alg = argv[2]; gl = argv[3]; // clearing description and summary: new.description = NULL; new.summary = NULL; return; } Regards, cdtj
  14. hi, with spel code you can execute external services using exec function. example: exec("ping google.com"); function have no return statement. If you need more advanced way, you can use PERL instead: https://communities.ca.com/docs/DOC-231168303-spel-how-to-execute-remote-reference-via-perl-code Regards, cdtj
  15. Hi, as far as I know you can use CA PAM to run 3rd party API from CA SDM, but sorry, I haven't experience in that question. If you have access to CA Support you could ask for the 3rd party integration's best practices. Regarding to our practice we have dedicated email server which do all the stuff, we have defined pager-email address using mask: <phone_number>@sms.ourcompany.com and simply sending short notifications to that address. Regadrs, cdtj