/** * 开票信息详情 * */ $(function() { // //获取所属行业//获取税务类别//获取客户信誉等级 // $.when(helper.getDropList.getlistDropByDic($('#customer_subtrade'), 'KHSSHY'), // helper.getDropList.getlistDropByDic($('#customer_taxCategory'), 'SWLB'), // helper.getDropList.getlistDropByDic($('#customer_layer'), 'KHLayer')) // .done(function() { var edit_id = helper.request.queryString("edit_id"); if (edit_id) { getCustomer(edit_id); } // }); }); //获取详情 function getCustomer(ids) { $.getJSON(huayi.config.callcenter_url + "WoBill/GetBill", { billid: ids, //id token: $.cookie("token") }, function(data) { if (data.state.toLowerCase() == "success") { var dealnames = data.data.dealname; var res = data.data.dModel; if (res) { $('#F_BillType').text(res.F_BillType);// string 发票类型 $('#F_CusName').text(res.F_CusName);// string 客户名称 $('#F_TaxIDNum').text(res.F_TaxIDNum);// string 纳税人识别号 $('#F_Address').text(res.F_Address);// string 地址 // $('#F_Phone').text(helper.filter.cutTel(res.F_Phone));// string 电话 $('#F_Phone').text(res.F_Phone);// string 电话 $('#F_Bank').text(res.F_Bank);// string 开户行 $('#F_BankAccount').text(res.F_BankAccount);// string 开户行账号 $('#F_ProName').text(res.F_ProName);// string 项目名称 $('#F_Models').text(res.F_Models);// string 型号 $('#F_Unit').text(res.F_Unit);// string 单位 $('#F_Amount').text(res.F_Amount);// string 数量 $('#F_UnitPrice').text(res.F_UnitPrice);// string 单价 $('#F_SumPrice').text(res.F_SumPrice);// string 金额 $('#F_TaxRate').text(res.F_TaxRate);// string 税率 $('#F_TaxAmount').text(res.F_TaxAmount);// string 税额 $('#F_State').text(formatterState(res.F_State));// F_State 是否开票 0否1是 $('#F_BillingMethod').text(res.F_BillingMethod);// string 开票方式:快递/自取 $('#F_BillingTime').text(res.F_BillingTime);//string 开票时间 $('#F_remark').html(helper.filter.content(res.F_Remark));// string 备注 if (dealnames){ $('#dealname').text(dealnames + '(' + res.F_DealBy + ')');//处理人 } if(res.F_DealOn){ $('#F_DealOn').text(res.F_DealOn);//处理时间 } if (res.F_DealROn){ $('#F_DealROn').text(res.F_DealROn);//接收时间 } if (res.F_DealContent){ $('#F_DealContent').html(helper.filter.content(res.F_DealContent));//处理备注信息 } } } }); } //格式化是否开票 function formatterState(val) { var str = '否'; if (val === 1) { str = '是'; } return str; }