提交 ad75a61d 编写于 作者: ibizdev's avatar ibizdev

xignzi006 发布系统代码

上级 a988c15f
......@@ -639,6 +639,16 @@
"viewtag": "697373026d90700244354625e1d01cc2",
"memo": "系统自动添加"
},
"accountgradation": {
"title": "客户树导航视图",
"caption": "客户",
"viewtype": "DETREEEXPVIEW",
"viewmodule": "Base",
"viewname": "AccountGradation",
"viewfilename": "account-gradation",
"viewtag": "6978259896338a7ace85a9fbc5d70395",
"memo": ""
},
"opportunityproductopp_oppprogridview": {
"title": "商机产品表格视图",
"caption": "商机产品",
......
......@@ -196,6 +196,10 @@ export default {
edit_accountinfo: {
caption: "账户信息",
title: '账户信息',
},
gradation: {
caption: "客户",
title: '客户树导航视图',
},
editview: {
caption: "客户",
......@@ -701,4 +705,11 @@ export default {
tip: "Filter",
},
},
account_treeview: {
nodes: {
root: '全部客户',
},
uiactions: {
},
},
};
\ No newline at end of file
......@@ -195,6 +195,10 @@ export default {
edit_accountinfo: {
caption: '账户信息',
title: '账户信息',
},
gradation: {
caption: '客户',
title: '客户树导航视图',
},
editview: {
caption: '客户',
......@@ -700,4 +704,11 @@ export default {
tip: '过滤',
},
},
account_treeview: {
nodes: {
root: '全部客户',
},
uiactions: {
},
},
};
\ No newline at end of file
......@@ -271,6 +271,50 @@ mock.onGet(new RegExp(/^\/accounts\/getdraft$/)).reply((config: any) => {
return [status, {}];
});
// FetchRoot
mock.onGet(new RegExp(/^\/accounts\/fetchroot$/)).reply((config: any) => {
console.groupCollapsed("实体:account 方法: FetchRoot");
console.table({url:config.url, method: config.method, data:config.data});
let status = MockAdapter.mockStatus(config);
if (status !== 200) {
return [status, null];
}
console.groupCollapsed("response数据 status: "+status+" data: ");
console.table(mockDatas);
console.groupEnd();
console.groupEnd();
return [status, mockDatas ? mockDatas : []];
});
// FetchRoot
mock.onGet(new RegExp(/^\/accounts\/fetchroot(\?[\w-./?%&=,]*)*$/)).reply((config: any) => {
console.groupCollapsed("实体:account 方法: FetchRoot");
console.table({url:config.url, method: config.method, data:config.data});
if(config.url.includes('page')){
let url = config.url.split('?')[1];
let params = qs.parse(url);
Object.assign(config, params);
}
let status = MockAdapter.mockStatus(config);
if (status !== 200) {
return [status, null];
}
let total = mockDatas.length;
let records: Array<any> = [];
if(!config.page || !config.size){
records = mockDatas;
}else{
if((config.page-1)*config.size < total){
records = mockDatas.slice(config.page,config.size);
}
}
console.groupCollapsed("response数据 status: "+status+" data: ");
console.table(records ? records : []);
console.groupEnd();
console.groupEnd();
return [status, records ? records : []];
});
// FetchDefault
mock.onGet(new RegExp(/^\/accounts\/fetchdefault$/)).reply((config: any) => {
console.groupCollapsed("实体:account 方法: FetchDefault");
......
......@@ -519,6 +519,14 @@ mock.onGet('./assets/json/view-config.json').reply((config: any) => {
"viewname": "CampaignInfo_Manager",
"viewtag": "697373026d90700244354625e1d01cc2"
},
"accountgradation": {
"title": "客户树导航视图",
"caption": "客户",
"viewtype": "DETREEEXPVIEW",
"viewmodule": "Base",
"viewname": "AccountGradation",
"viewtag": "6978259896338a7ace85a9fbc5d70395"
},
"opportunityproductopp_oppprogridview": {
"title": "商机产品表格视图",
"caption": "商机产品",
......
<template>
<studio-view-style2 viewName="accountgradation" viewTitle="客户树导航视图" class='detreeexpview account-gradation'>
<template slot='title'>
<span class='caption-info'>{{$t(model.srfTitle)}}</span>
</template>
<view_treeexpbar
:viewState="viewState"
:viewparams="viewparams"
:context="context"
:viewUID="viewUID"
name="treeexpbar"
ref='treeexpbar'
@selectionchange="treeexpbar_selectionchange($event)"
@activated="treeexpbar_activated($event)"
@load="treeexpbar_load($event)"
@closeview="closeView($event)">
</view_treeexpbar>
</studio-view-style2>
</template>
<script lang='tsx'>
import { Component, Prop, Provide, Emit, Watch } from 'vue-property-decorator';
import { Subject } from 'rxjs';
import { UIActionTool, Util } from '@/utils';
import { VueLifeCycleProcessing, TreeExpViewBase } from '@/studio-core';
import AccountService from '@/service/account/account-service';
import TreeExpViewEngine from '@engine/view/tree-exp-view-engine';
/**
* 客户树导航视图视图基类
*
* @export
* @class AccountGradationBase
* @extends {TreeExpViewBase}
*/
@Component({})
@VueLifeCycleProcessing()
export default class AccountGradationBase extends TreeExpViewBase {
/**
* 实体服务对象
*
* @type {AccountService}
* @memberof AccountGradationBase
*/
protected appEntityService: AccountService = new AccountService;
/**
* 计数器服务对象集合
*
* @protected
* @type {Array<*>}
* @memberof AccountGradationBase
*/
protected counterServiceArray: Array<any> = [];
/**
* 自定义视图导航上下文集合
*
* @protected
* @type {*}
* @memberof AccountGradationBase
*/
protected customViewNavContexts: any = {
};
/**
* 自定义视图导航参数集合
*
* @protected
* @type {*}
* @memberof AccountGradationBase
*/
protected customViewParams: any = {
};
/**
* 视图模型数据
*
* @protected
* @type {*}
* @memberof AccountGradationBase
*/
protected model: any = {
srfCaption: 'entities.account.views.gradation.caption',
srfTitle: 'entities.account.views.gradation.title',
srfSubTitle: 'entities.account.views.gradation.subtitle',
dataInfo: ''
}
/**
* 容器模型
*
* @protected
* @type {*}
* @memberof AccountGradationBase
*/
protected containerModel: any = {
view_treeexpbar: { name: 'treeexpbar', type: 'TREEEXPBAR' },
};
/**
* 视图引擎
*
* @public
* @type {Engine}
* @memberof AccountGradationBase
*/
public engine: TreeExpViewEngine = new TreeExpViewEngine();
/**
* 引擎初始化
*
* @public
* @memberof AccountGradationBase
*/
public engineInit(): void {
this.engine.init({
view: this,
treeexpbar: this.$refs.treeexpbar,
keyPSDEField: 'account',
majorPSDEField: 'accountname',
isLoadDefault: true,
});
}
/**
* treeexpbar 部件 selectionchange 事件
*
* @param {*} [args={}]
* @param {*} $event
* @memberof AccountGradationBase
*/
public treeexpbar_selectionchange($event: any, $event2?: any): void {
this.engine.onCtrlEvent('treeexpbar', 'selectionchange', $event);
}
/**
* treeexpbar 部件 activated 事件
*
* @param {*} [args={}]
* @param {*} $event
* @memberof AccountGradationBase
*/
public treeexpbar_activated($event: any, $event2?: any): void {
this.engine.onCtrlEvent('treeexpbar', 'activated', $event);
}
/**
* treeexpbar 部件 load 事件
*
* @param {*} [args={}]
* @param {*} $event
* @memberof AccountGradationBase
*/
public treeexpbar_load($event: any, $event2?: any): void {
this.engine.onCtrlEvent('treeexpbar', 'load', $event);
}
/**
* 打开新建数据视图
*
* @param {any[]} args
* @param {*} [params]
* @param {*} [fullargs]
* @param {*} [$event]
* @param {*} [xData]
* @memberof AccountGradation
*/
public newdata(args: any[],fullargs?:any[], params?: any, $event?: any, xData?: any) {
let localContext:any = null;
let localViewParam:any =null;
this.$Notice.warning({ title: '错误', desc: '未指定关系视图' });
}
/**
* 打开编辑数据视图
*
* @param {any[]} args
* @param {*} [params]
* @param {*} [fullargs]
* @param {*} [$event]
* @param {*} [xData]
* @memberof AccountGradation
*/
public opendata(args: any[],fullargs?:any[],params?: any, $event?: any, xData?: any) {
let localContext:any = null;
let localViewParam:any =null;
this.$Notice.warning({ title: '错误', desc: '未指定关系视图' });
}
/**
* 视图唯一标识
*
* @type {string}
* @memberof AccountGradation
*/
public viewUID: string = 'base-account-gradation';
}
</script>
<style lang='less'>
@import './account-gradation.less';
</style>
\ No newline at end of file
// 避免空文件,后台不让空文件过
.account-gradation {
--account-gradation: 0;
}
<script lang='tsx'>
import { Component } from 'vue-property-decorator';
import AccountGradationBase from './account-gradation-base.vue';
import view_treeexpbar from '@widgets/account/gradationtreeexpbar-treeexpbar/gradationtreeexpbar-treeexpbar.vue';
@Component({
components: {
view_treeexpbar,
},
beforeRouteEnter: (to: any, from: any, next: any) => {
next((vm: any) => {
vm.$store.commit('addCurPageViewtag', { route: to, viewtag: vm.viewtag });
});
},
})
export default class AccountGradation extends AccountGradationBase {
}
</script>
\ No newline at end of file
<template>
<studio-view-style2 viewName="competitorsummary" viewTitle="竞争对手概览" class='deportalview competitor-summary'>
<template slot='title'>
<span class='caption-info'>{{$t(model.srfTitle)}}</span>
</template>
<view_dashboard
:viewState="viewState"
:viewparams="viewparams"
......
export const PageComponents = {
install(Vue: any, opt: any) {
Vue.component('account-quick-create', () => import('@pages/base/account-quick-create/account-quick-create.vue'));
Vue.component('account-gradation', () => import('@pages/base/account-gradation/account-gradation.vue'));
Vue.component('account-quick-create', () => import('@pages/base/account-quick-create/account-quick-create.vue'));
Vue.component('list-account-by-list', () => import('@pages/marketing/list-account-by-list/list-account-by-list.vue'));
Vue.component('competitor-option-view', () => import('@pages/sales/competitor-option-view/competitor-option-view.vue'));
Vue.component('campaign-response-by-parent-key', () => import('@pages/marketing/campaign-response-by-parent-key/campaign-response-by-parent-key.vue'));
......@@ -16,8 +17,8 @@ export const PageComponents = {
Vue.component('contact-info-person', () => import('@pages/base/contact-info-person/contact-info-person.vue'));
Vue.component('campaign-info-schedule', () => import('@pages/marketing/campaign-info-schedule/campaign-info-schedule.vue'));
Vue.component('opportunity-grid-view', () => import('@pages/sales/opportunity-grid-view/opportunity-grid-view.vue'));
Vue.component('letter-edit-view', () => import('@pages/base/letter-edit-view/letter-edit-view.vue'));
Vue.component('goal-edit-view', () => import('@pages/sales/goal-edit-view/goal-edit-view.vue'));
Vue.component('letter-edit-view', () => import('@pages/base/letter-edit-view/letter-edit-view.vue'));
Vue.component('transaction-currency-pickup-view', () => import('@pages/base/transaction-currency-pickup-view/transaction-currency-pickup-view.vue'));
Vue.component('opportunity-product-edit-view', () => import('@pages/sales/opportunity-product-edit-view/opportunity-product-edit-view.vue'));
Vue.component('email-edit-view', () => import('@pages/base/email-edit-view/email-edit-view.vue'));
......
......@@ -35,6 +35,20 @@ const router = new Router({
},
component: () => import('@pages/ungroup/central/central.vue'),
children: [
{
path: 'accounts/:account?/gradation/:gradation?',
meta: {
caption: 'entities.account.views.gradation.title',
info:'',
parameters: [
{ pathName: 'central', parameterName: 'central' },
{ pathName: 'accounts', parameterName: 'account' },
{ pathName: 'gradation', parameterName: 'gradation' },
],
requireAuth: true,
},
component: () => import('@pages/base/account-gradation/account-gradation.vue'),
},
{
path: 'accounts/:account?/quickcreate/:quickcreate?',
meta: {
......@@ -521,32 +535,32 @@ const router = new Router({
component: () => import('@pages/sales/opportunity-grid-view/opportunity-grid-view.vue'),
},
{
path: 'letters/:letter?/editview/:editview?',
path: 'goals/:goal?/editview/:editview?',
meta: {
caption: 'entities.letter.views.editview.title',
caption: 'entities.goal.views.editview.title',
info:'',
parameters: [
{ pathName: 'central', parameterName: 'central' },
{ pathName: 'letters', parameterName: 'letter' },
{ pathName: 'goals', parameterName: 'goal' },
{ pathName: 'editview', parameterName: 'editview' },
],
requireAuth: true,
},
component: () => import('@pages/base/letter-edit-view/letter-edit-view.vue'),
component: () => import('@pages/sales/goal-edit-view/goal-edit-view.vue'),
},
{
path: 'goals/:goal?/editview/:editview?',
path: 'letters/:letter?/editview/:editview?',
meta: {
caption: 'entities.goal.views.editview.title',
caption: 'entities.letter.views.editview.title',
info:'',
parameters: [
{ pathName: 'central', parameterName: 'central' },
{ pathName: 'goals', parameterName: 'goal' },
{ pathName: 'letters', parameterName: 'letter' },
{ pathName: 'editview', parameterName: 'editview' },
],
requireAuth: true,
},
component: () => import('@pages/sales/goal-edit-view/goal-edit-view.vue'),
component: () => import('@pages/base/letter-edit-view/letter-edit-view.vue'),
},
{
path: 'transactioncurrencies/:transactioncurrency?/pickupview/:pickupview?',
......@@ -3304,28 +3318,27 @@ const router = new Router({
component: () => import('@pages/base/account-inner-pickup-grid-view/account-inner-pickup-grid-view.vue'),
},
{
path: 'ibizlists/:ibizlist?/listaccounts/:listaccount?/inner/:inner?',
path: 'accounts/:account?/edit_introduction/:edit_introduction?',
meta: {
caption: 'entities.listaccount.views.inner.title',
caption: 'entities.account.views.edit_introduction.title',
info:'',
parameters: [
{ pathName: 'central', parameterName: 'central' },
{ pathName: 'ibizlists', parameterName: 'ibizlist' },
{ pathName: 'listaccounts', parameterName: 'listaccount' },
{ pathName: 'inner', parameterName: 'inner' },
{ pathName: 'accounts', parameterName: 'account' },
{ pathName: 'edit_introduction', parameterName: 'edit_introduction' },
],
requireAuth: true,
},
component: () => import('@pages/marketing/list-account-inner/list-account-inner.vue'),
component: () => import('@pages/base/account-edit-introduction/account-edit-introduction.vue'),
},
{
path: 'accounts/:account?/listaccounts/:listaccount?/inner/:inner?',
path: 'ibizlists/:ibizlist?/listaccounts/:listaccount?/inner/:inner?',
meta: {
caption: 'entities.listaccount.views.inner.title',
info:'',
parameters: [
{ pathName: 'central', parameterName: 'central' },
{ pathName: 'accounts', parameterName: 'account' },
{ pathName: 'ibizlists', parameterName: 'ibizlist' },
{ pathName: 'listaccounts', parameterName: 'listaccount' },
{ pathName: 'inner', parameterName: 'inner' },
],
......@@ -3334,12 +3347,13 @@ const router = new Router({
component: () => import('@pages/marketing/list-account-inner/list-account-inner.vue'),
},
{
path: 'listaccounts/:listaccount?/inner/:inner?',
path: 'accounts/:account?/listaccounts/:listaccount?/inner/:inner?',
meta: {
caption: 'entities.listaccount.views.inner.title',
info:'',
parameters: [
{ pathName: 'central', parameterName: 'central' },
{ pathName: 'accounts', parameterName: 'account' },
{ pathName: 'listaccounts', parameterName: 'listaccount' },
{ pathName: 'inner', parameterName: 'inner' },
],
......@@ -3348,18 +3362,18 @@ const router = new Router({
component: () => import('@pages/marketing/list-account-inner/list-account-inner.vue'),
},
{
path: 'accounts/:account?/edit_introduction/:edit_introduction?',
path: 'listaccounts/:listaccount?/inner/:inner?',
meta: {
caption: 'entities.account.views.edit_introduction.title',
caption: 'entities.listaccount.views.inner.title',
info:'',
parameters: [
{ pathName: 'central', parameterName: 'central' },
{ pathName: 'accounts', parameterName: 'account' },
{ pathName: 'edit_introduction', parameterName: 'edit_introduction' },
{ pathName: 'listaccounts', parameterName: 'listaccount' },
{ pathName: 'inner', parameterName: 'inner' },
],
requireAuth: true,
},
component: () => import('@pages/base/account-edit-introduction/account-edit-introduction.vue'),
component: () => import('@pages/marketing/list-account-inner/list-account-inner.vue'),
},
{
path: 'accounts/:account?/contacts/:contact?/summary/:summary?',
......@@ -5115,6 +5129,19 @@ const router = new Router({
},
component: () => import('@pages/marketing/campaign-info-manager/campaign-info-manager.vue'),
},
{
path: '/accounts/:account?/gradation/:gradation?',
meta: {
caption: 'entities.account.views.gradation.title',
info:'',
parameters: [
{ pathName: 'accounts', parameterName: 'account' },
{ pathName: 'gradation', parameterName: 'gradation' },
],
requireAuth: true,
},
component: () => import('@pages/base/account-gradation/account-gradation.vue'),
},
{
path: '/accounts/:account?/contacts/:contact?/opportunities/:opportunity?/opportunityproducts/:opportunityproduct?/opp_oppprogridview/:opp_oppprogridview?',
meta: {
......
......@@ -92,6 +92,21 @@ export default class AccountServiceBase extends EntityService {
}
}
masterData.contacts = contactsData;
let accountsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_accounts'),'undefined')){
accountsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_accounts') as any);
if(accountsData && accountsData.length && accountsData.length > 0){
accountsData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.accountid = null;
}
delete item.srffrontuf;
}
});
}
}
masterData.accounts = accountsData;
Object.assign(data,masterData);
if(!data.srffrontuf || data.srffrontuf !== "1"){
data[this.APPDEKEY] = null;
......@@ -103,6 +118,7 @@ export default class AccountServiceBase extends EntityService {
let res:any = await Http.getInstance().post(`/accounts`,data,isloading);
this.tempStorage.setItem(tempContext.srfsessionkey+'_listaccounts',JSON.stringify(res.data.listaccounts));
this.tempStorage.setItem(tempContext.srfsessionkey+'_contacts',JSON.stringify(res.data.contacts));
this.tempStorage.setItem(tempContext.srfsessionkey+'_accounts',JSON.stringify(res.data.accounts));
return res;
}
......@@ -147,10 +163,26 @@ export default class AccountServiceBase extends EntityService {
}
}
masterData.contacts = contactsData;
let accountsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_accounts'),'undefined')){
accountsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_accounts') as any);
if(accountsData && accountsData.length && accountsData.length > 0){
accountsData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.accountid = null;
}
delete item.srffrontuf;
}
});
}
}
masterData.accounts = accountsData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().put(`/accounts/${context.account}`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_listaccounts',JSON.stringify(res.data.listaccounts));
this.tempStorage.setItem(context.srfsessionkey+'_contacts',JSON.stringify(res.data.contacts));
this.tempStorage.setItem(context.srfsessionkey+'_accounts',JSON.stringify(res.data.accounts));
return res;
}
......@@ -209,10 +241,26 @@ export default class AccountServiceBase extends EntityService {
}
}
masterData.contacts = contactsData;
let accountsData:any = [];
if(!Object.is(this.tempStorage.getItem(context.srfsessionkey+'_accounts'),'undefined')){
accountsData = JSON.parse(this.tempStorage.getItem(context.srfsessionkey+'_accounts') as any);
if(accountsData && accountsData.length && accountsData.length > 0){
accountsData.forEach((item:any) => {
if(item.srffrontuf){
if(Object.is(item.srffrontuf,"0")){
item.accountid = null;
}
delete item.srffrontuf;
}
});
}
}
masterData.accounts = accountsData;
Object.assign(data,masterData);
let res:any = await Http.getInstance().post(`/accounts/${context.account}/save`,data,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_listaccounts',JSON.stringify(res.data.listaccounts));
this.tempStorage.setItem(context.srfsessionkey+'_contacts',JSON.stringify(res.data.contacts));
this.tempStorage.setItem(context.srfsessionkey+'_accounts',JSON.stringify(res.data.accounts));
return res;
}
......@@ -242,6 +290,7 @@ export default class AccountServiceBase extends EntityService {
let res:any = await Http.getInstance().get(`/accounts/${context.account}`,isloading);
this.tempStorage.setItem(context.srfsessionkey+'_listaccounts',JSON.stringify(res.data.listaccounts));
this.tempStorage.setItem(context.srfsessionkey+'_contacts',JSON.stringify(res.data.contacts));
this.tempStorage.setItem(context.srfsessionkey+'_accounts',JSON.stringify(res.data.accounts));
return res;
}
......@@ -260,9 +309,24 @@ export default class AccountServiceBase extends EntityService {
res.data.account = data.account;
this.tempStorage.setItem(context.srfsessionkey+'_listaccounts',JSON.stringify(res.data.listaccounts));
this.tempStorage.setItem(context.srfsessionkey+'_contacts',JSON.stringify(res.data.contacts));
this.tempStorage.setItem(context.srfsessionkey+'_accounts',JSON.stringify(res.data.accounts));
return res;
}
/**
* FetchRoot接口方法
*
* @param {*} [context={}]
* @param {*} [data={}]
* @param {boolean} [isloading]
* @returns {Promise<any>}
* @memberof AccountServiceBase
*/
public async FetchRoot(context: any = {},data: any = {}, isloading?: boolean): Promise<any> {
let tempData:any = JSON.parse(JSON.stringify(data));
return Http.getInstance().get(`/accounts/fetchroot`,tempData,isloading);
}
/**
* FetchDefault接口方法
*
......
......@@ -605,6 +605,16 @@ export const viewstate: any = {
refviews: [
],
},
{
viewtag: '6978259896338a7ace85a9fbc5d70395',
viewmodule: 'Base',
viewname: 'AccountGradation',
viewaction: '',
viewdatachange: false,
refviews: [
'5c7e90ccfaeb49b5bd84ae6c17b479e3',
],
},
{
viewtag: '6c67094479c2f8af7ea1575eee584056',
viewmodule: 'Sales',
......@@ -764,13 +774,13 @@ export const viewstate: any = {
refviews: [
'07c5035fbb847e889f3dbb9657723f30',
'24a93674ec4c976c08902a3e95421ca6',
'6978259896338a7ace85a9fbc5d70395',
'b38bc0256ecd5be1a58a3c2210a98d05',
'5f8f689d5dccc3db6d2b74a24a8b24ef',
'dfc0051ae4813115e03f3d095f8cd7d3',
'631a4276161c551802f3aaf4bd7e607c',
'15d12c1173fcb6e742b6a6d92cbc53ed',
'0326a502bb574cddc41da4323786dcb5',
'5c7e90ccfaeb49b5bd84ae6c17b479e3',
'90b48a107932f432e0dde42791a51887',
'45fdc8ee4d1401d2d625e80177395ddc',
'7FCD2E75-E34A-493C-922E-8AE47BCE08CA',
......
......@@ -87,6 +87,7 @@ export default class AccountUIServiceBase extends UIService {
this.allViewMap.set(':',{viewname:'info_all',srfappde:'accounts'});
this.allViewMap.set('MDATAVIEW:',{viewname:'gridview',srfappde:'accounts'});
this.allViewMap.set(':',{viewname:'edit_accountinfo',srfappde:'accounts'});
this.allViewMap.set(':',{viewname:'gradation',srfappde:'accounts'});
this.allViewMap.set('EDITVIEW:',{viewname:'editview',srfappde:'accounts'});
this.allViewMap.set(':',{viewname:'innerpickupgridview',srfappde:'accounts'});
this.allViewMap.set(':',{viewname:'info_introduction',srfappde:'accounts'});
......
/**
* Account 部件模型
*
* @export
* @class AccountModel
*/
export default class AccountModel {
/**
* 获取数据项集合
*
* @returns {any[]}
* @memberof AccountModel
*/
public getDataItems(): any[] {
return [
{
name: 'address1_primarycontactname',
},
{
name: 'openrevenue_date',
},
{
name: 'address2_utcoffset',
},
{
name: 'fax',
},
{
name: 'address1_composite',
},
{
name: 'entityimage',
},
{
name: 'emailaddress1',
},
{
name: 'overriddencreatedon',
},
{
name: 'address1_stateorprovince',
},
{
name: 'openrevenue',
},
{
name: 'address1_upszone',
},
{
name: 'followemail',
},
{
name: 'marketingonly',
},
{
name: 'numberofemployees',
},
{
name: 'telephone1',
},
{
name: 'aging60',
},
{
name: 'sharesoutstanding',
},
{
name: 'address2_freighttermscode',
},
{
name: 'entityimage_timestamp',
},
{
name: 'revenue_base',
},
{
name: 'accountratingcode',
},
{
name: 'donotbulkemail',
},
{
name: 'aging30',
},
{
name: 'donotbulkpostalmail',
},
{
name: 'creditlimit_base',
},
{
name: 'timezoneruleversionnumber',
},
{
name: 'customertypecode',
},
{
name: 'address2_longitude',
},
{
name: 'accountname',
},
{
name: 'participatesinworkflow',
},
{
name: 'preferredcontactmethodcode',
},
{
name: 'preferredappointmentdaycode',
},
{
name: 'marketcap',
},
{
name: 'address2_telephone1',
},
{
name: 'businesstypecode',
},
{
name: 'entityimageid',
},
{
name: 'address2_city',
},
{
name: 'ownershipcode',
},
{
name: 'utcconversiontimezonecode',
},
{
name: 'accountnumber',
},
{
name: 'address1_telephone2',
},
{
name: 'address1_line1',
},
{
name: 'donotphone',
},
{
name: 'address1_telephone3',
},
{
name: 'exchangerate',
},
{
name: 'address2_line2',
},
{
name: 'address2_telephone3',
},
{
name: 'address1_telephone1',
},
{
name: 'address1_fax',
},
{
name: 'address1_freighttermscode',
},
{
name: 'description',
},
{
name: 'merged',
},
{
name: 'address1_shippingmethodcode',
},
{
name: 'address1_name',
},
{
name: 'aging30_base',
},
{
name: 'address2_telephone2',
},
{
name: 'account',
prop: 'accountid',
},
{
name: 'primarytwitterid',
},
{
name: 'tickersymbol',
},
{
name: 'stockexchange',
},
{
name: 'address2_stateorprovince',
},
{
name: 'ftpsiteurl',
},
{
name: 'statuscode',
},
{
name: 'websiteurl',
},
{
name: 'donotpostalmail',
},
{
name: 'address1_city',
},
{
name: 'address2_fax',
},
{
name: 'aging90_base',
},
{
name: 'opendeals_date',
},
{
name: 'traversedpath',
},
{
name: 'shippingmethodcode',
},
{
name: 'address1_line2',
},
{
name: 'openrevenue_base',
},
{
name: 'updatedate',
},
{
name: 'preferredsystemuseridyominame',
},
{
name: 'address2_line3',
},
{
name: 'address1_postalcode',
},
{
name: 'address2_latitude',
},
{
name: 'ibizprivate',
},
{
name: 'territorycode',
},
{
name: 'teamsfollowed',
},
{
name: 'yominame',
},
{
name: 'address1_latitude',
},
{
name: 'telephone3',
},
{
name: 'ownerid',
},
{
name: 'address2_country',
},
{
name: 'masteraccountidyominame',
},
{
name: 'industrycode',
},
{
name: 'lastonholdtime',
},
{
name: 'address2_addressid',
},
{
name: 'onholdtime',
},
{
name: 'accountclassificationcode',
},
{
name: 'address1_country',
},
{
name: 'address1_addresstypecode',
},
{
name: 'statecode',
},
{
name: 'address2_addresstypecode',
},
{
name: 'accountcategorycode',
},
{
name: 'emailaddress2',
},
{
name: 'address2_shippingmethodcode',
},
{
name: 'importsequencenumber',
},
{
name: 'primarysatoriid',
},
{
name: 'customersizecode',
},
{
name: 'opendeals',
},
{
name: 'donotsendmm',
},
{
name: 'processid',
},
{
name: 'paymenttermscode',
},
{
name: 'sic',
},
{
name: 'address2_primarycontactname',
},
{
name: 'address1_utcoffset',
},
{
name: 'owneridyominame',
},
{
name: 'lastusedincampaign',
},
{
name: 'aging60_base',
},
{
name: 'donotfax',
},
{
name: 'updateman',
},
{
name: 'openrevenue_state',
},
{
name: 'opendeals_state',
},
{
name: 'versionnumber',
},
{
name: 'address1_longitude',
},
{
name: 'aging90',
},
{
name: 'entityimage_url',
},
{
name: 'creditlimit',
},
{
name: 'preferredsystemuserid',
},
{
name: 'revenue',
},
{
name: 'address1_county',
},
{
name: 'address1_line3',
},
{
name: 'stageid',
},
{
name: 'donotemail',
},
{
name: 'address2_postalcode',
},
{
name: 'preferredappointmenttimecode',
},
{
name: 'address2_upszone',
},
{
name: 'createdate',
},
{
name: 'address2_county',
},
{
name: 'owneridtype',
},
{
name: 'address2_composite',
},
{
name: 'address2_name',
},
{
name: 'address2_line1',
},
{
name: 'marketcap_base',
},
{
name: 'emailaddress3',
},
{
name: 'telephone2',
},
{
name: 'createman',
},
{
name: 'address1_postofficebox',
},
{
name: 'creditonhold',
},
{
name: 'address1_addressid',
},
{
name: 'address2_postofficebox',
},
{
name: 'slaname',
},
{
name: 'originatingleadid',
},
{
name: 'transactioncurrencyid',
},
{
name: 'defaultpricelevelid',
},
{
name: 'parentaccountid',
},
{
name: 'preferredequipmentid',
},
{
name: 'territoryid',
},
{
name: 'primarycontactid',
},
{
name: 'slaid',
},
{
name: 'preferredserviceid',
},
{
name: 'originatingleadname',
},
{
name: 'defaultpricelevelname',
},
{
name: 'territoryname',
},
{
name: 'parentaccountname',
},
{
name: 'preferredequipmentname',
},
{
name: 'preferredservicename',
},
{
name: 'primarycontactname',
},
{
name: 'transactioncurrencyname',
},
]
}
}
\ No newline at end of file
<script lang='tsx'>
import { Component } from 'vue-property-decorator';
import AccountBase from './account-treeview-base.vue';
@Component({
components: {
}
})
export default class Account extends AccountBase {
}
</script>
\ No newline at end of file
/**
* Gradationtreeexpbar 部件模型
*
* @export
* @class GradationtreeexpbarModel
*/
export default class GradationtreeexpbarModel {
/**
* 获取数据项集合
*
* @returns {any[]}
* @memberof GradationtreeexpbarModel
*/
public getDataItems(): any[] {
return [
{
name: 'address1_primarycontactname',
},
{
name: 'openrevenue_date',
},
{
name: 'address2_utcoffset',
},
{
name: 'fax',
},
{
name: 'address1_composite',
},
{
name: 'entityimage',
},
{
name: 'emailaddress1',
},
{
name: 'overriddencreatedon',
},
{
name: 'address1_stateorprovince',
},
{
name: 'openrevenue',
},
{
name: 'address1_upszone',
},
{
name: 'followemail',
},
{
name: 'marketingonly',
},
{
name: 'numberofemployees',
},
{
name: 'telephone1',
},
{
name: 'aging60',
},
{
name: 'sharesoutstanding',
},
{
name: 'address2_freighttermscode',
},
{
name: 'entityimage_timestamp',
},
{
name: 'revenue_base',
},
{
name: 'accountratingcode',
},
{
name: 'donotbulkemail',
},
{
name: 'aging30',
},
{
name: 'donotbulkpostalmail',
},
{
name: 'creditlimit_base',
},
{
name: 'timezoneruleversionnumber',
},
{
name: 'customertypecode',
},
{
name: 'address2_longitude',
},
{
name: 'accountname',
},
{
name: 'participatesinworkflow',
},
{
name: 'preferredcontactmethodcode',
},
{
name: 'preferredappointmentdaycode',
},
{
name: 'marketcap',
},
{
name: 'address2_telephone1',
},
{
name: 'businesstypecode',
},
{
name: 'entityimageid',
},
{
name: 'address2_city',
},
{
name: 'ownershipcode',
},
{
name: 'utcconversiontimezonecode',
},
{
name: 'accountnumber',
},
{
name: 'address1_telephone2',
},
{
name: 'address1_line1',
},
{
name: 'donotphone',
},
{
name: 'address1_telephone3',
},
{
name: 'exchangerate',
},
{
name: 'address2_line2',
},
{
name: 'address2_telephone3',
},
{
name: 'address1_telephone1',
},
{
name: 'address1_fax',
},
{
name: 'address1_freighttermscode',
},
{
name: 'description',
},
{
name: 'merged',
},
{
name: 'address1_shippingmethodcode',
},
{
name: 'address1_name',
},
{
name: 'aging30_base',
},
{
name: 'address2_telephone2',
},
{
name: 'account',
prop: 'accountid',
},
{
name: 'primarytwitterid',
},
{
name: 'tickersymbol',
},
{
name: 'stockexchange',
},
{
name: 'address2_stateorprovince',
},
{
name: 'ftpsiteurl',
},
{
name: 'statuscode',
},
{
name: 'websiteurl',
},
{
name: 'donotpostalmail',
},
{
name: 'address1_city',
},
{
name: 'address2_fax',
},
{
name: 'aging90_base',
},
{
name: 'opendeals_date',
},
{
name: 'traversedpath',
},
{
name: 'shippingmethodcode',
},
{
name: 'address1_line2',
},
{
name: 'openrevenue_base',
},
{
name: 'updatedate',
},
{
name: 'preferredsystemuseridyominame',
},
{
name: 'address2_line3',
},
{
name: 'address1_postalcode',
},
{
name: 'address2_latitude',
},
{
name: 'ibizprivate',
},
{
name: 'territorycode',
},
{
name: 'teamsfollowed',
},
{
name: 'yominame',
},
{
name: 'address1_latitude',
},
{
name: 'telephone3',
},
{
name: 'ownerid',
},
{
name: 'address2_country',
},
{
name: 'masteraccountidyominame',
},
{
name: 'industrycode',
},
{
name: 'lastonholdtime',
},
{
name: 'address2_addressid',
},
{
name: 'onholdtime',
},
{
name: 'accountclassificationcode',
},
{
name: 'address1_country',
},
{
name: 'address1_addresstypecode',
},
{
name: 'statecode',
},
{
name: 'address2_addresstypecode',
},
{
name: 'accountcategorycode',
},
{
name: 'emailaddress2',
},
{
name: 'address2_shippingmethodcode',
},
{
name: 'importsequencenumber',
},
{
name: 'primarysatoriid',
},
{
name: 'customersizecode',
},
{
name: 'opendeals',
},
{
name: 'donotsendmm',
},
{
name: 'processid',
},
{
name: 'paymenttermscode',
},
{
name: 'sic',
},
{
name: 'address2_primarycontactname',
},
{
name: 'address1_utcoffset',
},
{
name: 'owneridyominame',
},
{
name: 'lastusedincampaign',
},
{
name: 'aging60_base',
},
{
name: 'donotfax',
},
{
name: 'updateman',
},
{
name: 'openrevenue_state',
},
{
name: 'opendeals_state',
},
{
name: 'versionnumber',
},
{
name: 'address1_longitude',
},
{
name: 'aging90',
},
{
name: 'entityimage_url',
},
{
name: 'creditlimit',
},
{
name: 'preferredsystemuserid',
},
{
name: 'revenue',
},
{
name: 'address1_county',
},
{
name: 'address1_line3',
},
{
name: 'stageid',
},
{
name: 'donotemail',
},
{
name: 'address2_postalcode',
},
{
name: 'preferredappointmenttimecode',
},
{
name: 'address2_upszone',
},
{
name: 'createdate',
},
{
name: 'address2_county',
},
{
name: 'owneridtype',
},
{
name: 'address2_composite',
},
{
name: 'address2_name',
},
{
name: 'address2_line1',
},
{
name: 'marketcap_base',
},
{
name: 'emailaddress3',
},
{
name: 'telephone2',
},
{
name: 'createman',
},
{
name: 'address1_postofficebox',
},
{
name: 'creditonhold',
},
{
name: 'address1_addressid',
},
{
name: 'address2_postofficebox',
},
{
name: 'slaname',
},
{
name: 'originatingleadid',
},
{
name: 'transactioncurrencyid',
},
{
name: 'defaultpricelevelid',
},
{
name: 'parentaccountid',
},
{
name: 'preferredequipmentid',
},
{
name: 'territoryid',
},
{
name: 'primarycontactid',
},
{
name: 'slaid',
},
{
name: 'preferredserviceid',
},
{
name: 'originatingleadname',
},
{
name: 'defaultpricelevelname',
},
{
name: 'territoryname',
},
{
name: 'parentaccountname',
},
{
name: 'preferredequipmentname',
},
{
name: 'preferredservicename',
},
{
name: 'primarycontactname',
},
{
name: 'transactioncurrencyname',
},
]
}
}
\ No newline at end of file
import { Http } from '@/utils';
import ControlService from '@/widgets/control-service';
/**
* Gradationtreeexpbar 部件服务对象
*
* @export
* @class GradationtreeexpbarService
*/
export default class GradationtreeexpbarService extends ControlService {
}
\ No newline at end of file
<script lang='tsx'>
import { Component } from 'vue-property-decorator';
import GradationtreeexpbarBase from './gradationtreeexpbar-treeexpbar-base.vue';
import view_treeexpbar_tree from '@widgets/account/account-treeview/account-treeview.vue';
@Component({
components: {
view_treeexpbar_tree,
}
})
export default class Gradationtreeexpbar extends GradationtreeexpbarBase {
}
</script>
\ No newline at end of file
......@@ -325,7 +325,7 @@ export default class CentralBase extends Vue {
}
/**
* 客户管理
* 客户层级管理
*
* @param {*} [item={}]
* @memberof Central
......@@ -336,7 +336,7 @@ export default class CentralBase extends Vue {
const deResParameters: any[] = [];
const parameters: any[] = [
{ pathName: 'accounts', parameterName: 'account' },
{ pathName: 'gridview', parameterName: 'gridview' },
{ pathName: 'gradation', parameterName: 'gradation' },
];
const path: string = this.$viewTool.buildUpRoutePath(this.$route, {}, deResParameters, parameters, [], viewparam);
this.$router.push(path);
......
......@@ -265,7 +265,7 @@ export default class CentralModel {
textcls: '',
appfunctag: 'Auto4',
appfuncyype: 'APPVIEW',
viewname: 'account-grid-view',
viewname: 'account-gradation',
resourcetag: '',
}
,
......@@ -948,12 +948,12 @@ export default class CentralModel {
appfunctag: 'Auto4',
appfuncyype: 'APPVIEW',
openmode: '',
codename: 'accountgridview',
codename: 'accountgradation',
deResParameters: [],
routepath: '/central/:central?/accounts/:account?/gridview/:gridview?',
routepath: '/central/:central?/accounts/:account?/gradation/:gradation?',
parameters: [
{ pathName: 'accounts', parameterName: 'account' },
{ pathName: 'gridview', parameterName: 'gridview' },
{ pathName: 'gradation', parameterName: 'gradation' },
],
},
{
......
......@@ -19,6 +19,7 @@ import com.alibaba.fastjson.JSONObject;
public interface AccountMapper extends BaseMapper<Account>{
Page<Account> searchRoot(IPage page, @Param("srf") AccountSearchContext context, @Param("ew") Wrapper<Account> wrapper) ;
Page<Account> searchDefault(IPage page, @Param("srf") AccountSearchContext context, @Param("ew") Wrapper<Account> wrapper) ;
@Override
Account selectById(Serializable id);
......
......@@ -36,6 +36,7 @@ public interface IAccountService extends IService<Account>{
boolean checkKey(Account et) ;
Account get(String key) ;
Account getDraft(Account et) ;
Page<Account> searchRoot(AccountSearchContext context) ;
Page<Account> searchDefault(AccountSearchContext context) ;
List<Account> selectByParentaccountid(String accountid) ;
void removeByParentaccountid(String accountid) ;
......
......@@ -277,6 +277,15 @@ public class AccountServiceImpl extends ServiceImpl<AccountMapper, Account> impl
}
/**
* 查询集合 Root
*/
@Override
public Page<Account> searchRoot(AccountSearchContext context) {
com.baomidou.mybatisplus.extension.plugins.pagination.Page<Account> pages=baseMapper.searchRoot(context.getPages(),context,context.getSelectCond());
return new PageImpl<Account>(pages.getRecords(), context.getPageable(), pages.getTotal());
}
/**
* 查询集合 DEFAULT
*/
......
......@@ -4514,7 +4514,7 @@
<!--输出实体[ACCOUNT]数据结构 -->
<changeSet author="a_LAB01_e85d8801c" id="tab-account-311-54">
<changeSet author="a_LAB01_e85d8801c" id="tab-account-314-54">
<createTable tableName="ACCOUNT">
<column name="ADDRESS1_PRIMARYCONTACTNAME" remarks="" type="VARCHAR(100)">
</column>
......@@ -8085,7 +8085,7 @@
<!--输出实体[COMPETITOR]数据结构 -->
<changeSet author="a_LAB01_e85d8801c" id="tab-competitor-33-89">
<changeSet author="a_LAB01_e85d8801c" id="tab-competitor-34-89">
<createTable tableName="COMPETITOR">
<column name="ENTITYIMAGE" remarks="" type="VARCHAR(100)">
</column>
......@@ -11135,31 +11135,31 @@
<addForeignKeyConstraint baseColumnNames="METRICID" baseTableName="GOAL" constraintName="DER1N_GOAL__METRIC__METRICID" deferrable="false" initiallyDeferred="false" onDelete="RESTRICT" onUpdate="RESTRICT" referencedColumnNames="METRICID" referencedTableName="METRIC" validate="true"/>
</changeSet>
<!--输出实体[ACCOUNT]外键关系 -->
<changeSet author="a_LAB01_e85d8801c" id="fk-account-311-255">
<changeSet author="a_LAB01_e85d8801c" id="fk-account-314-255">
<addForeignKeyConstraint baseColumnNames="PARENTACCOUNTID" baseTableName="ACCOUNT" constraintName="DER1N_ACCOUNT__ACCOUNT__PARENT" deferrable="false" initiallyDeferred="false" onDelete="RESTRICT" onUpdate="RESTRICT" referencedColumnNames="ACCOUNTID" referencedTableName="ACCOUNT" validate="true"/>
</changeSet>
<changeSet author="a_LAB01_e85d8801c" id="fk-account-311-256">
<changeSet author="a_LAB01_e85d8801c" id="fk-account-314-256">
<addForeignKeyConstraint baseColumnNames="PRIMARYCONTACTID" baseTableName="ACCOUNT" constraintName="DER1N_ACCOUNT__CONTACT__PRIMAR" deferrable="false" initiallyDeferred="false" onDelete="RESTRICT" onUpdate="RESTRICT" referencedColumnNames="CONTACTID" referencedTableName="CONTACT" validate="true"/>
</changeSet>
<changeSet author="a_LAB01_e85d8801c" id="fk-account-311-257">
<changeSet author="a_LAB01_e85d8801c" id="fk-account-314-257">
<addForeignKeyConstraint baseColumnNames="PREFERREDEQUIPMENTID" baseTableName="ACCOUNT" constraintName="DER1N_ACCOUNT__EQUIPMENT__PREF" deferrable="false" initiallyDeferred="false" onDelete="RESTRICT" onUpdate="RESTRICT" referencedColumnNames="EQUIPMENTID" referencedTableName="EQUIPMENT" validate="true"/>
</changeSet>
<changeSet author="a_LAB01_e85d8801c" id="fk-account-311-258">
<changeSet author="a_LAB01_e85d8801c" id="fk-account-314-258">
<addForeignKeyConstraint baseColumnNames="ORIGINATINGLEADID" baseTableName="ACCOUNT" constraintName="DER1N_ACCOUNT__LEAD__ORIGINATI" deferrable="false" initiallyDeferred="false" onDelete="RESTRICT" onUpdate="RESTRICT" referencedColumnNames="LEADID" referencedTableName="LEAD" validate="true"/>
</changeSet>
<changeSet author="a_LAB01_e85d8801c" id="fk-account-311-259">
<changeSet author="a_LAB01_e85d8801c" id="fk-account-314-259">
<addForeignKeyConstraint baseColumnNames="DEFAULTPRICELEVELID" baseTableName="ACCOUNT" constraintName="DER1N_ACCOUNT__PRICELEVEL__DEF" deferrable="false" initiallyDeferred="false" onDelete="RESTRICT" onUpdate="RESTRICT" referencedColumnNames="PRICELEVELID" referencedTableName="PRICELEVEL" validate="true"/>
</changeSet>
<changeSet author="a_LAB01_e85d8801c" id="fk-account-311-260">
<changeSet author="a_LAB01_e85d8801c" id="fk-account-314-260">
<addForeignKeyConstraint baseColumnNames="PREFERREDSERVICEID" baseTableName="ACCOUNT" constraintName="DER1N_ACCOUNT__SERVICE__PREFER" deferrable="false" initiallyDeferred="false" onDelete="RESTRICT" onUpdate="RESTRICT" referencedColumnNames="SERVICEID" referencedTableName="SERVICE" validate="true"/>
</changeSet>
<changeSet author="a_LAB01_e85d8801c" id="fk-account-311-261">
<changeSet author="a_LAB01_e85d8801c" id="fk-account-314-261">
<addForeignKeyConstraint baseColumnNames="SLAID" baseTableName="ACCOUNT" constraintName="DER1N_ACCOUNT__SLA__SLAID" deferrable="false" initiallyDeferred="false" onDelete="RESTRICT" onUpdate="RESTRICT" referencedColumnNames="SLAID" referencedTableName="SLA" validate="true"/>
</changeSet>
<changeSet author="a_LAB01_e85d8801c" id="fk-account-311-262">
<changeSet author="a_LAB01_e85d8801c" id="fk-account-314-262">
<addForeignKeyConstraint baseColumnNames="TERRITORYID" baseTableName="ACCOUNT" constraintName="DER1N_ACCOUNT__TERRITORY__TERR" deferrable="false" initiallyDeferred="false" onDelete="RESTRICT" onUpdate="RESTRICT" referencedColumnNames="TERRITORYID" referencedTableName="TERRITORY" validate="true"/>
</changeSet>
<changeSet author="a_LAB01_e85d8801c" id="fk-account-311-263">
<changeSet author="a_LAB01_e85d8801c" id="fk-account-314-263">
<addForeignKeyConstraint baseColumnNames="TRANSACTIONCURRENCYID" baseTableName="ACCOUNT" constraintName="DER1N_ACCOUNT__TRANSACTIONCURR" deferrable="false" initiallyDeferred="false" onDelete="RESTRICT" onUpdate="RESTRICT" referencedColumnNames="TRANSACTIONCURRENCYID" referencedTableName="TRANSACTIONCURRENCY" validate="true"/>
</changeSet>
<!--输出实体[KNOWLEDGEARTICLEVIEWS]外键关系 -->
......@@ -11419,7 +11419,7 @@
<!--输出实体[CAMPAIGNLIST]外键关系 -->
<!--输出实体[LISTCONTACT]外键关系 -->
<!--输出实体[COMPETITOR]外键关系 -->
<changeSet author="a_LAB01_e85d8801c" id="fk-competitor-33-346">
<changeSet author="a_LAB01_e85d8801c" id="fk-competitor-34-346">
<addForeignKeyConstraint baseColumnNames="TRANSACTIONCURRENCYID" baseTableName="COMPETITOR" constraintName="DER1N_COMPETITOR__TRANSACTIONC" deferrable="false" initiallyDeferred="false" onDelete="RESTRICT" onUpdate="RESTRICT" referencedColumnNames="TRANSACTIONCURRENCYID" referencedTableName="TRANSACTIONCURRENCY" validate="true"/>
</changeSet>
<!--输出实体[PRODUCT]外键关系 -->
......
......@@ -263,7 +263,7 @@
"dename":"Account",
"delogicname":"客户",
"sysmoudle":{"id":"BASE","name":"Base"},
"dedataset":[{"id":"Default" , "name":"DEFAULT"}],
"dedataset":[{"id":"Root" , "name":"Root"},{"id":"Default" , "name":"DEFAULT"}],
"deaction":[{"id":"Create" , "name":"Create" , "type":"BUILTIN" },{"id":"Update" , "name":"Update" , "type":"BUILTIN" },{"id":"Remove" , "name":"Remove" , "type":"BUILTIN" },{"id":"Save" , "name":"Save" , "type":"BUILTIN" },{"id":"CheckKey" , "name":"CheckKey" , "type":"BUILTIN" },{"id":"Get" , "name":"Get" , "type":"BUILTIN" },{"id":"GetDraft" , "name":"GetDraft" , "type":"BUILTIN" }],
"datascope":[{"id":"all","name":"全部数据"}, {"id":"createman","name":"创建人"}]
}
......
......@@ -137,6 +137,27 @@ public class AccountResource {
return ResponseEntity.status(HttpStatus.OK).body(accountMapping.toDto(accountService.getDraft(new Account())));
}
@PreAuthorize("hasAnyAuthority('ROLE_SUPERADMIN','iBizBusinessCentral-Account-Root-all')")
@ApiOperation(value = "获取Root", tags = {"客户" } ,notes = "获取Root")
@RequestMapping(method= RequestMethod.GET , value="/accounts/fetchroot")
public ResponseEntity<List<AccountDTO>> fetchRoot(AccountSearchContext context) {
Page<Account> domains = accountService.searchRoot(context) ;
List<AccountDTO> list = accountMapping.toDto(domains.getContent());
return ResponseEntity.status(HttpStatus.OK)
.header("x-page", String.valueOf(context.getPageable().getPageNumber()))
.header("x-per-page", String.valueOf(context.getPageable().getPageSize()))
.header("x-total", String.valueOf(domains.getTotalElements()))
.body(list);
}
@PreAuthorize("hasAnyAuthority('ROLE_SUPERADMIN','iBizBusinessCentral-Account-Root-all')")
@ApiOperation(value = "查询Root", tags = {"客户" } ,notes = "查询Root")
@RequestMapping(method= RequestMethod.POST , value="/accounts/searchroot")
public ResponseEntity<Page<AccountDTO>> searchRoot(@RequestBody AccountSearchContext context) {
Page<Account> domains = accountService.searchRoot(context) ;
return ResponseEntity.status(HttpStatus.OK)
.body(new PageImpl(accountMapping.toDto(domains.getContent()), context.getPageable(), domains.getTotalElements()));
}
@PreAuthorize("hasAnyAuthority('ROLE_SUPERADMIN','iBizBusinessCentral-Account-Default-all')")
@ApiOperation(value = "获取DEFAULT", tags = {"客户" } ,notes = "获取DEFAULT")
@RequestMapping(method= RequestMethod.GET , value="/accounts/fetchdefault")
......
Markdown 格式
0% or
您添加了 0 到此讨论。请谨慎行事。
先完成此消息的编辑!
想要评论请 注册