CZT
2023-09-15 abd0a1d82cbfedcc826007f808800a4a3db58902
src/main/java/com/fzzy/otherview/sh2023/ShApi2102.view.xml
@@ -3,9 +3,442 @@
  <Arguments/>
  <Context/>
  <Model>
    <DataType name="dtMain">
      <Property name="creationType">com.fzzy.push.sh2023.dto.SH2023Api2102</Property>
      <PropertyDef name="drdh">
        <Property></Property>
        <Property name="label">倒入单号</Property>
      </PropertyDef>
      <PropertyDef name="drdw">
        <Property></Property>
        <Property name="label">倒入单位</Property>
      </PropertyDef>
      <PropertyDef name="drhwsl">
        <Property></Property>
        <Property name="label">倒入数量</Property>
        <Property name="dataType">Double</Property>
        <Property name="displayFormat">#0.000000</Property>
      </PropertyDef>
      <PropertyDef name="drhwdm">
        <Property></Property>
        <Property name="label">倒入货位代码</Property>
      </PropertyDef>
      <PropertyDef name="czbz">
        <Property></Property>
        <Property name="label">操作标志</Property>
        <Property name="mapping">
          <Property name="mapValues">${dorado.getDataProvider(&quot;apiTriggerService#trigger&quot;).getResult(&quot;CZBZ&quot;)}</Property>
          <Property name="keyProperty">code</Property>
          <Property name="valueProperty">name</Property>
        </Property>
      </PropertyDef>
      <PropertyDef name="zhgxsj">
        <Property name="dataType">Date</Property>
        <Property name="label">最后更新时间</Property>
      </PropertyDef>
      <PropertyDef name="dcrq">
        <Property name="dataType">Date</Property>
        <Property name="label">倒入日期</Property>
      </PropertyDef>
      <PropertyDef name="kddh">
        <Property></Property>
        <Property name="label">库调单号</Property>
      </PropertyDef>
      <PropertyDef name="pch">
        <Property></Property>
        <Property name="label">批次号</Property>
      </PropertyDef>
      <PropertyDef name="bizId">
        <Property></Property>
        <Property name="label">业务id</Property>
      </PropertyDef>
      <PropertyDef name="kqdm">
        <Property></Property>
        <Property name="label">库区代码</Property>
      </PropertyDef>
      <PropertyDef name="syncTime">
        <Property name="dataType">Date</Property>
        <Property name="label">同步时间</Property>
      </PropertyDef>
      <PropertyDef name="bjw">
        <Property></Property>
        <Property name="label">标记位</Property>
        <Property name="mapping">
          <Property name="keyProperty">key</Property>
          <Property name="valueProperty">value</Property>
          <Property name="mapValues">
            <Collection>
              <Entity>
                <Property name="value">闵行区</Property>
                <Property name="key">minhang</Property>
              </Entity>
              <Entity>
                <Property name="value">宝山区</Property>
                <Property name="key">baoshan</Property>
              </Entity>
              <Entity>
                <Property name="value">嘉定区</Property>
                <Property name="key">jiading</Property>
              </Entity>
              <Entity>
                <Property name="value">浦东新区</Property>
                <Property name="key">pudong</Property>
              </Entity>
              <Entity>
                <Property name="value">金山区</Property>
                <Property name="key">jinshan</Property>
              </Entity>
              <Entity>
                <Property name="value">松江区</Property>
                <Property name="key">songjiang</Property>
              </Entity>
              <Entity>
                <Property name="value">青浦区</Property>
                <Property name="key">qingpu</Property>
              </Entity>
              <Entity>
                <Property name="value">奉贤区</Property>
                <Property name="key">fengxian</Property>
              </Entity>
              <Entity>
                <Property name="value">崇明区</Property>
                <Property name="key">chongming</Property>
              </Entity>
            </Collection>
          </Property>
        </Property>
      </PropertyDef>
    </DataType>
    <DataType name="dtParam">
      <Property name="creationType">com.fzzy.api.data.ApiParam</Property>
      <PropertyDef name="kqdm">
        <Property></Property>
        <Property name="label">所属库区</Property>
      </PropertyDef>
      <PropertyDef name="start">
        <Property name="dataType">Date</Property>
        <Property name="label">开始时间</Property>
      </PropertyDef>
      <PropertyDef name="end">
        <Property name="dataType">Date</Property>
        <Property name="label">截止时间</Property>
      </PropertyDef>
      <PropertyDef name="czbz">
        <Property></Property>
        <Property name="label">操作标志</Property>
        <Property name="mapping">
          <Property name="mapValues">${dorado.getDataProvider(&quot;apiTriggerService#trigger&quot;).getResult(&quot;CZBZ&quot;)}</Property>
          <Property name="keyProperty">code</Property>
          <Property name="valueProperty">name</Property>
        </Property>
      </PropertyDef>
    </DataType>
  </Model>
  <View layout="regionPadding:10">
    <Property name="packages">font-awesome,css-common</Property>
    <DataSet id="dsMain">
      <Property name="dataType">[dtMain]</Property>
      <Property name="dataProvider">sHApi2102PR#listData</Property>
      <Property name="pageSize">15</Property>
    </DataSet>
    <DataSet id="dsQuery">
      <ClientEvent name="onReady">self.insert();</ClientEvent>
      <Property name="dataType">dtParam</Property>
    </DataSet>
    <ToolBar>
      <ToolBarLabel>
        <Property name="text">工具栏:</Property>
        <Property name="style">
          <Property name="font-weight">bold</Property>
        </Property>
      </ToolBarLabel>
      <ToolBarButton>
        <ClientEvent name="onClick">var query = view.get(&quot;#dsQuery&quot;).getData();&#xD;
view.get(&quot;#dsMain&quot;).set(&quot;parameter&quot;,query).flushAsync();</ClientEvent>
        <Property name="caption">查询</Property>
        <Property name="iconClass">fa fa-search</Property>
        <Property name="width">100</Property>
        <Property name="exClassName">toolbar-button-push</Property>
      </ToolBarButton>
      <ToolBarButton id="btnAdd">
        <ClientEvent name="onClick">view.get(&quot;#dsMain&quot;).insert();&#xD;
view.get(&quot;#dialogMain&quot;).show();</ClientEvent>
        <Property name="caption">新增</Property>
        <Property name="iconClass">fa fa-plus</Property>
        <Property name="width">100</Property>
        <Property name="exClassName">toolbar-button</Property>
        <Property name="hideMode">display</Property>
      </ToolBarButton>
      <ToolBarButton id="btnUpdate">
        <ClientEvent name="onClick">var cur = view.get(&quot;#dgMain&quot;).getCurrentItem();&#xD;
if(cur){&#xD;
   view.get(&quot;#dialogMain&quot;).show();&#xD;
}</ClientEvent>
        <Property name="caption">修改</Property>
        <Property name="iconClass">fa fa-pencil</Property>
        <Property name="width">100</Property>
        <Property name="exClassName">toolbar-button-warm</Property>
        <Property name="hideMode">display</Property>
      </ToolBarButton>
      <ToolBarButton>
        <ClientEvent name="onClick">var cur = view.get(&quot;#dgMain&quot;).getCurrentItem();&#xD;
view.get(&quot;#ajaxDelUpdate&quot;).set(&quot;parameter&quot;,cur).execute(function(result){&#xD;
   if(result){&#xD;
      $alert(result);&#xD;
   } else{&#xD;
      cur.set(&quot;czbz&quot;,&quot;d&quot;)&#xD;
   }&#xD;
});&#xD;
</ClientEvent>
        <Property name="caption">标记删除</Property>
        <Property name="iconClass">fa fa-minus</Property>
        <Property name="exClassName">toolbar-button-warn</Property>
        <Property name="width">100</Property>
      </ToolBarButton>
      <ToolBarButton id="btnDel">
        <ClientEvent name="onClick">var cur = view.get(&quot;#dgMain&quot;).getCurrentItem();&#xD;
view.get(&quot;#ajaxDel&quot;).set(&quot;parameter&quot;,cur).execute(function(result){&#xD;
   if(result){&#xD;
      $alert(result);&#xD;
   } else{&#xD;
      cur.remove();&#xD;
   }&#xD;
});&#xD;
</ClientEvent>
        <Property name="caption">直接删除</Property>
        <Property name="iconClass">fa fa-minus</Property>
        <Property name="exClassName">toolbar-button-warn</Property>
        <Property name="width">100</Property>
        <Property name="hideMode">display</Property>
      </ToolBarButton>
      <ToolBarButton>
        <ClientEvent name="onClick">var select = view.get(&quot;#dgMain&quot;).get(&quot;selection&quot;);&#xD;
if(select &amp;&amp; select.length > 0){&#xD;
   view.get(&quot;#ajaxPush&quot;).set(&quot;parameter&quot;,select).execute(function(result){&#xD;
      view.get(&quot;#dsMain&quot;).flushAsync();&#xD;
          $notify(result);&#xD;
   });&#xD;
}else{&#xD;
   $alert(&quot;请勾选上报数据!&quot;);&#xD;
}&#xD;
</ClientEvent>
        <Property name="caption">手动上传</Property>
        <Property name="iconClass">fa fa-hand-o-up</Property>
        <Property name="exClassName">toolbar-button-push</Property>
        <Property name="width">100</Property>
      </ToolBarButton>
      <Fill/>
      <ToolBarButton>
        <Property name="caption">上传记录</Property>
        <Property name="iconClass">fa fa-bars</Property>
        <Property name="exClassName">toolbar-button</Property>
        <Property name="width">100</Property>
      </ToolBarButton>
    </ToolBar>
    <AutoForm>
      <Property name="dataSet">dsQuery</Property>
      <Property name="cols">*,*,*,*</Property>
      <Property name="labelAlign">right</Property>
      <Property name="labelSeparator">:</Property>
      <Property name="labelWidth">90</Property>
      <AutoFormElement>
        <Property name="name">kqdm</Property>
        <Property name="property">kqdm</Property>
        <Editor/>
      </AutoFormElement>
      <AutoFormElement>
        <Property name="name">start</Property>
        <Property name="property">start</Property>
        <Editor/>
      </AutoFormElement>
      <AutoFormElement>
        <Property name="name">end</Property>
        <Property name="property">end</Property>
        <Editor/>
      </AutoFormElement>
      <AutoFormElement>
        <Property name="name">czbz</Property>
        <Property name="property">czbz</Property>
        <Property name="trigger">autoMappingDropDown2</Property>
        <Editor/>
      </AutoFormElement>
    </AutoForm>
    <DataGrid id="dgMain">
      <ClientEvent name="onDataRowDoubleClick">view.get(&quot;#dialogMain&quot;).show();</ClientEvent>
      <Property name="dataSet">dsMain</Property>
      <Property name="selectionMode">multiRows</Property>
      <Property name="readOnly">true</Property>
      <RowNumColumn/>
      <RowSelectorColumn>
        <Property name="caption">上传</Property>
      </RowSelectorColumn>
      <DataColumn name="drdh">
        <Property name="property">drdh</Property>
        <Property name="align">center</Property>
      </DataColumn>
      <DataColumn name="drdw">
        <Property name="property">drdw</Property>
        <Property name="align">center</Property>
      </DataColumn>
      <DataColumn name="drhwsl">
        <Property name="property">drhwsl</Property>
        <Property name="align">center</Property>
      </DataColumn>
      <DataColumn name="drhwdm">
        <Property name="property">drhwdm</Property>
        <Property name="align">center</Property>
      </DataColumn>
      <DataColumn name="czbz">
        <Property name="property">czbz</Property>
        <Property name="align">center</Property>
      </DataColumn>
      <DataColumn name="zhgxsj">
        <Property name="property">zhgxsj</Property>
        <Property name="align">center</Property>
      </DataColumn>
      <DataColumn name="dcrq">
        <Property name="property">dcrq</Property>
        <Property name="align">center</Property>
      </DataColumn>
      <DataColumn name="kddh">
        <Property name="property">kddh</Property>
        <Property name="align">center</Property>
      </DataColumn>
      <DataColumn name="bjw">
        <Property name="property">bjw</Property>
        <Property name="align">center</Property>
      </DataColumn>
      <DataColumn name="pch">
        <Property name="property">pch</Property>
        <Property name="align">center</Property>
      </DataColumn>
    </DataGrid>
    <ToolBar layoutConstraint="bottom">
      <Fill/>
      <DataPilot>
        <Property name="itemCodes">pageSize,pages</Property>
        <Property name="dataSet">dsMain</Property>
      </DataPilot>
    </ToolBar>
    <Dialog id="dialogMain">
      <Property name="width">80%</Property>
      <Property name="caption">到仓信息</Property>
      <Property name="iconClass">fa fa-sliders</Property>
      <Property name="closeable">false</Property>
      <Buttons>
        <Button>
          <ClientEvent name="onClick">var cur = view.get(&quot;#dgMain&quot;).getCurrentItem();&#xD;
view.get(&quot;#updateSave&quot;).execute(function(){&#xD;
   self.get(&quot;parent&quot;).hide();&#xD;
});</ClientEvent>
          <Property name="caption">保存修改</Property>
          <Property name="iconClass">fa fa-check</Property>
          <Property name="exClassName">toolbar-button</Property>
        </Button>
        <Button>
          <ClientEvent name="onClick">var cur = view.get(&quot;#dgMain&quot;).getCurrentItem();&#xD;
self.get(&quot;parent&quot;).hide();&#xD;
if(cur) cur.cancel();</ClientEvent>
          <Property name="caption">取消修改</Property>
          <Property name="iconClass">fa fa-times</Property>
          <Property name="exClassName">toolbar-button-warn</Property>
        </Button>
      </Buttons>
      <Children>
        <AutoForm>
          <Property name="dataSet">dsMain</Property>
          <Property name="cols">*,*</Property>
          <Property name="labelWidth">150</Property>
          <Property name="labelAlign">left</Property>
          <Property name="labelSeparator">:</Property>
          <Property name="labelPosition">left</Property>
          <AutoFormElement>
            <Property name="name">drdh</Property>
            <Property name="property">drdh</Property>
            <Editor/>
          </AutoFormElement>
          <AutoFormElement>
            <Property name="name">drdw</Property>
            <Property name="property">drdw</Property>
            <Editor/>
          </AutoFormElement>
          <AutoFormElement>
            <Property name="name">drhwsl</Property>
            <Property name="property">drhwsl</Property>
            <Editor/>
          </AutoFormElement>
          <AutoFormElement>
            <Property name="name">drhwdm</Property>
            <Property name="property">drhwdm</Property>
            <Editor/>
          </AutoFormElement>
          <AutoFormElement>
            <Property name="name">czbz</Property>
            <Property name="property">czbz</Property>
            <Editor/>
          </AutoFormElement>
          <AutoFormElement>
            <Property name="name">zhgxsj</Property>
            <Property name="property">zhgxsj</Property>
            <Editor/>
          </AutoFormElement>
          <AutoFormElement>
            <Property name="name">dcrq</Property>
            <Property name="property">dcrq</Property>
            <Editor/>
          </AutoFormElement>
          <AutoFormElement>
            <Property name="name">kddh</Property>
            <Property name="property">kddh</Property>
            <Editor/>
          </AutoFormElement>
          <AutoFormElement>
            <Property name="name">bjw</Property>
            <Property name="property">bjw</Property>
            <Editor/>
          </AutoFormElement>
          <AutoFormElement>
            <Property name="name">pch</Property>
            <Property name="property">pch</Property>
            <Editor/>
          </AutoFormElement>
          <AutoFormElement>
            <Property name="name">bizId</Property>
            <Property name="property">bizId</Property>
            <Editor/>
          </AutoFormElement>
          <AutoFormElement>
            <Property name="name">kqdm</Property>
            <Property name="property">kqdm</Property>
            <Editor/>
          </AutoFormElement>
          <AutoFormElement>
            <Property name="name">syncTime</Property>
            <Property name="property">syncTime</Property>
            <Editor/>
          </AutoFormElement>
        </AutoForm>
      </Children>
      <Tools/>
    </Dialog>
    <UpdateAction id="updateSave">
      <Property name="dataResolver">sHApi2102PR#saveData</Property>
      <UpdateItem>
        <Property name="dataPath">[#current]</Property>
        <Property name="dataSet">dsMain</Property>
      </UpdateItem>
    </UpdateAction>
    <AjaxAction id="ajaxPush">
      <Property name="service">sHApi2102PR#pushData</Property>
      <Property name="confirmMessage">确定要上报么?</Property>
    </AjaxAction>
    <AjaxAction id="ajaxDel">
      <Property name="service">sHApi2102PR#delData</Property>
      <Property name="confirmMessage">当前数据删除后无法恢复,请确认要删除么?</Property>
    </AjaxAction>
    <AjaxAction id="ajaxDelUpdate">
      <Property name="service">sHApi2102PR#delUpdate</Property>
      <Property name="confirmMessage">确定要将数据标记为删除么?</Property>
    </AjaxAction>
  </View>
</ViewConfig>