wupengfei 2 years ago
parent
commit
d848722fd9
2 changed files with 5 additions and 1 deletions
  1. 2 1
      .idea/workspace.xml
  2. 3 0
      application/nutrition/controller/VideoManage.php

+ 2 - 1
.idea/workspace.xml

@@ -3,6 +3,7 @@
   <component name="ChangeListManager">
     <list default="true" id="1a36929e-c054-4875-a943-593a74e55fa4" name="Default Changelist" comment="">
       <change beforePath="$PROJECT_DIR$/.idea/workspace.xml" beforeDir="false" afterPath="$PROJECT_DIR$/.idea/workspace.xml" afterDir="false" />
+      <change beforePath="$PROJECT_DIR$/application/nutrition/controller/VideoManage.php" beforeDir="false" afterPath="$PROJECT_DIR$/application/nutrition/controller/VideoManage.php" afterDir="false" />
     </list>
     <option name="SHOW_DIALOG" value="false" />
     <option name="HIGHLIGHT_CONFLICTS" value="true" />
@@ -189,7 +190,7 @@
       <workItem from="1669429338320" duration="861000" />
       <workItem from="1669448616248" duration="5065000" />
       <workItem from="1669597148644" duration="17061000" />
-      <workItem from="1669682447842" duration="4543000" />
+      <workItem from="1669682447842" duration="4804000" />
     </task>
     <servers />
   </component>

+ 3 - 0
application/nutrition/controller/VideoManage.php

@@ -209,6 +209,7 @@ class VideoManage extends Controller
                 }else{
                     $user_id= '';
                 }
+                $vid_info = getVideoTime(input('post.ali_vid'));
                 Data::save('VideoUrl',['video_id'=>$result,
                     'url'=> $url,
                     'cover'=>input('post.cover'),
@@ -226,6 +227,8 @@ class VideoManage extends Controller
                     'desc'=>input('post.desc'),
                     'read_num'=>input('post.read_num'),
                     'ali_vid'=>input('post.ali_vid'),
+                    'duration'=>$vid_info['duration'],
+                    'duration_str'=> $vid_info['duration_str'],
                 ],'video_id',['video_id'=>$result]);
                 $up = [];
                 $up['video_url'] = $url;