|  |  | 
 |  |  | import com.dy.pipIrrGlobal.pojoPr.PrController; | 
 |  |  | import com.dy.pipIrrGlobal.pojoRm.RmCommandHistory; | 
 |  |  | import com.dy.pipIrrGlobal.rtuMw.Web2RtuMw; | 
 |  |  | import org.springframework.transaction.annotation.Transactional; | 
 |  |  |  | 
 |  |  | import java.util.Date; | 
 |  |  |  | 
 |  |  | 
 |  |  |      * @param operator | 
 |  |  |      * @return | 
 |  |  |      */ | 
 |  |  |     @Transactional(rollbackFor = Exception.class) | 
 |  |  |     public RmCommandHistory saveComHistoryPo(RmCommandHistoryMapper rmCommandHistoryDao, | 
 |  |  |                                              Long comId, | 
 |  |  |                                              String protocol, | 
 |  |  | 
 |  |  |         po.setParam((JSONObject) JSON.toJSON(param)); | 
 |  |  |         po.setSendTime(new Date()); | 
 |  |  |         po.setOperator(operator); | 
 |  |  |         rmCommandHistoryDao.insertSelective(po) ; | 
 |  |  |         int count = rmCommandHistoryDao.insertSelective(po) ; | 
 |  |  |         if(count == 0){ | 
 |  |  |             po = null ; | 
 |  |  |         } | 
 |  |  |         return po; | 
 |  |  |     } | 
 |  |  |  |