Groovy web console

subscribe to the feed Subscribe
to this
site

правильный

Published 2 weeks ago by Андрей
Actions Execute script  ▶ Edit in console Back to console Show/hide line numbers View recent scripts
def codes = '''
302708572'''
def template = '''
            {
                "customer_code": "%s",
                "event_name": "main_test_0",
                "event_type": "BANNER",
                "properties": {}
            },'''

def res=""
codes.split("\n")each {
    res += sprintf(template, it)
}


println res