diff --git a/service/Application/Admin/Controller/AlipayLifeMessageController.class.php b/service/Application/Admin/Controller/AlipayLifeMessageController.class.php
index e3d185848..b98100fdd 100644
--- a/service/Application/Admin/Controller/AlipayLifeMessageController.class.php
+++ b/service/Application/Admin/Controller/AlipayLifeMessageController.class.php
@@ -175,18 +175,23 @@ class AlipayLifeMessageController extends CommonController
$this->assign('alipay_life_message_type_list', L('alipay_life_message_type_list'));
// 单用户发消息用户信息
- $user = empty($_GET['user_id']) ? '' : M('User')->find(intval(I('user_id')));
- $this->assign('user', $user);
+ $alipay_openid = empty($_GET['user_id']) ? '' : M('User')->where(['id'=>intval(I('user_id'))])->getField('alipay_openid');
+ $this->assign('alipay_openid', $alipay_openid);
// 消息发送类型
$this->assign('alipay_life_message_send_type_list', L('alipay_life_message_send_type_list'));
- $this->assign('send_type', empty($user) ? 1 : 0);
+ $this->assign('send_type', empty($alipay_openid) ? 1 : 0);
- // 生活号消息分类
- $alipay_life_list = M('AlipayLife')->field('id,name')->select();
+ // 生活号
+ $where = [];
+ if(!empty($_GET['alipay_life_id']))
+ {
+ $where['id'] = intval(I('alipay_life_id'));
+ }
+ $alipay_life_list = M('AlipayLife')->field('id,name')->where($where)->select();
$this->assign('alipay_life_list', $alipay_life_list);
- // 生活号消息分类
+ // 生活号分类
$alipay_life_category = M('AlipayLifeCategory')->where(['is_enable'=>1])->field('id,name')->select();
$this->assign('alipay_life_category', $alipay_life_category);
diff --git a/service/Application/Admin/Lang/zh-cn/alipaylife.php b/service/Application/Admin/Lang/zh-cn/alipaylife.php
index 83f7752f9..59a802ce6 100755
--- a/service/Application/Admin/Lang/zh-cn/alipaylife.php
+++ b/service/Application/Admin/Lang/zh-cn/alipaylife.php
@@ -35,5 +35,7 @@ return array(
'alipay_life_is_shelves_text' => '上下架',
'alipay_life_save_category_error' => '分类添加失败',
+
+ 'alipay_life_user_send_text' => '发消息',
);
?>
\ No newline at end of file
diff --git a/service/Application/Admin/Lang/zh-cn/alipaylifemessage.php b/service/Application/Admin/Lang/zh-cn/alipaylifemessage.php
index 2697a9e60..680368c6f 100755
--- a/service/Application/Admin/Lang/zh-cn/alipaylifemessage.php
+++ b/service/Application/Admin/Lang/zh-cn/alipaylifemessage.php
@@ -9,7 +9,7 @@
*/
return array(
// 添加/编辑
- 'alipay_life_message_add_name' => '生活号消息添加',
+ 'alipay_life_message_add_name' => '生活号消息创建',
'alipay_life_message_life_text' => '生活号',
'alipay_life_message_life_format' => '请选择生活号',
@@ -46,5 +46,7 @@ return array(
0 => array('value' => 0, 'name' => '单条'),
1 => array('value' => 1, 'name' => '批量'),
),
+
+ 'alipay_life_message_user_text' => '给用户发送消息',
);
?>
\ No newline at end of file
diff --git a/service/Application/Admin/View/Default/AlipayLife/Index.html b/service/Application/Admin/View/Default/AlipayLife/Index.html
index c30cdfa58..d695d82a3 100755
--- a/service/Application/Admin/View/Default/AlipayLife/Index.html
+++ b/service/Application/Admin/View/Default/AlipayLife/Index.html
@@ -82,6 +82,10 @@