Jump to content

Search the Community

Showing results for tags 'spel'.



More search options

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


Forums

  • CA Service Desk Manager
    • General Discussions
    • Customizations / Modifications
    • Bugs / Errors / Patches
    • Knowledge Tools / Keyword Search
    • Support Automation
    • CMDB
    • Install / Migrate / Configure
    • Product Integration
    • Reporting
    • Workflow
  • Nimsoft Service Desk
    • General
  • General
    • Wiki Article Discussions
    • ITIL & Best Practices
    • Speak Out
    • Employment Opportunities

Categories

  • Getting Started
  • Installation
  • Configuration
  • Customization
  • Integration
    • CA Applications
    • Non-CA Applications
    • Custom Integrations
  • Reporting
  • Miscellaneous

Find results in...

Find results that contain...


Date Created

  • Start

    End


Last Updated

  • Start

    End


Filter by number of...

Joined

  • Start

    End


Group


AIM


MSN


Website URL


ICQ


Yahoo


Jabber


Skype


Location


Interests

Found 6 results

  1. Hey guys! I need to update some customers data according to the information that he enters at the moment of the opening of the ticket, for example a phone_number field. When filling this information in detail_cr, I need this phone data to be recorded in the phone_number attribute in the cnt factory. I found a spel code from @cdtj and thought it would work well. cr::z_update_obj(...) { object inc_group_leader; send_wait(0, top_object(), "get_co_group"); if (msg_error()) { logf(ERROR, "Error: '%s'", msg[0]); return; } inc_group_leader = msg[0]; string inc_where_clause; inc_where_clause = format("id = U'%s'", customer); // your UUID here, customer for example send_wait(0, top_object(), "call_attr", "cnt", "sync_fetch", "STATIC", inc_where_clause, -1, 0); object inc_zfound; inc_zfound = msg[0]; object inc_zobj; send_wait(0, inc_zfound, "dob_by_index", "DEFAULT", 0, 0); inc_zobj = msg[0]; send_wait(0, inc_group_leader, "checkout", inc_zobj); if (msg_error()) { logf(ERROR, "Cannot checkout"); return; } inc_zobj.phone_number = string4; // your attributes here // inc_zobj.z_some_another_attribute = z_value; // u can change multiple attributes send_wait(0, inc_group_leader, "checkin"); if (msg_error()) { logf(ERROR, "Cannot checkin"); send_wait(0, inc_group_leader, "uncheck"); return; } } I think I need to add some more details to the spel code or even improve the trigger. My trigger: MODIFY cr POST_VALIDATE z_update_cnt( customer, string4 ) 9020 FILTER(EVENT("INSERT") && (status == "OP")) ; Do I need to add any other attributes to the spel code? Thanks!!
  2. Hello good afternoon I have a detail with a spel since this to place the value of the zGrupop_inicial field in the group.id field I share the spel code if(type=="R" && active == 1) { if(status.code == "OP") { if(codeRol=="SOLSERRED") { send_wait(0, this, "get_attr_vals", 1, "zGrupo_Inicial"); zGrupo_Inicial=msg[3]; if(is_null(zGrupo_Inicial) || is_empty(zGrupo_Inicial) || zGrupo_Inicial=="") { send_wait(0, this, "call_attr", "zGrupo_Inicial", "set_val", group.id, "SURE_SET"); logf(SIGNIFICANT, "successfully set campo zGrupo_Inicial"); }else{ logf(SIGNIFICANT, "campo zGrupo_Inicial lleno"); } } } if(status.code == "RE") { if(codeRol=="SOLSERRED") { send_wait(0, this, "call_attr", group.id, "set_val", "zGrupo_Inicial", "SURE_SET"); logf(SIGNIFICANT, "successfully set campo zGrupo_Inicial"); } } } } I hope you can help me
  3. Good morning collaborators, I am building a spel code using get_list method to get the amount of CI's which they are element's KPIs in a specific Change Order. For that I used the following code which one works when I put the change order number as hard code as this: chg::zmatriz_riesgo(...) { object obList; int kpi_count, afectados, pruebas, ambiente_homologado, rollback, contingencia, frecuencia; string chg_num; chg_num = argv[3]; // ********** Existencia de Elementos de Configuracion KPI ********** uuid who; send_wait(0, top_object(), "call_attr", "cnt", "current_user_id"); who=msg[0]; send_wait(0, top_object(), "call_attr", "api", "get_list", "lrel_asset_chgnr", who, "chg.chg_ref_num IN '633' AND nr.zkpi IN '1'", -1); if (msg_error()) { logf(SIGNIFICANT, msg[0]); } else { obList = msg[0]; kpi_count = msg[1]; } but now I want to do this usable for any change order and I need to concatenate a variable in where clause after chg.chg_ref_num. I tried this but it doesn't work: chg::zmatriz_riesgo(...) { object obList; int kpi_count, afectados, pruebas, ambiente_homologado, rollback, contingencia, frecuencia; string chg_num; chg_num = argv[3]; // ********** Existencia de Elementos de Configuracion KPI ********** uuid who; send_wait(0, top_object(), "call_attr", "cnt", "current_user_id"); who=msg[0]; send_wait(0, top_object(), "call_attr", "api", "get_list", "lrel_asset_chgnr", who, "chg.chg_ref_num IN '+chg_num+' AND nr.zkpi IN '1'", -1); if (msg_error()) { logf(SIGNIFICANT, msg[0]); } else { obList = msg[0]; kpi_count = msg[1]; } Can you tell me what is wrong in the concatenation in get_list method? Regards.
  4. Can you help me? I need solve this problem. One of WF tasks must be skipped when affected_contact is member of Group assigned to task. How can I test it in Spel macro which will be started on change Task status to Pending? THX.
  5. How to log comment a bulk number of tickets with a single update? what is the best-optimised design solution to achieve this requirement. Service Desk 12.9
  6. Hi, I need to know if it's possible to run a spel function from a button in the detail_cr.htmpl form (for example). Regards.
×
×
  • Create New...