包含税号的页面

<%@ page contentType="text/html; charset=GBK"%>
<%@page import="com.sytax.xxfb.xxfbForm"%>
<%@page import="com.sytax.xxfb.xxfbCtrl"%>
<%@page import="java.util.ArrayList"%>
<%@ include file="/global.jsp" %>
<%@ page import ="com.sytax.oa.zixun.*" %>
<%@ taglib uri="/WEB-INF/struts-bean.tld" prefix="bean"%>
<%@ taglib uri="/WEB-INF/struts-html.tld" prefix="html"%>
<%@ taglib uri="/WEB-INF/struts-logic.tld" prefix="logic"%>
<%@page import="com.sytax.oa.menu.function.FunctionForm"%>
<%@page import="com.sytax.oa.menu.function.FunctionCtrl"%>
<%@ page import="java.util.List" %>
<%@ page import="java.util.Map" %>
<%@ page import="com.sytax.global.*" %>
<%
 String intidStr=session.getAttribute("menu_function_intid")!=null?(String)session.getAttribute("menu_function_intid"):"0";
%>
<%
 String path = request.getContextPath();
 String basePath = request.getScheme() + "://"
   + request.getServerName() + ":" + request.getServerPort()
   + path + "/";
%>

 

<script language="javascript">

String.prototype.trim = function()
{
return this.replace(/(^/s*)|(/s*$)/g, '');  

}


function tijiao(){
    document.zixunForm.flag.value=6;
    
   var yhsh=document.getElementById("YHSH").value;
      
   if(isEmpty(yhsh)){
    alert( "纳税税号不能为空");
    return false;
    }
     var gh=document.getElementById("GONGHAO").value;
   if(!(isNumeric(gh))){
   
     alert("工号不能为空且必须为数字");
    return false;
    }
  
    var n=document.getElementById("NEIRONG").value.trim();
     if(isEmpty(n)){
    alert( "咨询内容不能为空");
    return false;
    }
    document.zixunForm.submit();
    
    return true;
}


function searchcp(){
document.zixunForm.flag.value=9;
 var yhsh=document.getElementById("YHSH").value;
   
 if(isEmpty(yhsh)){
    alert( "纳税税号不能为空");
    return false;
    }
 document.zixunForm.action="<%=webPath%>/zixun/zixunAction.do";
    document.zixunForm.submit();
}
function searchxx(){

document.zixunForm.flag.value=7;
 var yhsh=document.getElementById("YHSH").value;
   
 if(isEmpty(yhsh)){
    alert( "纳税税号不能为空");
    return false;
    }
    document.zixunForm.submit();
}
function searchmc(){


document.zixunForm.flag.value=8;
 var yhsh=document.getElementById("YHSH").value;
   
if(isEmpty(yhsh)){
    alert( "纳税税号不能为空");
    return false;
    }
 document.zixunForm.action="<%=webPath%>/zixun/zixunAction.do";
    document.zixunForm.submit();
    
  
}
   function forback(){
   alert("确定要退出吗?");
 document.location.href="<%=webPath%>/yuyuedianhua/hrxx.jsp";
}
</script>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
 <head>
  <base href="<%=basePath%>">

  <title>咨询登记</title>
<meta http-equiv="Content-Type" content="text/html; charset=GBK">

  <meta http-equiv="pragma" content="no-cache">
  <meta http-equiv="cache-control" content="no-cache">
  <meta http-equiv="expires" content="0">
  <meta http-equiv="keywords" content="keyword1,keyword2,keyword3">
  <meta http-equiv="description" content="This is my page">
  
<link href="<%=webPath%>/resources/css/skin/<%=skinStr%>/common.css" rel="stylesheet" type="text/css">
<script language="JavaScript" src="<%=webPath%>/resources/javascript/to_check.js"></script>
<script language="JavaScript" src="<%=webPath%>/resources/javascript/article.js"></script>
<script language="JavaScript" src="<%=webPath%>/resources/javascript/page_goto.js"></script>
<script language="JavaScript" src="<%=webPath%>/resources/javascript/meizzDate.js"></script>
<script language="JavaScript" src="<%=webPath%>/resources/javascript/calendar.js"></script>
<script type="text/javascript" src="<%=webPath%>/resources/javascript/jquery-1.2.1.js"></script>

 </head>

 <body>

  <html:form action="/zixun/zixunAction" method="POST"
    scope="request">
  <html:hidden property="flag" />
   <table height="20"  width ="1100" cellspacing="0"  cellpandding="0"><tr class="bgcolor_detail"><td>&nbsp;</td></tr>
   <tr><td>&nbsp;</td></tr>
   </table>
   <table align="center">
   <tr>
   <td class="border1" width="20%" height="25"><div align="center">
      纳税人税号:
     </td>
      <%String yhsh = session.getAttribute("taxno")!=null?(String)session.getAttribute("taxno"):"";
      String j="";
        if(!"".equals(yhsh)){
        j="disabled";
        }
     
      %>
     <td class="border1" width="30%">
      <input id="YHSH" name="YHSH"  size = "50"
       <%=j %> value="<%=yhsh%>">
       <html:hidden property="YHSH" value="<%=yhsh%>"/>
     </td>
     <td>
     <input type="button" value="纳税人基本信息查询" onClick="searchxx();">
     </td>
   </tr>
   <tr>
     <td class="border1" width="20%" height="25"><div align="center">
      用户名称:
     </td>
     <%String yname=session.getAttribute("dymc")!= null?(String)session.getAttribute("dymc"):"" ;
     
     String jj="";
        if(!"".equals(yname)){
        jj="disabled";
        }
     %>
     <td class="border1" width="30%">
      <input id="YHNAME" name="YHNAME" size = "50"
       <%=jj %> value="<%=yname%>">
       <html:hidden property="YHNAME" value="<%=yname%>"/>
     </td>
     <td>
     <input type="button" value="激费信息查询" onClick="searchmc();">
     </td>
   </tr>
   <tr>
      <td class="border1" width="13%" height="25"><div align="center">
      流水号:
     </td>
    <%String lsh=session.getAttribute("lsh")!= null?(String)session.getAttribute("lsh"):"" ; %> 
     <td class="border1" width="30%">
    
      
            
      <input  disabled type="text"  name="LIUSHUI"  value="<%=lsh%>" size="50"/>
      <html:hidden property="LIUSHUI" value="<%=lsh%>"/>
     </td>
      
      <td class="border1" width="13%" height="25"><div align="center">
      工号:
     </div></td>
     <td class="border1" width="20%">
      <input id="GONGHAO" name="GONGHAO"   size = "50"
       >
     </td>
      </tr>
   
    <tr>
      <td class="border1" width="13%" height="25"><div align="center">
      来电人姓名:
     </td>
     
     <td class="border1" width="20%">
      <input id="XINGMING" name="XINGMING"   size = "50"
       >
     </td>

    
      <td class="border1" width="13%" height="25"><div align="center">
      来电人性别:
     </td>
     <td class="border1" width="30%">
      
      <select name="XINGBIE" >
       <option value="0">&nbsp;男&nbsp;</option>
       <option value="1">&nbsp;女&nbsp;</option>
      </select>
     </td>
     </tr>
   <tr>
   <td class="border1" width="20%" height="25"><div align="center">
      来话人地址:
     </td>
     
     <td class="border">
        <input id="DIZHI" name="DIZHI"  size = "50"
       >
        </td>
   
     <td class="border1" width="13%" height="25"><div align="center">
      来电号码:
     </td>
     <%String phonenum = session.getAttribute("dytel")!=null?(String)session.getAttribute("dytel"):""; %>
     <td class="border1" width="30%">
      <input id="DIANHUA" name="DIANHUA"  size = "50"
       value="<%=phonenum%>">
     </td>
     </tr>
    
     <tr>
           <td class="border1" width="20%" height="25"><div align="center">
      问题处理结果:
     </td>
     
     <td class="border1">
     <select name="DAFU_ZHUANGTAI">
     <option value="0">未处理
     </option>
     <option value="1">已处理
     </option>
     
     
     </select>
     </td>
      <td class="border1" width="20%" height="25"><div align="center">
      咨询分类:
     </td>
     <td class="border1" width="30%">
      
       <select style="width=100%;" name="FenLei" >
        <%
          ZXCtrl zixunCtrl=new ZXCtrl();
          try{
          String[] s=zixunCtrl.getFenlei();
          int i=0;
          while(i<s.length){
           out.println("<option value='"+s[i]+"'>"+s[i+1]+"</option>");
           i=i+2;
          }
          }catch(Exception e){
           e.printStackTrace();
          }
          %>
      </select>
     </td>
    </tr>
    <tr>
          
      <td class="border1" width="20%" height="25"><div align="center">
      受理满意度:
     </td>
     <%String MYD = session.getAttribute("myd")!=null?(String)session.getAttribute("myd"):"";
     
     
     %>
     
     <td class="border1" width="30%">
      
       <select name="SL_MYD" disabled>
       <option value="<%=MYD %>">  <%=MYD %></option>
       
      </select>
      <html:hidden property="SL_MYD" value="<%=MYD%>"/>
     </td>
    
        
     <td class="border1" width="20%" height="25"><div align="center">
      受理时间:
     </td>
         <%String d=session.getAttribute("cjdate")!=null?(String)session.getAttribute("cjdate"):"" ; %>
     <td class="border1">
        <input type="text" name="SLTIME" size = "30"  value="<%=d %>">
        </td>
     </tr>
    <tr>
      <td class="border1" width="20%" height="25"><div align="center">
      备注:
     </td>
     <td class="border1" width="30%">
      <textarea name="BEIZHU" cols=40 rows=6>
   </textarea>
     </td>
    
      <td class="border1" width="20%" height="25" ><div align="center">
      咨询内容:
     </td>
     <td class="border1" width="30%">
      <textarea name="NEIRONG" id="NEIRONG" cols=40 rows=6 ></textarea>
     </td>
    </tr>
    <tr>
          
      <td class="border1" width="20%" height="25"><div align="center">
      是否派单:
     </td>
     <td class="border1" width="30%">
      
       <select name="PD_FALSE">
       <option value="0">&nbsp;是&nbsp;</option>
       <option value="1">&nbsp;否&nbsp;</option>
      </select>
      </td>
      </tr>
    <tr >
      <td colspan="4" align="center">
       <input type="button"  value="&nbsp;通用产品信息&nbsp;" onClick="searchcp();" />
       &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
       <input type="button"  value="&nbsp;保存&nbsp;" onClick="tijiao();" />
       &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
       <input type="button" value="&nbsp;退出&nbsp;" onClick="forback();" />
      </td>
     </tr>
    
   </table>
<table>
<tr><td align = "right">
<font   color="#FF0000"><%=request.getAttribute("listdata")!=null?request.getAttribute("listdata"):""%></font>
</td></tr>
</table>
     
  </html:form>
 </body>
</html>

<template> <view class="fp_content"> <view class="fp_title">开票详情</view> <view class="fp_car"> <view class="shuruc mokuai-duiqi"> <view class="srcengji">*</view> <view class="sfname">抬头类型:</view> <view class="fp_xzc"> <radio-group @change="radioChange" style="display: inline-block;"> <label tyle="margin-left: 15px;"> <radio value="3ZV7RCN4">企业单位</radio> </label> <label style="margin-left: 15px;"> <radio value="3ZV7RCN5" checked="true">个人/非企业</radio> </label> </radio-group> </view> </view> <view class="shuruc mokuai-duiqi"> <view class="srcengji">*</view> <view class="sfname">发票抬头:</view> <input class="fp_xzc" type="text" placeholder="请输入发票抬头" v-model="zcxxObj.rl" /> </view> <view class="shuruc mokuai-duiqi"> <view class="srcengji">*</view> <view class="sfname">税号:</view> <input class="fp_xzc" type="text" placeholder="请输入税号" v-model="zcxxObj.rl" /> </view> <view class="shuruc mokuai-duiqi"> <view class="srcengji">*</view> <view class="sfname">发票内容:</view> <input class="fp_xzc" type="text" placeholder="请输入发票内容" v-model="zcxxObj.rl" /> </view> <view class="shuruc mokuai-duiqi"> <view class="sfname">备注:</view> <input class="fp_xzc" type="text" placeholder="请输入备注" v-model="zcxxObj.rl" /> </view> <view class="shuruc mokuai-duiqi" > <view class="sfname">发票金额:</view> <view class="fp_mount"> 22.22<text style="font-size: 14px;font-weight: 400;">元</text> </view> </view> </view> <view class="fp_title">接收方式</view> <view class="fp_car"> <view class="shuruc mokuai-duiqi"> <view class="srcengji">*</view> <view class="sfname">邮箱地址:</view> <input class="fp_xzc" type="text" placeholder="用来接收发票的邮箱地址" v-model="zcxxObj.rl" /> </view> </view> <view class="btn-view" @click="tijiao"> 申请 </view> </view> </template> <script> export default { data() { return { } }, methods: { } } </script> <style> .fp_title{ font-size: 16px; font-weight: 700; } .fp_content{ padding: 10px; background-color: #f5f5f5; height: 96vh; } .fp_car{ background-color: #fff; border-radius: 4px; margin: 10px 0; } .shuruc { width: 92%; margin: 0 auto; line-height: 96rpx; font-size: 28rpx; border-bottom: 1rpx solid #f4f4f4; } .fp_mount{ font-size: 26px; font-weight: 700; } .sfname { font-weight: 500; width: 46%; } .fp_xzc { width: 85%; flex-direction: row; font-size: 28rpx; text-align: right; color: #7f7f7f; min-height: 96rpx; } .srcengji { width: 3%; color: red; } </style>优化页面,给必填项加上rule规则校验
12-02
以下以 Vue 框架为例,使用 Element UI 组件库实现前端页面代码优化,为抬头类型、发票抬头、税号、发票内容、邮箱地址等必填项添加 rule 规则校验。 ```vue <template> <div> <el-form :model="form" :rules="rules" ref="formRef" label-width="120px"> <el-form-item label="抬头类型" prop="titleType"> <el-select v-model="form.titleType" placeholder="请选择抬头类型"> <el-option label="企业" value="enterprise"></el-option> <el-option label="个人" value="individual"></el-option> </el-select> </el-form-item> <el-form-item label="发票抬头" prop="invoiceTitle"> <el-input v-model="form.invoiceTitle"></el-input> </el-form-item> <el-form-item label="税号" prop="taxNumber"> <el-input v-model="form.taxNumber"></el-input> </el-form-item> <el-form-item label="发票内容" prop="invoiceContent"> <el-input v-model="form.invoiceContent"></el-input> </el-form-item> <el-form-item label="邮箱地址" prop="email"> <el-input v-model="form.email"></el-input> </el-form-item> <el-form-item> <el-button type="primary" @click="submitForm">提交</el-button> <el-button @click="resetForm">重置</el-button> </el-form-item> </el-form> </div> </template> <script> export default { data() { return { form: { titleType: '', invoiceTitle: '', taxNumber: '', invoiceContent: '', email: '' }, rules: { titleType: [ { required: true, message: '请选择抬头类型', trigger: 'change' } ], invoiceTitle: [ { required: true, message: '请输入发票抬头', trigger: 'blur' } ], taxNumber: [ { required: true, message: '请输入税号', trigger: 'blur' }, { pattern: /^[A-Z0-9]{15,20}$/, message: '税号格式不正确', trigger: 'blur' } ], invoiceContent: [ { required: true, message: '请输入发票内容', trigger: 'blur' } ], email: [ { required: true, message: '请输入邮箱地址', trigger: 'blur' }, { type: 'email', message: '请输入正确的邮箱地址', trigger: 'blur' } ] } }; }, methods: { submitForm() { this.$refs.formRef.validate((valid) => { if (valid) { alert('表单提交成功'); } else { console.log('表单验证失败'); return false; } }); }, resetForm() { this.$refs.formRef.resetFields(); } } }; </script> ``` 在上述代码中,定义了一个包含多个必填项的表单,为每个必填项都添加了对应的 rule 规则校验。当用户点击提交按钮时,会触发表单验证,只有所有必填项都通过验证,才会提示表单提交成功。
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值