示例#1
0
    def get_display(my):
        sobject = my.get_current_sobject()

        if my.name == None:
            my.name = "snapshot"

        xml = sobject.get_xml_value(my.name)

        images = xml.get_values("snapshot/file/@name")
        if len(images) != 3:
            return "No images"
        file_codes = xml.get_values("snapshot/file/@file_code")

        html = Html()
        for i in range(0, len(images)):
            html.writeln("%0.10d : %s<br/>" % (int(file_codes[i]), images[i]) )

        return html.getvalue()
示例#2
0
    def get_display(my):
        sobject = my.get_current_sobject()

        if my.name == None:
            my.name = "snapshot"

        xml = sobject.get_xml_value(my.name)

        images = xml.get_values("snapshot/file/@name")
        if len(images) != 3:
            return "No images"
        file_codes = xml.get_values("snapshot/file/@file_code")

        html = Html()
        for i in range(0, len(images)):
            html.writeln("%0.10d : %s<br/>" % (int(file_codes[i]), images[i]) )

        return html.getvalue()