The multiple-input multiple-output (MIMO) dual-function radar-communication system can adjust the sidelobe level (SLL) by transmit beamforming to realize the communication function in the line-of-sight channel. However, a high SLL of the transmit beampattern can affect target detection performance. We propose a low-sidelobe covariance matrix design of transmit waveform method to address this issue. Minimizing the integrated sidelobe level is taken as the objective function with the constraint of the mainlobe lower and upper bounds. The optimal global solution can be obtained by the interior point algorithm since the objective function is semi-definite programming. Finally, the simulation results verify the performance in transmit beampattern and bit error rate.