日常提交
This commit is contained in:
parent
5b2b2e0c78
commit
26069d6f4d
@ -51,7 +51,21 @@ Component({
|
|||||||
},
|
},
|
||||||
show:{
|
show:{
|
||||||
type:Boolean,
|
type:Boolean,
|
||||||
value:false
|
value:false,
|
||||||
|
observer(show){
|
||||||
|
if(show){
|
||||||
|
const windowInfo = wx.getWindowInfo();
|
||||||
|
this.createSelectorQuery().select('#modalViewMain').boundingClientRect((res)=>{
|
||||||
|
const viewHeight = res.height;
|
||||||
|
this.setData({
|
||||||
|
dynamicsStyle:`top:${(windowInfo.windowHeight-viewHeight)/2}px;height:${viewHeight}px;`
|
||||||
|
})
|
||||||
|
}).exec();
|
||||||
|
}
|
||||||
|
this.setData({
|
||||||
|
_show:show
|
||||||
|
})
|
||||||
|
}
|
||||||
},
|
},
|
||||||
overlayClose:{
|
overlayClose:{
|
||||||
type:Boolean,
|
type:Boolean,
|
||||||
@ -60,7 +74,15 @@ Component({
|
|||||||
showCloseButton:{
|
showCloseButton:{
|
||||||
type:Boolean,
|
type:Boolean,
|
||||||
value:false
|
value:false
|
||||||
}
|
},
|
||||||
|
autoFocus:{
|
||||||
|
type:Boolean,
|
||||||
|
value:false
|
||||||
|
},
|
||||||
|
useInput:{
|
||||||
|
type:Boolean,
|
||||||
|
value:false
|
||||||
|
},
|
||||||
},
|
},
|
||||||
/**
|
/**
|
||||||
* 组件的初始数据
|
* 组件的初始数据
|
||||||
@ -112,21 +134,5 @@ Component({
|
|||||||
attached(){
|
attached(){
|
||||||
console.log('init model view');
|
console.log('init model view');
|
||||||
}
|
}
|
||||||
},
|
|
||||||
observers:{
|
|
||||||
"show"(show){
|
|
||||||
if(show){
|
|
||||||
const windowInfo = wx.getWindowInfo();
|
|
||||||
this.createSelectorQuery().select('#modalViewMain').boundingClientRect((res)=>{
|
|
||||||
const viewHeight = res.height;
|
|
||||||
this.setData({
|
|
||||||
dynamicsStyle:`top:${(windowInfo.windowHeight-viewHeight)/2}px;height:${viewHeight}px;`
|
|
||||||
})
|
|
||||||
}).exec();
|
|
||||||
}
|
|
||||||
this.setData({
|
|
||||||
_show:show
|
|
||||||
})
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
@ -11,7 +11,9 @@
|
|||||||
<view class="close-btn" bind:tap="cancelButtonTap" wx:if="{{showCloseButton}}"></view>
|
<view class="close-btn" bind:tap="cancelButtonTap" wx:if="{{showCloseButton}}"></view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<textarea class="textarea {{contentMessage?'error':''}}" model:value="{{content}}" row="3" wx:if="{{editable}}"
|
<input wx:if="{{editable&&useInput}}" model:value="{{content}}"
|
||||||
|
focus="{{show&&autoFocus}}"/>
|
||||||
|
<textarea class="textarea {{contentMessage?'error':''}}" model:value="{{content}}" row="3" wx:elif="{{editable}}" focus="{{show&&autoFocus}}"
|
||||||
placeholder="{{contentPlaceholder}}" focus="{{contentFocus}}" animation="{{contentAnimation}}" cursor-spacing="200rpx"></textarea>
|
placeholder="{{contentPlaceholder}}" focus="{{contentFocus}}" animation="{{contentAnimation}}" cursor-spacing="200rpx"></textarea>
|
||||||
<view class="text" wx:else>{{content}}</view>
|
<view class="text" wx:else>{{content}}</view>
|
||||||
|
|
||||||
|
|||||||
@ -100,6 +100,10 @@
|
|||||||
<view class="key">取件数量</view>
|
<view class="key">取件数量</view>
|
||||||
<view class="value">{{orderDetail.package_count}}</view>
|
<view class="value">{{orderDetail.package_count}}</view>
|
||||||
</view>
|
</view>
|
||||||
|
<view class="row">
|
||||||
|
<view class="key">加价金额</view>
|
||||||
|
<view class="value money money-normal">{{orderDetail.additional_fee_amount}}</view>
|
||||||
|
</view>
|
||||||
<view class="row">
|
<view class="row">
|
||||||
<view class="key">订单金额</view>
|
<view class="key">订单金额</view>
|
||||||
<view class="value money money-normal">{{orderDetail.original_amount}}</view>
|
<view class="value money money-normal">{{orderDetail.original_amount}}</view>
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user