| | |
| | | <Property name="dataProvider">checkStandardPR#listCheckItemsByParam</Property> |
| | | <Property name="dataType">[dtCheckItems]</Property> |
| | | </Reference> |
| | | <Reference name="files"> |
| | | <Property name="dataProvider">sys.fileManager#listFile</Property> |
| | | <Property name="dataType">[dtFileData]</Property> |
| | | <Property name="parameter">$${this.id}</Property> |
| | | </Reference> |
| | | </DataType> |
| | | <DataType name="dtCheckItems"> |
| | | <Property name="creationType">com.ld.igds.check.dto.CheckItemData</Property> |
| | |
| | | <View layout="padding:5;regionPadding:5"> |
| | | <ClientEvent name="onReady">var TYPE = "${request.getParameter('type')}";
 |
| | | 
 |
| | | var PROGRESS = "WEIGHT_TAG";
 |
| | | 
 |
| | | /**
 |
| | | * 刷新页面
 |
| | | */
 |
| | |
| | | <Property name="iconClass">fa fa-minus</Property> |
| | | </Button> |
| | | </Container> |
| | | <TabControl id="tabControlMain"> |
| | | <TabControl id="tabControlMain" layoutConstraint="left "> |
| | | <Property name="width">1300</Property> |
| | | <ControlTab> |
| | | <Property name="caption">基础信息</Property> |
| | |
| | | </AutoFormElement> |
| | | </AutoForm> |
| | | <DataGrid id="dataGridCheckItem" layoutConstraint="padding:10"> |
| | | <ClientEvent name="onCellValueEdit">var data = arg.entity;
 |
| | | //根据填写化验数据,给出提醒是否合格
 |
| | | <ClientEvent name="onCellValueEdit">var data = view.get("#dsMain.data:#")
 |
| | | if(data){
 |
| | | //填写的数据值
 |
| | | var newValue = data.get("value");
 |
| | | 
 |
| | | //标准值
 |
| | | var limit = data.get("upperLimit");
 |
| | | 
 |
| | | //运算符
 |
| | | var symbol = data.get("operaSymbol");
 |
| | | 
 |
| | | if (symbol && limit) {
 |
| | | if (">=" == symbol) {
 |
| | | if (newValue < limit) {
 |
| | | data.set("result", "0");
 |
| | | 
 |
| | | } else {
 |
| | | data.set("result", "1");
 |
| | | }
 |
| | | }
 |
| | | if ("<=" == symbol) {
 |
| | | if (newValue > limit) {
 |
| | | data.set("result", "0");
 |
| | | } else {
 |
| | | data.set("result", "1");
 |
| | | }
 |
| | | }
 |
| | | if ("==" == symbol) {
 |
| | | if (newValue != limit) {
 |
| | | data.set("result", "0");
 |
| | | } else {
 |
| | | data.set("result", "1");
 |
| | | }
 |
| | | }
 |
| | | }
 |
| | | }</ClientEvent> |
| | | var plateNum = data.get("plateNum");
 |
| | | self.set("parameter",{
 |
| | | plateNum:plateNum
 |
| | | })
 |
| | | }
 |
| | | </ClientEvent> |
| | | <Property name="dataSet">dsMain</Property> |
| | | <Property name="dataPath">#.checkItems</Property> |
| | | <Property name="highlightCurrentRow">false</Property> |
| | |
| | | </DataColumn> |
| | | </DataGrid> |
| | | </Container> |
| | | </ControlTab> |
| | | </TabControl> |
| | | <TabControl id="tabControlImage" layoutConstraint="left"> |
| | | <Property name="width">370</Property> |
| | | <ControlTab id="tabImage"> |
| | | <Property name="name">tabImage</Property> |
| | | <Property name="caption">出入库过程记录</Property> |
| | | <FieldSet layout="regionPadding:5" layoutConstraint="top padding:10"> |
| | | <Buttons> |
| | | <Button layoutConstraint="left"> |
| | | <ClientEvent name="onClick">view.PROGRESS = "EMPTY_WEIGHT";
 |
| | | </ClientEvent> |
| | | <Property name="exClassName">btn-default</Property> |
| | | <Property name="iconClass">fa fa-cloud-upload</Property> |
| | | <Property name="action">uploadImg</Property> |
| | | <Property name="caption">空车称</Property> |
| | | </Button> |
| | | <Button layoutConstraint="left"> |
| | | <ClientEvent name="onClick">view.PROGRESS = "FULL_WEIGHT";
 |
| | | </ClientEvent> |
| | | <Property name="exClassName">btn-default</Property> |
| | | <Property name="iconClass">fa fa-cloud-upload</Property> |
| | | <Property name="action">uploadImg1</Property> |
| | | <Property name="caption">满车称</Property> |
| | | </Button> |
| | | <Button layoutConstraint="left"> |
| | | <ClientEvent name="onClick">view.PROGRESS = "HAND";</ClientEvent> |
| | | <Property name="caption">值仓</Property> |
| | | <Property name="exClassName">btn-default</Property> |
| | | <Property name="iconClass">fa fa-cloud-upload</Property> |
| | | <Property name="action">uploadImg2</Property> |
| | | </Button> |
| | | </Buttons> |
| | | <Children> |
| | | <DataGrid id="dgFiles"> |
| | | <Property name="dataSet">dsMain</Property> |
| | | <Property name="readOnly">true</Property> |
| | | <Property name="selectionMode">singleRow</Property> |
| | | <Property name="dataPath">#.files</Property> |
| | | <RowNumColumn/> |
| | | <DataColumn name="bizTag"> |
| | | <Property name="property">bizTag</Property> |
| | | <Property name="visible">false</Property> |
| | | </DataColumn> |
| | | <DataColumn name="fileName"> |
| | | <Property name="property">fileName</Property> |
| | | </DataColumn> |
| | | </DataGrid> |
| | | </Children> |
| | | </FieldSet> |
| | | </ControlTab> |
| | | </TabControl> |
| | | <YearDropDown id="yearDropDown"/> |
| | |
| | | </DataGrid> |
| | | </Container> |
| | | </CustomDropDown> |
| | | <UploadAction id="uploadImg"> |
| | | <ClientEvent name="beforeFileUploaded">var data = view.get("#dsMain.data:#")
 |
| | | 
 |
| | | var plateNum = data.get("plateNum");
 |
| | | self.set("parameter",{
 |
| | | plateNum:plateNum,
 |
| | | bizTag:"EMPTY_WEIGHT"
 |
| | | })</ClientEvent> |
| | | <ClientEvent name="onFileUploaded">//附件上传完成后添加业务数据
 |
| | | var mainData = view.get("#dsMain.data");
 |
| | | var fileName = arg.returnValue;
 |
| | | var files = mainData.get("files");
 |
| | | files.insert({bizTag:view.PROGRESS,fileName:fileName,createTime:new Date()});</ClientEvent> |
| | | <ClientEvent name="beforeFileUploaded">var data = view.get("#dsMain.data:#")
 |
| | | if(data){
 |
| | | var plateNum = data.get("plateNum");
 |
| | | self.set("parameter",{
 |
| | | plateNum:plateNum
 |
| | | })
 |
| | | }</ClientEvent> |
| | | <Property name="maxFileSize">20MB</Property> |
| | | <Property name="successMessage">上传成功</Property> |
| | | <Property name="parameter"></Property> |
| | | <Property name="fileResolver">inoutDataPR#uploadImage</Property> |
| | | <Filters/> |
| | | </UploadAction> |
| | | <UploadAction id="uploadImg1"> |
| | | <ClientEvent name="beforeFileUploaded">var data = view.get("#dsMain.data:#")
 |
| | | 
 |
| | | var plateNum = data.get("plateNum");
 |
| | | self.set("parameter",{
 |
| | | plateNum:plateNum,
 |
| | | bizTag:"FULL_WEIGHT"
 |
| | | })</ClientEvent> |
| | | <ClientEvent name="onFileUploaded">//附件上传完成后添加业务数据
 |
| | | var mainData = view.get("#dsMain.data");
 |
| | | var fileName = arg.returnValue;
 |
| | | var files = mainData.get("files");
 |
| | | files.insert({bizTag:view.PROGRESS,fileName:fileName});</ClientEvent> |
| | | <ClientEvent name="beforeFileUploaded">var data = view.get("#dsMain.data:#")
 |
| | | if(data){
 |
| | | var plateNum = data.get("plateNum");
 |
| | | self.set("parameter",{
 |
| | | plateNum:plateNum
 |
| | | })
 |
| | | }</ClientEvent> |
| | | <Property name="maxFileSize">20MB</Property> |
| | | <Property name="successMessage">上传成功</Property> |
| | | <Property name="parameter"></Property> |
| | | <Property name="fileResolver">inoutDataPR#uploadImage</Property> |
| | | <Filters/> |
| | | </UploadAction> |
| | | <UploadAction id="uploadImg2"> |
| | | <ClientEvent name="beforeFileUploaded">var data = view.get("#dsMain.data:#")
 |
| | | 
 |
| | | var plateNum = data.get("plateNum");
 |
| | | self.set("parameter",{
 |
| | | plateNum:plateNum,
 |
| | | bizTag:"HAND"
 |
| | | })</ClientEvent> |
| | | <ClientEvent name="onFileUploaded">//附件上传完成后添加业务数据
 |
| | | var mainData = view.get("#dsMain.data");
 |
| | | var fileName = arg.returnValue;
 |
| | | var files = mainData.get("files");
 |
| | | files.insert({bizTag:view.PROGRESS,fileName:fileName});</ClientEvent> |
| | | <ClientEvent name="beforeFileUploaded">var data = view.get("#dsMain.data:#")
 |
| | | if(data){
 |
| | | var plateNum = data.get("plateNum");
 |
| | | self.set("parameter",{
 |
| | | plateNum:plateNum
 |
| | | })
 |
| | | }</ClientEvent> |
| | | <Property name="maxFileSize">20MB</Property> |
| | | <Property name="successMessage">上传成功</Property> |
| | | <Property name="parameter"></Property> |
| | | <Property name="fileResolver">inoutDataPR#uploadImage</Property> |
| | | <Filters/> |
| | | </UploadAction> |
| | | </View> |
| | | </ViewConfig> |