1
0

first commit

This commit is contained in:
2020-08-06 14:58:51 +08:00
commit 17096657dc
780 changed files with 92857 additions and 0 deletions

View File

@@ -0,0 +1,76 @@
<?php
// +------------------------------------------------+
// |http://www.cjango.com |
// +------------------------------------------------+
// | 修复BUG不是一朝一夕的事情等我喝醉了再说吧 |
// +------------------------------------------------+
// | Author: 小陈叔叔 <Jason.Chen> |
// +------------------------------------------------+
namespace app\mobile\controller;
use app\common\model\MemberInfo as MemberInfoModel;
use app\common\service\Member as MemberService;
use app\common\service\Message as MessageService;
class Qrcode extends Center
{
public function index()
{
if (UID == $this->shareUser['uid']) {
$this->info = $this->user->info;
} else {
$this->info = $this->shareUser;
$user = MemberInfoModel::where('uid', $this->shareUser['uid'])->find();
$user->setInc('click');
}
return $this->fetch();
}
/**
* 留言
* @param string $uid [description]
* @return [type] [description]
*/
public function comment($uid = '')
{
if (IS_POST) {
$data = $this->request->post();
$res = MessageService::send($data, UID);
return $this->back($res);
} else {
$this->list = MessageService::getList($uid);
return $this->fetch();
}
}
// 点赞
public function tags($uid)
{
$res = MessageService::tags($uid);
if ($res === true) {
return $this->success();
} else {
return $this->error($res);
}
}
// 写签名
public function signature()
{
$signature = $this->request->post('signature');
$res = MemberService::editInfo(UID, ['signature' => $signature], 'signature');
if ($res === true) {
return $this->success('添加成功');
} else {
return $this->error($res);
}
}
//删除
public function del($id)
{
$res = MessageService::del($id);
return $this->back($res);
}
}