Commit dc1d5677 authored by 高滢's avatar 高滢

feat(样品): 图片展示

parent 7e122319
...@@ -39,7 +39,7 @@ export default { ...@@ -39,7 +39,7 @@ export default {
if (isExternal(real_src)) { if (isExternal(real_src)) {
return real_src return real_src
} }
return process.env.VUE_APP_BASE_API + real_src return process.env.VUE_APP_IMAGE_API + real_src
}, },
realSrcList() { realSrcList() {
if (!this.src) { if (!this.src) {
...@@ -51,7 +51,7 @@ export default { ...@@ -51,7 +51,7 @@ export default {
if (isExternal(item)) { if (isExternal(item)) {
return srcList.push(item) return srcList.push(item)
} }
return srcList.push(process.env.VUE_APP_BASE_API + item) return srcList.push(process.env.VUE_APP_IMAGE_API + item)
}) })
return srcList return srcList
}, },
......
...@@ -100,7 +100,7 @@ ...@@ -100,7 +100,7 @@
<el-link <el-link
type="primary" type="primary"
:underline="false" :underline="false"
@click="clickSampleName()" @click="clickSampleName(scope.row)"
>{{ scope.row.sampleName }}</el-link >{{ scope.row.sampleName }}</el-link
> >
</template> </template>
...@@ -302,6 +302,37 @@ ...@@ -302,6 +302,37 @@
</div> </div>
</el-form> </el-form>
</el-drawer> </el-drawer>
<el-dialog
title="查看"
:visible.sync="dialogFormVisible"
width="700px"
@close="closeSamplePhoto"
>
<el-form
:model="editParamsForm"
size="small"
label-position="right"
label-width="100px"
>
<el-form-item label="商标:" prop="trademark">
<image-preview
:src="clickNameForm.trademark"
width="150px"
height="150px"
></image-preview>
</el-form-item>
<el-form-item label="样品照片:" prop="samplePhotos">
<image-preview
:src="clickNameForm.samplePhotos"
width="150px"
height="150px"
></image-preview>
</el-form-item>
</el-form>
<div slot="footer" class="dialog-footer">
<el-button @click="dialogFormVisible = false">取 消</el-button>
</div>
</el-dialog>
</page-standard> </page-standard>
</template> </template>
<script> <script>
...@@ -316,6 +347,8 @@ import { ...@@ -316,6 +347,8 @@ import {
export default { export default {
data() { data() {
return { return {
clickNameForm: {},
dialogFormVisible: false,
addLoading: false, addLoading: false,
editFormRules: { editFormRules: {
identificationCode: [ identificationCode: [
...@@ -455,7 +488,13 @@ export default { ...@@ -455,7 +488,13 @@ export default {
this.getList() this.getList()
}, },
loadData() {}, loadData() {},
clickSampleName() {}, clickSampleName(row) {
this.dialogFormVisible = true
this.clickNameForm = row
},
closeSamplePhoto() {
this.clickNameForm = {}
},
handleUpdate(id) { handleUpdate(id) {
selectSampleInfo({ id: id }).then(res => { selectSampleInfo({ id: id }).then(res => {
this.editParamsForm = res.data this.editParamsForm = res.data
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment