|
...
|
...
|
@@ -65,9 +65,11 @@ class GeoWritingsLogic extends BaseLogic |
|
|
|
$this->param['status'] = GeoWritings::STATUS_INIT;
|
|
|
|
if(isset($this->param['id']) &&!empty($this->param['id'])){
|
|
|
|
$id = $this->param['id'];
|
|
|
|
$this->param['content_length'] = strlen($this->param['content'] ?? '');
|
|
|
|
$this->model->edit($this->param,['id'=>$id]);
|
|
|
|
}else{
|
|
|
|
$this->param['type'] = GeoWritings::TYPE_SUBMIT;
|
|
|
|
$this->param['content_length'] = strlen($this->param['content'] ?? '');
|
|
|
|
$this->param['uniqid'] = uniqid().$this->param['project_id'];
|
|
|
|
$id = $this->model->addReturnId($this->param);
|
|
|
|
}
|
|
...
|
...
|
@@ -102,7 +104,7 @@ class GeoWritingsLogic extends BaseLogic |
|
|
|
*/
|
|
|
|
public function sendWechatMessage()
|
|
|
|
{
|
|
|
|
$wechat = $this->param['wechat'] ?? true;
|
|
|
|
$wechat = $this->param['wechat'] ?? 1;
|
|
|
|
$this->model->edit(['status'=>2],['status'=>1,'project_id'=>$this->param['project_id']]);
|
|
|
|
$data = GeoWritings::sendConfirmMessage($this->param['project_id'],$wechat);
|
|
|
|
if($data === false){
|
...
|
...
|
|