|
@@ -131,25 +131,41 @@ const index = (props) => {
|
131
|
131
|
|
132
|
132
|
setIsOpened(false)
|
133
|
133
|
}
|
134
|
|
- const onSave = () => {
|
135
|
|
- console.log(333)
|
136
|
134
|
|
|
135
|
+ const deleteImage = (e) => {
|
137
|
136
|
Taro.showModal({
|
138
|
|
- title: '修改成功',
|
139
|
|
- content: '点击确认按钮,返回上级菜单',
|
140
|
|
- showCancel: false,
|
|
137
|
+ title: '确定删除该图片吗?',
|
|
138
|
+
|
|
139
|
+ cancelColor: '#d2d2d2',
|
|
140
|
+ confirmColor: "#274191",
|
141
|
141
|
success: function (res) {
|
142
|
|
- if (res.confirm) {
|
143
|
|
- console.log('用户点击确定')
|
144
|
|
-
|
145
|
|
- Taro.navigateBack({
|
146
|
|
- delta: 1
|
147
|
|
- })
|
148
|
|
- } else if (res.cancel) {
|
149
|
|
- console.log('用户点击取消')
|
150
|
|
- }
|
|
142
|
+ if (res.confirm) {
|
|
143
|
+ console.log('用户点击确定')
|
|
144
|
+
|
|
145
|
+ setIsOpened(false)
|
|
146
|
+ // Taro.showModal({
|
|
147
|
+ // title: `改标签组有${row.user.number}个标签仍在使用。请先清空标签,再删除标签组`,
|
|
148
|
+ // showCancel: false,
|
|
149
|
+ // // cancelColor:'#d2d2d2',
|
|
150
|
+ // confirmColor: "#274191",
|
|
151
|
+ // success: function (res) {
|
|
152
|
+ // if (res.confirm) {
|
|
153
|
+ // console.log('用户点击确定')
|
|
154
|
+
|
|
155
|
+
|
|
156
|
+ // } else if (res.cancel) {
|
|
157
|
+ // console.log('用户点击取消')
|
|
158
|
+ // }
|
|
159
|
+ // }
|
|
160
|
+ // })
|
|
161
|
+
|
|
162
|
+ } else if (res.cancel) {
|
|
163
|
+ setIsOpened(false)
|
|
164
|
+ }
|
151
|
165
|
}
|
152
|
|
- })
|
|
166
|
+
|
|
167
|
+ })
|
|
168
|
+
|
153
|
169
|
}
|
154
|
170
|
|
155
|
171
|
const onLabelChange = (e, index) => {
|
|
@@ -208,7 +224,7 @@ const index = (props) => {
|
208
|
224
|
<View className='floatmodel' >
|
209
|
225
|
<View onClick={() => updateLabel()}>更改标签</View>
|
210
|
226
|
<View onClick={() => updateImage()}>更换图片</View>
|
211
|
|
- <View onClick={() => { setIsOpened(false); setRadioHouseState(true) }}>删除</View>
|
|
227
|
+ <View onClick={() => deleteImage() }>删除</View>
|
212
|
228
|
<View style={{ color: '#d2d2d2' }} onClick={() => setIsOpened(false)}>取消</View>
|
213
|
229
|
</View>
|
214
|
230
|
|