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

tony001 发布系统代码 [后台服务,演示应用]

上级 48bea6f6
...@@ -560,23 +560,23 @@ export default class IBIZBOOKOptionView_layoutBase extends Vue { ...@@ -560,23 +560,23 @@ export default class IBIZBOOKOptionView_layoutBase extends Vue {
* @param {*} [srfParentDeName] 父实体名称 * @param {*} [srfParentDeName] 父实体名称
*/ */
public panel_Layoutpanel_button_calluilogic1_click(args: any[], contextJO?:any, params?: any, $event?: any, xData?: any, actionContext?:any, srfParentDeName?:string) { public panel_Layoutpanel_button_calluilogic1_click(args: any[], contextJO?:any, params?: any, $event?: any, xData?: any, actionContext?:any, srfParentDeName?:string) {
if (actionContext.viewType === 'APPLOGINVIEW') { if (this.viewType === 'APPLOGINVIEW') {
const length = Object.keys(actionContext.layoutData).length; const length = Object.keys(this.layoutData).length;
for (let i = length - 1; i >= 0; i--) { for (let i = length - 1; i >= 0; i--) {
const name = Object.keys(actionContext.layoutData)[i]; const name = Object.keys(this.layoutData)[i];
if (actionContext.layoutData.hasOwnProperty(name) && !Object.is(actionContext.layoutModelDetails[name].itemType, 'CONTAINER')) { if (this.layoutData.hasOwnProperty(name) && !Object.is(this.layoutModelDetails[name].itemType, 'CONTAINER')) {
actionContext.handleValueChange({ name, value: null }); this.handleValueChange({ name, value: null });
} }
} }
actionContext.$nextTick(() => { this.$nextTick(() => {
actionContext.$forceUpdate(); this.$forceUpdate();
}) })
} else { } else {
const parentRef = actionContext.$parent; const parentRef: any = this.$parent;
if (parentRef.closeView && (parentRef.closeView instanceof Function)) { if (parentRef.closeView && (parentRef.closeView instanceof Function)) {
parentRef.closeView(args); parentRef.closeView(args);
} else if (actionContext.closeView && (actionContext.closeView instanceof Function)) { } else if (this.closeView && (this.closeView instanceof Function)) {
actionContext.closeView(args); this.closeView(args);
} }
} }
} }
......
...@@ -484,23 +484,23 @@ export default class IBIZCustomerMPickupView_layoutBase extends Vue { ...@@ -484,23 +484,23 @@ export default class IBIZCustomerMPickupView_layoutBase extends Vue {
* @param {*} [srfParentDeName] 父实体名称 * @param {*} [srfParentDeName] 父实体名称
*/ */
public panel_Layoutpanel_button_calluilogic2_click(args: any[], contextJO?:any, params?: any, $event?: any, xData?: any, actionContext?:any, srfParentDeName?:string) { public panel_Layoutpanel_button_calluilogic2_click(args: any[], contextJO?:any, params?: any, $event?: any, xData?: any, actionContext?:any, srfParentDeName?:string) {
if (actionContext.viewType === 'APPLOGINVIEW') { if (this.viewType === 'APPLOGINVIEW') {
const length = Object.keys(actionContext.layoutData).length; const length = Object.keys(this.layoutData).length;
for (let i = length - 1; i >= 0; i--) { for (let i = length - 1; i >= 0; i--) {
const name = Object.keys(actionContext.layoutData)[i]; const name = Object.keys(this.layoutData)[i];
if (actionContext.layoutData.hasOwnProperty(name) && !Object.is(actionContext.layoutModelDetails[name].itemType, 'CONTAINER')) { if (this.layoutData.hasOwnProperty(name) && !Object.is(this.layoutModelDetails[name].itemType, 'CONTAINER')) {
actionContext.handleValueChange({ name, value: null }); this.handleValueChange({ name, value: null });
} }
} }
actionContext.$nextTick(() => { this.$nextTick(() => {
actionContext.$forceUpdate(); this.$forceUpdate();
}) })
} else { } else {
const parentRef = actionContext.$parent; const parentRef: any = this.$parent;
if (parentRef.closeView && (parentRef.closeView instanceof Function)) { if (parentRef.closeView && (parentRef.closeView instanceof Function)) {
parentRef.closeView(args); parentRef.closeView(args);
} else if (actionContext.closeView && (actionContext.closeView instanceof Function)) { } else if (this.closeView && (this.closeView instanceof Function)) {
actionContext.closeView(args); this.closeView(args);
} }
} }
} }
......
...@@ -483,23 +483,23 @@ export default class IBIZCustomerPickupView_layoutBase extends Vue { ...@@ -483,23 +483,23 @@ export default class IBIZCustomerPickupView_layoutBase extends Vue {
* @param {*} [srfParentDeName] 父实体名称 * @param {*} [srfParentDeName] 父实体名称
*/ */
public panel_Layoutpanel_button_calluilogic2_click(args: any[], contextJO?:any, params?: any, $event?: any, xData?: any, actionContext?:any, srfParentDeName?:string) { public panel_Layoutpanel_button_calluilogic2_click(args: any[], contextJO?:any, params?: any, $event?: any, xData?: any, actionContext?:any, srfParentDeName?:string) {
if (actionContext.viewType === 'APPLOGINVIEW') { if (this.viewType === 'APPLOGINVIEW') {
const length = Object.keys(actionContext.layoutData).length; const length = Object.keys(this.layoutData).length;
for (let i = length - 1; i >= 0; i--) { for (let i = length - 1; i >= 0; i--) {
const name = Object.keys(actionContext.layoutData)[i]; const name = Object.keys(this.layoutData)[i];
if (actionContext.layoutData.hasOwnProperty(name) && !Object.is(actionContext.layoutModelDetails[name].itemType, 'CONTAINER')) { if (this.layoutData.hasOwnProperty(name) && !Object.is(this.layoutModelDetails[name].itemType, 'CONTAINER')) {
actionContext.handleValueChange({ name, value: null }); this.handleValueChange({ name, value: null });
} }
} }
actionContext.$nextTick(() => { this.$nextTick(() => {
actionContext.$forceUpdate(); this.$forceUpdate();
}) })
} else { } else {
const parentRef = actionContext.$parent; const parentRef: any = this.$parent;
if (parentRef.closeView && (parentRef.closeView instanceof Function)) { if (parentRef.closeView && (parentRef.closeView instanceof Function)) {
parentRef.closeView(args); parentRef.closeView(args);
} else if (actionContext.closeView && (actionContext.closeView instanceof Function)) { } else if (this.closeView && (this.closeView instanceof Function)) {
actionContext.closeView(args); this.closeView(args);
} }
} }
} }
......
...@@ -484,23 +484,23 @@ export default class IBIZCustomerUsr2MPickupView_layoutBase extends Vue { ...@@ -484,23 +484,23 @@ export default class IBIZCustomerUsr2MPickupView_layoutBase extends Vue {
* @param {*} [srfParentDeName] 父实体名称 * @param {*} [srfParentDeName] 父实体名称
*/ */
public panel_Layoutpanel_button_calluilogic2_click(args: any[], contextJO?:any, params?: any, $event?: any, xData?: any, actionContext?:any, srfParentDeName?:string) { public panel_Layoutpanel_button_calluilogic2_click(args: any[], contextJO?:any, params?: any, $event?: any, xData?: any, actionContext?:any, srfParentDeName?:string) {
if (actionContext.viewType === 'APPLOGINVIEW') { if (this.viewType === 'APPLOGINVIEW') {
const length = Object.keys(actionContext.layoutData).length; const length = Object.keys(this.layoutData).length;
for (let i = length - 1; i >= 0; i--) { for (let i = length - 1; i >= 0; i--) {
const name = Object.keys(actionContext.layoutData)[i]; const name = Object.keys(this.layoutData)[i];
if (actionContext.layoutData.hasOwnProperty(name) && !Object.is(actionContext.layoutModelDetails[name].itemType, 'CONTAINER')) { if (this.layoutData.hasOwnProperty(name) && !Object.is(this.layoutModelDetails[name].itemType, 'CONTAINER')) {
actionContext.handleValueChange({ name, value: null }); this.handleValueChange({ name, value: null });
} }
} }
actionContext.$nextTick(() => { this.$nextTick(() => {
actionContext.$forceUpdate(); this.$forceUpdate();
}) })
} else { } else {
const parentRef = actionContext.$parent; const parentRef: any = this.$parent;
if (parentRef.closeView && (parentRef.closeView instanceof Function)) { if (parentRef.closeView && (parentRef.closeView instanceof Function)) {
parentRef.closeView(args); parentRef.closeView(args);
} else if (actionContext.closeView && (actionContext.closeView instanceof Function)) { } else if (this.closeView && (this.closeView instanceof Function)) {
actionContext.closeView(args); this.closeView(args);
} }
} }
} }
......
...@@ -531,23 +531,23 @@ export default class IBIZCustomerUsr2PickupView_layoutBase extends Vue { ...@@ -531,23 +531,23 @@ export default class IBIZCustomerUsr2PickupView_layoutBase extends Vue {
* @param {*} [srfParentDeName] 父实体名称 * @param {*} [srfParentDeName] 父实体名称
*/ */
public panel_Layoutpanel_button_calluilogic2_click(args: any[], contextJO?:any, params?: any, $event?: any, xData?: any, actionContext?:any, srfParentDeName?:string) { public panel_Layoutpanel_button_calluilogic2_click(args: any[], contextJO?:any, params?: any, $event?: any, xData?: any, actionContext?:any, srfParentDeName?:string) {
if (actionContext.viewType === 'APPLOGINVIEW') { if (this.viewType === 'APPLOGINVIEW') {
const length = Object.keys(actionContext.layoutData).length; const length = Object.keys(this.layoutData).length;
for (let i = length - 1; i >= 0; i--) { for (let i = length - 1; i >= 0; i--) {
const name = Object.keys(actionContext.layoutData)[i]; const name = Object.keys(this.layoutData)[i];
if (actionContext.layoutData.hasOwnProperty(name) && !Object.is(actionContext.layoutModelDetails[name].itemType, 'CONTAINER')) { if (this.layoutData.hasOwnProperty(name) && !Object.is(this.layoutModelDetails[name].itemType, 'CONTAINER')) {
actionContext.handleValueChange({ name, value: null }); this.handleValueChange({ name, value: null });
} }
} }
actionContext.$nextTick(() => { this.$nextTick(() => {
actionContext.$forceUpdate(); this.$forceUpdate();
}) })
} else { } else {
const parentRef = actionContext.$parent; const parentRef: any = this.$parent;
if (parentRef.closeView && (parentRef.closeView instanceof Function)) { if (parentRef.closeView && (parentRef.closeView instanceof Function)) {
parentRef.closeView(args); parentRef.closeView(args);
} else if (actionContext.closeView && (actionContext.closeView instanceof Function)) { } else if (this.closeView && (this.closeView instanceof Function)) {
actionContext.closeView(args); this.closeView(args);
} }
} }
} }
......
...@@ -466,60 +466,62 @@ export default class AppLoginViewBase extends Vue { ...@@ -466,60 +466,62 @@ export default class AppLoginViewBase extends Vue {
* @param {*} [srfParentDeName] 父实体名称 * @param {*} [srfParentDeName] 父实体名称
*/ */
public panel_Usr1102196415_auth_loginbutton1_click(args: any[], contextJO?:any, params?: any, $event?: any, xData?: any, actionContext?:any, srfParentDeName?:string) { public panel_Usr1102196415_auth_loginbutton1_click(args: any[], contextJO?:any, params?: any, $event?: any, xData?: any, actionContext?:any, srfParentDeName?:string) {
const layoutData = args.length > 0 ? args[0] : {}; if (this.viewType === 'APPLOGINVIEW') {
const layoutModelDetails: any = actionContext.layoutModelDetails || {}; const layoutData = args.length > 0 ? args[0] : {};
let userNameKey: string = Object.keys(layoutModelDetails).find((key: string) => Object.is(layoutModelDetails[key].predefinedType, 'AUTH_USERID')) || ''; const layoutModelDetails: any = this.layoutModelDetails || {};
let passwordKey: string = Object.keys(layoutModelDetails).find((key: string) => Object.is(layoutModelDetails[key].predefinedType, 'AUTH_PASSWORD')) || ''; let userNameKey: string = Object.keys(layoutModelDetails).find((key: string) => Object.is(layoutModelDetails[key].predefinedType, 'AUTH_USERID')) || '';
let messageKey: string = Object.keys(layoutModelDetails).find((key: string) => Object.is(layoutModelDetails[key].predefinedType, 'AUTH_LOGINMSG')) || ''; let passwordKey: string = Object.keys(layoutModelDetails).find((key: string) => Object.is(layoutModelDetails[key].predefinedType, 'AUTH_PASSWORD')) || '';
if (!userNameKey || !passwordKey) { let messageKey: string = Object.keys(layoutModelDetails).find((key: string) => Object.is(layoutModelDetails[key].predefinedType, 'AUTH_LOGINMSG')) || '';
actionContext.$message({ message: '用户名或密码未配置!',type: 'warning'}); if (!userNameKey || !passwordKey) {
if (messageKey) {
actionContext.handleValueChange({ name: messageKey, value: '用户名或密码未配置!' });
}
}
const loginname: any = layoutData[userNameKey];
const password: any = layoutData[passwordKey];
if (!loginname || !password) {
actionContext.$message({ message: '请输入用户名与密码',type: 'warning'});
if (messageKey) {
actionContext.handleValueChange({ name: messageKey, value: '请输入用户名与密码' });
}
}
// 清除cookie
let leftTime = new Date();
leftTime.setTime(leftTime.getSeconds() - 1000);
document.cookie = "ibzuaa-token=;expires=" + leftTime.toUTCString();
const data = { loginname, password };
const post: Promise<any> = actionContext.$http.post('/v7/login', data, true);
post.then((response: any) => {
if (response && response.status === 200) {
const data = response.data;
if (data && data.token) {
localStorage.setItem('token', data.token);
Util.setCookie('ibzuaa-token',data.token,0);
}
if(data && data.user){
localStorage.setItem('user', JSON.stringify(data.user));
}
// 设置cookie,保存账号密码7天
Util.setCookie("loginname",loginname, 7);
// 跳转首页
const url: any = actionContext.$route.query.redirect ? actionContext.$route.query.redirect : '*';
actionContext.$router.push({path: url});
}
}).catch((error: any) => {
// 登录提示
const data = error.data;
if (data && data.message) {
if (messageKey) { if (messageKey) {
actionContext.handleValueChange({ name: messageKey, value: data.message }); this.handleValueChange({ name: messageKey, value: '用户名或密码未配置!' });
} else {
this.$message({ message: '用户名或密码未配置!',type: 'warning'});
} }
} else { }
const loginname: any = layoutData[userNameKey];
const password: any = layoutData[passwordKey];
if (!loginname || !password) {
if (messageKey) { if (messageKey) {
actionContext.handleValueChange({ name: messageKey, value: actionContext.$t('components.login.loginfailed') }); this.handleValueChange({ name: messageKey, value: '请输入用户名与密码' });
} else {
this.$message({ message: '请输入用户名与密码',type: 'warning'});
} }
} }
}); // 清除cookie
let leftTime = new Date();
leftTime.setTime(leftTime.getSeconds() - 1000);
document.cookie = "ibzuaa-token=;expires=" + leftTime.toUTCString();
const data = { loginname, password };
const post: Promise<any> = this.$http.post('/v7/login', data, true);
post.then((response: any) => {
if (response && response.status === 200) {
const data = response.data;
if (data && data.token) {
localStorage.setItem('token', data.token);
Util.setCookie('ibzuaa-token',data.token,0);
}
if(data && data.user){
localStorage.setItem('user', JSON.stringify(data.user));
}
// 设置cookie,保存账号密码7天
Util.setCookie("loginname",loginname, 7);
// 跳转首页
const url: any = this.$route.query.redirect ? this.$route.query.redirect : '*';
this.$router.push({path: url});
}
}).catch((error: any) => {
// 登录提示
const data = error.data;
if (data) {
if (messageKey) {
this.handleValueChange({ name: messageKey, value: data.message || this.$t('components.login.loginfailed') });
}
}
});
} else {
this.$router.push({ path: "/login", query: { redirect: window.location.hash.replace("#", '') } });
}
} }
/** /**
* 重置 * 重置
...@@ -533,23 +535,23 @@ export default class AppLoginViewBase extends Vue { ...@@ -533,23 +535,23 @@ export default class AppLoginViewBase extends Vue {
* @param {*} [srfParentDeName] 父实体名称 * @param {*} [srfParentDeName] 父实体名称
*/ */
public panel_Usr1102196415_auth_resetinput1_click(args: any[], contextJO?:any, params?: any, $event?: any, xData?: any, actionContext?:any, srfParentDeName?:string) { public panel_Usr1102196415_auth_resetinput1_click(args: any[], contextJO?:any, params?: any, $event?: any, xData?: any, actionContext?:any, srfParentDeName?:string) {
if (actionContext.viewType === 'APPLOGINVIEW') { if (this.viewType === 'APPLOGINVIEW') {
const length = Object.keys(actionContext.layoutData).length; const length = Object.keys(this.layoutData).length;
for (let i = length - 1; i >= 0; i--) { for (let i = length - 1; i >= 0; i--) {
const name = Object.keys(actionContext.layoutData)[i]; const name = Object.keys(this.layoutData)[i];
if (actionContext.layoutData.hasOwnProperty(name) && !Object.is(actionContext.layoutModelDetails[name].itemType, 'CONTAINER')) { if (this.layoutData.hasOwnProperty(name) && !Object.is(this.layoutModelDetails[name].itemType, 'CONTAINER')) {
actionContext.handleValueChange({ name, value: null }); this.handleValueChange({ name, value: null });
} }
} }
actionContext.$nextTick(() => { this.$nextTick(() => {
actionContext.$forceUpdate(); this.$forceUpdate();
}) })
} else { } else {
const parentRef = actionContext.$parent; const parentRef: any = this.$parent;
if (parentRef.closeView && (parentRef.closeView instanceof Function)) { if (parentRef.closeView && (parentRef.closeView instanceof Function)) {
parentRef.closeView(args); parentRef.closeView(args);
} else if (actionContext.closeView && (actionContext.closeView instanceof Function)) { } else if (this.closeView && (this.closeView instanceof Function)) {
actionContext.closeView(args); this.closeView(args);
} }
} }
} }
...@@ -565,13 +567,13 @@ export default class AppLoginViewBase extends Vue { ...@@ -565,13 +567,13 @@ export default class AppLoginViewBase extends Vue {
* @param {*} [srfParentDeName] 父实体名称 * @param {*} [srfParentDeName] 父实体名称
*/ */
public panel_Usr1102196415_auth_logout1_click(args: any[], contextJO?:any, params?: any, $event?: any, xData?: any, actionContext?:any, srfParentDeName?:string) { public panel_Usr1102196415_auth_logout1_click(args: any[], contextJO?:any, params?: any, $event?: any, xData?: any, actionContext?:any, srfParentDeName?:string) {
actionContext.$Modal.confirm({ this.$Modal.confirm({
title: '提示', title: '提示',
content: '确认要退出登录?', content: '确认要退出登录?',
okText: '确认', okText: '确认',
cancelText: '取消', cancelText: '取消',
onOk: () => { onOk: () => {
actionContext.$http this.$http
.get("/v7/logout") .get("/v7/logout")
.then((response: any) => { .then((response: any) => {
if (response && response.status === 200) { if (response && response.status === 200) {
...@@ -580,7 +582,7 @@ export default class AppLoginViewBase extends Vue { ...@@ -580,7 +582,7 @@ export default class AppLoginViewBase extends Vue {
let leftTime = new Date(); let leftTime = new Date();
leftTime.setTime(leftTime.getSeconds() - 1); leftTime.setTime(leftTime.getSeconds() - 1);
document.cookie = "ibzuaa-token=;expires=" + leftTime.toUTCString(); document.cookie = "ibzuaa-token=;expires=" + leftTime.toUTCString();
actionContext.$router.push({ name: "login" }); this.$router.push({ path: "/login", query: { redirect: window.location.hash.replace("#", '') } });
} }
}) })
.catch((error: any) => { .catch((error: any) => {
......
...@@ -628,7 +628,7 @@ export default class DefaultBase extends Vue implements ControlInterface { ...@@ -628,7 +628,7 @@ export default class DefaultBase extends Vue implements ControlInterface {
*/ */
public load(opt: any = {}): void { public load(opt: any = {}): void {
if(!this.loadAction){ if(!this.loadAction){
this.$Notice.error({ title: (this.$t('app.commonWords.wrong') as string), desc: 'IBIZAPPEDITORListView' + (this.$t('app.searchForm.notConfig.loadAction') as string) }); this.$Notice.error({ title: (this.$t('app.commonWords.wrong') as string), desc: 'IBIZAPPEDITORGridView' + (this.$t('app.searchForm.notConfig.loadAction') as string) });
return; return;
} }
const arg: any = { ...opt }; const arg: any = { ...opt };
...@@ -664,7 +664,7 @@ export default class DefaultBase extends Vue implements ControlInterface { ...@@ -664,7 +664,7 @@ export default class DefaultBase extends Vue implements ControlInterface {
*/ */
public loadDraft(opt: any = {},mode?:string): void { public loadDraft(opt: any = {},mode?:string): void {
if(!this.loaddraftAction){ if(!this.loaddraftAction){
this.$Notice.error({ title: (this.$t('app.commonWords.wrong') as string), desc: 'IBIZAPPEDITORListView' + (this.$t('app.searchForm.notConfig.loaddraftAction') as string) }); this.$Notice.error({ title: (this.$t('app.commonWords.wrong') as string), desc: 'IBIZAPPEDITORGridView' + (this.$t('app.searchForm.notConfig.loaddraftAction') as string) });
return; return;
} }
const arg: any = { ...opt } ; const arg: any = { ...opt } ;
......
...@@ -202,9 +202,6 @@ export default class DefaultBase extends Vue implements ControlInterface { ...@@ -202,9 +202,6 @@ export default class DefaultBase extends Vue implements ControlInterface {
const data = args && args.data ? args.data : this.getData() || {}; const data = args && args.data ? args.data : this.getData() || {};
const event = args && args.event ? args.event : {}; const event = args && args.event ? args.event : {};
let result: boolean = true; let result: boolean = true;
if ('search;load;save'.indexOf(eventName) !== -1) {
result = await this.execute_engine_searchform_ctrl_logic(data, event);
}
if (!result) { if (!result) {
return false; return false;
} }
...@@ -212,17 +209,6 @@ export default class DefaultBase extends Vue implements ControlInterface { ...@@ -212,17 +209,6 @@ export default class DefaultBase extends Vue implements ControlInterface {
return true; return true;
} }
/**
* 部件逻辑 -- engine_searchform
*
* @param {string} eventName 部件事件名称
* @param {any[]} data 数据
* @param {*} event 源事件对象
* @memberof DefaultBase
*/
public async execute_engine_searchform_ctrl_logic(data: any[], event?: any): Promise<boolean> {
return true;
}
...@@ -701,7 +687,7 @@ export default class DefaultBase extends Vue implements ControlInterface { ...@@ -701,7 +687,7 @@ export default class DefaultBase extends Vue implements ControlInterface {
*/ */
public load(opt: any = {}): void { public load(opt: any = {}): void {
if(!this.loadAction){ if(!this.loadAction){
this.$Notice.error({ title: (this.$t('app.commonWords.wrong') as string), desc: 'IBIZBOOKUsr9GridView' + (this.$t('app.searchForm.notConfig.loadAction') as string) }); this.$Notice.error({ title: (this.$t('app.commonWords.wrong') as string), desc: 'IBIZBOOKCustomView_layout' + (this.$t('app.searchForm.notConfig.loadAction') as string) });
return; return;
} }
const arg: any = { ...opt }; const arg: any = { ...opt };
...@@ -737,7 +723,7 @@ export default class DefaultBase extends Vue implements ControlInterface { ...@@ -737,7 +723,7 @@ export default class DefaultBase extends Vue implements ControlInterface {
*/ */
public loadDraft(opt: any = {},mode?:string): void { public loadDraft(opt: any = {},mode?:string): void {
if(!this.loaddraftAction){ if(!this.loaddraftAction){
this.$Notice.error({ title: (this.$t('app.commonWords.wrong') as string), desc: 'IBIZBOOKUsr9GridView' + (this.$t('app.searchForm.notConfig.loaddraftAction') as string) }); this.$Notice.error({ title: (this.$t('app.commonWords.wrong') as string), desc: 'IBIZBOOKCustomView_layout' + (this.$t('app.searchForm.notConfig.loaddraftAction') as string) });
return; return;
} }
const arg: any = { ...opt } ; const arg: any = { ...opt } ;
......
...@@ -1352,7 +1352,7 @@ export default class GuideBorrowFormBase extends Vue implements ControlInterface ...@@ -1352,7 +1352,7 @@ export default class GuideBorrowFormBase extends Vue implements ControlInterface
*/ */
public load(opt: any = {}): void { public load(opt: any = {}): void {
if(!this.loadAction){ if(!this.loadAction){
this.$Notice.error({ title: (this.$t('app.commonWords.wrong') as string), desc: 'IBIZBOOKWizardView' + (this.$t('app.formpage.notconfig.loadaction') as string) }); this.$Notice.error({ title: (this.$t('app.commonWords.wrong') as string), desc: 'IBIZBOOKWizardView_layout' + (this.$t('app.formpage.notconfig.loadaction') as string) });
return; return;
} }
const arg: any = { ...opt }; const arg: any = { ...opt };
...@@ -1387,7 +1387,7 @@ export default class GuideBorrowFormBase extends Vue implements ControlInterface ...@@ -1387,7 +1387,7 @@ export default class GuideBorrowFormBase extends Vue implements ControlInterface
*/ */
public loadDraft(opt: any = {}): void { public loadDraft(opt: any = {}): void {
if(!this.loaddraftAction){ if(!this.loaddraftAction){
this.$Notice.error({ title: (this.$t('app.commonWords.wrong') as string), desc: 'IBIZBOOKWizardView' + (this.$t('app.formpage.notconfig.loaddraftaction') as string) }); this.$Notice.error({ title: (this.$t('app.commonWords.wrong') as string), desc: 'IBIZBOOKWizardView_layout' + (this.$t('app.formpage.notconfig.loaddraftaction') as string) });
return; return;
} }
const arg: any = { ...opt } ; const arg: any = { ...opt } ;
...@@ -1448,7 +1448,7 @@ export default class GuideBorrowFormBase extends Vue implements ControlInterface ...@@ -1448,7 +1448,7 @@ export default class GuideBorrowFormBase extends Vue implements ControlInterface
const action: any = Object.is(data.srfuf, '1') ? this.updateAction : this.createAction; const action: any = Object.is(data.srfuf, '1') ? this.updateAction : this.createAction;
if(!action){ if(!action){
let actionName:any = Object.is(data.srfuf, '1')?"updateAction":"createAction"; let actionName:any = Object.is(data.srfuf, '1')?"updateAction":"createAction";
this.$Notice.error({ title: (this.$t('app.commonWords.wrong') as string), desc: 'IBIZBOOKWizardView' + (this.$t('app.formpage.notconfig.actionname') as string) }); this.$Notice.error({ title: (this.$t('app.commonWords.wrong') as string), desc: 'IBIZBOOKWizardView_layout' + (this.$t('app.formpage.notconfig.actionname') as string) });
return; return;
} }
Object.assign(arg,{viewparams:this.viewparams}); Object.assign(arg,{viewparams:this.viewparams});
...@@ -1556,7 +1556,7 @@ export default class GuideBorrowFormBase extends Vue implements ControlInterface ...@@ -1556,7 +1556,7 @@ export default class GuideBorrowFormBase extends Vue implements ControlInterface
const action: any = Object.is(data.srfuf, '1') ? this.updateAction : this.createAction; const action: any = Object.is(data.srfuf, '1') ? this.updateAction : this.createAction;
if(!action){ if(!action){
let actionName:any = Object.is(data.srfuf, '1')?"updateAction":"createAction"; let actionName:any = Object.is(data.srfuf, '1')?"updateAction":"createAction";
this.$Notice.error({ title: (this.$t('app.commonWords.wrong') as string), desc: 'IBIZBOOKWizardView' + (this.$t('app.formpage.notconfig.actionname') as string) }); this.$Notice.error({ title: (this.$t('app.commonWords.wrong') as string), desc: 'IBIZBOOKWizardView_layout' + (this.$t('app.formpage.notconfig.actionname') as string) });
return; return;
} }
Object.assign(arg,{viewparams:this.viewparams}); Object.assign(arg,{viewparams:this.viewparams});
...@@ -1630,7 +1630,7 @@ export default class GuideBorrowFormBase extends Vue implements ControlInterface ...@@ -1630,7 +1630,7 @@ export default class GuideBorrowFormBase extends Vue implements ControlInterface
public remove(opt:Array<any> = [],showResultInfo?: boolean): Promise<any> { public remove(opt:Array<any> = [],showResultInfo?: boolean): Promise<any> {
return new Promise((resolve: any, reject: any) => { return new Promise((resolve: any, reject: any) => {
if(!this.removeAction){ if(!this.removeAction){
this.$Notice.error({ title: (this.$t('app.commonWords.wrong') as string), desc: 'IBIZBOOKWizardView' + (this.$t('app.formpage.notconfig.removeaction') as string) }); this.$Notice.error({ title: (this.$t('app.commonWords.wrong') as string), desc: 'IBIZBOOKWizardView_layout' + (this.$t('app.formpage.notconfig.removeaction') as string) });
return; return;
} }
const arg: any = opt[0]; const arg: any = opt[0];
......
...@@ -1318,7 +1318,7 @@ export default class GuideReturnFormBase extends Vue implements ControlInterface ...@@ -1318,7 +1318,7 @@ export default class GuideReturnFormBase extends Vue implements ControlInterface
*/ */
public load(opt: any = {}): void { public load(opt: any = {}): void {
if(!this.loadAction){ if(!this.loadAction){
this.$Notice.error({ title: (this.$t('app.commonWords.wrong') as string), desc: 'IBIZBOOKWizardView' + (this.$t('app.formpage.notconfig.loadaction') as string) }); this.$Notice.error({ title: (this.$t('app.commonWords.wrong') as string), desc: 'IBIZBOOKWizardView_layout' + (this.$t('app.formpage.notconfig.loadaction') as string) });
return; return;
} }
const arg: any = { ...opt }; const arg: any = { ...opt };
...@@ -1353,7 +1353,7 @@ export default class GuideReturnFormBase extends Vue implements ControlInterface ...@@ -1353,7 +1353,7 @@ export default class GuideReturnFormBase extends Vue implements ControlInterface
*/ */
public loadDraft(opt: any = {}): void { public loadDraft(opt: any = {}): void {
if(!this.loaddraftAction){ if(!this.loaddraftAction){
this.$Notice.error({ title: (this.$t('app.commonWords.wrong') as string), desc: 'IBIZBOOKWizardView' + (this.$t('app.formpage.notconfig.loaddraftaction') as string) }); this.$Notice.error({ title: (this.$t('app.commonWords.wrong') as string), desc: 'IBIZBOOKWizardView_layout' + (this.$t('app.formpage.notconfig.loaddraftaction') as string) });
return; return;
} }
const arg: any = { ...opt } ; const arg: any = { ...opt } ;
...@@ -1414,7 +1414,7 @@ export default class GuideReturnFormBase extends Vue implements ControlInterface ...@@ -1414,7 +1414,7 @@ export default class GuideReturnFormBase extends Vue implements ControlInterface
const action: any = Object.is(data.srfuf, '1') ? this.updateAction : this.createAction; const action: any = Object.is(data.srfuf, '1') ? this.updateAction : this.createAction;
if(!action){ if(!action){
let actionName:any = Object.is(data.srfuf, '1')?"updateAction":"createAction"; let actionName:any = Object.is(data.srfuf, '1')?"updateAction":"createAction";
this.$Notice.error({ title: (this.$t('app.commonWords.wrong') as string), desc: 'IBIZBOOKWizardView' + (this.$t('app.formpage.notconfig.actionname') as string) }); this.$Notice.error({ title: (this.$t('app.commonWords.wrong') as string), desc: 'IBIZBOOKWizardView_layout' + (this.$t('app.formpage.notconfig.actionname') as string) });
return; return;
} }
Object.assign(arg,{viewparams:this.viewparams}); Object.assign(arg,{viewparams:this.viewparams});
...@@ -1522,7 +1522,7 @@ export default class GuideReturnFormBase extends Vue implements ControlInterface ...@@ -1522,7 +1522,7 @@ export default class GuideReturnFormBase extends Vue implements ControlInterface
const action: any = Object.is(data.srfuf, '1') ? this.updateAction : this.createAction; const action: any = Object.is(data.srfuf, '1') ? this.updateAction : this.createAction;
if(!action){ if(!action){
let actionName:any = Object.is(data.srfuf, '1')?"updateAction":"createAction"; let actionName:any = Object.is(data.srfuf, '1')?"updateAction":"createAction";
this.$Notice.error({ title: (this.$t('app.commonWords.wrong') as string), desc: 'IBIZBOOKWizardView' + (this.$t('app.formpage.notconfig.actionname') as string) }); this.$Notice.error({ title: (this.$t('app.commonWords.wrong') as string), desc: 'IBIZBOOKWizardView_layout' + (this.$t('app.formpage.notconfig.actionname') as string) });
return; return;
} }
Object.assign(arg,{viewparams:this.viewparams}); Object.assign(arg,{viewparams:this.viewparams});
...@@ -1596,7 +1596,7 @@ export default class GuideReturnFormBase extends Vue implements ControlInterface ...@@ -1596,7 +1596,7 @@ export default class GuideReturnFormBase extends Vue implements ControlInterface
public remove(opt:Array<any> = [],showResultInfo?: boolean): Promise<any> { public remove(opt:Array<any> = [],showResultInfo?: boolean): Promise<any> {
return new Promise((resolve: any, reject: any) => { return new Promise((resolve: any, reject: any) => {
if(!this.removeAction){ if(!this.removeAction){
this.$Notice.error({ title: (this.$t('app.commonWords.wrong') as string), desc: 'IBIZBOOKWizardView' + (this.$t('app.formpage.notconfig.removeaction') as string) }); this.$Notice.error({ title: (this.$t('app.commonWords.wrong') as string), desc: 'IBIZBOOKWizardView_layout' + (this.$t('app.formpage.notconfig.removeaction') as string) });
return; return;
} }
const arg: any = opt[0]; const arg: any = opt[0];
......
...@@ -1421,7 +1421,7 @@ export default class GuideViewFormBase extends Vue implements ControlInterface { ...@@ -1421,7 +1421,7 @@ export default class GuideViewFormBase extends Vue implements ControlInterface {
*/ */
public load(opt: any = {}): void { public load(opt: any = {}): void {
if(!this.loadAction){ if(!this.loadAction){
this.$Notice.error({ title: (this.$t('app.commonWords.wrong') as string), desc: 'IBIZBOOKWizardView' + (this.$t('app.formpage.notconfig.loadaction') as string) }); this.$Notice.error({ title: (this.$t('app.commonWords.wrong') as string), desc: 'IBIZBOOKWizardView_layout' + (this.$t('app.formpage.notconfig.loadaction') as string) });
return; return;
} }
const arg: any = { ...opt }; const arg: any = { ...opt };
...@@ -1456,7 +1456,7 @@ export default class GuideViewFormBase extends Vue implements ControlInterface { ...@@ -1456,7 +1456,7 @@ export default class GuideViewFormBase extends Vue implements ControlInterface {
*/ */
public loadDraft(opt: any = {}): void { public loadDraft(opt: any = {}): void {
if(!this.loaddraftAction){ if(!this.loaddraftAction){
this.$Notice.error({ title: (this.$t('app.commonWords.wrong') as string), desc: 'IBIZBOOKWizardView' + (this.$t('app.formpage.notconfig.loaddraftaction') as string) }); this.$Notice.error({ title: (this.$t('app.commonWords.wrong') as string), desc: 'IBIZBOOKWizardView_layout' + (this.$t('app.formpage.notconfig.loaddraftaction') as string) });
return; return;
} }
const arg: any = { ...opt } ; const arg: any = { ...opt } ;
...@@ -1517,7 +1517,7 @@ export default class GuideViewFormBase extends Vue implements ControlInterface { ...@@ -1517,7 +1517,7 @@ export default class GuideViewFormBase extends Vue implements ControlInterface {
const action: any = Object.is(data.srfuf, '1') ? this.updateAction : this.createAction; const action: any = Object.is(data.srfuf, '1') ? this.updateAction : this.createAction;
if(!action){ if(!action){
let actionName:any = Object.is(data.srfuf, '1')?"updateAction":"createAction"; let actionName:any = Object.is(data.srfuf, '1')?"updateAction":"createAction";
this.$Notice.error({ title: (this.$t('app.commonWords.wrong') as string), desc: 'IBIZBOOKWizardView' + (this.$t('app.formpage.notconfig.actionname') as string) }); this.$Notice.error({ title: (this.$t('app.commonWords.wrong') as string), desc: 'IBIZBOOKWizardView_layout' + (this.$t('app.formpage.notconfig.actionname') as string) });
return; return;
} }
Object.assign(arg,{viewparams:this.viewparams}); Object.assign(arg,{viewparams:this.viewparams});
...@@ -1625,7 +1625,7 @@ export default class GuideViewFormBase extends Vue implements ControlInterface { ...@@ -1625,7 +1625,7 @@ export default class GuideViewFormBase extends Vue implements ControlInterface {
const action: any = Object.is(data.srfuf, '1') ? this.updateAction : this.createAction; const action: any = Object.is(data.srfuf, '1') ? this.updateAction : this.createAction;
if(!action){ if(!action){
let actionName:any = Object.is(data.srfuf, '1')?"updateAction":"createAction"; let actionName:any = Object.is(data.srfuf, '1')?"updateAction":"createAction";
this.$Notice.error({ title: (this.$t('app.commonWords.wrong') as string), desc: 'IBIZBOOKWizardView' + (this.$t('app.formpage.notconfig.actionname') as string) }); this.$Notice.error({ title: (this.$t('app.commonWords.wrong') as string), desc: 'IBIZBOOKWizardView_layout' + (this.$t('app.formpage.notconfig.actionname') as string) });
return; return;
} }
Object.assign(arg,{viewparams:this.viewparams}); Object.assign(arg,{viewparams:this.viewparams});
...@@ -1699,7 +1699,7 @@ export default class GuideViewFormBase extends Vue implements ControlInterface { ...@@ -1699,7 +1699,7 @@ export default class GuideViewFormBase extends Vue implements ControlInterface {
public remove(opt:Array<any> = [],showResultInfo?: boolean): Promise<any> { public remove(opt:Array<any> = [],showResultInfo?: boolean): Promise<any> {
return new Promise((resolve: any, reject: any) => { return new Promise((resolve: any, reject: any) => {
if(!this.removeAction){ if(!this.removeAction){
this.$Notice.error({ title: (this.$t('app.commonWords.wrong') as string), desc: 'IBIZBOOKWizardView' + (this.$t('app.formpage.notconfig.removeaction') as string) }); this.$Notice.error({ title: (this.$t('app.commonWords.wrong') as string), desc: 'IBIZBOOKWizardView_layout' + (this.$t('app.formpage.notconfig.removeaction') as string) });
return; return;
} }
const arg: any = opt[0]; const arg: any = opt[0];
......
...@@ -299,7 +299,7 @@ export default class MainBase extends Vue implements ControlInterface { ...@@ -299,7 +299,7 @@ export default class MainBase extends Vue implements ControlInterface {
* @param {*} [$event] 事件源 * @param {*} [$event] 事件源
* @param {*} [xData] 执行行为所需当前部件 * @param {*} [xData] 执行行为所需当前部件
* @param {*} [actionContext] 执行行为上下文 * @param {*} [actionContext] 执行行为上下文
* @memberof IBIZOrderPickupGridViewBase * @memberof IBIZOrderSF1GridViewBase
*/ */
public Edit(args: any[],contextJO?:any, params?: any, $event?: any, xData?: any,actionContext?:any,srfParentDeName?:string) { public Edit(args: any[],contextJO?:any, params?: any, $event?: any, xData?: any,actionContext?:any,srfParentDeName?:string) {
if (args.length === 0) { if (args.length === 0) {
...@@ -365,7 +365,7 @@ export default class MainBase extends Vue implements ControlInterface { ...@@ -365,7 +365,7 @@ export default class MainBase extends Vue implements ControlInterface {
const data = args && args.data ? args.data : this.getData() || {}; const data = args && args.data ? args.data : this.getData() || {};
const event = args && args.event ? args.event : {}; const event = args && args.event ? args.event : {};
let result: boolean = true; let result: boolean = true;
if ('rowdblclick;selectionchange;load;beforeload'.indexOf(eventName) !== -1) { if ('rowdblclick;selectionchange;remove;load;beforeload'.indexOf(eventName) !== -1) {
result = await this.execute_engine_grid_ctrl_logic(data, event); result = await this.execute_engine_grid_ctrl_logic(data, event);
} }
if (!result) { if (!result) {
...@@ -451,6 +451,20 @@ export default class MainBase extends Vue implements ControlInterface { ...@@ -451,6 +451,20 @@ export default class MainBase extends Vue implements ControlInterface {
return this.selections[0]; return this.selections[0];
} }
/**
* 打开新建数据视图
*
* @type {any}
* @memberof MainBase
*/
@Prop() public newdata: any;
/**
* 打开编辑数据视图
*
* @type {any}
* @memberof MainBase
*/
@Prop() public opendata: any;
/** /**
* 是否嵌入关系界面 * 是否嵌入关系界面
...@@ -983,7 +997,7 @@ export default class MainBase extends Vue implements ControlInterface { ...@@ -983,7 +997,7 @@ export default class MainBase extends Vue implements ControlInterface {
*/ */
public load(opt: any = {}, pageReset: boolean = false): void { public load(opt: any = {}, pageReset: boolean = false): void {
if(!this.fetchAction){ if(!this.fetchAction){
this.$Notice.error({ title: (this.$t('app.commonWords.wrong') as string), desc: 'IBIZOrderPickupGridView'+(this.$t('app.gridpage.notConfig.fetchAction') as string) }); this.$Notice.error({ title: (this.$t('app.commonWords.wrong') as string), desc: 'IBIZOrderSF1GridView'+(this.$t('app.gridpage.notConfig.fetchAction') as string) });
return; return;
} }
if(pageReset){ if(pageReset){
...@@ -1078,7 +1092,7 @@ export default class MainBase extends Vue implements ControlInterface { ...@@ -1078,7 +1092,7 @@ export default class MainBase extends Vue implements ControlInterface {
*/ */
public async remove(datas: any[]): Promise<any> { public async remove(datas: any[]): Promise<any> {
if(!this.removeAction){ if(!this.removeAction){
this.$Notice.error({ title: (this.$t('app.commonWords.wrong') as string), desc: 'IBIZOrderPickupGridView'+(this.$t('app.gridpage.notConfig.removeAction') as string) }); this.$Notice.error({ title: (this.$t('app.commonWords.wrong') as string), desc: 'IBIZOrderSF1GridView'+(this.$t('app.gridpage.notConfig.removeAction') as string) });
return; return;
} }
let _datas:any[] = []; let _datas:any[] = [];
...@@ -1184,7 +1198,7 @@ export default class MainBase extends Vue implements ControlInterface { ...@@ -1184,7 +1198,7 @@ export default class MainBase extends Vue implements ControlInterface {
*/ */
public addBatch(arg: any = {}): void { public addBatch(arg: any = {}): void {
if(!this.fetchAction){ if(!this.fetchAction){
this.$Notice.error({ title: (this.$t('app.commonWords.wrong') as string), desc: 'IBIZOrderPickupGridView'+(this.$t('app.gridpage.notConfig.fetchAction') as string) }); this.$Notice.error({ title: (this.$t('app.commonWords.wrong') as string), desc: 'IBIZOrderSF1GridView'+(this.$t('app.gridpage.notConfig.fetchAction') as string) });
return; return;
} }
if(!arg){ if(!arg){
...@@ -2101,7 +2115,7 @@ export default class MainBase extends Vue implements ControlInterface { ...@@ -2101,7 +2115,7 @@ export default class MainBase extends Vue implements ControlInterface {
try { try {
if(Object.is(item.rowDataState, 'create')){ if(Object.is(item.rowDataState, 'create')){
if(!this.createAction){ if(!this.createAction){
this.$Notice.error({ title: (this.$t('app.commonWords.wrong') as string), desc: 'IBIZOrderPickupGridView'+(this.$t('app.gridpage.notConfig.createAction') as string) }); this.$Notice.error({ title: (this.$t('app.commonWords.wrong') as string), desc: 'IBIZOrderSF1GridView'+(this.$t('app.gridpage.notConfig.createAction') as string) });
}else{ }else{
Object.assign(item,{viewparams:this.viewparams}); Object.assign(item,{viewparams:this.viewparams});
let response = await this.service.add(this.createAction, JSON.parse(JSON.stringify(this.context)),item, this.showBusyIndicator); let response = await this.service.add(this.createAction, JSON.parse(JSON.stringify(this.context)),item, this.showBusyIndicator);
...@@ -2109,7 +2123,7 @@ export default class MainBase extends Vue implements ControlInterface { ...@@ -2109,7 +2123,7 @@ export default class MainBase extends Vue implements ControlInterface {
} }
}else if(Object.is(item.rowDataState, 'update')){ }else if(Object.is(item.rowDataState, 'update')){
if(!this.updateAction){ if(!this.updateAction){
this.$Notice.error({ title: (this.$t('app.commonWords.wrong') as string), desc: 'IBIZOrderPickupGridView'+(this.$t('app.gridpage.notConfig.updateAction') as string) }); this.$Notice.error({ title: (this.$t('app.commonWords.wrong') as string), desc: 'IBIZOrderSF1GridView'+(this.$t('app.gridpage.notConfig.updateAction') as string) });
}else{ }else{
Object.assign(item,{viewparams:this.viewparams}); Object.assign(item,{viewparams:this.viewparams});
if(item.ibizorder){ if(item.ibizorder){
...@@ -2176,7 +2190,7 @@ export default class MainBase extends Vue implements ControlInterface { ...@@ -2176,7 +2190,7 @@ export default class MainBase extends Vue implements ControlInterface {
*/ */
public newRow(args: any[], params?: any, $event?: any, xData?: any): void { public newRow(args: any[], params?: any, $event?: any, xData?: any): void {
if(!this.loaddraftAction){ if(!this.loaddraftAction){
this.$Notice.error({ title: (this.$t('app.commonWords.wrong') as string), desc: 'IBIZOrderPickupGridView'+(this.$t('app.gridpage.notConfig.loaddraftAction') as string) }); this.$Notice.error({ title: (this.$t('app.commonWords.wrong') as string), desc: 'IBIZOrderSF1GridView'+(this.$t('app.gridpage.notConfig.loaddraftAction') as string) });
return; return;
} }
let _this = this; let _this = this;
......
...@@ -104,6 +104,21 @@ export default class MainModel { ...@@ -104,6 +104,21 @@ export default class MainModel {
prop: 'n_ibizordername_like', prop: 'n_ibizordername_like',
dataType: 'QUERYPARAM' dataType: 'QUERYPARAM'
}, },
{
name: 'n_orderstate_eq',
prop: 'n_orderstate_eq',
dataType: 'QUERYPARAM'
},
{
name: 'n_ordertime_gt',
prop: 'n_ordertime_gt',
dataType: 'QUERYPARAM'
},
{
name: 'n_ordertime_lt',
prop: 'n_ordertime_lt',
dataType: 'QUERYPARAM'
},
{ {
name:'size', name:'size',
......
Markdown 格式
0% or
您添加了 0 到此讨论。请谨慎行事。
先完成此消息的编辑!
想要评论请 注册