dever 5 年之前
父節點
當前提交
18af635025
共有 6 個文件被更改,包括 28 次插入7 次删除
  1. 8 1
      lib/dever/components/video.nvue
  2. 1 1
      manifest.json
  3. 1 1
      pages.json
  4. 6 2
      pages/dream/index.vue
  5. 10 1
      pages/dream/view.vue
  6. 2 1
      pages/dream/view/vodShort.vue

+ 8 - 1
lib/dever/components/video.nvue

@@ -96,6 +96,10 @@ export default {
 		position_save : {
 			type    : String,
 			value	: null
+		},
+		type : {
+			type    : String,
+			value	: 1
 		},
 	},
 	data() {
@@ -109,7 +113,10 @@ export default {
 			showInfo : false,
 		};
 	},
-	mounted() {
+	mounted() {
+		if (this.type == 2) {
+			this.objectFit = '';
+		}
 		this.video = uni.createVideoContext(this.id(), this);
 		if (this.auto) {
 			this.start();

+ 1 - 1
manifest.json

@@ -1,5 +1,5 @@
 {
-    "name" : "幻境",
+    "name" : "云店",
     "appid" : "__UNI__10C3233",
     "description" : "",
     "versionName" : "1.0.0",

+ 1 - 1
pages.json

@@ -65,7 +65,7 @@
 	"globalStyle": {
 		"navigationBarTextStyle": "white",
 		"navigationBarBackgroundColor": "#3c64c9",
-		"navigationBarTitleText" : "幻境",
+		"navigationBarTitleText" : "云店",
 		"enablePullDownRefresh": true,
 		"scrollIndicator": "none",
 		"navigationStyle": "default",

+ 6 - 2
pages/dream/index.vue

@@ -75,7 +75,11 @@ export default{
 			this.swiper.index = e.detail.current;
 		},
 		getData : function() {
-			this.Dever.get(this, 'app/collection/?l=api.getInfo', {id:this.id});
+			this.Dever.get(this, 'app/collection/?l=api.getInfo', {id:this.id}, function(t) {
+				uni.setNavigationBarTitle({
+					title:t.info.name
+				});
+			});
 		},
 		goView : function() {
 			//是否购买
@@ -86,7 +90,7 @@ export default{
 			}
 		},
 		view : function() {
-			this.Dever.location('dream/view?code='+this.fetch.code);
+			this.Dever.location('dream/view?code='+this.fetch.code + '&name=' + this.fetch.info.name);
 		},
 		hideBuy : function() {
 			this.buyState = false;

+ 10 - 1
pages/dream/view.vue

@@ -131,6 +131,12 @@ export default{
 	},
 	onLoad(option) {
 		this.login = true;
+		if (option && option.name) {
+			uni.setNavigationBarTitle({
+				title:option.name
+			});
+		}
+		
 		this.Dever.config.code = option.code;
 		this.getData();
 	},
@@ -192,7 +198,7 @@ export default{
 			this.Dever.location('dream/view?id=1');
 		},
 		initDrawer : function() {
-			this.getContentId();
+			//this.getContentId();
 			var i = '';
 			this.drawer.button = [];
 			for (i in this.drawer.item) {
@@ -206,6 +212,9 @@ export default{
 			var self = this;
 			self.drawer.item = {};
 			this.Dever.get(this, 'app/collection/?l=api.getContent', {code:this.Dever.config.code}, function(t) {
+				uni.setNavigationBarTitle({
+					title:t.info.name
+				});
 				self.swiper.index = parseInt(t.index);
 				self.record();
 				if (t && t['func']) {

+ 2 - 1
pages/dream/view/vodShort.vue

@@ -6,7 +6,8 @@
 				:src="v.video" 
 				:pic="v.pic" 
 				:index="k" 
-				:vid="v.id" 
+				:vid="v.id"
+				:type="v.type"
 				:position_item="v.text"
 				:position_save="v.is_button"
 				:load.sync="load"