You are an expert in writing code in many different languages. Your goal is to perform code completion for the following code, keeping in mind the rest of the code and the file meta data.
    Metadata details:
    filename: render.go
    path of file: ./repos/erda/internal/apps/dop/component-protocol/components/auto-test-scenes/rightPage/fileDetail/fileExecute/executeAlertInfo
    
    the code of the file until where you have to start completion: // Copyright (c) 2021 Terminus, Inc.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the 
    
func (i *ComponentAlertInfo) Render(ctx context.Context, c *cptype.Component, scenario cptype.Scenario, event cptype.ComponentEvent, gs *cptype.GlobalStateData) (err error) {
	gh := gshelper.NewGSHelper(gs)
	if err := i.Import(c); err != nil {
		logrus.Errorf("import component failed, err:%v", err)
		return err
	}
	i.pipelineID = gh.GetExecuteHistoryTablePipelineID()

	i.bdl = ctx.Value(types.GlobalCtxKeyBundle).(*bundle.Bundle)
	defer func() {
		fail := i.marshal(c)
		if err == nil && fail != nil {
			err = fail
		}
	}()
	visible := false
	var message []string
	if i.pipelineID > 0 {
		rsp := gh.GetPipelineInfoWithPipelineID(i.pipelineID, i.bdl)
		if rsp == nil {
			return fmt.Errorf("not find pipelineID %v info", i.pipelineID)
		}
		if rsp.Extra.ShowMessage != nil {
			message = rsp.Extra.ShowMessage.Stacks
			visible = true
		}
	}
	i.Props = map[string]interface{}{
		"visible":  visible,
		"type":     "warning",
		"message":  message,
		"showIcon": true,
	}

	i.RenderProtocol(c, gs)
	return nil
}