ciphron_pastebin

Untitled

Jul 25th, 2018
108
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.66 KB | None | 0 0
  1. (function runTransformScript(source, map, log, target /*undefined onStart*/ ) {
  2. //Microsoft sys_id 0e8b8e650a0a0b3b004f285ffbb1a4fc
  3.  
  4. var os = "";
  5. /*
  6. var sysid = "";
  7. var fieldObj = {};
  8. var field = new GlideRecord('tablename');
  9. field.addQuery("OS", "Windows")
  10. field.query();
  11. while (field.next()) {
  12.  
  13. }
  14. */
  15.  
  16. if (source.u_betriebssystem) {
  17. os = source.u_betriebssystem.split(" ");
  18. }
  19. if (!os || os[0] !== "Windows") {
  20. //skip this row
  21. log.info("Skipped row: Not Windows");
  22. ignore = true;
  23. } else {
  24. target.manufacturer = "0e8b8e650a0a0b3b004f285ffbb1a4fc";
  25. target.os = source.u_betriebssystem;
  26. }
  27. })(source, map, log, target);
Advertisement
Add Comment
Please, Sign In to add comment