123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104 |
- <template>
- <u-mask class="productModal" :show="isShow" :mask-click-able="false">
- <view class="product-con">
- <view class="product-main">
- <view v-for="item in list" :key="item.id">22</view>
- </view>
- <view class="product-footer">
- <view class="button-cancel" @click="isShow=false">取消</view>
- <view class="button-confirm" @click="handleConfirm">确定</view>
- </view>
- </view>
- </u-mask>
- </template>
- <script>
- import { queryWaitListByShelfSn } from '@/api/stockCheck'
- export default {
- props: {
- openModal: { // 弹框显示状态
- type: Boolean,
- default: false
- },
- infoData: {
- tyoe: Object,
- default: ()=>{
- return null
- }
- },
- },
- data() {
- return {
- isShow: this.openModal, // 是否打开弹框
- list: []
- }
- },
- methods: {
- // 确认
- handleConfirm(){
-
- },
- // 获取列表数据
- getList(){
- queryWaitListByShelfSn({shelfSn: this.infoData.shelfSn}).then(res => {
- if(res.status == 200){
- this.list = res.data||[]
- }
- })
- }
- },
- watch: {
- // 父页面传过来的弹框状态
- openModal (newValue, oldValue) {
- this.isShow = newValue
- },
- // 重定义的弹框状态
- isShow (newValue, oldValue) {
- if (!newValue) {
- this.$emit('close')
- }else{
- this.getList()
- }
- }
- }
- }
- </script>
- <style lang="scss" scoped>
- .productModal{
- width: 100%;
- height: 100%;
- .text-c{
- text-align: center;
- }
- .product-con{
- width: 78%;
- margin: 55% auto 0;
- background-color: #fff;
- border-radius: 24upx;
- .product-main{
- padding: 60upx 20upx 50upx;
-
- }
- .product-footer{
- font-size: 30upx;
- display: flex;
- justify-content: space-between;
- align-items: center;
- text-align: center;
- border-top: 1upx solid #E5E5E5;
- .button-cancel{
- color: #999;
- border-right: 1upx solid #E5E5E5;
- flex-grow: 1;
- padding: 20upx 0;
- }
- .button-confirm{
- color: #2A86F4;
- flex-grow: 1;
- padding: 20upx 0;
- }
- }
- }
- }
- </style>
|