浏览代码

修改发票管理模块

luobo 4 年之前
父节点
当前提交
e5a8d167ec

+ 2 - 2
WebContent/WEB-INF/view/bus/annual_plan_select.jsp

@@ -46,7 +46,7 @@
 	                { display: '年份', name: 'year',     align: 'center', width: "8%"},
 	                { display: '考核类型', name: 'quarterlyType',     align: 'center', width: "10%",
 	                	render:function(rowdata, rowindex, value, column){
-	                		return "季度考核";
+	                		return "月份考核";
 	                	}
 	                },
 	                { display: '考核方式', name: '',     align: 'center', width: "10%",
@@ -63,7 +63,7 @@
                 	return false;
                 },
                 onDblClickRow:function(rowdata){
-                    if(rowdata.isPlanUser=='yes'){
+                    if(rowdata.orgIsPlanUser=='yes'){
                     	top.document.getElementById("_DialogFrame_a1").contentWindow.document.getElementById('isPlanUser').value='是';
                     }else{
                     	top.document.getElementById("_DialogFrame_a1").contentWindow.document.getElementById('isPlanUser').value='否';

+ 168 - 24
WebContent/WEB-INF/view/bus/invoice-edit.jsp

@@ -24,47 +24,114 @@
     <!--箭头分页start-->
     <script type="text/javascript" src="${ctx}/qui/libs/js/nav/pageArrow.js"></script>
     <!--箭头分页end-->
+    <!-- 日期选择框start -->
+    <script type="text/javascript"
+            src="${ctx}/qui/libs/js/form/datePicker/WdatePicker.js"></script>
+    <!-- 日期选择框end -->
 </head>
 <body>
-<form id="myFormId" action="${ctx}/invoice/editData.do" method="post" target="frmright">
-    <div class="box1" id="formContent" whiteBg="true">
+ <div class="box1" id="formContent" whiteBg="true">
+        <form id="myFormId" action="${ctx}/invoice/editData.do" method="post" >
         <input type="hidden" name="invoiceId" value='${bwp.invoiceId!""}'/>
-        <table class="tableStyle" formMode="transparent">
-            <tr>
-                <td><span class="star">*</span>发票号:</td>
-                <td><input type="text" name="invoiceNumb" value='${bwp.invoiceNumb!""}' datatype="*"/></td>
-            </tr>
+        <input type="hidden" name="invoiceInfo" value='${bwp.invoiceInfo!""}'/>
+
+        <table class="tableStyle" formMode="view">
             <tr>
                 <td><span class="star">*</span>发票代码:</td>
-                <td><input type="text" name="invoiceCode" value='${bwp.invoiceCode!""}' datatype="*"/></td>
+                <td><input type="text" name="invoiceCode" value='${bwp.invoiceCode!""}' datatype="*" autocomplete="off"/></td>
+
+                <td><span class="star">*</span>发票号:</td>
+                <td><input type="text" name="invoiceNumb" value='${bwp.invoiceNumb!""}' datatype="*" autocomplete="off"/></td>
+
             </tr>
-            <tr>
-                <td>金额:</td>
-                <td><input type="text" name="amountMoney" value='${bwp.amountMoney!""}' /></td>
+            <tr >
+                <td><span class="star">*</span>发票抬头:</td>
+                <td colspan="3"><input style="width: 75%" type="text" name="orgName" value='${bwp.orgName!""}' autocomplete="off" datatype="*"/></td>
             </tr>
             <tr>
-                <td>开票信息:</td>
-                <td><textarea name="invoiceInfo">${bwp.invoiceInfo!""}</textarea></td>
+                <td><span class="star">*</span>纳税人识别号:</td>
+                <td colspan="3"><input style="width: 75%" type="text" name="taxpayerNumber" value='${bwp.taxpayerNumber!""}' autocomplete="off" datatype="*"/></td>
             </tr>
             <tr>
-                <td>发票状态:</td>
-                <td><select prompt="请选择" id="state"
-                            data='{"list":[{"value":"1","key":"冲红机制"},{"value":"0","key":"发票作废"}]}'
-                            name="state"></select></td>
+                <td>总金额:</td>
+                <td><input type="text" name="totalAmount" value='${bwp.totalAmount!""}' autocomplete="off" /></td>
+                <td>税额:</td>
+                <td><input type="text" name="taxAmount" value='${bwp.taxAmount!""}' autocomplete="off" /></td>
             </tr>
+
             <tr>
-                <td>备注:</td>
-                <td><textarea name="remark">${bwp.remark!""}</textarea></td>
+                <td>开票时间:</td>
+                <td><input type="text" class="date" dateFmt="yyyy-MM-dd" id="billingTimeStr" autocomplete="off" name="billingTimeStr" value='${bwp.billingTime!""?string("yyyy-MM-dd")}' /></td>
+                <td>开票人:</td>
+                <td><input type="text" name="billingUser" value='${bwp.billingUser!""}' autocomplete="off"/></td>
             </tr>
             <tr>
-                <td colspan="2">
-                    <input type="submit" value="提交"/>
-                    <input type="button" value="取消" onclick="top.Dialog.close()"/>
+                <td>发票状态:</td>
+                <td><select name="state"
+                            data='{"list":[{"value":"1","key":"正常"},{"value":"2","key":"作废"}]}'
+                    selectedValue='${bwp.state!""}'></select>
                 </td>
+                <td>备注:</td>
+                <td ><textarea rows="2" name="remark">${bwp.remark!""}</textarea></td>
             </tr>
         </table>
-    </div>
-</form>
+            <div class="right">
+                <div class="padding_top5 padding_left10">
+                    <a href="#" onclick="addRow()"><span class="icon_add">添加</span></a>
+                    <div class="box_tool_line"></div>
+                    <a href="#" onclick="delRow()"><span class="icon_delete">删除</span></a>
+                    <div class="box_tool_line"></div>
+                    <a href="#" onclick="save()"><span class="icon_save">保存</span></a>
+                    <div class="box_tool_line"></div>
+                    <a href="#"  onclick="top.Dialog.close()"><span class="icon_back">退出</span></a>
+                    <div class="clear"></div>
+
+
+                </div>
+            </div>
+        </form>
+
+
+                <table id="invoiceInfoTab" class="tableStyle" useCheckBox="false">
+                    <thead>
+                        <th width="5%"></th>
+                        <th width="25%">名称</th>
+                        <th width="10%">规格</th>
+                        <th width="10%">单位</th>
+                        <th width="10%">数量</th>
+                        <th width="10%">单价</th>
+                        <th width="10%">金额</th>
+                        <th width="10%">税率(%)</th>
+                        <th width="10%">税费</th>
+
+                    </thead>
+                    <tbody>
+                    [#if bwp.infoList??]
+                    [#assign size=1]
+                    [#list bwp.infoList as bs]
+                    [#if bs??]
+                    <tr>
+                        <td width="5%"><input type='checkbox' name='infoCk'/></td>
+                        <td width="25%"><input type='text' name='name' value='${bs.name!"" }' style='width:95%;'/></td>
+                        <td width="10%"><input type='text' name='specs' value='${bs.specs!"" }' style='width:95%;'/></td>
+                        <td width="10%"><input type='text' name='unit' value='${bs.unit!"" }' style='width:95%;'/></td>
+                        <td width="10%"><input type='number' name='number' value='${bs.number!"" }' style='width:95%;'/></td>
+                        <td width="10%"><input type='number' name='price' value='${bs.price!"" }' style='width:95%;'/></td>
+                        <td width="10%"><input type='number' name='amount' value='${bs.amount!"" }' style='width:95%;'/></td>
+                        <td width="10%"><input type='number' name='taxRate' value='${bs.taxRate!"" }' style='width:95%;'/></td>
+                        <td width="10%"><input type='number' name='taxAmount' value='${bs.taxAmount!"0" }' style='width:95%;'/></td>
+                    </tr>
+
+                    [/#if]
+
+                    [#assign size=size+1]
+                    [/#list]
+                    [/#if]
+                    </tbody>
+                </table>
+
+
+</div>
 <!-- 异步提交start -->
 <script type="text/javascript">
     function initComplete(){
@@ -103,6 +170,83 @@
         //关闭窗口
         top.Dialog.close();
     }
+
+    var j=1;
+    //添加行
+    function addRow(){
+
+
+        //名称
+        var val0="<td width='5%'><input type='checkbox' name='infoCk' value='"+j+"'/></td>";
+        var val1="<td width='25%'><input type='text' name='name' value='' style='width:95%;' autocomplete='off' /></td>";
+        //规格<t</td>"; width="10%"
+        var val2="<td width='10%'><input type='text' name='specs' value='元/m³' style='width:95%;' autocomplete='off'/></td>";
+        //单位<t</td>"; width="10%"
+        var val3="<td width='10%'><input type='text' name='unit' value='m³' style='width:95%;' autocomplete='off'/></td>";
+        //数量<t</td>"; width="10%"
+        var val4="<td width='10%'><input type='number' name='number' value='' style='width:95%;' autocomplete='off'/></td>";
+        //单价<t</td>"; width="10%"
+        var val5="<td width='10%'><input type='number' name='price' value='' style='width:95%;' autocomplete='off'/></td>";
+        //金额<t</td>"; width="10%"
+        var val6="<td width='10%'><input type='number' name='amount' value='' style='width:95%;' autocomplete='off'/></td>";
+        var val7="<td width='10%'><input type='number' name='taxRate' value='' style='width:95%;' autocomplete='off'/></td>";
+        var val8="<td width='10%'><input type='number' name='taxAmount' value='' style='width:95%;' autocomplete='off'/></td>";
+
+        var $tr=$("<tr>"+val0+val1+val2+val3+val4+val5+val6+val7+val8+"</tr>");
+
+        $("#invoiceInfoTab tbody").append($tr);
+        j++;
+
+        //重新渲染表格
+        $("#invoiceInfoTab").render();
+    }
+
+
+    //删除行
+    function delRow(){
+        var cks=$("input[name='infoCk']:checked");
+        if(cks.length==0){
+            top.Dialog.alert('请选择要删除的行!');
+            return ;
+        }
+        for(var i=cks.length-1;i>=0;i--){
+
+            //删除表单上的行
+            $(cks[i]).parent().parent().remove();
+
+
+        }
+    }
+
+    function save() {
+        //将明细拼接成String
+        var trDate =  $("#invoiceInfoTab tbody ").find("tr");
+        trDate =  Array.from(trDate);
+        var infoList=[];
+        trDate.forEach(function (item,index) {
+            var inputData =  $(item).find("input");
+            inputData =  Array.from(inputData);
+            var data  = {};
+            inputData.forEach(function (value) {
+                var inputItem = $(value);
+                if(inputItem.attr("name")!="infoCk"){
+                    if (inputItem.attr("type") =="number") {
+                        data[inputItem.attr("name")] =Number(inputItem.val());
+                    }else{
+                        data[inputItem.attr("name")] = inputItem.val();
+                    }
+                }
+
+            });
+            infoList.push(data);
+        })
+
+
+        $("input[name='invoiceInfo']").val(JSON.stringify(infoList));
+
+        $("#myFormId").submit();
+    }
+
 </script>
 <!-- 异步提交end -->
 </body>

+ 54 - 17
WebContent/WEB-INF/view/bus/invoice-list.jsp

@@ -33,21 +33,23 @@
             g = $("#maingrid").quiGrid({
                 columns: [
                     // { display: 'id', name: 'invoiceId',  key: true, hidden: true , align: 'center', width: "8%"},
-                    { display: '发票号', name: 'invoiceNumb',     align: 'center', width: "8%"},
-                    { display: '发票代码', name: 'invoiceCode',     align: 'center', width: "8%"},
-                    { display: '金额', name: 'amountMoney',     align: 'center', width: "10%"},
-                    { display: '开票时间', name: 'billingTime',     align: 'center', width: "10%"},
-                    { display: '开票人', name: 'billingUser',     align: 'center', width: "8%"},
-                    { display: '开票信息', name: 'invoiceInfo',     align: 'center', width: "15%"},
+                    { display: '发票代码', name: 'invoiceCode',     align: 'center', width: "10%"},
+                    { display: '发票号', name: 'invoiceNumb',     align: 'center', width: "10%"},
+                    { display: '发票抬头', name: 'orgName',     align: 'center', width: "20%"},
+                    // { display: '纳税人识别号', name: 'taxpayerNumber',     align: 'center', width: "8%"},
+                    { display: '总金额', name: 'totalAmount',     align: 'center', width: "8%"},
+                    { display: '税额', name: 'taxAmount',     align: 'center', width: "8%"},
+                    { display: '开票时间', name: 'billingTime',     align: 'center', width: "8%"},
+                    // { display: '开票人', name: 'billingUser',     align: 'center', width: "8%"},
                     {  display: '发票状态', name: 'state',     align: 'center', width: "8%",
                         render : function(rowdata, rowindex, value, column){
-                            if("0"==value)
-                                return "<font color=red>发票作废</font>";
                             if("1"==value)
-                                return "<font color=blue>冲红机制</font>";
+                                return "<font color=blue>正常</font>";
+                            if("2"==value)
+                                return "<font color=red>作废</font>";
                         }	},
-                    { display: '备注', name: 'remark',     align: 'center', width: "20%"},
-                    { display: '操作', isAllowHide: false, align: 'left', width:"15%",
+                    { display: '备注', name: 'remark',     align: 'center', width: "8%"},
+                    { display: '操作', isAllowHide: false, align: 'left', width:"10%",
                         render: function (rowdata, rowindex, value, column){
                             return '<div class="padding_top4 padding_left20">'
                                 +'<a href="#"  onclick="onEdit(' + rowdata.invoiceId +')"><span class="icon_edit">修改</span></a>'
@@ -62,8 +64,17 @@
                     {line:true}
         ]
         },
-            data:[],rownumbers:true,dataAction:'local',checkbox:false,usePager: false,
-                height: '100%', width:"100%",heightDiff:-40
+            data:[],
+                rownumbers:true,
+                dataAction:'local',
+                checkbox:false,
+                usePager: false,
+                isScroll: true,
+                frozen:false,
+                height: '100%',
+                width:"100%",
+                heightDiff:-40,
+                detail: { onShowDetail: showInfoList, height: 'auto' }
         });
         }
 
@@ -71,6 +82,32 @@
             getData(g_pageNo,g_pageSize);
         });
 
+        function showInfoList(row, detailPanel,callback) {
+            console.log(row)
+            if (row.infoList) {
+               
+                var childGrid = document.createElement('div');
+                $(detailPanel).append(childGrid);
+
+                var childGrid=$(childGrid).css('margin','5px 0px 5px 55px').quiGrid({
+                    columns: [
+                        { display: '名称', name: 'name', align: 'center',width: "20%"},
+                        { display: '规格', name: 'specs', 	 align: 'center',width: "10%"},
+                        { display: '单位', name: 'unit', 	 align: 'center',width: "5%"},
+                        { display: '数量', name: 'number', 	align: 'center',width: "5%"},
+                        { display: '单价', name: 'price', align: 'center',width: "20%"},
+                        { display: '金额', name: 'amount', 	align: 'center',width: "20%"},
+                        { display: '税率(%)', name: 'taxRate', 	align: 'center',width: "10%"},
+                        { display: '税费', name: 'taxAmount', 	align: 'center',width: "10%"}
+
+                    ],
+                    isScroll: false,width: '600px', columnWidth: 120,usePager:false,
+                    data: {rows: row.infoList}
+                });
+            }
+        }
+
+
         /**初始时通过向后台传递排序id、排序顺序、初始页码、每页条数**/
         function getData(pageNo,pageSize){
             jQuery.post("${ctx}/invoice/listPage.do",
@@ -129,8 +166,8 @@
             top.Dialog.open({
                 URL : "${ctx}/invoice/edit.do?invoiceId="+rowId,
                 Title : "编辑发票性质",
-                Width : 500,
-                Height : 320
+                Width : 800,
+                Height : 600
             });
         }
 
@@ -139,8 +176,8 @@
             top.Dialog.open({
                 URL : "${ctx}/invoice/edit.do",
                 Title : "新增发票性质",
-                Width : 500,
-                Height : 320
+                Width : 800,
+                Height : 600
             });
         }
 

+ 21 - 14
WebContent/WEB-INF/view/bus/month-assessment-list.jsp

@@ -155,19 +155,19 @@
                     }],
                 toolbar:{
                     items:[
-                    <@pop_perm url="/monthAssessment/create.do">
-                {text:'新增',click:onCreate,iconClass:'icon_add'},
-        </@pop_perm>
-
-            <@pop_perm url="/monthAssessment/update.do">
-                {line:true},
-                {text:'修改',click:onEdit1, iconClass:'icon_edit'},
-        </@pop_perm>
-
-            <@pop_perm url="/monthAssessment/delete.do">
-                {line:true},
-                {text:'批量删除',click:batchDelete, iconClass:'icon_delete'},
-        </@pop_perm>
+        //             <@pop_perm url="/monthAssessment/create.do">
+        //         {text:'新增',click:onCreate,iconClass:'icon_add'},
+        // </@pop_perm>
+        //
+        //     <@pop_perm url="/monthAssessment/update.do">
+        //         {line:true},
+        //         {text:'修改',click:onEdit1, iconClass:'icon_edit'},
+        // </@pop_perm>
+        //
+        //     <@pop_perm url="/monthAssessment/delete.do">
+        //         {line:true},
+        //         {text:'批量删除',click:batchDelete, iconClass:'icon_delete'},
+        // </@pop_perm>
             <@pop_perm url="/monthAssessment/print.do">
                 {line:true},
                 {text:'打印',click:print, iconClass:'icon_print'},
@@ -176,7 +176,10 @@
                 {line:true},
                 {text:'导出',click:exportExcel, iconClass:'icon_export'},
         </@pop_perm>
-
+            <@pop_perm url="/monthAssessment/print.do">
+                {line:true},
+                {text:'开发票',click:invoice, iconClass:'icon_export'},
+        </@pop_perm>
             <@pop_perm url="/monthAssessment/wx.do">
                 {line:true},
                 {text:'wx',click:wx, iconClass:'icon_export'},
@@ -471,6 +474,10 @@
 
 
         }
+        //开发票
+        function invoice() {
+            console.log("开发票")
+        }
         //修改
         function onEdit(rowId){
 // 		alert(rowId);

+ 23 - 4
src/java/com/bus/model/Invoice.hbm.xml

@@ -17,8 +17,11 @@
       <property name="invoiceCode" type="string">
             <column name="invoice_code" length="64" />
         </property>
-        <property name="amountMoney" type="string">
-            <column name="amount_money" length="64" />
+        <property name="totalAmount" type="java.lang.Float">
+            <column name="total_amount" precision="8" scale="0"/>
+        </property>
+        <property name="taxAmount" type="java.lang.Float">
+            <column name="tax_amount" precision="8" scale="0"/>
         </property>
         
          <property name="billingTime">
@@ -30,12 +33,28 @@
         <property name="invoiceInfo" type="string">
             <column name="invoice_info" length="1024" />
         </property>
-        <property name="state" type="long">
-            <column name="state" length="32" />
+        <property name="state" type="java.lang.Integer">
+            <column name="state" />
         </property>
         <property name="remarks" type="string">
             <column name="remarks" length="1024" />
         </property>
 
+        <property name="orgName" type="string">
+            <column name="org_name" length="255" />
+        </property>
+
+        <property name="taxpayerNumber" type="string">
+            <column name="taxpayer_number" length="255" />
+        </property>
+
+        <property name="bankAccount" type="string">
+            <column name="bank_account" length="255" />
+        </property>
+
+        <property name="addressPhone" type="string">
+            <column name="address_phone" length="255" />
+        </property>
+
     </class>
 </hibernate-mapping>

+ 132 - 23
src/java/com/bus/model/Invoice.java

@@ -1,8 +1,11 @@
 package com.bus.model;
 
 import java.util.Date;
+import java.util.List;
 
 import flexjson.JSON;
+import flexjson.JSONDeserializer;
+import flexjson.JSONSerializer;
 import org.joda.time.DateTime;
 
 /**
@@ -20,8 +23,11 @@ public class Invoice {
     /**发票代码**/
     private String invoiceCode;
 
-    /**金额**/
-    private String amountMoney;
+    /**总金额**/
+    private Float totalAmount;
+
+    /**税额**/
+    private Float taxAmount;
 
     /**开票时间**/
     private Date billingTime;
@@ -32,17 +38,30 @@ public class Invoice {
     /**开票信息**/
     private String invoiceInfo;
 
-    /**发票状态**/
-    private Long state;
+    private List<InvoiceInfo> infoList;
+
+    /**发票状态(1、正常 2、作废)**/
+    private Integer state;
 
     /**备注**/
     private String remarks;
+    /**
+     * 发票抬头(购买方名称)
+     */
+    private String orgName;
+    /**
+     * 纳税人识别号
+     */
+    private String taxpayerNumber;
+    /**
+     * 开户行及账号
+     */
+    private String bankAccount;
+    /**
+     * 地址及电话
+     */
+    private  String addressPhone;
 
-    public String getInvoiceNumb() {
-        return invoiceNumb;
-    }
-
-    public void setInvoiceNumb(String invoiceNumb) { this.invoiceNumb = invoiceNumb; }
 
     public Long getInvoiceId() {
         return invoiceId;
@@ -52,34 +71,124 @@ public class Invoice {
         this.invoiceId = invoiceId;
     }
 
-    public String getInvoiceCode() { return invoiceCode; }
+    public String getInvoiceNumb() {
+        return invoiceNumb;
+    }
+
+    public void setInvoiceNumb(String invoiceNumb) {
+        this.invoiceNumb = invoiceNumb;
+    }
+
+    public String getInvoiceCode() {
+        return invoiceCode;
+    }
+
+    public void setInvoiceCode(String invoiceCode) {
+        this.invoiceCode = invoiceCode;
+    }
 
-    public void setInvoiceCode(String invoiceCode) { this.invoiceCode = invoiceCode; }
+    public Float getTotalAmount() {
+        return totalAmount;
+    }
 
-    public String getAmountMoney() { return amountMoney; }
+    public void setTotalAmount(Float totalAmount) {
+        this.totalAmount = totalAmount;
+    }
 
-    public void setAmountMoney(String amountMoney) { this.amountMoney = amountMoney; }
+    public Float getTaxAmount() {
+        return taxAmount;
+    }
 
-    public Date getBillingTime() { return billingTime; }
+    public void setTaxAmount(Float taxAmount) {
+        this.taxAmount = taxAmount;
+    }
 
-    public void setBillingTime(Date billingTime) { this.billingTime = billingTime; }
 
-    public String getBillingUser() { return billingUser; }
+    public Date getBillingTime() {
+        return billingTime;
+    }
 
-    public void setBillingUser(String billingUser) { this.billingUser = billingUser; }
+    public void setBillingTime(Date billingTime) {
+        this.billingTime = billingTime;
+    }
+
+    public String getBillingUser() {
+        return billingUser;
+    }
 
-    public String getInvoiceInfo() { return invoiceInfo; }
+    public void setBillingUser(String billingUser) {
+        this.billingUser = billingUser;
+    }
 
-    public void setInvoiceInfo(String invoiceInfo) { this.invoiceInfo = invoiceInfo; }
+    public String getInvoiceInfo() {
+        return invoiceInfo;
+    }
 
-    public Long getState() {
+    public void setInvoiceInfo(String invoiceInfo) {
+        this.invoiceInfo = invoiceInfo;
+    }
+
+    public Integer getState() {
         return state;
     }
 
-    public void setState(Long state) { this.state = state; }
+    public void setState(Integer state) {
+        this.state = state;
+    }
 
-    public String getRemarks() { return remarks; }
+    public List<InvoiceInfo> getInfoList() {
+        if (this.invoiceInfo!=null && !this.invoiceInfo.equalsIgnoreCase("") && infoList==null){
+            infoList = new JSONDeserializer<List<InvoiceInfo>>().deserialize(this.invoiceInfo);
+        }
+        return infoList;
+    }
 
-    public void setRemarks(String remarks) { this.remarks = remarks; }
+    public void setInfoList(List<InvoiceInfo> infoList) {
+        if (infoList!=null && infoList.size()>0){
+            this.invoiceInfo = new JSONSerializer().deepSerialize(infoList);
+        }
+        this.infoList = infoList;
+    }
 
+
+
+    public String getRemarks() {
+        return remarks;
+    }
+
+    public void setRemarks(String remarks) {
+        this.remarks = remarks;
+    }
+
+    public String getOrgName() {
+        return orgName;
+    }
+
+    public void setOrgName(String orgName) {
+        this.orgName = orgName;
+    }
+
+    public String getTaxpayerNumber() {
+        return taxpayerNumber;
+    }
+
+    public void setTaxpayerNumber(String taxpayerNumber) {
+        this.taxpayerNumber = taxpayerNumber;
+    }
+
+    public String getBankAccount() {
+        return bankAccount;
+    }
+
+    public void setBankAccount(String bankAccount) {
+        this.bankAccount = bankAccount;
+    }
+
+    public String getAddressPhone() {
+        return addressPhone;
+    }
+
+    public void setAddressPhone(String addressPhone) {
+        this.addressPhone = addressPhone;
+    }
 }

+ 100 - 0
src/java/com/bus/model/InvoiceInfo.java

@@ -0,0 +1,100 @@
+package com.bus.model;
+
+public class InvoiceInfo {
+    /**
+     * 物品名称
+     */
+    private String name;
+    /**
+     * 规格
+     */
+    private String specs;
+    /**
+     * 单位
+     */
+    private String unit;
+    /**
+     * 数量
+     */
+    private Integer number;
+    /**
+     * 单价
+     */
+    private Float price;
+    /**
+     * 金额
+     */
+    private Float amount;
+    /**
+     * 税率
+     */
+    private Integer taxRate;
+    /**
+     * 税费
+     */
+    private Float taxAmount;
+
+    public String getName() {
+        return name;
+    }
+
+    public void setName(String name) {
+        this.name = name;
+    }
+
+    public String getSpecs() {
+        return specs;
+    }
+
+    public void setSpecs(String specs) {
+        this.specs = specs;
+    }
+
+    public String getUnit() {
+        return unit;
+    }
+
+    public void setUnit(String unit) {
+        this.unit = unit;
+    }
+
+    public Integer getNumber() {
+        return number;
+    }
+
+    public void setNumber(Integer number) {
+        this.number = number;
+    }
+
+    public Float getPrice() {
+        return price;
+    }
+
+    public void setPrice(Float price) {
+        this.price = price;
+    }
+
+    public Float getAmount() {
+        return amount;
+    }
+
+    public void setAmount(Float amount) {
+        this.amount = amount;
+    }
+
+    public Integer getTaxRate() {
+        return taxRate;
+    }
+
+    public void setTaxRate(Integer taxRate) {
+        this.taxRate = taxRate;
+    }
+
+    public Float getTaxAmount() {
+        return taxAmount;
+    }
+
+    public void setTaxAmount(Float taxAmount) {
+        this.taxAmount = taxAmount;
+    }
+}

+ 11 - 2
src/java/com/bus/web/InvoiceController.java

@@ -3,6 +3,7 @@ package com.bus.web;
 import com.bus.model.Invoice;
 import com.bus.service.InvoiceService;
 import com.core.dao.util.Updater;
+import com.core.util.DateUtil;
 import com.core.web.BaseController;
 import com.core.web.query.QueryFilter;
 import com.core.web.security.ContextUtil;
@@ -68,13 +69,21 @@ public class InvoiceController extends BaseController {
 
     /**
      * 编辑发票信息
-     * @param role
+     * @param
      * @return
      */
     @RequestMapping("editData.do")
     @ResponseBody
-    public Object editData(Invoice bwp,ModelMap model){
+    public Object editData(Invoice bwp,String billingTimeStr,ModelMap model){
         try {
+
+            if (billingTimeStr!=null && !billingTimeStr.equalsIgnoreCase("")){
+                billingTimeStr = billingTimeStr.split(" ")[0];
+              Date  billingTime = DateUtil.parseDate(billingTimeStr,new String[]{"yyyy-MM-dd"});
+                bwp.setBillingTime(billingTime);
+            }
+
+
             if(bwp.getInvoiceId()!=null){
                 Updater<Invoice> updater = new Updater<Invoice>(bwp);
                 invoiceService.updateByUpdater(updater);