Uploading/Adding a war and a jar using gradle

Hi All,

Can I use Publishing multiple modules from a single project from Chapter 34 which is below to upload a jar and a war file ?
-> Can I do this using uploadArchives ?

My main aim is to publish a jar and a war to artifactory using artifactorypublish and do that using the Jenkins Artficatory plugin.