30 Commits

Author SHA1 Message Date
f713dfd5ba xxx 2022-12-15 17:45:19 +08:00
ac1cd2e9b7 保存进度! 2022-11-18 18:05:08 +08:00
71adc2622e 注册页面 2022-11-16 18:03:17 +08:00
7e8c5da593 保存进度! 2022-11-15 17:56:34 +08:00
d249fdd576 ... 2022-11-14 10:23:26 +08:00
cdda49370f 保存进度! 2022-11-13 00:31:39 +08:00
9cd7373f90 尝试新的背影颜色!#f4f5f7 2022-11-04 00:22:28 +08:00
15bf339118 ... 2022-11-03 17:53:04 +08:00
0c392ee354 保存进度! 2022-11-02 18:02:22 +08:00
3aa898fee8 保存进度! 2022-11-01 17:51:14 +08:00
fd6e7ad959 保存进度! 2022-11-01 10:06:40 +08:00
a634bdfad4 保存进度! 2022-11-01 00:13:34 +08:00
52e7a355bf 保存进度! 2022-10-31 23:08:51 +08:00
fe484c0eec 保存进度! 2022-10-31 18:01:26 +08:00
a89f773825 学习axios
联系用axios发送请求,并且复习springmvc接收json请求。
2022-10-31 16:59:21 +08:00
dfac0eaa64 开始编写数据上传的前后端。 2022-10-31 11:41:55 +08:00
ccdd94ed1a Merge branch 'javaweb' of http://222.76.244.118:3000/CPICXIM/car_deal_util into javaweb 2022-10-31 00:13:41 +08:00
82eed0a470 删掉一些没用的代码! 2022-10-31 00:12:55 +08:00
b0f9f4e48d 保存进度! 2022-10-25 18:01:01 +08:00
e4fff250d2 保存进度! 2022-10-23 15:32:03 +08:00
6a3f5d820f 修改了一些样式! 2022-10-23 00:41:28 +08:00
bfb0375e84 学习设置滚动条样式! 2022-10-22 01:52:42 +08:00
2a160aaabc 保存进度! 2022-10-22 01:35:43 +08:00
c768a04b90 保存进度! 2022-10-21 19:03:12 +08:00
a963a76d01 保存进度! 2022-10-21 11:49:40 +08:00
b7df4c2235 保存进度! 2022-10-21 01:19:47 +08:00
7439e216b9 保存进度! 2022-10-20 18:04:19 +08:00
8e3dcf4e5b 保存进度! 2022-10-20 00:07:19 +08:00
60017b58aa Merge branch 'javaweb' of http://222.76.244.118:3000/CPICXIM/car_deal_util into javaweb 2022-10-19 22:45:08 +08:00
55c81f3df6 保存进度! 2022-10-19 22:44:56 +08:00
33 changed files with 21041 additions and 81 deletions

View File

@@ -1,3 +1,4 @@
{
"java.configuration.updateBuildConfiguration": "automatic"
"java.configuration.updateBuildConfiguration": "automatic",
"java.compile.nullAnalysis.mode": "automatic"
}

View File

@@ -0,0 +1,40 @@
/*
* @Author: Kane
* @Date: 2022-10-31 10:23:32
* @LastEditors: Kane
* @LastEditTime: 2022-10-31 15:11:40
* @FilePath: \car_dealer\src\main\java\com\cpic\xim\car_dealer\controllers\data\importer\CarDealerDataImport.java
* @Description:
*
* Copyright (c) ${2022} by Kane, All Rights Reserved.
*/
package com.cpic.xim.car_dealer.controllers.data.importer;
import java.util.ArrayList;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;
@Controller
@ResponseBody
@RequestMapping( path = "/data/import/")
public class CarDealerDataImport
{
@RequestMapping( "/importcardealer.do")
public ImportResult importCarDealer( @RequestBody ImportRequest importRequest )
{
ArrayList<RecordErrorMessage> recordErrorMessages = new ArrayList<RecordErrorMessage>();
ImportResult result = new ImportResult();
result.setFileName( "测试文件" );
result.setFilePath( "测试" );
result.setMessage( "测试" );
result.setSuccess( true );
result.setRecordErrorMessages( recordErrorMessages );
return result;
}
}

View File

@@ -0,0 +1,58 @@
/*
* @Author: Kane
* @Date: 2022-10-31 11:16:22
* @LastEditors: Kane
* @LastEditTime: 2022-10-31 15:29:26
* @FilePath: \car_dealer\src\main\java\com\cpic\xim\car_dealer\controllers\data\importer\importRequest.java
* @Description:
*
* Copyright (c) ${2022} by Kane, All Rights Reserved.
*/
package com.cpic.xim.car_dealer.controllers.data.importer;
import com.fasterxml.jackson.annotation.JsonProperty;
public class ImportRequest
{
public ImportRequest()
{}
public ImportRequest( String filePath, String tableName)
{
this.filePath = filePath;
this.tableName = tableName;
}
public String getFilePath()
{
return filePath;
}
public void setFilePath( String filePath )
{
this.filePath = filePath;
}
public String getTableName()
{
return tableName;
}
public void setTableName( String tableName )
{
this.tableName = tableName;
}
@Override
public String toString()
{
return "{ \"file_path\":\"" + filePath + "\", \"table_name\":\"" + tableName + "\"}";
}
@JsonProperty( "file_path")
private String filePath;
@JsonProperty( "table_name")
private String tableName;
}

View File

@@ -0,0 +1,86 @@
/*
* @Author: Kane
* @Date: 2022-10-31 10:31:35
* @LastEditors: Kane
* @LastEditTime: 2022-10-31 10:43:12
* @FilePath: \car_dealer\src\main\java\com\cpic\xim\car_dealer\controllers\data\importer\ImportResult.java
* @Description:
*
* Copyright (c) ${2022} by Kane, All Rights Reserved.
*/
package com.cpic.xim.car_dealer.controllers.data.importer;
import java.util.ArrayList;
import com.fasterxml.jackson.annotation.JsonProperty;
public class ImportResult
{
ImportResult()
{}
public String getFileName()
{
return fileName;
}
public void setFileName( String fileName )
{
this.fileName = fileName;
}
public String getFilePath()
{
return filePath;
}
public void setFilePath( String filePath )
{
this.filePath = filePath;
}
public boolean isSuccess()
{
return success;
}
public void setSuccess( boolean success )
{
this.success = success;
}
public String getMessage()
{
return message;
}
public void setMessage( String message )
{
this.message = message;
}
public ArrayList<RecordErrorMessage> getRecordErrorMessages()
{
return recordErrorMessages;
}
public void setRecordErrorMessages( ArrayList<RecordErrorMessage> recordErrorMessages )
{
this.recordErrorMessages = recordErrorMessages;
}
@JsonProperty( "file_name")
private String fileName;
@JsonProperty( "file_path")
private String filePath;
@JsonProperty( "success")
private boolean success;
@JsonProperty( "message")
private String message;
@JsonProperty( "record_error_messages")
private ArrayList<RecordErrorMessage> recordErrorMessages;
}

View File

@@ -0,0 +1,102 @@
/*
* @Author: Kane
* @Date: 2022-10-31 10:48:29
* @LastEditors: Kane
* @LastEditTime: 2022-10-31 15:29:24
* @FilePath: \car_dealer\src\main\java\com\cpic\xim\car_dealer\controllers\data\importer\RecordErrorMessage.java
* @Description: 存放导入数据记录结果的对象.
*
* Copyright (c) ${2022} by Kane, All Rights Reserved.
*/
package com.cpic.xim.car_dealer.controllers.data.importer;
import com.fasterxml.jackson.annotation.*;;
/*****************************************************
* 存放导入数据记录结果的对象.
*****************************************************/
public class RecordErrorMessage
{
public RecordErrorMessage()
{}
public RecordErrorMessage( int rowIndex, String message)
{
this.rowIndex = rowIndex;
this.message = message;
}
public int getRowIndex()
{
return rowIndex;
}
public void setRowIndex( int rowIndex )
{
this.rowIndex = rowIndex;
}
public String getMessage()
{
return message;
}
public void setMessage( String message )
{
this.message = message;
}
@Override
public int hashCode()
{
final int prime = 31;
int result = 1;
result = prime * result + rowIndex;
result = prime * result + ((message == null) ? 0 : message.hashCode());
return result;
}
@Override
public boolean equals( Object obj )
{
if ( this == obj)
return true;
if ( obj == null)
return false;
if ( getClass() != obj.getClass())
return false;
RecordErrorMessage other = (RecordErrorMessage) obj;
if ( rowIndex != other.rowIndex)
return false;
if ( message == null)
{
if ( other.message != null)
return false;
} else if ( !message.equals( other.message ))
return false;
return true;
}
@Override
public String toString()
{
return "importRecordErrorMessage [rowIndex=" + rowIndex + ", message=" + message + "]";
}
/**
* 数据的行id。
*/
@JsonProperty( "row_index")
private int rowIndex;
/**
* 导入时的错误信息。
*/
@JsonProperty( "message")
private String message;
}

View File

@@ -2,7 +2,7 @@
* @Author: Kane
* @Date: 2022-09-28 15:47:02
* @LastEditors: Kane
* @LastEditTime: 2022-10-19 16:19:01
* @LastEditTime: 2022-12-15 17:45:18
* @FilePath: \car_dealer\src\main\java\com\cpic\xim\car_dealer\controllers\fileupload\FileUploadController.java
* @Description: 用于实现跨域功能的过滤器对象。
* Copyright (c) ${2022} by Kane, All Rights Reserved.
@@ -56,6 +56,7 @@ public class FileUploadController
FileUploadResult result = new FileUploadResult();
String sessionID = request.getSession().getId();
if ( uploadFile == null)
{
result.setSuccess( false );

View File

@@ -1,13 +1,12 @@
<beans xmlns="http://www.springframework.org/schema/beans" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:context="http://www.springframework.org/schema/context" xmlns:jdbc="http://www.springframework.org/schema/jdbc" xmlns:jee="http://www.springframework.org/schema/jee" xmlns:tx="http://www.springframework.org/schema/tx" xmlns:aop="http://www.springframework.org/schema/aop" xmlns:mvc="http://www.springframework.org/schema/mvc" xmlns:util="http://www.springframework.org/schema/util" xmlns:jpa="http://www.springframework.org/schema/data/jpa" xsi:schemaLocation="
http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-3.2.xsd
http://www.springframework.org/schema/context http://www.springframework.org/schema/context/spring-context-3.2.xsd
http://www.springframework.org/schema/jdbc http://www.springframework.org/schema/jdbc/spring-jdbc-3.2.xsd
http://www.springframework.org/schema/jee http://www.springframework.org/schema/jee/spring-jee-3.2.xsd
http://www.springframework.org/schema/tx http://www.springframework.org/schema/tx/spring-tx-3.2.xsd
http://www.springframework.org/schema/data/jpa http://www.springframework.org/schema/data/jpa/spring-jpa-1.3.xsd
http://www.springframework.org/schema/aop http://www.springframework.org/schema/aop/spring-aop-3.2.xsd
http://www.springframework.org/schema/mvc http://www.springframework.org/schema/mvc/spring-mvc-3.2.xsd
http://www.springframework.org/schema/util http://www.springframework.org/schema/util/spring-util-3.2.xsd">
<beans xmlns="http://www.springframework.org/schema/beans" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:context="http://www.springframework.org/schema/context" xmlns:jdbc="http://www.springframework.org/schema/jdbc" xmlns:jee="http://www.springframework.org/schema/jee" xmlns:tx="http://www.springframework.org/schema/tx" xmlns:aop="http://www.springframework.org/schema/aop" xmlns:mvc="http://www.springframework.org/schema/mvc" xmlns:util="http://www.springframework.org/schema/util" xmlns:jpa="http://www.springframework.org/schema/data/jpa" xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-3.2.xsd
http://www.springframework.org/schema/context http://www.springframework.org/schema/context/spring-context-3.2.xsd
http://www.springframework.org/schema/jdbc http://www.springframework.org/schema/jdbc/spring-jdbc-3.2.xsd
http://www.springframework.org/schema/jee http://www.springframework.org/schema/jee/spring-jee-3.2.xsd
http://www.springframework.org/schema/tx http://www.springframework.org/schema/tx/spring-tx-3.2.xsd
http://www.springframework.org/schema/data/jpa http://www.springframework.org/schema/data/jpa/spring-jpa-1.3.xsd
http://www.springframework.org/schema/aop http://www.springframework.org/schema/aop/spring-aop-3.2.xsd
http://www.springframework.org/schema/mvc http://www.springframework.org/schema/mvc/spring-mvc-3.2.xsd
http://www.springframework.org/schema/util http://www.springframework.org/schema/util/spring-util-3.2.xsd">
<context:component-scan base-package="com.cpic.xim" />
<mvc:annotation-driven />

View File

@@ -67,6 +67,7 @@
const xhr = new XMLHttpRequest();
//处理进度
xhr.upload.onprogress = function (event) {
if (event.lengthComputable) {
let percent = Math.round(
@@ -77,6 +78,7 @@
}
};
//传送完成
xhr.onload = function (event) {
console.log(xhr.responseText);

View File

@@ -0,0 +1,23 @@
<%-- /*
* @Author: Kane
* @Date: 2022-10-21 00:14:43
* @LastEditors: Kane
* @LastEditTime: 2022-10-21 00:16:48
* @FilePath: \car_dealer\src\main\webapp\test.jsp
* @Description:
*
* Copyright (c) ${2022} by Kane, All Rights Reserved.
*/ --%>
<%@ page contentType="text/html;charset=UTF-8" %>
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Document</title>
</head>
<body>
</body>
</html>

View File

@@ -8,6 +8,15 @@
{
"label": "off"
}
]
],
"compat-api/css": [
"default",
{
"ignore": [
"-webkit-text-size-adjust"
]
}
],
"highest-available-document-mode": "off"
}
}

View File

@@ -0,0 +1,27 @@
/*
* @Author: Kane
* @Date: 2022-11-12 23:32:20
* @LastEditors: Kane
* @LastEditTime: 2022-11-16 11:08:23
* @FilePath: \car_dealer\css\app.css
* @Description:
*
* Copyright (c) ${2022} by Kane, All Rights Reserved.
*/
@import url("colors.css");
body {
background-color: var(--backupground-color);
padding: 50px;
}
.content {
display: flex;
flex-direction: column;
align-items: center;
justify-content: center;
background-color: #fff;
width: 25rem;
margin: 0px auto;
border-radius: 5px;
}

View File

@@ -0,0 +1,52 @@
/*
* @Author: Kane
* @Date: 2022-10-31 14:38:45
* @LastEditors: Kane
* @LastEditTime: 2022-11-01 11:01:28
* @FilePath: \car_dealer\css\axios\axios.css
* @Description:
*
* Copyright (c) ${2022} by Kane, All Rights Reserved.
*/
html {
--border-color: #efefef;
--hr-color: #efefef;
--backupground-color: #f8f8f8;
--btn-color-blue: #307dbe;
--btn-color-yellow: #f7b24d;
--btn-color-green: #5bad60;
--btn-color-red: #e56651;
--btn-font-color: #fff;
--light-shadow: #cfcfcf;
--dark-shadow: #afafaf;
--scrollbar-backupground-color: #cfcfcf7f;
--scrollbar-track-color: #f7f7f700;
--font-color: #486171ff;
color: var(--font-color);
}
input {
line-height: 2rem;
width: 100%;
}
/* 隐藏上传文件 */
input[type="file"] {
display: none;
}
.main_plane {
display: flex;
flex-direction: column;
justify-content: center;
align-items: center;
width: 20rem;
}
.main_plane > * + * {
margin-top: 15px;
}

View File

@@ -0,0 +1,34 @@
/*
* @Author: Kane
* @Date: 2022-11-12 23:20:29
* @LastEditors: Kane
* @LastEditTime: 2022-11-12 23:45:27
* @FilePath: \car_dealer\css\button.css
* @Description:
*
* Copyright (c) ${2022} by Kane, All Rights Reserved.
*/
@import url("colors.css");
button {
padding: 5px 10px;
background-color: var(--btn-color-red);
color: var(--btn-font-color);
width: 10em;
border: none;
border-radius: 0.25em;
font-size: 1.5rem;
text-align: center;
-webkit-user-select: none;
user-select: none;
}
button:hover {
cursor: pointer;
}
/* 用于按钮点击时样式切换。 */
button:active {
background-color: var(--btn-font-color);
color: var(--btn-color-red);
}

View File

@@ -0,0 +1,21 @@
/*
* @Author: Kane
* @Date: 2022-11-12 23:22:59
* @LastEditors: Kane
* @LastEditTime: 2022-11-16 15:26:04
* @FilePath: \car_dealer\css\colors.css
* @Description:
*
* Copyright (c) ${2022} by Kane, All Rights Reserved.
*/
html {
--backupground-color: #f4f5f7ff;
--btn-color-blue: #307dbe;
--btn-color-yellow: #f7b24d;
--btn-color-green: #5bad60;
--btn-color-red: #e56651;
--btn-font-color: #fff;
--input-focus-color: #e56651;
}

View File

@@ -1,5 +1,16 @@
/*
* @Author: Kane
* @Date: 2022-10-12 08:49:14
* @LastEditors: Kane
* @LastEditTime: 2022-11-12 23:34:06
* @FilePath: \car_dealer\css\kane.css
* @Description: vue学习用的样式表
*
* Copyright (c) ${2022} by Kane, All Rights Reserved.
*/
html {
--backupground-color: #f7f7f7;
--backupground-color: #f4f5f7ff;
--btn-color-blue: #307dbe;
--btn-color-yellow: #f7b24d;
--btn-color-green: #5bad60;
@@ -9,55 +20,34 @@ html {
#root,
#app {
height: 100vh;
width: 100vw;
position: fixed;
padding: 50px;
/* font-size: 0; */
overflow: auto;
}
#root,
#app * + * {
margin-top: 15px;
.content {
display: flex;
flex-direction: column;
align-items: center;
justify-content: center;
}
hr {
background-color: steelblue;
border: none;
height: 3px;
/* width: 100% */
}
.test {
width: 110vw;
height: 100vh;
border: 1px solid red;
overflow: auto;
}
/* .test {
width : 110vw;
height : 100vh;
border : 1px solid red;
overflow : auto;
} */
button {
padding: 5px 10px;
background-color: var(--btn-color-red);
color: var(--btn-font-color);
width: 10em;
border: none;
border-radius: 0.25em;
font-size: 1.5rem;
}
button + button {
margin-left: 0.5em;
}
button:active {
background-color: var(--btn-font-color);
color: var(--btn-color-red);
}
input {
input[type="text"] {
border: none;
outline: solid 2px #e56651;
font-size: 2rem;
/* font-size: 2rem; */
}
label {

View File

@@ -135,7 +135,7 @@ body {
position: absolute;
font-family: "jinghongtifan";
font-size: 60px;
color: #fff;
color: #f00;
top: 5vh;
left: 10vw;
height: 2em;

View File

@@ -9,8 +9,10 @@
*/
html {
line-height: 1.15; /* 1 */
-webkit-text-size-adjust: 100%; /* 2 */
line-height: 1.15;
/* 1 */
-webkit-text-size-adjust: 100%;
/* 2 */
}
/* Sections
@@ -51,9 +53,12 @@ h1 {
*/
hr {
box-sizing: content-box; /* 1 */
height: 0; /* 1 */
overflow: visible; /* 2 */
box-sizing: content-box;
/* 1 */
height: 0;
/* 1 */
overflow: visible;
/* 2 */
}
/**
@@ -62,8 +67,10 @@ hr {
*/
pre {
font-family: monospace, monospace; /* 1 */
font-size: 1em; /* 2 */
font-family: monospace, monospace;
/* 1 */
font-size: 1em;
/* 2 */
}
/* Text-level semantics
@@ -83,9 +90,12 @@ a {
*/
abbr[title] {
border-bottom: none; /* 1 */
text-decoration: underline; /* 2 */
text-decoration: underline dotted; /* 2 */
border-bottom: none;
/* 1 */
text-decoration: underline;
/* 2 */
text-decoration: underline dotted;
/* 2 */
}
/**
@@ -105,8 +115,10 @@ strong {
code,
kbd,
samp {
font-family: monospace, monospace; /* 1 */
font-size: 1em; /* 2 */
font-family: monospace, monospace;
/* 1 */
font-size: 1em;
/* 2 */
}
/**
@@ -162,10 +174,14 @@ input,
optgroup,
select,
textarea {
font-family: inherit; /* 1 */
font-size: 100%; /* 1 */
line-height: 1.15; /* 1 */
margin: 0; /* 2 */
font-family: inherit;
/* 1 */
font-size: 100%;
/* 1 */
line-height: 1.15;
/* 1 */
margin: 0;
/* 2 */
}
/**
@@ -174,7 +190,8 @@ textarea {
*/
button,
input { /* 1 */
input {
/* 1 */
overflow: visible;
}
@@ -184,7 +201,8 @@ input { /* 1 */
*/
button,
select { /* 1 */
select {
/* 1 */
text-transform: none;
}
@@ -238,12 +256,18 @@ fieldset {
*/
legend {
box-sizing: border-box; /* 1 */
color: inherit; /* 2 */
display: table; /* 1 */
max-width: 100%; /* 1 */
padding: 0; /* 3 */
white-space: normal; /* 1 */
box-sizing: border-box;
/* 1 */
color: inherit;
/* 2 */
display: table;
/* 1 */
max-width: 100%;
/* 1 */
padding: 0;
/* 3 */
white-space: normal;
/* 1 */
}
/**
@@ -269,8 +293,10 @@ textarea {
[type="checkbox"],
[type="radio"] {
box-sizing: border-box; /* 1 */
padding: 0; /* 2 */
box-sizing: border-box;
/* 1 */
padding: 0;
/* 2 */
}
/**
@@ -288,8 +314,10 @@ textarea {
*/
[type="search"] {
-webkit-appearance: textfield; /* 1 */
outline-offset: -2px; /* 2 */
-webkit-appearance: textfield;
/* 1 */
outline-offset: -2px;
/* 2 */
}
/**
@@ -306,8 +334,10 @@ textarea {
*/
::-webkit-file-upload-button {
-webkit-appearance: button; /* 1 */
font: inherit; /* 2 */
-webkit-appearance: button;
/* 1 */
font: inherit;
/* 2 */
}
/* Interactive
@@ -346,4 +376,4 @@ template {
[hidden] {
display: none;
}
}

View File

@@ -0,0 +1,24 @@
button {
clip: rect(0, 0, 0, 0);
position: absolute;
}
label {
display: inline-block;
line-height: 20px;
padding: 10px;
}
.father {
width: 200px;
height: 200px;
padding: 0px;
border: 1px solid red;
}
.son {
border: 1px solid blue;
height: 100%;
/* margin: 0px 20px; */
width: 300px;
}

View File

@@ -0,0 +1,195 @@
/*
* @Author: Kane
* @Date: 2022-10-21 16:39:27
* @LastEditors: Kane
* @LastEditTime: 2022-11-03 23:48:28
* @FilePath: \car_dealer\css\todo-list\to-list.css
* @Description: 用于待办事项页面的css
*
* Copyright (c) ${2022} by Kane, All Rights Reserved.
*/
html {
--border-color: #efefef;
--hr-color: #efefef;
--backupground-color: #f4f5f7ff;
--plane-color: #ffffff;
--btn-color-blue: #307dbe;
--btn-color-yellow: #f7b24d;
--btn-color-green: #5bad60;
--btn-color-red: #e56651;
--btn-font-color: #fff;
--light-shadow: #cfcfcf;
--dark-shadow: #afafaf;
--scrollbar-backupground-color: #cfcfcf7f;
--scrollbar-track-color: #f7f7f700;
--font-color: #486171ff;
color: var(--font-color);
background-color: var(--backupground-color);
}
.border {
border: 1px solid var(--border-color);
border-radius: 5px;
background-color: var(--plane-color);
width: 30rem;
padding: 1em;
box-shadow: 0px 0px 10px var(--light-shadow);
}
.border:hover {
box-shadow: 0px 0px 10px var(--dark-shadow);
transition: box-shadow 1;
}
.border > .add_todo {
display: flex;
align-items: center;
justify-content: center;
}
.border > .add_todo > button {
margin-left: 5px;
flex-basis: 4rem;
flex-grow: 0;
font-size: 1rem;
height: 2.3rem;
}
.border > .add_todo > input {
flex-shrink: auto;
flex-grow: 1;
font-size: 1rem;
line-height: 2rem;
padding: 0 5px;
margin: 0px;
outline-color: var(--border-color);
}
hr {
border: none;
margin-top: 1rem;
background-color: var(--border-color);
height: 1px;
}
.border > .todo_list {
margin-top: calc(1rem - 1px);
margin-bottom: calc(1rem - 1px);
height: 12.34rem;
overflow-y: overlay;
padding-top: 1px;
padding-bottom: 1px;
}
.todo_list::-webkit-scrollbar {
width: 0.75rem;
cursor: pointer;
/* height: 100px; */
}
.todo_list::-webkit-scrollbar-thumb {
cursor: pointer;
}
.todo_list:hover::-webkit-scrollbar-thumb {
border-radius: 10px;
-webkit-box-shadow: inset 0 0 5px var(--scrollbar-track-color);
box-shadow: 0 0 5px var(--scrollbar-track-color);
background: var(--scrollbar-backupground-color);
}
/* .todo_list:hover::-webkit-scrollbar-track {
-webkit-box-shadow: inset 0 0 5px var(--scrollbar-backupground-color);
box-shadow: 0 0 5px var(--scrollbar-backupground-color);
border-radius: 10px;
background: var(--scrollbar-track-color);
} */
.border > .todo_list > * + * {
margin-top: 5px;
}
.border > .todo_list div {
display: flex;
align-items: center;
justify-content: center;
}
.border > .todo_list div > input[type="checkbox"] {
flex-grow: 0;
outline: none !important;
}
.border > .todo_list div * + * {
margin-left: 5px;
}
.border > .todo_list span {
flex-grow: 1;
border-bottom: 1px solid var(--border-color);
height: 1.25rem;
vertical-align: center;
-webkit-user-select: none;
user-select: none;
padding-left: 5px;
}
.border > .todo_list input {
flex-grow: 1;
font-size: 1rem;
/* line-height: 1.5rem; */
padding: 5px 5px;
margin: 0px 0px 0px 5px;
outline-color: var(--border-color);
}
.border > .todo_list button {
flex-grow: 0;
font-size: 1rem;
width: 4rem;
}
.border > .todo_list input {
outline: 1px solid var(--border-color);
}
.border > .tools {
margin-top: 1rem;
}
.border > .tools > p {
text-align: right;
margin: 0px 1rem;
}
#message_border {
position: fixed;
display: none;
left: 0px;
top: 0px;
right: 0px;
bottom: 0px;
background-color: rgba(128, 128, 128, 0.8);
justify-content: center;
align-items: center;
}
.message_box {
display: flex;
flex-direction: column;
justify-content: center;
align-items: center;
background-color: var(--backupground-color);
padding: 2rem;
border-radius: 5px;
}
.message_box > button {
padding: 0.5rem 2rem;
font-size: 1rem;
}

View File

@@ -0,0 +1,55 @@
/*
* @Author: Kane
* @Date: 2022-11-14 10:50:51
* @LastEditors: Kane
* @LastEditTime: 2022-11-14 11:44:15
* @FilePath: \car_dealer\css\表单\表单.css
* @Description:
*
* Copyright (c) ${2022} by Kane, All Rights Reserved.
*/
@import url("../colors.css");
#app {
padding: 15px;
display: grid;
grid-template-columns: 4rem auto;
/* grid-template-rows: repeat(3, 1.5rem); */
grid-auto-rows: 2rem;
grid-gap: 0.5rem;
place-items: center center;
}
#app > * + * {
/* margin-top: 15px; */
}
.grid-left {
/* display: inline-block; */
/* grid-column: 1/2; */
/* place-self: end; */
text-align: right;
line-height: 2rem;
width: 100%;
}
.grid-left + input {
height: 1.8rem;
width: 100%;
outline-color: #f4f5f7;
border: 1px solid #f4f5f7;
border-radius: 5px;
padding: 0.5rem;
}
.grid-left + input:focus {
outline: 2px solid #e56651;
}
.cell-gender {
display: flex;
justify-content: left;
align-items: center;
width: 100%;
}

File diff suppressed because it is too large Load Diff

File diff suppressed because one or more lines are too long

File diff suppressed because it is too large Load Diff

View File

@@ -0,0 +1,30 @@
<!--
* @Author: Kane
* @Date: 2022-10-19 22:46:18
* @LastEditors: Kane
* @LastEditTime: 2022-10-19 23:38:21
* @FilePath: \car_dealer\test.html
* @Description:
*
* Copyright (c) ${2022} by Kane, All Rights Reserved.
-->
<!DOCTYPE html>
<html lang="zh-cn">
<head>
<meta charset="UTF-8" />
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>测试css</title>
<!-- <link rel="stylesheet" href="css/root.css" /> -->
<!-- <link rel="stylesheet" href="css/normalize.css" /> -->
<link rel="stylesheet" href="css/kane.css" />
<link rel="stylesheet" href="css/test.css" />
</head>
<body>
<div id="root">
<div class="father">
<div class="son"></div>
</div>
</div>
</body>
</html>

View File

@@ -0,0 +1,103 @@
<table align="center" style="width: 215px;">
<tbody>
<tr class="firstRow">
<td align="center" style="-ms-word-break: break-all;" valign="middle" width="60">
<p style="text-align:center"><a href="http://newoa.hq.cpic.com/" target="_Blank"><img alt=""
src="/images/portal/1.png" /> </a></p>
<p><a href="http://newoa.hq.cpic.com/" target="_Blank"><span style="color:#000000;"><span
style="font-size: 12px;">太保e办1.0</span> </span> </a></p>
</td>
<td align="center" style="width: 89px;" valign="middle" width="60">
<p style="text-align:center"><a href="http://mailoa7.hq.cpic.com/mail/empmail.nsf/cxxx?openform"
target="_Blank"><img alt="" src="/images/portal/7.png" /> </a></p>
<p><a href="http://mailoa7.hq.cpic.com/mail/empmail.nsf/cxxx?openform" target="_Blank"><span
style="color:#000000;"><span style="font-size: 12px;">董事长邮箱</span> </span> </a></p>
</td>
<td align="center" style="width: 60px;" valign="middle" width="60">
<p style="text-align:center"><a
href="http://xcoa-gp21oa.group.cpic.com/wui/index.html#/main/workflow/add?menuIds=1,12&amp;menuPathIds=1,12&amp;_key=4556on"
target="_Blank"><img alt="" src="/images/portal/1.png" /> </a></p>
<p><a href="http://xcoa-gp21oa.group.cpic.com/wui/index.html#/main/workflow/add?menuIds=1,12&amp;menuPathIds=1,12&amp;_key=4556on"
target="_Blank"><span style="color:#000000;"><span style="font-size: 12px;">新建流程</span> </span>
</a></p>
</td>
</tr>
<tr class="firstRow">
<td align="center" style="width: 60px;" valign="middle" width="60">
<p style="text-align:center"><a
href="http://xcoa-gp21oa.group.cpic.com/spa/meeting/static/index.html#/main/meeting/RoomPlan?canEdit=1"
target="_Blank"><img alt="" src="/images/portal/8.png" /> </a></p>
<p><a href="http://xcoa-gp21oa.group.cpic.com/spa/meeting/static/index.html#/main/meeting/RoomPlan?canEdit=1"
target="_Blank"><span style="color:#000000;"><span style="font-size: 12px;">会议室预定</span> </span>
</a></p>
</td>
<td align="center" style="width: 89px;" valign="middle" width="60">
<p style="text-align:center"><a
href="http://xcoa-gp21oa.group.cpic.com/spa/hrm/index_mobx.html#/main/hrm/card/cardInfo/99068?_key=z1z8ru"
target="_Blank"><img alt="" src="/images/portal/8.png" /> </a></p>
<p><a href="http://xcoa-gp21oa.group.cpic.com/spa/hrm/index_mobx.html#/main/hrm/card/cardInfo/99068?_key=z1z8ru"
target="_Blank"><span style="color:#000000;"><span style="font-size: 12px;">个人名片</span> </span>
</a></p>
</td>
<td align="center" style="width: 60px;" valign="middle" width="60">
<p style="text-align:center"><a href="http://trippc.hq.cpic.com/taibao-pc/users/loginPage.do"
target="_Blank"><img alt="" src="/images/portal/4.png" /> </a></p>
<p><a href="http://trippc.hq.cpic.com/taibao-pc/users/loginPage.do" target="_Blank"><span
style="color:#000000;"><span style="font-size: 12px;">太保e行</span> </span> </a></p>
</td>
</tr>
<tr class="firstRow">
<td align="center" style="-ms-word-break: break-all;" valign="middle" width="60">
<p style="text-align:center"><a
href="http://xcoa-gp21oa.group.cpic.com/spa/document/static/index.html#/main/document/search?eid=1481&amp;tabid=9&amp;redictFrom=more&amp;_key=yw4d6i"
target="_Blank"><img alt="" src="/images/portal/1.png" /> </a></p>
<p><a href="http://xcoa-gp21oa.group.cpic.com/spa/document/static/index.html#/main/document/search?eid=1481&amp;tabid=9&amp;redictFrom=more&amp;_key=yw4d6i"
target="_Blank"><span style="color:#000000;"><span style="font-size: 12px;">办事指南</span> </span>
</a></p>
</td>
<td align="center" style="width: 89px;" valign="middle" width="60">
<p style="text-align:center"><a
href="http://21.10.0.67/caf-cxhg-web/com.cpic.caf.main.view.caseLibrary.caseSearch.d"
target="_Blank"><img alt="" src="/images/portal/16.png" /> </a></p>
<p><a href="http://21.10.0.67/caf-cxhg-web/com.cpic.caf.main.view.caseLibrary.caseSearch.d"
target="_Blank"><span style="color:#000000;"><span style="font-size: 12px;">合规e查</span> </span>
</a></p>
</td>
<td align="center" style="width: 60px;" valign="middle" width="60">
<p style="text-align:center"><a href="/spa/portal/static/index.html#/main/portal/portal-1321-1"
target="_Blank"><img alt="" src="/images/portal/7.png" /> </a></p>
<p><a href="/spa/portal/static/index.html#/main/portal/portal-1321-1" target="_Blank"><span
style="color:#000000;"><span style="font-size: 12px;">IT热线</span> </span> </a></p>
</td>
</tr>
<tr class="firstRow">
<td align="center" style="-ms-word-break: break-all;" valign="middle" width="60">
<p style="text-align:center"><a
href="http://10.187.28.129:8080/xm/servlet/SkipJspServlet?cmd=message_all&amp;id=000325&amp;info=QC9bKmwCMOItJatSmkD5EQq46uLDeLJ5nX-qq8xAY4A&amp;idCard=lZsIq4st6PfvratOk5C_rTRiA7X2PdjvrDNZt5kCwlM&amp;mobile=5A07ebGbeA8URvr842Ei8A&amp;name=%E4%BA%8E%E5%BD%AC&amp;cpicuid=yubin-033&amp;unitCode=2030100&amp;sign=9dbb28ed96215ea502875ec1c195d846a93ab796"
target="_Blank"><img alt="" src="/images/portal/1.png" /> </a></p>
<p><a href="http://10.187.28.129:8080/xm/servlet/SkipJspServlet?cmd=message_all&amp;id=000325&amp;info=QC9bKmwCMOItJatSmkD5EQq46uLDeLJ5nX-qq8xAY4A&amp;idCard=lZsIq4st6PfvratOk5C_rTRiA7X2PdjvrDNZt5kCwlM&amp;mobile=5A07ebGbeA8URvr842Ei8A&amp;name=%E4%BA%8E%E5%BD%AC&amp;cpicuid=yubin-033&amp;unitCode=2030100&amp;sign=9dbb28ed96215ea502875ec1c195d846a93ab796"
target="_Blank"><span style="color:#000000;"><span style="font-size: 12px;">厦分民意箱</span> </span>
</a></p>
</td>
<td align="center" style="width: 60px;" valign="middle" width="60">
<p style="text-align:center"><a
href="http://10.187.28.129:8080/crm/servlet/Innovateservlet?cmd=innovateMainManager&amp;org_id="
target="_Blank"><img alt="" src="/images/portal/7.png" /> </a></p>
<p><a href="http://10.187.28.129:8080/crm/servlet/Innovateservlet?cmd=innovateMainManager&amp;org_id="
target="_Blank"><span style="color:#000000;"><span style="font-size: 12px;">创新天地</span> </span>
</a></p>
</td>
</tr>
</tbody>
</table>

View File

@@ -0,0 +1,113 @@
<!--
* @Author: Kane
* @Date: 2022-10-31 13:11:55
* @LastEditors: Kane
* @LastEditTime: 2022-11-01 09:54:11
* @FilePath: \car_dealer\vue\axios.html
* @Description:
*
* Copyright (c) ${2022} by Kane, All Rights Reserved.
-->
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8" />
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>axios</title>
<link rel="stylesheet" href="../css/root.css" />
<link rel="stylesheet" href="../css/normalize.css" />
<link rel="stylesheet" href="../css/kane.css" />
<link rel="stylesheet" href="../css/axios/axios.css" />
<script src="../js/axios/1.1.3/axios.js"></script>
<script src="../js/vue/vue.global.js"></script>
</head>
<body>
<div class="content">
<div id="app">
<div class="main_plane">
<input
type="text"
name="file_name"
id="file_name"
readonly
onclick="selectFile()"
/>
<button type="button" @click="onUploadFile()">上传</button>
<input
type="file"
name="uploadFile"
id="fileupload"
onchange="onFileuploadChange()"
/>
</div>
</div>
</div>
</body>
<script>
const UPLOAD_FILE_URL =
"http://localhost:8080/cardealer/upload/upload_file.do";
const IMPORT_CARDEALER_URL =
"http://localhost:8080/cardealer/data/import/importcardealer.do";
function selectFile() {
const upload_file = document.getElementById("fileupload");
const file_name = document.getElementById("file_name");
upload_file.click();
}
function onFileuploadChange() {
const upload_file = document.getElementById("fileupload");
const file_name = document.getElementById("file_name");
file_name.value = upload_file.value;
}
</script>
<script>
const app = {
data() {
return {
test: "测试this",
};
},
methods: {
onUploadFile: function () {
let param = {
file_path: "file path",
table_name: "车商表",
};
axios
.post(IMPORT_CARDEALER_URL, param)
.then((response) => {
console.log(response.data);
console.log(response);
})
.catch((error) => {
//先检查response看看是否因为状态码不是200
if (error.response) {
console.log(error.response.data);
console.log(error.response.status);
}
//没有收到响应就检查request
else if (error.request) {
console.log(error.request);
}
//如果request也为undefined说明是引擎抛出了异常
else {
console.log(error.message);
}
});
},
},
};
Vue.config.productionTip = false;
const vm = Vue.createApp(app);
vm.mount("#app");
</script>
</html>

View File

@@ -0,0 +1,104 @@
<!--
* @Author: Kane
* @Date: 2022-11-02 11:22:37
* @LastEditors: Kane
* @LastEditTime: 2022-11-07 16:45:06
* @FilePath: \car_dealer\vue\keypath.html
* @Description:
*
* Copyright (c) ${2022} by Kane, All Rights Reserved.
-->
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8" />
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>keypath测试</title>
</head>
<body>
<div>a<div>b</div>c</div>
</body>
<script>
const keypathReg = /[^\w.$]/;
let a = {
b: {
c: {
d: 100,
},
},
};
function parsePath(path) {
if (keypathReg.test(path)) {
return;
}
const segments = path.split(".");
return function (obj) {
console.log(segments);
for (let i = 0; i < segments.length; i++) {
// console.log(segments.length);
if (!obj) {
//如果obj没有值就返回
return;
}
obj = obj[segments[i]];
}
return obj;
};
}
let obj = parsePath("b.c.d");
console.log(obj.call(a, a));
</script>
<script>
class Dep {
constructor() { }
depend() { }
notify() { }
}
/**
* data 要添加响应式的对象
* key 要设置为响应式的属性
* val 属性的值
*/
function defineReactive(data, key, val) {
if (typeof val === "Object ") {
}
let dep = new Dep();
Object.defineProperty(data, key, {
enumerable: true,
configurable: true,
get: function () {
dep.depend();
return val;
},
set: function (newVal) {
if (val === newVal) {
return;
}
val = newVal;
dep.notify();
},
});
}
</script>
</html>

View File

@@ -0,0 +1,213 @@
<!--
* @Author: Kane
* @Date: 2022-10-21 16:36:51
* @LastEditors: Kane
* @LastEditTime: 2022-11-01 17:48:11
* @FilePath: \car_dealer\vue\todo-list.html
* @Description:
*
* Copyright (c) ${2022} by Kane, All Rights Reserved.
-->
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8" />
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>待办任务</title>
<link rel="stylesheet" href="../css/root.css" />
<link rel="stylesheet" href="../css/normalize.css" />
<link rel="stylesheet" href="../css/kane.css" />
<link rel="stylesheet" href="../css/todo-list/to-list.css" />
<script src="../js/vue/vue.global.js"></script>
</head>
<body>
<div id="app">
<div id="message_border">
<div class="message_box">
<span>{{errorMessage}}</span>
<button type="button" @click="closeMessageBox()">
关闭
</button>
</div>
</div>
<div class="content">
<h1>{{title}}</h1>
<div class="border">
<div class="add_todo">
<input type="text" v-model="todo_text" placeholder="请输入待办事项" />
<button type="button" @click="showMessageBox()">
添加
</button>
</div>
<hr />
<div class="todo_list">
<div v-for="(item,index) in todo_list" :key="index">
<input type="checkbox" v-model="todo_list[index].selected" />
<span v-show="!item.edit">{{item.todo_text}}</span>
<input type="text" v-show="item.edit" v-model="item.todo_text" />
<button type="button" v-on:click="editTodo(index,event)">
修改
</button>
<button type="button" @click="removeTodo(index)">
删除
</button>
</div>
</div>
<hr />
<div class="tools">
<p class="summary">总计:{{totalTodos}}</p>
</div>
</div>
</div>
</div>
</body>
<script>
const app = {
data() {
return {
title: "待办任务",
errorMessage: "奇怪的错误!",
todo_text: "",
todo_list: [
{
selected: false,
todo_text: "回家",
edit: false,
},
{
selected: true,
todo_text: "吃饭",
edit: false,
},
{
selected: false,
todo_text: "洗澡",
edit: false,
},
{
selected: false,
todo_text: "玩游戏",
edit: false,
},
{
selected: false,
todo_text: "回家",
edit: false,
},
{
selected: true,
todo_text: "吃饭",
edit: false,
},
{
selected: false,
todo_text: "洗澡",
edit: false,
},
{
selected: false,
todo_text: "玩游戏",
edit: false,
},
{
selected: false,
todo_text: "回家",
edit: false,
},
{
selected: true,
todo_text: "吃饭",
edit: false,
},
{
selected: false,
todo_text: "洗澡",
edit: false,
},
{
selected: false,
todo_text: "玩游戏",
edit: false,
},
{
selected: false,
todo_text: "回家",
edit: false,
},
{
selected: true,
todo_text: "吃饭",
edit: false,
},
{
selected: false,
todo_text: "洗澡",
edit: false,
},
{
selected: false,
todo_text: "玩游戏",
edit: false,
},
{
selected: false,
todo_text: "回家",
edit: false,
},
{
selected: true,
todo_text: "吃饭",
edit: false,
},
{
selected: false,
todo_text: "洗澡",
edit: false,
},
{
selected: false,
todo_text: "玩游戏",
edit: false,
},
],
};
},
methods: {
addTodo() { },
editTodo(index, event) {
console.log(index);
console.log(event);
this.todo_list[index].edit = !this.todo_list[index].edit;
},
removeTodo(index) {
this.todo_list.splice(index, 1);
},
showMessageBox() {
const message = document.getElementById("message_border");
message.style["display"] = "flex";
},
closeMessageBox() {
const message = document.getElementById("message_border");
message.style["display"] = "none";
},
},
computed: {
totalTodos: {
get() {
return this.todo_list.length;
},
},
},
};
const vm = Vue.createApp(app);
vm.mount("#app");
</script>
</html>

View File

@@ -0,0 +1,84 @@
<!--
* @Author: Kane
* @Date: 2022-10-20 15:07:59
* @LastEditors: Kane
* @LastEditTime: 2022-10-21 16:29:39
* @FilePath: \car_dealer\vue\vue_01.html
* @Description:
*
* Copyright (c) ${2022} by Kane, All Rights Reserved.
-->
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8" />
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>vue3入门</title>
<link rel="stylesheet" href="../css/root.css" />
<link rel="stylesheet" href="../css/normalize.css" />
<link rel="stylesheet" href="../css/kane.css" />
<script src="../js/vue/vue.global.js"></script>
</head>
<body>
<div id="app">
<div class="content">
<h1>{{title}}</h1>
<h1>{{count}}</h1>
<button type="button" v-on:click="addCount()">计数器</button>
<button type="button" v-on:click="switchButton()">
{{btn_title}}
</button>
<hr />
<h1>测试列表渲染</h1>
<h3>员工数量:{{stuffCount}}</h3>
<table>
<tr v-for="(stuff,index) in stuff_list" v-bind:key="index">
<td>{{index+1}}</td>
<td>{{stuff.name}}</td>
<td>{{stuff.age}}</td>
</tr>
</table>
<hr />
</div>
</div>
</body>
<script>
const app = {
data() {
return {
title: "vue3 入门!",
count: 0,
btn_title: "走你",
btn_switch: true,
stuff_list: [
{ name: "kane1", age: "40" },
{ name: "kane2", age: "41" },
{ name: "kane3", age: "42" },
{ name: "kane4", age: "43" },
{ name: "kane5", age: "44" },
],
};
},
methods: {
addCount() {
this.count++;
},
switchButton() {
this.btn_switch = !this.btn_switch;
this.btn_title = this.btn_switch ? "走你!" : "滚";
},
},
computed: {
stuffCount() {
return this.stuff_list.length;
},
},
};
const vm = Vue.createApp(app);
vm.mount("#app");
</script>
</html>

View File

@@ -0,0 +1,81 @@
/*
* @Author: Kane
* @Date: 2022-11-16 10:58:30
* @LastEditors: Kane
* @LastEditTime: 2022-11-16 14:38:15
* @FilePath: \car_dealer\vue\注册\css\main.css
* @Description:
*
* Copyright (c) ${2022} by Kane, All Rights Reserved.
*/
@import url("../../../css/colors.css");
html {
--text-border-color: #f4f5f7ff;
}
#app {
width: 20rem;
background-color: #fff;
display: flex;
flex-direction: column;
justify-content: center;
align-items: center;
padding: 1rem;
}
#app > div {
width: 100%;
}
/* #app input {
margin-top: 0.25rem;
margin-bottom: 5px;
} */
#app input[type="text"] {
margin-top: 0.25rem;
margin-bottom: 5px;
width: 100%;
height: 2rem;
line-height: 1.5rem;
padding: 2px 1rem;
border: 1px solid #f4f5f7ff;
border-radius: 5px;
}
#app input[type="text"]:focus {
border: none;
outline: 2px solid var(--input-focus-color);
}
#app > * + * {
margin-top: 15px;
}
.pianhao {
display: flex;
justify-content: left;
align-items: center;
margin-top: 0.25rem;
}
.pianhao label {
line-height: 0.8rem;
font-size: 0.8rem;
}
button {
background-color: var(--btn-color-red);
color: var(--btn-font-color);
border: none;
border-radius: 5px;
width: 10rem;
padding: 0.5rem 1rem;
margin-top: 25px !important;
}
button:active {
color: var(--btn-color-red);
background-color: var(--btn-font-color);
}

View File

@@ -0,0 +1,100 @@
<!--
* @Author: Kane
* @Date: 2022-11-16 10:50:27
* @LastEditors: Kane
* @LastEditTime: 2022-11-16 15:07:29
* @FilePath: \car_dealer\vue\注册\signup.html
* @Description:
*
* Copyright (c) ${2022} by Kane, All Rights Reserved.
-->
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8" />
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>注册</title>
<link rel="stylesheet" href="../../css/root.css" />
<link rel="stylesheet" href="../../css/normalize.css" />
<link rel="stylesheet" href="../../css/app.css" />
<link rel="stylesheet" href="css/main.css" />
</head>
<body>
<div class="content">
<div id="app">
<h5>加入我们,一起创造美好世界</h5>
<h1>创建你的账号</h1>
<div>
<h6>用户名 *</h6>
<input
type="text"
v-model.lazy.trim="signupInfo.username"
/>
</div>
<div>
<h6>邮箱地址</h6>
<input type="text" v-model.lazy.trim="signupInfo.email" />
</div>
<div>
<h6>密码*</h6>
<input
type="text"
v-model.lazy.trim="signupInfo.password"
/>
<h6>请确认密码长度需要大于6位</h6>
</div>
<div>
<h6>偏好设置</h6>
<div class="pianhao">
<input
type="checkbox"
id="sendUpdateMail"
v-model="signupInfo.sendUpdateMail"
/>
<label for="sendUpdateMail">&nbsp;接收更新邮件</label>
</div>
</div>
<button type="button" @click="doSignup()">创建账号</button>
</div>
</div>
</body>
<script src="../../js/axios/1.1.3/axios.js"></script>
<script src="../../js/vue/vue.global.js"></script>
<script>
const app = {
data() {
return {
signupInfo: {
username: "",
email: "",
password: "",
sendUpdateMail: false,
},
};
},
methods: {
doSignup() {
let json = "";
if (
this.signupInfo.username.length != 0 &&
this.signupInfo.password.length != 0
) {
try {
json = JSON.stringify(this.signupInfo);
} catch (exception) {
console.log(exception.message);
}
} else {
}
console.log(json);
},
},
};
const vm = Vue.createApp(app);
vm.mount("#app");
</script>
</html>

View File

@@ -0,0 +1,61 @@
<!--
* @Author: Kane
* @Date: 2022-11-18 16:07:50
* @LastEditors: Kane
* @LastEditTime: 2022-11-18 16:27:14
* @FilePath: \car_dealer\vue\自定义组件\component.html
* @Description:
*
* Copyright (c) ${2022} by Kane, All Rights Reserved.
-->
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8" />
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>自定义组件</title>
<link rel="stylesheet" href="../../css/root.css" />
<link rel="stylesheet" href="../../css/normalize.css" />
<link rel="stylesheet" href="../../css/app.css" />
</head>
<body>
<div class="content">
<div id="app">
<my-component title="测试" v-model="count"></my-component>
</div>
</div>
</body>
<script src="../../js/vue/vue.global.js"></script>
<script>
const root = {
data() {
return {
count: 0,
value: "",
};
},
};
const component = {
template:
"<div><button @click='doClick($event)'>{{title}}</button></div>",
props: ["title", "modelValue"],
data() {
return {
count: 0,
};
},
methods: {
doClick(event) {
this.count++;
this.$emit("update:modelValue", this.count);
},
},
};
const vm = Vue.createApp(root);
vm.component("my-component", component);
vm.mount("#app");
</script>
</html>

View File

@@ -0,0 +1,88 @@
<!--
* @Author: Kane
* @Date: 2022-11-12 23:21:53
* @LastEditors: Kane
* @LastEditTime: 2022-11-14 16:25:35
* @FilePath: \car_dealer\vue\表单.html
* @Description:
*
* Copyright (c) ${2022} by Kane, All Rights Reserved.
-->
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8" />
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>表单</title>
<link rel="stylesheet" href="../css/root.css" />
<link rel="stylesheet" href="../css/normalize.css" />
<link rel="stylesheet" href="../css/button.css" />
<link rel="stylesheet" href="../css/app.css" />
<link rel="stylesheet" href="../css/表单/表单.css" />
</head>
<body>
<div class="content">
<div id="app">
<p class="grid-left">用户名:</p>
<input
class="grid-right"
type="text"
placeholder=""
v-model="account.username"
/>
<p class="grid-left">密码:</p>
<input type="password" v-model="account.password" />
<p class="grid-left">性别:</p>
<div class="cell-gender">
<input
type="radio"
name="gender"
id="male"
value="male"
v-model="account.gender"
/><label for="male"></label>&nbsp;
<input
type="radio"
name="gender"
id="female"
value="female"
v-model="account.gender"
/><label for="female"></label>
</div>
<p class="grid-left">年龄:</p>
<input type="number" v-model.number="account.age" />
<p class="grid-left">水果:</p>
<select name="fruit" id="fruit" v-model="account.fruits">
<option disabled value="">喜欢的水果</option>
<option v-for="fruit in fruits" v-bind:value="fruit">
{{fruit}}
</option>
</select>
</div>
</div>
</body>
<script src="../js/vue/vue.global.js"></script>
<script src="../js/axios/1.1.3/axios.js"></script>
<script>
const app = {
data() {
return {
account: {
username: "",
password: "",
gender: "",
age: "",
hobbies: [],
fruits: "",
},
fruits: ["香蕉", "梨子", "苹果"],
};
},
};
const vm = Vue.createApp(app);
vm.mount("#app");
</script>
</html>