作者 郭盛
1 个管道 的构建 通过 耗费 3 秒

修改后台价格

... ... @@ -2,9 +2,15 @@
<project version="4">
<component name="ChangeListManager">
<list default="true" id="e93f11c2-a7d9-4d35-8b1c-8dd18e7f5fef" name="Default" comment="">
<change type="DELETED" beforePath="$PROJECT_DIR$/application/api/controller/Demo.php" afterPath="" />
<change type="DELETED" beforePath="$PROJECT_DIR$/application/api/controller/Index.php" afterPath="" />
<change type="MODIFICATION" beforePath="$PROJECT_DIR$/.idea/workspace.xml" afterPath="$PROJECT_DIR$/.idea/workspace.xml" />
<change type="MODIFICATION" beforePath="$PROJECT_DIR$/application/admin/lang/zh-cn/video.php" afterPath="$PROJECT_DIR$/application/admin/lang/zh-cn/video.php" />
<change type="MODIFICATION" beforePath="$PROJECT_DIR$/application/admin/view/video/add.html" afterPath="$PROJECT_DIR$/application/admin/view/video/add.html" />
<change type="MODIFICATION" beforePath="$PROJECT_DIR$/application/admin/view/video/edit.html" afterPath="$PROJECT_DIR$/application/admin/view/video/edit.html" />
<change type="MODIFICATION" beforePath="$PROJECT_DIR$/application/api/controller/User.php" afterPath="$PROJECT_DIR$/application/api/controller/User.php" />
<change type="MODIFICATION" beforePath="$PROJECT_DIR$/public/api.html" afterPath="$PROJECT_DIR$/public/api.html" />
<change type="MODIFICATION" beforePath="$PROJECT_DIR$/public/assets/js/backend/video.js" afterPath="$PROJECT_DIR$/public/assets/js/backend/video.js" />
</list>
<option name="EXCLUDED_CONVERTED_TO_IGNORED" value="true" />
<option name="TRACKING_ENABLED" value="true" />
... ... @@ -15,28 +21,52 @@
</component>
<component name="FileEditorManager">
<leaf SIDE_TABS_SIZE_LIMIT_KEY="300">
<file leaf-file-name="User.php" pinned="false" current-in-tab="true">
<entry file="file://$PROJECT_DIR$/application/api/controller/User.php">
<file leaf-file-name="Video.php" pinned="false" current-in-tab="false">
<entry file="file://$PROJECT_DIR$/application/admin/controller/Video.php">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="327">
<caret line="197" column="33" lean-forward="false" selection-start-line="197" selection-start-column="33" selection-end-line="197" selection-end-column="33" />
<folding>
<element signature="e#38#68#0#PHP" expanded="true" />
<element signature="e#337#456#0#PHP" expanded="false" />
<element signature="e#462#1200#0#PHP" expanded="false" />
<element signature="e#1205#2868#0#PHP" expanded="false" />
<element signature="e#2874#3402#0#PHP" expanded="false" />
<element signature="e#3407#4178#0#PHP" expanded="false" />
<element signature="e#4184#4591#0#PHP" expanded="false" />
<element signature="e#4596#4939#0#PHP" expanded="false" />
<element signature="e#4945#5597#0#PHP" expanded="false" />
<element signature="e#7551#8000#0#PHP" expanded="false" />
<element signature="e#8005#8888#0#PHP" expanded="false" />
<element signature="e#8894#9578#0#PHP" expanded="false" />
<element signature="e#9583#11079#0#PHP" expanded="false" />
<element signature="e#11085#11462#0#PHP" expanded="false" />
<element signature="e#11467#11731#0#PHP" expanded="false" />
</folding>
<state relative-caret-position="1464">
<caret line="169" column="0" lean-forward="true" selection-start-line="169" selection-start-column="0" selection-end-line="169" selection-end-column="0" />
<folding />
</state>
</provider>
</entry>
</file>
<file leaf-file-name="video.php" pinned="false" current-in-tab="true">
<entry file="file://$PROJECT_DIR$/application/admin/lang/zh-cn/video.php">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="325">
<caret line="13" column="24" lean-forward="false" selection-start-line="13" selection-start-column="24" selection-end-line="13" selection-end-column="24" />
<folding />
</state>
</provider>
</entry>
</file>
<file leaf-file-name="video.js" pinned="false" current-in-tab="false">
<entry file="file://$PROJECT_DIR$/public/assets/js/backend/video.js">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="50">
<caret line="23" column="26" lean-forward="true" selection-start-line="23" selection-start-column="26" selection-end-line="23" selection-end-column="26" />
<folding />
</state>
</provider>
</entry>
</file>
<file leaf-file-name="add.html" pinned="false" current-in-tab="false">
<entry file="file://$PROJECT_DIR$/application/admin/view/video/add.html">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="51">
<caret line="90" column="4" lean-forward="false" selection-start-line="90" selection-start-column="4" selection-end-line="113" selection-end-column="10" />
<folding />
</state>
</provider>
</entry>
</file>
<file leaf-file-name="edit.html" pinned="false" current-in-tab="false">
<entry file="file://$PROJECT_DIR$/application/admin/view/video/edit.html">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="326">
<caret line="104" column="40" lean-forward="true" selection-start-line="104" selection-start-column="40" selection-end-line="104" selection-end-column="40" />
<folding />
</state>
</provider>
</entry>
... ... @@ -73,10 +103,6 @@
<option value="$PROJECT_DIR$/application/admin/model/Pic.php" />
<option value="$PROJECT_DIR$/application/admin/model/Type.php" />
<option value="$PROJECT_DIR$/application/admin/view/pic/index.html" />
<option value="$PROJECT_DIR$/application/admin/view/video/edit.html" />
<option value="$PROJECT_DIR$/application/admin/view/video/add.html" />
<option value="$PROJECT_DIR$/application/admin/lang/zh-cn/video.php" />
<option value="$PROJECT_DIR$/public/assets/js/backend/video.js" />
<option value="$PROJECT_DIR$/application/admin/controller/Pic.php" />
<option value="$PROJECT_DIR$/application/admin/controller/Video.php" />
<option value="$PROJECT_DIR$/application/index/controller/User.php" />
... ... @@ -92,6 +118,10 @@
<option value="$PROJECT_DIR$/application/admin/view/pic/add.html" />
<option value="$PROJECT_DIR$/application/admin/view/pic/edit.html" />
<option value="$PROJECT_DIR$/application/api/controller/User.php" />
<option value="$PROJECT_DIR$/public/assets/js/backend/video.js" />
<option value="$PROJECT_DIR$/application/admin/view/video/add.html" />
<option value="$PROJECT_DIR$/application/admin/view/video/edit.html" />
<option value="$PROJECT_DIR$/application/admin/lang/zh-cn/video.php" />
</list>
</option>
</component>
... ... @@ -109,11 +139,11 @@
<sorting>DEFINITION_ORDER</sorting>
</component>
<component name="PhpWorkspaceProjectConfiguration" backward_compatibility_performed="true" />
<component name="ProjectFrameBounds">
<option name="x" value="311" />
<option name="y" value="58" />
<option name="width" value="1589" />
<option name="height" value="939" />
<component name="ProjectFrameBounds" extendedState="7">
<option name="x" value="44" />
<option name="y" value="79" />
<option name="width" value="1560" />
<option name="height" value="948" />
</component>
<component name="ProjectView">
<navigator currentView="ProjectPane" proportions="" version="1">
... ... @@ -168,7 +198,7 @@
<item name="application" type="2a2b976b:PhpTreeStructureProvider$1" />
<item name="admin" type="2a2b976b:PhpTreeStructureProvider$1" />
<item name="view" type="2a2b976b:PhpTreeStructureProvider$1" />
<item name="pic" type="2a2b976b:PhpTreeStructureProvider$1" />
<item name="video" type="2a2b976b:PhpTreeStructureProvider$1" />
</path>
<path>
<item name="areial" type="b2602c69:ProjectViewProjectNode" />
... ... @@ -242,7 +272,7 @@
<workItem from="1574122453532" duration="15780000" />
<workItem from="1574141466352" duration="745000" />
<workItem from="1574143209694" duration="3660000" />
<workItem from="1574146994475" duration="12061000" />
<workItem from="1574146994475" duration="15295000" />
</task>
<task id="LOCAL-00001" summary="调试">
<created>1574145133364</created>
... ... @@ -255,7 +285,7 @@
<servers />
</component>
<component name="TimeTrackingManager">
<option name="totallyTimeSpent" value="60414000" />
<option name="totallyTimeSpent" value="63648000" />
</component>
<component name="TodoView">
<todo-panel id="selected-file">
... ... @@ -267,9 +297,10 @@
</todo-panel>
</component>
<component name="ToolWindowManager">
<frame x="311" y="58" width="1589" height="939" extended-state="0" />
<frame x="-8" y="-8" width="1936" height="1056" extended-state="7" />
<editor active="true" />
<layout>
<window_info id="Project" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="true" show_stripe_button="true" weight="0.18574232" sideWeight="0.5" order="1" side_tool="false" content_ui="combo" />
<window_info id="Project" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="true" show_stripe_button="true" weight="0.15138593" sideWeight="0.5" order="1" side_tool="false" content_ui="combo" />
<window_info id="TODO" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.32912987" sideWeight="0.5" order="9" side_tool="false" content_ui="tabs" />
<window_info id="Event Log" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="0" side_tool="true" content_ui="tabs" />
<window_info id="Database" active="false" anchor="right" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="0" side_tool="false" content_ui="tabs" />
... ... @@ -277,7 +308,7 @@
<window_info id="Version Control" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="1" side_tool="false" content_ui="tabs" />
<window_info id="Run" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="5" side_tool="false" content_ui="tabs" />
<window_info id="Structure" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.25" sideWeight="0.5" order="2" side_tool="false" content_ui="tabs" />
<window_info id="Terminal" active="true" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="true" show_stripe_button="true" weight="0.2319202" sideWeight="0.5" order="2" side_tool="false" content_ui="tabs" />
<window_info id="Terminal" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.1772784" sideWeight="0.5" order="2" side_tool="false" content_ui="tabs" />
<window_info id="Favorites" active="false" anchor="left" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.33" sideWeight="0.5" order="0" side_tool="true" content_ui="tabs" />
<window_info id="Debug" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.4" sideWeight="0.5" order="6" side_tool="false" content_ui="tabs" />
<window_info id="Cvs" active="false" anchor="bottom" auto_hide="false" internal_type="DOCKED" type="DOCKED" visible="false" show_stripe_button="true" weight="0.25" sideWeight="0.5" order="7" side_tool="false" content_ui="tabs" />
... ... @@ -324,13 +355,6 @@
<watches-manager />
</component>
<component name="editorHistoryManager">
<entry file="file://$PROJECT_DIR$/application/admin/view/type/index.html">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="325">
<caret line="13" column="0" lean-forward="true" selection-start-line="13" selection-start-column="0" selection-end-line="13" selection-end-column="0" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/application/admin/view/type/add.html">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="550">
... ... @@ -450,34 +474,6 @@
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/application/admin/view/video/add.html">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="675">
<caret line="89" column="10" lean-forward="false" selection-start-line="89" selection-start-column="10" selection-end-line="89" selection-end-column="10" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/application/admin/view/video/edit.html">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="600">
<caret line="89" column="10" lean-forward="false" selection-start-line="89" selection-start-column="10" selection-end-line="89" selection-end-column="10" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/application/admin/lang/zh-cn/video.php">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="325">
<caret line="13" column="28" lean-forward="false" selection-start-line="13" selection-start-column="28" selection-end-line="13" selection-end-column="28" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/public/assets/js/backend/video.js">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="325">
<caret line="13" column="17" lean-forward="true" selection-start-line="13" selection-start-column="17" selection-end-line="13" selection-end-column="17" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/application/common/controller/Backend.php">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="3867">
... ... @@ -485,13 +481,6 @@
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/application/admin/controller/Video.php">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="539">
<caret line="177" column="5" lean-forward="true" selection-start-line="177" selection-start-column="5" selection-end-line="177" selection-end-column="5" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/application/api/library/ExceptionHandle.php">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="-61">
... ... @@ -531,13 +520,6 @@
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/application/api/controller/Sms.php" />
<entry file="file://$PROJECT_DIR$/application/api/controller/Index.php">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="-11">
<caret line="0" column="0" lean-forward="false" selection-start-line="0" selection-start-column="0" selection-end-line="0" selection-end-column="0" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/application/api/controller/Token.php">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="175">
... ... @@ -545,13 +527,6 @@
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/application/api/controller/Demo.php">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="450">
<caret line="21" column="4" lean-forward="true" selection-start-line="21" selection-start-column="4" selection-end-line="39" selection-end-column="7" />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/application/database.php">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="450">
... ... @@ -682,10 +657,34 @@
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/application/api/controller/Demo.php">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="375">
<caret line="21" column="4" lean-forward="true" selection-start-line="21" selection-start-column="4" selection-end-line="39" selection-end-column="7" />
<folding />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/application/api/controller/Ems.php">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="0">
<caret line="0" column="0" lean-forward="false" selection-start-line="0" selection-start-column="0" selection-end-line="0" selection-end-column="0" />
<folding />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/application/api/controller/Index.php">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="0">
<caret line="0" column="0" lean-forward="false" selection-start-line="0" selection-start-column="0" selection-end-line="0" selection-end-column="0" />
<folding />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/application/api/controller/User.php">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="327">
<caret line="197" column="33" lean-forward="false" selection-start-line="197" selection-start-column="33" selection-end-line="197" selection-end-column="33" />
<state relative-caret-position="309">
<caret line="459" column="5" lean-forward="true" selection-start-line="459" selection-start-column="5" selection-end-line="459" selection-end-column="5" />
<folding>
<element signature="e#38#68#0#PHP" expanded="true" />
<element signature="e#337#456#0#PHP" expanded="false" />
... ... @@ -696,15 +695,60 @@
<element signature="e#4184#4591#0#PHP" expanded="false" />
<element signature="e#4596#4939#0#PHP" expanded="false" />
<element signature="e#4945#5597#0#PHP" expanded="false" />
<element signature="e#5602#7545#0#PHP" expanded="false" />
<element signature="e#7551#8000#0#PHP" expanded="false" />
<element signature="e#8005#8888#0#PHP" expanded="false" />
<element signature="e#8894#9578#0#PHP" expanded="false" />
<element signature="e#9583#11079#0#PHP" expanded="false" />
<element signature="e#11085#11462#0#PHP" expanded="false" />
<element signature="e#11467#11731#0#PHP" expanded="false" />
<element signature="e#8894#9411#0#PHP" expanded="false" />
<element signature="e#9416#10415#0#PHP" expanded="false" />
<element signature="e#10421#11105#0#PHP" expanded="false" />
<element signature="e#11110#12606#0#PHP" expanded="false" />
<element signature="e#12612#13336#0#PHP" expanded="false" />
<element signature="e#13341#14959#0#PHP" expanded="false" />
<element signature="e#14965#15342#0#PHP" expanded="false" />
<element signature="e#15347#15611#0#PHP" expanded="false" />
</folding>
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/application/admin/controller/Video.php">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="1464">
<caret line="169" column="0" lean-forward="true" selection-start-line="169" selection-start-column="0" selection-end-line="169" selection-end-column="0" />
<folding />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/public/assets/js/backend/video.js">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="50">
<caret line="23" column="26" lean-forward="true" selection-start-line="23" selection-start-column="26" selection-end-line="23" selection-end-column="26" />
<folding />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/application/admin/view/video/add.html">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="51">
<caret line="90" column="4" lean-forward="false" selection-start-line="90" selection-start-column="4" selection-end-line="113" selection-end-column="10" />
<folding />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/application/admin/view/video/edit.html">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="326">
<caret line="104" column="40" lean-forward="true" selection-start-line="104" selection-start-column="40" selection-end-line="104" selection-end-column="40" />
<folding />
</state>
</provider>
</entry>
<entry file="file://$PROJECT_DIR$/application/admin/lang/zh-cn/video.php">
<provider selected="true" editor-type-id="text-editor">
<state relative-caret-position="325">
<caret line="13" column="24" lean-forward="false" selection-start-line="13" selection-start-column="24" selection-end-line="13" selection-end-column="24" />
<folding />
</state>
</provider>
</entry>
</component>
</project>
\ No newline at end of file
... ...
... ... @@ -10,8 +10,12 @@ return [
'Two_url' => '2k视频地址',
'Four_url' => '4k视频地址',
'Eight_url' => '8k视频地址',
'Price' =>'正常价格',
'Vip_price' =>'会员价格',
'Price' =>'2k正常价格',
'Vip_price' =>'2k会员价格',
'Four_price' =>'4K正常价格',
'Four_vipprice' =>'4K会员价格',
'Eight_price' =>'8K正常价格',
'Eight_vipprice' =>'8K会员价格',
'Content' =>'视频介绍',
'Is_recommend' => '是否精选',
'Buy_num' =>'购买数量',
... ...
... ... @@ -55,19 +55,19 @@
<div class="form-group">
<label class="control-label col-xs-12 col-sm-2">{:__('Two_url')}:</label>
<div class="col-xs-12 col-sm-8">
<input id="c-two_url" data-rule="required" class="form-control" name="row[two_url]" type="text" placeholder="请输入2k视频网址">
<input id="c-two_url" class="form-control" name="row[two_url]" type="text" placeholder="请输入2k视频网址">
</div>
</div>
<div class="form-group">
<label class="control-label col-xs-12 col-sm-2">{:__('Four_url')}:</label>
<div class="col-xs-12 col-sm-8">
<input id="c-four_url" data-rule="required" class="form-control" name="row[four_url]" type="text" placeholder="请输入4k视频网址">
<input id="c-four_url" class="form-control" name="row[four_url]" type="text" placeholder="请输入4k视频网址">
</div>
</div>
<div class="form-group">
<label class="control-label col-xs-12 col-sm-2">{:__('Eight_url')}:</label>
<div class="col-xs-12 col-sm-8">
<input id="c-eight_url" data-rule="required" class="form-control" name="row[eight_url]" type="text" placeholder="请输入8k视频网址">
<input id="c-eight_url" class="form-control" name="row[eight_url]" type="text" placeholder="请输入8k视频网址">
</div>
</div>
<div class="form-group">
... ... @@ -79,13 +79,37 @@
<div class="form-group">
<label class="control-label col-xs-12 col-sm-2">{:__('Price')}:</label>
<div class="col-xs-12 col-sm-8">
<input id="c-price" data-rule="required" class="form-control" name="row[price]" type="text" placeholder="请输入普通价格">
<input id="c-price" class="form-control" name="row[price]" type="text" placeholder="请输入2k普通价格">
</div>
</div>
<div class="form-group">
<label class="control-label col-xs-12 col-sm-2">{:__('Vip_price')}:</label>
<div class="col-xs-12 col-sm-8">
<input id="c-vip_price" data-rule="required" class="form-control" name="row[vip_price]" type="text" placeholder="请输入会员价格">
<input id="c-vip_price" class="form-control" name="row[vip_price]" type="text" placeholder="请输入2k会员价格">
</div>
</div>
<div class="form-group">
<label class="control-label col-xs-12 col-sm-2">{:__('Four_price')}:</label>
<div class="col-xs-12 col-sm-8">
<input id="c-four_price" class="form-control" name="row[four_price]" type="text" placeholder="请输入4k普通价格">
</div>
</div>
<div class="form-group">
<label class="control-label col-xs-12 col-sm-2">{:__('Four_vipprice')}:</label>
<div class="col-xs-12 col-sm-8">
<input id="c-four_vipprice" class="form-control" name="row[four_vipprice]" type="text" placeholder="请输入4k会员价格">
</div>
</div>
<div class="form-group">
<label class="control-label col-xs-12 col-sm-2">{:__('Eight_price')}:</label>
<div class="col-xs-12 col-sm-8">
<input id="c-eight_price" class="form-control" name="row[eight_price]" type="text" placeholder="请输入8k普通价格">
</div>
</div>
<div class="form-group">
<label class="control-label col-xs-12 col-sm-2">{:__('Eight_vipprice')}:</label>
<div class="col-xs-12 col-sm-8">
<input id="c-eight_vipprice" class="form-control" name="row[eight_vipprice]" type="text" placeholder="请输入8k会员价格">
</div>
</div>
<div class="form-group">
... ...
... ... @@ -55,19 +55,19 @@
<div class="form-group">
<label class="control-label col-xs-12 col-sm-2">{:__('Two_url')}:</label>
<div class="col-xs-12 col-sm-8">
<input id="c-two_url" data-rule="required" class="form-control" name="row[two_url]" type="text" value="{$row.two_url|htmlentities}" placeholder="请输入2k云盘地址">
<input id="c-two_url" class="form-control" name="row[two_url]" type="text" value="{$row.two_url|htmlentities}" placeholder="请输入2k云盘地址">
</div>
</div>
<div class="form-group">
<label class="control-label col-xs-12 col-sm-2">{:__('Four_url')}:</label>
<div class="col-xs-12 col-sm-8">
<input id="c-four_url" data-rule="required" class="form-control" name="row[four_url]" type="text" value="{$row.four_url|htmlentities}" placeholder="请输入4k云盘地址">
<input id="c-four_url" class="form-control" name="row[four_url]" type="text" value="{$row.four_url|htmlentities}" placeholder="请输入4k云盘地址">
</div>
</div>
<div class="form-group">
<label class="control-label col-xs-12 col-sm-2">{:__('Eight_url')}:</label>
<div class="col-xs-12 col-sm-8">
<input id="c-eight_url" data-rule="required" class="form-control" name="row[eight_url]" type="text" value="{$row.eight_url|htmlentities}" placeholder="请输入8k云盘地址">
<input id="c-eight_url" class="form-control" name="row[eight_url]" type="text" value="{$row.eight_url|htmlentities}" placeholder="请输入8k云盘地址">
</div>
</div>
<div class="form-group">
... ... @@ -79,13 +79,37 @@
<div class="form-group">
<label class="control-label col-xs-12 col-sm-2">{:__('Price')}:</label>
<div class="col-xs-12 col-sm-8">
<input id="c-price" data-rule="required" class="form-control" name="row[price]" type="text" value="{$row.price}" placeholder="请输入普通价格">
<input id="c-price" class="form-control" name="row[price]" type="text" value="{$row.price}" placeholder="请输入2k普通价格">
</div>
</div>
<div class="form-group">
<label class="control-label col-xs-12 col-sm-2">{:__('Vip_price')}:</label>
<div class="col-xs-12 col-sm-8">
<input id="c-vip_price" data-rule="required" class="form-control" name="row[vip_price]" type="text" value="{$row.vip_price}" placeholder="请输入会员价格">
<input id="c-vip_price" class="form-control" name="row[vip_price]" type="text" value="{$row.vip_price}" placeholder="请输入2k会员价格">
</div>
</div>
<div class="form-group">
<label class="control-label col-xs-12 col-sm-2">{:__('Four_price')}:</label>
<div class="col-xs-12 col-sm-8">
<input id="c-four_price" class="form-control" name="row[four_price]" type="text" value="{$row.four_price}" placeholder="请输入4k普通价格">
</div>
</div>
<div class="form-group">
<label class="control-label col-xs-12 col-sm-2">{:__('Four_vipprice')}:</label>
<div class="col-xs-12 col-sm-8">
<input id="c-four_vipprice" class="form-control" name="row[four_vipprice]" type="text" value="{$row.four_vipprice}" placeholder="请输入4k会员价格">
</div>
</div>
<div class="form-group">
<label class="control-label col-xs-12 col-sm-2">{:__('Eight_price')}:</label>
<div class="col-xs-12 col-sm-8">
<input id="c-eight_price" class="form-control" name="row[eight_price]" type="text" value="{$row.eight_price}" placeholder="请输入8k普通价格">
</div>
</div>
<div class="form-group">
<label class="control-label col-xs-12 col-sm-2">{:__('Eight_vipprice')}:</label>
<div class="col-xs-12 col-sm-8">
<input id="c-eight_vipprice" class="form-control" name="row[eight_vipprice]" type="text" value="{$row.eight_vipprice}" placeholder="请输入8k会员价格">
</div>
</div>
<div class="form-group">
... ...
<?php
namespace app\api\controller;
use app\common\controller\Api;
/**
* 示例接口
*/
class Demo extends Api
{
//如果$noNeedLogin为空表示所有接口都需要登录才能请求
//如果$noNeedRight为空表示所有接口都需要验证权限才能请求
//如果接口已经设置无需登录,那也就无需鉴权了
//
// 无需登录的接口,*表示全部
protected $noNeedLogin = ['test', 'test1'];
// 无需鉴权的接口,*表示全部
protected $noNeedRight = ['test2'];
/**
* 测试方法
*
* @ApiTitle (测试名称)
* @ApiSummary (测试描述信息)
* @ApiMethod (POST)
* @ApiRoute (/api/demo/test/id/{id}/name/{name})
* @ApiHeaders (name=token, type=string, required=true, description="请求的Token")
* @ApiParams (name="id", type="integer", required=true, description="会员ID")
* @ApiParams (name="name", type="string", required=true, description="用户名")
* @ApiParams (name="data", type="object", sample="{'user_id':'int','user_name':'string','profile':{'email':'string','age':'integer'}}", description="扩展数据")
* @ApiReturnParams (name="code", type="integer", required=true, sample="0")
* @ApiReturnParams (name="msg", type="string", required=true, sample="返回成功")
* @ApiReturnParams (name="data", type="object", sample="{'user_id':'int','user_name':'string','profile':{'email':'string','age':'integer'}}", description="扩展数据返回")
* @ApiReturn ({
'code':'1',
'msg':'返回成功'
})
*/
public function test()
{
var_dump(1111);exit;
$this->success('返回成功', $this->request->param());
}
}
<?php
namespace app\api\controller;
use app\common\controller\Api;
/**
* 首页接口
*/
class Index extends Api
{
protected $noNeedLogin = ['*'];
protected $noNeedRight = ['*'];
/**
* 首页
*
*/
public function index()
{
$this->success('请求成功');
}
}
... ... @@ -282,6 +282,54 @@ class User extends Api
}
/**
* @ApiTitle (视频列表)
* @ApiSummary (视频列表)
* @ApiMethod (POST)
* @ApiRoute (/api/user/video)
* @ApiHeaders (name=token, type=string, required=true, description="请求的Token")
* @ApiParams (name="type_id", type="inter", required=false, description="地区ID")
* @ApiReturn({
"code": 1,
"msg": "成功",
"time": "1571492001",
"data": {
"id": //图片id,
"thumbnail": //视频封面,
"video"://视频地址
}
})
*/
public function video()
{
$rule = config('verify.path');
$type_id = $this->request->post('type_id');
if(empty($type_id)){
$data = Db::name('video')
->field('id,thumbnail,video')
->order('id desc')
->select();
foreach ($data as &$v){
$v['thumbnail'] = $rule.$v['thumbnail'];
$v['video'] = $rule.$v['video'];
}
$this->success('SUCCESS',$data);
}else{
$type = ','.$type_id.',';
$where['type_ids'] = ['like',"%$type%"];
$data = Db::name('video')
->where($where)
->field('id,thumbnail,video')
->order('id desc')
->select();
foreach ($data as &$v){
$v['thumbnail'] = $rule.$v['thumbnail'];
$v['video'] = $rule.$v['video'];
}
$this->success('SUCCESS',$data);
}
}
/**
* @ApiTitle (图片详情)
* @ApiSummary (图片详情)
* @ApiMethod (POST)
... ... @@ -346,6 +394,72 @@ class User extends Api
}
/**
* @ApiTitle (视频详情)
* @ApiSummary (视频详情)
* @ApiMethod (POST)
* @ApiRoute (/api/user/videodetail)
* @ApiHeaders (name=token, type=string, required=true, description="请求的Token")
*
* @ApiParams (name="video_id", type="inter", required=true, description="视频ID")
* @ApiReturn({
"code": 1,
"msg": "成功",
"time": "1571492001",
"data": {
"id": 4,//视频id,
"title"://标题
"thumbnail": //视频封面图,
"video": //2K视频地址,
"water_url"://小样视频网址
"price"://2K价格,
"vip_price"://2Kvip价格,
"content"://图片介绍,
"is_vip"://是否为会员(0否 1是)
}
})
*/
public function videodetail()
{
$uid = $this->uid;
$rule = config('verify.path');
$res = Db::name('user')
->where('id',$uid)
->field('id,is_vip')
->find();
if($res['is_vip'] == 0){
$pic_id = $this->request->post('video_id');
if(empty($pic_id)){
$this->error(['code'=>2,'msg'=>'缺少必要参数']);
}
$data = Db::name('video')
->field('id,title,thumbnail,video,price,vip_price,water_url,content')
->where('id',$pic_id)
->find();
$data['thumbnail'] = $rule.$data['thumbnail'];
$data['video'] = $rule.$data['video'];
$data['water_url'] = $rule.$data['water_url'];
$data['content'] = strip_tags($data['content']);
$data['is_vip'] = 0;
$this->success('SUCCESS',$data);
}elseif($res['is_vip'] == 1){
$pic_id = $this->request->post('pic_id');
if(empty($pic_id)){
$this->error(['code'=>2,'msg'=>'缺少必要参数']);
}
$data = Db::name('video')
->field('id,title,thumbnail,video,price,vip_price,water_url,content')
->where('id',$pic_id)
->find();
$data['is_vip'] = 1;
$data['thumbnail'] = $rule.$data['thumbnail'];
$data['video'] = $rule.$data['video'];
$data['water_url'] = $rule.$data['water_url'];
$data['content'] = strip_tags($data['content']);
$this->success('SUCCESS',$data);
}
}
/**
* @ApiTitle (历史记录)
* @ApiSummary (历史记录)
* @ApiMethod (POST)
... ...
... ... @@ -144,32 +144,26 @@
<a href="javascript:;" data-id="0" class="list-group-item">加载初始化</a>
<a href="javascript:;" data-id="1" class="list-group-item">上传文件</a>
</div>
<a href="#示例接口" class="list-group-item" data-toggle="collapse" data-parent="#sidebar">示例接口 <i class="fa fa-caret-down"></i></a>
<div class="child collapse" id="示例接口">
<a href="javascript:;" data-id="2" class="list-group-item">测试名称</a>
</div>
<a href="#邮箱验证码接口" class="list-group-item" data-toggle="collapse" data-parent="#sidebar">邮箱验证码接口 <i class="fa fa-caret-down"></i></a>
<div class="child collapse" id="邮箱验证码接口">
<a href="javascript:;" data-id="3" class="list-group-item">发送验证码</a>
<a href="javascript:;" data-id="4" class="list-group-item">检测验证码</a>
</div>
<a href="#首页接口" class="list-group-item" data-toggle="collapse" data-parent="#sidebar">首页接口 <i class="fa fa-caret-down"></i></a>
<div class="child collapse" id="首页接口">
<a href="javascript:;" data-id="5" class="list-group-item">首页</a>
<a href="javascript:;" data-id="2" class="list-group-item">发送验证码</a>
<a href="javascript:;" data-id="3" class="list-group-item">检测验证码</a>
</div>
<a href="#Token接口" class="list-group-item" data-toggle="collapse" data-parent="#sidebar">Token接口 <i class="fa fa-caret-down"></i></a>
<div class="child collapse" id="Token接口">
<a href="javascript:;" data-id="6" class="list-group-item">检测Token是否过期</a>
<a href="javascript:;" data-id="7" class="list-group-item">刷新Token</a>
<a href="javascript:;" data-id="4" class="list-group-item">检测Token是否过期</a>
<a href="javascript:;" data-id="5" class="list-group-item">刷新Token</a>
</div>
<a href="#个人中心" class="list-group-item" data-toggle="collapse" data-parent="#sidebar">个人中心 <i class="fa fa-caret-down"></i></a>
<div class="child collapse" id="个人中心">
<a href="javascript:;" data-id="8" class="list-group-item">小程序登录</a>
<a href="javascript:;" data-id="9" class="list-group-item">首页视频、图片、精美大片入口</a>
<a href="javascript:;" data-id="10" class="list-group-item">地区分类</a>
<a href="javascript:;" data-id="11" class="list-group-item">搜索页</a>
<a href="javascript:;" data-id="12" class="list-group-item">图片列表</a>
<a href="javascript:;" data-id="13" class="list-group-item">图片详情</a>
<a href="javascript:;" data-id="6" class="list-group-item">小程序登录</a>
<a href="javascript:;" data-id="7" class="list-group-item">首页视频、图片、精美大片入口</a>
<a href="javascript:;" data-id="8" class="list-group-item">地区分类</a>
<a href="javascript:;" data-id="9" class="list-group-item">搜索页</a>
<a href="javascript:;" data-id="10" class="list-group-item">图片列表</a>
<a href="javascript:;" data-id="11" class="list-group-item">视频列表</a>
<a href="javascript:;" data-id="12" class="list-group-item">图片详情</a>
<a href="javascript:;" data-id="13" class="list-group-item">视频详情</a>
<a href="javascript:;" data-id="14" class="list-group-item">历史记录</a>
</div>
</div>
... ... @@ -417,13 +411,13 @@
</div>
</div>
</div>
<h2>示例接口</h2>
<h2>邮箱验证码接口</h2>
<hr>
<div class="panel panel-default">
<div class="panel-heading" id="heading-2">
<h4 class="panel-title">
<span class="label label-primary">POST</span>
<a data-toggle="collapse" data-parent="#accordion2" href="#collapseOne2"> 测试名称 <span class="text-muted">/api/demo/test/id/{id}/name/{name}</span></a>
<span class="label label-success">GET</span>
<a data-toggle="collapse" data-parent="#accordion2" href="#collapseOne2"> 发送验证码 <span class="text-muted">/api/ems/send</span></a>
</h4>
</div>
<div id="collapseOne2" class="panel-collapse collapse">
... ... @@ -441,28 +435,11 @@
<div class="tab-pane active" id="info2">
<div class="well">
测试描述信息 </div>
发送验证码 </div>
<div class="panel panel-default">
<div class="panel-heading"><strong>Headers</strong></div>
<div class="panel-body">
<table class="table table-hover">
<thead>
<tr>
<th>名称</th>
<th>类型</th>
<th>必选</th>
<th>描述</th>
</tr>
</thead>
<tbody>
<tr>
<td>token</td>
<td>string</td>
<td></td>
<td>请求的Token</td>
</tr>
</tbody>
</table>
</div>
</div>
<div class="panel panel-default">
... ... @@ -479,22 +456,16 @@
</thead>
<tbody>
<tr>
<td>id</td>
<td>integer</td>
<td></td>
<td>会员ID</td>
</tr>
<tr>
<td>name</td>
<td>email</td>
<td>string</td>
<td></td>
<td>用户名</td>
<td>邮箱</td>
</tr>
<tr>
<td>data</td>
<td>object</td>
<td>event</td>
<td>string</td>
<td></td>
<td>扩展数据</td>
<td>事件名称</td>
</tr>
</tbody>
</table>
... ... @@ -511,31 +482,16 @@
<div class="row">
<div class="col-md-12">
<div class="panel panel-default">
<div class="panel-heading"><strong>Headers</strong></div>
<div class="panel-body">
<div class="headers">
<div class="form-group">
<label class="control-label" for="token">token</label>
<input type="string" class="form-control input-sm" id="token" required placeholder="请求的Token - Ex: " name="token">
</div>
</div>
</div>
</div>
<div class="panel panel-default">
<div class="panel-heading"><strong>参数</strong></div>
<div class="panel-body">
<form enctype="application/x-www-form-urlencoded" role="form" action="/api/demo/test/id/{id}/name/{name}" method="POST" name="form2" id="form2">
<form enctype="application/x-www-form-urlencoded" role="form" action="/api/ems/send" method="get" name="form2" id="form2">
<div class="form-group">
<label class="control-label" for="id">id</label>
<input type="integer" class="form-control input-sm" id="id" required placeholder="会员ID" name="id">
</div>
<div class="form-group">
<label class="control-label" for="name">name</label>
<input type="string" class="form-control input-sm" id="name" required placeholder="用户名" name="name">
<label class="control-label" for="email">email</label>
<input type="string" class="form-control input-sm" id="email" required placeholder="邮箱" name="email">
</div>
<div class="form-group">
<label class="control-label" for="data">data</label>
<input type="object" class="form-control input-sm" id="data" required placeholder="扩展数据 - 例: {'user_id':'int','user_name':'string','profile':{'email':'string','age':'integer'}}" name="data">
<label class="control-label" for="event">event</label>
<input type="string" class="form-control input-sm" id="event" required placeholder="事件名称" name="event">
</div>
<div class="form-group">
<button type="submit" class="btn btn-success send" rel="2">提交</button>
... ... @@ -558,32 +514,7 @@
<div class="panel panel-default">
<div class="panel-heading"><strong>返回参数</strong></div>
<div class="panel-body">
<table class="table table-hover">
<thead>
<tr>
<th>名称</th>
<th>类型</th>
<th>描述</th>
</tr>
</thead>
<tbody>
<tr>
<td>code</td>
<td>integer</td>
<td></td>
</tr>
<tr>
<td>msg</td>
<td>string</td>
<td></td>
</tr>
<tr>
<td>data</td>
<td>object</td>
<td>扩展数据返回</td>
</tr>
</tbody>
</table>
</div>
</div>
</div>
... ... @@ -593,10 +524,7 @@
<div class="tab-pane" id="sample2">
<div class="row">
<div class="col-md-12">
<pre id="sample_response2">{
'code':'1',
'msg':'返回成功'
}</pre>
<pre id="sample_response2"></pre>
</div>
</div>
</div><!-- #sample -->
... ... @@ -605,13 +533,11 @@
</div>
</div>
</div>
<h2>邮箱验证码接口</h2>
<hr>
<div class="panel panel-default">
<div class="panel-heading" id="heading-3">
<h4 class="panel-title">
<span class="label label-success">GET</span>
<a data-toggle="collapse" data-parent="#accordion3" href="#collapseOne3"> 发送验证码 <span class="text-muted">/api/ems/send</span></a>
<a data-toggle="collapse" data-parent="#accordion3" href="#collapseOne3"> 检测验证码 <span class="text-muted">/api/ems/check</span></a>
</h4>
</div>
<div id="collapseOne3" class="panel-collapse collapse">
... ... @@ -629,7 +555,7 @@
<div class="tab-pane active" id="info3">
<div class="well">
发送验证码 </div>
检测验证码 </div>
<div class="panel panel-default">
<div class="panel-heading"><strong>Headers</strong></div>
<div class="panel-body">
... ... @@ -661,6 +587,12 @@
<td></td>
<td>事件名称</td>
</tr>
<tr>
<td>captcha</td>
<td>string</td>
<td></td>
<td>验证码</td>
</tr>
</tbody>
</table>
</div>
... ... @@ -678,7 +610,7 @@
<div class="panel panel-default">
<div class="panel-heading"><strong>参数</strong></div>
<div class="panel-body">
<form enctype="application/x-www-form-urlencoded" role="form" action="/api/ems/send" method="get" name="form3" id="form3">
<form enctype="application/x-www-form-urlencoded" role="form" action="/api/ems/check" method="get" name="form3" id="form3">
<div class="form-group">
<label class="control-label" for="email">email</label>
<input type="string" class="form-control input-sm" id="email" required placeholder="邮箱" name="email">
... ... @@ -688,6 +620,10 @@
<input type="string" class="form-control input-sm" id="event" required placeholder="事件名称" name="event">
</div>
<div class="form-group">
<label class="control-label" for="captcha">captcha</label>
<input type="string" class="form-control input-sm" id="captcha" required placeholder="验证码" name="captcha">
</div>
<div class="form-group">
<button type="submit" class="btn btn-success send" rel="3">提交</button>
<button type="reset" class="btn btn-info" rel="3">重置</button>
</div>
... ... @@ -727,11 +663,13 @@
</div>
</div>
</div>
<h2>Token接口</h2>
<hr>
<div class="panel panel-default">
<div class="panel-heading" id="heading-4">
<h4 class="panel-title">
<span class="label label-success">GET</span>
<a data-toggle="collapse" data-parent="#accordion4" href="#collapseOne4"> 检测验证码 <span class="text-muted">/api/ems/check</span></a>
<a data-toggle="collapse" data-parent="#accordion4" href="#collapseOne4"> 检测Token是否过期 <span class="text-muted">/api/token/check</span></a>
</h4>
</div>
<div id="collapseOne4" class="panel-collapse collapse">
... ... @@ -749,7 +687,7 @@
<div class="tab-pane active" id="info4">
<div class="well">
检测验证码 </div>
检测Token是否过期 </div>
<div class="panel panel-default">
<div class="panel-heading"><strong>Headers</strong></div>
<div class="panel-body">
... ... @@ -759,36 +697,7 @@
<div class="panel panel-default">
<div class="panel-heading"><strong>参数</strong></div>
<div class="panel-body">
<table class="table table-hover">
<thead>
<tr>
<th>名称</th>
<th>类型</th>
<th>必选</th>
<th>描述</th>
</tr>
</thead>
<tbody>
<tr>
<td>email</td>
<td>string</td>
<td></td>
<td>邮箱</td>
</tr>
<tr>
<td>event</td>
<td>string</td>
<td></td>
<td>事件名称</td>
</tr>
<tr>
<td>captcha</td>
<td>string</td>
<td></td>
<td>验证码</td>
</tr>
</tbody>
</table>
</div>
</div>
<div class="panel panel-default">
... ... @@ -804,18 +713,9 @@
<div class="panel panel-default">
<div class="panel-heading"><strong>参数</strong></div>
<div class="panel-body">
<form enctype="application/x-www-form-urlencoded" role="form" action="/api/ems/check" method="get" name="form4" id="form4">
<div class="form-group">
<label class="control-label" for="email">email</label>
<input type="string" class="form-control input-sm" id="email" required placeholder="邮箱" name="email">
</div>
<div class="form-group">
<label class="control-label" for="event">event</label>
<input type="string" class="form-control input-sm" id="event" required placeholder="事件名称" name="event">
</div>
<form enctype="application/x-www-form-urlencoded" role="form" action="/api/token/check" method="get" name="form4" id="form4">
<div class="form-group">
<label class="control-label" for="captcha">captcha</label>
<input type="string" class="form-control input-sm" id="captcha" required placeholder="验证码" name="captcha">
</div>
<div class="form-group">
<button type="submit" class="btn btn-success send" rel="4">提交</button>
... ... @@ -857,13 +757,11 @@
</div>
</div>
</div>
<h2>首页接口</h2>
<hr>
<div class="panel panel-default">
<div class="panel-heading" id="heading-5">
<h4 class="panel-title">
<span class="label label-success">GET</span>
<a data-toggle="collapse" data-parent="#accordion5" href="#collapseOne5"> 首页 <span class="text-muted">/api/index/index</span></a>
<a data-toggle="collapse" data-parent="#accordion5" href="#collapseOne5"> 刷新Token <span class="text-muted">/api/token/refresh</span></a>
</h4>
</div>
<div id="collapseOne5" class="panel-collapse collapse">
... ... @@ -881,7 +779,7 @@
<div class="tab-pane active" id="info5">
<div class="well">
首页 </div>
刷新Token </div>
<div class="panel panel-default">
<div class="panel-heading"><strong>Headers</strong></div>
<div class="panel-body">
... ... @@ -907,7 +805,7 @@
<div class="panel panel-default">
<div class="panel-heading"><strong>参数</strong></div>
<div class="panel-body">
<form enctype="application/x-www-form-urlencoded" role="form" action="/api/index/index" method="get" name="form5" id="form5">
<form enctype="application/x-www-form-urlencoded" role="form" action="/api/token/refresh" method="get" name="form5" id="form5">
<div class="form-group">
</div>
... ... @@ -951,13 +849,13 @@
</div>
</div>
</div>
<h2>Token接口</h2>
<h2>个人中心</h2>
<hr>
<div class="panel panel-default">
<div class="panel-heading" id="heading-6">
<h4 class="panel-title">
<span class="label label-success">GET</span>
<a data-toggle="collapse" data-parent="#accordion6" href="#collapseOne6"> 检测Token是否过期 <span class="text-muted">/api/token/check</span></a>
<span class="label label-primary">POST</span>
<a data-toggle="collapse" data-parent="#accordion6" href="#collapseOne6"> 小程序登录 <span class="text-muted">/api/user/login</span></a>
</h4>
</div>
<div id="collapseOne6" class="panel-collapse collapse">
... ... @@ -975,7 +873,7 @@
<div class="tab-pane active" id="info6">
<div class="well">
检测Token是否过期 </div>
小程序登录 </div>
<div class="panel panel-default">
<div class="panel-heading"><strong>Headers</strong></div>
<div class="panel-body">
... ... @@ -985,7 +883,36 @@
<div class="panel panel-default">
<div class="panel-heading"><strong>参数</strong></div>
<div class="panel-body">
<table class="table table-hover">
<thead>
<tr>
<th>名称</th>
<th>类型</th>
<th>必选</th>
<th>描述</th>
</tr>
</thead>
<tbody>
<tr>
<td>code</td>
<td>string</td>
<td></td>
<td>小程序code</td>
</tr>
<tr>
<td>nickname</td>
<td>string</td>
<td></td>
<td>小程序昵称</td>
</tr>
<tr>
<td>avatar</td>
<td>string</td>
<td></td>
<td>小程序头像</td>
</tr>
</tbody>
</table>
</div>
</div>
<div class="panel panel-default">
... ... @@ -1001,9 +928,18 @@
<div class="panel panel-default">
<div class="panel-heading"><strong>参数</strong></div>
<div class="panel-body">
<form enctype="application/x-www-form-urlencoded" role="form" action="/api/token/check" method="get" name="form6" id="form6">
<form enctype="application/x-www-form-urlencoded" role="form" action="/api/user/login" method="POST" name="form6" id="form6">
<div class="form-group">
<label class="control-label" for="code">code</label>
<input type="string" class="form-control input-sm" id="code" required placeholder="小程序code" name="code">
</div>
<div class="form-group">
<label class="control-label" for="nickname">nickname</label>
<input type="string" class="form-control input-sm" id="nickname" required placeholder="小程序昵称" name="nickname">
</div>
<div class="form-group">
<label class="control-label" for="avatar">avatar</label>
<input type="string" class="form-control input-sm" id="avatar" required placeholder="小程序头像" name="avatar">
</div>
<div class="form-group">
<button type="submit" class="btn btn-success send" rel="6">提交</button>
... ... @@ -1036,7 +972,18 @@
<div class="tab-pane" id="sample6">
<div class="row">
<div class="col-md-12">
<pre id="sample_response6"></pre>
<pre id="sample_response6">{
"code": 1,
"msg": "登录成功",
"time": "1553839125",
"data": {
"token": "677afb39-1a4f-4492-84d3-0bcf32016b8a",//token
"user_id": 27,//用户id
"createtime": 1553839125,//登录时间
"expiretime": 1556431125,//token失效时间
"expires_in": 2592000//token失效剩余时间(单位s)
"openid": 1485212522522//openid
}</pre>
</div>
</div>
</div><!-- #sample -->
... ... @@ -1048,8 +995,8 @@
<div class="panel panel-default">
<div class="panel-heading" id="heading-7">
<h4 class="panel-title">
<span class="label label-success">GET</span>
<a data-toggle="collapse" data-parent="#accordion7" href="#collapseOne7"> 刷新Token <span class="text-muted">/api/token/refresh</span></a>
<span class="label label-primary">POST</span>
<a data-toggle="collapse" data-parent="#accordion7" href="#collapseOne7"> 首页视频、图片、精美大片入口 <span class="text-muted">/api/user/index</span></a>
</h4>
</div>
<div id="collapseOne7" class="panel-collapse collapse">
... ... @@ -1067,11 +1014,28 @@
<div class="tab-pane active" id="info7">
<div class="well">
刷新Token </div>
首页视频、图片、精美大片入口 </div>
<div class="panel panel-default">
<div class="panel-heading"><strong>Headers</strong></div>
<div class="panel-body">
<table class="table table-hover">
<thead>
<tr>
<th>名称</th>
<th>类型</th>
<th>必选</th>
<th>描述</th>
</tr>
</thead>
<tbody>
<tr>
<td>token</td>
<td>string</td>
<td></td>
<td>请求的Token</td>
</tr>
</tbody>
</table>
</div>
</div>
<div class="panel panel-default">
... ... @@ -1091,9 +1055,20 @@
<div class="row">
<div class="col-md-12">
<div class="panel panel-default">
<div class="panel-heading"><strong>Headers</strong></div>
<div class="panel-body">
<div class="headers">
<div class="form-group">
<label class="control-label" for="token">token</label>
<input type="string" class="form-control input-sm" id="token" required placeholder="请求的Token - Ex: " name="token">
</div>
</div>
</div>
</div>
<div class="panel panel-default">
<div class="panel-heading"><strong>参数</strong></div>
<div class="panel-body">
<form enctype="application/x-www-form-urlencoded" role="form" action="/api/token/refresh" method="get" name="form7" id="form7">
<form enctype="application/x-www-form-urlencoded" role="form" action="/api/user/index" method="POST" name="form7" id="form7">
<div class="form-group">
</div>
... ... @@ -1128,7 +1103,16 @@
<div class="tab-pane" id="sample7">
<div class="row">
<div class="col-md-12">
<pre id="sample_response7"></pre>
<pre id="sample_response7">{
'code':'1',
'msg':'返回成功',
"time": "1571492001",
"data": {
"video_thumbnail": http://mapwww.baidu.com 视频封面图地址
"pic_thumbnail": http://mapwww.baidu.com 图片地址
"wonderful_thumbnail": http://mapwww.baidu.com 精美大片地址
}
}</pre>
</div>
</div>
</div><!-- #sample -->
... ... @@ -1137,13 +1121,11 @@
</div>
</div>
</div>
<h2>个人中心</h2>
<hr>
<div class="panel panel-default">
<div class="panel-heading" id="heading-8">
<h4 class="panel-title">
<span class="label label-primary">POST</span>
<a data-toggle="collapse" data-parent="#accordion8" href="#collapseOne8"> 小程序登录 <span class="text-muted">/api/user/login</span></a>
<a data-toggle="collapse" data-parent="#accordion8" href="#collapseOne8"> 地区分类 <span class="text-muted">/api/user/type</span></a>
</h4>
</div>
<div id="collapseOne8" class="panel-collapse collapse">
... ... @@ -1161,16 +1143,10 @@
<div class="tab-pane active" id="info8">
<div class="well">
小程序登录 </div>
地区分类 </div>
<div class="panel panel-default">
<div class="panel-heading"><strong>Headers</strong></div>
<div class="panel-body">
</div>
</div>
<div class="panel panel-default">
<div class="panel-heading"><strong>参数</strong></div>
<div class="panel-body">
<table class="table table-hover">
<thead>
<tr>
... ... @@ -1182,28 +1158,22 @@
</thead>
<tbody>
<tr>
<td>code</td>
<td>string</td>
<td></td>
<td>小程序code</td>
</tr>
<tr>
<td>nickname</td>
<td>string</td>
<td></td>
<td>小程序昵称</td>
</tr>
<tr>
<td>avatar</td>
<td>token</td>
<td>string</td>
<td></td>
<td>小程序头像</td>
<td>请求的Token</td>
</tr>
</tbody>
</table>
</div>
</div>
<div class="panel panel-default">
<div class="panel-heading"><strong>参数</strong></div>
<div class="panel-body">
</div>
</div>
<div class="panel panel-default">
<div class="panel-heading"><strong>正文</strong></div>
<div class="panel-body">
</div>
... ... @@ -1214,20 +1184,22 @@
<div class="row">
<div class="col-md-12">
<div class="panel panel-default">
<div class="panel-heading"><strong>参数</strong></div>
<div class="panel-heading"><strong>Headers</strong></div>
<div class="panel-body">
<form enctype="application/x-www-form-urlencoded" role="form" action="/api/user/login" method="POST" name="form8" id="form8">
<div class="form-group">
<label class="control-label" for="code">code</label>
<input type="string" class="form-control input-sm" id="code" required placeholder="小程序code" name="code">
</div>
<div class="headers">
<div class="form-group">
<label class="control-label" for="nickname">nickname</label>
<input type="string" class="form-control input-sm" id="nickname" required placeholder="小程序昵称" name="nickname">
<label class="control-label" for="token">token</label>
<input type="string" class="form-control input-sm" id="token" required placeholder="请求的Token - Ex: " name="token">
</div>
</div>
</div>
</div>
<div class="panel panel-default">
<div class="panel-heading"><strong>参数</strong></div>
<div class="panel-body">
<form enctype="application/x-www-form-urlencoded" role="form" action="/api/user/type" method="POST" name="form8" id="form8">
<div class="form-group">
<label class="control-label" for="avatar">avatar</label>
<input type="string" class="form-control input-sm" id="avatar" required placeholder="小程序头像" name="avatar">
</div>
<div class="form-group">
<button type="submit" class="btn btn-success send" rel="8">提交</button>
... ... @@ -1262,15 +1234,13 @@
<div class="col-md-12">
<pre id="sample_response8">{
"code": 1,
"msg": "登录成功",
"time": "1553839125",
"msg": "成功",
"time": "1571492001",
"data": {
"token": "677afb39-1a4f-4492-84d3-0bcf32016b8a",//token
"user_id": 27,//用户id
"createtime": 1553839125,//登录时间
"expiretime": 1556431125,//token失效时间
"expires_in": 2592000//token失效剩余时间(单位s)
"openid": 1485212522522//openid
"id": 4,//分类id
"area_name": //分类名称
"thumbnail": //图片
}
}</pre>
</div>
</div>
... ... @@ -1284,7 +1254,7 @@
<div class="panel-heading" id="heading-9">
<h4 class="panel-title">
<span class="label label-primary">POST</span>
<a data-toggle="collapse" data-parent="#accordion9" href="#collapseOne9"> 首页视频、图片、精美大片入口 <span class="text-muted">/api/user/index</span></a>
<a data-toggle="collapse" data-parent="#accordion9" href="#collapseOne9"> 搜索页 <span class="text-muted">/api/user/search</span></a>
</h4>
</div>
<div id="collapseOne9" class="panel-collapse collapse">
... ... @@ -1302,7 +1272,7 @@
<div class="tab-pane active" id="info9">
<div class="well">
首页视频、图片、精美大片入口 </div>
搜索页 </div>
<div class="panel panel-default">
<div class="panel-heading"><strong>Headers</strong></div>
<div class="panel-body">
... ... @@ -1329,7 +1299,30 @@
<div class="panel panel-default">
<div class="panel-heading"><strong>参数</strong></div>
<div class="panel-body">
<table class="table table-hover">
<thead>
<tr>
<th>名称</th>
<th>类型</th>
<th>必选</th>
<th>描述</th>
</tr>
</thead>
<tbody>
<tr>
<td>type_id</td>
<td>inter</td>
<td></td>
<td>视频/图片 (视频为1 图片为2 精美大片为3)</td>
</tr>
<tr>
<td>keyword</td>
<td>string</td>
<td></td>
<td>关键字</td>
</tr>
</tbody>
</table>
</div>
</div>
<div class="panel panel-default">
... ... @@ -1356,9 +1349,14 @@
<div class="panel panel-default">
<div class="panel-heading"><strong>参数</strong></div>
<div class="panel-body">
<form enctype="application/x-www-form-urlencoded" role="form" action="/api/user/index" method="POST" name="form9" id="form9">
<form enctype="application/x-www-form-urlencoded" role="form" action="/api/user/search" method="POST" name="form9" id="form9">
<div class="form-group">
<label class="control-label" for="type_id">type_id</label>
<input type="inter" class="form-control input-sm" id="type_id" placeholder="视频/图片 (视频为1 图片为2 精美大片为3)" name="type_id">
</div>
<div class="form-group">
<label class="control-label" for="keyword">keyword</label>
<input type="string" class="form-control input-sm" id="keyword" required placeholder="关键字" name="keyword">
</div>
<div class="form-group">
<button type="submit" class="btn btn-success send" rel="9">提交</button>
... ... @@ -1392,13 +1390,13 @@
<div class="row">
<div class="col-md-12">
<pre id="sample_response9">{
'code':'1',
'msg':'返回成功',
"time": "1571492001",
"code": 1,
"msg": "成功",
"time": "1571492001",
"data": {
"video_thumbnail": http://mapwww.baidu.com 视频封面图地址
"pic_thumbnail": http://mapwww.baidu.com 图片地址
"wonderful_thumbnail": http://mapwww.baidu.com 精美大片地址
"id": 4,//视频id/图片id,
"thumbnail": //视频封面图地址/图片地址,
"video": //视频路径/精美大片视频路径,
}
}</pre>
</div>
... ... @@ -1413,7 +1411,7 @@
<div class="panel-heading" id="heading-10">
<h4 class="panel-title">
<span class="label label-primary">POST</span>
<a data-toggle="collapse" data-parent="#accordion10" href="#collapseOne10"> 地区分类 <span class="text-muted">/api/user/type</span></a>
<a data-toggle="collapse" data-parent="#accordion10" href="#collapseOne10"> 图片列表 <span class="text-muted">/api/user/pic</span></a>
</h4>
</div>
<div id="collapseOne10" class="panel-collapse collapse">
... ... @@ -1431,7 +1429,7 @@
<div class="tab-pane active" id="info10">
<div class="well">
地区分类 </div>
图片列表 </div>
<div class="panel panel-default">
<div class="panel-heading"><strong>Headers</strong></div>
<div class="panel-body">
... ... @@ -1458,7 +1456,24 @@
<div class="panel panel-default">
<div class="panel-heading"><strong>参数</strong></div>
<div class="panel-body">
<table class="table table-hover">
<thead>
<tr>
<th>名称</th>
<th>类型</th>
<th>必选</th>
<th>描述</th>
</tr>
</thead>
<tbody>
<tr>
<td>type_id</td>
<td>inter</td>
<td></td>
<td>地区ID</td>
</tr>
</tbody>
</table>
</div>
</div>
<div class="panel panel-default">
... ... @@ -1485,9 +1500,10 @@
<div class="panel panel-default">
<div class="panel-heading"><strong>参数</strong></div>
<div class="panel-body">
<form enctype="application/x-www-form-urlencoded" role="form" action="/api/user/type" method="POST" name="form10" id="form10">
<form enctype="application/x-www-form-urlencoded" role="form" action="/api/user/pic" method="POST" name="form10" id="form10">
<div class="form-group">
<label class="control-label" for="type_id">type_id</label>
<input type="inter" class="form-control input-sm" id="type_id" placeholder="地区ID" name="type_id">
</div>
<div class="form-group">
<button type="submit" class="btn btn-success send" rel="10">提交</button>
... ... @@ -1525,10 +1541,9 @@
"msg": "成功",
"time": "1571492001",
"data": {
"id": 4,//分类id
"area_name": //分类名称
"thumbnail": //图片
}
"id": 4,//图片id,
"thumbnail": //缩略图,
}
}</pre>
</div>
</div>
... ... @@ -1542,7 +1557,7 @@
<div class="panel-heading" id="heading-11">
<h4 class="panel-title">
<span class="label label-primary">POST</span>
<a data-toggle="collapse" data-parent="#accordion11" href="#collapseOne11"> 搜索页 <span class="text-muted">/api/user/search</span></a>
<a data-toggle="collapse" data-parent="#accordion11" href="#collapseOne11"> 视频列表 <span class="text-muted">/api/user/video</span></a>
</h4>
</div>
<div id="collapseOne11" class="panel-collapse collapse">
... ... @@ -1560,7 +1575,7 @@
<div class="tab-pane active" id="info11">
<div class="well">
搜索页 </div>
视频列表 </div>
<div class="panel panel-default">
<div class="panel-heading"><strong>Headers</strong></div>
<div class="panel-body">
... ... @@ -1601,13 +1616,7 @@
<td>type_id</td>
<td>inter</td>
<td></td>
<td>视频/图片 (视频为1 图片为2 精美大片为3)</td>
</tr>
<tr>
<td>keyword</td>
<td>string</td>
<td></td>
<td>关键字</td>
<td>地区ID</td>
</tr>
</tbody>
</table>
... ... @@ -1637,14 +1646,10 @@
<div class="panel panel-default">
<div class="panel-heading"><strong>参数</strong></div>
<div class="panel-body">
<form enctype="application/x-www-form-urlencoded" role="form" action="/api/user/search" method="POST" name="form11" id="form11">
<form enctype="application/x-www-form-urlencoded" role="form" action="/api/user/video" method="POST" name="form11" id="form11">
<div class="form-group">
<label class="control-label" for="type_id">type_id</label>
<input type="inter" class="form-control input-sm" id="type_id" placeholder="视频/图片 (视频为1 图片为2 精美大片为3)" name="type_id">
</div>
<div class="form-group">
<label class="control-label" for="keyword">keyword</label>
<input type="string" class="form-control input-sm" id="keyword" required placeholder="关键字" name="keyword">
<input type="inter" class="form-control input-sm" id="type_id" placeholder="地区ID" name="type_id">
</div>
<div class="form-group">
<button type="submit" class="btn btn-success send" rel="11">提交</button>
... ... @@ -1682,11 +1687,11 @@
"msg": "成功",
"time": "1571492001",
"data": {
"id": 4,//视频id/图片id,
"thumbnail": //视频封面图地址/图片地址,
"video": //视频路径/精美大片视频路径,
"id": //图片id,
"thumbnail": //视频封面,
"video"://视频地址
}
}</pre>
}</pre>
</div>
</div>
</div><!-- #sample -->
... ... @@ -1699,7 +1704,7 @@
<div class="panel-heading" id="heading-12">
<h4 class="panel-title">
<span class="label label-primary">POST</span>
<a data-toggle="collapse" data-parent="#accordion12" href="#collapseOne12"> 图片列表 <span class="text-muted">/api/user/pic</span></a>
<a data-toggle="collapse" data-parent="#accordion12" href="#collapseOne12"> 图片详情 <span class="text-muted">/api/user/picdetail</span></a>
</h4>
</div>
<div id="collapseOne12" class="panel-collapse collapse">
... ... @@ -1717,7 +1722,7 @@
<div class="tab-pane active" id="info12">
<div class="well">
图片列表 </div>
图片详情 </div>
<div class="panel panel-default">
<div class="panel-heading"><strong>Headers</strong></div>
<div class="panel-body">
... ... @@ -1755,10 +1760,10 @@
</thead>
<tbody>
<tr>
<td>type_id</td>
<td>pic_id</td>
<td>inter</td>
<td></td>
<td>地区ID</td>
<td></td>
<td>图片ID</td>
</tr>
</tbody>
</table>
... ... @@ -1788,10 +1793,10 @@
<div class="panel panel-default">
<div class="panel-heading"><strong>参数</strong></div>
<div class="panel-body">
<form enctype="application/x-www-form-urlencoded" role="form" action="/api/user/pic" method="POST" name="form12" id="form12">
<form enctype="application/x-www-form-urlencoded" role="form" action="/api/user/picdetail" method="POST" name="form12" id="form12">
<div class="form-group">
<label class="control-label" for="type_id">type_id</label>
<input type="inter" class="form-control input-sm" id="type_id" placeholder="地区ID" name="type_id">
<label class="control-label" for="pic_id">pic_id</label>
<input type="inter" class="form-control input-sm" id="pic_id" required placeholder="图片ID" name="pic_id">
</div>
<div class="form-group">
<button type="submit" class="btn btn-success send" rel="12">提交</button>
... ... @@ -1825,13 +1830,20 @@
<div class="row">
<div class="col-md-12">
<pre id="sample_response12">{
"code": 1,
"msg": "成功",
"time": "1571492001",
"data": {
"id": 4,//图片id,
"thumbnail": //缩略图,
}
"code": 1,
"msg": "成功",
"time": "1571492001",
"data": {
"id": 4,//图片id,
"title"://标题
"thumbnail": //缩略图,
"water_url": //小样带水印的图片地址,
"price"://正常价格,
"vip_price"://vip价格,
"content"://图片介绍,
"is_vip"://是否为会员(0否 1是)
}
}</pre>
</div>
</div>
... ... @@ -1845,7 +1857,7 @@
<div class="panel-heading" id="heading-13">
<h4 class="panel-title">
<span class="label label-primary">POST</span>
<a data-toggle="collapse" data-parent="#accordion13" href="#collapseOne13"> 图片详情 <span class="text-muted">/api/user/picdetail</span></a>
<a data-toggle="collapse" data-parent="#accordion13" href="#collapseOne13"> 视频详情 <span class="text-muted">/api/user/videodetail</span></a>
</h4>
</div>
<div id="collapseOne13" class="panel-collapse collapse">
... ... @@ -1863,7 +1875,7 @@
<div class="tab-pane active" id="info13">
<div class="well">
图片详情 </div>
视频详情 </div>
<div class="panel panel-default">
<div class="panel-heading"><strong>Headers</strong></div>
<div class="panel-body">
... ... @@ -1901,10 +1913,10 @@
</thead>
<tbody>
<tr>
<td>pic_id</td>
<td>video_id</td>
<td>inter</td>
<td></td>
<td>图片ID</td>
<td>视频ID</td>
</tr>
</tbody>
</table>
... ... @@ -1934,10 +1946,10 @@
<div class="panel panel-default">
<div class="panel-heading"><strong>参数</strong></div>
<div class="panel-body">
<form enctype="application/x-www-form-urlencoded" role="form" action="/api/user/picdetail" method="POST" name="form13" id="form13">
<form enctype="application/x-www-form-urlencoded" role="form" action="/api/user/videodetail" method="POST" name="form13" id="form13">
<div class="form-group">
<label class="control-label" for="pic_id">pic_id</label>
<input type="inter" class="form-control input-sm" id="pic_id" required placeholder="图片ID" name="pic_id">
<label class="control-label" for="video_id">video_id</label>
<input type="inter" class="form-control input-sm" id="video_id" required placeholder="视频ID" name="video_id">
</div>
<div class="form-group">
<button type="submit" class="btn btn-success send" rel="13">提交</button>
... ... @@ -1975,17 +1987,17 @@
"msg": "成功",
"time": "1571492001",
"data": {
"id": 4,//图片id,
"id": 4,//视频id,
"title"://标题
"thumbnail": //缩略图,
"water_url": //小样带水印的图片地址,
"price"://正常价格,
"vip_price"://vip价格,
"content"://图片介绍,
"is_vip"://是否为会员(0否 1是)
"thumbnail": //视频封面图,
"video": //2K视频地址,
"water_url"://小样视频网址
"price"://2K价格,
"vip_price"://2Kvip价格,
"content"://图片介绍,
"is_vip"://是否为会员(0否 1是)
}
}</pre>
}</pre>
</div>
</div>
</div><!-- #sample -->
... ... @@ -2128,7 +2140,7 @@
<div class="row mt0 footer">
<div class="col-md-6" align="left">
Generated on 2019-11-19 18:57:51 </div>
Generated on 2019-11-19 19:24:34 </div>
<div class="col-md-6" align="right">
<a href="https://www.fastadmin.net" target="_blank">FastAdmin</a>
</div>
... ...
... ... @@ -38,6 +38,10 @@ define(['jquery', 'bootstrap', 'backend', 'table', 'form'], function ($, undefin
{field: 'click_num', title: __('Click_num')},
{field: 'price', title: __('Price')},
{field: 'vip_price', title: __('Vip_price')},
{field: 'four_price', title: __('Four_price')},
{field: 'four_vipprice', title: __('Four_vipprice')},
{field: 'eight_price', title: __('Eight_price')},
{field: 'eight_vipprice', title: __('Eight_vipprice')},
{field: 'createtime', title: __('Createtime'), operate:'RANGE', addclass:'datetimerange', formatter: Table.api.formatter.datetime},
{field: 'operate', title: __('Operate'), table: table, events: Table.api.events.operate, formatter: Table.api.formatter.operate}
]
... ...