Merge remote-tracking branch 'origin/alipayplus_aps' into alipayplus_aps

master
dalong306 3 years ago
commit e893ed3111

@ -5,7 +5,7 @@
<parent> <parent>
<groupId>au.com.royalpay.payment</groupId> <groupId>au.com.royalpay.payment</groupId>
<artifactId>payment-parent</artifactId> <artifactId>payment-parent</artifactId>
<version>2.3.1</version> <version>2.3.2</version>
</parent> </parent>
<modelVersion>4.0.0</modelVersion> <modelVersion>4.0.0</modelVersion>
<artifactId>manage</artifactId> <artifactId>manage</artifactId>

@ -75,6 +75,7 @@ public class ApsNoticeServiceImpl implements ApsNoticeService {
for (JSONObject a : apsNotice) { for (JSONObject a : apsNotice) {
addNoticeCommand.setTitle(a.getString("title")); addNoticeCommand.setTitle(a.getString("title"));
addNoticeCommand.setContent(a.getString("content")); addNoticeCommand.setContent(a.getString("content"));
addNoticeCommand.setCreateTime(a.getDate("create_time"));
codes.add(a.getString("partner_code")); codes.add(a.getString("partner_code"));
} }
addNoticeCommand.setPartnerCodes(codes.toArray(new String[codes.size()])); addNoticeCommand.setPartnerCodes(codes.toArray(new String[codes.size()]));

@ -22,6 +22,8 @@ public class AddNoticeCommand {
private String content; private String content;
private Date createTime;
public ApsNotice saveApsNotice(AddNoticeCommand addNoticeDescriptor, JSONObject manager) { public ApsNotice saveApsNotice(AddNoticeCommand addNoticeDescriptor, JSONObject manager) {
return new ApsNotice() return new ApsNotice()
.setCreateTime(new Date()) .setCreateTime(new Date())

@ -21,7 +21,7 @@
ORDER BY n.create_time DESC ORDER BY n.create_time DESC
</select> </select>
<select id="getApsNotice" resultType="com.alibaba.fastjson.JSONObject"> <select id="getApsNotice" resultType="com.alibaba.fastjson.JSONObject">
SELECT n.title, n.content, c.partner_code SELECT n.title, n.content, c.partner_code, n.create_time
FROM sys_aps_notice n FROM sys_aps_notice n
INNER JOIN sys_aps_notice_clients c ON c.notice_id = n.id INNER JOIN sys_aps_notice_clients c ON c.notice_id = n.id
where n.id = #{id} where n.id = #{id}

@ -12,11 +12,12 @@ define(['angular', 'uiBootstrap', 'uiRouter'], function (angular) {
}); });
}]); }]);
app.controller('ApsKYCCtrl', ['$scope', '$http', '$uibModal', function ($scope, $http, $uibModal) { app.controller('ApsKYCCtrl', ['$scope', '$http', '$uibModal', 'commonDialog', function ($scope, $http, $uibModal, commonDialog) {
var that = $scope var that = $scope
that.params = {}; that.params = {};
that.noticeClients = {}; that.noticeClients = {};
that.showClients = false that.showClients = false
that.selectIndex = -1;
that.loadApsNotice = function (page) { that.loadApsNotice = function (page) {
var params = angular.copy(that.params); var params = angular.copy(that.params);
params.page = page || that.pagination.page || 1; params.page = page || that.pagination.page || 1;
@ -27,13 +28,19 @@ define(['angular', 'uiBootstrap', 'uiRouter'], function (angular) {
} }
that.loadApsNotice(1); that.loadApsNotice(1);
that.stopNotice = function (id) { that.stopNotice = function (id) {
var item = {}; commonDialog.confirm({
item.id = id; title: 'Confirm',
$http.put('/aps/kyc/notice', item).then(function () { content: '你确定禁用该消息推送并且所有关联商户都不会继续推送?'
that.loadApsNotice(); }).then(function () {
}); var item = {};
item.id = id;
$http.put('/aps/kyc/notice', item).then(function () {
that.loadApsNotice();
});
})
}; };
that.getNoticeClients = function (title, id, page) { that.getNoticeClients = function (title, id, page, index) {
that.selectIndex = index
that.showClients = true that.showClients = true
that.clientTitle = title that.clientTitle = title
that.clientId = id; that.clientId = id;
@ -79,22 +86,32 @@ define(['angular', 'uiBootstrap', 'uiRouter'], function (angular) {
}); });
}; };
that.setHandle = function (noticeId, id) { that.setHandle = function (noticeId, id) {
that.item = {}; commonDialog.confirm({
that.item.id = id; title: 'Confirm',
that.item.handle = 1; content: '你确定已经帮助商户支持Alipay+支付?'
$http.put('/aps/kyc/notice/client', that.item).then(function () { }).then(function () {
that.loadApsNoticeClients() that.item = {};
that.loadApsNotice() that.item.id = id;
}); that.item.handle = 1;
$http.put('/aps/kyc/notice/client', that.item).then(function () {
that.loadApsNoticeClients()
that.loadApsNotice()
});
})
}; };
that.stopNoticeClient = function (noticeId, id) { that.stopNoticeClient = function (noticeId, id) {
that.item = {}; commonDialog.confirm({
that.item.id = id; title: 'Confirm',
that.item.isValid = 1; content: '你确定不再通知商户该消息?'
$http.put('/aps/kyc/notice/client', that.item).then(function () { }).then(function () {
that.loadApsNoticeClients() that.item = {};
that.loadApsNotice() that.item.id = id;
}); that.item.isValid = 1;
$http.put('/aps/kyc/notice/client', that.item).then(function () {
that.loadApsNoticeClients()
that.loadApsNotice()
});
})
} }
}]); }]);
app.controller('addApsNoticeCtrl', ['$scope', '$http', function ($scope, $http) { app.controller('addApsNoticeCtrl', ['$scope', '$http', function ($scope, $http) {

@ -24,7 +24,6 @@
<tr> <tr>
<th>通知时间</th> <th>通知时间</th>
<th>通知标题</th> <th>通知标题</th>
<th>通知内容</th>
<th>通知商户数</th> <th>通知商户数</th>
<th>未读数</th> <th>未读数</th>
<th>同意数</th> <th>同意数</th>
@ -33,24 +32,22 @@
</tr> </tr>
</thead> </thead>
<tbody> <tbody>
<tr ng-repeat="item in apply"> <tr ng-repeat="(index,item) in apply">
<td>{{ item.createTime }}</td> <td ng-style="{'background-color':selectIndex==index?'#f06101 ':''}">{{ item.createTime }}
<td>{{ item.title }}</td>
<td style="width: 300px;">
<div style="max-width: 300px;overflow: hidden;text-overflow: ellipsis;white-space: nowrap">
{{ item.content }}
</div>
</td> </td>
<td>{{ item.clientsNum }} <td ng-style="{'background-color':selectIndex==index?'#f06101 ':''}">{{ item.title }}</td>
<td ng-style="{'background-color':selectIndex==index?'#f06101 ':''}">{{ item.clientsNum }}
<a href="" type="button"> <a href="" type="button">
<i class="fa fa-bars" aria-hidden="true" <i class="fa fa-bars" aria-hidden="true"
ng-click="getNoticeClients(item.title,item.id,1)"></i> ng-click="getNoticeClients(item.title,item.id,1,index)"></i>
</a> </a>
</td> </td>
<td>{{ item.noRead }}</td> <td ng-style="{'background-color':selectIndex==index?'#f06101 ':''}">{{ item.noRead }}</td>
<td>{{ item.agree }}</td> <td ng-style="{'background-color':selectIndex==index?'#f06101 ':''}">{{ item.agree }}</td>
<td>{{ item.handleNum }}</td> <td ng-style="{'background-color':selectIndex==index?'#f06101 ':''}">{{ item.handleNum }}
<td style="text-align: center"> </td>
<td ng-style="{'background-color':selectIndex==index?'#f06101 ':''}"
style="text-align: center">
<a href="" type="button"> <a href="" type="button">
<i ng-if="item.status == 0" class="fa fa-times" style="color: red" <i ng-if="item.status == 0" class="fa fa-times" style="color: red"
ng-click="stopNotice(item.id)">&nbsp;禁用</i> ng-click="stopNotice(item.id)">&nbsp;禁用</i>
@ -106,15 +103,15 @@
<td>{{item.partner_code}}</td> <td>{{item.partner_code}}</td>
<td style="text-align: center"> <td style="text-align: center">
<span ng-if="item.status == 0" style="color: black">未读</span> <span ng-if="item.status == 0" style="color: black">未读</span>
<span ng-if="item.status == 1" style="color: #c09d03">已读</span> <span ng-if="item.status == 1" style="color: #c09d03">已读({{ item.read_time }})</span>
<span ng-if="item.status == 2" style="color: #00a65a">同意</span> <span ng-if="item.status == 2" style="color: #00a65a">同意({{ item.status_time }})</span>
<span ng-if="item.status == 3" style="color: red">拒绝</span> <span ng-if="item.status == 3" style="color: red">拒绝({{ item.status_time }})</span>
</td> </td>
<td style="text-align: center"> <td style="text-align: center">
<a href="" type="button"><span ng-if="item.handle == 0">未处理 | <i class="fa fa-check" <a href="" type="button"><span ng-if="item.handle == 0">未处理 | <i class="fa fa-check"
aria-hidden="true" aria-hidden="true"
ng-click="setHandle(item.notice_id,item.id)"></i></span></a> ng-click="setHandle(item.notice_id,item.id)"></i></span></a>
<span ng-if="item.handle == 1" style="color: #00a65a">已处理</span> <span ng-if="item.handle == 1" style="color: #00a65a">已处理({{ item.modify_time }})</span>
</td> </td>
<td style="text-align: center"> <td style="text-align: center">
<a href="" type="button"> <a href="" type="button">

@ -1,51 +1,37 @@
<section class="content-header"> <div class="modal-header bg-green" style="text-align: center">
<h1>A+KYC通知详情</h1> <h4>{{ noticeDetail.title }}</h4>
</section> <span>({{ noticeDetail.createTime }})</span>
<div class="content"> </div>
<div class="modal-body" style="padding: 20px">
<div class="row"> <div class="row">
<div class="col-sm-12"> <div class="col-xs-12">
<div class="form-horizontal"> <div class="form-horizontal">
<div class="form-group"> <div class="form-group">
<label class="control-label col-sm-2">* 商户编码</label> <div class="col-xs-12">
<div class="col-xs-10" style="margin-top: 7px"> <div id="input"></div>
<textarea
rows="5"
style="width: 100%;resize:none;"
required
ng-model="noticeDetail.partnerCodes">
</textarea>
</div>
</div>
<div class="form-group">
<label class="control-label col-sm-2">* 通知标题</label>
<div class="col-xs-10" style="margin-top: 7px">
<span>{{ noticeDetail.title }}</span>
</div>
</div>
<div class="form-group">
<label class="control-label col-sm-2">* 通知内容</label>
<div class="col-xs-10" style="margin-top: 7px">
<div style="border:1px solid #000000" id="input"></div>
</div> </div>
</div> </div>
</form>
</div> </div>
</div> </div>
</div> </div>
<br/>
<br/>
<div>
<div>已通知商户:</div>
<textarea
rows="3"
style="width: 100%;resize:none;"
ng-model="noticeDetail.partnerCodes"></textarea>
</div>
</div> </div>
<div class="modal-footer"> <div class="modal-footer">
<div class="margin-bottom margin-top" style="text-align: right"> <button class="btn btn-danger" type="button" ng-click="$dismiss()">关闭</button>
<a role="button"
style="margin-left: 10px;"
ng-click="$dismiss()"
class="btn btn-danger">cancel
</a>
</div>
</div> </div>

Loading…
Cancel
Save