Encode/decode and serialize/unserialize PK to allow composite keys in widget and action