master
阿丽 3 years ago
parent c31e544330
commit 57aa6d42ef

27099
package-lock.json generated

File diff suppressed because it is too large Load Diff

@ -8,8 +8,18 @@
"lint": "vue-cli-service lint" "lint": "vue-cli-service lint"
}, },
"dependencies": { "dependencies": {
"axios": "^0.26.0",
"core-js": "^3.6.5", "core-js": "^3.6.5",
"vue": "^2.6.11" "cz-storage": "^1.0.1",
"element-ui": "^2.15.6",
"less": "^4.1.2",
"less-loader": "5.0.0",
"nprogress": "^0.2.0",
"permission": "^1.1.0",
"vue": "^2.6.11",
"vue-router": "^3.5.3",
"vuex": "^3.6.2",
"moment": "^2.29.1"
}, },
"devDependencies": { "devDependencies": {
"@vue/cli-plugin-babel": "~4.5.15", "@vue/cli-plugin-babel": "~4.5.15",

@ -1,28 +1,27 @@
<template> <template>
<div id="app"> <div id="app">
<img alt="Vue logo" src="./assets/logo.png"> <router-view></router-view>
<HelloWorld msg="Welcome to Your Vue.js App"/>
</div> </div>
</template> </template>
<script> <script>
import HelloWorld from './components/HelloWorld.vue'
export default { export default {
name: 'App', name: "App",
components: { data() {
HelloWorld return {
} };
} },
mounted() {
},
components: {},
};
</script> </script>
<style> <style lang="less" scoped>
#app { #app {
font-family: Avenir, Helvetica, Arial, sans-serif;
-webkit-font-smoothing: antialiased; width: 100%;
-moz-osx-font-smoothing: grayscale; height: 100%;
text-align: center;
color: #2c3e50;
margin-top: 60px;
} }
</style> </style>

@ -1,58 +0,0 @@
<template>
<div class="hello">
<h1>{{ msg }}</h1>
<p>
For a guide and recipes on how to configure / customize this project,<br>
check out the
<a href="https://cli.vuejs.org" target="_blank" rel="noopener">vue-cli documentation</a>.
</p>
<h3>Installed CLI Plugins</h3>
<ul>
<li><a href="https://github.com/vuejs/vue-cli/tree/dev/packages/%40vue/cli-plugin-babel" target="_blank" rel="noopener">babel</a></li>
<li><a href="https://github.com/vuejs/vue-cli/tree/dev/packages/%40vue/cli-plugin-eslint" target="_blank" rel="noopener">eslint</a></li>
</ul>
<h3>Essential Links</h3>
<ul>
<li><a href="https://vuejs.org" target="_blank" rel="noopener">Core Docs</a></li>
<li><a href="https://forum.vuejs.org" target="_blank" rel="noopener">Forum</a></li>
<li><a href="https://chat.vuejs.org" target="_blank" rel="noopener">Community Chat</a></li>
<li><a href="https://twitter.com/vuejs" target="_blank" rel="noopener">Twitter</a></li>
<li><a href="https://news.vuejs.org" target="_blank" rel="noopener">News</a></li>
</ul>
<h3>Ecosystem</h3>
<ul>
<li><a href="https://router.vuejs.org" target="_blank" rel="noopener">vue-router</a></li>
<li><a href="https://vuex.vuejs.org" target="_blank" rel="noopener">vuex</a></li>
<li><a href="https://github.com/vuejs/vue-devtools#vue-devtools" target="_blank" rel="noopener">vue-devtools</a></li>
<li><a href="https://vue-loader.vuejs.org" target="_blank" rel="noopener">vue-loader</a></li>
<li><a href="https://github.com/vuejs/awesome-vue" target="_blank" rel="noopener">awesome-vue</a></li>
</ul>
</div>
</template>
<script>
export default {
name: 'HelloWorld',
props: {
msg: String
}
}
</script>
<!-- Add "scoped" attribute to limit CSS to this component only -->
<style scoped>
h3 {
margin: 40px 0 0;
}
ul {
list-style-type: none;
padding: 0;
}
li {
display: inline-block;
margin: 0 10px;
}
a {
color: #42b983;
}
</style>

@ -0,0 +1,38 @@
<template>
<div class="th-container">
<span class="th-title">{{title}}</span>
<div>
<slot></slot>
</div>
</div>
</template>
<script>
export default {
name: "TopHeader",
props: {
title: {
type: String,
default: ""
}
}
}
</script>
<style lang="less" scoped>
.th-container {
display: flex;
padding: 0px 16px;
justify-content: space-between;
height: 36px;
align-items: center;
background-color: rgb(255, 255, 255);
border-bottom: 1px solid #d8d8d8;
}
.th-title {
color: rgb(182, 188, 203);
font-weight: 500;
font-size: 16px;
font-weight: 15px;
}
</style>

@ -0,0 +1,10 @@
import TopHeader from "./TopHeader";
export default {
install(Vue) {
Vue.mixin({
components: {
TopHeader,
}
})
}
}

@ -1,8 +1,17 @@
import Vue from 'vue' import Vue from 'vue'
import App from './App.vue' import App from './App.vue'
import router from "@/permission";
import ElementUI from 'element-ui';
import 'element-ui/lib/theme-chalk/index.css';
Vue.use(ElementUI, {size: 'small'});
import '@/styles/index.less';
import store from "@/store";
import selfUi from "@/components/index.js";
Vue.use(selfUi);
Vue.config.productionTip = false Vue.config.productionTip = false
new Vue({ new Vue({
render: h => h(App), render: h => h(App),
router,
store
}).$mount('#app') }).$mount('#app')

@ -0,0 +1,30 @@
/*
* @Author: your name
* @Date: 2021-11-18 17:34:50
* @LastEditTime: 2022-01-11 10:54:42
* @LastEditors: Please set LastEditors
* @Description: 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
* @FilePath: /ansu-business/src/permission.js
*/
import NProgress from "nprogress"
import "nprogress/nprogress.css"
import router from "@/router"
// import store from '@/store'
// const whitePath = [ '/login']
router.beforeEach((to, from, next) => {
NProgress.start()
// const token = store.getters.getToken;
// if(!token && !whitePath.includes(to.path)) {
// next('/login');
// } else {
// next();
// }
next();
})
router.afterEach(() => {
NProgress.done()
})
export default router

@ -0,0 +1,43 @@
/*
* @Author: your name
* @Date: 2021-12-17 10:35:07
* @LastEditTime: 2021-12-17 13:19:09
* @LastEditors: Please set LastEditors
* @Description: 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
* @FilePath: /chinaoffer-phone/src/router/index.js
*/
import Vue from 'vue'
import Router from 'vue-router'
import Vehicleevaluation from '../views/Vehicleevaluation/index.vue'
import Scoresituation from '../views/Scoresituation/index.vue'
const originalPush = Router.prototype.push
Router.prototype.push = function push(location) {
return originalPush.call(this, location).catch(err => err)
}
Vue.use(Router)
const router = [
{
path: '/',
name: "Layout",
component: resolve => require(['@/views/Layout'], resolve),
redirect:'/Vehicleevaluation',
children: [
{
path: '/Vehicleevaluation',
name: 'Vehicleevaluation',
component: Vehicleevaluation,
},
{
path: '/Scoresituation',
name: 'Scoresituation',
component: Scoresituation,
},
]
},
]
export default new Router({
mode: 'history',
routes: router
})

@ -0,0 +1,29 @@
/*
* @Author: your name
* @Date: 2022-02-14 11:54:56
* @LastEditTime: 2022-02-16 10:12:04
* @LastEditors: Please set LastEditors
* @Description: 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
* @FilePath: /yyac-system/src/store/actions.js
*/
const actions = {
setToken: ({ commit }, log) => {
commit('setToken', log);
},
setTags: ({ commit }, log) => {
commit('setTags', log);
},
setNavBarIndex: ({ commit }, log) => {
commit('setNavBarIndex', log);
},
delTags: ({ commit }, log) => {
commit('delTags', log)
},
setOpenedKeys: ({ commit }, log) => {
commit('setOpenedKeys', log);
},
delOpenedKeys: ({ commit }, log) => {
commit('delOpenedKeys', log);
},
}
export default actions

@ -0,0 +1,23 @@
/*
* @Author: your name
* @Date: 2022-02-14 11:56:12
* @LastEditTime: 2022-02-16 10:06:13
* @LastEditors: Please set LastEditors
* @Description: 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
* @FilePath: /yyac-system/src/store/getters.js
*/
const getters = {
getToken(state) {
return state.token
},
getTags(state) {
return state.tags
},
getNavBarIndex(state) {
return state.navBarIndex
},
getOpenedKeys(state) {
return state.openedKeys
}
}
export default getters

@ -0,0 +1,23 @@
/*
* @Author: your name
* @Date: 2022-02-14 11:54:23
* @LastEditTime: 2022-02-14 11:54:24
* @LastEditors: Please set LastEditors
* @Description: 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
* @FilePath: /yyac-system/src/store/index.js
*/
import Vue from "vue";
import Vuex from "vuex";
Vue.use(Vuex);
import actions from "./actions";
import mutations from "./mutations";
import getters from "./getters";
import state from "./state";
const store = new Vuex.Store({
state,
actions,
mutations,
getters
})
export default store

@ -0,0 +1,60 @@
/*
* @Author: your name
* @Date: 2022-02-14 11:55:31
* @LastEditTime: 2022-02-16 10:13:40
* @LastEditors: Please set LastEditors
* @Description: 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
* @FilePath: /yyac-system/src/store/mutations.js
*/
import LS from 'cz-storage'
const mutations = {
setTags: (state, log) => {
const arr = state.tags;
if (Array.isArray(arr)) {
const n = arr.findIndex(ele => ele.path === log.path);
if (n === -1) {
arr.push(log);
}
let str = JSON.stringify(arr);
LS.put('tags', str, 1 / 8);
}
},
setToken: (state, log) => {
state.token = log
LS.put('token', log, 1 / 8);
},
setNavBarIndex: (state, log) => {
state.navBarIndex = log
LS.put('navBarIndex', log, 1 / 8);
},
delTags: (state, log) => {
const arr = state.tags;
arr.splice(log, 1);
let str = JSON.stringify(arr);
LS.put('tags', str);
},
setOpenedKeys: (state, log) => {
const arr = state.openedKeys;
if (Array.isArray(arr)) {
const n = arr.findIndex(ele => ele === log);
if (n === -1) {
arr.push(log);
}
let str = JSON.stringify(arr);
LS.put('openedKeys', str, 1 / 8);
}
},
delOpenedKeys: (state, log) => {
const arr = state.openedKeys;
if (Array.isArray(arr)) {
const n = arr.findIndex(ele => ele === log);
if (n != -1) {
arr.splice(n, 1);
}
let str = JSON.stringify(arr);
LS.put('openedKeys', str, 1 / 8);
}
},
}
export default mutations;

@ -0,0 +1,17 @@
/*
* @Author: your name
* @Date: 2022-02-14 11:56:51
* @LastEditTime: 2022-02-16 10:03:13
* @LastEditors: Please set LastEditors
* @Description: 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
* @FilePath: /yyac-system/src/store/state.js
*/
import LS from 'cz-storage'
const state = {
tags: JSON.parse(LS.get("tags"))|| [],
token: LS.get("token") || "",
navBarIndex: LS.get("navBarIndex") || "",
openedKeys: JSON.parse(LS.get("openedKeys")) || []
}
export default state;

@ -0,0 +1,28 @@
.el-container {
width: 100%;
height: 100%;
background: #eff2f5;
}
.el-aside {
background: #fff;
border-right: 1px solid #f0f2f9;
}
.el-header {
background: #fff;
padding: 0px !important;
box-shadow: 0px 20px 20px -20px #bababa;
z-index: 300;
}
.el-menu {
width: 230px;
border-right-style: none !important;
}
.el-main {
padding: 7px 10px !important;
}
.el-tabs--top .el-tabs__item.is-top:nth-child(2) {
padding-left: 20px !important;
}
body .el-table th.gutter {
display: table-cell !important
}

Binary file not shown.

@ -0,0 +1,26 @@
@import url(./element.less);
@font-face {
font-family: "myFont";
src: url("./font/PingFangSC-Semibold.ttf"),
url("./font/PingFangSC.ttf");
}
html,body {
width: 100%;
height: 100%;
font-size: 62.5%;
color: #3c3c3c;
font-family: 'myFont';
}
.page-container {
position: relative;
width: 100%;
min-height: 100%;
background: #fff;
border-radius: 4px;
}
.y-btn {
cursor: pointer;
display: inline-block;
margin-right: 10px;
}

@ -0,0 +1,18 @@
<template>
<div class="app">
<router-view></router-view>
</div>
</template>
<script>
export default {
name: "App",
};
</script>
<style lang="less" scoped>
#app {
width: 100%;
height: 100%;
}
</style>

@ -0,0 +1,72 @@
<template>
<div id="app">
<TopHeader title="车辆评估系统得分情况" />
<div class="appbox">
<div class="app-left">
<el-descriptions title="凯美瑞车辆评估报告:" size="medium" column=1 :contentStyle="{'color': 'rgb(22, 93, 253)'}">
<el-descriptions-item label="1.过户得分">9</el-descriptions-item>
<el-descriptions-item label="2.公里数得分">11</el-descriptions-item>
<el-descriptions-item label="3.油漆面得分">7</el-descriptions-item>
<el-descriptions-item label="4.钣金得分">7</el-descriptions-item>
<el-descriptions-item label="5.更换件得分">13</el-descriptions-item>
<el-descriptions-item label="6.发动机变速箱状态得分">40</el-descriptions-item>
<el-descriptions-item label="7.重大事故得分">0</el-descriptions-item>
<el-descriptions-item label="8.全程4S店保养得分">5</el-descriptions-item>
</el-descriptions>
</div>
<div class="app-right">
<el-descriptions size="40" column=1 :contentStyle="{'color': 'rgb(22, 93, 253)'}">
<el-descriptions-item label="最终得分">60.9</el-descriptions-item>
<el-descriptions-item label="车辆状态">良好{中间值}</el-descriptions-item>
</el-descriptions>
</div>
</div>
<el-button class="orangeBtn" type="primary" @click="onSubmit"></el-button>
</div>
</template>
<script>
export default {
data() {
return {};
},
methods: {
onSubmit() {
console.log("submit!");
},
},
};
</script>
<style lang="less" scoped>
#app {
width: 100%;
height: 100%;
text-align: center;
}
.appbox {
width: 50%;
display: flex;
padding: 10px 50px;
margin: 0 auto;
}
.app-left {
width: 50%;
border-right: 2px dashed #333332;
text-align: center;
margin-right: 20px;
}
.app-right {
width: 50%;
height: 100%;
text-align: center;
margin: auto;
}
.orangeBtn {
width: 15%;
margin: 20px;
}
</style>

@ -0,0 +1,377 @@
<template>
<div id="app">
<TopHeader title="车辆评估系统" />
<div class="app-xt">
<el-form ref="form" label-position="left" :model="form">
<el-form-item label="1.车辆型号:">
<el-input type="text" v-model="form.name" style="width: 150px;"></el-input>
</el-form-item>
<el-form-item label="2.车辆年份:">
<el-date-picker v-model="form.month" type="monthrange" align="right" unlink-panels range-separator="至" start-placeholder="开始月份" end-placeholder="结束月份" @blur="getRemainderTime">
</el-date-picker>
<el-select v-model="form.region" placeholder="请选择" style="width: 150px;">
<el-option v-for="item in region" :value="item.id" :key="item.id" :label="item.name"></el-option>
</el-select>
</el-form-item>
<el-form-item label="3.过户次数:">
<el-select v-model="form.frequency" placeholder="请选择" style="width: 150px;">
<el-option v-for="item in frequency" :value="item.id" :key="item.id1" :label="item.name"></el-option>
</el-select>
</el-form-item>
<el-form-item label="4.公里数:">
<el-input type="text" v-model="form.Kilometers" style="width: 150px;"><i slot="suffix"></i></el-input>
</el-form-item>
<el-form-item label="5.油漆面:">
<el-select v-model="form.surface" placeholder="请选择" style="width: 150px;">
<el-option v-for="item in surface" :value="item.id" :key="item.id2" :label="item.name"></el-option>
</el-select>
</el-form-item>
<el-form-item label="6.钣金面:">
<el-select v-model="form.Sheet" placeholder="请选择" style="width: 150px;">
<el-option v-for="item in Sheet" :value="item.id" :key="item.id3" :label="item.name"></el-option>
</el-select>
</el-form-item>
</el-form>
<el-form ref="form" label-position="top" :model="form">
<el-form-item label="7.更换配件,有则打勾:">
<el-checkbox-group v-model="form.tick">
<el-col :span="4">
<el-checkbox label="右大灯" name="type"></el-checkbox>
</el-col>
<el-col :span="4">
<el-checkbox label="左大灯" name="type"></el-checkbox>
</el-col>
<el-col :span="4">
<el-checkbox label="右尾灯" name="type"></el-checkbox>
</el-col>
<el-col :span="4">
<el-checkbox label="左尾灯" name="type"></el-checkbox>
</el-col>
<el-col :span="4">
<el-checkbox label="前保险杠" name="type"></el-checkbox>
</el-col>
<el-col :span="4">
<el-checkbox label="后保险杠" name="type"></el-checkbox>
</el-col>
<el-col :span="4">
<el-checkbox label="前右翼子板" name="type"></el-checkbox>
</el-col>
<el-col :span="4">
<el-checkbox label="前左翼子板" name="type"></el-checkbox>
</el-col>
<el-col :span="4">
<el-checkbox label="前右后门" name="type"></el-checkbox>
</el-col>
<el-col :span="4">
<el-checkbox label="前左后门" name="type"></el-checkbox>
</el-col>
<el-col :span="4">
<el-checkbox label="后右后门" name="type"></el-checkbox>
</el-col>
<el-col :span="4">
<el-checkbox label="后左后门" name="type"></el-checkbox>
</el-col>
</el-checkbox-group>
</el-form-item>
<el-form-item label="8.发动机变速箱状态:">
<el-radio-group v-model="form.state">
<el-radio label="轻微渗油"></el-radio>
<el-radio label="严重渗油"></el-radio>
<el-radio label="发动机解体维修"></el-radio>
</el-radio-group>
</el-form-item>
<el-form-item label="9.:
柱发生修复后翼子板切割)">
<el-radio-group v-model="form.accident">
<el-radio label="是"></el-radio>
<el-radio label="否"></el-radio>
</el-radio-group>
</el-form-item>
<el-form-item label="10.是否全程4S店保养:">
<el-radio-group v-model="form.maintain">
<el-radio label="是"></el-radio>
<el-radio label="否"></el-radio>
</el-radio-group>
</el-form-item>
<el-form-item>
<el-button class="orangeBtn" type="primary" @click="onSubmit"></el-button>
</el-form-item>
</el-form>
</div>
</div>
</template>
<script>
export default {
data() {
return {
value2: "",
form: {
month: "",
name: "",
region: "",
frequency: "",
Kilometers: "",
surface: "",
Sheet: "",
tick: [],
state: "",
accident: "",
maintain: "",
},
afterSubmit: {
frequency: 10,
surface: 10,
Sheet: 10,
Kilometers: 15,
},
region: [
{
id: 1,
name: "2010年",
},
{
id: 2,
name: "2011年",
},
{
id: 3,
name: "2012年",
},
{
id: 4,
name: "2013年",
},
{
id: 5,
name: "2014年",
},
{
id: 6,
name: "2015年",
},
{
id: 7,
name: "2016年",
},
{
id: 8,
name: "2017年",
},
{
id: 9,
name: "2018年",
},
{
id: 10,
name: "2019年",
},
{
id: 11,
name: "2020年",
},
{
id: 12,
name: "2021年",
},
],
//
Sheet: [
{
id: 0,
name: "0面",
},
{
id: 1,
name: "1面",
},
{
id: 2,
name: "2面",
},
{
id: 3,
name: "3面",
},
{
id: 4,
name: "4面",
},
{
id: 5,
name: "5面",
},
{
id: 6,
name: "6面",
},
{
id: 7,
name: "7面",
},
{
id: 8,
name: "8面",
},
{
id: 9,
name: "9面",
},
{
id: 10,
name: "10面",
},
{
id: 10,
name: "11面及以上",
},
],
//
surface: [
{
id: 0,
name: "0面",
},
{
id: 1,
name: "1面",
},
{
id: 2,
name: "2面",
},
{
id: 3,
name: "3面",
},
{
id: 4,
name: "4面",
},
{
id: 5,
name: "5面",
},
{
id: 6,
name: "6面",
},
{
id: 7,
name: "7面",
},
{
id: 8,
name: "8面",
},
{
id: 9,
name: "9面",
},
{
id: 10,
name: "10面",
},
{
id: 10,
name: "11面及以上",
},
],
//
frequency: [
{
id: 0,
name: "0次",
},
{
id: 1,
name: "1次",
},
{
id: 2,
name: "2次",
},
{
id: 3,
name: "3次",
},
{
id: 4,
name: "4次",
},
{
id: 5,
name: "5次",
},
{
id: 6,
name: "6次",
},
{
id: 7,
name: "7次",
},
{
id: 8,
name: "8次",
},
{
id: 9,
name: "9次",
},
{
id: 10,
name: "10次",
},
{
id: 10,
name: "11次及以上",
},
],
};
},
methods: {
getRemainderTime(startTime, endTime) {
var s1 = new Date(startTime.replace(/-/g, "/")),
s2 = new Date(endTime.replace(/-/g, "/")),
runTime = parseInt((s2.getTime() - s1.getTime()) / 1000);
var year = Math.floor(runTime / 86400 / 365);
runTime = runTime % (86400 * 365);
var month = Math.floor(runTime / 86400 / 30);
return year + "," + month;
},
onSubmit() {
//
let frequency = this.afterSubmit.frequency - this.form.frequency;
//
let surface = this.afterSubmit.surface - this.from.surface;
//
let Sheet = this.afterSubmit.Sheet - this.from.Sheet;
//
let Kilometers =this.afterSubmit.Sheet - ((this.from.Kilometers * 10000) / this.getRemainderTime) ;
//
let total = frequency + surface + Sheet + Kilometers;
console.log('month')
console.log("total score = " + total);
},
},
};
</script>
<style lang="less" scoped>
#app {
width: 100%;
height: 100%;
}
.app-xt {
width: 45%;
padding: 10px 50px;
background-color: rgb(236, 247, 243);
margin: 0 auto;
}
.orangeBtn {
width: 30%;
margin: 0 auto;
}
</style>

File diff suppressed because it is too large Load Diff
Loading…
Cancel
Save