pc 端完成 访客功能

This commit is contained in:
Your Name 2023-01-24 23:57:53 +08:00
parent 9e8a7b68c5
commit 03b492c697
4 changed files with 163 additions and 2 deletions

View File

@ -60,7 +60,7 @@
</div>
<div class="col-sm-2 margin-top">
<div class="form-group text-center">
<a class="col-form-label" style="text-decoration:underline;" @click="_toGo('/#/pages/property/visitUndo')"><span><vc:i18n name="访客审核待办" namespace="newOaWorkflowDoing"></vc:i18n></span><span
<a class="col-form-label" style="text-decoration:underline;" @click="_toGo('/#/pages/property/visitUndo')"><span><vc:i18n name="访客待办" namespace="newOaWorkflowDoing"></vc:i18n></span><span
:class="{'font-red':newOaWorkflowDoingInfo.visitUndoCount>0}">({{newOaWorkflowDoingInfo.visitUndoCount}})</span></a>
</div>
</div>
@ -127,6 +127,11 @@
<a class="col-form-label" style="text-decoration:underline;" @click="_toGo('/#/pages/property/itemReleaseFinish')"><span><vc:i18n name="物品放行已办" namespace="newOaWorkflowDoing"></vc:i18n></span></a>
</div>
</div>
<div class="col-sm-2 margin-top">
<div class="form-group text-center">
<a class="col-form-label" style="text-decoration:underline;" @click="_toGo('/#/pages/property/visitFinish')"><span><vc:i18n name="访客已办" namespace="newOaWorkflowDoing"></vc:i18n></span></a>
</div>
</div>
<div class="col-sm-2 margin-top" v-for="(item,index) in newOaWorkflowDoingInfo.newOaWorkflows">
<div class="form-group text-center">
<a class="col-form-label" style="text-decoration:underline;" @click="_toGoB(item)">{{item.flowName}}<span><vc:i18n name="已办" namespace="newOaWorkflowDoing"></vc:i18n></span></a>

View File

@ -124,7 +124,7 @@
}
vc.http.apiPost(
'/itemRelease.auditUndoItemRelease',
'/visit.auditUndoVisit',
JSON.stringify(_audit), {
emulateJSON: true
},

View File

@ -0,0 +1,87 @@
<div class="animated fadeInRight ecommerce">
<div class="row">
<div class="col-lg-12">
<div class="ibox">
<div class="ibox-title">
<h5><span><vc:i18n name="访客已办单" namespace="visitFinish"></vc:i18n></span></h5>
<div class="ibox-tools" style="top:10px;">
<button type="button" class="btn btn-white btn-sm" v-on:click="vc.goBack()">
<vc:i18n name="返回" namespace="visitFinish"></vc:i18n>
</button>
<button type="button" class="btn btn-primary btn-sm" v-on:click="_queryFinishOrdersMethod()">
<vc:i18n name="刷新" namespace="visitFinish"></vc:i18n>
</button>
</div>
</div>
<div class="ibox-content">
<table class="footable table table-stripped toggle-arrow-tiny" data-page-size="15">
<thead>
<tr>
<th class="text-center">
<span><vc:i18n name="访客ID" namespace="visitFinish"></vc:i18n></span>
</th>
<th class="text-center">
<span><vc:i18n name="访客" namespace="visitFinish"></vc:i18n></span>
</th>
<th class="text-center">
<span><vc:i18n name="业主姓名" namespace="visitFinish"></vc:i18n></span>
</th>
<th class="text-center">
<span><vc:i18n name="来访事由/类型" namespace="visitFinish"></vc:i18n></span>
</th>
<th class="text-center">
<span><vc:i18n name="车牌号" namespace="visitFinish"></vc:i18n></span>
</th>
<th class="text-center">
<span><vc:i18n name="随行人数" namespace="visitFinish"></vc:i18n></span>
</th>
<th class="text-center">
<span><vc:i18n name="创建时间" namespace="visitFinish"></vc:i18n></span>
</th>
<th class="text-center">
<span><vc:i18n name="来访/离开时间" namespace="visitFinish"></vc:i18n></span>
</th>
<th class="text-center">
<span><vc:i18n name="状态" namespace="visitFinish"></vc:i18n></span>
</th>
<th class="text-center"><span><vc:i18n name="操作" namespace="visitFinish"></vc:i18n></span></th>
</tr>
</thead>
<tbody>
<tr v-for="finish in visitFinishInfo.finishs">
<td class="text-center">{{finish.vId}}</td>
<td class="text-center">{{finish.vName}}({{finish.phoneNumber}})/{{finish.visitGender=='0'?'男':'女'}}</td>
<td class="text-center">{{finish.ownerName}}</td>
<td class="text-center">{{finish.visitCase}}({{finish.reasonType == 0 ? '喜事' :
finish.reasonType == 1 ? '白事' : finish.reasonType == 2 ? '其他' : '-'}})
</td>
<td class="text-center">{{finish.carNum}}</td>
<td class="text-center">{{finish.entourage}}</td>
<td class="text-center">{{finish.createTime}}</td>
<td class="text-center">{{finish.visitTime}}<br/>{{finish.departureTime}}</td>
<td class="text-center">{{finish.stateName}}</td>
<td class="text-center">
<div class="btn-group">
<button class="btn-white btn btn-xs"
v-on:click="_openDetail(finish)"><span><vc:i18n name="详情" namespace="visitFinish"></vc:i18n></span>
</button>
</div>
</td>
</tr>
</tbody>
<tfoot>
<tr>
<td colspan="7">
<ul class="pagination float-right"></ul>
</td>
</tr>
</tfoot>
</table>
<!-- 分页 -->
<vc:create path="frame/pagination"></vc:create>
</div>
</div>
</div>
</div>
</div>

View File

@ -0,0 +1,69 @@
/**
审核订单
**/
(function(vc) {
var DEFAULT_PAGE = 1;
var DEFAULT_ROWS = 10;
vc.extends({
data: {
visitFinishInfo: {
finishs: [],
total: 0,
records: 1,
moreCondition: false,
userName: '',
currentUserId: vc.getData('/nav/getUserInfo').userId,
conditions: {
vId: '',
userName: '',
auditLink: '',
},
orderInfo: '',
procure: false,
audit: '1'
}
},
_initMethod: function() {
vc.component._listFinishOrders(DEFAULT_PAGE, DEFAULT_ROWS);
},
_initEvent: function() {
vc.on('pagination', 'page_event', function(_currentPage) {
vc.component._listFinishOrders(_currentPage, DEFAULT_ROWS);
});
},
methods: {
_listFinishOrders: function(_page, _rows) {
$that.visitFinishInfo.audit = '1';
vc.component.visitFinishInfo.conditions.page = _page;
vc.component.visitFinishInfo.conditions.row = _rows;
var param = {
params: vc.component.visitFinishInfo.conditions
};
//发送get请求
vc.http.apiGet('/visit.queryFinishVisit',
param,
function(json, res) {
var _visitFinishInfo = JSON.parse(json);
vc.component.visitFinishInfo.total = _visitFinishInfo.total;
vc.component.visitFinishInfo.records = _visitFinishInfo.records;
vc.component.visitFinishInfo.finishs = _visitFinishInfo.data;
vc.emit('pagination', 'init', {
total: vc.component.visitFinishInfo.records,
dataCount: vc.component.visitFinishInfo.total,
currentPage: _page
});
},
function(errInfo, error) {
console.log('请求失败处理');
}
);
},
_queryFinishOrdersMethod: function() {
vc.component._listFinishOrders(DEFAULT_PAGE, DEFAULT_ROWS);
},
_openDetail: function(_item) {
vc.jumpToPage("/#/pages/property/visitDetail?vId=" + _item.vId + "&flowId=" + _item.flowId);
}
}
});
})(window.vc);