Commit 26029be5 authored by 李苏's avatar 李苏 💬

移除项目,引用公用ERP项目

parent 186f179d
<template>
<RelDialog width="50%" :type='type' :editApp='editApp' :app='app' :buttonApp='buttonApp'>
<el-form slot="form" ref="form" :model="form" label-width="100px" :rules="rules">
<el-row :gutter="20" :app="this">
<EditColItem :required="item.required||false" :readonly="item.readonly?true:false " v-for="(item,index) in editColItemList " :value="item.value" :span="item.span" :label="item.label" :prop='item.prop' :key="item.prop" :type="item.type" :typeConfig='item.typeConfig' :rule="item.rule" />
</el-row>
</el-form>
</RelDialog>
</template>
<script>
import {
editMixin
} from 'common'
export default {
mixins: [editMixin],
data() {
return {
editColItemList: [
{
label: '人员编码',
prop: 'usercode',
span: 12,
type: 'input',
required:'true',
},
{
label: '姓名',
prop: 'username',
span: 12,
type: 'input',
required:true,
},
{
label: '手机号',
prop: 'phone',
span: 12,
type: 'inputNumber',
rule:'phone'
},
{
label: '部门',
prop: 'bmid',
span: 12,
type: 'RelSelect',
typeConfig:{
match:{
key:'bmid',
value:'bmmc',
},
src:'/kzzx/bm/query'
}
},
{
label: '备注',
prop: 'bz',
span: 24,
type: 'input'
},
]
}
}
}
</script>
<template>
<div class="min_full">
<!-- 查询条件-->
<div class="search" v-condition>
<SearchButton :app='app'></SearchButton>
<el-row :gutter="20" class="search-row-1">
<el-col :span="6" class="search-col">
<div class="search-item">
<span class="search-span">部门:</span>
<RelSelect style="width: 100%;" src='jcsj/common/bm/queryXsckBm' filterable clearable
:match="{value:'id',label:'bmmc'}" v-model='queryParams.bmid'></RelSelect>
</div>
</el-col>
<el-col :span="6" class="search-col">
<div class="search-item">
<span class="search-span">人员信息:</span>
<el-input v-model="queryParams.userinfo"></el-input>
</div>
</el-col>
</el-row>
</div>
<!-- 按钮操作-->
<el-row class="tool-bar">
<ToolButton :app='app'></ToolButton>
<ViewButton ref="view" :app='app'></ViewButton>
<AddButton ref="add" :app='app'></AddButton>
<CopyButton ref="copy" :app='app'></CopyButton>
<EditButton ref="edit" :app='app'></EditButton>
<ImportPersonnelButton @save="save" />
<!-- 额外按钮-->
<!-- 表头设置 -->
<!-- 权限-->
</el-row>
<!-- 表格-->
<div class="tablePagers">
<TablePager @getData='getData' :ref="'TablePager'" :app='app' :query='query' @selectItem='selectItem'
@getRow='getRow'>
</TablePager>
</div>
</div>
</template>
<script>
import {
doQuery,
doAdd,
doUpdate,
doDelete,
importXsry
} from '@/api/baseData/custom/attribute.js';
/* edit页面*/
import Edit from './edit'
import {
tableMixin
} from 'common'
export default {
mixins: [tableMixin],
name: 'customAttribute',
/* 初始额外赋值*/
async mounted() {
this.$refs['TablePager'].pageQuery()
},
data() {
return {
/*需要的额外参数 */
// showDialog: false,
// DialogName: '',
// type: '',
// DialogTitle: '',
/* 基础url*/
baseUrl: 'csj/xsry',
/* 查询参数*/
queryParams: {
userinfo: '',
bmid: ''
},
/* 表格标题对应参数*/
tableTitle: [
{title: "人员编码",field: "usercode",width:140},
{title: "姓名", field: "username",width:140},
{title: "人员编码", field: "userid", fieldType:"ftString",width:140,hidden:true},
{title: "部门编码", field: "bmid", fieldType:"ftString",width:140,hidden:true},
{title: "部门名称", field: "bmName", fieldType:"ftString",width:140},
{title: "备注", field: "bz", fieldType:"ftString",width:240},
{title: "维护人", field: "whr", fieldType:"username"},
{title: "维护时间", field: "whsj", fieldType:"ftDateTime"}
]
}
},
methods: {
save(list){
importXsry({
userList:list
}).then(res=>{
if(res.success){
this.$success('添加成功')
this.$refs['TablePager'].pageQuery()
}
})
},
/* 基础查询*/
query: doQuery,
/* 基础增*/
apiAdd: doAdd,
/* 基础更新*/
apiUpdate: doUpdate,
/* 删除操作*/
apiDelete: doDelete,
/* 初始化赋值操作*/
// init() {
// }
},
components: {
Edit,
}
}
</script>
<style scoped>
</style>
<template>
<RelDialog width="50%" :type='type' :editApp='editApp' :app='app' :buttonApp='buttonApp'>
<el-form slot="form" ref="form" :model="form" label-width="100px" :rules="rules">
<el-row :gutter="20" :app="this">
<EditColItem :required="item.required||false" :readonly="item.readonly?true:false " v-for="(item,index) in editColItemList " :value="item.value" :span="item.span" :label="item.label" :prop='item.prop' :key="item.prop" :type="item.type" :typeConfig='item.typeConfig' :rule="item.rule" />
</el-row>
</el-form>
</RelDialog>
</template>
<script>
import {
editMixin
} from 'common'
export default {
mixins: [editMixin],
data() {
return {
editColItemList: [
{
label: '编码',
prop: 'code',
span: 12,
type: 'input',
required:true,
},
{
label: '名称',
prop: 'name',
span: 12,
type: 'input',
required:true,
},
{
label: '备注',
prop: 'bz',
span: 24,
type: 'input'
},
]
}
}
}
</script>
<template>
<div class="min_full">
<!-- 按钮操作-->
<el-row class="tool-bar">
<ToolButton :app='app'></ToolButton>
<ViewButton ref="view" :app='app'></ViewButton>
<AddButton ref="add" :app='app'></AddButton>
<CopyButton ref="copy" :app='app'></CopyButton>
<EditButton ref="edit" :app='app'></EditButton>
<!-- <AttachFileButton :app='app' ></AttachFileButton> -->
<!-- 额外按钮-->
<!-- 表头设置 -->
<!-- 权限-->
</el-row>
<!-- 表格-->
<div class="tablePagers">
<TablePager @getData='getData' :ref="'TablePager'" :app='app' :query='query' @selectItem='selectItem'
@getRow='getRow'>
</TablePager>
</div>
</div>
</template>
<script>
import {
doQuery,
doAdd,
doUpdate,
doDelete
} from '@/api/baseData/custom/classification.js';
/* edit页面*/
import Edit from './edit'
import {
tableMixin
} from 'common'
export default {
mixins: [tableMixin],
name: 'customClassification',
/* 初始额外赋值*/
async mounted() {
this.$refs['TablePager'].pageQuery()
},
data() {
return {
/*需要的额外参数 */
showDialog: false,
DialogName: '',
type: '',
DialogTitle: '',
/* 基础url*/
baseUrl: 'jcsj/khfl',
/* 查询参数*/
queryParams: {
info: '',
gsid: ''
},
/* 表格标题对应参数*/
tableTitle: [
{title: "编码", field: "code", fieldType:"upper",width: 140},
{title: "名称", field: "name", width: 160},
{title: "停用", field: "tybz"},
{title: "停用日期", field: "tyrq", fieldType:"ftDate"},
{title: "备注", field: "bz",width: 250},
{title: "维护人", field: "whr"},
{title: "维护时间", field: "whsj", fieldType:"ftDateTime"}
]
}
},
methods: {
/* 基础查询*/
query: doQuery,
/* 基础增*/
apiAdd: doAdd,
/* 基础更新*/
apiUpdate: doUpdate,
/* 删除操作*/
apiDelete: doDelete,
/* 初始化赋值操作*/
init() {
}
},
components: {
Edit,
}
}
</script>
<style scoped>
</style>
<template>
<section class="app-main">
<transition name="fade-transform" mode="out-in">
<router-view />
</transition>
</section>
</template>
<script>
export default {
name: 'dictionary',
computed: {
cachedViews() {
return this.$store.state.tagsView.cachedViews
},
key() {
return this.$route.path
}
}
}
</script>
<style lang="scss" scoped>
.app-main {
/* 50= navbar 50 */
min-height: calc(100vh - 50px);
width: 100%;
position: relative;
overflow: hidden;
}
.fixed-header+.app-main {
padding-top: 50px;
}
.hasTagsView {
.app-main {
/* 84 = navbar + tags-view = 50 + 34 */
min-height: calc(100vh - 84px);
}
.fixed-header+.app-main {
padding-top: 84px;
}
}
</style>
<style lang="scss">
// fix css style bug in open el-dialog
.el-popup-parent--hidden {
.fixed-header {
padding-right: 17px;
}
}
</style>
<template>
<RelDialog width="50%" :type='type' :editApp='editApp' :app='app' :buttonApp='buttonApp'>
<el-form slot="form" ref="form" :model="form" label-width="100px" :rules="rules">
<el-row :gutter="20" :app="this">
<EditColItem :required="item.required||false" :readonly="item.readonly?true:false " v-for="(item,index) in editColItemList " :value="item.value" :span="item.span" :label="item.label" :prop='item.prop' :key="item.prop" :type="item.type" :typeConfig='item.typeConfig' :rule="item.rule" />
</el-row>
</el-form>
</RelDialog>
</template>
<script>
import {
editMixin
} from 'common'
export default {
mixins: [editMixin],
data() {
return {
editColItemList: [
{
label: '客户编码',
prop: 'code',
span: 12,
type: 'input',
required:true,
},
{
label: '客户名称',
prop: 'name',
span: 12,
type: 'input',
required:true,
},
{
label: '简称',
prop: 'fullname',
span: 12,
type: 'input',
},
{
label: '联系人',
prop: 'lxr',
span: 12,
type: 'input',
},
{
label: '电话',
prop: 'tel',
span: 12,
type: 'input',
},
{
label: '邮箱',
prop: 'email',
span: 12,
type: 'input',
},
{
label: '传真',
prop: 'fax',
span: 12,
type: 'input'
},
{
label: '地址',
prop: 'address',
span: 12,
type: 'input',
},
{
label: '开户银行',
prop: 'bank',
span: 12,
type: 'input',
},
{
label: '账号',
prop: 'account',
span: 12,
type: 'input',
},
{
label: '税号',
prop: 'taxid',
span: 12,
type: 'input',
},
{
label: '法人代表',
prop: 'ceo',
span: 12,
type: 'input',
},
{
label: '财务主管',
prop: 'cfo',
span: 12,
type: 'input',
},
// {
// label: '销售员',
// prop: 'xsyid',
// span: 12,
// type: 'input',
// },
{
label: '销售员',
prop: 'xsyid',
span: 12,
type: 'AuxInput',
typeConfig:{
code:'SALESPERSON',
label:'username',
transform:{
value:'userid',
label:'username'
}
}
},
{
label: '客户分类',
prop: 'khflid',
span: 12,
type: 'RelSelect',
typeConfig:{
src:'/jcsj/khfl/query'
}
},
{
label: '开票单位',
prop: 'kpkhid',
span: 12,
type: 'AuxInput',
typeConfig:{
code:'CUSTOM',
label:'kpdwname',
transform:{
value:'id',
label:'name'
}
}
},
{
label: '备注',
prop: 'bz',
span: 24,
type: 'input'
},
]
}
}
}
</script>
<template>
<div class="min_full">
<!-- 查询条件-->
<div class="search" v-condition>
<SearchButton :app='app'></SearchButton>
<el-row :gutter="20" class="search-row-1">
<el-col :span="6" class="search-col">
<div class="search-item">
<span class="search-span">客户信息:</span>
<el-input v-model="queryParams.code"></el-input>
</div>
</el-col>
<el-col :span="6" class="search-col">
<div class="search-item">
<span class="search-span">联系人:</span>
<el-input v-model="queryParams.lxr"></el-input>
</div>
</el-col>
<el-col :span="6" class="search-col">
<div class="search-item">
<span class="search-span">选择:</span>
<RelSelect style="width: 100%;" src='jcsj/common/tybz/query' filterable clearable
:match="{value:'id',label:'name'}" v-model='queryParams.tybz'></RelSelect>
</div>
</el-col>
</el-row>
</div>
<!-- 按钮操作-->
<el-row class="tool-bar">
<ToolButton :app='app'></ToolButton>
<ViewButton ref="view" :app='app'></ViewButton>
<AddButton ref="add" :app='app'></AddButton>
<CopyButton ref="copy" :app='app'></CopyButton>
<EditButton ref="edit" :app='app'></EditButton>
<ExportTempButton :url="'jcsj/kh/excel/export'" :exportName="'客户信息导入模板.xlsx'" ></ExportTempButton>
<ImportTempButton @success="()=>{
$refs['TablePager'].pageQuery()
}" :url="'jcsj/kh/import'"></ImportTempButton>
<!-- <AttachFileButton :app='app' ></AttachFileButton> -->
<!-- 额外按钮-->
<!-- 表头设置 -->
<!-- 权限-->
</el-row>
<!-- 表格-->
<div class="tablePagers">
<TablePager @getData='getData' :ref="'TablePager'" :app='app' :query='query' @selectItem='selectItem'
@getRow='getRow'>
<template slot="tabCustom">
<el-table-column label="启用/停用" width="90" header-align="center" fixed="right" >
<template slot-scope="scope">
<el-switch @click.native="setEnable(scope.row.id)" :value='tybz(scope)' style="width: 80px;justify-content: center;"
active-color="#13ce66" inactive-color="#eee">
</el-switch>
</template>
</el-table-column>
</template>
</TablePager>
</div>
</div>
</template>
<script>
import {
doQuery,
doAdd,
doUpdate,
doDelete,
qt
} from '@/api/baseData/custom/info.js';
/* edit页面*/
import Edit from './edit'
import {
tableMixin
} from 'common'
export default {
mixins: [tableMixin],
name: 'customInfo',
/* 初始额外赋值*/
async mounted() {
this.$refs['TablePager'].pageQuery()
},
data() {
return {
/*需要的额外参数 */
// showDialog: false,
// DialogName: '',
// type: '',
// DialogTitle: '',
/* 基础url*/
baseUrl: 'jcsj/kh',
/* 查询参数*/
queryParams: {
code: '',
lxr: '',
tybz:''
},
/* 表格标题对应参数*/
tableTitle: [ {title: "客户编码", field: "code", fieldType:"upper", width: 120},
{title: "客户名称", field: "name", width: 140},
{title: "联系人", field: "lxr", width: 140},
{title: "电话", field: "tel", width: 120},
{title: "邮箱", field: "email", width: 120},
{title: "地址", field: "address", width: 200},
{title: "开票单位ID", field: "kpkhid", hidden:true},
{title: "开票单位", field: "kpdwname", width: 160},
{title: "开户银行", field: "bank", width: 140},
{title: "账号", field: "account", width: 140},
{title: "税号", field: "taxid", width: 140},
{title: "法人代表", field: "ceo", width: 140},
{title: "财务主管", field: "cfo", width: 140},
{title: "销售员", field: "username", width: 140},
{title: "附件数", field: "attachcount", fieldType:"int"},
{title: "状态", field: "tybz", fieldType:"tybz"},
{title: "停用日期", field: "tyrq", fieldType:"ftDate"},
{title: "备注", field: "bz", width: 240},
{title: "维护人", field: "whr"},
{title: "维护时间", field: "whsj", fieldType:"ftDateTime"}]
}
},
methods: {
setEnable(id) {
this.$confirm('是否启用/停用该属性, 是否继续?', '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning'
}).then(() => {
let params = {
id: id
}
qt(params).then(res => {
if (res.success) {
this.$success('操作成功')
this.app.$refs['TablePager'].reLoad()
} else {
this.$error(res.message || '操作失败')
}
})
})
},
tybz(a) {
let nTy = false
nTy = (a.row.tybz == 'Y' ? true : false)
return nTy
},
/* 基础查询*/
query: doQuery,
/* 基础增*/
apiAdd: doAdd,
/* 基础更新*/
apiUpdate: doUpdate,
/* 删除操作*/
apiDelete: doDelete,
/* 初始化赋值操作*/
// init() {
// }
},
components: {
Edit,
}
}
</script>
<style scoped>
</style>
<template>
<DefaultDialog :app='app'>
<div slot="form" style="display: flex;">
<el-form label-width="80px" :model="form" >
<el-col :span="24">
<el-form-item label="年度" ref="year" prop="year">
<el-input v-model="form.year"></el-input>
</el-form-item>
</el-col>
<el-col :span="24">
<el-form-item label="上一年" ref="year" prop="year">
<el-input v-model="form.previous"></el-input>
</el-form-item>
</el-col>
</el-form>
</div>
<div slot="reFooter" class="refooter" >
<span slot="footer" class="dialog-footer" >
<el-button @click="app.showDialog=false">取 消</el-button>
<el-button type="primary" @click="save()">保 存</el-button>
</span>
</div>
</DefaultDialog>
</template>
<script>
export default {
props: {
app: {
type: Object,
default: ()=>{
return {}
}
}
},
async mounted() {
this.form= _.cloneDeep(this.app.singleItem)
this.form.previous= parseInt(this.form.year)-1
},
data() {
return {
form:{
year:'',
previous:''
}
}
},
methods: {
save(){
const copyByPrevious=()=>this.$post('jcsj/kjqj/copyByPrevious',this.form)
this.$post('/jcsj/kjqj/check',this.form).then(res=>{
if(res){
if(res.result=='Y'){
/* 弹框*/
this.$confirm('该年度已有数据,是否覆盖?', '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning'
}).then(()=>{
copyByPrevious().then(res=>{
if(res.success){
this.$success('操作成功')
this.app.showDialog=false
this.app.refresh()
}
})
})
}else{
copyByPrevious().then(res=>{
if(res.success){
this.$success('操作成功')
this.app.showDialog=false
this.app.refresh()
}
})
}
// this.$success('操作成功')
// this.app.showDialog=false
// this.app.refresh()
}
})
}
}
}
</script>
<style scoped>
</style>
<template>
<RelDialog width="50%" :type='type' :editApp='editApp' :app='app' :buttonApp='buttonApp'>
<el-form slot="form" ref="form" :model="form" label-width="100px" :rules="rules">
<el-row :gutter="20" :app="this">
<EditColItem :required="item.required||false" :readonly="item.readonly?true:false " v-for="(item,index) in editColItemList " :value="item.value" :span="item.span" :label="item.label" :prop='item.prop' :key="item.prop" :type="item.type" :typeConfig='item.typeConfig' :rule="item.rule" />
</el-row>
</el-form>
</RelDialog>
</template>
<script>
import {
editMixin
} from 'common'
export default {
mixins: [editMixin],
data() {
return {
editColItemList: [
{
label: '类别编码',
prop: 'code',
span: 12,
type: 'input',
},
{
label: '类别名称',
prop: 'name',
span: 12,
type: 'input',
},
{
label: '增值税率(%)',
prop: 'zzsl',
span: 12,
type: 'inputNumber',
},
{
label: '价外税',
prop: 'jws',
span: 12,
type: 'checkbox',
},
{
label: '备注',
prop: 'bz',
span: 24,
type: 'input'
}
]
}
}
}
</script>
<template>
<BasePage class="min_full" :config="config" >
<template #dialog="ctx" >
<Normal v-if="ctx.basePage.showDialog&&ctx.basePage.DialogTitle=='按照自然年月生成'" :app='ctx.basePage' />
<Copy v-if="ctx.basePage.showDialog&&ctx.basePage.DialogTitle=='复刻上一年'" :app='ctx.basePage' />
</template>
<template #toolbar="ctx" >
<!-- 嵌入默认页面工具栏的插槽 ctx.pagePage来操作默认页面 -->
<el-button @click="create(ctx.basePage)" size='mini' type="primary">按照自然年月生成</el-button>
<el-button @click="copyLast(ctx.basePage)" size='mini' type="primary">复刻上一年</el-button>
</template>
</BasePage>
</template>
<script>
import Edit from './edit.vue'
import Normal from './normal.vue'
import Copy from './copy.vue'
export default{
data(){
return{
config:{
url:'jcsj/kjqj',
tableTitle: [
{title: "年度", field: "year", fieldType:"int"},
{title: "期号", field: "month", fieldType:"int", width: 100},
{title: "开始日期", field: "ksrq", fieldType:"ftDate"},
{title: "结束日期", field: "jsrq", fieldType:"ftDate"},
{title: "维护人", field: "whr"},
{title: "维护时间", field: "whsj", fieldType:"ftDateTime"}
],
queryParams:[
[
{
label: '年度',
prop: 'year',
span: 6,
type: 'year',
value:''
}
]
]
}
}
},
methods: {
/* 示例*/
create(ctx){
if(ctx.singleItem.id){
ctx.DialogWidth="400px"
ctx.showDialog=true
ctx.DialogTitle="按照自然年月生成"
}else{
this.$warning('请选中一条数据')
}
},
copyLast(ctx){
if(ctx.singleItem.id){
ctx.DialogWidth="400px"
ctx.showDialog=true
ctx.DialogTitle="复刻上一年"
}else{
this.$warning('请选中一条数据')
}
}
},
components:{
Edit,Normal,Copy
}
}
</script>
<style>
</style>
<template>
<DefaultDialog :app='app'>
<div slot="form" style="display: flex;">
<el-form label-width="80px" :model="form" >
<el-col :span="24">
<el-form-item label="年度" ref="year" prop="year">
<el-input v-model="form.year"></el-input>
</el-form-item>
</el-col>
</el-form>
</div>
<div slot="reFooter" class="refooter" >
<span slot="footer" class="dialog-footer" >
<el-button @click="app.showDialog=false">取 消</el-button>
<el-button type="primary" @click="save()">保 存</el-button>
</span>
</div>
</DefaultDialog>
</template>
<script>
export default {
props: {
app: {
type: Object,
default: ()=>{
return {}
}
}
},
async mounted() {
this.form= _.cloneDeep(this.app.singleItem)
},
data() {
return {
form:{
year:''
}
}
},
methods: {
save(){
this.$post('/jcsj/kjqj/autoByYear',this.form).then(res=>{
if(res.success){
this.$success('操作成功')
this.app.showDialog=false
this.app.refresh()
}
})
}
}
}
</script>
<style scoped>
</style>
<template>
<DefaultDialog :app='app'>
<div slot="form" style="display: flex;height: 70vh;">
DialogTitle:'新增',
showDialog:false,
</div>
<div slot="reFooter" class="refooter" >
<span slot="footer" class="dialog-footer" >
<el-button @click="app.showDialog=false">取 消</el-button>
<el-button type="primary" @click="save()">保 存</el-button>
</span>
</div>
</DefaultDialog>
</template>
<script>
export default {
props: {
app: {
type: Object,
default: ()=>{
return {}
}
}
},
async mounted() {
},
data() {
return {
}
},
methods: {
}
}
</script>
<style scoped>
</style>
<template>
<RelDialog width="50%" :type='type' :editApp='editApp' :app='app' :buttonApp='buttonApp'>
<el-form slot="form" ref="form" :model="form" label-width="100px" :rules="rules">
<el-row :gutter="20" :app="this">
<EditColItem :required="item.required||false" :readonly="item.readonly?true:false " v-for="(item,index) in editColItemList " :value="item.value" :span="item.span" :label="item.label" :prop='item.prop' :key="item.prop" :type="item.type" :typeConfig='item.typeConfig' :rule="item.rule" />
</el-row>
</el-form>
</RelDialog>
</template>
<script>
import {
editMixin
} from 'common'
export default {
mixins: [editMixin],
data() {
return {
editColItemList: [
{
label: '编码',
prop: 'code',
span: 12,
type: 'input',
required:true,
},
{
label: '名称',
prop: 'name',
span: 12,
type: 'input',
required:true,
},
{
label: '备注',
prop: 'bz',
span: 24,
type: 'input'
},
]
}
}
}
</script>
<template>
<BasePage :power="power" class="min_full" :config="config" >
<template #dialog="ctx" >
<!-- 嵌入默认页面额外弹框的插槽 ctx.pagePage来操作默认页面 -->
</template>
<template #toolbar="ctx" >
<!-- 嵌入默认页面工具栏的插槽 ctx.pagePage来操作默认页面 -->
<!-- <el-button @click="demo(ctx.basePage)" size='mini' type="primary">示例按钮</el-button> -->
</template>
</BasePage>
</template>
<script>
import Edit from './edit.vue'
export default{
data(){
return{
power:{
delButton:false,
editButton:true,
operateButtons:true
},
config:{
/* 基本配置*/
url:'jcsj/cwck',
tableTitle: [
{title:"仓库ID",field:"id",width:120,hidden:true},
{title:"仓库编码",field:"code",width:120},
{title:"仓库名称",field:"name",width:140},
{title:"会计单位ID",field:"kjdwid",width:140,hidden:true},
{title:"会计单位编码",field:"kjdwcode",width:120},
{title:"会计单位",field:"kjdwname",width:140},
{title:"计价方法", field: "cbjjff", width: 120,transform:{
url:'jcsj/cwck/init/jjff',label:'name',value:'id'
}
},
{title:"核算对象", field: "cbhsdx", width: 120, fieldType:"tybz"},
{title:"入库单前缀",field:"cwrkdqz",width:120},
{title:"出库单前缀",field:"cwckdqz",width:120},
{title:"调拨过账方式",field:"dbgzfs", width:120},
{title:"过账",field:"gzbz",width:80, fieldType:'tybz'},
{title: "状态",field: "tybz"},
{title: "停用日期",field: "tyrq", fieldType:'ftDate'},
{title:"备注",field:"bz",width:240},
{title:"维护人",field:"whr"},
{title:"维护时间",field:"whsj",fieldType:'ftDateTime'}
],
queryParams:[[
{
label: '编码',
prop: 'code',
span: 6,
type: 'input',
value:''
},
{
label: '名称',
prop: 'name',
span: 6,
type: 'input',
value:''
}
]],
/* 默认启停用 */
showqt:true,
// qtUrl:'',
/* 树的支持*/
// hasTree:false,
// treeTitle:'',
// treeDefaultProps: {
// children: 'children',
// label: 'name',
// fatherId: 'pid',
// sonId: 'id',
// rootName: "全部",
// rootId:'root'
// },
// treeQueryParams:{
// },
// treeUrl:''
}
}
},
methods: {
/* 示例*/
// demo(basePage){
// }
},
components:{
Edit
}
}
</script>
<style>
</style>
<template>
<RelDialog :type='type' :editApp='editApp' :app='app' :buttonApp='buttonApp'>
<!-- 填写表单内容,slot=form必写-->
<el-form slot="form" ref="form" :model="form" label-width="100px" :rules="rules">
<el-row :gutter="20">
<el-col :span="12">
<el-form-item label="名称" ref="name" prop="name">
<el-input :readonly="readonly" v-model="form.name"></el-input>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="类型" ref="type" prop="type">
<RelSelect :readonly="readonly" filterable style="width: 100%;" src='jcsj/wlsx//init/type' :match="{value:'id',label:'name'}" v-model='form.type' ></RelSelect>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="宽度" ref="width" prop="width">
<el-input type="number" :readonly="readonly" v-model="form.width"></el-input>
</el-form-item>
</el-col>
<el-col :span="24">
<el-form-item label="备注" ref="bz" prop="bz">
<el-input :readonly="readonly" v-model="form.bz"></el-input>
</el-form-item>
</el-col>
</el-row>
</el-form>
</RelDialog>
</template>
<script>
import {editMixin} from 'common'
export default {
mixins: [editMixin],
/* 存放index页面传递的额外参数*/
mounted() {
},
/* 组件名称*/
/* 传递props模式一样必填,用于index,button,REdialog之间的组件通信*/
data() {
return {
/* 当前表单初始值,默认由RelDialog查询indexQuery赋值,copy时不赋值id,初始化时所有query的值都会赋值给form*/
form: {
name:'',
type:'',
bz:'',
width:''
}
}
},
methods: {
}
}
</script>
<style scoped lang="scss">
</style>
<template>
<div class="min_full">
<!-- 查询条件-->
<!-- <div class="search" v-condition>
<SearchButton :app='app'></SearchButton>
<el-row :gutter="20" class="search-row-1">
<el-col :span="6" class="search-col">
<div class="search-item">
<span class="search-span">物料分类:</span>
<el-input v-model="queryParams.search"></el-input>
</div>
</el-col>
</el-row>
</div> -->
<!-- 按钮操作-->
<el-row class="tool-bar">
<ToolButton :app='app'></ToolButton>
<ViewButton ref="view" :app='app'></ViewButton>
<AddButton ref="add" :app='app'></AddButton>
<CopyButton ref="copy" :app='app'></CopyButton>
<EditButton ref="edit" :app='app'></EditButton>
<!-- <AttachFileButton :app='app' ></AttachFileButton> -->
<!-- 额外按钮-->
<!-- 表头设置 -->
<!-- 权限-->
</el-row>
<!-- 表格-->
<div class="tablePagers">
<TablePager @getData='getData' :ref="'TablePager'" :app='app' :query='query' @selectItem='selectItem'
@getRow='getRow'>
<template slot="tabCustom">
<el-table-column label="启用/停用" width="90" header-align="center" fixed="right" >
<template slot-scope="scope">
<el-switch @click.native="setEnable(scope.row.id)" :value='tybz(scope)' style="width: 80px;justify-content: center;"
active-color="#13ce66" inactive-color="#eee">
</el-switch>
</template>
</el-table-column>
</template>
</TablePager>
</div>
</div>
</template>
<script>
import {
doQuery,
doAdd,
doUpdate,
doDelete,
qt
} from '@/api/baseData/material/attribute.js';
/* edit页面*/
import Edit from './edit'
import {
tableMixin
} from 'common'
export default {
mixins: [tableMixin],
name: 'materialAttribute',
/* 初始额外赋值*/
async mounted() {
this.$refs['TablePager'].pageQuery()
},
data() {
return {
/*需要的额外参数 */
showDialog: false,
DialogName: '',
type: '',
DialogTitle: '',
/* 基础url*/
baseUrl: 'jcsj/wlsx',
/* 查询参数*/
queryParams: {
search:''
},
/* 表格标题对应参数*/
tableTitle: [
{title: "名称", field: "name", fieldType: "ftString",width:220},
{title: "显示", field: "show", formatter(a,b,v){
let map={
Y:'显示',
N:'隐藏'
}
return map[v]
},width:60},
{title: "类型", field: "type", fieldType: "ftString",width:60,
transform:{
url:'jcsj/wlsx/init/type',label:'name',value:'id'
}
},
{title: "宽度", field: "width", fieldType: "int"},
{title: "备注", field: "bz", fieldType: "ftString",width:300},
{title: "维护人", field: "whr", fieldType: "ftString"},
{title: "维护时间", field: "whsj", fieldType: "ftDateTime"}
]
}
},
methods: {
setEnable(id) {
this.$confirm('是否启用/停用该属性, 是否继续?', '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning'
}).then(() => {
let params = {
id: id
}
qt(params).then(res => {
if (res.success) {
this.$success('操作成功')
this.app.$refs['TablePager'].reLoad()
} else {
this.$error(res.message || '操作失败')
}
})
})
},
tybz(a) {
let nTy = false
nTy = (a.row.show == 'Y' ? true : false)
return nTy
},
selectedTree(e) {
this.queryParams.pid=e.id||'root'
this.$refs['TablePager'].pageQuery()
},
// /* 基础查询*/
query: doQuery,
/* 基础增*/
apiAdd: doAdd,
/* 基础更新*/
apiUpdate: doUpdate,
/* 删除操作*/
apiDelete: doDelete,
/* 初始化赋值操作*/
init() {
}
},
components: {
Edit,
}
}
</script>
<style scoped>
</style>
<template>
<RelDialog :type='type' :editApp='editApp' :app='app' :buttonApp='buttonApp'>
<!-- 填写表单内容,slot=form必写-->
<el-form slot="form" ref="form" :model="form" label-width="100px" :rules="rules">
<el-row :gutter="20">
<el-col :span="12">
<el-form-item v-rule="{
required:true,
rules:rules,
}" label="上级分类" ref="pid" prop="pid">
<RelSelect :readonly="readonly" filterable style="width: 100%;" src='/jcsj/wlfl/init/sjfl' :match="{value:'id',label:'name'}" v-model='form.pid' ></RelSelect>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item v-rule="{
required:true,
rules:rules,
}" label="分类编码" ref="code" prop="code">
<el-input :readonly="readonly" v-model="form.code"></el-input>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item v-rule="{
required:true,
rules:rules,
}" label="分类名称" ref="name" prop="name">
<el-input :readonly="readonly" v-model="form.name"></el-input>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="增值税率(%)" ref="zzsl" prop="zzsl">
<el-input :readonly="readonly" v-model="form.zzsl"></el-input>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item v-rule="{
required:true,
rules:rules,
}" label="流水号长度" ref="snlen" prop="snlen">
<el-input :readonly="readonly" v-model="form.snlen"></el-input>
</el-form-item>
</el-col>
<el-col :span="24">
<el-form-item label="备注" ref="bz" prop="bz">
<el-input :readonly="readonly" v-model="form.bz"></el-input>
</el-form-item>
</el-col>
</el-row>
</el-form>
</RelDialog>
</template>
<script>
import {editMixin} from 'common'
export default {
mixins: [editMixin],
/* 存放index页面传递的额外参数*/
mounted() {
},
/* 组件名称*/
/* 传递props模式一样必填,用于index,button,REdialog之间的组件通信*/
data() {
return {
/* 当前表单初始值,默认由RelDialog查询indexQuery赋值,copy时不赋值id,初始化时所有query的值都会赋值给form*/
form: {
pid:'',
code:'',
name:'',
zzsl:'',
snlen:'',
bz:''
}
}
},
methods: {
}
}
</script>
<style scoped lang="scss">
</style>
<template>
<div style="display: flex;">
<div class="min_full" style="width: 200px;border-right: 0px;">
<TreeBase :dgtype='5' :app='app' @selected='selectedTree'></TreeBase>
</div>
<div class="min_full" style="width: calc(100% - 200px)">
<!-- 查询条件-->
<div class="search" v-condition>
<SearchButton :app='app'></SearchButton>
<el-row :gutter="20" class="search-row-1">
<el-col :span="6" class="search-col">
<div class="search-item">
<span class="search-span">物料分类:</span>
<el-input v-model="queryParams.search"></el-input>
</div>
</el-col>
</el-row>
</div>
<!-- 按钮操作-->
<el-row class="tool-bar">
<ToolButton :app='app'></ToolButton>
<ViewButton ref="view" :app='app'></ViewButton>
<AddButton ref="add" :app='app'></AddButton>
<CopyButton ref="copy" :app='app'></CopyButton>
<EditButton ref="edit" :app='app'></EditButton>
<!-- 额外按钮-->
<!-- 表头设置 -->
<!-- 权限-->
</el-row>
<!-- 表格-->
<div class="tablePagers">
<TablePager @getData='getData' :ref="'TablePager'" :app='app' :query='query' @selectItem='selectItem'
@getRow='getRow'>
</TablePager>
</div>
</div>
</div>
</template>
<script>
import {
doQuery,
doAdd,
doUpdate,
doDelete
} from '@/api/baseData/material/classification.js';
/* edit页面*/
import Edit from './edit'
import {
tableMixin
} from 'common'
export default {
mixins: [tableMixin],
name: 'materialClassification',
/* 初始额外赋值*/
async mounted() {
this.$refs['TablePager'].pageQuery()
},
data() {
return {
/* 树的标题 */
treeTitle: '物料分类',
treeDefaultProps: {
/* 构建递归的children */
children: 'children',
/* 展示的参数 */
label: 'name',
/* 父id */
fatherId: 'pid',
/* 子id */
sonId: 'id',
/* 无父节点构建root 的属性 type=5生效 */
rootName: "全部",
rootId:'root'
},
treeQueryParams: {
},
/*需要的额外参数 */
showDialog: false,
DialogName: '',
type: '',
DialogTitle: '',
/* 基础url*/
baseUrl: 'jcsj/wlfl',
/* 查询参数*/
queryParams: {
search:''
},
/* 表格标题对应参数*/
tableTitle: [
{title: "分类编码", field: "code", fieldType:"upper", width: 140},
{title: "分类名称", field: "name", width: 160},
{title: "增值税率(%)", field: "zzsl", fieldType:"zzsl", width: 100},
{title: "流水号长度", field: "snlen", fieldType:"int", width: 100},
{title: "备注", field: "bz",width: 240},
{title: "维护人", field: "whr",fieldType:"whr"},
{title: "维护时间", field: "whsj", fieldType:"ftDateTime"}
]
}
},
methods: {
selectedTree(e) {
this.queryParams.pid=e.id||'root'
this.$refs['TablePager'].pageQuery()
},
// /* 基础查询*/
query: doQuery,
/* 基础增*/
apiAdd: doAdd,
/* 基础更新*/
apiUpdate: doUpdate,
/* 删除操作*/
apiDelete: doDelete,
apiTreeQuery: doQuery,
/* 初始化赋值操作*/
init() {
}
},
components: {
Edit,
}
}
</script>
<style scoped>
</style>
<template>
<section class="app-main">
<transition name="fade-transform" mode="out-in">
<router-view />
</transition>
</section>
</template>
<script>
export default {
name: 'dictionary',
computed: {
cachedViews() {
return this.$store.state.tagsView.cachedViews
},
key() {
return this.$route.path
}
}
}
</script>
<style lang="scss" scoped>
.app-main {
/* 50= navbar 50 */
min-height: calc(100vh - 50px);
width: 100%;
position: relative;
overflow: hidden;
}
.fixed-header+.app-main {
padding-top: 50px;
}
.hasTagsView {
.app-main {
/* 84 = navbar + tags-view = 50 + 34 */
min-height: calc(100vh - 84px);
}
.fixed-header+.app-main {
padding-top: 84px;
}
}
</style>
<style lang="scss">
// fix css style bug in open el-dialog
.el-popup-parent--hidden {
.fixed-header {
padding-right: 17px;
}
}
</style>
<template>
<RelDialog width="80%" :type='type' :editApp='editApp' :app='app' :buttonApp='buttonApp'>
<!-- 填写表单内容,slot=form必写-->
<el-form slot="form" ref="form" :model="form" label-width="100px" :rules="rules">
<el-row :gutter="20" :app="this">
<EditColItem :required="item.required||false" :readonly="item.readonly?true:false " v-for="(item,index) in editColItemList " :value="item.value" :span="item.span" :label="item.label" :prop='item.prop' :key="item.prop" :type="item.type" :typeConfig='item.typeConfig' :rule="item.rule" />
</el-row>
</el-form>
</RelDialog>
</template>
<script>
import {
editMixin
} from 'common'
export default {
mixins: [editMixin],
data() {
return {
editColItemList: [{
label: '物料编码',
prop: 'code',
span: 6,
type: 'input',
},
{
label: '物料名称',
prop: 'name',
span: 6,
type: 'input',
required:true,
},
{
label: '物料分类',
prop: 'flid',
span: 6,
type: 'RelSelect',
typeConfig:{
src:"jcsj/wlxx/init/wlfl"
}
},
{
label: '规格',
prop: 'gg',
span: 6,
type: 'input'
},
{
label: '计量单位',
prop: 'jldw',
span: 6,
type: 'RelSelect',
typeConfig:{
src:"jcsj/jldw/query"
},
required:true,
},
{
label: '辅计量单位',
prop: 'fjldw',
span: 6,
type: 'RelSelect',
typeConfig:{
src:"jcsj/jldw/query"
},
},
{
label: '增值税率(%)',
prop: 'zzsl',
span: 6,
type: 'inputNumber'
},
{
label: '批号管理',
prop: 'phgl',
span: 6,
type: 'checkbox',
value:'N'
},
{
label: '单件管理',
prop: 'djgl',
span: 6,
type: 'checkbox',
value:'N'
},
{
label: '最小订货批量',
prop: 'zxdhpl',
span: 6,
type: 'inputNumber'
},
{
label: '订单倍数',
prop: 'ddbs',
span: 6,
type: 'inputNumber'
},
{
label: '安全库存',
prop: 'aqkc',
span: 6,
type: 'inputNumber'
},
{
label: '库存高限',
prop: 'kcgx',
span: 6,
type: 'inputNumber'
},
{
label: '订货提前期',
prop: 'dhtqq',
span: 6,
type: 'inputNumber'
},
{
label: '询价方式',
prop: 'xjfs',
span: 6,
type: 'RelSelect',
typeConfig:{
src:"jcsj/wlxx/init/xjfs"
},
},
{
label: '供应商',
prop: 'gysid',
span: 6,
type: 'RelSelect',
typeConfig:{
src:"jcsj/gys/query"
}
},
/* 测试*/
// {
// label: '供应商',
// prop: 'gysid',
// span: 6,
// type: 'AuxInput',
// typeConfig:{
// isRequest:true,
// code:'METERIALINFOEDIT_TEST',
// label:'gysname',
// transform:{
// value:'GYS_ID',
// label:'GYS_NAME'
// }
// },
// },
{
label: '物料形态',
prop: 'wlxt',
span: 6,
type: 'RelSelect',
typeConfig:{
src:"jcsj/wlxx/init/wlxt"
},
},
{
label: '缺省仓库',
prop: 'ckid',
span: 6,
type: 'RelSelect',
typeConfig:{
src:"jcsj/common/ck/query"
},
},
{
label: '缺省库位',
prop: 'kwid',
span: 6,
type: 'RelSelect',
typeConfig:{
src:"jcsj/kw/query",
linkage:true,
linkParams:['ckid']
},
},
{
label: '产品结构号',
prop: 'bomid',
span: 6,
type: 'AuxInput',
typeConfig:{
isRequest:true,
code:'METERIALINFOEDIT_BOMID',
label:'BOMID',
transform:{
value:'BOMID',
label:'BOMID'
}
},
},
{
label: '工艺路线号',
prop: 'gylxid',
span: 6,
type: 'AuxInput',
typeConfig:{
isRequest:true,
code:'METERIALINFOEDIT_BOMID',
label:'BOMID',
transform:{
value:'BOMID',
label:'BOMID'
}
}
},
{
label: '库存期限',
prop: 'kcqx',
span: 6,
type: 'input'
},
/* 开始*/
{
label: '订货部门',
prop: 'dhbmid',
span: 6,
type: 'RelSelect',
typeConfig:{
src:"jcsj/common/bm/query",
match:{
key:'bmid',
value:"bmmc"
}
},
},
{
label: '计划方法',
prop: 'jhff',
span: 6,
type: 'RelSelect',
typeConfig:{
src:"jcsj/wlxx/init/jhff",
},
},
{
label: '订货类型',
prop: 'dhlx',
span: 6,
type: 'RelSelect',
typeConfig:{
src:"jcsj/wlxx/init/dhlx",
},
},
{
label: '条码规则',
prop: 'snruleid',
span: 6,
type: 'input'
},
{
label: '计划部门',
prop: 'jhbmid',
span: 6,
type: 'RelSelect',
typeConfig:{
src:"jcsj/common/bm/query",
match:{
key:'bmid',
value:"bmmc"
}
}
},
{
label: '主生产计划 ',
prop: 'mps',
span: 6,
type: 'checkbox',
value:'N'
},
{
label: '定制生产',
prop: 'dzsc',
span: 6,
type: 'checkbox',
value:'N'
},
{
label: '单件净重',
prop: 'jz',
span: 6,
type: 'input'
},
{
label: '单件毛重',
prop: 'mz',
span: 6,
type: 'input'
},
{
label: '标准成本',
prop: 'bzcb',
span: 6,
type: 'input'
},
{
label: '备注',
prop: 'bz',
span: 24,
type: 'input'
},
]
}
}
}
</script>
<template>
<div style="display: flex;">
<div class="min_full" style="width: 200px;border-right: 0px;">
<TreeBase :dgtype='5' :app='app' @selected='selectedTree'></TreeBase>
</div>
<div class="min_full" style="width: calc(100% - 200px)">
<!-- 查询条件-->
<div class="search" v-condition>
<SearchButton :app='app'></SearchButton>
<el-row :gutter="20" class="search-row-1">
<el-col :span="6" class="search-col">
<div class="search-item">
<span class="search-span">物料分类:</span>
<el-input v-model="queryParams.search"></el-input>
</div>
</el-col>
</el-row>
</div>
<!-- 按钮操作-->
<el-row class="tool-bar">
<ToolButton :app='app'></ToolButton>
<ViewButton ref="view" :app='app'></ViewButton>
<AddButton ref="add" :app='app'></AddButton>
<CopyButton ref="copy" :app='app'></CopyButton>
<EditButton ref="edit" :app='app'></EditButton>
<AttachFileButton :app='app' ></AttachFileButton>
<ExportTempButton :url="'jcsj/wlxx/excel/export'" :exportName="'物料信息导入模板.xlsx'" ></ExportTempButton>
<ImportTempButton @success="()=>{
$refs['TablePager'].pageQuery()
}" :url="'jcsj/wlxx/import'"></ImportTempButton>
<!-- 额外按钮-->
<!-- 表头设置 -->
<!-- 权限-->
</el-row>
<!-- 表格-->
<div class="tablePagers">
<TablePager @getData='getData' :ref="'TablePager'" :app='app' :query='query' @selectItem='selectItem'
@getRow='getRow'>
<template slot="tabCustom">
<el-table-column label="启用/停用" width="90" header-align="center" fixed="right" >
<template slot-scope="scope">
<el-switch @click.native="setEnable(scope.row.id)" :value='tybz(scope)' style="width: 80px;justify-content: center;"
active-color="#13ce66" inactive-color="#eee">
</el-switch>
</template>
</el-table-column>
</template>
</TablePager>
</div>
</div>
</div>
</template>
<script>
import {
doQuery,
doAdd,
doUpdate,
doDelete,
apiTreeQuery,
qt
} from '@/api/baseData/material/info.js';
/* edit页面*/
import Edit from './edit'
import {
tableMixin
} from 'common'
export default {
mixins: [tableMixin],
name: 'materialInfo',
/* 初始额外赋值*/
async mounted() {
this.$refs['TablePager'].pageQuery()
},
data() {
return {
/* 树的标题 */
treeTitle: '物料分类',
treeDefaultProps: {
/* 构建递归的children */
children: 'children',
/* 展示的参数 */
label: 'name',
/* 父id */
fatherId: 'pid',
/* 子id */
sonId: 'id',
/* 无父节点构建root 的属性 type=5生效 */
rootName: "全部",
rootId:'root'
},
treeQueryParams: {
},
/*需要的额外参数 */
showDialog: false,
DialogName: '',
type: '',
DialogTitle: '',
/* 基础url*/
baseUrl: 'jcsj/wlxx',
/* 查询参数*/
queryParams: {
search:''
},
/* 表格标题对应参数*/
tableTitle: [
{title:"物料编码",field:"code",width:120},
{title:"物料名称",field:"name",width:160},
{title:"规格",field:"gg",width:120},
{title:"计量单位",field:"jldwname",width:80},
{title:"辅计量单位",field:"fjldwname",width:80,align:"center"},
// {title:"采购计量单位",field:"cgjldwname",width:80,align:"center"},
{title:"增值税率(%)",field:"zzsl", fieldType:"zzsl", width: 100},
{title:"批号管理",field:"phgl",width:80,formatter(a,b,v){
let map={
Y:'停用',
N:'正常'
}
return map[v]
}},
{title:"单件管理",field:"djgl",width:80,formatter(a,b,v){
let map={
Y:'停用',
N:'正常'
}
return map[v]
}},
{title:"产品条码规则",field:"coderulename",width:160},
{title:"缺省仓库",field:"ckname", width:120},
{title:"计划部门",field:"jhbmmc",width:120},
{title:"产品结构号",field:"bomcode", width:120},
{title:"工艺路线号",field:"gylxcode", width:120},
{title:"状态",field:"tybz",width:80,formatter(a,b,v){
let map={
Y:'停用',
N:'正常'
}
return map[v]
}},
{title:"停用日期",field:"tyrq",fieldType:'ftDate'},
{title:"备注",field:"bz",width:200},
{title:"维护人",field:"whr"},
{title:"维护时间",field:"whsj",fieldType:'ftDateTime'}
]
}
},
methods: {
setEnable(id) {
this.$confirm('是否启用/停用, 是否继续?', '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning'
}).then(() => {
let params = {
id: id
}
qt(params).then(res => {
if (res.success) {
this.$success('操作成功')
this.app.$refs['TablePager'].reLoad()
} else {
this.$error(res.message || '操作失败')
}
})
})
},
tybz(a) {
let nTy = false
nTy = (a.row.tybz == 'N' ? true : false)
return nTy
},
selectedTree(e) {
this.queryParams.pid=e.id||'root'
this.$refs['TablePager'].pageQuery()
},
// /* 基础查询*/
query: doQuery,
/* 基础增*/
apiAdd: doAdd,
/* 基础更新*/
apiUpdate: doUpdate,
/* 删除操作*/
apiDelete: doDelete,
apiTreeQuery: apiTreeQuery,
/* 初始化赋值操作*/
init() {
}
},
components: {
Edit,
}
}
</script>
<style scoped>
</style>
<template>
<section class="app-main">
<transition name="fade-transform" mode="out-in">
<router-view />
</transition>
</section>
</template>
<script>
export default {
name: 'dictionary',
computed: {
cachedViews() {
return this.$store.state.tagsView.cachedViews
},
key() {
return this.$route.path
}
}
}
</script>
<style lang="scss" scoped>
.app-main {
/* 50= navbar 50 */
min-height: calc(100vh - 50px);
width: 100%;
position: relative;
overflow: hidden;
}
.fixed-header+.app-main {
padding-top: 50px;
}
.hasTagsView {
.app-main {
/* 84 = navbar + tags-view = 50 + 34 */
min-height: calc(100vh - 84px);
}
.fixed-header+.app-main {
padding-top: 84px;
}
}
</style>
<style lang="scss">
// fix css style bug in open el-dialog
.el-popup-parent--hidden {
.fixed-header {
padding-right: 17px;
}
}
</style>
<template>
<RelDialog width="50%" :type='type' :editApp='editApp' :app='app' :buttonApp='buttonApp'>
<el-form slot="form" ref="form" :model="form" label-width="100px" :rules="rules">
<el-row :gutter="20" :app="this">
<EditColItem :required="item.required||false" :readonly="item.readonly?true:false " v-for="(item,index) in editColItemList " :value="item.value" :span="item.span" :label="item.label" :prop='item.prop' :key="item.prop" :type="item.type" :typeConfig='item.typeConfig' :rule="item.rule" />
</el-row>
</el-form>
</RelDialog>
</template>
<script>
import {
editMixin
} from 'common'
export default {
mixins: [editMixin],
data() {
return {
editColItemList: [
{
label: '货币编码',
prop: 'code',
span: 12,
type: 'input',
required:true,
},
{
label: '货币名称',
prop: 'name',
span: 12,
type: 'input',
required:true,
},
{
label: '汇率',
prop: 'hl',
span: 12,
type: 'inputNumber',
required:true,
},
{
label: '备注',
prop: 'bz',
span: 24,
type: 'input'
},
]
}
}
}
</script>
<template>
<BasePage class="min_full" :config="config" >
<template #dialog="ctx" >
<!-- 嵌入默认页面额外弹框的插槽 ctx.pagePage来操作默认页面 -->
</template>
<template #toolbar="ctx" >
<!-- 嵌入默认页面工具栏的插槽 ctx.pagePage来操作默认页面 -->
<el-button @click="setting(ctx.basePage)" size='mini' type="primary">设置本位币</el-button>
</template>
</BasePage>
</template>
<script>
import Edit from './edit.vue'
export default{
data(){
return{
config:{
/* 基本配置*/
url:'jcsj/hb',
tableTitle: [
{title: "货币编码", field: "code", fieldType:"upper", width: 120},
{title: "货币名称", field: "name", width: 120},
{title: "本位币", field: "bwb", width: 100,fieldType:"yn"},
{title: "汇率", field: "hl",width: 100, fieldType:"float"},
{title: "停用", field: "tybz",fieldType:"tybz"},
{title: "停用日期", field: "tyrq", fieldType:"ftDate"},
{title: "备注", field: "bz", width: 260},
{title: "维护人", field: "whr"},
{title: "维护时间", field: "whsj", fieldType:"ftDateTime"}
],
queryParams:[],
}
}
},
methods: {
/* 示例*/
setting(basePage){
if (basePage.selectOne || basePage.clickOne) {
this.$post('jcsj/hb/setbwb',basePage.singleItem).then(e=>{
if(e.success){
basePage.$success('操作成功')
basePage.$refs['TablePager'].reLoad()
}
})
} else {
basePage.$warning('请选中一行操作');
}
}
},
components:{
Edit
}
}
</script>
<template>
<DefaultDialog :app='app'>
<div slot="form" style="display: flex;height: 70vh;">
DialogTitle:'新增',
showDialog:false,
</div>
<div slot="reFooter" class="refooter" >
<span slot="footer" class="dialog-footer" >
<el-button @click="app.showDialog=false">取 消</el-button>
<el-button type="primary" @click="save()">保 存</el-button>
</span>
</div>
</DefaultDialog>
</template>
<script>
export default {
props: {
app: {
type: Object,
default: ()=>{
return {}
}
}
},
async mounted() {
},
data() {
return {
}
},
methods: {
}
}
</script>
<style scoped>
</style>
<template>
<RelDialog width="50%" :type='type' :editApp='editApp' :app='app' :buttonApp='buttonApp'>
<el-form slot="form" ref="form" :model="form" label-width="100px" :rules="rules">
<el-row :gutter="20" :app="this">
<EditColItem :required="item.required||false" :readonly="item.readonly?true:false " v-for="(item,index) in editColItemList " :value="item.value" :span="item.span" :label="item.label" :prop='item.prop' :key="item.prop" :type="item.type" :typeConfig='item.typeConfig' :rule="item.rule" />
</el-row>
</el-form>
</RelDialog>
</template>
<script>
import {
editMixin
} from 'common'
export default {
mixins: [editMixin],
data() {
return {
editColItemList: [
{
label: '替代类型',
prop: 'type',
span: 12,
type: 'RelSelect',
typeConfig:{
src:'jcsj/fzjldw/init/type'
},
required:true,
},
{
label: '控制方式',
prop: 'kzfs',
span: 12,
type: 'RelSelect',
typeConfig:{
src:'jcsj/fzjldw/init/kzfs'
},
required:true,
},
{
label: '计量单位',
prop: 'jldw',
span: 12,
type: 'RelSelect',
typeConfig:{
src:'/jcsj/jldw/query'
},
required:true,
},
{
label: '替代计量单位',
prop: 'fjldw',
span: 12,
type: 'RelSelect',
typeConfig:{
src:'/jcsj/jldw/query'
},
required:true,
},
{
label: '数量',
prop: 'sl',
span: 12,
type: 'inputNumber',
required:true,
},
{
label: '换算数量',
prop: 'hssl',
span: 12,
type: 'inputNumber',
required:true,
},
{
label: '换算系数',
prop: 'hsxs',
span: 12,
type: 'inputNumber',
},
{
label: '物料编码',
prop: 'wlid',
span: 12,
type: 'AuxInput',
typeConfig:{
code:'MATERIAL',
label:'wlmc',
transform:{
value:'id',
label:'name'
}
},
},
{
label: '备注',
prop: 'bz',
span: 24,
type: 'input'
},
]
}
}
}
</script>
<template>
<BasePage class="min_full" :config="config" >
<template #dialog="ctx" >
<!-- 嵌入默认页面额外弹框的插槽 ctx.pagePage来操作默认页面 -->
</template>
<template #toolbar="ctx" >
<!-- 嵌入默认页面工具栏的插槽 ctx.pagePage来操作默认页面 -->
<!-- <el-button @click="demo(ctx.basePage)" size='mini' type="primary">示例按钮</el-button> -->
</template>
</BasePage>
</template>
<script>
import Edit from './edit.vue'
export default{
data(){
return{
config:{
/* 基本配置*/
url:'/jcsj/fzjldw',
tableTitle: [
{"title": "替代类型", "field": "type", "width": 100,
transform:{
url:'jcsj/fzjldw/init/type',label:'name',value:'id'
}
},
{"title":"物料名称","field":"wlmc","width":140},
{"title":"数量","field":"sl",fieldType:"float","width":80},
{"title":"计量单位","field":"jldwname","width":100,align:"center"},
{"title":"换算数量","field":"hssl",fieldType:"float","width":80},
{"title":"替代计量单位","field":"fjldwname","width":100,align:"center"},
{"title":"换算系数","field":"hsxs","width":100, fieldType:"price"},
{"title": "控制方式", "field": "kzfs", "width": 100, align: "center",
transform:{
url:'jcsj/fzjldw/init/kzfs',label:'name',value:'id'
}
},
{"title":"备注","field":"bz","width":200},
{"title":"维护人","field":"whr"},
{"title":"维护时间","field":"whsj",fieldType:'ftDateTime'}
],
queryParams:[[
{
label: '替代类型',
prop: 'type',
span: 6,
type: 'RelSelect',
typeConfig:{
src:'jcsj/fzjldw/init/type'
}
}
]],
}
}
},
methods: {
/* 示例*/
// demo(basePage){
// }
},
components:{
Edit
}
}
</script>
<style>
</style>
<template>
<RelDialog width="50%" :type='type' :editApp='editApp' :app='app' :buttonApp='buttonApp'>
<el-form slot="form" ref="form" :model="form" label-width="100px" :rules="rules">
<el-row :gutter="20" :app="this">
<EditColItem :required="item.required||false" :readonly="item.readonly?true:false " v-for="(item,index) in editColItemList " :value="item.value" :span="item.span" :label="item.label" :prop='item.prop' :key="item.prop" :type="item.type" :typeConfig='item.typeConfig' :rule="item.rule" />
</el-row>
</el-form>
</RelDialog>
</template>
<script>
import {
editMixin
} from 'common'
export default {
mixins: [editMixin],
data() {
return {
editColItemList: [
{
label: '计量单位',
prop: 'name',
span: 24,
type: 'input',
required:true,
},
{
label: '备注',
prop: 'bz',
span: 24,
type: 'input'
},
]
}
}
}
</script>
<template>
<BasePage class="min_full" :config="config">
</BasePage>
</template>
<script>
import Edit from './edit.vue'
export default {
data() {
return {
config: {
/* 基本配置*/
url: 'jcsj/jldw',
tableTitle: [{
"title": "计量单位",
"field": "name",
"width": 140
},
{
"title": "备注",
"field": "bz",
"width": 200
},
{
"title": "维护人",
"field": "whr"
},
{
"title": "维护时间",
"field": "whsj",
fieldType: 'ftDateTime'
}
],
queryParams: [
[{
label: '计量单位',
prop: 'name',
span: 6,
type: 'input',
value: ''
}]
],
}
}
},
components: {
Edit
}
}
</script>
<template>
<DefaultDialog :app='app'>
<div slot="form" style="display: flex;height: 70vh;">
DialogTitle:'新增',
showDialog:false,
</div>
<div slot="reFooter" class="refooter" >
<span slot="footer" class="dialog-footer" >
<el-button @click="app.showDialog=false">取 消</el-button>
<el-button type="primary" @click="save()">保 存</el-button>
</span>
</div>
</DefaultDialog>
</template>
<script>
export default {
props: {
app: {
type: Object,
default: ()=>{
return {}
}
}
},
async mounted() {
},
data() {
return {
}
},
methods: {
}
}
</script>
<style scoped>
</style>
<template>
<RelDialog :type='type' :editApp='editApp' :app='app' :buttonApp='buttonApp'>
<!-- 填写表单内容,slot=form必写-->
<el-form slot="form" ref="form" :model="form" label-width="80px" :rules="rules">
<el-row :gutter="20">
<el-col :span="12">
<el-form-item v-rule="{
required:true,
rules:rules,
}" label="系统类型" ref="xtswlxid" prop="xtswlxid">
<!-- <el-input :readonly="readonly" v-model="form.name" ></el-input> -->
<RelSelect :readonly="readonly" filterable style="width: 100%;" src='jcsj/swlx/getXtswlx' :match="{value:'id',label:'name'}" v-model='form.xtswlxid' ></RelSelect>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item v-rule="{
required:true,
rules:rules,
}" label="编码" ref="code" prop="code">
<el-input :readonly="readonly" v-model="form.code"></el-input>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item v-rule="{
required:true,
rules:rules,
}" label="名称" ref="name" prop="name">
<el-input :readonly="readonly" v-model="form.name"></el-input>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="备注" ref="bz" prop="bz">
<el-input :readonly="readonly" v-model="form.bz"></el-input>
</el-form-item>
</el-col>
</el-row>
</el-form>
</RelDialog>
</template>
<script>
import {editMixin} from 'common'
export default {
mixins: [editMixin],
/* 存放index页面传递的额外参数*/
mounted() {
},
/* 组件名称*/
/* 传递props模式一样必填,用于index,button,REdialog之间的组件通信*/
data() {
return {
/* 当前表单初始值,默认由RelDialog查询indexQuery赋值,copy时不赋值id,初始化时所有query的值都会赋值给form*/
form: {
xtswlxid:"",
code:'',
name:'',
bz:''
}
}
},
methods: {
}
}
</script>
<style scoped lang="scss">
</style>
<template>
<div class="min_full">
<!-- 查询条件-->
<!-- 按钮操作-->
<el-row class="tool-bar">
<ToolButton :app='app'></ToolButton>
<ViewButton ref="view" :app='app'></ViewButton>
<AddButton ref="add" :app='app'></AddButton>
<CopyButton ref="copy" :app='app'></CopyButton>
<EditButton ref="edit" :app='app'></EditButton>
<!-- <AttachFileButton :app='app' ></AttachFileButton> -->
<!-- 额外按钮-->
<!-- 表头设置 -->
<!-- 权限-->
</el-row>
<!-- 表格-->
<div class="tablePagers">
<TablePager @getData='getData' :ref="'TablePager'" :app='app' :query='query' @selectItem='selectItem'
@getRow='getRow'>
<template slot="tabCustom">
<el-table-column label="启用/停用" width="90" header-align="center" fixed="right" >
<template slot-scope="scope">
<el-switch @click.native="setEnable(scope.row.id)" :value='tybz(scope)' style="width: 80px;justify-content: center;"
active-color="#13ce66" inactive-color="#eee">
</el-switch>
</template>
</el-table-column>
</template>
</TablePager>
</div>
</div>
</template>
<script>
import {
doQuery,
doAdd,
doUpdate,
doDelete,
qt
} from '@/api/baseData/store/actionType.js';
/* edit页面*/
import Edit from './edit'
import {
tableMixin
} from 'common'
export default {
mixins: [tableMixin],
name: 'storeActionType',
/* 初始额外赋值*/
async mounted() {
this.$refs['TablePager'].pageQuery()
},
data() {
return {
/*需要的额外参数 */
showDialog: false,
DialogName: '',
type: '',
DialogTitle: '',
/* 基础url*/
baseUrl: 'jcsj/swlx',
/* 查询参数*/
queryParams: {
},
/* 表格标题对应参数*/
tableTitle: [
{title:"编码",field:"code",width:100},
{title:"名称",field:"name",width:120},
{title:"系统类型",field:"xtswlxName",width:120},
{title:"状态",field: "tybz",
formatter:function(a,b,c){
let map={
Y:'禁用',
N:'正常'
}
return map[c]
}
},
{title:"停用日期",field: "tyrq",fieldType:'ftDate'},
{title:"备注",field:"bz",width:240},
{title:"维护人",field:"whr"},
{title:"维护时间",field:"whsj",fieldType:'ftDateTime'},
{title: "创建人",field:"cjr", hidden:true},
{title: "创建时间",field:"cjsj",fieldType:'ftDateTime', hidden:true}
]
}
},
methods: {
/* 基础查询*/
query: doQuery,
/* 基础增*/
apiAdd: doAdd,
/* 基础更新*/
apiUpdate: doUpdate,
/* 删除操作*/
apiDelete: doDelete,
setEnable(id) {
this.$confirm('是否启用/停用, 是否继续?', '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning'
}).then(() => {
let params = {
id: id
}
qt(params).then(res => {
if (res.success) {
this.$success('操作成功')
this.app.$refs['TablePager'].reLoad()
} else {
this.$error(res.message || '操作失败')
}
})
})
},
tybz(a) {
let nTy = false
nTy = (a.row.tybz == 'N' ? true : false)
return nTy
},
/* 初始化赋值操作*/
init() {
}
},
components: {
Edit,
}
}
</script>
<style scoped>
</style>
<template>
<div style="display: flex;">
<div class="min_full" style="width: 200px;border-right: 0px;">
<TreeBase :dgtype='5' :app='app' @selected='selectedTree'></TreeBase>
</div>
<div class="min_full" style="width: calc(100% - 200px)">
<!-- 查询条件-->
<div class="search" v-condition>
<SearchButton :app='app'></SearchButton>
<el-row :gutter="20" class="search-row-1">
<el-col :span="6" class="search-col">
<div class="search-item">
<span class="search-span">信息:</span>
<el-input v-model="queryParams.info"></el-input>
</div>
</el-col>
<el-col :span="4" class="search-col">
<div class="search-item">
<span class="search-span">选择:</span>
<RelSelect style="width: 100%;" src='jcsj/common/bm/queryGs' filterable clearable
:match="{value:'id',label:'bmmc'}" v-model='queryParams.gsid'></RelSelect>
</div>
</el-col>
</el-row>
</div>
<!-- 按钮操作-->
<el-row class="tool-bar">
<ToolButton :app='app'></ToolButton>
<ViewButton ref="view" :app='app'></ViewButton>
<AddButton ref="add" :app='app'></AddButton>
<CopyButton ref="copy" :app='app'></CopyButton>
<EditButton ref="edit" :app='app'></EditButton>
<!-- <AttachFileButton :app='app' ></AttachFileButton> -->
<!-- 额外按钮-->
<!-- 表头设置 -->
<!-- 权限-->
</el-row>
<!-- 表格-->
<div class="tablePagers">
<TablePager @getData='getData' :ref="'TablePager'" :app='app' :query='query' @selectItem='selectItem'
@getRow='getRow'>
</TablePager>
</div>
</div>
</div>
</template>
<script>
import {
apiTreeQuery
// doQuery,
// doAdd,
// doUpdate,
// doDelete
} from 'common/src/api/documentManagement/folder.js';
/* edit页面*/
import Edit from './edit'
import {
tableMixin
} from 'common'
export default {
mixins: [tableMixin],
name: '功能名称',
/* 初始额外赋值*/
async mounted() {
this.$refs['TablePager'].pageQuery()
},
data() {
return {
/* 树的标题 */
treeTitle: '文件管理',
treeDefaultProps: {
/* 构建递归的children */
children: 'children',
/* 展示的参数 */
label: 'name',
/* 父id */
fatherId: 'pid',
/* 子id */
sonId: 'id',
/* 无父节点构建root 的属性 type=5生效 */
rootName: "根节点",
rootId:'root'
},
treeQueryParams: {
},
/*需要的额外参数 */
showDialog: false,
DialogName: '',
type: '',
DialogTitle: '',
/* 基础url*/
baseUrl: '请填写',
/* 查询参数*/
queryParams: {
info: '',
gsid: ''
},
/* 表格标题对应参数*/
tableTitle: [{
label: "备注",
prop: "bz",
fieldType: "ftString",
width: 300
}]
}
},
methods: {
selectedTree(e) {
console.log(e)
// this.queryParams.bmid=e.id||'root'
this.$refs['TablePager'].pageQuery()
},
// /* 基础查询*/
query: apiTreeQuery,
// /* 基础增*/
// apiAdd: doAdd,
// /* 基础更新*/
// apiUpdate: doUpdate,
// /* 删除操作*/
// apiDelete: doDelete,
apiTreeQuery: apiTreeQuery,
/* 初始化赋值操作*/
init() {
}
},
components: {
Edit,
}
}
</script>
<style scoped>
</style>
\ No newline at end of file
<template>
<section class="app-main">
<transition name="fade-transform" mode="out-in">
<router-view />
</transition>
</section>
</template>
<script>
export default {
name: 'dictionary',
computed: {
cachedViews() {
return this.$store.state.tagsView.cachedViews
},
key() {
return this.$route.path
}
}
}
</script>
<style lang="scss" scoped>
.app-main {
/* 50= navbar 50 */
min-height: calc(100vh - 50px);
width: 100%;
position: relative;
overflow: hidden;
}
.fixed-header+.app-main {
padding-top: 50px;
}
.hasTagsView {
.app-main {
/* 84 = navbar + tags-view = 50 + 34 */
min-height: calc(100vh - 84px);
}
.fixed-header+.app-main {
padding-top: 84px;
}
}
</style>
<style lang="scss">
// fix css style bug in open el-dialog
.el-popup-parent--hidden {
.fixed-header {
padding-right: 17px;
}
}
</style>
<template>
<RelDialog :type='type' :editApp='editApp' :app='app' :buttonApp='buttonApp'>
<!-- 填写表单内容,slot=form必写-->
<el-form slot="form" ref="form" :model="form" label-width="80px" :rules="rules">
<el-row :gutter="20">
<el-col :span="12">
<el-form-item v-rule="{
required:true,
rules:rules,
}" label="仓库" ref="ckid" prop="ckid">
<!-- <el-input :readonly="readonly" v-model="form.name" ></el-input> -->
<RelSelect :readonly="readonly" filterable style="width: 100%;" src='jcsj/ck/init/getKwglCk' :match="{value:'id',label:'name'}" v-model='form.ckid' ></RelSelect>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item v-rule="{
required:true,
rules:rules,
}" label="库位编码" ref="code" prop="code">
<el-input :readonly="readonly" v-model="form.code"></el-input>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item v-rule="{
required:true,
rules:rules,
}" label="库位名称" ref="name" prop="name">
<el-input :readonly="readonly" v-model="form.name"></el-input>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="备注" ref="bz" prop="bz">
<el-input :readonly="readonly" v-model="form.bz"></el-input>
</el-form-item>
</el-col>
</el-row>
</el-form>
</RelDialog>
</template>
<script>
import {editMixin} from 'common'
export default {
mixins: [editMixin],
/* 存放index页面传递的额外参数*/
mounted() {
},
/* 组件名称*/
/* 传递props模式一样必填,用于index,button,REdialog之间的组件通信*/
data() {
return {
/* 当前表单初始值,默认由RelDialog查询indexQuery赋值,copy时不赋值id,初始化时所有query的值都会赋值给form*/
form: {
ckid:"",
code:'',
name:'',
bz:''
}
}
},
methods: {
}
}
</script>
<style scoped lang="scss">
</style>
<template>
<div class="min_full">
<!-- 查询条件-->
<Zdwl :app='this' v-if='showDialog' />
<div class="search" v-condition>
<SearchButton :app='app'></SearchButton>
<el-row :gutter="20" class="search-row-1">
<el-col :span="6" class="search-col">
<div class="search-item">
<span class="search-span">库位:</span>
<el-input v-model="queryParams.condition"></el-input>
</div>
</el-col>
<el-col :span="6" class="search-col">
<div class="search-item">
<span class="search-span">仓库:</span>
<RelSelect style="width: 100%;" src='/jcsj/ck/init/getKwglCk' filterable clearable
:match="{value:'id',label:'name'}" v-model='queryParams.ckid'></RelSelect>
</div>
</el-col>
</el-row>
</div>
<!-- 按钮操作-->
<el-row class="tool-bar">
<ToolButton :app='app'></ToolButton>
<ViewButton ref="view" :app='app'></ViewButton>
<AddButton ref="add" :app='app'></AddButton>
<CopyButton ref="copy" :app='app'></CopyButton>
<EditButton ref="edit" :app='app'></EditButton>
<el-button size='mini' @click.native="zdwl()" type="primary">指定物料</el-button>
<!-- <AttachFileButton :app='app' ></AttachFileButton> -->
<!-- 额外按钮-->
<!-- 表头设置 -->
<!-- 权限-->
</el-row>
<!-- 表格-->
<div class="tablePagers">
<TablePager @getData='getData' :ref="'TablePager'" :app='this' :query='query' @selectItem='selectItem'
@getRow='getRow'>
<template slot="tabCustom">
<el-table-column label="启用/停用" width="90" header-align="center" fixed="right" >
<template slot-scope="scope">
<el-switch @click.native="setEnable(scope.row.id)" :value='tybz(scope)' style="width: 80px;justify-content: center;"
active-color="#13ce66" inactive-color="#eee">
</el-switch>
</template>
</el-table-column>
</template>
</TablePager>
</div>
</div>
</template>
<script>
import {
doQuery,
doAdd,
doUpdate,
doDelete,
qt
} from '@/api/baseData/store/location.js';
/* edit页面*/
import Edit from './edit'
import Zdwl from './zdwl.vue'
import {
tableMixin
} from 'common'
export default {
mixins: [tableMixin],
name: 'baseDataLocation',
/* 初始额外赋值*/
async mounted() {
this.$refs['TablePager'].pageQuery()
},
data() {
return {
/*需要的额外参数 */
showDialog: false,
DialogName: '',
type: '',
DialogTitle: '',
/* 基础url*/
baseUrl: 'jcsj/kw',
/* 查询参数*/
queryParams: {
condition: '',
ckid: ''
},
/* 启用停用*/
/* 表格标题对应参数*/
tableTitle: [
{
title: "库位编码",
field: "code",
width: 120
},
{
title: "库位描述",
field: "name",
width: 140
},
{
title: "仓库名称",
field: "ckname",
width: 140
},
{
title: "状态",
field: "tybz",
formatter:function(a,b,c){
let map={
Y:'禁用',
N:'正常'
}
return map[c]
}
},
{
title: "停用日期",
field: "tyrq",
fieldType: 'ftDate'
},
{
title: "备注",
field: "bz",
width: 240
},
{
title: "维护人",
field: "whr"
},
{
title: "维护时间",
field: "whsj",
fieldType: 'ftDateTime'
},
{
title: "创建人",
field: "cjr",
hidden: true
},
{
title: "创建时间",
field: "cjsj",
fieldType: 'ftDateTime',
hidden: true
}
]
}
},
methods: {
setEnable(id) {
this.$confirm('是否启用/停用, 是否继续?', '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning'
}).then(() => {
let params = {
id: id
}
qt(params).then(res => {
if (res.success) {
this.$success('操作成功')
this.app.$refs['TablePager'].reLoad()
} else {
this.$error(res.message || '操作失败')
}
})
})
},
tybz(a) {
let nTy = false
nTy = (a.row.tybz == 'N' ? true : false)
return nTy
},
zdwl() {
if (this.app.selectOne || this.app.clickOne) {
// this.DialogName = 'zdwl'
this.DialogWidth = '70%'
this.DialogTitle = '指定物料'
this.showDialog = true
} else {
this.$warning('请选中一行操作');
}
},
/* 基础查询*/
query: doQuery,
/* 基础增*/
apiAdd: doAdd,
/* 基础更新*/
apiUpdate: doUpdate,
/* 删除操作*/
apiDelete: doDelete,
/* 初始化赋值操作*/
init() {
}
},
components: {
Edit,Zdwl
}
}
</script>
<style scoped>
</style>
<template>
<DefaultDialog :app='app'>
<div slot="form" class="min_full" style="height: 70vh;" >
<div class="search" v-condition>
<SearchButton :app='this'></SearchButton>
<el-row :gutter="20" class="search-row-1">
<el-col :span="6" class="search-col">
<div class="search-item">
<span class="search-span">物料信息:</span>
<el-input v-model="queryParams.wlinfo"></el-input>
</div>
</el-col>
</el-row>
</div>
<!-- 按钮操作-->
<el-row class="tool-bar">
<selectMaterial ref="selectMaterial" :params="params" @save="save" />
</el-row>
<!-- 表格-->
<div class="tablePagers">
<TablePager @getData='getData' :ref="'TablePager'" :app='this' :query='query' @selectItem='selectItem' :editButton="false"
@getRow='getRow'>
</TablePager>
</div>
</div>
<div slot="reFooter" class="refooter">
<span slot="footer" class="dialog-footer">
<el-button @click="app.showDialog=false">取 消</el-button>
<el-button type="primary" @click="save()">保 存</el-button>
</span>
</div>
</DefaultDialog>
</template>
<script>
import {
queryKwwl,
delKwwl,
addKwwl
} from '@/api/baseData/store/location.js';
import {
tableMixin_noapp
} from 'common'
export default {
mixins: [tableMixin_noapp],
props: {
app: {
type: Object,
default: () => {
return {}
}
}
},
async mounted() {
this.$nextTick(()=>{
this.queryParams.kwid=this.app.singleItem.id
this.params.kwid=this.app.singleItem.id
this.$refs['TablePager'].pageQuery()
})
},
data() {
return {
params:{
},
queryParams:{
wlinfo:'',
kwid:''
},
tableTitle: [{
title: "物料ID",
field: "wlid",
hidden: true
},
{
title: "物料编码",
field: "wlxxCode",
width: 140,
allowEdit: false
},
{
title: "物料名称",
field: "wlxxName",
width: 160,
allowEdit: false
},
{
title: "规格",
field: "wlxxGg",
width: 120,
allowEdit: false
},
{
title: "计量单位",
field: "jldwName",
width: 120,
allowEdit: false
},
{
title: "备注",
field: "bz",
width: 224
}
]
}
},
methods: {
query: queryKwwl,
apiDelete: delKwwl,
save(e){
let kwwl=[]
e.forEach(item=>{
kwwl.push({
wlid:item.id
})
})
let params={
kwwl:kwwl,
kwid:this.queryParams.kwid
}
addKwwl(params).then(res=>{
if(res.success){
this.$refs.selectMaterial.showDialog=false
this.$success("操作成功")
this.$refs.TablePager.pageQuery()
}
})
}
}
}
</script>
<style scoped>
</style>
<template>
<RelDialog :type='type' :editApp='editApp' :app='app' :buttonApp='buttonApp'>
<!-- 填写表单内容,slot=form必写-->
<el-form slot="form" ref="form" :model="form" label-width="80px" :rules="rules">
<el-row :gutter="20">
<el-col :span="12">
<el-form-item v-rule="{
required:true,
rules:rules,
}" label="仓库编码" ref="code" prop="code">
<el-input :readonly="readonly" v-model="form.code"></el-input>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item v-rule="{
required:true,
rules:rules,
}" label="仓库名称" ref="name" prop="name">
<el-input :readonly="readonly" v-model="form.name"></el-input>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="入库单前缀" ref="rkdqz" prop="rkdqz">
<el-input :readonly="readonly" v-model="form.rkdqz"></el-input>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="出库单前缀" ref="ckdqz" prop="ckdqz">
<el-input :readonly="readonly" v-model="form.ckdqz"></el-input>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item v-rule="{
required:true,
rules:rules,
}" label="仓库分类" ref="flid" prop="flid">
<RelSelect style="width: 100%;" src='jcsj/ck/init/ckfl' clearable :match="{value:'id',label:'name'}" v-model='form.flid' ></RelSelect>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="保管员" ref="bgy" prop="bgy">
<el-input :readonly="readonly" v-model="form.bgy"></el-input>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="所属车间" ref="bmid" prop="bmid">
<RelSelect style="width: 100%;" src='jcsj/common/bm/query' clearable :match="{value:'id',label:'bmmc'}" v-model='form.bmid' ></RelSelect>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item >
<el-checkbox v-model="form.kwgl" true-label="Y" false-label="N" >库位管理</el-checkbox>
<el-checkbox v-model="form.gysgl" true-label="Y" false-label="N" >供应商管理</el-checkbox>
</el-form-item>
</el-col>
<el-col :span="24">
<el-form-item label="备注" ref="bz" prop="bz">
<el-input :readonly="readonly" v-model="form.bz"></el-input>
</el-form-item>
</el-col>
</el-row>
</el-form>
</RelDialog>
</template>
<script>
import {editMixin} from 'common'
export default {
mixins: [editMixin],
/* 存放index页面传递的额外参数*/
mounted() {
},
/* 组件名称*/
/* 传递props模式一样必填,用于index,button,REdialog之间的组件通信*/
data() {
return {
/* 当前表单初始值,默认由RelDialog查询indexQuery赋值,copy时不赋值id,初始化时所有query的值都会赋值给form*/
form: {
code:'',
id:'',
name:'',
rkdqz:'',
ckdqz:'',
flid:'',
bgy:'',
bz:'',
gysgl:'N',
kwgl:'N'
}
}
},
methods: {
}
}
</script>
<style scoped lang="scss">
</style>
<template>
<div class="min_full">
<!-- 查询条件-->
<div class="search" v-condition>
<SearchButton :app='app'></SearchButton>
<el-row :gutter="20" class="search-row-1">
<el-col :span="6" class="search-col">
<div class="search-item">
<span class="search-span">仓库:</span>
<el-input v-model="queryParams.ckinfo"></el-input>
</div>
</el-col>
</el-row>
</div>
<!-- 按钮操作-->
<el-row class="tool-bar">
<ToolButton :app='app'></ToolButton>
<ViewButton ref="view" :app='app'></ViewButton>
<AddButton ref="add" :app='app'></AddButton>
<CopyButton ref="copy" :app='app'></CopyButton>
<EditButton ref="edit" :app='app'></EditButton>
<!-- <AttachFileButton :app='app' ></AttachFileButton> -->
<!-- 额外按钮-->
<!-- 表头设置 -->
<!-- 权限-->
</el-row>
<!-- 表格-->
<div class="tablePagers">
<TablePager @getData='getData' :ref="'TablePager'" :app='app' :query='query' @selectItem='selectItem'
@getRow='getRow'>
<template slot="tabCustom">
<el-table-column label="启用/停用" width="90" header-align="center" fixed="right" >
<template slot-scope="scope">
<el-switch @click.native="setEnable(scope.row.id)" :value='tybz(scope)' style="width: 80px;justify-content: center;"
active-color="#13ce66" inactive-color="#eee">
</el-switch>
</template>
</el-table-column>
</template>
</TablePager>
</div>
</div>
</template>
<script>
import {
doQuery,
doAdd,
doUpdate,
doDelete,
qt
} from '@/api/baseData/store/maintenance.js';
/* edit页面*/
import Edit from './edit'
import {
tableMixin
} from 'common'
export default {
mixins: [tableMixin],
name: 'storeMaintenance',
/* 初始额外赋值*/
async mounted() {
this.$refs['TablePager'].pageQuery()
},
data() {
return {
/*需要的额外参数 */
showDialog: false,
DialogName: '',
type: '',
DialogTitle: '',
/* 基础url*/
baseUrl: 'jcsj/ck',
/* 查询参数*/
queryParams: {
ckinfo: ''
},
/* 表格标题对应参数*/
tableTitle: [
{title:"仓库编码",field:"code",width:120},
{title:"仓库名称",field:"name",width:140},
// {title: "仓库分类", field: "flid", width: 100,align:"center",formatter: function (A, B, value) {
// var text = ckflData[value];
// return text || "";
// }
// },
{title:"入库单前缀",field:"rkdqz",width:120},
{title:"出库单前缀",field:"ckdqz",width:120},
/* {title:"实物库",field:"swk",width:80,fieldType:"checkbox"}, */
{title:"保管员",field:"bgy",width:140},
{title:"所属车间",field:"bmName",width:160},
{title:"库位管理",field:"kwgl",width:80,formatter:function(a,b,c){
let map={
Y:'开启',
N:'关闭'
}
return map[c]
}},
{title:"供应商管理",field:"gysgl",width:80,formatter:function(a,b,c){
let map={
Y:'开启',
N:'关闭'
}
return map[c]
}},
/* {title:"客户管理",field:"khgl",width:80,fieldType:"checkbox"},*/
{title: "状态",field: "tybz",formatter:function(a,b,c){
let map={
Y:'禁用',
N:'正常'
}
return map[c]
}},
{title: "停用日期",field: "tyrq", fieldType:'ftDate'},
{title:"备注",field:"bz",width:240},
{title:"维护人",field:"whr"},
{title:"维护时间",field:"whsj",fieldType:'ftDateTime'}
]
}
},
methods: {
tybz(a) {
let nTy = false
nTy = (a.row.tybz == 'N' ? true : false)
return nTy
},
/* 启用停用*/
setEnable(id) {
this.$confirm('是否启用/停用, 是否继续?', '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning'
}).then(() => {
let params = {
id: id
}
qt(params).then(res => {
if (res.success) {
this.$success('操作成功')
this.app.$refs['TablePager'].reLoad()
} else {
this.$error(res.message || '操作失败')
}
})
})
},
/* 基础查询*/
query: doQuery,
/* 基础增*/
apiAdd: doAdd,
/* 基础更新*/
apiUpdate: doUpdate,
/* 删除操作*/
apiDelete: doDelete,
/* 初始化赋值操作*/
init() {
}
},
components: {
Edit,
}
}
</script>
<style scoped>
</style>
<template>
<RelDialog width="50%" :type='type' :editApp='editApp' :app='app' :buttonApp='buttonApp'>
<el-form slot="form" ref="form" :model="form" label-width="100px" :rules="rules">
<el-row :gutter="20" :app="this">
<EditColItem :required="item.required||false" :readonly="item.readonly?true:false " v-for="(item,index) in editColItemList " :value="item.value" :span="item.span" :label="item.label" :prop='item.prop' :key="item.prop" :type="item.type" :typeConfig='item.typeConfig' :rule="item.rule" />
</el-row>
</el-form>
</RelDialog>
</template>
<script>
import {
editMixin
} from 'common'
export default {
mixins: [editMixin],
data() {
return {
editColItemList: [
{
label: '人员编码',
prop: 'usercode',
span: 12,
type: 'input',
required:'true',
},
{
label: '姓名',
prop: 'username',
span: 12,
type: 'input',
required:true,
},
{
label: '手机号',
prop: 'phone',
span: 12,
type: 'inputNumber',
rule:'phone'
},
{
label: '部门',
prop: 'bmid',
span: 12,
type: 'RelSelect',
typeConfig:{
match:{
key:'bmid',
value:'bmmc',
},
src:'/kzzx/bm/query'
}
},
{
label: '备注',
prop: 'bz',
span: 24,
type: 'input'
},
]
}
}
}
</script>
<template>
<div class="min_full">
<!-- 查询条件-->
<div class="search" v-condition>
<SearchButton :app='app'></SearchButton>
<el-row :gutter="20" class="search-row-1">
<el-col :span="6" class="search-col">
<div class="search-item">
<span class="search-span">部门:</span>
<RelSelect style="width: 100%;" src='jcsj/common/bm/queryXsckBm' filterable clearable
:match="{value:'id',label:'bmmc'}" v-model='queryParams.bmid'></RelSelect>
</div>
</el-col>
<el-col :span="6" class="search-col">
<div class="search-item">
<span class="search-span">人员信息:</span>
<el-input v-model="queryParams.userinfo"></el-input>
</div>
</el-col>
</el-row>
</div>
<!-- 按钮操作-->
<el-row class="tool-bar">
<ToolButton :app='app'></ToolButton>
<ViewButton ref="view" :app='app'></ViewButton>
<AddButton ref="add" :app='app'></AddButton>
<CopyButton ref="copy" :app='app'></CopyButton>
<EditButton ref="edit" :app='app'></EditButton>
<ImportPersonnelButton :query="getCgryForImp" @save="save" />
<!-- 额外按钮-->
<!-- 表头设置 -->
<!-- 权限-->
</el-row>
<!-- 表格-->
<div class="tablePagers">
<TablePager @getData='getData' :ref="'TablePager'" :app='app' :query='query' @selectItem='selectItem'
@getRow='getRow'>
</TablePager>
</div>
</div>
</template>
<script>
import {
doQuery,
doAdd,
doUpdate,
doDelete,
importCgry,
getCgryForImp
} from '@/api/baseData/supplier/attribute.js';
/* edit页面*/
import Edit from './edit'
import {
tableMixin
} from 'common'
export default {
mixins: [tableMixin],
name: 'supplierAttribute',
/* 初始额外赋值*/
async mounted() {
this.$refs['TablePager'].pageQuery()
},
data() {
return {
getCgryForImp:getCgryForImp,
/*需要的额外参数 */
// showDialog: false,
// DialogName: '',
// type: '',
// DialogTitle: '',
/* 基础url*/
baseUrl: 'csj/cgry',
/* 查询参数*/
queryParams: {
userinfo: '',
bmid: ''
},
/* 表格标题对应参数*/
tableTitle: [
{title: "人员编码",field: "usercode",width:140},
{title: "姓名", field: "username",width:140},
{title: "人员编码", field: "userid", fieldType:"ftString",width:140,hidden:true},
{title: "部门编码", field: "bmid", fieldType:"ftString",width:140,hidden:true},
{title: "部门名称", field: "bmName", fieldType:"ftString",width:140},
{title: "备注", field: "bz", fieldType:"ftString",width:240},
{title: "维护人", field: "whr", fieldType:"username"},
{title: "维护时间", field: "whsj", fieldType:"ftDateTime"}
]
}
},
methods: {
save(list){
importCgry({
userList:list
}).then(res=>{
if(res.success){
this.$success('添加成功')
this.$refs['TablePager'].pageQuery()
}
})
},
/* 基础查询*/
query: doQuery,
/* 基础增*/
apiAdd: doAdd,
/* 基础更新*/
apiUpdate: doUpdate,
/* 删除操作*/
apiDelete: doDelete,
/* 初始化赋值操作*/
// init() {
// }
},
components: {
Edit,
}
}
</script>
<style scoped>
</style>
<template>
<RelDialog width="50%" :type='type' :editApp='editApp' :app='app' :buttonApp='buttonApp'>
<el-form slot="form" ref="form" :model="form" label-width="100px" :rules="rules">
<el-row :gutter="20" :app="this">
<EditColItem :required="item.required||false" :readonly="item.readonly?true:false " v-for="(item,index) in editColItemList " :value="item.value" :span="item.span" :label="item.label" :prop='item.prop' :key="item.prop" :type="item.type" :typeConfig='item.typeConfig' :rule="item.rule" />
</el-row>
</el-form>
</RelDialog>
</template>
<script>
import {
editMixin
} from 'common'
export default {
mixins: [editMixin],
data() {
return {
editColItemList: [
{
label: '编码',
prop: 'code',
span: 12,
type: 'input',
required:true,
},
{
label: '名称',
prop: 'name',
span: 12,
type: 'input',
required:true,
},
{
label: '备注',
prop: 'bz',
span: 24,
type: 'input'
},
]
}
}
}
</script>
<template>
<BasePage class="min_full" :config="config" >
<template #dialog="ctx" >
</template>
<template #toolbar="ctx" >
</template>
</BasePage>
</template>
<script>
import Edit from './edit.vue'
export default{
data(){
return{
config:{
/* 基本配置*/
url:'jcsj/gysfl',
tableTitle: [
{title: "编码", field: "code", fieldType:"upper", width: 140},
{title: "名称", field: "name", width: 140},
{title: "停用", field: "tybz",fieldType:"tybz"},
{title: "停用日期", field: "tyrq", fieldType:"ftDate"},
{title: "维护人", field: "whr"},
{title: "维护时间", field: "whsj", fieldType:"ftDateTime"},
],
queryParams:[[
{
label: '编码',
prop: 'code',
span: 6,
type: 'input',
value:''
},
{
label: '名称',
prop: 'name',
span: 6,
type: 'input',
value:''
}
]],
showqt:true,
}
}
},
methods: {
},
components:{
Edit
}
}
</script>
<style>
</style>
<template>
<section class="app-main">
<transition name="fade-transform" mode="out-in">
<router-view />
</transition>
</section>
</template>
<script>
export default {
name: 'dictionary',
computed: {
cachedViews() {
return this.$store.state.tagsView.cachedViews
},
key() {
return this.$route.path
}
}
}
</script>
<style lang="scss" scoped>
.app-main {
/* 50= navbar 50 */
min-height: calc(100vh - 50px);
width: 100%;
position: relative;
overflow: hidden;
}
.fixed-header+.app-main {
padding-top: 50px;
}
.hasTagsView {
.app-main {
/* 84 = navbar + tags-view = 50 + 34 */
min-height: calc(100vh - 84px);
}
.fixed-header+.app-main {
padding-top: 84px;
}
}
</style>
<style lang="scss">
// fix css style bug in open el-dialog
.el-popup-parent--hidden {
.fixed-header {
padding-right: 17px;
}
}
</style>
<template>
<RelDialog width="50%" :type='type' :editApp='editApp' :app='app' :buttonApp='buttonApp'>
<el-form slot="form" ref="form" :model="form" label-width="100px" :rules="rules">
<el-row :gutter="20" :app="this">
<EditColItem :required="item.required||false" :readonly="item.readonly?true:false " v-for="(item,index) in editColItemList " :value="item.value" :span="item.span" :label="item.label" :prop='item.prop' :key="item.prop" :type="item.type" :typeConfig='item.typeConfig' :rule="item.rule" />
</el-row>
</el-form>
</RelDialog>
</template>
<script>
import {
editMixin
} from 'common'
export default {
mixins: [editMixin],
data() {
return {
editColItemList: [
{
label: '供应商编码',
prop: 'code',
span: 12,
type: 'input',
},
{
label: '供应商名称',
prop: 'name',
span: 12,
type: 'input',
required:true,
},
{
label: '简称',
prop: 'fullname',
span: 12,
type: 'input',
},
{
label: '联系人',
prop: 'lxr',
span: 12,
type: 'input',
},
{
label: '电话',
prop: 'tel',
span: 12,
type: 'input',
},
{
label: '邮箱',
prop: 'email',
span: 12,
type: 'input',
},
{
label: '传真',
prop: 'fax',
span: 12,
type: 'input'
},
{
label: '地址',
prop: 'address',
span: 12,
type: 'input',
},
{
label: '开户银行',
prop: 'bank',
span: 12,
type: 'input',
},
{
label: '账号',
prop: 'account',
span: 12,
type: 'input',
},
{
label: '税号',
prop: 'taxid',
span: 12,
type: 'input',
},
{
label: '法人代表',
prop: 'ceo',
span: 12,
type: 'input',
},
{
label: '财务主管',
prop: 'cfo',
span: 12,
type: 'input',
},
{
label: '采购员',
prop: 'cgyid',
span: 12,
type: 'AuxInput',
typeConfig:{
code:'PURCHASER',
label:'username',
transform:{
value:'userid',
label:'username'
}
}
},
{
label: '供应商分类',
prop: 'gysflid',
span: 12,
type: 'RelSelect',
typeConfig:{
src:'/jcsj/gysfl/query'
}
},
{
label: '备注',
prop: 'bz',
span: 24,
type: 'input'
},
]
}
}
}
</script>
<template>
<div class="min_full">
<!-- 查询条件-->
<div class="search" v-condition>
<SearchButton :app='app'></SearchButton>
<el-row :gutter="20" class="search-row-1">
<el-col :span="6" class="search-col">
<div class="search-item">
<span class="search-span">编码:</span>
<el-input v-model="queryParams.code"></el-input>
</div>
</el-col>
<el-col :span="6" class="search-col">
<div class="search-item">
<span class="search-span">名称:</span>
<el-input v-model="queryParams.name"></el-input>
</div>
</el-col>
</el-row>
</div>
<!-- 按钮操作-->
<el-row class="tool-bar">
<ToolButton :app='app'></ToolButton>
<ViewButton ref="view" :app='app'></ViewButton>
<AddButton ref="add" :app='app'></AddButton>
<CopyButton ref="copy" :app='app'></CopyButton>
<EditButton ref="edit" :app='app'></EditButton>
<ExportTempButton :url="'jcsj/gys/excel/export'" :exportName="'供应商信息导入模板.xlsx'" ></ExportTempButton>
<ImportTempButton @success="()=>{
$refs['TablePager'].pageQuery()
}" :url="'jcsj/gys/import'"></ImportTempButton>
<!-- <AttachFileButton :app='app' ></AttachFileButton> -->
<!-- 额外按钮-->
<!-- 表头设置 -->
<!-- 权限-->
</el-row>
<!-- 表格-->
<div class="tablePagers">
<TablePager @getData='getData' :ref="'TablePager'" :app='app' :query='query' @selectItem='selectItem'
@getRow='getRow'>
<template slot="tabCustom">
<el-table-column label="启用/停用" width="90" header-align="center" fixed="right" >
<template slot-scope="scope">
<el-switch @click.native="setEnable(scope.row.id)" :value='tybz(scope)' style="width: 80px;justify-content: center;"
active-color="#13ce66" inactive-color="#eee">
</el-switch>
</template>
</el-table-column>
</template>
</TablePager>
</div>
</div>
</template>
<script>
import {
doQuery,
doAdd,
doUpdate,
doDelete,
qt
} from '@/api/baseData/supplier/info.js';
/* edit页面*/
import Edit from './edit'
import {
tableMixin
} from 'common'
export default {
mixins: [tableMixin],
name: 'supplierInfo',
/* 初始额外赋值*/
async mounted() {
this.$refs['TablePager'].pageQuery()
},
data() {
return {
/*需要的额外参数 */
// showDialog: false,
// DialogName: '',
// type: '',
// DialogTitle: '',
/* 基础url*/
baseUrl: 'jcsj/gys',
/* 查询参数*/
queryParams: {
code: '',
name: '',
},
/* 表格标题对应参数*/
tableTitle: [
{title: "供应商编码", field: "code", fieldType:"upper", width: 140},
{title: "供应商名称", field: "name", width: 140},
{title: "简称", field: "fullname", width: 160},
{title: "联系人", field: "lxr", width: 160},
{title: "电话", field: "tel", width: 120},
{title: "邮箱", field: "email", width: 120},
{title: "传真", field: "fax", width: 120},
{title: "地址", field: "address", width: 120},
{title: "开户银行", field: "bank", width: 120},
{title: "账号", field: "account", width: 120},
{title: "税号", field: "taxid", width: 120},
{title: "法人代表", field: "ceo", width: 120},
{title: "财务主管", field: "cfo", width: 120},
{title: "采购员", field: "username", width: 120},
{title: "附件数", field: "attachcount", fieldType:"int"},
{title: "状态", field: "tybz",fieldType:'tybz'},
{title: "停用日期", field: "tyrq", fieldType:"ftDate"},
{title: "备注", field: "bz", width: 250},
{title: "维护人", field: "whr"},
{title: "维护时间", field: "whsj", fieldType:"ftDateTime"},
{title: "创建人",field:"cjr", hidden:true},
{title: "创建时间",field:"cjsj",fieldType:'ftDateTime', hidden:true}
]
}
},
methods: {
setEnable(id) {
this.$confirm('是否启用/停用该属性, 是否继续?', '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning'
}).then(() => {
let params = {
id: id
}
qt(params).then(res => {
if (res.success) {
this.$success('操作成功')
this.app.$refs['TablePager'].reLoad()
} else {
this.$error(res.message || '操作失败')
}
})
})
},
tybz(a) {
let nTy = false
nTy = (a.row.tybz == 'Y' ? true : false)
return nTy
},
/* 基础查询*/
query: doQuery,
/* 基础增*/
apiAdd: doAdd,
/* 基础更新*/
apiUpdate: doUpdate,
/* 删除操作*/
apiDelete: doDelete,
/* 初始化赋值操作*/
// init() {
// }
},
components: {
Edit,
}
}
</script>
<style scoped>
</style>
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment