% % process transaction for pshop demo % % stack: xact image1 text1 image2 text2 image3 text3 image4 text4 % template result % isnull { pop _Arching.Result } if !Result !Template !Text4 !Image4 !Text3 !Image3 !Text2 !Image2 !Text1 !Image1 !Xact _Image1 any? { jpg ^_CameraDir !Im1 _Im1 exists not { "NoImage.jpg" ^_ImageDir _Im1 copyfile } if } if _Image2 any? { jpg ^_CameraDir !Im2 _Im2 exists not { "NoImage.jpg" ^_ImageDir _Im2 copyfile } if } if _Image3 any? { jpg ^_CameraDir !Im3 _Im3 exists not { "NoImage.jpg" ^_ImageDir _Im3 copyfile } if } if _Image4 any? { jpg ^_CameraDir !Im4 _Im4 exists not { "NoImage.jpg" ^_ImageDir _Im4 copyfile } if } if _Template isnull) _Xact isnull) or { } { _Arching.PhysChain &"xact" &_Xact &"\" !TarXact "" _Im1 quoter &" !Im1" catcr & _Im2 quoter &" !Im2" catcr & _Im3 quoter &" !Im3" catcr & _Im4 quoter &" !Im4" catcr & "TemImg.txt" ^_TarXact write "//* function XactSrc() { MaxOrdinal = 4; SourceImage = []; SourceText = []; SourceImage[0] = " _Im1 *jsphfspc quoter & &"; SourceText[0] = " _Text1 quoter & &"; SourceImage[1] = " _Im2 *jsphfspc quoter & &"; SourceText[1] = " _Text2 quoter & &"; SourceImage[2] = " _Im3 *jsphfspc quoter & &"; Image = SourceText[2] = " _Text3 quoter & &"; SourceImage[3] = " _Im4 *jsphfspc quoter & &"; Subject = SourceText[3] = " _Text4 quoter & &"; Xact = " _Xact ^"xact" quoter & &"; SourcePath = " _ImageDir *jsphfspc quoter & &"; TargetPath = " _TarXact *jsphfspc quoter & &"; Template = SourcePath +" _Template psd quoter & &"; Result = " _Result quoter & &"; } " "XactSrc.jsx" ofdesk write "//+XactSize //+Server //* Xacting('" &_Xactex &"','Main'); " *phocperf } ifelse