<!-- 资源管理 -->
<template>
  <view>
    <button class="text-xs bg-blue-500 text-white leading-6" style="width: 500rpx" @click="openSourceManage">资源管理</button>
  </view>
</template>

<script setup>
import { inject } from 'vue';
import useGenerateWebviewParam from '@/hooks/project/useGenerateWebviewParam';

const task = inject('task');
const { projectId, projectName, token } = useGenerateWebviewParam();

function openSourceManage() {
  uni.$ui.openDetail({
    url: `http://121.36.3.207/finance/index?name=资源管理&token=${token}&projectId=${projectId}&id=${task.id}&pn=${projectName}&tn=${task.name}`,
    name: '资源管理',
  });
}
</script>
