Authored by yyq

Merge branch 'feature/homeInvoice' into release/6.1

... ... @@ -18,7 +18,7 @@ module.exports = class extends global.yoho.BaseModel {
*/
getUserOrders(uid, page, limit, type) {
let options = {
method: 'app.SpaceOrders.get',
method: 'app.SpaceOrders.list',
uid: uid,
type: type,
page: page,
... ...
... ... @@ -368,7 +368,11 @@ module.exports = class extends global.yoho.BaseModel {
newOrder.payType = _.get(order, 'payment_type');
newOrder.title = _.get(order, 'order_title');
newOrder.invoiceType = '';
newOrder.issueType = _.get(order, 'invoice.issueType', 0) === 1;
let issueType = +_.get(order, 'invoice.issueType');
newOrder.issueType = issueType === 2;
newOrder.invoiceSupplying = issueType === 1;
if (newOrder.issueType) {
newOrder.invoiceType = _.get(order, 'invoice.type', 0) === 2 ? '电子发票' : '纸质发票';
... ...
... ... @@ -97,7 +97,11 @@
{{#if issueType}}
<span class="op-item view-invoice" data-id="{{orderNum}}">查看发票</span>
{{^}}
<span class="op-item supply-invoice" data-id="{{orderNum}}">申请补开</span>
{{#if invoiceSupplying}}
<span class="op-item on-invoice" data-id="{{orderNum}}">开票中</span>
{{^}}
<span class="op-item supply-invoice" data-id="{{orderNum}}">申请补开</span>
{{/if}}
{{/if}}
</div>
</div>
... ...
... ... @@ -7,15 +7,21 @@
margin-bottom: 10px;
}
.operation > .supply-invoice {
display: inline-block;
box-sizing: border-box;
width: 68px;
height: 18px;
border-radius: 5px;
text-align: center;
color: #000;
border: 1px solid #000;
.operation {
> .on-invoice {
color: #999;
}
> .supply-invoice {
display: inline-block;
box-sizing: border-box;
width: 68px;
height: 18px;
border-radius: 5px;
text-align: center;
color: #000;
border: 1px solid #000;
}
}
&.invoice-detail-dialog {
... ...