落地合伙股东收益体系,并纳入 sheep 用户端源码。

Co-authored-by: Cursor <cursoragent@cursor.com>
这个提交包含在:
chen
2026-09-17 07:47:35 +08:00
父节点 7747dfaa82
当前提交 251d62296e
共有 595 个文件被更改,包括 90234 次插入 和 105 次删除

查看文件

@@ -0,0 +1,60 @@
{include file="/shopro/common/script" /}
<div id="index" class="reward-index panel panel-default panel-intro" v-cloak>
<el-container class="panel-block">
<el-header class="sa-header">
<div class="sa-title sa-flex sa-row-between">
<div class="sa-title-left">
<div class="left-name">日结对账</div>
<div class="sa-flex" style="gap:16px;margin-top:8px;font-size:13px">
<span>昨日单数 {{ state.kpi.yesterday?.order_count || 0 }}</span>
<span>昨日GMV {{ state.kpi.yesterday?.gmv || '0.00' }}</span>
<span>昨日现金 {{ state.kpi.yesterday_cash || '0.00' }}</span>
<span>昨日马豆池 {{ state.kpi.yesterday?.madow_pool || '0' }}</span>
<span>今日单数 {{ state.kpi.today?.order_count || 0 }}</span>
<span>今日现金 {{ state.kpi.today_cash || '0.00' }}</span>
<span>暂停领取 {{ state.kpi.inactive_count || 0 }} 人</span>
</div>
</div>
<div class="sa-title-right">
<el-button class="sa-button-refresh" icon="RefreshRight" @click="getData"></el-button>
</div>
</div>
</el-header>
<el-main class="sa-main">
<el-table height="100%" class="sa-table" :data="state.data" stripe>
<el-table-column prop="settle_date" label="日期" width="120"></el-table-column>
<el-table-column prop="order_count" label="合格单数" min-width="90"></el-table-column>
<el-table-column prop="gmv" label="GMV" min-width="110"></el-table-column>
<el-table-column prop="order_count_n" label="汇率N" min-width="90"></el-table-column>
<el-table-column prop="rate" label="汇率" min-width="120"></el-table-column>
<el-table-column prop="madow_pool" label="马豆池" min-width="120"></el-table-column>
<el-table-column prop="share_user_count" label="马豆人数" min-width="90"></el-table-column>
<el-table-column prop="venue_pool" label="酒道馆奖池" min-width="110"></el-table-column>
<el-table-column prop="venue_user_count" label="馆人数" min-width="80"></el-table-column>
<el-table-column prop="county_pool" label="区县奖池" min-width="110"></el-table-column>
<el-table-column prop="county_user_count" label="县人数" min-width="80"></el-table-column>
<el-table-column prop="voucher_release_total" label="券释放" min-width="100"></el-table-column>
<el-table-column prop="status_text" label="状态" min-width="80">
<template #default="scope">
<span :class="scope.row.status==1 ? 'sa-color--success' : 'sa-color--danger'">
{{ scope.row.status_text }}
</span>
</template>
</el-table-column>
<el-table-column prop="error_msg" label="失败原因" min-width="160"></el-table-column>
<el-table-column label="操作" min-width="140" fixed="right">
<template #default="scope">
<el-button type="primary" link @click="onDetail(scope.row)">明细</el-button>
{if $auth->check('shopro/partner/daily/rerun')}
<el-button type="warning" link @click="onRerun(scope.row)">重跑</el-button>
{/if}
</template>
</el-table-column>
</el-table>
</el-main>
<el-footer class="sa-footer sa-flex sa-row-right">
<sa-pagination v-model="pagination" @pagination-change="getData"></sa-pagination>
</el-footer>
</el-container>
</div>

查看文件

@@ -0,0 +1,97 @@
{include file="/shopro/common/script" /}
<div id="index" class="reward-index panel panel-default panel-intro" v-cloak>
<el-container class="panel-block">
<el-header class="sa-header">
<div class="sa-title sa-flex sa-row-between">
<div class="sa-title-left">
<div class="left-name">收益流水</div>
<sa-filter-condition v-model="state.filter" @filter-delete="onChangeFilter">
</sa-filter-condition>
</div>
<div class="sa-title-right">
<el-button class="sa-button-refresh" icon="RefreshRight" @click="getData"></el-button>
<el-button class="sa-button-refresh" icon="Search" @click="onOpenFilter"></el-button>
{if $auth->check('shopro/partner/reward/export')}
<el-button :loading="exportLoading" :disabled="exportLoading" @click="onExport('export')">导出
</el-button>
{/if}
{if $auth->check('shopro/partner/reward/reissue')}
<el-button type="primary" @click="reissue.visible = true">手工补发</el-button>
{/if}
</div>
</div>
</el-header>
<el-main class="sa-main">
<el-table height="100%" class="sa-table" :data="state.data" stripe>
<el-table-column prop="id" label="ID" min-width="80"></el-table-column>
<el-table-column prop="createtime" label="入账时间" width="172"></el-table-column>
<el-table-column label="受益人" min-width="150">
<template #default="scope">
<sa-user-profile :user="scope.row.user" :id="scope.row.user_id"></sa-user-profile>
</template>
</el-table-column>
<el-table-column label="买家" min-width="150">
<template #default="scope">
<sa-user-profile :user="scope.row.buyer" :id="scope.row.buyer_id"></sa-user-profile>
</template>
</el-table-column>
<el-table-column label="订单" min-width="180">
<template #default="scope">
{{ scope.row.order?.order_sn || scope.row.order_id }}
</template>
</el-table-column>
<el-table-column prop="reward_type_text" label="奖项" min-width="120"></el-table-column>
<el-table-column prop="role_text" label="角色" min-width="80"></el-table-column>
<el-table-column label="金额" min-width="90">
<template #default="scope"> {{ scope.row.amount }} </template>
</el-table-column>
<el-table-column label="马豆" min-width="110">
<template #default="scope"> {{ scope.row.madow }} </template>
</el-table-column>
<el-table-column prop="base_amount" label="基数" min-width="80"></el-table-column>
<el-table-column label="状态" min-width="80">
<template #default="scope">
<span :class="`sa-color--${state.statusStyle[scope.row.status]}`">
{{ scope.row.status_text }}
</span>
</template>
</el-table-column>
<el-table-column prop="formula" label="公式摘要" min-width="200"></el-table-column>
<el-table-column label="操作" min-width="120" fixed="right">
<template #default="scope">
<el-button type="primary" link @click="onViewExt(scope.row)">查看公式</el-button>
{if $auth->check('shopro/partner/reward/back')}
<el-button v-if="scope.row.status==1 && !scope.row.settle_date" type="danger" link
@click="onBack(scope.row)">退回</el-button>
{/if}
{if $auth->check('shopro/partner/reward/back')}
<el-button v-if="scope.row.order_id>0 && scope.row.status==1 && !scope.row.settle_date" type="danger" link
@click="onBackOrder(scope.row)">整单退回</el-button>
{/if}
</template>
</el-table-column>
</el-table>
</el-main>
<el-footer class="sa-footer sa-flex sa-row-right">
<sa-pagination v-model="pagination" @pagination-change="getData"></sa-pagination>
</el-footer>
</el-container>
<sa-filter v-model="state.filter" @filter-change="onChangeFilter"></sa-filter>
<el-dialog v-model="ext.visible" title="公式明细" width="520px">
<pre style="white-space:pre-wrap">{{ ext.text }}</pre>
</el-dialog>
<el-dialog v-model="reissue.visible" title="手工补发" width="480px">
<el-form label-width="90px">
<el-form-item label="用户ID"><el-input v-model="reissue.form.user_id"></el-input></el-form-item>
<el-form-item label="奖项"><el-input v-model="reissue.form.reward_type" placeholder="如 push3"></el-input></el-form-item>
<el-form-item label="金额"><el-input v-model="reissue.form.amount"></el-input></el-form-item>
<el-form-item label="订单ID"><el-input v-model="reissue.form.order_id"></el-input></el-form-item>
<el-form-item label="备注"><el-input v-model="reissue.form.memo" type="textarea"></el-input></el-form-item>
</el-form>
<template #footer>
<el-button @click="reissue.visible=false">取消</el-button>
<el-button type="primary" @click="onReissue">确定</el-button>
</template>
</el-dialog>
</div>

查看文件

@@ -0,0 +1,62 @@
{include file="/shopro/common/script" /}
<div id="index" class="reward-index panel panel-default panel-intro" v-cloak>
<el-container class="panel-block">
<el-header class="sa-header">
<div class="sa-title sa-flex sa-row-between">
<div class="sa-title-left">
<div class="left-name">兑换券计划</div>
</div>
<div class="sa-title-right">
<el-button class="sa-button-refresh" icon="RefreshRight" @click="getData"></el-button>
</div>
</div>
</el-header>
<el-main class="sa-main">
<el-table height="100%" class="sa-table" :data="state.data" stripe>
<el-table-column prop="id" label="ID" width="80"></el-table-column>
<el-table-column label="用户" min-width="150">
<template #default="scope">
<sa-user-profile :user="scope.row.user" :id="scope.row.user_id"></sa-user-profile>
</template>
</el-table-column>
<el-table-column label="订单" min-width="180">
<template #default="scope">
{{ scope.row.order?.order_sn || scope.row.order_id }}
</template>
</el-table-column>
<el-table-column prop="total_amount" label="总额" min-width="90"></el-table-column>
<el-table-column prop="daily_amount" label="每天释放" min-width="90"></el-table-column>
<el-table-column label="进度" min-width="110">
<template #default="scope"> {{ scope.row.released_days }}/{{ scope.row.total_days }} </template>
</el-table-column>
<el-table-column prop="released_amount" label="已释放" min-width="90"></el-table-column>
<el-table-column prop="available" label="可用" min-width="90"></el-table-column>
<el-table-column prop="voucher_used" label="账户已使用" min-width="90"></el-table-column>
<el-table-column prop="voucher_available" label="账户可用" min-width="90"></el-table-column>
<el-table-column prop="start_date" label="开始日" width="120"></el-table-column>
<el-table-column prop="status_text" label="状态" min-width="80"></el-table-column>
<el-table-column label="操作" min-width="140" fixed="right">
<template #default="scope">
<el-button type="primary" link @click="onLogs(scope.row)">释放日志</el-button>
<el-button v-if="scope.row.status==1" type="danger" link @click="onClose(scope.row)">关闭</el-button>
</template>
</el-table-column>
</el-table>
</el-main>
<el-footer class="sa-footer sa-flex sa-row-right">
<sa-pagination v-model="pagination" @pagination-change="getData"></sa-pagination>
</el-footer>
</el-container>
<el-dialog v-model="logs.visible" title="按日释放日志" width="640px">
<div class="mb-2">计划 #{{ logs.plan?.id }} · 用户 {{ logs.plan?.user_id }} · 订单 {{ logs.plan?.order_id }}</div>
<el-table :data="logs.rows" stripe max-height="420">
<el-table-column prop="settle_date" label="日结日" width="120"></el-table-column>
<el-table-column prop="amount" label="释放金额" width="100"></el-table-column>
<el-table-column prop="status_text" label="状态" width="90"></el-table-column>
<el-table-column prop="formula" label="说明" min-width="160"></el-table-column>
<el-table-column prop="createtime" label="时间" width="172"></el-table-column>
</el-table>
<div v-if="!logs.rows.length" style="padding:20px;color:#999;text-align:center">暂无释放记录(次日 00:30 日结后产生)</div>
</el-dialog>
</div>