You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
shop-pc/pages/order/submit/module/Message.vue

95 lines
1.5 KiB

This file contains ambiguous Unicode characters!

This file contains ambiguous Unicode characters that may be confused with others in your current locale. If your use case is intentional and legitimate, you can safely ignore this warning. Use the Escape button to highlight these characters.

<!--
* @Author: ch
* @Date: 2022-05-08 16:06:28
* @LastEditors: ch
* @LastEditTime: 2022-05-08 16:18:51
* @Description: file content
-->
<template>
<div class="message">
<div class="message--left">
<label>买家留言</label>
<el-input type="textarea" class="textarea" placeholder="填写您想要备注的信息50字以内"
show-word-limit :maxlength="50" v-model="myMsg"/>
</div>
<div>
<p>
<label>商品总额</label>
<b>{{orderInfo.totalAmount}}</b>
</p>
<p>
<label>运费</label>
<b>{{orderInfo.shippingAmount}}</b>
</p>
</div>
</div>
</template>
<script>
export default {
props : {
orderInfo : {
type: Object,
defautl : ()=>({})
},
message : {
type : String,
default : ''
}
},
computed : {
myMsg : {
get(){
return this.message;
},
set(val){
this.$emit('update:message',val)
}
}
}
}
</script>
<style lang="scss" scoped>
.message{
height: 110px;
border: 1px solid #ddd;
border-top: 0;
padding: 20px 40px 20px 20px;
display: flex;
justify-content: space-between;
&--left{
display: flex;
label{
margin: 11px 16px 0 0;
}
}
label{
color: #666;
}
p{
display: flex;
justify-content: space-between;
width: 308px;
margin: 11px 0;
}
}
/deep/ {
.textarea {
display: inline-block;
width: 467px;
textarea{
height: 70px;
background: #f8f8f8;
border: none;
resize:none;
&::placeholder{
color: #999;
font-size: 12px;
}
}
span{
background: #f8f8f8;
}
}
}
</style>