#
whycq
2023-03-20 eabfdea3f6f37bdcc63d79dccd062210d345d5c2
pages/pakin/pakin.vue
@@ -47,7 +47,7 @@
            </view>
            <view class="list-right">
               <uni-icons type="compose" color="#c1c1c1" size="24" @click="revise(item,i)"></uni-icons>
               <uni-icons type="trash" color="#c1c1c1" size="24" @click="remove(item,i)"></uni-icons>
               <uni-icons type="trash" color="#c1c1c1" size="24" @click="remove(item,i,'warn')"></uni-icons>
            </view>
         </view>
      </scroll-view>
@@ -80,6 +80,14 @@
            </view>
         </uni-popup>
      </view>
      <!-- 删除确认 -->
      <view>
         <!-- 提示窗示例 -->
         <uni-popup ref="alertDialog" type="dialog">
            <uni-popup-dialog :type="msgType" title="通知" content="是否删除当前商品!" @confirm="removeConfirm"
               @close="removeClose"></uni-popup-dialog>
         </uni-popup>
      </view>
   </view>
</template>
@@ -87,7 +95,9 @@
   export default {
      data() {
         return {
            dataList: [{
            dataList:
            [
            {
               matnr: "whycq19950222222-232321111",
               maktx: "wusuowei",
               specs: "个",
@@ -133,7 +143,8 @@
            ],
            count: 0,
            rowNum: '',
            batch: ''
            batch: '',
            msgType: 'success',
         }
      },
      onLoad() {
@@ -151,8 +162,17 @@
            this.$refs.revise.open(type)
         },
         // 列表删除按钮
         remove(item,index) {
            this.dataList.splice(index,1)
         remove(item,i,type) {
            this.msgType = type
            this.$refs.alertDialog.open(i)
         },
         // 确认删除
         removeConfirm(i) {
            this.dataList.splice(i,1)
         },
         // 取消删除
         removeClose() {
            this.$refs.alertDialog.close()
         },
         confirm() {
            this.dataList[this.rowNum].anfme = this.count