Browse Source

修改体现审核

zs 1 year ago
parent
commit
d92f0b3d26
1 changed files with 4 additions and 0 deletions
  1. 4 0
      src/views/platfinance/withdrawal/index.vue

+ 4 - 0
src/views/platfinance/withdrawal/index.vue

@@ -94,6 +94,8 @@ export default {
     // 查询
     async search({ skip = 0, limit = this.$limit, ...info } = {}) {
       let condition = _.cloneDeep(this.searchForm);
+      // 判断是否是个人店铺查询
+      if (this.user.role.code == 'shopAdmin') info.shop = this.user.shop._id || this.user.shop.id;
       let res = await this.query({ skip, limit, ...condition, ...info });
       if (this.$checkRes(res)) {
         this.$set(this, 'list', res.data);
@@ -116,6 +118,8 @@ export default {
     // 保存
     async onSubmit({ data }) {
       data.exam_time = moment().format('YYYY-MM-DD HH:mm:ss');
+      // 判断是否是个人店铺查询
+      if (this.user.role.code == 'shopAdmin' && !data.shop) data.shop = this.user.shop._id || this.user.shop.id;
       let res;
       if (data.id) res = await this.update(data);
       else res = await this.create(data);