Merge branch 'main' of https://gitea.lihaink.cn/weipengfei/ERP-admin
This commit is contained in:
commit
77e05647bb
|
@ -1,9 +1,5 @@
|
|||
NODE_ENV = 'development'
|
||||
VITE_NOW_TYPE = 'dist'
|
||||
# Base API
|
||||
|
||||
VITE_PUSH_URL = 'ws://192.168.1.22:8787'
|
||||
VITE_APP_BASE_URL = 'http://192.168.1.22:8546'
|
||||
|
||||
# VITE_PUSH_URL ='wss://erp.lihaink.cn/pull'
|
||||
# VITE_APP_BASE_URL = 'https://erp.lihaink.cn'
|
||||
# VITE_APP_BASE_URL='http://192.168.1.13:8546'
|
||||
VITE_APP_BASE_URL='https://erp.lihaink.cn'
|
||||
|
|
|
@ -12,7 +12,7 @@
|
|||
{{ formData.supplier.service_phone }}
|
||||
</el-descriptions-item>
|
||||
<el-descriptions-item label="供应商地址">
|
||||
{{ formData.supplier?.storeAddress }}
|
||||
{{ formData.supplier?.mer_address }}
|
||||
</el-descriptions-item>
|
||||
<el-descriptions-item label="公司名称" :span="2">
|
||||
{{ dataJSON.company_name }}
|
||||
|
|
|
@ -1,6 +1,7 @@
|
|||
<template>
|
||||
<div class="edit-popup">
|
||||
<popup ref="popupRef" :async="true" width="60vw" @close="handleClose" :bottom-btn="false">
|
||||
|
||||
<el-descriptions class="margin-top" :title="popupTitle" :column="3" border>
|
||||
<el-descriptions-item label="供应商头像">
|
||||
<material-picker v-model="formData.mer_avatar" disabled />
|
||||
|
@ -72,12 +73,30 @@
|
|||
<dict-value :options="dictData.financial_type" :value="formData.financial_type" />
|
||||
</el-descriptions-item>
|
||||
</el-descriptions>
|
||||
<el-card class="mt-5">
|
||||
<template #header>
|
||||
<span>供应商银行账户</span>
|
||||
</template>
|
||||
<el-table :data="formData.supplier_banks">
|
||||
<el-table-column label="id" prop="id" show-overflow-tooltip />
|
||||
<el-table-column label="账户名称" prop="name" show-overflow-tooltip />
|
||||
<el-table-column label="电话" prop="phone" show-overflow-tooltip />
|
||||
<el-table-column label="开户网点" prop="bank_branch" show-overflow-tooltip />
|
||||
<el-table-column label="银行账户" prop="bank_code" show-overflow-tooltip />
|
||||
<el-table-column label="身份证号" prop="id_card" show-overflow-tooltip />
|
||||
<el-table-column label="账户类型" prop="is_own_text" show-overflow-tooltip />
|
||||
<el-table-column label="审核状态" prop="is_check_text" show-overflow-tooltip />
|
||||
<el-table-column label="拒绝原因" prop="fail_msg" show-overflow-tooltip />
|
||||
</el-table>
|
||||
</el-card>
|
||||
|
||||
</popup>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script lang="ts" setup name="brandEdit">
|
||||
import Popup from '@/components/popup/index.vue'
|
||||
|
||||
import type { PropType } from 'vue'
|
||||
defineProps({
|
||||
dictData: {
|
||||
|
@ -128,9 +147,9 @@ const formData = reactive({
|
|||
financial_wechat: '',
|
||||
financial_alipay: '',
|
||||
financial_type: '',
|
||||
supplier_banks: []
|
||||
})
|
||||
|
||||
|
||||
// 表单验证
|
||||
const formRules = reactive<any>({
|
||||
name: [{
|
||||
|
|
|
@ -127,13 +127,13 @@
|
|||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="8">
|
||||
<el-form-item label="供应商电话" prop="service_phone">
|
||||
<el-input v-model="formData.service_phone" clearable placeholder="请输入供应商电话" :readonly="false" />
|
||||
<el-form-item label="供应商电话" prop="phone">
|
||||
<el-input v-model="formData.phone" clearable placeholder="请输入供应商电话" :readonly="false" />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="8">
|
||||
<el-form-item label="供应商余额" prop="mer_money">
|
||||
<el-input v-model="formData.mer_money" clearable placeholder="请输入供应商余额" :readonly="false" />
|
||||
<el-form-item label="供应商余额">
|
||||
<el-input v-model="formData.mer_money" clearable placeholder="请输入供应商余额" readonly />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="8">
|
||||
|
@ -236,12 +236,13 @@ const formData = reactive({
|
|||
commission_switch: '',
|
||||
long: '',
|
||||
lat: '',
|
||||
service_phone: '',
|
||||
phone: '',
|
||||
mer_money: '',
|
||||
financial_bank: '',
|
||||
financial_wechat: '',
|
||||
financial_alipay: '',
|
||||
financial_type: '',
|
||||
service_phone: "",
|
||||
sys_labels_arr: []
|
||||
})
|
||||
const dataJSON = ref({})
|
||||
|
@ -292,7 +293,7 @@ const formRules = reactive<any>({
|
|||
message: '请选择供应商是否禁用0锁定,1正常',
|
||||
trigger: ['blur']
|
||||
}],
|
||||
service_phone: [{
|
||||
phone: [{
|
||||
required: true,
|
||||
message: '请输入供应商电话',
|
||||
trigger: ['blur']
|
||||
|
@ -318,8 +319,12 @@ const setFormData = async (data: Record<any, any>) => {
|
|||
formData[key] = data[key]
|
||||
}
|
||||
}
|
||||
dataJSON.value = JSON.parse(data.data_json||'{}');
|
||||
if(!formData.mer_address) formData.mer_address = dataJSON.value.company_address;
|
||||
formData.phone = formData.service_phone || formData.phone
|
||||
formData.financial_type = data.financial_type == 0 ? '' : data.financial_type
|
||||
formData.sys_labels_text = data.sys_labels_text
|
||||
dataJSON.value = JSON.parse(data.data_json || '{}')
|
||||
dataJSON.value = JSON.parse(data.data_json || '{}');
|
||||
if (!formData.mer_address) formData.mer_address = dataJSON.value.company_address;
|
||||
await getAreaList(formData.city_id, true)
|
||||
await getTownList(formData.area_id, true)
|
||||
getVilllageList(formData.street_id)
|
||||
|
@ -340,6 +345,7 @@ const getDetail = async (row: Record<string, any>) => {
|
|||
const handleSubmit = async () => {
|
||||
await formRef.value?.validate()
|
||||
const data = { ...formData, }
|
||||
data.phone = data.service_phone || data.phone
|
||||
data.sys_labels = data.sys_labels_arr.map(item => {
|
||||
return item.id
|
||||
}).join(',')
|
||||
|
|
|
@ -5,43 +5,23 @@
|
|||
<el-row>
|
||||
<el-col :span="6">
|
||||
<el-form-item label="供应商分类" prop="category_id">
|
||||
<el-select
|
||||
v-model="queryParams.category_id"
|
||||
clearable
|
||||
placeholder="请选择供应商类型"
|
||||
>
|
||||
<el-option
|
||||
v-for="(item, index) in dictData.mer_category_type"
|
||||
:key="index"
|
||||
:label="item.name"
|
||||
:value="parseInt(item.value)"
|
||||
/>
|
||||
<el-select v-model="queryParams.category_id" clearable placeholder="请选择供应商类型">
|
||||
<el-option v-for="(item, index) in dictData.mer_category_type" :key="index" :label="item.name"
|
||||
:value="parseInt(item.value)" />
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="6">
|
||||
<el-form-item label="供应商类型" prop="type_id">
|
||||
<el-select
|
||||
v-model="queryParams.type_id"
|
||||
clearable
|
||||
placeholder="请选择供应商类型"
|
||||
>
|
||||
<el-option
|
||||
v-for="(item, index) in dictData.merchat_type"
|
||||
:key="index"
|
||||
:label="item.name"
|
||||
:value="parseInt(item.value)"
|
||||
/>
|
||||
<el-select v-model="queryParams.type_id" clearable placeholder="请选择供应商类型">
|
||||
<el-option v-for="(item, index) in dictData.merchat_type" :key="index" :label="item.name"
|
||||
:value="parseInt(item.value)" />
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="6">
|
||||
<el-form-item label="供应商名称" prop="mer_name">
|
||||
<el-input
|
||||
v-model="queryParams.mer_name"
|
||||
clearable
|
||||
placeholder="请输入供应商名称"
|
||||
/>
|
||||
<el-input v-model="queryParams.mer_name" clearable placeholder="请输入供应商名称" />
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="6">
|
||||
|
@ -54,21 +34,13 @@
|
|||
</el-form>
|
||||
</el-card>
|
||||
<el-card class="!border-none" v-loading="pager.loading" shadow="never">
|
||||
<el-button
|
||||
v-perms="['supplier.supplier/add']"
|
||||
type="primary"
|
||||
@click="handleAdd"
|
||||
>
|
||||
<el-button v-perms="['supplier.supplier/add']" type="primary" @click="handleAdd">
|
||||
<template #icon>
|
||||
<icon name="el-icon-Plus" />
|
||||
</template>
|
||||
新增
|
||||
</el-button>
|
||||
<el-button
|
||||
v-perms="['supplier.supplier/delete']"
|
||||
:disabled="!selectData.length"
|
||||
@click="handleDelete(selectData)"
|
||||
>
|
||||
<el-button v-perms="['supplier.supplier/delete']" :disabled="!selectData.length" @click="handleDelete(selectData)">
|
||||
删除
|
||||
</el-button>
|
||||
<div class="mt-4">
|
||||
|
@ -87,33 +59,14 @@
|
|||
/>
|
||||
</template>
|
||||
</el-table-column> -->
|
||||
<el-table-column
|
||||
label="供应商类型"
|
||||
prop="type_id"
|
||||
show-overflow-tooltip
|
||||
>
|
||||
<el-table-column label="供应商类型" prop="type_id" show-overflow-tooltip>
|
||||
<template #default="{ row }">
|
||||
<dict-value
|
||||
:options="dictData.merchat_type"
|
||||
:value="row.type_id"
|
||||
/>
|
||||
<dict-value :options="dictData.merchat_type" :value="row.type_id" />
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
label="供应商名称"
|
||||
prop="mer_name"
|
||||
show-overflow-tooltip
|
||||
/>
|
||||
<el-table-column
|
||||
label="结算周期(天)"
|
||||
prop="settle_cycle"
|
||||
show-overflow-tooltip
|
||||
/>
|
||||
<el-table-column
|
||||
label="利率"
|
||||
prop="interest_rate"
|
||||
show-overflow-tooltip
|
||||
/>
|
||||
<el-table-column label="供应商名称" prop="mer_name" show-overflow-tooltip />
|
||||
<el-table-column label="结算周期(天)" prop="settle_cycle" show-overflow-tooltip />
|
||||
<el-table-column label="利率" prop="interest_rate" show-overflow-tooltip />
|
||||
<!-- <el-table-column
|
||||
label="标签"
|
||||
prop="sys_labels_arr"
|
||||
|
@ -125,26 +78,14 @@
|
|||
}}</span>
|
||||
</template>
|
||||
</el-table-column> -->
|
||||
<el-table-column
|
||||
label="供应商地址"
|
||||
prop="mer_address"
|
||||
show-overflow-tooltip
|
||||
/>
|
||||
<el-table-column label="供应商地址" prop="mer_address" show-overflow-tooltip />
|
||||
<el-table-column label="供应商是否禁用" prop="status">
|
||||
<template #default="{ row }">
|
||||
<dict-value :options="dictData.show_status" :value="row.status" />
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
label="提成比例"
|
||||
prop="commission_rate"
|
||||
show-overflow-tooltip
|
||||
/>
|
||||
<el-table-column
|
||||
label="供应商手续费单独设置"
|
||||
width="200"
|
||||
prop="commission_switch"
|
||||
>
|
||||
<el-table-column label="提成比例" prop="commission_rate" show-overflow-tooltip />
|
||||
<el-table-column label="供应商手续费单独设置" width="200" prop="commission_switch">
|
||||
<template #default="{ row }">
|
||||
<!-- <dict-value :options="dictData.show_status" :value="row.commission_switch" /> -->
|
||||
{{ row.commission_switch ? "开启" : "关闭" }}
|
||||
|
@ -157,31 +98,19 @@
|
|||
/>
|
||||
<el-table-column label="操作" width="200" fixed="right">
|
||||
<template #default="{ row }">
|
||||
<el-button
|
||||
v-perms="['supplier.supplier/edit']"
|
||||
type="primary"
|
||||
link
|
||||
@click="handleEdit(row)"
|
||||
>
|
||||
<el-button v-perms="['supplier.supplier/edit']" type="primary" link @click="handleEdit(row)">
|
||||
编辑
|
||||
</el-button>
|
||||
<el-button
|
||||
v-perms="['supplier.supplier/delete']"
|
||||
type="danger"
|
||||
link
|
||||
@click="handleDelete(row.id)"
|
||||
>
|
||||
<el-button v-perms="['supplier.supplier/delete']" type="danger" link @click="handleDelete(row.id)">
|
||||
删除
|
||||
</el-button>
|
||||
<el-button link @click="handleDetail(row.id)"> 详情 </el-button>
|
||||
<router-link
|
||||
:to="{
|
||||
path: 'bindGoods',
|
||||
query: {
|
||||
id: row.id,
|
||||
},
|
||||
}"
|
||||
>
|
||||
<router-link :to="{
|
||||
path: 'bindGoods',
|
||||
query: {
|
||||
id: row.id,
|
||||
},
|
||||
}">
|
||||
<el-button link type="primary"> 商品绑定 </el-button>
|
||||
</router-link>
|
||||
<el-button v-if="!row.uid" link @click="bindUser(row)" type="primary">
|
||||
|
|
|
@ -173,8 +173,6 @@ const setFormData = async (data: Record<any, any>) => {
|
|||
form.arrival_proof = JSON.parse(data.arrival_proof)
|
||||
}
|
||||
form.id = data.id
|
||||
|
||||
|
||||
}
|
||||
|
||||
const getDetail = async (row: Record<string, any>) => {
|
||||
|
|
|
@ -0,0 +1,120 @@
|
|||
<!DOCTYPE html>
|
||||
<html lang="zh">
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
<title>登录页面</title>
|
||||
<link rel="stylesheet" href="style.css">
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<div class="login-wrap">
|
||||
<div class="login-container">
|
||||
<h2 class="login-title">欢迎登录</h2>
|
||||
<form action="/your-login-processing-url" method="post">
|
||||
<div class="input-field">
|
||||
<i class="fas fa-user icon"></i>
|
||||
<input type="text" id="username" name="username" placeholder="用户名" required>
|
||||
</div>
|
||||
<div class="input-field">
|
||||
<i class="fas fa-lock icon"></i>
|
||||
<input type="password" id="password" name="password" placeholder="密码" required>
|
||||
</div>
|
||||
<button type="submit" class="login-btn">登录</button>
|
||||
<p class="signup-link">还没有账号?<a href="#">立即注册</a></p>
|
||||
</form>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</body>
|
||||
</html>
|
||||
|
||||
<style>
|
||||
@import url('https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.0.0-beta3/css/all.min.css');
|
||||
|
||||
body, html {
|
||||
height: 100%;
|
||||
margin: 0;
|
||||
font-family: 'Roboto', sans-serif;
|
||||
background-image: linear-gradient(to right, #f0f2f5, #dfe4ea);
|
||||
}
|
||||
|
||||
.login-wrap {
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
height: 100%;
|
||||
}
|
||||
|
||||
.login-container {
|
||||
width: 100%;
|
||||
max-width: 400px;
|
||||
padding: 30px;
|
||||
background-color: white;
|
||||
border-radius: 10px;
|
||||
box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
|
||||
}
|
||||
|
||||
.login-title {
|
||||
text-align: center;
|
||||
margin-bottom: 30px;
|
||||
color: #333;
|
||||
}
|
||||
|
||||
.input-field {
|
||||
position: relative;
|
||||
margin-bottom: 20px;
|
||||
}
|
||||
|
||||
.input-field input {
|
||||
width: 100%;
|
||||
padding: 15px 20px 15px 45px;
|
||||
border: 1px solid #ddd;
|
||||
border-radius: 5px;
|
||||
outline: none;
|
||||
transition: all 0.3s ease;
|
||||
}
|
||||
|
||||
.input-field input:focus {
|
||||
border-color: #0099cc;
|
||||
}
|
||||
|
||||
.icon {
|
||||
position: absolute;
|
||||
top: 50%;
|
||||
left: 15px;
|
||||
transform: translateY(-50%);
|
||||
color: #aaa;
|
||||
}
|
||||
|
||||
.login-btn {
|
||||
width: 100%;
|
||||
padding: 15px;
|
||||
background-color: #0099cc;
|
||||
color: white;
|
||||
border: none;
|
||||
border-radius: 5px;
|
||||
cursor: pointer;
|
||||
font-size: 16px;
|
||||
transition: all 0.3s ease;
|
||||
}
|
||||
|
||||
.login-btn:hover {
|
||||
background-color: #0077aa;
|
||||
}
|
||||
|
||||
.signup-link {
|
||||
text-align: center;
|
||||
margin-top: 20px;
|
||||
color: #777;
|
||||
}
|
||||
|
||||
.signup-link a {
|
||||
color: #0099cc;
|
||||
text-decoration: none;
|
||||
}
|
||||
|
||||
.signup-link a:hover {
|
||||
text-decoration: underline;
|
||||
}
|
||||
</style>
|
Loading…
Reference in New Issue