wupengfei
5 天以前 6244c26cd11f6446b39c0ad50c8223b379e5258a
apps/cMiniApp/src/subpackages/task/taskDetail/InnerPage.vue
@@ -129,6 +129,7 @@
} from '@12333/constants';
import { useAccessLogin } from '@/hooks';
import { useTaskInfo } from '@12333/hooks';
import _ from 'lodash';
defineOptions({
  name: 'InnerPage',
@@ -162,20 +163,27 @@
  }
});
const handleApply = useAccessReal(
  async () => {
    try {
      let params: API.ApplyTaskCommand = {
        ids: [id],
      };
      let res = await taskUserServices.applyTask(params);
      if (res) {
        Message.success('报名成功');
        refetch({ type: 'inactive' });
      }
    } catch (error) {}
  },
  { message: '实名成功后才可报名,请前往实名认证' }
const handleApply = _.debounce(
  useAccessReal(
    async () => {
      try {
        let params: API.ApplyTaskCommand = {
          ids: [id],
        };
        let res = await taskUserServices.applyTask(params);
        if (res) {
          Message.success('报名成功');
          refetch({ type: 'inactive' });
        }
      } catch (error) {}
    },
    { message: '实名成功后才可报名,请前往实名认证' }
  ),
  1000,
  {
    leading: true,
    trailing: false,
  }
);
const handleAttention = useAccessLogin(async () => {