📄 getcontent.java
字号:
//if(Config.Switch.startsWith("on") && this.thirdNum!=0){ Config.submit_queue.push(submitStr); /********************/ sql="insert into mobile_bill (row_id,msg_content,dest_terminal_id,bill_type,gateway_msg_id,src_terminal_id,registered_delivery,gateway_route,msg_type,create_date,pk_total,pk_number,create_time,service_id)values('"+(++Config.id)+"','"+this.msg_id+"','"+Config.service_code+"','Mo','"+this.gateway_msg_id+"','"+this.src_terminal_id+"','"+this.registered_delivery+"','"+this.source_name+"','"+this.msg_type+"','"+Time.getDateString()+" "+Time.getTimeString()+"',"+Content.pk_t+","+Content.pk_n+",'"+Time.createTime()+"','"+Config.service_id+"')"; Config.sql_queue.push(sql); //} boolean isSubcode; try{ int i=Integer.parseInt(this.service_type) ; isSubcode=true; } catch(Exception e){ isSubcode=false; } /* if(!isSubcode && Config.Switch.startsWith("on") && this.thirdNum==0 ){ Config.submit_queue.push(submitStr); sql="insert into mobile_bill (row_id,msg_content,dest_terminal_id,bill_type,gateway_msg_id,src_terminal_id,registered_delivery,gateway_route,msg_type,create_date,pk_total,pk_number,create_time,service_id)values('"+(++Config.id)+"','"+this.msg_id+"','"+Config.service_code+"','Mo','"+this.gateway_msg_id+"','"+this.src_terminal_id+"','"+this.registered_delivery+"','"+this.source_name+"','"+this.msg_type+"','"+Time.getDateString()+" "+Time.getTimeString()+"',"+Content.pk_t+","+Content.pk_n+",'"+Time.createTime()+"','"+Config.service_id+"')"; Config.sql_queue.push(sql); } */ result=false; System.out.println("mo error 11"); } if(this.thirdGatewayName==null && this.thirdNum != 0 && rsBool){ submitStr="<cmpp_submit><source><name>1</name><guid>0</guid></source><destination><name>"+this.source_name+"</name></destination><src_terminal_id>"+Config.service_code+"</src_terminal_id><dest_terminal_id>"+this.src_terminal_id+"</dest_terminal_id><msg_fmt>15</msg_fmt><tp_pid>0</tp_pid><tp_udhi>0</tp_udhi><registered_delivery>0</registered_delivery><service_id></service_id><fee_user_type>0</fee_user_type><fee_type>01</fee_type><fee_code>000000</fee_code><msg_content>"+utilities.Utility.toHexString(Config.error)+"</msg_content></cmpp_submit>\r\n"; Config.submit_queue.push(submitStr); sql="insert into mobile_bill (row_id,msg_content,dest_terminal_id,bill_type,gateway_msg_id,src_terminal_id,registered_delivery,gateway_route,msg_type,create_date,pk_total,pk_number,create_time,service_id)values('"+(++Config.id)+"','"+this.msg_id+"','"+Config.service_code+"','Mo','"+this.gateway_msg_id+"','"+this.src_terminal_id+"','"+this.registered_delivery+"','"+this.source_name+"','"+this.msg_type+"','"+Time.getDateString()+" "+Time.getTimeString()+"',"+Content.pk_t+","+Content.pk_n+",'"+Time.createTime()+"','"+Config.service_id+"')"; Config.sql_queue.push(sql); result=false; System.out.println("mo error"); } if(rsBool&&msg_idRight){//点播正确的内容 try{ while(rs.next()){ this.msg_type=rs.getInt("msg_type"); //otherContent.getParameter(this.wwwGateway ,Content.msg_fmt);//www //System.out.println(source_name+"source _ name"+Content.msg_fmt+"msg_type"+"||msg_fmt"+otherContent.msg_fmt); Content.msg_content =rs.getString("msg_content"); Content.pk_t=rs.getInt("pk_total"); Content.pk_n =rs.getInt("pk_number"); //如果是www型定单 if(this.bill_type.equals("ww")){ //回写mobile_www_order的Sql语句****************************有错误!!!!!重发 otherContent.getParameter(this.wwwGateway ,this.msg_type);//www //要根据guid判断是否发送成功! //submitStr="<cmpp_submit><source><name></name><guid>"+(++id)+"</guid></source><destination><name>"+this.source_name+"</name></destination><src_terminal_id>"+Config.service_code+"</src_terminal_id><dest_terminal_id>"+this.src_terminal_id+"</dest_terminal_id><msg_fmt>"+Content.msg_fmt+"</msg_fmt><tp_pid>0</tp_pid><tp_udhi>0</tp_udhi><registered_delivery>"+this.registered_delivery+"</registered_delivery><service_id>DJSD</service_id><fee_user_type>0</fee_user_type><fee_type>02</fee_type><fee_code>000010</fee_code><msg_content>"+Content.msg_content+"</msg_content></cmpp_submit>\r\n"; submitStr="<cmpp_submit><source><name>1</name><guid>"+(++Config.id)+"</guid></source><destination><name>"+this.wwwGateway+"</name></destination><src_terminal_id>"+Config.service_code+"</src_terminal_id><dest_terminal_id>"+this.dest_number+"</dest_terminal_id><msg_fmt>"+otherContent.msg_fmt+"</msg_fmt><tp_pid>"+otherContent.tp_pid+"</tp_pid><tp_udhi>"+otherContent.tp_udhi+"</tp_udhi><registered_delivery>"+Fee.registered_delivery+"</registered_delivery><service_id>"+Fee.service_id+"</service_id><fee_terminal_id></fee_terminal_id><fee_user_type>"+Fee.fee_user_type+"</fee_user_type><fee_type>"+Fee.fee_type+"</fee_type><fee_code>"+Fee.fee_code+"</fee_code><msg_content>"+Content.msg_content+"</msg_content></cmpp_submit>\r\n"; Config.submit_queue.push(submitStr); billContent.msg_content=Content.msg_content; //生成写mobile_content表的sql语句MT**不要收条 sql="insert into mobile_bill (row_id,msg_content,dest_terminal_id,bill_type,registered_delivery,gateway_route,src_terminal_id,msg_type,create_date,fee_user_type,fee_type,fee_code,pk_total,pk_number,service_id,agent_flag,given_value,create_time,msg_fmt,tp_pid,tp_udhi)values('"+(Config.id)+"','"+billContent.msg_content+"','"+this.wwwDestNumber+"','"+this.bill_type+"','"+"0"+"','"+this.wwwGateway+"','"+this.wwwSrcNumber+"',"+this.msg_type+",'"+Time.getDateString()+" "+Time.getTimeString()+"',"+Fee.fee_user_type+","+Fee.fee_type+",'"+Fee.fee_code+"',"+Content.pk_t+","+Content.pk_n+",'"+Fee.service_id+"',"+Fee.agent_flag+",'"+Fee.given_value+"',"+utilities.Utility.createTime()+","+otherContent.msg_fmt+","+otherContent.tp_pid+","+otherContent.tp_udhi+")"; Config.sql_queue.push(sql); } else if(this.thirdGatewayName==null && this.thirdNum == 0){ /*自己给自己点播*/ otherContent.getParameter(this.source_name,this.msg_type);//www /* if(Fee.fee_user_type == 3){ Fee.fee_terminal_id=this.src_terminal_id; } else{ Fee.fee_terminal_id=null; } */ //要根据guid判断是否发送成功! //submitStr="<cmpp_submit><source><name></name><guid>"+(++id)+"</guid></source><destination><name>"+this.source_name+"</name></destination><src_terminal_id>"+Config.service_code+"</src_terminal_id><dest_terminal_id>"+this.src_terminal_id+"</dest_terminal_id><msg_fmt>"+Content.msg_fmt+"</msg_fmt><tp_pid>0</tp_pid><tp_udhi>0</tp_udhi><registered_delivery>"+this.registered_delivery+"</registered_delivery><service_id>DJSD</service_id><fee_user_type>0</fee_user_type><fee_type>02</fee_type><fee_code>000010</fee_code><msg_content>"+Content.msg_content+"</msg_content></cmpp_submit>\r\n"; //submitStr="<cmpp_submit><source><name>1</name><guid>"+(++Config.id)+"</guid></source><destination><name>"+this.source_name+"</name></destination><src_terminal_id>"+Config.service_code+"</src_terminal_id><dest_terminal_id>"+this.src_terminal_id+"</dest_terminal_id><msg_fmt>"+Content.msg_fmt+"</msg_fmt><tp_pid>"+otherContent.tp_pid+"</tp_pid><tp_udhi>"+otherContent.tp_udhi+"</tp_udhi><registered_delivery>"+this.registered_delivery+"</registered_delivery><service_id>"+Fee.service_id+"</service_id><fee_user_type>"+Fee.fee_user_type+"</fee_user_type><fee_terminal_id></fee_terminal_id><fee_type>"+Fee.fee_type+"</fee_type><fee_code>"+Fee.fee_code+"</fee_code><msg_content>"+Content.msg_content+"</msg_content></cmpp_submit>\r\n"; /* 对3受费*/ submitStr="<cmpp_submit><source><name>1</name><guid>"+(++Config.id)+"</guid></source><destination><name>"+this.source_name+"</name></destination><src_terminal_id>"+Config.service_code+"</src_terminal_id><dest_terminal_id>"+this.src_terminal_id+"</dest_terminal_id><msg_fmt>"+Content.msg_fmt+"</msg_fmt><tp_pid>"+otherContent.tp_pid+"</tp_pid><tp_udhi>"+otherContent.tp_udhi+"</tp_udhi><registered_delivery>"+this.registered_delivery+"</registered_delivery><service_id>"+Fee.service_id+"</service_id><fee_user_type>3</fee_user_type><fee_terminal_id>"+this.src_terminal_id+"</fee_terminal_id><fee_type>"+Fee.fee_type+"</fee_type><fee_code>"+Fee.fee_code+"</fee_code><msg_content>"+Content.msg_content+"</msg_content></cmpp_submit>\r\n"; Config.submit_queue.push(submitStr); billContent.msg_content=Content.msg_content; //billContent.dest_terminal_id ="13123123123"; //生成写mobile_content表的sql语句MT /* 对3端受费*/ sql="insert into mobile_bill (row_id,msg_content,dest_terminal_id,bill_type,registered_delivery,gateway_route,src_terminal_id,msg_type,create_date,fee_user_type,fee_type,fee_code,service_id,pk_total,pk_number,create_time,agent_flag,given_value,msg_fmt,tp_pid,tp_udhi,fee_terminal_id)values('"+(Config.id)+"','"+billContent.msg_content+"','"+this.src_terminal_id+"','"+this.bill_type+"','"+this.Fee.registered_delivery+"','"+this.source_name+"','"+Config.service_code+"',"+this.msg_type+",'"+Time.getDateString()+" "+Time.getTimeString()+"',"+3+","+Fee.fee_type+",'"+Fee.fee_code+"','"+Fee.service_id+"',"+Content.pk_t+","+Content.pk_n+","+Time.createTime()+","+Fee.agent_flag+",'"+Fee.given_value+"',"+otherContent.msg_fmt+","+otherContent.tp_pid+","+otherContent.tp_udhi+",'"+this.src_terminal_id+"')"; Config.sql_queue.push(sql); billContent.msg_content=Content.msg_content; //生成写mobile_content表的sql语句MO sql="insert into mobile_bill (row_id,msg_content,dest_terminal_id,bill_type,gateway_msg_id,src_terminal_id,registered_delivery,gateway_route,msg_type,create_date,pk_total,pk_number,create_time)values('"+(++Config.id)+"','"+this.msg_id+"','"+Config.service_code+"','Mo','"+this.gateway_msg_id+"','"+this.src_terminal_id+"','"+this.registered_delivery+"','"+this.source_name+"','"+this.msg_type+"','"+Time.getDateString()+" "+Time.getTimeString()+"',"+Content.pk_t+","+Content.pk_n+",'"+Time.createTime()+"')"; Config.sql_queue.push(sql); }else if(thirdGatewayName!=null){ /*自己给beiren点播*/ otherContent.getParameter(this.source_name,this.msg_type);//www /* if(Fee.fee_user_type == 3){ Fee.fee_terminal_id=this.src_terminal_id; } else{ Fee.fee_terminal_id=null; } */ //要根据guid判断是否发送成功! //submitStr="<cmpp_submit><source><name></name><guid>"+(++id)+"</guid></source><destination><name>"+this.source_name+"</name></destination><src_terminal_id>"+Config.service_code+"</src_terminal_id><dest_terminal_id>"+this.src_terminal_id+"</dest_terminal_id><msg_fmt>"+Content.msg_fmt+"</msg_fmt><tp_pid>0</tp_pid><tp_udhi>0</tp_udhi><registered_delivery>"+this.registered_delivery+"</registered_delivery><service_id>DJSD</service_id><fee_user_type>0</fee_user_type><fee_type>02</fee_type><fee_code>000010</fee_code><msg_content>"+Content.msg_content+"</msg_content></cmpp_submit>\r\n"; //submitStr="<cmpp_submit><source><name>1</name><guid>"+(++Config.id)+"</guid></source><destination><name>"+this.source_name+"</name></destination><src_terminal_id>"+Config.service_code+"</src_terminal_id><dest_terminal_id>"+this.src_terminal_id+"</dest_terminal_id><msg_fmt>"+Content.msg_fmt+"</msg_fmt><tp_pid>"+otherContent.tp_pid+"</tp_pid><tp_udhi>"+otherContent.tp_udhi+"</tp_udhi><registered_delivery>"+this.registered_delivery+"</registered_delivery><service_id>"+Fee.service_id+"</service_id><fee_user_type>"+Fee.fee_user_type+"</fee_user_type><fee_terminal_id></fee_terminal_id><fee_type>"+Fee.fee_type+"</fee_type><fee_code>"+Fee.fee_code+"</fee_code><msg_content>"+Content.msg_content+"</msg_content></cmpp_submit>\r\n"; /* 对3端受费*/ submitStr="<cmpp_submit><source><name>1</name><guid>"+(++Config.id)+"</guid></source><destination><name>"+this.thirdGatewayName+"</name></destination><src_terminal_id>"+Config.service_code+"</src_terminal_id><dest_terminal_id>"+this.thirdNum+"</dest_terminal_id><msg_fmt>"+Content.msg_fmt+"</msg_fmt><tp_pid>"+otherContent.tp_pid+"</tp_pid><tp_udhi>"+otherContent.tp_udhi+"</tp_udhi><registered_delivery>"+this.registered_delivery+"</registered_delivery><service_id>"+Fee.service_id+"</service_id><fee_user_type>3</fee_user_type><fee_terminal_id>"+this.src_terminal_id+"</fee_terminal_id><fee_type>"+Fee.fee_type+"</fee_type><fee_code>"+Fee.fee_code+"</fee_code><msg_content>"+Content.msg_content+"</msg_content></cmpp_submit>\r\n"; Config.submit_queue.push(submitStr); billContent.msg_content=Content.msg_content; //billContent.dest_terminal_id ="13123123123"; //生成写mobile_content表的sql语句MT /* 对3端受费*/ sql="insert into mobile_bill (row_id,msg_content,dest_terminal_id,bill_type,registered_delivery,gateway_route,src_terminal_id,msg_type,create_date,fee_user_type,fee_type,fee_code,service_id,pk_total,pk_number,create_time,agent_flag,given_value,msg_fmt,tp_pid,tp_udhi,fee_terminal_id)values('"+(Config.id)+"','"+billContent.msg_content+"','"+this.thirdNum+"','"+this.bill_type+"','"+this.Fee.registered_delivery+"','"+this.thirdGatewayName+"','"+Config.service_code+"',"+this.msg_type+",'"+Time.getDateString()+" "+Time.getTimeString()+"',"+3+","+Fee.fee_type+",'"+Fee.fee_code+"','"+Fee.service_id+"',"+Content.pk_t+","+Content.pk_n+","+Time.createTime()+","+Fee.agent_flag+",'"+Fee.given_value+"',"+otherContent.msg_fmt+","+otherContent.tp_pid+","+otherContent.tp_udhi+",'"+this.src_terminal_id+"')"; Config.sql_queue.push(sql); billContent.msg_content=Content.msg_content; //生成写mobile_content表的sql语句MO sql="insert into mobile_bill (row_id,msg_content,dest_terminal_id,bill_type,gateway_msg_id,src_terminal_id,registered_delivery,gateway_route,msg_type,create_date,pk_total,pk_number,create_time)values('"+(++Config.id)+"','"+this.msg_id+"','"+Config.service_code+"','Mo','"+this.gateway_msg_id+"','"+this.src_terminal_id+"','"+this.registered_delivery+"','"+this.source_name+"','"+this.msg_type+"','"+Time.getDateString()+" "+Time.getTimeString()+"',"+Content.pk_t+","+Content.pk_n+",'"+Time.createTime()+"')"; Config.sql_queue.push(sql); } } rs.close(); rs=null; //database.release() ; //database=null; result=true; } catch(Exception e){ e.printStackTrace(); } } return result; }}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -