12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364 |
- <?php
- namespace App\Http\Controllers\Channel\Behavior;
- use App\Http\Controllers\Channel\BaseController;
- use App\Modules\Channel\Models\Behavior;
- use Illuminate\Http\Request;
- use Illuminate\Routing\Controller;
- class BehaviorController extends BaseController {
-
-
- public function userBehaviorUpload(Request $request) {
- if(!$request->has('action')){
- return response()->error('PARAM_EMPTY');
- }
- $action = $request->input('action');
- $hay_stack = ['manual','bookRecom','noticePromote',
- 'withdraw','notice', 'query', 'sumData','promotionNovel',
- 'rankNovel','pagePromote','businessPromote','smartPush',
- 'templateMsg','clientMsg','picArtElem','miniProgram','keywordRe',
- 'promoteStats','pushStats','rechargeRecord','balanceCenter',
- 'serviceAccountSet','ClientSet','siteList'];
- if(!in_array($action,$hay_stack)){
- return response()->error('PARAM_ERROR');
- }
- $data = array(
- 'uid'=>$this->getChannelUserId(),
- 'action' =>$action,
- );
- Behavior::create($data);
- return response()->success();
- }
- }
|