|
|
@ -5,7 +5,7 @@ class WechatService
|
|
|
|
data = {
|
|
|
|
data = {
|
|
|
|
touser:openid,
|
|
|
|
touser:openid,
|
|
|
|
template_id:template_id,
|
|
|
|
template_id:template_id,
|
|
|
|
url:"https://open.weixin.qq.com/connect/oauth2/authorize?appid=wxc09454f171153c2d&redirect_uri=https://www.trustie.net/assets/wechat/app.html#/#{type}/#{id}?response_type=code&scope=snsapi_base&state=123#wechat_redirect",
|
|
|
|
url:"https://open.weixin.qq.com/connect/oauth2/authorize?appid=wx8e1ab05163a28e37&redirect_uri=https://www.trustie.net/assets/wechat/app.html#/#{type}/#{id}?response_type=code&scope=snsapi_base&state=123#wechat_redirect",
|
|
|
|
topcolor:"#FF0000",
|
|
|
|
topcolor:"#FF0000",
|
|
|
|
data:{
|
|
|
|
data:{
|
|
|
|
first: {
|
|
|
|
first: {
|
|
|
@ -44,7 +44,7 @@ class WechatService
|
|
|
|
end
|
|
|
|
end
|
|
|
|
Rails.logger.info "send over. #{req}"
|
|
|
|
Rails.logger.info "send over. #{req}"
|
|
|
|
end
|
|
|
|
end
|
|
|
|
Rails.logger.info "https://open.weixin.qq.com/connect/oauth2/authorize?appid=wxc09454f171153c2d&redirect_uri=https://www.trustie.net/assets/wechat/app.html#/#{type}/#{id}?response_type=code&scope=snsapi_base&state=123#wechat_redirect"
|
|
|
|
Rails.logger.info "https://open.weixin.qq.com/connect/oauth2/authorize?appid=wx8e1ab05163a28e37&redirect_uri=https://www.trustie.net/assets/wechat/app.html#/#{type}/#{id}?response_type=code&scope=snsapi_base&state=123#wechat_redirect"
|
|
|
|
end
|
|
|
|
end
|
|
|
|
|
|
|
|
|
|
|
|
def topic_publish_template(user_id, type, id, first, key1, key2, key3, remark="")
|
|
|
|
def topic_publish_template(user_id, type, id, first, key1, key2, key3, remark="")
|
|
|
@ -59,7 +59,7 @@ class WechatService
|
|
|
|
end
|
|
|
|
end
|
|
|
|
Rails.logger.info "send over. #{req}"
|
|
|
|
Rails.logger.info "send over. #{req}"
|
|
|
|
end
|
|
|
|
end
|
|
|
|
Rails.logger.info "https://open.weixin.qq.com/connect/oauth2/authorize?appid=wxc09454f171153c2d&redirect_uri=https://www.trustie.net/assets/wechat/app.html#/#{type}/#{id}?response_type=code&scope=snsapi_base&state=123#wechat_redirect"
|
|
|
|
Rails.logger.info "https://open.weixin.qq.com/connect/oauth2/authorize?appid=wx8e1ab05163a28e37&redirect_uri=https://www.trustie.net/assets/wechat/app.html#/#{type}/#{id}?response_type=code&scope=snsapi_base&state=123#wechat_redirect"
|
|
|
|
end
|
|
|
|
end
|
|
|
|
|
|
|
|
|
|
|
|
def comment_template(user_id,type, id, first, key1, key2, key3, remark="")
|
|
|
|
def comment_template(user_id,type, id, first, key1, key2, key3, remark="")
|
|
|
@ -74,7 +74,7 @@ class WechatService
|
|
|
|
end
|
|
|
|
end
|
|
|
|
Rails.logger.info "send over. #{req}"
|
|
|
|
Rails.logger.info "send over. #{req}"
|
|
|
|
end
|
|
|
|
end
|
|
|
|
Rails.logger.info "https://open.weixin.qq.com/connect/oauth2/authorize?appid=wxc09454f171153c2d&redirect_uri=https://www.trustie.net/assets/wechat/app.html#/#{type}/#{id}?response_type=code&scope=snsapi_base&state=123#wechat_redirect"
|
|
|
|
Rails.logger.info "https://open.weixin.qq.com/connect/oauth2/authorize?appid=wx8e1ab05163a28e37&redirect_uri=https://www.trustie.net/assets/wechat/app.html#/#{type}/#{id}?response_type=code&scope=snsapi_base&state=123#wechat_redirect"
|
|
|
|
end
|
|
|
|
end
|
|
|
|
|
|
|
|
|
|
|
|
def message_update_template(user_id, type, id, first, key1, key2, remark="")
|
|
|
|
def message_update_template(user_id, type, id, first, key1, key2, remark="")
|
|
|
@ -83,7 +83,7 @@ class WechatService
|
|
|
|
data = {
|
|
|
|
data = {
|
|
|
|
touser:uw.openid,
|
|
|
|
touser:uw.openid,
|
|
|
|
template_id:"YTyNPZnQD8uZFBFq-Q6cCOWaq5LA9vL6RFlF2JuD5Cg",
|
|
|
|
template_id:"YTyNPZnQD8uZFBFq-Q6cCOWaq5LA9vL6RFlF2JuD5Cg",
|
|
|
|
url:"https://open.weixin.qq.com/connect/oauth2/authorize?appid=wxc09454f171153c2d&redirect_uri=https://www.trustie.net/assets/wechat/app.html#/#{type}/#{id}?response_type=code&scope=snsapi_base&state=123#wechat_redirect",
|
|
|
|
url:"https://open.weixin.qq.com/connect/oauth2/authorize?appid=wx8e1ab05163a28e37&redirect_uri=https://www.trustie.net/assets/wechat/app.html#/#{type}/#{id}?response_type=code&scope=snsapi_base&state=123#wechat_redirect",
|
|
|
|
topcolor:"#FF0000",
|
|
|
|
topcolor:"#FF0000",
|
|
|
|
data:{
|
|
|
|
data:{
|
|
|
|
first: {
|
|
|
|
first: {
|
|
|
@ -112,6 +112,6 @@ class WechatService
|
|
|
|
end
|
|
|
|
end
|
|
|
|
Rails.logger.info "send over. #{req}"
|
|
|
|
Rails.logger.info "send over. #{req}"
|
|
|
|
end
|
|
|
|
end
|
|
|
|
Rails.logger.info "https://open.weixin.qq.com/connect/oauth2/authorize?appid=wxc09454f171153c2d&redirect_uri=https://www.trustie.net/assets/wechat/app.html#/#{type}/#{id}?response_type=code&scope=snsapi_base&state=123#wechat_redirect"
|
|
|
|
Rails.logger.info "https://open.weixin.qq.com/connect/oauth2/authorize?appid=wx8e1ab05163a28e37&redirect_uri=https://www.trustie.net/assets/wechat/app.html#/#{type}/#{id}?response_type=code&scope=snsapi_base&state=123#wechat_redirect"
|
|
|
|
end
|
|
|
|
end
|
|
|
|
end
|
|
|
|
end
|