From aa20f8184a3554fa8fe6347fde5f17e0fc00e849 Mon Sep 17 00:00:00 2001
From: wuxw <928255095@qq.com>
Date: Tue, 27 Feb 2024 21:50:13 +0800
Subject: [PATCH] =?UTF-8?q?=E4=BC=98=E5=8C=96=E4=BB=A3=E7=A0=81?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
.../addRepairSetting/addRepairSetting.html | 6 +--
.../addRepairSetting/addRepairSetting.js | 48 ++++++++-----------
.../editRepairSetting/editRepairSetting.html | 10 ++--
.../repairSettingManage.html | 12 ++---
4 files changed, 34 insertions(+), 42 deletions(-)
diff --git a/public/components/property/addRepairSetting/addRepairSetting.html b/public/components/property/addRepairSetting/addRepairSetting.html
index a98c3635a..718fd0964 100644
--- a/public/components/property/addRepairSetting/addRepairSetting.html
+++ b/public/components/property/addRepairSetting/addRepairSetting.html
@@ -51,10 +51,10 @@
diff --git a/public/components/property/addRepairSetting/addRepairSetting.js b/public/components/property/addRepairSetting/addRepairSetting.js
index 696252e5e..155c99dea 100644
--- a/public/components/property/addRepairSetting/addRepairSetting.js
+++ b/public/components/property/addRepairSetting/addRepairSetting.js
@@ -1,22 +1,18 @@
(function (vc) {
vc.extends({
- propTypes: {
- callBackListener: vc.propTypes.string, //父组件名称
- callBackFunction: vc.propTypes.string //父组件监听方法
- },
data: {
addRepairSettingInfo: {
settingId: '',
repairTypeName: '',
- repairWay: '',
- repairSettingType: '',
+ repairWay: '200',
+ repairSettingType: '200',
remark: '',
- publicArea: '',
+ publicArea: 'F',
payFeeFlag: 'F',
priceScope: '',
- returnVisitFlag: '',
- isShow: '',
- notifyWay:'WECHAT'
+ returnVisitFlag: '003',
+ isShow: 'Y',
+ notifyWay: 'WECHAT'
}
},
_initMethod: function () {
@@ -29,7 +25,7 @@
methods: {
addRepairSettingValidate() {
return vc.validate.validate({
- addRepairSettingInfo: vc.component.addRepairSettingInfo
+ addRepairSettingInfo: $that.addRepairSettingInfo
}, {
'addRepairSettingInfo.repairTypeName': [
{
@@ -103,20 +99,14 @@
if ($that.addRepairSettingInfo.payFeeFlag == 'F') {
$that.addRepairSettingInfo.priceScope = '不收费';
}
- if (!vc.component.addRepairSettingValidate()) {
+ if (!$that.addRepairSettingValidate()) {
vc.toast(vc.validate.errInfo);
return;
}
- vc.component.addRepairSettingInfo.communityId = vc.getCurrentCommunity().communityId;
- //不提交数据将数据 回调给侦听处理
- if (vc.notNull($props.callBackListener)) {
- vc.emit($props.callBackListener, $props.callBackFunction, vc.component.addRepairSettingInfo);
- $('#addRepairSettingModel').modal('hide');
- return;
- }
+ $that.addRepairSettingInfo.communityId = vc.getCurrentCommunity().communityId;
vc.http.apiPost(
- 'repair.saveRepairSetting',
- JSON.stringify(vc.component.addRepairSettingInfo),
+ '/repair.saveRepairSetting',
+ JSON.stringify($that.addRepairSettingInfo),
{
emulateJSON: true
},
@@ -126,7 +116,7 @@
if (_json.code == 0) {
//关闭model
$('#addRepairSettingModel').modal('hide');
- vc.component.clearAddRepairSettingInfo();
+ $that.clearAddRepairSettingInfo();
vc.emit('repairSettingManage', 'listRepairSetting', {});
vc.toast("添加成功,请记得绑定维修师傅!");
return;
@@ -140,16 +130,18 @@
});
},
clearAddRepairSettingInfo: function () {
- vc.component.addRepairSettingInfo = {
+ $that.addRepairSettingInfo = {
+ settingId: '',
repairTypeName: '',
- repairWay: '',
- saveRepairSetting: '',
+ repairWay: '200',
+ repairSettingType: '200',
remark: '',
- publicArea: '',
+ publicArea: 'F',
payFeeFlag: 'F',
priceScope: '',
- returnVisitFlag: '',
- notifyWay:'WECHAT'
+ returnVisitFlag: '003',
+ isShow: 'Y',
+ notifyWay: 'WECHAT'
};
}
}
diff --git a/public/components/property/editRepairSetting/editRepairSetting.html b/public/components/property/editRepairSetting/editRepairSetting.html
index 3f086797e..d199286e6 100644
--- a/public/components/property/editRepairSetting/editRepairSetting.html
+++ b/public/components/property/editRepairSetting/editRepairSetting.html
@@ -48,15 +48,15 @@
@@ -67,7 +67,7 @@