Currently, the new Map Viewer and Map Viewer Classic only support adding attachments from hosted feature services (hosted in AGOL or hosted in Enterprise). We would like to be able to add attachments from our enterprise geodatabase (SDE), which has a service in Portal and then is shared to ArcGIS Online. Using this final AGOL service, you can add attachments in mobile apps, just not in AGOL itself.