Packages zenity and xterm must be installed and the script must be executable (chmod +x the-script)
#!/bin/sh
zenity --question --text "Would you like to check and install updates?"
if [ $? = 0 ];
then
xterm -e su -c 'xterm -e zypper update && zypper -y upgrade' root && zenity --info --text "System Upgraded"
else exit 0
fi
Read also openSUSE and deltarpm update