提交 d7b75851 编写于 作者: xinglee23's avatar xinglee23

Merge branch 'release' into feature/wxl

...@@ -17,7 +17,8 @@ ...@@ -17,7 +17,8 @@
<div id="app"> <div id="app">
<router-view></router-view> <router-view></router-view>
</div> </div>
<script src="https://unpkg.com/qiniu-js@2.2.0/dist/qiniu.min.js"></script> <!-- <script src="https://unpkg.com/qiniu-js@2.2.0/dist/qiniu.min.js"></script> -->
<script src="https://pica-h5.yunqueyi.com/static/js/qiniu2.5.4.min.js"></script>
<script src="https://cdn.bootcss.com/downloadjs/1.4.8/download.min.js"></script> <script src="https://cdn.bootcss.com/downloadjs/1.4.8/download.min.js"></script>
<script src="https://pv.sohu.com/cityjson?ie=utf-8"></script> <script src="https://pv.sohu.com/cityjson?ie=utf-8"></script>
<script src="https://gosspublic.alicdn.com/aliyun-oss-sdk-5.1.1.min.js"></script> <script src="https://gosspublic.alicdn.com/aliyun-oss-sdk-5.1.1.min.js"></script>
......
...@@ -14,6 +14,7 @@ ...@@ -14,6 +14,7 @@
} }
.word-tip { .word-tip {
color: #e6af7a; color: #e6af7a;
line-height: 32px;
} }
.word-show { .word-show {
color: #449284; color: #449284;
...@@ -49,8 +50,9 @@ ...@@ -49,8 +50,9 @@
color: #f56c6c; color: #f56c6c;
margin-right: 4px; margin-right: 4px;
} }
.required-label .el-form-item__content .bg-uploader .el-upload{ .required-label .el-form-item__content .bg-uploader .el-upload {
width: 100%; width: 100%;
line-height: 32px;
} }
.goods-category, .goods-category,
.project-req { .project-req {
...@@ -101,11 +103,9 @@ ...@@ -101,11 +103,9 @@
color: #f56c6c; color: #f56c6c;
} }
.upload-message { .upload-message {
position: absolute;
left: 0;
top: 105px;
font-size: 12px; font-size: 12px;
color: #f56c6c; color: #f56c6c;
line-height: 24px;
} }
.backTip { .backTip {
font-size: 12px; font-size: 12px;
...@@ -123,7 +123,7 @@ ...@@ -123,7 +123,7 @@
height: 100%; height: 100%;
background: #000; background: #000;
opacity: 0.7; opacity: 0.7;
transform: translate(-50%,-50%); transform: translate(-50%, -50%);
z-index: 999; z-index: 999;
i { i {
...@@ -146,6 +146,7 @@ ...@@ -146,6 +146,7 @@
} }
.bg-uploader { .bg-uploader {
line-height: 1;
.bg-img { .bg-img {
float: left; float: left;
width: 84px; width: 84px;
...@@ -155,12 +156,12 @@ ...@@ -155,12 +156,12 @@
.limit-text { .limit-text {
float: left; float: left;
margin-left: 10px; margin-left: 10px;
margin-top: -10px;
p { p {
font-size: 12px; font-size: 12px;
color: #999; color: #999;
text-align: left; text-align: left;
line-height: 32px;
} }
} }
} }
...@@ -245,13 +246,20 @@ ...@@ -245,13 +246,20 @@
cursor: pointer; cursor: pointer;
color: #449284; color: #449284;
} }
.file-pics { .img-box {
display: inline-block;
width: 84px; width: 84px;
height: 100px; height: 130px;
float: left; float: left;
margin-right: 15px; margin-right: 15px;
position: relative; position: relative;
.checkbox {
line-height: 32px;
}
}
.file-pics {
width: 84px;
height: 100px;
position: relative;
} }
.el-input-number__decrease, .el-input-number__decrease,
.el-input-number__increase { .el-input-number__increase {
......
...@@ -131,15 +131,20 @@ ...@@ -131,15 +131,20 @@
:limit="6" :limit="6"
> >
<div :key="index" v-for="(item,index) in fileGoodsList"> <div :key="index" v-for="(item,index) in fileGoodsList">
<div class="file-pics" v-if="fileGoodsList.length > 0" > <div class="img-box">
<img :src="item.url" @mouseover.stop="headIndex=index" class="bg-img"/> <div class="file-pics" v-if="fileGoodsList.length > 0" >
<div <img :src="item.url" @mouseover.stop="headIndex=index" class="bg-img"/>
class="img-delete" <div
v-if="headIndex==index" class="img-delete"
@click.stop="deleteImg(item,fileGoodsList)" v-if="headIndex==index"
@mouseout.stop="headIndex=-1" @click.stop="deleteImg(item,fileGoodsList)"
> @mouseout.stop="headIndex=-1"
<i class="el-icon-delete"></i> >
<i class="el-icon-delete"></i>
</div>
</div>
<div class="checkbox" @click.stop>
<el-checkbox :true-label="0" :false-label="1" v-model="fileGoodsList[index].miniProgramShow"></el-checkbox>
</div> </div>
</div> </div>
</div> </div>
...@@ -151,6 +156,7 @@ ...@@ -151,6 +156,7 @@
</div> </div>
</el-upload> </el-upload>
<p class="upload-message" v-if="!isgoodsImages">请上传商品头图</p> <p class="upload-message" v-if="!isgoodsImages">请上传商品头图</p>
<p class="word-tip">勾选的头图在云鹊健康小程序不可见</p>
<!-- <p class="upload-message" v-if="uploadImgMessage1">请上传商品头图</p> --> <!-- <p class="upload-message" v-if="uploadImgMessage1">请上传商品头图</p> -->
</el-form-item> </el-form-item>
...@@ -191,8 +197,8 @@ ...@@ -191,8 +197,8 @@
:show-file-list="false" :show-file-list="false"
:before-upload="beforeUploadPic1" :before-upload="beforeUploadPic1"
> >
<div v-if="fileIntrList.length > 0"> <div :key="index" v-for="(item,index) in fileIntrList">
<div :key="index" v-for="(item,index) in fileIntrList"> <div class="img-box">
<div class="file-pics" v-if="item.url||item.imageUrl"> <div class="file-pics" v-if="item.url||item.imageUrl">
<img v-if="item.imageType==4" :src="item.url" @mouseover.stop="intrIndex=index" class="bg-img"/> <img v-if="item.imageType==4" :src="item.url" @mouseover.stop="intrIndex=index" class="bg-img"/>
<video v-if="item.imageType==5" @mouseover.stop="intrIndex=index" :src="item.imageUrl" controls preload style="width: 100%;height:100%; object-fit:fill" > <video v-if="item.imageType==5" @mouseover.stop="intrIndex=index" :src="item.imageUrl" controls preload style="width: 100%;height:100%; object-fit:fill" >
...@@ -207,6 +213,9 @@ ...@@ -207,6 +213,9 @@
<i class="el-icon-delete"></i> <i class="el-icon-delete"></i>
</div> </div>
</div> </div>
<div class="checkbox" @click.stop>
<el-checkbox :true-label="0" :false-label="1" v-model="fileIntrList[index].miniProgramShow"></el-checkbox>
</div>
</div> </div>
</div> </div>
...@@ -217,6 +226,7 @@ ...@@ -217,6 +226,7 @@
</div> </div>
</el-upload> </el-upload>
<p class="upload-message" v-if="!isSpecification_url">请上传商品详情图片</p> <p class="upload-message" v-if="!isSpecification_url">请上传商品详情图片</p>
<p class="word-tip">勾选的详情在云鹊健康小程序不可见</p>
</el-form-item> </el-form-item>
</div> </div>
...@@ -566,15 +576,15 @@ ...@@ -566,15 +576,15 @@
</template> </template>
<script> <script>
import BreadCrumb from "@/components/breadcrumb.vue"; import BreadCrumb from "@/components/breadcrumb.vue";
import Cropper from '@/components/common/cropper.vue';
import { getBarcodeData, getCategorysList, getContractList, getCooperationProjectList, getGoodsList, getGoodsListAll, getMedList, saveMedList, updateGoods, updateStock } from '@/utils/goods';
import { isEmptyUtils } from "@/utils/index";
import { createFilePath, doUpload, getFilePath } from "@/utils/qiniu-util";
import { getStoreAdressRepot } from "@/utils/shop";
import { closeLoading, openLoading, signFigures } from "@/utils/utils";
import { originForm, originForm1, originForm3 } from './common/forms';
import { originRules, originRules1, originRules3 } from './common/rules';
let vm = null; let vm = null;
import { openLoading, closeLoading, signFigures } from "@/utils/utils";
import { isEmptyUtils } from "@/utils/index";
import { doUpload, getFilePath, createFilePath } from "@/utils/qiniu-util";
import { updateGoods ,updateStock,getGoodsList, getGoodDetails, updateGoodsV2,getContractList, getCooperationProjectList,getMedList,getCategorysList,saveMedList,getGoodsListAll,getBarcodeData} from '@/utils/goods';
import { getStoreAdressRepot } from "@/utils/shop";
import Cropper from '@/components/common/cropper.vue'
import { originRules1, originRules, originRules3 } from './common/rules';
import { originForm1, originForm, originForm3 } from './common/forms';
export default { export default {
components: { components: {
...@@ -1108,6 +1118,7 @@ ...@@ -1108,6 +1118,7 @@
imageSort: d[i].imageSort, imageSort: d[i].imageSort,
imgSort: d[i].imgSort, imgSort: d[i].imgSort,
imageType: type == 1 ? d[i].imgType : d[i].imageType, imageType: type == 1 ? d[i].imgType : d[i].imageType,
miniProgramShow: d[i].miniProgramShow===0?0:1,
}) })
} }
} }
...@@ -1336,7 +1347,7 @@ ...@@ -1336,7 +1347,7 @@
closeLoading(vm); closeLoading(vm);
console.log('上传成功后路径', path); console.log('上传成功后路径', path);
let len = vm.fileGoodsList.length; let len = vm.fileGoodsList.length;
vm.fileGoodsList.push({ url: path.fullPath, goodsImgUrl: path.fullPath,imageUrl:path.fullPath, imgSort: len+1,imageSort: len+1, goodsId: vm.formData.goodsId }); vm.fileGoodsList.push({miniProgramShow:1, url: path.fullPath, goodsImgUrl: path.fullPath,imageUrl:path.fullPath, imgSort: len+1,imageSort: len+1, goodsId: vm.formData.goodsId });
vm.isgoodsImages = true; vm.isgoodsImages = true;
// vm.fileGoodsList.push({url:path.fullPath,goodsImgUrl: path.fullPath,imageUrl:path.fullPath,imageName:'',imageSort: len+1,imageType: 2,id: null,}) // vm.fileGoodsList.push({url:path.fullPath,goodsImgUrl: path.fullPath,imageUrl:path.fullPath,imageName:'',imageSort: len+1,imageType: 2,id: null,})
...@@ -1430,7 +1441,7 @@ ...@@ -1430,7 +1441,7 @@
doUpload(vm, file, getFilePath(file, null), "preview4", "progress1", 1).then(function (path) { doUpload(vm, file, getFilePath(file, null), "preview4", "progress1", 1).then(function (path) {
closeLoading(vm); closeLoading(vm);
let len = vm.fileIntrList.length; let len = vm.fileIntrList.length;
vm.fileIntrList.push({url:path.fullPath,imageUrl:path.fullPath,imageSort: len+1,id: null, imageType: 4}) vm.fileIntrList.push({miniProgramShow:1, url:path.fullPath,imageUrl:path.fullPath,imageSort: len+1,id: null, imageType: 4})
vm.isSpecification_url = true; vm.isSpecification_url = true;
vm.$message.success("上传成功"); vm.$message.success("上传成功");
}); });
......
Markdown 格式
0% or
您添加了 0 到此讨论。请谨慎行事。
先完成此消息的编辑!
想要评论请 注册