Initial commit (code only without large binaries)

This commit is contained in:
robin
2026-02-15 18:58:44 +08:00
commit 35df75498f
9442 changed files with 1495866 additions and 0 deletions

View File

@@ -0,0 +1,18 @@
{$layout "layout_popup"}
<h3>创建接收人分组</h3>
<form class="ui form" data-tea-success="success" data-tea-action="$">
<csrf-token></csrf-token>
<table class="ui table definition selectable">
<tr>
<td class="title">分组名称 *</td>
<td>
<input type="text" name="name" maxlength="50" ref="focus"/>
</td>
</tr>
</table>
<submit-btn></submit-btn>
</form>

View File

@@ -0,0 +1,28 @@
{$layout}
{$template "../menu"}
<second-menu>
<menu-item @click.prevent="createGroup">[创建接收人分组]</menu-item>
</second-menu>
<p class="comment" v-if="groups.length == 0">暂时还没有分组。</p>
<table class="ui table selectable celled" v-if="groups.length > 0">
<thead>
<tr>
<th>分组名称</th>
<th class="two wide">状态</th>
<th class="two op">操作</th>
</tr>
</thead>
<tr v-for="group in groups">
<td>{{group.name}}</td>
<td>
<label-on :v-is-on="group.isOn"></label-on>
</td>
<td>
<a href="" @click.prevent="updateGroup(group.id)">修改</a> &nbsp;
<a href="" @click.prevent="deleteGroup(group.id)">删除</a>
</td>
</tr>
</table>

View File

@@ -0,0 +1,33 @@
Tea.context(function () {
this.createGroup = function () {
teaweb.popup(Tea.url(".createPopup"), {
callback: function () {
teaweb.success("保存成功", function () {
teaweb.reload()
})
}
})
}
this.updateGroup = function (groupId) {
teaweb.popup(Tea.url(".updatePopup", {groupId: groupId}), {
callback: function () {
teaweb.success("保存成功", function () {
teaweb.reload()
})
}
})
}
this.deleteGroup = function (groupId) {
teaweb.confirm("确定要删除此分组吗?", function () {
this.$post(".delete")
.params({groupId: groupId})
.success(function () {
teaweb.success("删除成功", function () {
teaweb.reload()
})
})
})
}
})

View File

@@ -0,0 +1,15 @@
{$layout "layout_popup"}
<h3>选择分组</h3>
<table class="ui table definition selectable">
<tr>
<td class="title">选择分组</td>
<td>
<p class="comment" v-if="groups.length == 0">暂时没有可以选择的分组。</p>
<div v-if="groups.length > 0">
<a class="ui label small basic" v-for="group in groups" @click.prevent="selectGroup(group)">{{group.name}}</a>
</div>
</td>
</tr>
</table>

View File

@@ -0,0 +1,10 @@
Tea.context(function () {
this.selectGroup = function (group) {
NotifyPopup({
code: 200,
data: {
group: group
}
})
}
})

View File

@@ -0,0 +1,24 @@
{$layout "layout_popup"}
<h3>修改接收人分组</h3>
<form class="ui form" data-tea-success="success" data-tea-action="$">
<csrf-token></csrf-token>
<input type="hidden" name="groupId" :value="group.id"/>
<table class="ui table definition selectable">
<tr>
<td class="title">分组名称 *</td>
<td>
<input type="text" name="name" maxlength="50" ref="focus" v-model="group.name"/>
</td>
</tr>
<tr>
<td>启用当前分组</td>
<td>
<checkbox name="isOn" value="1" v-model="group.isOn"></checkbox>
</td>
</tr>
</table>
<submit-btn></submit-btn>
</form>