Commit f71c1238 authored by 仇晓婷's avatar 仇晓婷

文档

parent f8132fc0
<template> <template>
<div class="input-code"> <div class="input-code">
<Input v-model="code" clearable> <Input v-model="codeValue" clearable required>
<Button <Button
slot="append" slot="append"
style="width: 95px; text-align: left"
@click="codeClick" @click="codeClick"
>生成编号</Button >生成编号</Button
> >
</Input> </Input>
<!-- <Dropdown placement="bottom-start">
<a href="javascript:void(0)">
<Icon type="ios-arrow-down">55</Icon>
</a>
<DropdownMenu slot="list" @on-click="changeSelect">
<DropdownItem>生成</DropdownItem>
</DropdownMenu>
</Dropdown> -->
</div> </div>
</template> </template>
<script> <script>
...@@ -24,47 +15,47 @@ import Api from "./api"; ...@@ -24,47 +15,47 @@ import Api from "./api";
export default { export default {
data() { data() {
return { return {
code: "", codeValue: "",
select: "", select: "",
}; };
}, },
props: { model: {
value: [String, Number, Array, Object], prop: "value",
clearable: { event: "on-change"
type: Boolean,
default: true,
}, },
props: {
code:{
type:String,
default:""
},
type:{
type:String
}
}, },
mounted() { mounted() { },
this.getSerialcode();
},
methods: { methods: {
// 生成临时编号code // 生成临时编号code
getSerialcode() { getSerialcode() {
Api.serialcode({ Api.serialcode({
code: "", code: this.code,
}).then((r) => { }).then((r) => {
if (r.result) { if (r.result) {
this.code = r.result[0]; this.codeValue = r.result[0];
this.$emit(
"on-change",
this.codeValue
);
} }
}); });
}, },
codeClick() { codeClick() {
this.getSerialcode(); this.getSerialcode();
}, },
// changeSelect(a) {
// console.log(a);
// },
}, },
watch: { watch: {
value(v) { value(v) {
this.code = v; this.codeValue = v;
}, }
code(v) {
if ((v = "")) {
this.select = "";
}
},
}, },
}; };
</script> </script>
......
<template>
<img :src="downUrl + row.img"/>
</template>
<script>
export default {
props:["src",size],
data(){
return {
path:""
}
},
mounted(){
if(this.src){
this.path=downUrl+v
}
},
watch:{
src(v){
if(v){
this.path=downUrl+v
}
}
}
}
</script>
\ No newline at end of file
...@@ -12,6 +12,7 @@ ...@@ -12,6 +12,7 @@
></Input> ></Input>
<InputCode <InputCode
v-if="li.dataType == 0 && li.field == 'code'" v-if="li.dataType == 0 && li.field == 'code'"
code="WORD"
v-model="entity[li.field]" v-model="entity[li.field]"
/> />
<InputNumber <InputNumber
......
...@@ -56,7 +56,7 @@ ...@@ -56,7 +56,7 @@
<img :src="downUrl + row.img" v-if="row.img" /> <img :src="downUrl + row.img" v-if="row.img" />
<!-- onerror="this.src='/imgicon/chan_Pin.png'" --> <!-- onerror="this.src='/imgicon/chan_Pin.png'" -->
<img <img
src="@/assets/imgicon/chan_Pin.png" src="@/assets/images/files_header.png"
v-else v-else
width="100%" width="100%"
height="100%" height="100%"
...@@ -412,7 +412,7 @@ export default { ...@@ -412,7 +412,7 @@ export default {
height: 110px; height: 110px;
.img-i { .img-i {
width: 90px; width: 90px;
background: #eee; // background: #eee;
height: 90px; height: 90px;
img { img {
width: 90px; width: 90px;
......
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