瀏覽代碼

处理文件上传种类以及bug问题

张启 4 年之前
父節點
當前提交
bbe4191188
共有 4 個文件被更改,包括 11 次插入11 次删除
  1. 2 2
      pages/enterprise/add_change.html
  2. 6 6
      pages/pdinfo/add_change.html
  3. 2 2
      pages/region/add_change.html
  4. 1 1
      pages/spread/index.html

+ 2 - 2
pages/enterprise/add_change.html

@@ -183,7 +183,7 @@
 				<div class="layui-form-item">
 					{{# if(!d.list){d.list = []}; layui.each(d.list, function(index, item){ }}
 					<div class="my-images-inline">
-						{{#if ("jpg|jpeg|png|bmp".indexOf(item.substring(item.lastIndexOf(".")+1))==-1){}}
+						{{#if ("jpg|jpeg|png|gif|bmp".indexOf(item.substring(item.lastIndexOf(".")+1))==-1){}}
 						<video class="my-img" src="{{window.hywa.config.href}}/{{item}}" autoplay loop></video>
 						{{#}else{}}
 						<img class="my-img" src="{{window.hywa.config.href}}/{{item}}">
@@ -305,7 +305,7 @@
 				elem: '#imageUploadBtn',
 				url: 'uploadImage',
 				accept: "file",
-				exts: "jpg|jpeg|png|bmp|avi|mp4|wma|rmvb|rm|3gp|flv|mp3",
+				exts: "jpg|jpeg|png|gif|bmp|mp4|ogg|webm|avi|wma|rmvb|rm|flash|3gp|flv|mp3",
 				size: 10240,//kb
 				before: function () {
 					uploadMsg = layer.msg('正在上传中……', {

+ 6 - 6
pages/pdinfo/add_change.html

@@ -351,7 +351,7 @@
 			<div class="layui-form-item">
 			{{# if(!d.list){d.list = []}; layui.each(d.list, function(index, item){ }}
 			<div class="my-images-inline">
-				{{#if ("jpg|jpeg|png|bmp".indexOf(item.substring(item.lastIndexOf(".")+1))==-1){}}
+				{{#if ("jpg|jpeg|png|gif|bmp".indexOf(item.substring(item.lastIndexOf(".")+1))==-1){}}
 				<video class="my-img" src="{{window.hywa.config.href}}/{{item}}" autoplay loop></video>
 				{{#}else{}}
 				<img class="my-img" src="{{window.hywa.config.href}}/{{item}}">
@@ -383,7 +383,7 @@
 			<div class="layui-form-item">
 			{{# if(!d.list){d.list = []}; layui.each(d.list, function(index, item){ }}
 			<div class="my-images-inline">
-				{{#if ("jpg|jpeg|png|bmp".indexOf(item.substring(item.lastIndexOf(".")+1))==-1){}}
+				{{#if ("jpg|jpeg|png|gif|bmp".indexOf(item.substring(item.lastIndexOf(".")+1))==-1){}}
 				<video class="my-img" src="{{window.hywa.config.href}}/{{item}}" autoplay loop></video>
 				{{#}else{}}
 				<img class="my-img" src="{{window.hywa.config.href}}/{{item}}">
@@ -450,7 +450,7 @@
 					elem: '#imageUploadBtn',
 					url: 'uploadImage',
 					accept: "file",
-					exts: "jpg|jpeg|png|bmp|mp4|ogg|webm",
+					exts: "jpg|jpeg|png|gif|bmp|mp4|ogg|webm|avi|wma|rmvb|rm|flash|3gp|flv",
 					size: 10240, //kb
 					before: function () {
 						uploadMsg = layer.msg('正在上传中……', {
@@ -473,7 +473,7 @@
 					elem: '#assayImageUploadBtn',
 					url: 'uploadImage',
 					accept: "file",
-					exts: "jpg|jpeg|png|bmp|mp4|ogg|webm",
+					exts: "jpg|jpeg|png|gif|bmp|mp4|ogg|webm|avi|wma|rmvb|rm|flash|3gp|flv",
 					size: 10240, //kb
 					before: function () {
 						uploadMsg = layer.msg('正在上传中……', {
@@ -699,7 +699,7 @@
 							elem: upelem, //绑定元素
 							url: 'uploadImage',
 							accept: "file",
-							exts: "jpg|jpeg|png|bmp|avi|mp4|wma|rmvb|rm|3gp|flv|mp3",
+							exts: "jpg|jpeg|png|gif|bmp|mp4|ogg|webm|avi|wma|rmvb|rm|flash|3gp|flv|mp3",
 							size: 10240,
 							before: function () {
 								uploadMsg = layer.msg('正在上传中……', {
@@ -889,7 +889,7 @@
 							elem: upelem, //绑定元素
 							url: 'uploadImage',
 							accept: "file",
-							exts: "jpg|jpeg|png|bmp|avi|mp4|wma|rmvb|rm|3gp|flv|mp3",
+							exts: "jpg|jpeg|png|gif|bmp|mp4|ogg|webm|avi|wma|rmvb|rm|flash|3gp|flv|mp3",
 							size: 10240,
 							before: function () {
 								uploadMsg = layer.msg('正在上传中……', {

+ 2 - 2
pages/region/add_change.html

@@ -220,7 +220,7 @@
 		<div class="layui-form-item">
 		{{# if(!d.list){d.list = []}; layui.each(d.list, function(index, item){ }}
 			<div class="my-images-inline">
-				{{#if ("jpg|jpeg|png|bmp".indexOf(item.substring(item.lastIndexOf(".")+1))==-1){}}
+				{{#if ("jpg|jpeg|png|gif|bmp".indexOf(item.substring(item.lastIndexOf(".")+1))==-1){}}
 				<video class="my-img" src="{{window.hywa.config.href}}/{{item}}" autoplay loop></video>
 				{{#}else{}}
 				<img class="my-img" src="{{window.hywa.config.href}}/{{item}}">
@@ -267,7 +267,7 @@
 				elem: '#imageUploadBtn',
 				url: 'uploadImage',
 				accept: "file",
-				exts: "jpg|jpeg|png|bmp|avi|mp4|wma|rmvb|rm|3gp|flv|mp3",
+				exts: "jpg|jpeg|png|gif|bmp|mp4|ogg|webm|avi|wma|rmvb|rm|flash|3gp|flv|mp3",
 				size: 10240,//kb
 				before: function () {
 					uploadMsg = layer.msg('正在上传中……', {

+ 1 - 1
pages/spread/index.html

@@ -215,7 +215,7 @@
 			<div class="layui-form-item">
 				{{# if(!d.list){d.list = []}; layui.each(d.list, function(index, item){ }}
 					<div class="my-images-inline">
-						{{#if ("jpg|jpeg|png|bmp".indexOf(item.substring(item.lastIndexOf(".")+1))==-1){}}
+						{{#if ("jpg|jpeg|png|gif|bmp".indexOf(item.substring(item.lastIndexOf(".")+1))==-1){}}
 						<video class="my-img" src="{{window.hywa.config.href}}/{{item}}" autoplay loop></video>
 						{{#}else{}}
 						<img class="my-img" src="{{window.hywa.config.href}}/{{item}}">