//将主表的字段的拼接
export default {
    execute:function(){
        console.log("进入主表的字段的拼接前端公式");
        if(arguments && arguments[0] && arguments[1]){
           var concatData = ""
           const masterList=arguments[0]
           const firstData = arguments[0][0]
           const  firstDataLink = firstData.FieldTableCode + "." +firstData.FieldCode
           for (const item  of  masterList){
               if(item instanceof BillDataNode){
                if (item !== firstData){
                    let  itemLink = item.FieldTableCode + "." + item.FieldCode
                    let  itemData = item.dynamicNodeFactory.methodJson.GetFieldData('', itemLink, '')
                    if(itemData !== null ){
                        concatData += itemData
                    }
                }
               }else if(item instanceof StaticDataNode){
                 concatData += item.StaticValue
               }
           
           }
           firstData.dynamicNodeFactory.methodJson.SetFieldData("",firstDataLink,concatData,"")
        }
      
    },
    getResultType:function(){
        return FMR.ConstDataTypes.General;
    }
}