提交 a2b8bdff 编写于 作者: tony001's avatar tony001

update:更新

上级 0fe0b336
...@@ -48,7 +48,7 @@ export default class AppIndexNavBreadcrumb extends Vue { ...@@ -48,7 +48,7 @@ export default class AppIndexNavBreadcrumb extends Vue {
* @type {number} * @type {number}
* @memberof AppIndexNavBreadcrumb * @memberof AppIndexNavBreadcrumb
*/ */
@Prop({ default: 0 }) public index?: number; @Prop() public index?: number;
/** /**
* 项名称 * 项名称
...@@ -57,7 +57,7 @@ export default class AppIndexNavBreadcrumb extends Vue { ...@@ -57,7 +57,7 @@ export default class AppIndexNavBreadcrumb extends Vue {
* @memberof AppIndexNavBreadcrumb * @memberof AppIndexNavBreadcrumb
*/ */
get itemName() { get itemName() {
return this.index ? `${this.name}_${this.index}` : this.name; return (this.index || this.index === 0) ? `${this.name}_${this.index}` : this.name;
} }
/** /**
......
...@@ -31,7 +31,7 @@ export default class AppIndexNavTabs extends Vue { ...@@ -31,7 +31,7 @@ export default class AppIndexNavTabs extends Vue {
* @type {number} * @type {number}
* @memberof AppIndexNavTabs * @memberof AppIndexNavTabs
*/ */
@Prop({ default: 0 }) public index?: number; @Prop() public index?: number;
/** /**
* 项名称 * 项名称
...@@ -40,7 +40,7 @@ export default class AppIndexNavTabs extends Vue { ...@@ -40,7 +40,7 @@ export default class AppIndexNavTabs extends Vue {
* @memberof AppIndexNavTabs * @memberof AppIndexNavTabs
*/ */
get itemName() { get itemName() {
return this.index ? `${this.name}_${this.index}` : this.name; return (this.index || this.index === 0) ? `${this.name}_${this.index}` : this.name;
} }
/** /**
......
...@@ -31,7 +31,7 @@ export default class AppIndexOrgSelect extends Vue { ...@@ -31,7 +31,7 @@ export default class AppIndexOrgSelect extends Vue {
* @type {number} * @type {number}
* @memberof AppIndexOrgSelect * @memberof AppIndexOrgSelect
*/ */
@Prop({ default: 0 }) public index?: number; @Prop() public index?: number;
/** /**
* 项名称 * 项名称
...@@ -40,7 +40,7 @@ export default class AppIndexOrgSelect extends Vue { ...@@ -40,7 +40,7 @@ export default class AppIndexOrgSelect extends Vue {
* @memberof AppIndexOrgSelect * @memberof AppIndexOrgSelect
*/ */
get itemName() { get itemName() {
return this.index ? `${this.name}_${this.index}` : this.name; return (this.index || this.index === 0) ? `${this.name}_${this.index}` : this.name;
} }
/** /**
......
...@@ -31,7 +31,7 @@ export default class AppIndexUserInfo extends Vue { ...@@ -31,7 +31,7 @@ export default class AppIndexUserInfo extends Vue {
* @type {number} * @type {number}
* @memberof AppIndexUserInfo * @memberof AppIndexUserInfo
*/ */
@Prop({ default: 0 }) public index?: number; @Prop() public index?: number;
/** /**
* 项名称 * 项名称
...@@ -40,7 +40,7 @@ export default class AppIndexUserInfo extends Vue { ...@@ -40,7 +40,7 @@ export default class AppIndexUserInfo extends Vue {
* @memberof AppIndexUserInfo * @memberof AppIndexUserInfo
*/ */
get itemName() { get itemName() {
return this.index ? `${this.name}_${this.index}` : this.name; return (this.index || this.index === 0) ? `${this.name}_${this.index}` : this.name;
} }
/** /**
......
...@@ -47,7 +47,7 @@ export default class AppPresetButton extends Vue { ...@@ -47,7 +47,7 @@ export default class AppPresetButton extends Vue {
* @type {number} * @type {number}
* @memberof AppPresetButton * @memberof AppPresetButton
*/ */
@Prop({ default: 0 }) public index?: number; @Prop() public index?: number;
/** /**
* 项名称 * 项名称
...@@ -56,7 +56,7 @@ export default class AppPresetButton extends Vue { ...@@ -56,7 +56,7 @@ export default class AppPresetButton extends Vue {
* @memberof AppPresetButton * @memberof AppPresetButton
*/ */
get itemName() { get itemName() {
return this.index ? `${this.name}_${this.index}` : this.name; return (this.index || this.index === 0) ? `${this.name}_${this.index}` : this.name;
} }
/** /**
......
...@@ -46,7 +46,7 @@ export default class AppPresetQrCode extends Vue { ...@@ -46,7 +46,7 @@ export default class AppPresetQrCode extends Vue {
* @type {number} * @type {number}
* @memberof AppPresetQrCode * @memberof AppPresetQrCode
*/ */
@Prop({ default: 0 }) public index?: number; @Prop() public index?: number;
/** /**
* 项名称 * 项名称
...@@ -55,7 +55,7 @@ export default class AppPresetQrCode extends Vue { ...@@ -55,7 +55,7 @@ export default class AppPresetQrCode extends Vue {
* @memberof AppPresetQrCode * @memberof AppPresetQrCode
*/ */
get itemName() { get itemName() {
return this.index ? `${this.name}_${this.index}` : this.name; return (this.index || this.index === 0) ? `${this.name}_${this.index}` : this.name;
} }
/** /**
......
...@@ -37,7 +37,7 @@ export default class AppPresetSwitch extends Vue { ...@@ -37,7 +37,7 @@ export default class AppPresetSwitch extends Vue {
* @type {number} * @type {number}
* @memberof AppPresetSwitch * @memberof AppPresetSwitch
*/ */
@Prop({ default: 0 }) public index?: number; @Prop() public index?: number;
/** /**
* 项名称 * 项名称
...@@ -46,7 +46,7 @@ export default class AppPresetSwitch extends Vue { ...@@ -46,7 +46,7 @@ export default class AppPresetSwitch extends Vue {
* @memberof AppPresetSwitch * @memberof AppPresetSwitch
*/ */
get itemName() { get itemName() {
return this.index ? `${this.name}_${this.index}` : this.name; return (this.index || this.index === 0) ? `${this.name}_${this.index}` : this.name;
} }
/** /**
......
...@@ -39,7 +39,7 @@ export default class AppPresetTextInput extends Vue { ...@@ -39,7 +39,7 @@ export default class AppPresetTextInput extends Vue {
* @type {number} * @type {number}
* @memberof AppPresetTextInput * @memberof AppPresetTextInput
*/ */
@Prop({ default: 0 }) public index?: number; @Prop() public index?: number;
/** /**
* 项名称 * 项名称
...@@ -48,7 +48,7 @@ export default class AppPresetTextInput extends Vue { ...@@ -48,7 +48,7 @@ export default class AppPresetTextInput extends Vue {
* @memberof AppPresetTextInput * @memberof AppPresetTextInput
*/ */
get itemName() { get itemName() {
return this.index ? `${this.name}_${this.index}` : this.name; return (this.index || this.index === 0) ? `${this.name}_${this.index}` : this.name;
} }
/** /**
......
...@@ -47,7 +47,7 @@ export default class AppLoginButton extends Vue { ...@@ -47,7 +47,7 @@ export default class AppLoginButton extends Vue {
* @type {number} * @type {number}
* @memberof AppLoginButton * @memberof AppLoginButton
*/ */
@Prop({ default: 0 }) public index?: number; @Prop() public index?: number;
/** /**
* 项名称 * 项名称
...@@ -56,7 +56,7 @@ export default class AppLoginButton extends Vue { ...@@ -56,7 +56,7 @@ export default class AppLoginButton extends Vue {
* @memberof AppLoginButton * @memberof AppLoginButton
*/ */
get itemName() { get itemName() {
return this.index ? `${this.name}_${this.index}` : this.name; return (this.index || this.index === 0) ? `${this.name}_${this.index}` : this.name;
} }
/** /**
......
...@@ -44,8 +44,7 @@ export default class AppLoginCaptcha extends Vue { ...@@ -44,8 +44,7 @@ export default class AppLoginCaptcha extends Vue {
* @type {number} * @type {number}
* @memberof AppLoginCaptcha * @memberof AppLoginCaptcha
*/ */
@Prop({ default: 0 }) public index?: number; @Prop() public index?: number;
/** /**
* 是否显示 * 是否显示
...@@ -69,7 +68,7 @@ export default class AppLoginCaptcha extends Vue { ...@@ -69,7 +68,7 @@ export default class AppLoginCaptcha extends Vue {
* @memberof AppLoginCaptcha * @memberof AppLoginCaptcha
*/ */
get itemName() { get itemName() {
return this.index ? `${this.name}_${this.index}` : this.name; return (this.index || this.index === 0) ? `${this.name}_${this.index}` : this.name;
} }
/** /**
......
...@@ -59,7 +59,7 @@ export default class AppLoginInput extends Vue { ...@@ -59,7 +59,7 @@ export default class AppLoginInput extends Vue {
* @type {number} * @type {number}
* @memberof AppLoginInput * @memberof AppLoginInput
*/ */
@Prop({ default: 0 }) public index?: number; @Prop() public index?: number;
/** /**
* 项名称 * 项名称
...@@ -68,7 +68,7 @@ export default class AppLoginInput extends Vue { ...@@ -68,7 +68,7 @@ export default class AppLoginInput extends Vue {
* @memberof AppLoginInput * @memberof AppLoginInput
*/ */
get itemName() { get itemName() {
return this.index ? `${this.name}_${this.index}` : this.name; return (this.index || this.index === 0) ? `${this.name}_${this.index}` : this.name;
} }
/** /**
......
...@@ -40,7 +40,7 @@ export default class AppLoginMessage extends Vue { ...@@ -40,7 +40,7 @@ export default class AppLoginMessage extends Vue {
* @type {number} * @type {number}
* @memberof AppLoginMessage * @memberof AppLoginMessage
*/ */
@Prop({ default: 0 }) public index?: number; @Prop() public index?: number;
/** /**
* 项名称 * 项名称
...@@ -49,7 +49,7 @@ export default class AppLoginMessage extends Vue { ...@@ -49,7 +49,7 @@ export default class AppLoginMessage extends Vue {
* @memberof AppLoginMessage * @memberof AppLoginMessage
*/ */
get itemName() { get itemName() {
return this.index ? `${this.name}_${this.index}` : this.name; return (this.index || this.index === 0) ? `${this.name}_${this.index}` : this.name;
} }
/** /**
......
...@@ -50,7 +50,7 @@ export default class AppLoginNoteVerify extends Vue { ...@@ -50,7 +50,7 @@ export default class AppLoginNoteVerify extends Vue {
* @type {number} * @type {number}
* @memberof AppLoginNoteVerify * @memberof AppLoginNoteVerify
*/ */
@Prop({ default: 0 }) public index?: number; @Prop() public index?: number;
/** /**
* 项名称 * 项名称
...@@ -59,7 +59,7 @@ export default class AppLoginNoteVerify extends Vue { ...@@ -59,7 +59,7 @@ export default class AppLoginNoteVerify extends Vue {
* @memberof AppLoginNoteVerify * @memberof AppLoginNoteVerify
*/ */
get itemName() { get itemName() {
return this.index ? `${this.name}_${this.index}` : this.name; return (this.index || this.index === 0) ? `${this.name}_${this.index}` : this.name;
} }
/** /**
......
...@@ -41,7 +41,7 @@ export default class AppLoginOrg extends Vue { ...@@ -41,7 +41,7 @@ export default class AppLoginOrg extends Vue {
* @type {number} * @type {number}
* @memberof AppLoginOrg * @memberof AppLoginOrg
*/ */
@Prop({ default: 0 }) public index?: number; @Prop() public index?: number;
/** /**
* 项名称 * 项名称
...@@ -50,7 +50,7 @@ export default class AppLoginOrg extends Vue { ...@@ -50,7 +50,7 @@ export default class AppLoginOrg extends Vue {
* @memberof AppLoginOrg * @memberof AppLoginOrg
*/ */
get itemName() { get itemName() {
return this.index ? `${this.name}_${this.index}` : this.name; return (this.index || this.index === 0) ? `${this.name}_${this.index}` : this.name;
} }
/** /**
......
...@@ -47,7 +47,7 @@ export default class AppThirdLogin extends Vue { ...@@ -47,7 +47,7 @@ export default class AppThirdLogin extends Vue {
* @type {number} * @type {number}
* @memberof AppThirdLogin * @memberof AppThirdLogin
*/ */
@Prop({ default: 0 }) public index?: number; @Prop() public index?: number;
/** /**
* 项名称 * 项名称
...@@ -56,7 +56,7 @@ export default class AppThirdLogin extends Vue { ...@@ -56,7 +56,7 @@ export default class AppThirdLogin extends Vue {
* @memberof AppThirdLogin * @memberof AppThirdLogin
*/ */
get itemName() { get itemName() {
return this.index ? `${this.name}_${this.index}` : this.name; return (this.index || this.index === 0) ? `${this.name}_${this.index}` : this.name;
} }
/** /**
......
...@@ -39,7 +39,7 @@ export default class AppFieldImageDynamic extends Vue { ...@@ -39,7 +39,7 @@ export default class AppFieldImageDynamic extends Vue {
* @type {number} * @type {number}
* @memberof AppFieldImageDynamic * @memberof AppFieldImageDynamic
*/ */
@Prop({ default: 0 }) public index?: number; @Prop() public index?: number;
/** /**
* 值变更 * 值变更
...@@ -58,7 +58,7 @@ export default class AppFieldImageDynamic extends Vue { ...@@ -58,7 +58,7 @@ export default class AppFieldImageDynamic extends Vue {
* @memberof AppFieldImageDynamic * @memberof AppFieldImageDynamic
*/ */
get itemName() { get itemName() {
return this.index ? `${this.name}_${this.index}` : this.name; return (this.index || this.index === 0) ? `${this.name}_${this.index}` : this.name;
} }
/** /**
......
...@@ -60,7 +60,7 @@ export default class AppCarousel extends Vue { ...@@ -60,7 +60,7 @@ export default class AppCarousel extends Vue {
* @type {number} * @type {number}
* @memberof AppCarousel * @memberof AppCarousel
*/ */
@Prop({ default: 0 }) public index?: number; @Prop() public index?: number;
/** /**
* 项名称 * 项名称
...@@ -69,7 +69,7 @@ export default class AppCarousel extends Vue { ...@@ -69,7 +69,7 @@ export default class AppCarousel extends Vue {
* @memberof AppCarousel * @memberof AppCarousel
*/ */
get itemName() { get itemName() {
return this.index ? `${this.name}_${this.index}` : this.name; return (this.index || this.index === 0) ? `${this.name}_${this.index}` : this.name;
} }
/** /**
......
...@@ -46,7 +46,7 @@ export default class AppRawItemImage extends Vue { ...@@ -46,7 +46,7 @@ export default class AppRawItemImage extends Vue {
* @type {number} * @type {number}
* @memberof AppRawItemImage * @memberof AppRawItemImage
*/ */
@Prop({ default: 0 }) public index?: number; @Prop() public index?: number;
/** /**
* 项名称 * 项名称
...@@ -55,7 +55,7 @@ export default class AppRawItemImage extends Vue { ...@@ -55,7 +55,7 @@ export default class AppRawItemImage extends Vue {
* @memberof AppRawItemImage * @memberof AppRawItemImage
*/ */
get itemName() { get itemName() {
return this.index ? `${this.name}_${this.index}` : this.name; return (this.index || this.index === 0) ? `${this.name}_${this.index}` : this.name;
} }
/** /**
......
...@@ -42,7 +42,7 @@ export default class AppRawItemVideo extends Vue { ...@@ -42,7 +42,7 @@ export default class AppRawItemVideo extends Vue {
* @type {number} * @type {number}
* @memberof AppRawItemVideo * @memberof AppRawItemVideo
*/ */
@Prop({ default: 0 }) public index?: number; @Prop() public index?: number;
/** /**
* 值变更 * 值变更
...@@ -61,7 +61,7 @@ export default class AppRawItemVideo extends Vue { ...@@ -61,7 +61,7 @@ export default class AppRawItemVideo extends Vue {
* @memberof AppRawItemVideo * @memberof AppRawItemVideo
*/ */
get itemName() { get itemName() {
return this.index ? `${this.name}_${this.index}` : this.name; return (this.index || this.index === 0) ? `${this.name}_${this.index}` : this.name;
} }
/** /**
......
...@@ -31,7 +31,7 @@ export default class AppCtrlPos extends Vue { ...@@ -31,7 +31,7 @@ export default class AppCtrlPos extends Vue {
* @type {number} * @type {number}
* @memberof AppCtrlPos * @memberof AppCtrlPos
*/ */
@Prop({ default: 0 }) public index?: number; @Prop() public index?: number;
/** /**
* 项名称 * 项名称
...@@ -40,7 +40,7 @@ export default class AppCtrlPos extends Vue { ...@@ -40,7 +40,7 @@ export default class AppCtrlPos extends Vue {
* @memberof AppCtrlPos * @memberof AppCtrlPos
*/ */
get itemName() { get itemName() {
return this.index ? `${this.name}_${this.index}` : this.name; return (this.index || this.index === 0) ? `${this.name}_${this.index}` : this.name;
} }
/** /**
......
...@@ -43,7 +43,7 @@ export default class AppNavPos extends Vue { ...@@ -43,7 +43,7 @@ export default class AppNavPos extends Vue {
* @type {number} * @type {number}
* @memberof AppNavPos * @memberof AppNavPos
*/ */
@Prop({ default: 0 }) public index?: number; @Prop() public index?: number;
/** /**
* 导航数据 * 导航数据
...@@ -60,7 +60,7 @@ export default class AppNavPos extends Vue { ...@@ -60,7 +60,7 @@ export default class AppNavPos extends Vue {
* @memberof AppNavPos * @memberof AppNavPos
*/ */
get itemName() { get itemName() {
return this.index ? `${this.name}_${this.index}` : this.name; return (this.index || this.index === 0) ? `${this.name}_${this.index}` : this.name;
} }
/** /**
......
...@@ -55,7 +55,7 @@ export default class AppScrollContainer extends Vue { ...@@ -55,7 +55,7 @@ export default class AppScrollContainer extends Vue {
* @type {number} * @type {number}
* @memberof AppScrollContainer * @memberof AppScrollContainer
*/ */
@Prop({ default: 0 }) public index?: number; @Prop() public index?: number;
/** /**
* 布局模型详情 * 布局模型详情
...@@ -96,7 +96,7 @@ export default class AppScrollContainer extends Vue { ...@@ -96,7 +96,7 @@ export default class AppScrollContainer extends Vue {
* @memberof AppScrollContainer * @memberof AppScrollContainer
*/ */
get itemName() { get itemName() {
return this.index ? `${this.name}_${this.index}` : this.name; return (this.index || this.index === 0) ? `${this.name}_${this.index}` : this.name;
} }
/** /**
...@@ -132,7 +132,7 @@ export default class AppScrollContainer extends Vue { ...@@ -132,7 +132,7 @@ export default class AppScrollContainer extends Vue {
if (curLayoutModel && curLayoutModel.details && curLayoutModel.details.length > 0) { if (curLayoutModel && curLayoutModel.details && curLayoutModel.details.length > 0) {
curLayoutModel.details.forEach((key: string) => { curLayoutModel.details.forEach((key: string) => {
let childModelDetail: any; let childModelDetail: any;
if (this.index) { if (this.index || this.index === 0) {
childModelDetail = this.layoutModelDetails[`${key}_${this.index}`]; childModelDetail = this.layoutModelDetails[`${key}_${this.index}`];
} else { } else {
childModelDetail = this.layoutModelDetails[key]; childModelDetail = this.layoutModelDetails[key];
...@@ -171,7 +171,7 @@ export default class AppScrollContainer extends Vue { ...@@ -171,7 +171,7 @@ export default class AppScrollContainer extends Vue {
* 获取项布局样式 * 获取项布局样式
*/ */
public getItemPosStyle(name: string) { public getItemPosStyle(name: string) {
const itemName = this.index ? `${name}_${this.index}` : name; const itemName = (this.index || this.index === 0) ? `${name}_${this.index}` : name;
let layoutModel = this.layoutModelDetails[itemName]; let layoutModel = this.layoutModelDetails[itemName];
if (layoutModel) { if (layoutModel) {
const childBoxSizeStyle: any = layoutModel.getBoxSizeStyle(); const childBoxSizeStyle: any = layoutModel.getBoxSizeStyle();
......
...@@ -27,7 +27,7 @@ export default class AppSimpleFlexContainer extends Vue { ...@@ -27,7 +27,7 @@ export default class AppSimpleFlexContainer extends Vue {
* @type {number} * @type {number}
* @memberof AppSimpleFlexContainer * @memberof AppSimpleFlexContainer
*/ */
@Prop({ default: 0 }) public index?: number; @Prop() public index?: number;
/** /**
* 布局模型详情 * 布局模型详情
...@@ -61,7 +61,7 @@ export default class AppSimpleFlexContainer extends Vue { ...@@ -61,7 +61,7 @@ export default class AppSimpleFlexContainer extends Vue {
* @memberof AppSimpleFlexContainer * @memberof AppSimpleFlexContainer
*/ */
get itemName() { get itemName() {
return this.index ? `${this.name}_${this.index}` : this.name; return (this.index || this.index === 0) ? `${this.name}_${this.index}` : this.name;
} }
/** /**
...@@ -104,7 +104,7 @@ export default class AppSimpleFlexContainer extends Vue { ...@@ -104,7 +104,7 @@ export default class AppSimpleFlexContainer extends Vue {
*/ */
public getItemPosStyle(name: string) { public getItemPosStyle(name: string) {
let layoutModel: any; let layoutModel: any;
if (this.index) { if (this.index || this.index === 0) {
layoutModel = this.layoutModelDetails[`${name}_${this.index}`]; layoutModel = this.layoutModelDetails[`${name}_${this.index}`];
} else { } else {
layoutModel = this.layoutModelDetails[name]; layoutModel = this.layoutModelDetails[name];
......
...@@ -38,7 +38,7 @@ export default class AppStandardContainer extends Vue { ...@@ -38,7 +38,7 @@ export default class AppStandardContainer extends Vue {
* @type {number} * @type {number}
* @memberof AppStandardContainer * @memberof AppStandardContainer
*/ */
@Prop({ default: 0 }) public index?: number; @Prop() public index?: number;
/** /**
* 布局模型详情 * 布局模型详情
...@@ -63,7 +63,7 @@ export default class AppStandardContainer extends Vue { ...@@ -63,7 +63,7 @@ export default class AppStandardContainer extends Vue {
* @memberof AppStandardContainer * @memberof AppStandardContainer
*/ */
get itemName() { get itemName() {
return this.index ? `${this.name}_${this.index}` : this.name; return (this.index || this.index === 0) ? `${this.name}_${this.index}` : this.name;
} }
/** /**
...@@ -137,7 +137,7 @@ export default class AppStandardContainer extends Vue { ...@@ -137,7 +137,7 @@ export default class AppStandardContainer extends Vue {
*/ */
public getItemPosStyle(name: string) { public getItemPosStyle(name: string) {
let layoutModel: any; let layoutModel: any;
if (this.index) { if ((this.index || this.index === 0)) {
layoutModel = this.layoutModelDetails[`${name}_${this.index}`]; layoutModel = this.layoutModelDetails[`${name}_${this.index}`];
} else { } else {
layoutModel = this.layoutModelDetails[name]; layoutModel = this.layoutModelDetails[name];
......
...@@ -36,7 +36,7 @@ export default class AppTabPage extends Vue { ...@@ -36,7 +36,7 @@ export default class AppTabPage extends Vue {
* @type {number} * @type {number}
* @memberof AppTabPage * @memberof AppTabPage
*/ */
@Prop({ default: 0 }) public index?: number; @Prop() public index?: number;
/** /**
* 布局模型详情变更 * 布局模型详情变更
...@@ -69,7 +69,7 @@ export default class AppTabPage extends Vue { ...@@ -69,7 +69,7 @@ export default class AppTabPage extends Vue {
* @memberof AppTabPage * @memberof AppTabPage
*/ */
get itemName() { get itemName() {
return this.index ? `${this.name}_${this.index}` : this.name; return (this.index || this.index === 0) ? `${this.name}_${this.index}` : this.name;
} }
/** /**
......
...@@ -35,7 +35,7 @@ export default class AppTabPanel extends Vue { ...@@ -35,7 +35,7 @@ export default class AppTabPanel extends Vue {
* @type {number} * @type {number}
* @memberof AppTabPanel * @memberof AppTabPanel
*/ */
@Prop({ default: 0 }) public index?: number; @Prop() public index?: number;
/** /**
* 项名称 * 项名称
...@@ -44,7 +44,7 @@ export default class AppTabPanel extends Vue { ...@@ -44,7 +44,7 @@ export default class AppTabPanel extends Vue {
* @memberof AppTabPanel * @memberof AppTabPanel
*/ */
get itemName() { get itemName() {
return this.index ? `${this.name}_${this.index}` : this.name; return (this.index || this.index === 0) ? `${this.name}_${this.index}` : this.name;
} }
/** /**
......
...@@ -70,7 +70,7 @@ export default class AppPresetCaption extends Vue { ...@@ -70,7 +70,7 @@ export default class AppPresetCaption extends Vue {
* @type {number} * @type {number}
* @memberof AppPresetCaption * @memberof AppPresetCaption
*/ */
@Prop({ default: 0 }) public index?: number; @Prop() public index?: number;
/** /**
* 项名称 * 项名称
...@@ -79,7 +79,7 @@ export default class AppPresetCaption extends Vue { ...@@ -79,7 +79,7 @@ export default class AppPresetCaption extends Vue {
* @memberof AppPresetCaption * @memberof AppPresetCaption
*/ */
get itemName() { get itemName() {
return this.index ? `${this.name}_${this.index}` : this.name; return (this.index || this.index === 0) ? `${this.name}_${this.index}` : this.name;
} }
/** /**
......
...@@ -87,7 +87,7 @@ export default class AppPresetText extends Vue { ...@@ -87,7 +87,7 @@ export default class AppPresetText extends Vue {
* @type {number} * @type {number}
* @memberof AppPresetText * @memberof AppPresetText
*/ */
@Prop({ default: 0 }) public index?: number; @Prop() public index?: number;
/** /**
* 项名称 * 项名称
...@@ -96,7 +96,7 @@ export default class AppPresetText extends Vue { ...@@ -96,7 +96,7 @@ export default class AppPresetText extends Vue {
* @memberof AppPresetText * @memberof AppPresetText
*/ */
get itemName() { get itemName() {
return this.index ? `${this.name}_${this.index}` : this.name; return (this.index || this.index === 0) ? `${this.name}_${this.index}` : this.name;
} }
/** /**
......
...@@ -30,7 +30,7 @@ export default class AppPresetTitle extends Vue { ...@@ -30,7 +30,7 @@ export default class AppPresetTitle extends Vue {
* @type {number} * @type {number}
* @memberof AppPresetTitle * @memberof AppPresetTitle
*/ */
@Prop({ default: 0 }) public index?: number; @Prop() public index?: number;
/** /**
* 项名称 * 项名称
...@@ -39,7 +39,7 @@ export default class AppPresetTitle extends Vue { ...@@ -39,7 +39,7 @@ export default class AppPresetTitle extends Vue {
* @memberof AppPresetTitle * @memberof AppPresetTitle
*/ */
get itemName() { get itemName() {
return this.index ? `${this.name}_${this.index}` : this.name; return (this.index || this.index === 0) ? `${this.name}_${this.index}` : this.name;
} }
/** /**
......
Markdown 格式
0% or
您添加了 0 到此讨论。请谨慎行事。
先完成此消息的编辑!
想要评论请 注册